public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "marxin at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/103465] Invalid note with -fno-reorder-blocks-and-partition Date: Thu, 09 Dec 2021 19:29:31 +0000 [thread overview] Message-ID: <bug-103465-4-C9BF5V6J8o@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-103465-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103465 Martin Liška <marxin at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|WAITING |ASSIGNED Assignee|unassigned at gcc dot gnu.org |marxin at gcc dot gnu.org Target Milestone|--- |12.0 --- Comment #15 from Martin Liška <marxin at gcc dot gnu.org> --- All right, got it even with the cross compiler. So what happens with the test-case without the optimize attribute: - options are parsed and finish_options is called: if (opts->x_flag_unwind_tables && !targetm_common.unwind_tables_default && opts->x_flag_reorder_blocks_and_partition && (ui_except == UI_SJLJ || ui_except >= UI_TARGET)) { if (opts_set->x_flag_reorder_blocks_and_partition) inform (loc, "%<-freorder-blocks-and-partition%> does not support " "unwind info on this architecture"); opts->x_flag_reorder_blocks_and_partition = 0; opts->x_flag_reorder_blocks = 1; } It's not triggered because of opts->x_flag_unwind_tables is false by default, but the option is overwritten in target: #0 ix86_recompute_optlev_based_flags (opts=0x3c6b1c0 <global_options>, opts_set=0x3c6c8a0 <global_options_set>) at /home/marxin/Programming/gcc/gcc/config/i386/i386-options.c:1787 #1 0x0000000001b1c126 in ix86_option_override_internal (main_args_p=true, opts=0x3c6b1c0 <global_options>, opts_set=0x3c6c8a0 <global_options_set>) at /home/marxin/Programming/gcc/gcc/config/i386/i386-options.c:2332 #2 0x0000000001b1de5f in ix86_option_override () at /home/marxin/Programming/gcc/gcc/config/i386/i386-options.c:2961 #3 0x00000000014e44be in process_options (no_backend=false) at /home/marxin/Programming/gcc/gcc/toplev.c:1238 #4 0x00000000014e6925 in toplev::main (this=0x7fffffffdb7a, argc=21, argv=0x7fffffffdcc8) at /home/marxin/Programming/gcc/gcc/toplev.c:2320 #5 0x0000000002d423c8 in main (argc=21, argv=0x7fffffffdcc8) at /home/marxin/Programming/gcc/gcc/main.c:39 ... if (TARGET_64BIT_P (opts->x_ix86_isa_flags)) { if (opts->x_optimize >= 1) SET_OPTION_IF_UNSET (opts, opts_set, flag_omit_frame_pointer, !USE_IX86_FRAME_POINTER); if (opts->x_flag_asynchronous_unwind_tables && TARGET_64BIT_MS_ABI) SET_OPTION_IF_UNSET (opts, opts_set, flag_unwind_tables, 1); ... and so x_flag_reorder_blocks_and_partition is not dropped. On the other hand, when optimize attribute is used, then finish_options is called for it and we see the note and the flagged dropped. So the checking code should be called both from process_options and finish_options. Option handling is a can of worms. Lemme test a patch tomorrow.
next prev parent reply other threads:[~2021-12-09 19:29 UTC|newest] Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-11-29 10:00 [Bug rtl-optimization/103465] New: " tomas.kalibera at gmail dot com 2021-11-29 10:12 ` [Bug rtl-optimization/103465] " marxin at gcc dot gnu.org 2021-11-29 10:17 ` tomas.kalibera at gmail dot com 2021-11-29 10:18 ` marxin at gcc dot gnu.org 2021-11-29 13:23 ` marxin at gcc dot gnu.org 2021-11-29 15:25 ` tomas.kalibera at gmail dot com 2021-12-09 13:39 ` marxin at gcc dot gnu.org 2021-12-09 13:40 ` marxin at gcc dot gnu.org 2021-12-09 14:37 ` tomas.kalibera at gmail dot com 2021-12-09 14:41 ` tomas.kalibera at gmail dot com 2021-12-09 14:44 ` tomas.kalibera at gmail dot com 2021-12-09 15:24 ` tomas.kalibera at gmail dot com 2021-12-09 15:28 ` marxin at gcc dot gnu.org 2021-12-09 15:44 ` marxin at gcc dot gnu.org 2021-12-09 15:53 ` tomas.kalibera at gmail dot com 2021-12-09 15:55 ` tomas.kalibera at gmail dot com 2021-12-09 19:29 ` marxin at gcc dot gnu.org [this message] 2021-12-28 10:05 ` [Bug driver/103465] " cvs-commit at gcc dot gnu.org 2021-12-28 10:06 ` marxin at gcc dot gnu.org 2022-01-06 7:32 ` [Bug driver/103465] [12 regression] -freorder-blocks-and-partition broken on 64-bit Windows ebotcazou at gcc dot gnu.org 2022-01-06 9:51 ` marxin at gcc dot gnu.org 2022-01-06 11:42 ` ebotcazou at gcc dot gnu.org 2022-01-06 12:47 ` marxin at gcc dot gnu.org 2022-01-06 13:45 ` ebotcazou at gcc dot gnu.org 2022-01-06 13:50 ` marxin at gcc dot gnu.org 2022-01-06 14:07 ` tomas.kalibera at gmail dot com 2022-01-06 17:17 ` [Bug target/103465] " ebotcazou at gcc dot gnu.org 2022-01-06 22:18 ` tomas.kalibera at gmail dot com 2022-01-07 9:50 ` tomas.kalibera at gmail dot com 2022-01-07 17:33 ` tomas.kalibera at gmail dot com 2022-01-10 11:44 ` cvs-commit at gcc dot gnu.org 2022-01-10 16:06 ` cvs-commit at gcc dot gnu.org 2022-01-10 16:06 ` cvs-commit at gcc dot gnu.org 2022-01-10 16:07 ` cvs-commit at gcc dot gnu.org 2022-01-10 16:09 ` ebotcazou at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-103465-4-C9BF5V6J8o@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).