From c15acfb9b1f123be747a95c2ca323f6255faed2f Mon Sep 17 00:00:00 2001 From: Sanjay Patel Date: Mon, 30 Jan 2017 16:38:49 +0000 Subject: [PATCH] [InstCombine] add 'exact' to lshr to show that it got dropped; NFC git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@293496 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/Transforms/InstCombine/shift.ll | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/Transforms/InstCombine/shift.ll b/test/Transforms/InstCombine/shift.ll index 5ee4f49fe0a..ac9b7e1c37f 100644 --- a/test/Transforms/InstCombine/shift.ll +++ b/test/Transforms/InstCombine/shift.ll @@ -933,6 +933,7 @@ define <2 x i32> @test51_splat_vec(<2 x i32> %x) { } ; (X << C1) >>u C2 --> X >>u (C2-C1) & (-1 >> C2) +; Also, check that exact is propagated. define i32 @test51_no_nuw(i32 %x) { ; CHECK-LABEL: @test51_no_nuw( @@ -941,7 +942,7 @@ define i32 @test51_no_nuw(i32 %x) { ; CHECK-NEXT: ret i32 [[B]] ; %A = shl i32 %x, 1 - %B = lshr i32 %A, 3 + %B = lshr exact i32 %A, 3 ret i32 %B } -- 2.40.0