mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-11 23:05:31 +00:00
5ff30e70f8
known zero in the LHS. Fixes PR12541. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@155818 91177308-0d34-0410-b5e6-96231b3b80d8
13 lines
285 B
LLVM
13 lines
285 B
LLVM
; RUN: opt -instcombine -S < %s | FileCheck %s
|
|
; PR12541
|
|
|
|
define i32 @foo(i32 %x) {
|
|
%y = xor i32 %x, 3
|
|
%z = srem i32 1656690544, %y
|
|
%sext = shl i32 %z, 24
|
|
%s = ashr exact i32 %sext, 24
|
|
ret i32 %s
|
|
; CHECK-NOT: and
|
|
; The shifts were wrongly being turned into an and with 112
|
|
}
|