[llvm-commits] CVS: llvm/test/Regression/CodeGen/PowerPC/rlwinm.ll
Nate Begeman
natebegeman at mac.com
Wed Aug 3 11:27:28 PDT 2005
Changes in directory llvm/test/Regression/CodeGen/PowerPC:
rlwinm.ll added (r1.1)
---
Log message:
Add a couple rlwinm tests for bitfield clears
---
Diffs of the changes: (+17 -0)
rlwinm.ll | 17 +++++++++++++++++
1 files changed, 17 insertions(+)
Index: llvm/test/Regression/CodeGen/PowerPC/rlwinm.ll
diff -c /dev/null llvm/test/Regression/CodeGen/PowerPC/rlwinm.ll:1.1
*** /dev/null Wed Aug 3 13:27:27 2005
--- llvm/test/Regression/CodeGen/PowerPC/rlwinm.ll Wed Aug 3 13:27:17 2005
***************
*** 0 ****
--- 1,17 ----
+ ; All of these ands and shifts should be folded into rlwimi's
+ ; RUN: llvm-as < rlwinm.ll | llc -march=ppc32 | not grep and &&
+ ; RUN: llvm-as < rlwinm.ll | llc -march=ppc32 | grep rlwinm | wc -l | grep 2
+
+ implementation ; Functions:
+
+ int %test1(int %a) {
+ entry:
+ %tmp.1 = and int %a, 268431360 ; <int> [#uses=1]
+ ret int %tmp.1
+ }
+
+ int %test2(int %a) {
+ entry:
+ %tmp.1 = and int %a, -268435441 ; <int> [#uses=1]
+ ret int %tmp.1
+ }
More information about the llvm-commits
mailing list