[PATCH] D70779: AArch64: add support for newer Apple CPUs

Tim Northover via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 27 05:14:22 PST 2019


t.p.northover created this revision.
t.p.northover added a reviewer: ab.
Herald added subscribers: hiraditya, kristof.beyls, mcrosier.
Herald added a project: LLVM.
t.p.northover updated this revision to Diff 231220.
t.p.northover added a comment.

Test updates after switching arm64_32 default CPU to apple-s4.


The CPUs used in Apple devices have been gradually getting more features, but upstream LLVM only knew about the original "Cyclone" variant. Xcode could also target "vortex" (for arm64_32 and arm64e), but using internal names isn't really ideal for anyone.

In official documentation the 64-bit CPUs are known as A7-A13 (iPhone, iPad) and S4-S5 (Watch), with some marketing suffixes that we probably don't need to care about. Since those bare names would be quite a land grab (and easily confused with Cortex-A*), this adds the currently released CPUs as "apple-aN" and "apple-sN".

I've left Cyclone in as a legacy option (build systems and existing bitcode probably relies on it), but switched the default over to the new scheme: apple-a7 for arm64 and apple-s4 for arm64_32.


https://reviews.llvm.org/D70779

Files:
  clang/lib/Driver/ToolChains/Arch/AArch64.cpp
  clang/test/Driver/aarch64-cpus.c
  clang/test/Driver/arm64-as.s
  clang/test/Preprocessor/aarch64-target-features.c
  llvm/include/llvm/Support/AArch64TargetParser.def
  llvm/lib/Target/AArch64/AArch64.td
  llvm/lib/Target/AArch64/AArch64Subtarget.cpp
  llvm/lib/Target/AArch64/AArch64Subtarget.h
  llvm/lib/Target/AArch64/AArch64SystemOperands.td
  llvm/unittests/Support/TargetParserTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D70779.231220.patch
Type: text/x-patch
Size: 20062 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191127/f28172a3/attachment-0001.bin>


More information about the cfe-commits mailing list