This is an archive of the discontinued LLVM Phabricator instance.

[builtins] Add support for single-precision-only-FPU ARM targets.
ClosedPublic

Authored by chaosdefinition on Nov 3 2020, 11:12 AM.

Details

Summary

This patch enables building compiler-rt builtins for ARM targets that only support single-precision floating point instructions (e.g., those with -mfpu=fpv4-sp-d16).

This fixes PR42838.

Diff Detail

Event Timeline

Herald added a project: Restricted Project. · View Herald TranscriptNov 3 2020, 11:12 AM
Herald added subscribers: Restricted Project, kristof.beyls, mgorny. · View Herald Transcript
chaosdefinition requested review of this revision.Nov 3 2020, 11:12 AM
psmith accepted this revision.Nov 4 2020, 3:24 AM
psmith added a subscriber: psmith.

This looks good to me. The __ARM_FP feature test macro is defined in the ACLE and 0x8 is the right flag to check for Double precision support. I've tested at least one single precision only build.

I suggest waiting a day or two before committing to see if anyone else has any objections or alternative implementation suggestions.

This revision is now accepted and ready to land.Nov 4 2020, 3:24 AM

@psmith Thank you for reviewing! I'll wait a few days for other comments.

If there are no more comments, can someone please commit this for me? I don't have commit access to LLVM.

If there are no more comments, can someone please commit this for me? I don't have commit access to LLVM.

That's a little complicated for me as I need to go through various internal company procedures to commit something I didn't write. I can do this but it will take time, if there are any others that can do it faster then please do.

Now committed. Commit message has your name and email address.

Assuming there are no problems with the bots or other downstream builds, please update the PR with a link to this review.

If there are no more comments, can someone please commit this for me? I don't have commit access to LLVM.

That's a little complicated for me as I need to go through various internal company procedures to commit something I didn't write. I can do this but it will take time, if there are any others that can do it faster then please do.

Thank you for taking time doing this! I'll consider getting myself commit access for future patches.