summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/X86/overflow.ll
diff options
context:
space:
mode:
authorAmaury Sechet <deadalnix@gmail.com>2017-05-19 18:20:44 +0000
committerAmaury Sechet <deadalnix@gmail.com>2017-05-19 18:20:44 +0000
commit77cfb4a85f09a8330e5901b37e36b5e3ca597f9d (patch)
treefe28eeba0f71730383a29a386ea6d5c122530f2c /llvm/test/CodeGen/X86/overflow.ll
parent090871f2061b5760e36133cae9687cc6526b927f (diff)
downloadbcm5719-llvm-77cfb4a85f09a8330e5901b37e36b5e3ca597f9d.tar.gz
bcm5719-llvm-77cfb4a85f09a8330e5901b37e36b5e3ca597f9d.zip
[DAGCombine] (addcarry 0, 0, X) -> (ext/trunc X)
Summary: While this makes some case better and some case worse - so it's unclear if it is a worthy combine just by itself - this is a useful canonicalisation. As per discussion in D32756 . Reviewers: jyknight, nemanjai, mkuper, spatel, RKSimon, zvi, bkramer Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D32916 llvm-svn: 303441
Diffstat (limited to 'llvm/test/CodeGen/X86/overflow.ll')
-rw-r--r--llvm/test/CodeGen/X86/overflow.ll8
1 files changed, 3 insertions, 5 deletions
diff --git a/llvm/test/CodeGen/X86/overflow.ll b/llvm/test/CodeGen/X86/overflow.ll
index ff25b5de493..00dadc4a80f 100644
--- a/llvm/test/CodeGen/X86/overflow.ll
+++ b/llvm/test/CodeGen/X86/overflow.ll
@@ -27,16 +27,14 @@ define i128 @mulhioverflow(i64 %a, i64 %b, i64 %c) nounwind {
; X32-NEXT: addl $32, %esp
; X32-NEXT: movl {{[0-9]+}}(%esp), %eax
; X32-NEXT: andl $1, %edi
-; X32-NEXT: xorl %ecx, %ecx
; X32-NEXT: addl {{[0-9]+}}(%esp), %edi
; X32-NEXT: adcl $0, %eax
-; X32-NEXT: adcl $0, %ecx
-; X32-NEXT: sbbl %edx, %edx
-; X32-NEXT: andl $1, %edx
+; X32-NEXT: setb %cl
+; X32-NEXT: movzbl %cl, %ecx
; X32-NEXT: movl %edi, (%esi)
; X32-NEXT: movl %eax, 4(%esi)
; X32-NEXT: movl %ecx, 8(%esi)
-; X32-NEXT: movl %edx, 12(%esi)
+; X32-NEXT: movl $0, 12(%esi)
; X32-NEXT: movl %esi, %eax
; X32-NEXT: leal -8(%ebp), %esp
; X32-NEXT: popl %esi
OpenPOWER on IntegriCloud