blob: d49672d8ce4f5b4a28004ffc5b95008f06c937df [file] [log] [blame]
Chris Lattner16289472005-10-10 21:21:36 +00001; RUN: llvm-as < %s | llc -march=ppc32 &&
2; RUN: llvm-as < %s | llc -march=ppc32 | not grep rlwin
3
4void %test(ubyte* %P) {
5 %W = load ubyte* %P
6 %X = shl ubyte %W, ubyte 1
7 %Y = add ubyte %X, 2
8 %Z = and ubyte %Y, 254 ; dead and
9 store ubyte %Z, ubyte* %P
10 ret void
11}
Chris Lattnercfdbb7c2006-02-27 00:20:23 +000012
13ushort %test2(ushort %crc) { ; No and's should be needed for the ushorts here.
14 %tmp.1 = shr ushort %crc, ubyte 1
15 %tmp.7 = xor ushort %tmp.1, 40961
16 ret ushort %tmp.7
17}
18