1 ; RUN: opt -mtriple=arm64-darwin-unknown -S -passes=consthoist < %s | FileCheck %s
3 define i128 @test1(i128 %a) nounwind {
5 ; CHECK: %const = bitcast i128 12297829382473034410122878 to i128
6 %1 = add i128 %a, 12297829382473034410122878
7 %2 = add i128 %1, 12297829382473034410122878
11 ; Check that we don't hoist large, but cheap constants
12 define i512 @test2(i512 %a) nounwind {
14 ; CHECK-NOT: %const = bitcast i512 7 to i512
20 ; Check that we don't hoist the shift value of a shift instruction.
21 define i512 @test3(i512 %a) nounwind {
23 ; CHECK-NOT: %const = bitcast i512 504 to i512
25 %2 = ashr i512 %1, 504