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: [email protected]
          Reporter: [email protected]
                CC: [email protected]

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.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to