diff options
Diffstat (limited to 'llvm/test/Transforms')
| -rw-r--r-- | llvm/test/Transforms/ConstantHoisting/X86/large-immediate.ll | 9 | ||||
| -rw-r--r-- | llvm/test/Transforms/ConstantHoisting/X86/stackmap.ll | 6 |
2 files changed, 12 insertions, 3 deletions
diff --git a/llvm/test/Transforms/ConstantHoisting/X86/large-immediate.ll b/llvm/test/Transforms/ConstantHoisting/X86/large-immediate.ll index e0af9c9be57..b8c04f38b12 100644 --- a/llvm/test/Transforms/ConstantHoisting/X86/large-immediate.ll +++ b/llvm/test/Transforms/ConstantHoisting/X86/large-immediate.ll @@ -25,3 +25,12 @@ define i196 @test3(i196 %a) nounwind { %2 = mul i196 %1, 2 ret i196 %2 } + +; Check that we don't hoist immediates with small values. +define i96 @test4(i96 %a) nounwind { +; CHECK-LABEL: test4 +; CHECK-NOT: %const = bitcast i96 2 to i96 + %1 = mul i96 %a, 2 + %2 = add i96 %1, 2 + ret i96 %2 +} diff --git a/llvm/test/Transforms/ConstantHoisting/X86/stackmap.ll b/llvm/test/Transforms/ConstantHoisting/X86/stackmap.ll index cef022ebc0b..9df44177820 100644 --- a/llvm/test/Transforms/ConstantHoisting/X86/stackmap.ll +++ b/llvm/test/Transforms/ConstantHoisting/X86/stackmap.ll @@ -6,11 +6,11 @@ target triple = "x86_64-apple-macosx10.9.0" ; Test if the 3rd argument of a stackmap is hoisted. define i128 @test1(i128 %a) { ; CHECK-LABEL: @test1 -; CHECK: %const = bitcast i128 13464618275673403322 to i128 +; CHECK: %const = bitcast i128 134646182756734033220 to i128 ; CHECK: tail call void (i64, i32, ...)* @llvm.experimental.stackmap(i64 1, i32 24, i128 %const) entry: - %0 = add i128 %a, 13464618275673403322 - tail call void (i64, i32, ...)* @llvm.experimental.stackmap(i64 1, i32 24, i128 13464618275673403322) + %0 = add i128 %a, 134646182756734033220 + tail call void (i64, i32, ...)* @llvm.experimental.stackmap(i64 1, i32 24, i128 134646182756734033220) ret i128 %0 } |

