[PATCH] D55485: [X86] Fix avoid store forwarding blocks pass for negative displacements
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 10 02:20:12 PST 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rL348750: [X86] Fix AvoidStoreForwardingBlocks pass for negative displacements (authored by nikic, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D55485?vs=177410&id=177476#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55485/new/
https://reviews.llvm.org/D55485
Files:
llvm/trunk/lib/Target/X86/X86AvoidStoreForwardingBlocks.cpp
llvm/trunk/test/CodeGen/X86/pr39926.ll
Index: llvm/trunk/test/CodeGen/X86/pr39926.ll
===================================================================
--- llvm/trunk/test/CodeGen/X86/pr39926.ll
+++ llvm/trunk/test/CodeGen/X86/pr39926.ll
@@ -8,9 +8,9 @@
; CHECK-NEXT: movb $0, 7(%rdi)
; CHECK-NEXT: movw $0, 5(%rdi)
; CHECK-NEXT: movl $0, 1(%rdi)
-; CHECK-NEXT: movzwl -4(%rdi), %eax
-; CHECK-NEXT: movw %ax, -{{[0-9]+}}(%rsp)
-; CHECK-NEXT: movb -2(%rdi), %al
+; CHECK-NEXT: movl -4(%rdi), %eax
+; CHECK-NEXT: movl %eax, -{{[0-9]+}}(%rsp)
+; CHECK-NEXT: movb (%rdi), %al
; CHECK-NEXT: movb %al, -{{[0-9]+}}(%rsp)
; CHECK-NEXT: movl 1(%rdi), %eax
; CHECK-NEXT: movl %eax, -{{[0-9]+}}(%rsp)
Index: llvm/trunk/lib/Target/X86/X86AvoidStoreForwardingBlocks.cpp
===================================================================
--- llvm/trunk/lib/Target/X86/X86AvoidStoreForwardingBlocks.cpp
+++ llvm/trunk/lib/Target/X86/X86AvoidStoreForwardingBlocks.cpp
@@ -586,7 +586,7 @@
StDisp2 += OverlapDelta;
Size2 -= OverlapDelta;
}
- Size1 = std::abs(std::abs(LdDisp2) - std::abs(LdDisp1));
+ Size1 = LdDisp2 - LdDisp1;
// Build a copy for the point until the current blocking store's
// displacement.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D55485.177476.patch
Type: text/x-patch
Size: 1234 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181210/7384e71a/attachment.bin>
More information about the llvm-commits
mailing list