diff options
author | Evan Cheng <evan.cheng@apple.com> | 2006-10-11 07:01:37 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2006-10-11 07:01:37 +0000 |
commit | 27b1bb999b33d4b54308f51e6e03bcc0dda51a21 (patch) | |
tree | f476a24ca3707e554bfb9f156c91f146ae1fcf3c /test/CodeGen/X86/2006-10-10-FindModifiedNodeSlotBug.ll | |
parent | 3cd5ca6c72787fa4e5fd2b8d880545f8863f35d1 (diff) | |
download | external_llvm-27b1bb999b33d4b54308f51e6e03bcc0dda51a21.zip external_llvm-27b1bb999b33d4b54308f51e6e03bcc0dda51a21.tar.gz external_llvm-27b1bb999b33d4b54308f51e6e03bcc0dda51a21.tar.bz2 |
Test case for the recently fixed FindModifiedNodeSlot bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30877 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/X86/2006-10-10-FindModifiedNodeSlotBug.ll')
-rw-r--r-- | test/CodeGen/X86/2006-10-10-FindModifiedNodeSlotBug.ll | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/test/CodeGen/X86/2006-10-10-FindModifiedNodeSlotBug.ll b/test/CodeGen/X86/2006-10-10-FindModifiedNodeSlotBug.ll new file mode 100644 index 0000000..5cb233b --- /dev/null +++ b/test/CodeGen/X86/2006-10-10-FindModifiedNodeSlotBug.ll @@ -0,0 +1,31 @@ +; RUN: llvm-as < %s | llc -march=x86 | grep shrl +; Bug in FindModifiedNodeSlot cause tmp14 load to become a zextload and shr 31 +; is then optimized away. + +%tree_code_type = external global [0 x uint] + +void %copy_if_shared_r() { + %tmp = load uint* null + %tmp56 = and uint %tmp, 255 + %tmp8 = getelementptr [0 x uint]* %tree_code_type, int 0, uint %tmp56 + %tmp9 = load uint* %tmp8 + %tmp10 = add uint %tmp9, 4294967295 + %tmp = setgt uint %tmp10, 2 + %tmp14 = load uint* null + %tmp15 = shr uint %tmp14, ubyte 31 + %tmp15 = cast uint %tmp15 to ubyte + %tmp16 = setne ubyte %tmp15, 0 + br bool %tmp, label %cond_false25, label %cond_true + +cond_true: + br bool %tmp16, label %cond_true17, label %cond_false + +cond_true17: + ret void + +cond_false: + ret void + +cond_false25: + ret void +} |