HIP: Heterogenous-computing Interface for Portability
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
hip_ldg.h
1 /*
2 Copyright (c) 2015-2016 Advanced Micro Devices, Inc. All rights reserved.
3 Permission is hereby granted, free of charge, to any person obtaining a copy
4 of this software and associated documentation files (the "Software"), to deal
5 in the Software without restriction, including without limitation the rights
6 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 copies of the Software, and to permit persons to whom the Software is
8 furnished to do so, subject to the following conditions:
9 The above copyright notice and this permission notice shall be included in
10 all copies or substantial portions of the Software.
11 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
13 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
14 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
15 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
17 THE SOFTWARE.
18 */
19 
20 #ifndef HIP_LDG_H
21 #define HIP_LDG_H
22 
23 #if __HCC__
24 #include"hip_vector_types.h"
25 #include"host_defines.h"
26 #if __hcc_workweek__ >= 16164
27 #include"hip/hip_vector_types.h"
28 #include"hip/hcc_detail/host_defines.h"
29 
30 
31 __device__ char __ldg(const char* );
32 __device__ char1 __ldg(const char1* );
33 __device__ char2 __ldg(const char2* );
34 __device__ char3 __ldg(const char3* );
35 __device__ char4 __ldg(const char4* );
36 __device__ signed char __ldg(const signed char* );
37 __device__ unsigned char __ldg(const unsigned char* );
38 
39 __device__ short __ldg(const short* );
40 __device__ short1 __ldg(const short1* );
41 __device__ short2 __ldg(const short2* );
42 __device__ short3 __ldg(const short3* );
43 __device__ short4 __ldg(const short4* );
44 __device__ unsigned short __ldg(const unsigned short* );
45 
46 __device__ int __ldg(const int* );
47 __device__ int1 __ldg(const int1* );
48 __device__ int2 __ldg(const int2* );
49 __device__ int3 __ldg(const int3* );
50 __device__ int4 __ldg(const int4* );
51 __device__ unsigned int __ldg(const unsigned int* );
52 
53 
54 __device__ long __ldg(const long* );
55 __device__ long1 __ldg(const long1* );
56 __device__ long2 __ldg(const long2* );
57 __device__ long3 __ldg(const long3* );
58 __device__ long4 __ldg(const long4* );
59 __device__ unsigned long __ldg(const unsigned long* );
60 
61 __device__ long long __ldg(const long long* );
62 __device__ longlong1 __ldg(const longlong1* );
63 __device__ longlong2 __ldg(const longlong2* );
64 __device__ longlong3 __ldg(const longlong3* );
65 __device__ longlong4 __ldg(const longlong4* );
66 __device__ unsigned long long __ldg(const unsigned long long* );
67 
68 __device__ uchar1 __ldg(const uchar1* );
69 __device__ uchar2 __ldg(const uchar2* );
70 __device__ uchar3 __ldg(const uchar3* );
71 __device__ uchar4 __ldg(const uchar4* );
72 
73 __device__ ushort1 __ldg(const ushort1* );
74 __device__ ushort2 __ldg(const ushort2* );
75 __device__ ushort3 __ldg(const ushort3* );
76 __device__ ushort4 __ldg(const ushort4* );
77 
78 __device__ uint1 __ldg(const uint1* );
79 __device__ uint2 __ldg(const uint2* );
80 __device__ uint3 __ldg(const uint3* );
81 __device__ uint4 __ldg(const uint4* );
82 
83 __device__ ulonglong1 __ldg(const ulonglong1* );
84 __device__ ulonglong2 __ldg(const ulonglong2* );
85 __device__ ulonglong3 __ldg(const ulonglong3* );
86 __device__ ulonglong4 __ldg(const ulonglong4* );
87 
88 __device__ float __ldg(const float* );
89 __device__ float1 __ldg(const float1* );
90 __device__ float2 __ldg(const float2* );
91 __device__ float3 __ldg(const float3* );
92 __device__ float4 __ldg(const float4* );
93 
94 __device__ double __ldg(const double* );
95 __device__ double1 __ldg(const double1* );
96 __device__ double2 __ldg(const double2* );
97 __device__ double3 __ldg(const double3* );
98 __device__ double4 __ldg(const double4* );
99 
100 #endif // __hcc_workweek__
101 
102 #endif // __HCC__
103 
104 #endif // HIP_LDG_H
105 
TODO-doc.
Defines the different newt vector types for HIP runtime.