[llvm-dev] [RFC] A new multidimensional array indexing intrinsic
David Greene via llvm-dev
llvm-dev at lists.llvm.org
Thu Jul 25 08:40:49 PDT 2019
"Doerfert, Johannes via llvm-dev" <llvm-dev at lists.llvm.org> writes:
> On 07/24, Tim Northover via llvm-dev wrote:
>> Apart from all that, I'm pretty disappointed to see this as an
>> intrinsic though. GEP is such a fundamental part of addressing in LLVM
>> that bifurcating it into an intrinsic for either a language or an
>> analysis seems like we'd be papering over a language deficiency.
>
> Agreed. I included some non-intrinsic solutions in the other mail for
> this reason. Personally, I would prefer a type-system extension to make
> multi-dimensional "inrange" GEPs for symbolic sized arrays a natural GEP
> extension. However, that solution is be the hardest to get right. If we
> have enough dedicated people and no strong objections, we should give it
> a try.
Are you suggesting dependent types in LLVM IR? That would be really
useful not only for true multidimensional arrays and accesses, but also
things like vectorization with a runtime width (a la SVE and RISC-V).
Obviously it's a huge change.
If you have something else in mind, can youi elaborate?
I too would prefer this kind of thing use GEP if possible.
-David
More information about the llvm-dev
mailing list