From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id DF7DB3857C6F; Mon, 29 Nov 2021 13:23:23 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DF7DB3857C6F From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/103465] Invalid note with -fno-reorder-blocks-and-partition Date: Mon, 29 Nov 2021 13:23:23 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: rtl-optimization X-Bugzilla-Version: 11.2.0 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: normal X-Bugzilla-Who: marxin at gcc dot gnu.org X-Bugzilla-Status: WAITING X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: marxin at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Nov 2021 13:23:24 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D103465 Martin Li=C5=A1ka changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |WAITING --- Comment #3 from Martin Li=C5=A1ka --- Let's speak about the current master: > With "12.0" (5e5f880d0452ef2cffb94f4a686d56833c9f4215), the note is not > emitted with -fno-reorder-blocks-and-partition, however, the other problem > remains. The note is still not emitted when the optimization is enabled > implicitly via -O2. I see: /xgcc -B. /home/marxin/Programming/testcases/pr103465.c -c -O2 -freorder-blocks-and-partition /home/marxin/Programming/testcases/pr103465.c:2:9: note: =E2=80=98-freorder-blocks-and-partition=E2=80=99 does not support unwind in= fo on this architecture 2 | #pragma GCC optimize ("unroll-loops") | ^~~ /home/marxin/Programming/testcases/pr103465.c:4:1: note: =E2=80=98-freorder-blocks-and-partition=E2=80=99 does not support unwind in= fo on this architecture 4 | int main(int argc, char **argv) { | ^~~ which seems correct to me. With only -O2 there's no note emitted and the fl= ags are properly dropped (same in -freorder-blocks-and-partition): $ cat -n gcc/opts.c ... 1133 if (opts->x_flag_unwind_tables 1134 && !targetm_common.unwind_tables_default 1135 && opts->x_flag_reorder_blocks_and_partition 1136 && (ui_except =3D=3D UI_SJLJ || ui_except >=3D UI_TARGET)) 1137 { 1138 if (opts_set->x_flag_reorder_blocks_and_partition) 1139 inform (loc, 1140 "%<-freorder-blocks-and-partition%> does not suppor= t " 1141 "unwind info on this architecture"); 1142 opts->x_flag_reorder_blocks_and_partition =3D 0; 1143 opts->x_flag_reorder_blocks =3D 1; 1144 } So what's wrong with that, please?=