[PATCH] D112421: [clang][ARM] PACBTI-M frontend support

Daniel Kiss via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 4 04:48:08 PDT 2021


danielkiss added inline comments.


================
Comment at: clang/lib/Basic/Targets/AArch64.cpp:134-135
                                                  StringRef &Err) const {
-  llvm::AArch64::ParsedBranchProtection PBP;
-  if (!llvm::AArch64::parseBranchProtection(Spec, PBP, Err))
+  llvm::ARM::ParsedBranchProtection PBP;
+  if (!llvm::ARM::parseBranchProtection(Spec, PBP, Err))
     return false;
----------------
aaron.ballman wrote:
> chill wrote:
> > vhscampos wrote:
> > > aaron.ballman wrote:
> > > > This change surprises me. Why should AArch64TargetInfo prefer calling into ARM instead?
> > > Since that particular function ended up identical in both ARM and AArch64, we removed the AArch64 specific function and kept only one under ARM. You can spot the removal further down the patch.
> > > 
> > > The ARM namespace under ARMTargetParser.h already had code used in AArch64TargetParser, so we did not introduce new cross dependencies.
> > It's the unfortunate overload of "ARM" used to denote the backend and the organisation.
> Ah, that's good to know, thank you for the explanation. (And yeah, that is an unfortunate overload of the term.)
Wondering will this link when the `LLVM_TARGETS_TO_BUILD` does not contains ARM but AArch64?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D112421



More information about the cfe-commits mailing list