[PATCH] D138026: [ARM][AArch64] Use StringRef in TargetParser structs

Tomas Matheson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 15 04:55:12 PST 2022


tmatheson created this revision.
tmatheson added reviewers: lenary, pratlucas, DavidSpickett.
Herald added subscribers: hiraditya, kristof.beyls.
Herald added a project: All.
tmatheson requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

The invalid case is now represented by an empty StringRef rather than
a nullptr.

Previously ARCH_FEATURE was build from SUB_ARCH by prepending "+".
This is now reverse, so that the "+arch-feature" is now visible in
the .def, which is a bit clearer. This meant converting one StringSwitch
into a loop.

Removed getters which are now mostly unnecessary.

Removed some old FIXMEs.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D138026

Files:
  llvm/include/llvm/Support/AArch64TargetParser.def
  llvm/include/llvm/Support/AArch64TargetParser.h
  llvm/include/llvm/Support/ARMTargetParser.def
  llvm/include/llvm/Support/ARMTargetParser.h
  llvm/lib/Support/AArch64TargetParser.cpp
  llvm/lib/Support/ARMTargetParser.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D138026.475430.patch
Type: text/x-patch
Size: 35085 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221115/2ec7168e/attachment.bin>


More information about the llvm-commits mailing list