[PATCH] D95016: [Clang][RISCV] Add custom TableGen backend for riscv-vector intrinsics.

Jessica Clarke via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 10 13:38:18 PST 2021


jrtc27 added inline comments.


================
Comment at: clang/utils/TableGen/RISCVVEmitter.cpp:58-62
+  bool IsPointer = false;
+  // IsConstant indices are "int", but have the constant expression.
+  bool IsImmediate = false;
+  // const qualifier.
+  bool IsConstant = false;
----------------
craig.topper wrote:
> craig.topper wrote:
> > jrtc27 wrote:
> > > This isn't expressive enough for the grammar you defined. `PCPCec` is supposed to give `const i8 * const i8 *`, whereas this will interpret it as `const i8 *`. Given such types are presumably not needed you need to tighten the rules of your grammar.
> > @jrtc, are you asking for RVVType::applyModifier to verify that that C doesn't appear twice for example?
> Oops I meant to write @jrtc27 above. Are you asking for RVVType::applyModifier to verify that that C doesn't appear twice for example?
That P and C don't appear twice, and that C appears in the "right" order wrt P (i.e. it's always PC never CP).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D95016



More information about the llvm-commits mailing list