[PATCH] D61668: [ARM] Fix the extensions implied by a cpu name

Diogo N. Sampaio via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 8 02:27:46 PDT 2019


dnsampaio created this revision.
Herald added subscribers: cfe-commits, kristof.beyls, javed.absar.
Herald added a project: clang.
dnsampaio added reviewers: keith.walker.arm, DavidSpickett, carwil.

When using `clang -mcpu=CPUNAME+FEATURELIST`,
the intrinsic features defined by CPUNAME are
not obtained, as the entire string is passed.
This fixes that by spiting the cpuname
string in the first `+`, if any.

For example, when using

  clang -### --target=arm-arm-none-eabi -march=armv7-a -mcpu=cortex-a8+nocrc

the intrinsic

  "target-feature" "+dsp"

implied by `cortex-a8` is missing.


Repository:
  rC Clang

https://reviews.llvm.org/D61668

Files:
  lib/Driver/ToolChains/Arch/ARM.cpp
  test/Driver/arm-cortex-cpus.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61668.198605.patch
Type: text/x-patch
Size: 6699 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190508/614f7b51/attachment-0001.bin>


More information about the cfe-commits mailing list