[PATCH] D31972: Do not force the frame pointer by default for ARM EABI

Christian Bruel via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 6 04:57:51 PDT 2017


chrib added inline comments.


================
Comment at: lib/Driver/ToolChains/Clang.cpp:569
 
+  if (Triple.getEnvironment() == llvm::Triple::EABI) {
+    switch (Triple.getArch()) {
----------------
efriedma wrote:
> chrib wrote:
> > efriedma wrote:
> > > Specifically checking for "llvm::Triple::EABI" is suspicious... what are you trying to distinguish?
> > I'm targeting the AAPCS for bare toolsets, (we could also test EABIHF by the way)
> > 
> > I'm not sure about the other ABIs (such as llvm::Triple::OpenBSD) so it is probably conservative and stick to what I can test. Do you think this pertains to more, for instance to AAPCS-LINUX, without breaking anything ?
> > 
> So... something like isTargetAEABI() in ARMSubtarget.h?
> 
> Please clarify the comment, and add a check for EABIHF.
yes, (although I'm not sure for Darwin). The closest check for AAPCS I've found is Clang::AddARMTargetArgs. 

I've updated the patch to check EABIHF as well.


https://reviews.llvm.org/D31972





More information about the cfe-commits mailing list