blob: 8a5d3b0fa2c2eea0928541ad329a1e5f136dfabd [file] [log] [blame]
Chris Lattner0cb34c42005-10-09 05:31:47 +00001; This was erroneously being turned into an rlwinm instruction.
2; The sign bit does matter in this case.
3
Dan Gohmanfce288f2009-09-09 00:09:15 +00004; RUN: llc < %s -march=ppc32 | grep srawi
Tanya Lattner6f729d62008-03-25 04:26:08 +00005
6define i32 @test(i32 %X) {
7 %Y = and i32 %X, -2 ; <i32> [#uses=1]
8 %Z = ashr i32 %Y, 11 ; <i32> [#uses=1]
9 ret i32 %Z
Chris Lattner0cb34c42005-10-09 05:31:47 +000010}
Tanya Lattner6f729d62008-03-25 04:26:08 +000011