[PATCH] D32530: [SVE][IR] Scalable Vector IR Type

Cameron McInally via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 2 07:38:47 PDT 2019


cameron.mcinally added a comment.

Sorry to be late to the party, but I have a quick question:

> Ok, so do we have agreement that constant literal indices should be limited to 0..n-1 for now, but non-constant indices can potentially exceed n so that expressions featuring vscale can be used?

What if we know the width is fixed on our target machine? Let's say it's fixed at 512b. So a full width scalable double vector would be:

`<vscale x 2 x double>`

Since our width is fixed, we know that vscale=4 here and there are 8 elements in this vector.

I'd like to be able to do a really fast insert at say index 3. I.e. `insert_element(<vscale x 2 x double> res, double elt, int 3)`. Would that insert be as fast with the vscale method as it would be for an index < n-1?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D32530/new/

https://reviews.llvm.org/D32530





More information about the llvm-commits mailing list