@@ -20,7 +20,7 @@ struct dot_helper
20
20
{
21
21
using scalar_type = typename vector_traits<T>::scalar_type;
22
22
23
- static inline scalar_type dot_product (NBL_CONST_REF_ARG (T) lhs, NBL_CONST_REF_ARG (T) rhs)
23
+ static inline scalar_type __call (NBL_CONST_REF_ARG (T) lhs, NBL_CONST_REF_ARG (T) rhs)
24
24
{
25
25
static array_get<T, scalar_type> getter;
26
26
scalar_type retval = getter (lhs, 0 ) * getter (rhs, 0 );
@@ -40,7 +40,7 @@ struct dot_helper<vector<FLOAT_TYPE, N> >\
40
40
using VectorType = vector <FLOAT_TYPE, N>;\
41
41
using ScalarType = typename vector_traits<VectorType>::scalar_type;\
42
42
\
43
- static inline ScalarType dot_product (NBL_CONST_REF_ARG (VectorType) lhs, NBL_CONST_REF_ARG (VectorType) rhs)\
43
+ static inline ScalarType __call (NBL_CONST_REF_ARG (VectorType) lhs, NBL_CONST_REF_ARG (VectorType) rhs)\
44
44
{\
45
45
return RETURN_VALUE;\
46
46
}\
@@ -65,7 +65,7 @@ struct find_msb_helper;
65
65
template<>
66
66
struct find_msb_helper<uint32_t>
67
67
{
68
- static int32_t findMSB (NBL_CONST_REF_ARG (uint32_t) val)
68
+ static int32_t __call (NBL_CONST_REF_ARG (uint32_t) val)
69
69
{
70
70
#ifdef __HLSL_VERSION
71
71
return spirv::findUMsb (val);
@@ -78,7 +78,7 @@ struct find_msb_helper<uint32_t>
78
78
template<>
79
79
struct find_msb_helper<int32_t>
80
80
{
81
- static int32_t findMSB (NBL_CONST_REF_ARG (int32_t) val)
81
+ static int32_t __call (NBL_CONST_REF_ARG (int32_t) val)
82
82
{
83
83
#ifdef __HLSL_VERSION
84
84
return spirv::findSMsb (val);
@@ -92,9 +92,9 @@ struct find_msb_helper<int32_t>
92
92
template<>\
93
93
struct find_msb_helper<INPUT_INTEGER_TYPE>\
94
94
{\
95
- static int32_t findMSB (NBL_CONST_REF_ARG (INPUT_INTEGER_TYPE) val)\
95
+ static int32_t __call (NBL_CONST_REF_ARG (INPUT_INTEGER_TYPE) val)\
96
96
{\
97
- return find_msb_helper<INTEGER_TYPE>::findMSB (val);\
97
+ return find_msb_helper<INTEGER_TYPE>::__call (val);\
98
98
}\
99
99
};\
100
100
@@ -108,16 +108,16 @@ DEFINE_FIND_MSB_COMMON_SPECIALIZATION(uint8_t, uint32_t)
108
108
template<>
109
109
struct find_msb_helper<uint64_t>
110
110
{
111
- static int32_t findMSB (NBL_CONST_REF_ARG (uint64_t) val)
111
+ static int32_t __call (NBL_CONST_REF_ARG (uint64_t) val)
112
112
{
113
113
#ifdef __HLSL_VERSION
114
114
const uint32_t highBits = uint32_t (val >> 32 );
115
- const int32_t highMsb = find_msb_helper<uint32_t>::findMSB (highBits);
115
+ const int32_t highMsb = find_msb_helper<uint32_t>::__call (highBits);
116
116
117
117
if (highMsb == -1 )
118
118
{
119
119
const uint32_t lowBits = uint32_t (val);
120
- const int32_t lowMsb = find_msb_helper<uint32_t>::findMSB (lowBits);
120
+ const int32_t lowMsb = find_msb_helper<uint32_t>::__call (lowBits);
121
121
if (lowMsb == -1 )
122
122
return -1 ;
123
123
@@ -134,7 +134,7 @@ struct find_msb_helper<uint64_t>
134
134
template<int N>
135
135
struct find_msb_helper<vector <uint32_t, N> >
136
136
{
137
- static vector <int32_t, N> findMSB (NBL_CONST_REF_ARG (vector <uint32_t, N>) val)
137
+ static vector <int32_t, N> __call (NBL_CONST_REF_ARG (vector <uint32_t, N>) val)
138
138
{
139
139
#ifdef __HLSL_VERSION
140
140
return spirv::findUMsb (val);
@@ -147,7 +147,7 @@ struct find_msb_helper<vector<uint32_t, N> >
147
147
template<int N>
148
148
struct find_msb_helper<vector <int32_t, N> >
149
149
{
150
- static vector <int32_t, N> findMSB (NBL_CONST_REF_ARG (vector <int32_t, N>) val)
150
+ static vector <int32_t, N> __call (NBL_CONST_REF_ARG (vector <int32_t, N>) val)
151
151
{
152
152
#ifdef __HLSL_VERSION
153
153
return spirv::findSMsb (val);
@@ -163,10 +163,10 @@ template<typename EnumType>
163
163
requires std::is_enum_v<EnumType>
164
164
struct find_msb_helper<EnumType>
165
165
{
166
- static int32_t findMSB (NBL_CONST_REF_ARG (EnumType) val)
166
+ static int32_t __call (NBL_CONST_REF_ARG (EnumType) val)
167
167
{
168
168
using underlying_t = std::underlying_type_t<EnumType>;
169
- return find_msb_helper<underlying_t>::findMSB (static_cast<underlying_t>(val));
169
+ return find_msb_helper<underlying_t>::__call (static_cast<underlying_t>(val));
170
170
}
171
171
};
172
172
@@ -178,7 +178,7 @@ struct find_lsb_helper;
178
178
template<>
179
179
struct find_lsb_helper<int32_t>
180
180
{
181
- static int32_t findLSB (NBL_CONST_REF_ARG (int32_t) val)
181
+ static int32_t __call (NBL_CONST_REF_ARG (int32_t) val)
182
182
{
183
183
#ifdef __HLSL_VERSION
184
184
return spirv::findILsb (val);
@@ -191,7 +191,7 @@ struct find_lsb_helper<int32_t>
191
191
template<>
192
192
struct find_lsb_helper<uint32_t>
193
193
{
194
- static int32_t findLSB (NBL_CONST_REF_ARG (uint32_t) val)
194
+ static int32_t __call (NBL_CONST_REF_ARG (uint32_t) val)
195
195
{
196
196
#ifdef __HLSL_VERSION
197
197
return spirv::findILsb (val);
@@ -205,9 +205,9 @@ struct find_lsb_helper<uint32_t>
205
205
template<>\
206
206
struct find_lsb_helper<INPUT_INTEGER_TYPE>\
207
207
{\
208
- static int32_t findLSB (NBL_CONST_REF_ARG (INPUT_INTEGER_TYPE) val)\
208
+ static int32_t __call (NBL_CONST_REF_ARG (INPUT_INTEGER_TYPE) val)\
209
209
{\
210
- return find_lsb_helper<INTEGER_TYPE>::findLSB (val);\
210
+ return find_lsb_helper<INTEGER_TYPE>::__call (val);\
211
211
}\
212
212
};\
213
213
@@ -221,16 +221,16 @@ DEFINE_FIND_LSB_COMMON_SPECIALIZATION(uint8_t, uint32_t)
221
221
template<>
222
222
struct find_lsb_helper<uint64_t>
223
223
{
224
- static int32_t findLSB (NBL_CONST_REF_ARG (uint64_t) val)
224
+ static int32_t __call (NBL_CONST_REF_ARG (uint64_t) val)
225
225
{
226
226
#ifdef __HLSL_VERSION
227
227
const uint32_t lowBits = uint32_t (val);
228
- const int32_t lowLsb = find_lsb_helper<uint32_t>::findLSB (lowBits);
228
+ const int32_t lowLsb = find_lsb_helper<uint32_t>::__call (lowBits);
229
229
230
230
if (lowLsb == -1 )
231
231
{
232
232
const uint32_t highBits = uint32_t (val >> 32 );
233
- const int32_t highLsb = find_lsb_helper<uint32_t>::findLSB (highBits);
233
+ const int32_t highLsb = find_lsb_helper<uint32_t>::__call (highBits);
234
234
if (highLsb == -1 )
235
235
return -1 ;
236
236
else
@@ -247,7 +247,7 @@ struct find_lsb_helper<uint64_t>
247
247
template<int N>
248
248
struct find_lsb_helper<vector <int32_t, N> >
249
249
{
250
- static vector <int32_t, N> findLSB (NBL_CONST_REF_ARG (vector <int32_t, N>) val)
250
+ static vector <int32_t, N> __call (NBL_CONST_REF_ARG (vector <int32_t, N>) val)
251
251
{
252
252
#ifdef __HLSL_VERSION
253
253
return spirv::findILsb (val);
@@ -260,7 +260,7 @@ struct find_lsb_helper<vector<int32_t, N> >
260
260
template<int N>
261
261
struct find_lsb_helper<vector <uint32_t, N> >
262
262
{
263
- static vector <int32_t, N> findLSB (NBL_CONST_REF_ARG (vector <uint32_t, N>) val)
263
+ static vector <int32_t, N> __call (NBL_CONST_REF_ARG (vector <uint32_t, N>) val)
264
264
{
265
265
#ifdef __HLSL_VERSION
266
266
return spirv::findILsb (val);
@@ -276,10 +276,10 @@ template<typename EnumType>
276
276
requires std::is_enum_v<EnumType>
277
277
struct find_lsb_helper<EnumType>
278
278
{
279
- static int32_t findLSB (NBL_CONST_REF_ARG (EnumType) val)
279
+ static int32_t __call (NBL_CONST_REF_ARG (EnumType) val)
280
280
{
281
281
using underlying_t = std::underlying_type_t<EnumType>;
282
- return find_lsb_helper<underlying_t>::findLSB (static_cast<underlying_t>(val));
282
+ return find_lsb_helper<underlying_t>::__call (static_cast<underlying_t>(val));
283
283
}
284
284
};
285
285
@@ -306,7 +306,7 @@ struct transpose_helper<matrix<T, N, M> >
306
306
{
307
307
using transposed_t = typename matrix_traits<matrix <T, N, M> >::transposed_type;
308
308
309
- static transposed_t transpose (NBL_CONST_REF_ARG (matrix <T, N, M>) m)
309
+ static transposed_t __call (NBL_CONST_REF_ARG (matrix <T, N, M>) m)
310
310
{
311
311
#ifdef __HLSL_VERSION
312
312
return spirv::transpose (m);
@@ -319,7 +319,7 @@ struct transpose_helper<matrix<T, N, M> >
319
319
template<typename LhsT, typename RhsT>
320
320
struct mul_helper
321
321
{
322
- static inline mul_output_t<LhsT, RhsT> multiply (LhsT lhs, RhsT rhs)
322
+ static inline mul_output_t<LhsT, RhsT> __call (LhsT lhs, RhsT rhs)
323
323
{
324
324
return mul (lhs, rhs);
325
325
}
0 commit comments