aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-11-04 23:36:50 +0000
committerChris Lattner <sabre@nondot.org>2003-11-04 23:36:50 +0000
commit736cca670f9149cc381a519abc2f22e9a720de76 (patch)
treef13e58b76c17b544125c438499daa4e100d190b5
parentf61641f7d4bf69e3df7c455d6afcd9c47b4c2cbb (diff)
Add a generalization of the previous case
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9707 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--test/Transforms/InstCombine/xor.ll6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Transforms/InstCombine/xor.ll b/test/Transforms/InstCombine/xor.ll
index 0e6550c233..0cbd1320d3 100644
--- a/test/Transforms/InstCombine/xor.ll
+++ b/test/Transforms/InstCombine/xor.ll
@@ -104,3 +104,9 @@ uint %test15(uint %A) { ; ~(X-1) == -X
%C = xor uint %B, 4294967295
ret uint %C
}
+
+uint %test16(uint %A) { ; ~(X+c) == (-c-1)-X
+ %B = add uint %A, 123 ; A generalization of the previous case
+ %C = xor uint %B, 4294967295
+ ret uint %C
+}