From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2759 invoked by alias); 11 Jul 2014 16:23:41 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 2680 invoked by uid 48); 11 Jul 2014 16:23:33 -0000 From: "zeccav at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/61779] New: gcc -Og fails with impossible constraint on legal C code Date: Fri, 11 Jul 2014 16:23:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 4.9.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: zeccav at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: 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-SW-Source: 2014-07/txt/msg00714.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D61779 Bug ID: 61779 Summary: gcc -Og fails with impossible constraint on legal C code Product: gcc Version: 4.9.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: zeccav at gmail dot com Created attachment 33108 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D33108&action=3Dedit Same code as in the bug Description The following code compiles fine without the -Og option. Compiled with -Og gcc fails. /* gcc -Og error: impossible constraint in =E2=80=98asm=E2=80=99 */ extern unsigned long long __sdt_unsp; void f(void) { for (;;) __asm__ (".pushsection .note.stapsdt" "," "\"?\"" "," "\"note\"" "\n" ".4= byte 992f-991f" "," "994f-993f" "," "3" "\n" ".asciz \"%n[_SDT_S1]@%[_SDT_A1]\"" "\n" :: [_SDT_S1] "n" (((!__extension__ (__builtin_constant_p ((((unsigned = long long) (__typeof (__builtin_choose_expr (((__builtin_classify_type (0) + 3) & -4) =3D=3D 4, (0), 0U))) __sdt_unsp) ) =3D=3D 0) )) ? 1 : -1) ), [_SDT_A1] = "nor" ((0))); } >>From gcc-bugs-return-456124-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri Jul 11 16:26:21 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 6108 invoked by alias); 11 Jul 2014 16:26:20 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 5969 invoked by uid 48); 11 Jul 2014 16:26:11 -0000 From: "zeccav at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/61779] gcc -Og fails with impossible constraint on legal C code Date: Fri, 11 Jul 2014 16:26:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 4.9.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: zeccav at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-07/txt/msg00715.txt.bz2 Content-length: 192 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61779 --- Comment #1 from Vittorio Zecca --- I forgot to say that gcc 4.9.0 fails but compiles correctly on gcc 4.8.3.