As far as I can tell, this matches gcc: -mfloat-abi determines the calling convention for all functions except those explicitly defined as soft-float in the ARM RTABI.
This change only affects cases where the user specifies -mfloat-abi to override the default calling convention derived from the target triple.
Fixes https://bugs.llvm.org//show_bug.cgi?id=34530.
(This obsoletes https://reviews.llvm.org/D38050 if it's accepted.)
@peter.smith and I had a look at this. Since at least GCC 4.9, GCC uses the floating point ABI to determine the libcall calling convention. Note that this does break the current ABI.
Given that GCC now does something sane (i.e. only the __aeabi_ functions are soft float, and the other calls are dependent on -mfloat-abi) this seems like the best thing to do.