RFR: aarch32: Another version of SoftFP implementation

Sergey Nazarkin snazarkin at azul.com
Thu Oct 27 14:24:34 UTC 2016


Hi Ed,

my fault, I forget to mention http://cr.openjdk.java.net/~snazarki/softfp/src/cpu/aarch32/vm/vm_version_aarch32.cpp.sdiff.html

For sure, we disable UseFPU if no FPU was detected

 222 #ifndef HARD_FLOAT_CC
 223   if( !(VM_Version::features() & (FT_VFPV2 | FT_VFPV3)) ) {
 224       if(FLAG_IS_CMDLINE(UseFPU)) {
 225           warning("FPU is not present at this core");
 226       }
 227       FLAG_SET_DEFAULT(UseFPU, false);
 228   }
 229 #endif

Sergey Nazarkin




> On 27 Oct 2016, at 17:10, Edward Nevill <edward.nevill at gmail.com> wrote:
> 
> On Thu, 2016-10-27 at 12:43 +0000, Sergey Nazarkin wrote:
>> Hi Ed,
>> 
>> I’ve updated webrev  and introduce UseFPU variable 
>> http://cr.openjdk.java.net/~snazarki/softfp/src/cpu/aarch32/vm/globals_aarch32.hpp.sdiff.html
>> http://cr.openjdk.java.net/~snazarki/softfp/src/cpu/aarch32/vm/vm_version_aarch32.hpp.sdiff.html
>> 
> 
> Hi Sergey,
> 
> The logic here seems broken? Or maybe I am misunderstanding something?
> 
> from globals_aarch32.hpp
> 
>  100   product(bool, UseFPU, true, "Enable FPU utilization at floating point ops." \
>  101       "Affects SoftFP mode only.")
> 
> So UseFPU defaults to true.
> 
> from vm_version_aarch32.hpp
> 
>   88 #ifdef HARD_FLOAT_CC
>   89 inline const bool hasFPU(void) { return true; }
>   90 #else
>   91 inline bool hasFPU(void) { return (UseFPU); }
>   92 #endif
>   93 
>   94
> 
> So by default hasFPU returns true in both cases. This will cause problems running on a genuine FPU less target?
> 
> If you want to push without this change that is fine, I can submit a subsequent patch to add the UseFPU option.
> 
> All the best,
> Ed.
> 



More information about the aarch32-port-dev mailing list