[PATCH] D99984: [RISCV] Prevent __builtin_riscv_orc_b_64 from being compiled RV32 target.

Craig Topper via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 8 08:25:37 PDT 2021


craig.topper added inline comments.


================
Comment at: clang/lib/Basic/Targets/RISCV.cpp:259
       .Case("riscv64", Is64Bit)
+      .Case("64bit", Is64Bit)
       .Case("m", HasM)
----------------
frasercrmck wrote:
> What's the difference between this new feature and `riscv64` above?
The name I added to initFeatureMap has to match the feature name in RISCV.td because it will end up in the target-features attribute in IR.

SemaChecking just calls hasFeature, but CodeGenFunction also checks builtin features using the feature map. We check features in SemaChecking because the CodeGenFunction diagnostic isn’t phrased well for RISCV.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D99984



More information about the cfe-commits mailing list