diff options
Diffstat (limited to 'test/Transforms/ConstantHoisting')
6 files changed, 37 insertions, 37 deletions
diff --git a/test/Transforms/ConstantHoisting/AArch64/const-addr.ll b/test/Transforms/ConstantHoisting/AArch64/const-addr.ll index 89d5960..4c36d20 100644 --- a/test/Transforms/ConstantHoisting/AArch64/const-addr.ll +++ b/test/Transforms/ConstantHoisting/AArch64/const-addr.ll @@ -6,17 +6,17 @@ define i32 @test1() nounwind { ; CHECK-LABEL: test1 ; CHECK: %const = bitcast i64 68141056 to i64 ; CHECK: %1 = inttoptr i64 %const to %T* -; CHECK: %o1 = getelementptr %T* %1, i32 0, i32 1 -; CHECK: %o2 = getelementptr %T* %1, i32 0, i32 2 -; CHECK: %o3 = getelementptr %T* %1, i32 0, i32 3 +; CHECK: %o1 = getelementptr %T, %T* %1, i32 0, i32 1 +; CHECK: %o2 = getelementptr %T, %T* %1, i32 0, i32 2 +; CHECK: %o3 = getelementptr %T, %T* %1, i32 0, i32 3 %at = inttoptr i64 68141056 to %T* - %o1 = getelementptr %T* %at, i32 0, i32 1 - %t1 = load i32* %o1 - %o2 = getelementptr %T* %at, i32 0, i32 2 - %t2 = load i32* %o2 + %o1 = getelementptr %T, %T* %at, i32 0, i32 1 + %t1 = load i32, i32* %o1 + %o2 = getelementptr %T, %T* %at, i32 0, i32 2 + %t2 = load i32, i32* %o2 %a1 = add i32 %t1, %t2 - %o3 = getelementptr %T* %at, i32 0, i32 3 - %t3 = load i32* %o3 + %o3 = getelementptr %T, %T* %at, i32 0, i32 3 + %t3 = load i32, i32* %o3 %a2 = add i32 %a1, %t3 ret i32 %a2 } diff --git a/test/Transforms/ConstantHoisting/PowerPC/const-base-addr.ll b/test/Transforms/ConstantHoisting/PowerPC/const-base-addr.ll index b4337ee..69b13cf 100644 --- a/test/Transforms/ConstantHoisting/PowerPC/const-base-addr.ll +++ b/test/Transforms/ConstantHoisting/PowerPC/const-base-addr.ll @@ -9,13 +9,13 @@ define i32 @test1() nounwind { ; CHECK-LABEL: @test1 ; CHECK: %const = bitcast i32 12345678 to i32 ; CHECK: %1 = inttoptr i32 %const to %T* -; CHECK: %addr1 = getelementptr %T* %1, i32 0, i32 1 - %addr1 = getelementptr %T* inttoptr (i32 12345678 to %T*), i32 0, i32 1 - %tmp1 = load i32* %addr1 - %addr2 = getelementptr %T* inttoptr (i32 12345678 to %T*), i32 0, i32 2 - %tmp2 = load i32* %addr2 - %addr3 = getelementptr %T* inttoptr (i32 12345678 to %T*), i32 0, i32 3 - %tmp3 = load i32* %addr3 +; CHECK: %addr1 = getelementptr %T, %T* %1, i32 0, i32 1 + %addr1 = getelementptr %T, %T* inttoptr (i32 12345678 to %T*), i32 0, i32 1 + %tmp1 = load i32, i32* %addr1 + %addr2 = getelementptr %T, %T* inttoptr (i32 12345678 to %T*), i32 0, i32 2 + %tmp2 = load i32, i32* %addr2 + %addr3 = getelementptr %T, %T* inttoptr (i32 12345678 to %T*), i32 0, i32 3 + %tmp3 = load i32, i32* %addr3 %tmp4 = add i32 %tmp1, %tmp2 %tmp5 = add i32 %tmp3, %tmp4 ret i32 %tmp5 diff --git a/test/Transforms/ConstantHoisting/PowerPC/masks.ll b/test/Transforms/ConstantHoisting/PowerPC/masks.ll index d553182..4cc504f 100644 --- a/test/Transforms/ConstantHoisting/PowerPC/masks.ll +++ b/test/Transforms/ConstantHoisting/PowerPC/masks.ll @@ -19,7 +19,7 @@ if.then152: if.end167: ; CHECK: and i32 {{.*}}, 32768 %shl161 = shl nuw nsw i32 %conv121, 15 - %0 = load i8* undef, align 1 + %0 = load i8, i8* undef, align 1 %conv169 = zext i8 %0 to i32 %shl170 = shl nuw nsw i32 %conv169, 7 %shl161.masked = and i32 %shl161, 32768 @@ -49,7 +49,7 @@ if.then152: if.end167: ; CHECK: add i32 {{.*}}, -32758 %shl161 = shl nuw nsw i32 %conv121, 15 - %0 = load i8* undef, align 1 + %0 = load i8, i8* undef, align 1 %conv169 = zext i8 %0 to i32 %shl170 = shl nuw nsw i32 %conv169, 7 %shl161.masked = and i32 %shl161, 32773 diff --git a/test/Transforms/ConstantHoisting/X86/cast-inst.ll b/test/Transforms/ConstantHoisting/X86/cast-inst.ll index f490f4a..bd1e196 100644 --- a/test/Transforms/ConstantHoisting/X86/cast-inst.ll +++ b/test/Transforms/ConstantHoisting/X86/cast-inst.ll @@ -9,19 +9,19 @@ define i32 @cast_inst_test() { ; CHECK-LABEL: @cast_inst_test ; CHECK: %const = bitcast i64 4646526064 to i64 ; CHECK: %1 = inttoptr i64 %const to i32* -; CHECK: %v0 = load i32* %1, align 16 +; CHECK: %v0 = load i32, i32* %1, align 16 ; CHECK: %const_mat = add i64 %const, 16 ; CHECK-NEXT: %2 = inttoptr i64 %const_mat to i32* -; CHECK-NEXT: %v1 = load i32* %2, align 16 +; CHECK-NEXT: %v1 = load i32, i32* %2, align 16 ; CHECK: %const_mat1 = add i64 %const, 32 ; CHECK-NEXT: %3 = inttoptr i64 %const_mat1 to i32* -; CHECK-NEXT: %v2 = load i32* %3, align 16 +; CHECK-NEXT: %v2 = load i32, i32* %3, align 16 %a0 = inttoptr i64 4646526064 to i32* - %v0 = load i32* %a0, align 16 + %v0 = load i32, i32* %a0, align 16 %a1 = inttoptr i64 4646526080 to i32* - %v1 = load i32* %a1, align 16 + %v1 = load i32, i32* %a1, align 16 %a2 = inttoptr i64 4646526096 to i32* - %v2 = load i32* %a2, align 16 + %v2 = load i32, i32* %a2, align 16 %r0 = add i32 %v0, %v1 %r1 = add i32 %r0, %v2 ret i32 %r1 diff --git a/test/Transforms/ConstantHoisting/X86/const-base-addr.ll b/test/Transforms/ConstantHoisting/X86/const-base-addr.ll index 01e6cdf..db5dfdd 100644 --- a/test/Transforms/ConstantHoisting/X86/const-base-addr.ll +++ b/test/Transforms/ConstantHoisting/X86/const-base-addr.ll @@ -10,13 +10,13 @@ define i32 @test1() nounwind { ; CHECK-LABEL: @test1 ; CHECK: %const = bitcast i32 12345678 to i32 ; CHECK: %1 = inttoptr i32 %const to %T* -; CHECK: %addr1 = getelementptr %T* %1, i32 0, i32 1 - %addr1 = getelementptr %T* inttoptr (i32 12345678 to %T*), i32 0, i32 1 - %tmp1 = load i32* %addr1 - %addr2 = getelementptr %T* inttoptr (i32 12345678 to %T*), i32 0, i32 2 - %tmp2 = load i32* %addr2 - %addr3 = getelementptr %T* inttoptr (i32 12345678 to %T*), i32 0, i32 3 - %tmp3 = load i32* %addr3 +; CHECK: %addr1 = getelementptr %T, %T* %1, i32 0, i32 1 + %addr1 = getelementptr %T, %T* inttoptr (i32 12345678 to %T*), i32 0, i32 1 + %tmp1 = load i32, i32* %addr1 + %addr2 = getelementptr %T, %T* inttoptr (i32 12345678 to %T*), i32 0, i32 2 + %tmp2 = load i32, i32* %addr2 + %addr3 = getelementptr %T, %T* inttoptr (i32 12345678 to %T*), i32 0, i32 3 + %tmp3 = load i32, i32* %addr3 %tmp4 = add i32 %tmp1, %tmp2 %tmp5 = add i32 %tmp3, %tmp4 ret i32 %tmp5 diff --git a/test/Transforms/ConstantHoisting/X86/delete-dead-cast-inst.ll b/test/Transforms/ConstantHoisting/X86/delete-dead-cast-inst.ll index d352386..5df4c1a 100644 --- a/test/Transforms/ConstantHoisting/X86/delete-dead-cast-inst.ll +++ b/test/Transforms/ConstantHoisting/X86/delete-dead-cast-inst.ll @@ -10,13 +10,13 @@ define i32 @test1() nounwind { ; CHECK: %const = bitcast i32 12345678 to i32 ; CHECK-NOT: %base = inttoptr i32 12345678 to %T* ; CHECK-NEXT: %1 = inttoptr i32 %const to %T* -; CHECK-NEXT: %addr1 = getelementptr %T* %1, i32 0, i32 1 -; CHECK-NEXT: %addr2 = getelementptr %T* %1, i32 0, i32 2 -; CHECK-NEXT: %addr3 = getelementptr %T* %1, i32 0, i32 3 +; CHECK-NEXT: %addr1 = getelementptr %T, %T* %1, i32 0, i32 1 +; CHECK-NEXT: %addr2 = getelementptr %T, %T* %1, i32 0, i32 2 +; CHECK-NEXT: %addr3 = getelementptr %T, %T* %1, i32 0, i32 3 %base = inttoptr i32 12345678 to %T* - %addr1 = getelementptr %T* %base, i32 0, i32 1 - %addr2 = getelementptr %T* %base, i32 0, i32 2 - %addr3 = getelementptr %T* %base, i32 0, i32 3 + %addr1 = getelementptr %T, %T* %base, i32 0, i32 1 + %addr2 = getelementptr %T, %T* %base, i32 0, i32 2 + %addr3 = getelementptr %T, %T* %base, i32 0, i32 3 ret i32 12345678 } |