I would like to add a command line option, -no-implicit-float, that will cause the noimplicitfloat attribute to be added to functions when targeting ARM. This attribute disables implicit floating point instructions. X86 already utilizes this attribute when the -msoft-float option is used. Unfortunately, we can't use -msoft-float on ARM, because it's already defined to mean something else. Therefore, I would like to propose we allow the driver to accept the -no-implicit-float option directly (i.e., basically forwarding the -no-implocit-float option to cc1). Does anyone have any opinions, comments or suggestions?
Regards,
Chad
On ARM, if -msoft-float is set, doesn't that already imply -no-implicit-float?
You want to set it in the case where -msoft-float otherwise isn't desired?
deep
On ARM, if -msoft-float is set, doesn't that already imply -no-implicit-float?
No, -msoft-float does not imply -no-implicit-float on ARM.
You want to set it in the case where -msoft-float otherwise isn't desired?
Yes, I would like to be able to use -no-implicit-float in isolation.
Chad
Perhaps I'm just missing something here, but why would I want the FP
hardware to be used implicitly if I have -msoft-float set? I could see
doing so if -mfloat-abi=soft, but not if we're fully soft-float.
deep
On ARM, if -msoft-float is set, doesn't that already imply -no-implicit-float?
No, -msoft-float does not imply -no-implicit-float on ARM.
Perhaps I'm just missing something here, but why would I want the FP
hardware to be used implicitly if I have -msoft-float set? I could see
doing so if -mfloat-abi=soft, but not if we're fully soft-float.
I'm no expert in this area and a do see your point. Unfortunately, I don't have a great answer. Possibly someone else on the list could provide some insight.
Chad
I don't know about recent versions of GCC, but in Apple's gcc-4.2, here is how the ARM -msoft-float option is defined (in gcc/config/arm/arm.opt):
msoft-float
Target RejectNegative
Alias for -mfloat-abi=soft
This has been highly confusing to me and others, but we're kind of stuck with it.