1 of 9

Road to

RVV C Intrinsic API v1.0

Meeting #10 2023/05/15

2 of 9

Agenda 2023/05/15

  • Reinterpret cast intrinsics between vector boolean and LMUL=1 (m1) vector integer values
  • Tuple type to improve the segment load/store interface
  • Model rounding mode for fixed-point intrinsics
  • Ratification plan status
  • AOB

3 of 9

Reinterpret cast between vector boolean and LMUL=1 (m1) vector integer values

rvv-intrinsic-doc

LLVM Phabricator

  • https://reviews.llvm.org/D149642
  • Expected to converge and land this week.

4 of 9

Tuple type to improve the segment load/store interface

rvv-intrinsic-doc

LLVM Phabricator

  • First critical patch [0] is accepted by Craig Topper. If no further concern from Nikita Popov, the patch will land and eop will finish the rest of the patch set.

[0] https://reviews.llvm.org/D146872

5 of 9

Model rounding mode for fixed-point intrinsics

rvv-intrinsic-doc

  • https://github.com/riscv-non-isa/rvv-intrinsic-doc/pull/222
  • Status: Adjusted style to adding an extra parameter in the function instead of static encoding rounding mode into the function name.

LLVM Phabricator

  • Implementation is still work-in-progress.

[0] https://reviews.llvm.org/D146872

6 of 9

Ratification plan status - 2023/05/15

Milestones:

  • Publicize intrinsic generator from SiFive into rvv-intrinsic-doc
  • Simplification Proposal
  • Change operand order for vmerge, vcompress
  • Change default tail undisturbed intrinsics to tail agnostic
  • Overall tail policy simplification
  • Expose access of read-only CSR vlenb to user
  • Add "__riscv_" prefix for all intrinsics
  • Adaptor header to transit RVV v0.10 to v0.11
  • Tuple type as primitive type for segment load / store due 5/17
  • Mask interpretation between m1 reg with non-boolean types and mask registers (#156) due 5/01
  • Rounding mode for fixed-point and floating-point intrinsics due 6/12
  • Polish the document due 6/26

7 of 9

AOB

(Nick) On the scheme for fixed point intrinsics modeling rounding mode.

Concern on compiler work for the rounding mode changes.

Initial patch-set will have suboptimal CSR read/write, guaranteeing function correctness first.

8 of 9

AOB

Sizeless types in struct.

Google use Eigen.

Eigen computation - Transpose, can utilize the homogeneous tuple.

Function that returns pair<float, int>, if vectorized will not fit current proposal (tuple).

Offset for struct, in non-homogeneous case.

Complexity of approaching the problem needs a matching use case.

Nick: Use case may be multi-word arithmetic with mixed data width.

Philip: Fundamental hardness considering non-homogeneous in the compiler.

Homogeneous limitation: SEW / LMUL match, No scalar mixed.

POD = Plain of Data

Non-POD: including virtual functions.

9 of 9

AOB