search for: idx_1

Displaying 6 results from an estimated 6 matches for "idx_1".

Did you mean: idx_r
2019 Jul 23
2
[RFC] A new multidimensional array indexing intrinsic
...ete, fully-legal IR representation of what's being proposed would help. > > Here's a best guess, switching the indexed base type to a non-integer for illustration purposes: > > %arrayidx = call i64 @llvm.multidim.array.index.i64.p0f64.i64.i64.i64.i64 double* %A, i64 %str_1, i64 %idx_1, i64 %str_2, i64 %idx_2 > > According to the RFC, that would get lowered to this: > > %mul1 = mul nsw i64 %str_1, %idx_1 > %mul2 = mul1 nsw i64 %str_2, %idx_2 > %total = add nsw i64 %mul2, %mul1 > %arrayidx = getelementptr inbounds double, double* %A, i64 %total, !multi...
2019 Jul 22
1
[RFC] A new multidimensional array indexing intrinsic
...; <result> = llvm.multidim.array.index.* <ty> <ty>* <ptrval> {<stride>, <idx>}* > > It isn't clear to me what that means. The later example is also in a somewhat generalized form: > > %arrayidx = llvm.multidim.array.index.* i64 i64* %A, %str_1, %idx_1, %str_2, %idx_2 > > Trying to expand this into something concrete it looks to me like the extra value-less type argument ('i64' immediately following the intrinsic name) won't work, and if I'm reading it correctly that's a necessary element. The GEP instruction accepts a r...
2019 Jul 21
6
[RFC] A new multidimensional array indexing intrinsic
...`idxA_i != idxB_i`), then the resulting pointer values are not equal. ##### Address computation: Consider an invocation of `llvm.multidim.array.index.*`: ``` <result> = call @llvm.multidim.array.index.* <ty> <ty>* <ptrval> <str_0>, <idx_0>, <str_1> <idx_1>, ..., <str_n> <idx_n> ``` If the pairs are denoted by `(str_i, idx_i)`, where `str_i` denotes the stride and `idx_i` denotes the index of the ith pair, then the final address (in bytes) is computed as: ``` ptrval + len(ty) * [(str_0 * idx_0) + (str_1 * idx_1) + ... (str_n * idx_n)...
2019 Jul 22
2
[RFC] A new multidimensional array indexing intrinsic
...r values are not equal. > > > ##### Address computation: > Consider an invocation of `llvm.multidim.array.index.*`: > > ``` > <result> = call @llvm.multidim.array.index.* <ty> <ty>* <ptrval> <str_0>, <idx_0>, <str_1> <idx_1>, ..., <str_n> <idx_n> > ``` > > If the pairs are denoted by `(str_i, idx_i)`, where `str_i` denotes the stride > and `idx_i` denotes the index of the ith pair, then the final address (in bytes) > is computed as: > > ``` > ptrval + len(...
2019 Jul 22
2
[RFC] A new multidimensional array indexing intrinsic
...not equal. >> >> >> ##### Address computation: >> Consider an invocation of `llvm.multidim.array.index.*`: >> >> ``` >> <result> = call @llvm.multidim.array.index.* <ty> <ty>* <ptrval> <str_0>, <idx_0>, <str_1> <idx_1>, ..., <str_n> <idx_n> >> ``` >> >> If the pairs are denoted by `(str_i, idx_i)`, where `str_i` denotes the stride >> and `idx_i` denotes the index of the ith pair, then the final address (in bytes) >> is computed as: >> >> ``` >> ptrva...
2019 Jul 25
0
[RFC] A new multidimensional array indexing intrinsic
...;>> >>> ##### Address computation: >>> Consider an invocation of `llvm.multidim.array.index.*`: >>> >>> ``` >>> <result> = call @llvm.multidim.array.index.* <ty> <ty>* <ptrval> <str_0>, <idx_0>, <str_1> <idx_1>, ..., <str_n> <idx_n> >>> ``` >>> >>> If the pairs are denoted by `(str_i, idx_i)`, where `str_i` denotes the stride >>> and `idx_i` denotes the index of the ith pair, then the final address (in bytes) >>> is computed as: >>> &gt...