[llvm] r275690 - add vector test to show missing transform
Sanjay Patel via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 16 11:24:18 PDT 2016
Author: spatel
Date: Sat Jul 16 13:24:18 2016
New Revision: 275690
URL: http://llvm.org/viewvc/llvm-project?rev=275690&view=rev
Log:
add vector test to show missing transform
Modified:
llvm/trunk/test/Transforms/InstCombine/apint-add.ll
Modified: llvm/trunk/test/Transforms/InstCombine/apint-add.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/InstCombine/apint-add.ll?rev=275690&r1=275689&r2=275690&view=diff
==============================================================================
--- llvm/trunk/test/Transforms/InstCombine/apint-add.ll (original)
+++ llvm/trunk/test/Transforms/InstCombine/apint-add.ll Sat Jul 16 13:24:18 2016
@@ -33,6 +33,16 @@ define i15 @test3(i15 %x) {
ret i15 %tmp.4
}
+; X + signbit --> X ^ signbit
+define <2 x i5> @test3vec(<2 x i5> %x) {
+; CHECK-LABEL: @test3vec(
+; CHECK-NEXT: [[Y:%.*]] = add <2 x i5> %x, <i5 -16, i5 -16>
+; CHECK-NEXT: ret <2 x i5> [[Y]]
+;
+ %y = add <2 x i5> %x, <i5 16, i5 16>
+ ret <2 x i5> %y
+}
+
;; (x & 0b1111..0) + 1 -> x | 1
define i49 @test4(i49 %x) {
; CHECK-LABEL: @test4(
More information about the llvm-commits
mailing list