options: Fix variable tracking option processing.
authorMartin Liska <mliska@suse.cz>
Thu, 14 Oct 2021 12:57:18 +0000 (14:57 +0200)
committerMartin Liska <mliska@suse.cz>
Thu, 21 Oct 2021 13:20:09 +0000 (15:20 +0200)
commitb4702276615ff8d43bc910e7a54fdd850ad8d461
tree755b63565fd478c74216b8af60e208ed96220740
parent701ee067807b80957c65bd7ff94b6099a27181de
options: Fix variable tracking option processing.

PR debug/102585
PR bootstrap/102766

gcc/ChangeLog:

* opts.c (finish_options): Process flag_var_tracking* options
here as they can be adjusted by optimize attribute.
Process also flag_syntax_only and flag_gtoggle.
* toplev.c (process_options): Remove it here.
* common.opt: Make debug_nonbind_markers_p as PerFunction
attribute as it depends on optimization level.

gcc/testsuite/ChangeLog:

* gcc.dg/pr102585.c: New test.
gcc/common.opt
gcc/opts.c
gcc/testsuite/gcc.dg/pr102585.c [new file with mode: 0644]
gcc/toplev.c