[Libclc-dev] [PATCH 8/9] Add optimized generic addrspace(3) vstore implementation

Aaron Watry awatry at gmail.com
Tue Jul 22 18:46:49 PDT 2014


Not used until next commit.

Signed-off-by: Aaron Watry <awatry at gmail.com>
---
 generic/lib/shared/vstore_impl.ll | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/generic/lib/shared/vstore_impl.ll b/generic/lib/shared/vstore_impl.ll
index 9e2a37b..ed6bed4 100644
--- a/generic/lib/shared/vstore_impl.ll
+++ b/generic/lib/shared/vstore_impl.ll
@@ -31,6 +31,36 @@ define void @__clc_vstore16_i32__addr1(<16 x i32> %vec, i32 addrspace(1)* nocapt
   ret void
 }
 
+define void @__clc_vstore2_i32__addr3(<2 x i32> %vec, i32 addrspace(3)* nocapture %addr) nounwind alwaysinline {
+  %1 = bitcast i32 addrspace(3)* %addr to <2 x i32> addrspace(3)*
+  store <2 x i32> %vec, <2 x i32> addrspace(3)* %1, align 4, !tbaa !3
+  ret void
+}
+
+define void @__clc_vstore3_i32__addr3(<3 x i32> %vec, i32 addrspace(3)* nocapture %addr) nounwind alwaysinline {
+  %1 = bitcast i32 addrspace(3)* %addr to <3 x i32> addrspace(3)*
+  store <3 x i32> %vec, <3 x i32> addrspace(3)* %1, align 4, !tbaa !3
+  ret void
+}
+
+define void @__clc_vstore4_i32__addr3(<4 x i32> %vec, i32 addrspace(3)* nocapture %addr) nounwind alwaysinline {
+  %1 = bitcast i32 addrspace(3)* %addr to <4 x i32> addrspace(3)*
+  store <4 x i32> %vec, <4 x i32> addrspace(3)* %1, align 4, !tbaa !3
+  ret void
+}
+
+define void @__clc_vstore8_i32__addr3(<8 x i32> %vec, i32 addrspace(3)* nocapture %addr) nounwind alwaysinline {
+  %1 = bitcast i32 addrspace(3)* %addr to <8 x i32> addrspace(3)*
+  store <8 x i32> %vec, <8 x i32> addrspace(3)* %1, align 4, !tbaa !3
+  ret void
+}
+
+define void @__clc_vstore16_i32__addr3(<16 x i32> %vec, i32 addrspace(3)* nocapture %addr) nounwind alwaysinline {
+  %1 = bitcast i32 addrspace(3)* %addr to <16 x i32> addrspace(3)*
+  store <16 x i32> %vec, <16 x i32> addrspace(3)* %1, align 4, !tbaa !3
+  ret void
+}
+
 !1 = metadata !{metadata !"char", metadata !5}
 !2 = metadata !{metadata !"short", metadata !5}
 !3 = metadata !{metadata !"int", metadata !5}
-- 
1.9.1





More information about the Libclc-dev mailing list