From a79ac14fa68297f9888bc70a10df5ed9b8864e38 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Fri, 27 Feb 2015 21:17:42 +0000 Subject: [opaque pointer type] Add textual IR support for explicit type parameter to load instruction Essentially the same as the GEP change in r230786. A similar migration script can be used to update test cases, though a few more test case improvements/changes were required this time around: (r229269-r229278) import fileinput import sys import re pat = re.compile(r"((?:=|:|^)\s*load (?:atomic )?(?:volatile )?(.*?))(| addrspace\(\d+\) *)\*($| *(?:%|@|null|undef|blockaddress|getelementptr|addrspacecast|bitcast|inttoptr|\[\[[a-zA-Z]|\{\{).*$)") for line in sys.stdin: sys.stdout.write(re.sub(pat, r"\1, \2\3*\4", line)) Reviewers: rafael, dexonsmith, grosser Differential Revision: http://reviews.llvm.org/D7649 llvm-svn: 230794 --- llvm/test/CodeGen/X86/avx-vbroadcast.ll | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'llvm/test/CodeGen/X86/avx-vbroadcast.ll') diff --git a/llvm/test/CodeGen/X86/avx-vbroadcast.ll b/llvm/test/CodeGen/X86/avx-vbroadcast.ll index 2ebe6fda37a..8b8c11b8587 100644 --- a/llvm/test/CodeGen/X86/avx-vbroadcast.ll +++ b/llvm/test/CodeGen/X86/avx-vbroadcast.ll @@ -3,7 +3,7 @@ ; CHECK: vbroadcastsd (% define <4 x i64> @A(i64* %ptr) nounwind uwtable readnone ssp { entry: - %q = load i64* %ptr, align 8 + %q = load i64, i64* %ptr, align 8 %vecinit.i = insertelement <4 x i64> undef, i64 %q, i32 0 %vecinit2.i = insertelement <4 x i64> %vecinit.i, i64 %q, i32 1 %vecinit4.i = insertelement <4 x i64> %vecinit2.i, i64 %q, i32 2 @@ -14,7 +14,7 @@ entry: ; CHECK: vbroadcastss (% define <8 x i32> @B(i32* %ptr) nounwind uwtable readnone ssp { entry: - %q = load i32* %ptr, align 4 + %q = load i32, i32* %ptr, align 4 %vecinit.i = insertelement <8 x i32> undef, i32 %q, i32 0 %vecinit2.i = insertelement <8 x i32> %vecinit.i, i32 %q, i32 1 %vecinit4.i = insertelement <8 x i32> %vecinit2.i, i32 %q, i32 2 @@ -25,7 +25,7 @@ entry: ; CHECK: vbroadcastsd (% define <4 x double> @C(double* %ptr) nounwind uwtable readnone ssp { entry: - %q = load double* %ptr, align 8 + %q = load double, double* %ptr, align 8 %vecinit.i = insertelement <4 x double> undef, double %q, i32 0 %vecinit2.i = insertelement <4 x double> %vecinit.i, double %q, i32 1 %vecinit4.i = insertelement <4 x double> %vecinit2.i, double %q, i32 2 @@ -36,7 +36,7 @@ entry: ; CHECK: vbroadcastss (% define <8 x float> @D(float* %ptr) nounwind uwtable readnone ssp { entry: - %q = load float* %ptr, align 4 + %q = load float, float* %ptr, align 4 %vecinit.i = insertelement <8 x float> undef, float %q, i32 0 %vecinit2.i = insertelement <8 x float> %vecinit.i, float %q, i32 1 %vecinit4.i = insertelement <8 x float> %vecinit2.i, float %q, i32 2 @@ -49,7 +49,7 @@ entry: ; CHECK: vbroadcastss (% define <4 x float> @e(float* %ptr) nounwind uwtable readnone ssp { entry: - %q = load float* %ptr, align 4 + %q = load float, float* %ptr, align 4 %vecinit.i = insertelement <4 x float> undef, float %q, i32 0 %vecinit2.i = insertelement <4 x float> %vecinit.i, float %q, i32 1 %vecinit4.i = insertelement <4 x float> %vecinit2.i, float %q, i32 2 @@ -73,7 +73,7 @@ define <4 x float> @_e2(float* %ptr) nounwind uwtable readnone ssp { ; CHECK: vbroadcastss (% define <4 x i32> @F(i32* %ptr) nounwind uwtable readnone ssp { entry: - %q = load i32* %ptr, align 4 + %q = load i32, i32* %ptr, align 4 %vecinit.i = insertelement <4 x i32> undef, i32 %q, i32 0 %vecinit2.i = insertelement <4 x i32> %vecinit.i, i32 %q, i32 1 %vecinit4.i = insertelement <4 x i32> %vecinit2.i, i32 %q, i32 2 @@ -88,7 +88,7 @@ entry: ; CHECK: ret define <2 x i64> @G(i64* %ptr) nounwind uwtable readnone ssp { entry: - %q = load i64* %ptr, align 8 + %q = load i64, i64* %ptr, align 8 %vecinit.i = insertelement <2 x i64> undef, i64 %q, i32 0 %vecinit2.i = insertelement <2 x i64> %vecinit.i, i64 %q, i32 1 ret <2 x i64> %vecinit2.i @@ -107,7 +107,7 @@ define <4 x i32> @H(<4 x i32> %a) { ; CHECK: ret define <2 x double> @I(double* %ptr) nounwind uwtable readnone ssp { entry: - %q = load double* %ptr, align 4 + %q = load double, double* %ptr, align 4 %vecinit.i = insertelement <2 x double> undef, double %q, i32 0 %vecinit2.i = insertelement <2 x double> %vecinit.i, double %q, i32 1 ret <2 x double> %vecinit2.i @@ -118,13 +118,13 @@ entry: ; CHECK: ret define <4 x float> @_RR(float* %ptr, i32* %k) nounwind uwtable readnone ssp { entry: - %q = load float* %ptr, align 4 + %q = load float, float* %ptr, align 4 %vecinit.i = insertelement <4 x float> undef, float %q, i32 0 %vecinit2.i = insertelement <4 x float> %vecinit.i, float %q, i32 1 %vecinit4.i = insertelement <4 x float> %vecinit2.i, float %q, i32 2 %vecinit6.i = insertelement <4 x float> %vecinit4.i, float %q, i32 3 ; force a chain - %j = load i32* %k, align 4 + %j = load i32, i32* %k, align 4 store i32 %j, i32* undef ret <4 x float> %vecinit6.i } @@ -135,7 +135,7 @@ entry: ; CHECK: ret define <4 x float> @_RR2(float* %ptr, i32* %k) nounwind uwtable readnone ssp { entry: - %q = load float* %ptr, align 4 + %q = load float, float* %ptr, align 4 %v = insertelement <4 x float> undef, float %q, i32 0 %t = shufflevector <4 x float> %v, <4 x float> undef, <4 x i32> zeroinitializer ret <4 x float> %t @@ -151,7 +151,7 @@ entry: ; CHECK: vbroadcastss (% ; CHECK-NEXT: ret define <8 x float> @splat_concat1(float* %p) { - %1 = load float* %p, align 4 + %1 = load float, float* %p, align 4 %2 = insertelement <4 x float> undef, float %1, i32 0 %3 = insertelement <4 x float> %2, float %1, i32 1 %4 = insertelement <4 x float> %3, float %1, i32 2 @@ -165,7 +165,7 @@ define <8 x float> @splat_concat1(float* %p) { ; CHECK: vbroadcastss (% ; CHECK-NEXT: ret define <8 x float> @splat_concat2(float* %p) { - %1 = load float* %p, align 4 + %1 = load float, float* %p, align 4 %2 = insertelement <4 x float> undef, float %1, i32 0 %3 = insertelement <4 x float> %2, float %1, i32 1 %4 = insertelement <4 x float> %3, float %1, i32 2 @@ -183,7 +183,7 @@ define <8 x float> @splat_concat2(float* %p) { ; CHECK: vbroadcastsd (% ; CHECK-NEXT: ret define <4 x double> @splat_concat3(double* %p) { - %1 = load double* %p, align 8 + %1 = load double, double* %p, align 8 %2 = insertelement <2 x double> undef, double %1, i32 0 %3 = insertelement <2 x double> %2, double %1, i32 1 %4 = shufflevector <2 x double> %3, <2 x double> undef, <4 x i32> @@ -195,7 +195,7 @@ define <4 x double> @splat_concat3(double* %p) { ; CHECK: vbroadcastsd (% ; CHECK-NEXT: ret define <4 x double> @splat_concat4(double* %p) { - %1 = load double* %p, align 8 + %1 = load double, double* %p, align 8 %2 = insertelement <2 x double> undef, double %1, i32 0 %3 = insertelement <2 x double> %2, double %1, i32 1 %4 = insertelement <2 x double> undef, double %1, i32 0 -- cgit v1.2.3