diff options
author | Bill Wendling <isanbard@gmail.com> | 2008-03-24 23:16:37 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2008-03-24 23:16:37 +0000 |
commit | a77e9f0453ee449a486019e9de21f8ebd1e74efe (patch) | |
tree | 170b010898def458df8645a03735dc44fb9f1db2 /test | |
parent | 7db979944d0020335a72a72a1d182b0f381c2ede (diff) | |
download | external_llvm-a77e9f0453ee449a486019e9de21f8ebd1e74efe.zip external_llvm-a77e9f0453ee449a486019e9de21f8ebd1e74efe.tar.gz external_llvm-a77e9f0453ee449a486019e9de21f8ebd1e74efe.tar.bz2 |
Use the bit size of the operand instead of the hard-coded 32 to generate the
mask.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48750 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/CodeGen/PowerPC/2008-03-24-AddressRegImm.ll | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/test/CodeGen/PowerPC/2008-03-24-AddressRegImm.ll b/test/CodeGen/PowerPC/2008-03-24-AddressRegImm.ll new file mode 100644 index 0000000..395c986 --- /dev/null +++ b/test/CodeGen/PowerPC/2008-03-24-AddressRegImm.ll @@ -0,0 +1,25 @@ +; RUN: llvm-as < %s | llc -march=ppc64 + +define fastcc i8* @page_rec_get_next(i8* %rec) nounwind { +entry: + %tmp2627 = ptrtoint i8* %rec to i64 ; <i64> [#uses=2] + %tmp28 = and i64 %tmp2627, -16384 ; <i64> [#uses=2] + %tmp2829 = inttoptr i64 %tmp28 to i8* ; <i8*> [#uses=1] + %tmp37 = getelementptr i8* %tmp2829, i64 42 ; <i8*> [#uses=1] + %tmp40 = load i8* %tmp37, align 1 ; <i8> [#uses=1] + %tmp4041 = zext i8 %tmp40 to i64 ; <i64> [#uses=1] + %tmp42 = shl i64 %tmp4041, 8 ; <i64> [#uses=1] + %tmp47 = add i64 %tmp42, 0 ; <i64> [#uses=1] + %tmp52 = and i64 %tmp47, 32768 ; <i64> [#uses=1] + %tmp72 = icmp eq i64 %tmp52, 0 ; <i1> [#uses=1] + br i1 %tmp72, label %bb91, label %bb +bb: ; preds = %entry + ret i8* null +bb91: ; preds = %entry + br i1 false, label %bb100, label %bb185 +bb100: ; preds = %bb91 + %tmp106 = sub i64 %tmp2627, %tmp28 ; <i64> [#uses=0] + ret i8* null +bb185: ; preds = %bb91 + ret i8* null +} |