1; RUN: opt -instcombine -S < %s | FileCheck %s
2; PR12541
3
4define i32 @foo(i32 %x) {
5  %y = xor i32 %x, 3
6  %z = srem i32 1656690544, %y
7  %sext = shl i32 %z, 24
8  %s = ashr exact i32 %sext, 24
9  ret i32 %s
10; CHECK-NOT: and
11; The shifts were wrongly being turned into an and with 112
12}
13