diff options
author | Evan Cheng <evan.cheng@apple.com> | 2006-07-07 21:36:24 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2006-07-07 21:36:24 +0000 |
commit | a962bfa001de1d8ded248b49d37ff795c582a0e9 (patch) | |
tree | 6826f9dd152fcdd6cfd2fc51a651c4b885488aec /test/CodeGen/PowerPC/2006-07-07-ComputeMaskedBits.ll | |
parent | b14c342bd5233348237cf1239c795045ee7612bc (diff) | |
download | llvm-a962bfa001de1d8ded248b49d37ff795c582a0e9.tar.gz llvm-a962bfa001de1d8ded248b49d37ff795c582a0e9.tar.bz2 llvm-a962bfa001de1d8ded248b49d37ff795c582a0e9.tar.xz |
Add a 64-bit test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29069 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/PowerPC/2006-07-07-ComputeMaskedBits.ll')
-rw-r--r-- | test/CodeGen/PowerPC/2006-07-07-ComputeMaskedBits.ll | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/CodeGen/PowerPC/2006-07-07-ComputeMaskedBits.ll b/test/CodeGen/PowerPC/2006-07-07-ComputeMaskedBits.ll new file mode 100644 index 0000000000..396da37d2f --- /dev/null +++ b/test/CodeGen/PowerPC/2006-07-07-ComputeMaskedBits.ll @@ -0,0 +1,16 @@ +; RUN: llvm-as < %s | llc -mtriple=powerpc64-apple-darwin | grep extsw | wc -l | grep 2 + +%lens = external global ubyte* +%vals = external global int* + +int %test(int %i) { + %tmp = load ubyte** %lens + %tmp1 = getelementptr ubyte* %tmp, int %i + %tmp = load ubyte* %tmp1 + %tmp2 = cast ubyte %tmp to int + %tmp3 = load int** %vals + %tmp5 = sub int 1, %tmp2 + %tmp6 = getelementptr int* %tmp3, int %tmp5 + %tmp7 = load int* %tmp6 + ret int %tmp7 +} |