public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/65784] New: after reload, the memrefs_conflict_p is unreliable?
@ 2015-04-16  6:00 wangjiefeng at huawei dot com
  2015-04-16  6:46 ` [Bug c/65784] " pinskia at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: wangjiefeng at huawei dot com @ 2015-04-16  6:00 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65784

            Bug ID: 65784
           Summary: after reload, the memrefs_conflict_p is unreliable?
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: wangjiefeng at huawei dot com

int f = -1;
int foo(int * pa)
{
  int a = 1;
  *(pa) = a;
  pa = pa + f;
  a = *(pa + 1);
  return a;
}

With -O2, the ARM's assembler is as follows:
foo:
        @ args = 0, pretend = 0, frame = 0
        @ frame_needed = 0, uses_anonymous_args = 0
        @ link register save eliminated.
        movw    r3, #:lower16:.LANCHOR0 @ 20    *arm_movsi_insn/4       [length
= 4]
        mov     r2, #1  @ 6     *arm_movsi_insn/2       [length = 4]
        movt    r3, #:upper16:.LANCHOR0 @ 21    *arm_movt       [length = 4]
        str     r2, [r0]        @ 7     *arm_movsi_insn/6       [length = 4]
        ldr     r3, [r3]        @ 9     *arm_movsi_insn/5       [length = 4]
        add     r0, r0, r3, asl #2      @ 11    *arith_shiftsi/1        [length
= 4]
        ldr     r0, [r0, #4]    @ 17    *arm_movsi_insn/5       [length = 4]
        bx      lr      @ 26    *arm_return     [length = 12]
        .size   foo, .-foo
        .global f
        .data
        .align  2

In sched1, insn 7 and insn 17 has true dependence, but in sched2, the true
dependence between insn 7 and insn 17 is omitted.
It seems after reload, in function true_dependence_1, the memrefs_conflict_p is
unreliable?


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

* [Bug c/65784] after reload, the memrefs_conflict_p is unreliable?
  2015-04-16  6:00 [Bug c/65784] New: after reload, the memrefs_conflict_p is unreliable? wangjiefeng at huawei dot com
@ 2015-04-16  6:46 ` pinskia at gcc dot gnu.org
  0 siblings, 0 replies; 2+ messages in thread
From: pinskia at gcc dot gnu.org @ 2015-04-16  6:46 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65784

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

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

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
.

*** This bug has been marked as a duplicate of bug 65783 ***


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

end of thread, other threads:[~2015-04-16  6:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-16  6:00 [Bug c/65784] New: after reload, the memrefs_conflict_p is unreliable? wangjiefeng at huawei dot com
2015-04-16  6:46 ` [Bug c/65784] " pinskia 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).