[fpc-devel] MIPS big-endian program starts but does nothing

Mark Morgan Lloyd markMLl.fpc-devel at telemetry.co.uk
Tue Sep 9 10:20:46 CEST 2014


Sven Barth wrote:
> On 08.09.2014 22:54, Michael Ring wrote:
>> This smells like a problem I had on pic32. In my case the pic32 chips do
>> not have a floating point unit and the processor creates an illegal
>> instruction (or something similar) exception.
>>
>> I solved this for me by patching out the call to the hardware
>> coprocessor when softfpu is selected.
> 
> Which should be the correct approach for softfpu anyway. Afterall the 
> premise of softfpu is that there is no hardware FPU to use and thus 
> corresponding CPU instructions are useless (or as it seems in this case 
> lead to nothing).

I was wondering whether a completely empty program would be a better 
test than a "Hello, World!". Could a completely empty program be 
recognised by the compiler etc. as a special case and built with only 
minimal RTL initialisation, specifically as a test that a program will 
load and terminate in good order i.e. that FPC and the OS are 
compatible? Or is there a set of portable options that will already do 
this, which could be documented prominently?

After all, there's been comparable issues on ARM, and there might be 
more on various platforms in the future.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]



More information about the fpc-devel mailing list