[NFC][Clang][RISCV] Reduce boilerplate when determining prototype for segment loads
authoreopXD <yueh.ting.chen@gmail.com>
Thu, 29 Dec 2022 09:05:54 +0000 (01:05 -0800)
committereopXD <yueh.ting.chen@gmail.com>
Tue, 3 Jan 2023 02:50:36 +0000 (18:50 -0800)
commitf2bec8702688ea034cefcf4e13922aa4d40bd4a0
treeb63e17a34955aa2ffb7f42ca6eac4dd300dde730
parente8d6c537ac7c1caea865860fd32c1ba2623c4ddc
[NFC][Clang][RISCV] Reduce boilerplate when determining prototype for segment loads

No functionality change of the RVV builtin and compiler intrinsics is intended
in this patch.

This patch gathers scattered comments for the segment load builtin/intrinsics
and its variants (e.g. segment unit-stride load, segment strided load) into a
single paragraph under riscv_vector.td.

This patch also tries to reduce one level of the if-statements as the push_back
are essentially the same actions but differs in index based on the the value
of the policy attributes and whether the intrinsic is masked.

Reviewed By: kito-cheng

Differential Revision: https://reviews.llvm.org/D140662
clang/include/clang/Basic/riscv_vector.td