diff options
author | Chris Lattner <sabre@nondot.org> | 2004-12-11 23:14:40 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-12-11 23:14:40 +0000 |
commit | e0e50dbb9fe975b4f4b3d2eb061b2ac74a5cc7c0 (patch) | |
tree | ad9c51b703186ea11f34c66cafbf25687d2d133f /test/Transforms/SCCP/logical-nuke.ll | |
parent | 74be3a579403d27df14571a8c7ba7fe7ad28745a (diff) | |
download | external_llvm-e0e50dbb9fe975b4f4b3d2eb061b2ac74a5cc7c0.zip external_llvm-e0e50dbb9fe975b4f4b3d2eb061b2ac74a5cc7c0.tar.gz external_llvm-e0e50dbb9fe975b4f4b3d2eb061b2ac74a5cc7c0.tar.bz2 |
New testcase. If one side of and/or is known to be 0/-1, it doesn't matter
if the other side is overdefined.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18806 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/SCCP/logical-nuke.ll')
-rw-r--r-- | test/Transforms/SCCP/logical-nuke.ll | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Transforms/SCCP/logical-nuke.ll b/test/Transforms/SCCP/logical-nuke.ll new file mode 100644 index 0000000..5b4f842 --- /dev/null +++ b/test/Transforms/SCCP/logical-nuke.ll @@ -0,0 +1,8 @@ +; RUN: llvm-as < %s | opt -sccp | llvm-dis | grep 'ret int 0' + +; Test that SCCP has basic knowledge of when and/or nuke overdefined values. + +int %test(int %X) { + %Y = and int %X, 0 + ret int %Y +} |