diff options
author | Martin Liska <mliska@suse.cz> | 2022-01-12 12:48:33 +0100 |
---|---|---|
committer | Martin Liska <mliska@suse.cz> | 2022-01-12 12:52:19 +0100 |
commit | 4960516df2f90e6ae16aa03c63c8bf2c702e6bc4 (patch) | |
tree | c60ab9b070fd9ac64d1ea60febc7f10c5411d316 /gcc | |
parent | 4ec756cee0be1510a9fcb3dcb9bdea625f774277 (diff) | |
download | gcc-4960516df2f90e6ae16aa03c63c8bf2c702e6bc4.zip gcc-4960516df2f90e6ae16aa03c63c8bf2c702e6bc4.tar.gz gcc-4960516df2f90e6ae16aa03c63c8bf2c702e6bc4.tar.bz2 |
opts: do not do sanity check when an error is seen
PR target/103804
gcc/c-family/ChangeLog:
* c-attribs.c (handle_optimize_attribute): Do not call
cl_optimization_compare if we seen an error.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/c-family/c-attribs.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/c-family/c-attribs.c b/gcc/c-family/c-attribs.c index dbb892e..bdf72ce 100644 --- a/gcc/c-family/c-attribs.c +++ b/gcc/c-family/c-attribs.c @@ -5516,7 +5516,8 @@ handle_optimize_attribute (tree *node, tree name, tree args, if (saved_global_options != NULL) { - cl_optimization_compare (saved_global_options, &global_options); + if (!seen_error ()) + cl_optimization_compare (saved_global_options, &global_options); free (saved_global_options); } } |