This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug bootstrap/64213] gimple-match.c:1523:6: error: âGIMPLEâ was not declared in this scope
- From: "rguenther at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 09 Dec 2014 11:41:29 +0000
- Subject: [Bug bootstrap/64213] gimple-match.c:1523:6: error: âGIMPLEâ was not declared in this scope
- Auto-submitted: auto-generated
- References: <bug-64213-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64213
--- Comment #5 from rguenther at suse dot de <rguenther at suse dot de> ---
On Tue, 9 Dec 2014, ubizjak at gmail dot com wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64213
>
> --- Comment #4 from UroÅ Bizjak <ubizjak at gmail dot com> ---
> One of several testsuite failures (with non-bootstrapped compiler) is:
>
> FAIL: gcc.c-torture/execute/20020805-1.c -Os execution test
>
> --cut here--
> extern void abort (void);
> extern void exit (int);
>
> void check (unsigned int m)
> {
> if (m != (unsigned int) -1)
> abort ();
> }
>
> unsigned int n = 1;
>
> int main (void)
> {
> unsigned int m;
> m = (1 | (2 - n)) | (-n);
> check (m);
> exit (0);
> }
> --cut here--
>
> So, the difference between trunk (+) and trunk with reverted patch (-) starts
> at _.214r.combine, where "check" function gets miscompiled:
>
> 4: NOTE_INSN_BASIC_BLOCK 2
> 2: NOTE_INSN_DELETED
> 3: NOTE_INSN_FUNCTION_BEG
> - 6: r71:DI=zero_extend($16:SI)
> - REG_DEAD $16:DI
> + 6: NOTE_INSN_DELETED
> 7: r73:DI=0xffffffffffffffff
> 8: r72:DI=r73:DI 0>>0x20
> REG_DEAD r73:DI
> REG_EQUAL 0xffffffff
> - 9: r74:DI=r71:DI==r72:DI
> + 9: r74:DI=$16:DI==r72:DI
> + REG_DEAD $16:DI
> REG_DEAD r72:DI
> - REG_DEAD r71:DI
> 10: pc={(r74:DI!=0)?L16:pc}
> REG_DEAD r74:DI
> REG_BR_PROB 9996
>
> This results in an asm code difference, where needed SI->DI zero_extend is
> missing:
>
> @@ -18,7 +18,6 @@
> lda $1,-1($31)
> lda $30,-16($30)
> .cfi_def_cfa_offset 16
> - zapnot $16,15,$16
> srl $1,32,$1
> stq $26,0($30)
> .cfi_offset 26, -16
>
> I propose to revert H.J.'s patch for PR64037.
Agreed and approved. Please make sure to re-open bugs that were
fixed by the patch.