[llvm-bugs] [Bug 49927] New: DSE fails to eliminate store of same value

via llvm-bugs llvm-bugs at lists.llvm.org
Sun Apr 11 16:21:53 PDT 2021


https://bugs.llvm.org/show_bug.cgi?id=49927

            Bug ID: 49927
           Summary: DSE fails to eliminate store of same value
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Scalar Optimizations
          Assignee: unassignedbugs at nondot.org
          Reporter: david.bolvansky at gmail.com
                CC: llvm-bugs at lists.llvm.org

void dse_missed (int *q, int *p)
{
  int y = *p;
  *q = y;
  *p = y;
}


gcc
dse_missed(int*, int*):
        mov     eax, DWORD PTR [rsi]
        mov     DWORD PTR [rdi], eax
        ret

dse_missed(int*, int*):                     # @dse_missed(int*, int*)
        mov     eax, dword ptr [rsi]
        mov     dword ptr [rdi], eax
        mov     dword ptr [rsi], eax
        ret


https://godbolt.org/z/8Pb9ne4vh

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210411/b5f09106/attachment.html>


More information about the llvm-bugs mailing list