From 7d6d241c11690431d019df64ae07257e64b4f00c Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Fri, 10 Nov 2006 23:37:54 +0000 Subject: [PATCH] This testcase is miscompiled by instcombine, reduced from 176.gcc git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31652 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/Transforms/InstCombine/2006-11-10-ashr-miscompile.ll | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 test/Transforms/InstCombine/2006-11-10-ashr-miscompile.ll diff --git a/test/Transforms/InstCombine/2006-11-10-ashr-miscompile.ll b/test/Transforms/InstCombine/2006-11-10-ashr-miscompile.ll new file mode 100644 index 00000000000..85c1f915940 --- /dev/null +++ b/test/Transforms/InstCombine/2006-11-10-ashr-miscompile.ll @@ -0,0 +1,7 @@ +; RUN: llvm-as < %s | opt -instcombine | llvm-dis | grep lshr +; Verify this is not turned into -1. + +int %test(ubyte %amt) { + %B = lshr int -1, ubyte %amt + ret int %B +} -- 2.34.1