possible SPARC cpu_asm.S error

Jerry Needell jerry.needell at unh.edu
Tue Aug 15 12:26:26 UTC 2006


I think I have found an error in the cpukit/score/cpu/sparc/cpu_asm.S 
code. When writing to the PSR, a sequence of three NOP's must be added 
to ensure that the PSR value is properly set after running through the 
pipeline. This is done in most places in cpu_asm.S but was left out in a 
few and, I think, causing me some problems. I have been trying to track 
down and intermittent crash for a long time! My application was crashing 
after servicing an interrupt. cpu_asm.S includes ISR_Dispatch which was 
missing the NOP's ater setting the PSR before returning.

    The problem became much worse when I tried rebuilding 4.6.99.3 using 
the -mcpu-v8 flag to take advantage of the SPARC V8 multiply in the 
LEON3.  The  diff attached also  has the change I made to 
make/custom/leon3.cfg to set the -mcpu=v8 switch.       
   
    The cpu-asm.S error should apply to all SPARC cpu's (v7 or v8).

   

- Jerry
   
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: rtems-diffs
URL: <http://lists.rtems.org/pipermail/users/attachments/20060815/a9536d88/attachment.ksh>


More information about the users mailing list