[PATCH] D52149: add support functions for hard/soft float multilib distinction

Peter Smith via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 1 03:27:02 PDT 2018


peter.smith added reviewers: compnerd, rengolin.
peter.smith added a comment.

I've added another couple of reviewers.

At this stage I'm not yet sure that it is worth adding this functionality to Triple. In https://reviews.llvm.org/D52705 it seems like this is used to get the HF or non HF string name for the provided triple only when multilibs are used on Arm. As a result a lot of the code in the function (x86 handling) won't ever be exercised as it won't be called for other targets. A name change of the functions to getARMSoftFloatVariant() or getARMHardFloatVariant() and only handle the Arm cases would be a bit more honest, but it also points out that perhaps it would be better to handle as a local function called from findArmEABIMultilibs()?

The similar functions getLittleEndianVariant() and getBigEndianVariant() in Triple are slightly more general. They are called for all targets and there are also at least 3 targets (Arm, AArch64 and Mips) that include the endianness in the Target. This makes it more useful to handle the functionality in Triple.

If the consensus is to go ahead with this in triple please do add some tests to llvm/unittests/ADT/TripleTest.cpp


Repository:
  rL LLVM

https://reviews.llvm.org/D52149





More information about the llvm-commits mailing list