]> granicus.if.org Git - clang/commit
[clang][Driver][ARM] Favor -mfpu over default CPU features
authorAlexandros Lamprineas <alexandros.lamprineas@arm.com>
Sun, 14 Jul 2019 18:32:42 +0000 (18:32 +0000)
committerAlexandros Lamprineas <alexandros.lamprineas@arm.com>
Sun, 14 Jul 2019 18:32:42 +0000 (18:32 +0000)
commit54ed9d692456b4dd2eb4cfe37debef897caeed14
tree863d47bc81bfe85bd389801ce3c7b74741f4331c
parentd68805d6a72b3cf9bdd4276069bcbaa6fd65fdb3
[clang][Driver][ARM] Favor -mfpu over default CPU features

When processing the command line options march, mcpu and mfpu, we store
the implied target features on a vector. The change D62998 introduced a
temporary vector, where the processed features get accumulated. When
calling DecodeARMFeaturesFromCPU, which sets the default features for
the specified CPU, we certainly don't want to override the features
that have been explicitly specified on the command line. Therefore, the
default features should appear first in the final vector. This problem
became evident once I added the missing (unhandled) target features in
ARM::getExtensionFeatures.

Differential Revision: https://reviews.llvm.org/D63936

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@366027 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Driver/ToolChains/Arch/ARM.cpp
test/CodeGen/arm-target-features.c