public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug rtl-optimization/57963] New: LRA S/390: esa mode failure memcpy-chk
@ 2013-07-23 15:11 krebbel at gcc dot gnu.org
  2013-08-01 20:43 ` [Bug rtl-optimization/57963] " vmakarov at gcc dot gnu.org
  2013-09-09 15:24 ` krebbel at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: krebbel at gcc dot gnu.org @ 2013-07-23 15:11 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57963

            Bug ID: 57963
           Summary: LRA S/390: esa mode failure memcpy-chk
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: rtl-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: krebbel at gcc dot gnu.org

memcpy-chk with -O2 fails if compiled with lra enabled.
It succeeds with -mno-lra.

With lra an insn storing into the literal pool is being emitted:

ira:

(insn 126 127 129 11 (parallel [
            (set (reg/f:SI 60 [ D.1911 ])
                (plus:SI (reg/v/f:SI 126 [ buf3 ])
                    (const_int 14 [0xe])))
            (clobber (reg:CC 33 %cc))
        ])
/build/gcc-head/gcc/testsuite/gcc.c-torture/execute/builtins/memcpy-chk.c:131
297 {*addsi3}
     (expr_list:REG_UNUSED (reg:CC 33 %cc)
        (expr_list:REG_EQUIV (const:SI (plus:SI (symbol_ref:SI ("buf1") [flags
0x400]  <var_decl 0x7b97c9c0 buf1>)
                    (const_int 14 [0xe])))
            (nil))))

(insn 129 126 135 11 (set (reg/f:SI 261)
        (mem/u/c:SI (symbol_ref/u:SI ("*.LC69") [flags 0x2]) [3 S4 A32]))
/build/gcc-head/gcc/testsuite/gcc.c-torture/execute/builtins/memcpy-chk.c:131
68 {*movsi_esa}
     (expr_list:REG_EQUIV (const:SI (plus:SI (symbol_ref:SI ("buf1") [flags
0x400]  <var_decl 0x7b97c9c0 buf1>)
                (const_int 14 [0xe])))
        (nil)))


reload:


  126: {r406:SI=r406:SI+0xe;clobber %cc:CC;}
      REG_UNUSED %cc:CC
      REG_EQUIV const(`buf1'+0xe)
    Inserting insn reload before:
  829: r406:SI=r126:SI
    Inserting insn reload after:
  830: r60:SI=r406:SI

          alt=1,overall=1,losers=0,rld_nregs=0
         Choosing alt 1 in insn 830:  (0) d  (1) d {*movsi_esa}
          alt=1,overall=1,losers=0,rld_nregs=0
         Choosing alt 1 in insn 829:  (0) d  (1) d {*movsi_esa}
      Removing equiv init insn 129 (freq=9944)
  129: r261:SI=[`*.LC69']
      REG_EQUIV const(`buf1'+0xe)
deleting insn with uid = 129.

Changing pseudo 60 in operand 0 of insn 830 on equiv [`*.LC69']
          alt=1,overall=609,losers=1,rld_nregs=1
          alt=2,overall=17,losers=2,rld_nregs=1
          alt=3,overall=0,losers=0,rld_nregs=0
         Choosing alt 3 in insn 830:  (0) R  (1) d {*movsi_esa}


(insn 829 828 126 11 (set (reg/f:SI 7 %r7 [orig:60 D.1911 ] [60])
        (reg/v/f:SI 2 %r2 [orig:126 buf3 ] [126]))
/build/gcc-head/gcc/testsuite/gcc.c-torture/execute/
builtins/memcpy-chk.c:131 68 {*movsi_esa}
     (nil))
(insn 126 829 830 11 (parallel [
            (set (reg/f:SI 7 %r7 [orig:60 D.1911 ] [60])
                (plus:SI (reg/f:SI 7 %r7 [orig:60 D.1911 ] [60])
                    (const_int 14 [0xe])))
            (clobber (reg:CC 33 %cc))
        ])
/build/gcc-head/gcc/testsuite/gcc.c-torture/execute/builtins/memcpy-chk.c:131
297 {*addsi3}
     (expr_list:REG_EQUIV (const:SI (plus:SI (symbol_ref:SI ("buf1") [flags
0x400]  <var_decl 0x7b97c9c
0 buf1>)
                (const_int 14 [0xe])))
        (nil)))
(insn 830 126 129 11 (set (mem/u/c:SI (symbol_ref/u:SI ("*.LC69") [flags 0x2])
[3 S4 A32])
        (reg/f:SI 7 %r7 [orig:60 D.1911 ] [60]))
/build/gcc-head/gcc/testsuite/gcc.c-torture/execute/builtins/memcpy-chk.c:131
68 {*movsi_esa}
     (expr_list:REG_DEAD (reg/f:SI 7 %r7 [orig:60 D.1911 ] [60])
        (nil)))



insn 830 writes to a literal pool slot. The testcase fails with a segfault due
to this.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug rtl-optimization/57963] LRA S/390: esa mode failure memcpy-chk
  2013-07-23 15:11 [Bug rtl-optimization/57963] New: LRA S/390: esa mode failure memcpy-chk krebbel at gcc dot gnu.org
@ 2013-08-01 20:43 ` vmakarov at gcc dot gnu.org
  2013-09-09 15:24 ` krebbel at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: vmakarov at gcc dot gnu.org @ 2013-08-01 20:43 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57963

--- Comment #1 from Vladimir Makarov <vmakarov at gcc dot gnu.org> ---
Thanks, Andreas.  I've reproduced the bug.  I hope to fix it on this week.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug rtl-optimization/57963] LRA S/390: esa mode failure memcpy-chk
  2013-07-23 15:11 [Bug rtl-optimization/57963] New: LRA S/390: esa mode failure memcpy-chk krebbel at gcc dot gnu.org
  2013-08-01 20:43 ` [Bug rtl-optimization/57963] " vmakarov at gcc dot gnu.org
@ 2013-09-09 15:24 ` krebbel at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: krebbel at gcc dot gnu.org @ 2013-09-09 15:24 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57963

Andreas Krebbel <krebbel at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED

--- Comment #2 from Andreas Krebbel <krebbel at gcc dot gnu.org> ---
Fixed with: http://gcc.gnu.org/ml/gcc-patches/2013-08/msg00091.html


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-09-09 15:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-23 15:11 [Bug rtl-optimization/57963] New: LRA S/390: esa mode failure memcpy-chk krebbel at gcc dot gnu.org
2013-08-01 20:43 ` [Bug rtl-optimization/57963] " vmakarov at gcc dot gnu.org
2013-09-09 15:24 ` krebbel at gcc dot gnu.org

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).