Soft Float for PC386

Angelo Fraietta angelo_f at bigpond.com
Mon Feb 4 21:04:33 UTC 2002


In am using snapshot rtems-ss-20010525 using the rpms of that date 
(which was around November) and paranoia is working fine. I have no 
co-processor on my machine and am using the pc386dx BSP.

Additionally, the floating point problem was resolved in Feb last year, 
so the RPMs from there should be fine


Smith, Gene wrote:

>I am trying to include soft-float on my rtems-4.5.0 386 system (no
>coprocessor). This thread indicates there was (is?) a problem with the
>newlib rpms. I am using the newlib rpm updated in Sept for 4.5.0. However,
>the compile of paranoia fails due to undefined fp routines (I have set
>CPU_CFLAG = -msoft-float -mno-fp-ret-in-387).  
>
>Is it ok to use snapshot or preview rpms (need newlib1.9.0-1 per below) with
>my 4.5.0 system without totally upgrading rtems to the 4.5.1-preview or a
>snapshot? If so, which ones? (I see some that indicated they are
>LATEST_TRUSTED.)
>
>Tks,
>-gene
>
>>-----Original Message-----
>>From: Angelo Fraietta [mailto:angelo at hunterlink.net.au]
>>Sent: Tuesday, February 27, 2001 4:10 AM
>>To: corsepiu at faw.uni-ulm.de; rtems-users; Joel Sherrill
>>Subject: Re: Soft Float for PC386
>>
>>
>>Wait on that, I have just found that there was another RPM 
>>made, being the i386-rtems-gcc-gcc2.95.2newlib1.9.0-1.i386.rpm   as
>>well as the rtems-base-gcc-gcc2.95.2newlib1.9.0-1.i386.rpm
>>(I thought my machine had frozen up after the first RPM was made)
>>I'll rebuild RTEMS and check again. Sorry about that.
>>
>>Angelo Fraietta wrote:
>>
>>>The computer no longer re-boots when running two tasks with  
>>>
>>the -mno-fp-ret-in-387 flags.
>>
>>>However, there are still co-processor commands occuring. 
>>>
>>This is where the exception occurs:
>>
>>>with CPU_CFLAGS =-msoft-float -mno-fp-ret-in-387
>>>
>>>  10ba89: 5e                    pop    %esi
>>>  10ba8a: 5f                    pop    %edi
>>>  10ba8b: dd 45 f0              fldl   0xfffffff0(%ebp)
>>>  10ba8e: c9                    leave
>>>
>>>Ralf Corsepius wrote:
>>>
>>>>Angelo Fraietta wrote:
>>>>
>>>>>If I build the pc386 with both the -mno-fp-ret-in-387 
>>>>>
>>and the -msoft-float flags
>>
>>>>>the machine re-boots if you try to create a task. Eg, if 
>>>>>
>>you try to run the
>>
>>>>>ticker sample, the machine re-boots.  If you only use 
>>>>>
>>the -msoft-float and not
>>
>>>>>the -mno-fp-ret-in-387 flag, the tasks run OK.
>>>>>I am mentioning this because the ts_386ex build uses 
>>>>>
>>both flags, and so if
>>
>>>>>someone tests these on a ts_386ex, they may want to try 
>>>>>
>>running ticker on it to
>>
>>>>>see if it crashes.
>>>>>
>>>>This doesn't surprize me, because newlib unconditionally inserts
>>>>FPU-code into its libc, no matter which compiler options are used
>>>>for building it. I.e. at least one cause of your problems 
>>>>
>>is lurking
>>
>>>>in newlib.
>>>>
>>>>I believe to have fixed this issue, so you could consider 
>>>>
>>rebuilding
>>
>>>>your gcc-newlib rpms, using the *.nosrc.rpm below, which 
>>>>
>>contains my
>>
>>>>fixes.
>>>>
>>>>Procedure for rebuilding:
>>>>1) Copy gcc-2.95.2.tar.gz and newlib-1.9.0.tar.gz to
>>>>/usr/src/redhat/SOURCES.
>>>>
>>>>2) rpm -i i386-rtems-gcc-newlib-gcc2.95.2newlib1.9.0-1.nosrc.rpm
>>>>[This will install RTEMS diffs and my patches to
>>>>/usr/src/redhat/SOURCES]
>>>>
>>>>3)
>>>>export PATH=/opt/rtems/bin:$PATH
>>>>rpm -bb
>>>>
>>/usr/src/redhat/SPECS/i386-rtems-gcc-newlib-gcc2.95.2newlib1.9.0.spec
>>
>>>>[Now wait a couple of hours for the built to finish. Requires 500MB
>>>>to 1GB of free diskspace below /usr/src/redhat]
>>>>
>>>>4) /usr/src/redhat/RPMS/i386 now should contain the new
>>>>i386-rtems-*.rpms
>>>>
>>>>5) Rebuild RTEMS w/ -msoft-float -mno-fp-ret-in-387.
>>>>
>>>>6) Test at run-time.
>>>>
>>>>Hope that helps.
>>>>
>>>>FYI: These patches already are submitted to Joel and to the newlib
>>>>maintainers.
>>>>
>>>>AFAIK, Joel already is preparing new RTEMS toolchain rpms. 
>>>>
>>So if you
>>
>>>>can't build the toolchain yourself for some reason, it's probably
>>>>only a matter of days until new RTEMS toolchain rpms will appear on
>>>>OAR's site.
>>>>
>>>>Ralf
>>>>
>>>>--
>>>>Ralf Corsepius
>>>>Forschungsinstitut fuer Anwendungsorientierte Wissensverarbeitung
>>>>(FAW)
>>>>Helmholtzstr. 16, 89081 Ulm, Germany     Tel: +49/731/501-8690
>>>>mailto:corsepiu at faw.uni-ulm.de           FAX: +49/731/501-999
>>>>http://www.faw.uni-ulm.de
>>>>
>>>>  
>>>>
>>---------------------------------------------------------------
>>---------
>>
>>>>                                                           
>>>>
>> Name: i386-rtems-gcc-newlib-gcc2.95.2newlib1.9.0-1.nosrc.rpm
>>
>>>>   i386-rtems-gcc-newlib-gcc2.95.2newlib1.9.0-1.nosrc.rpm  
>>>>
>> Type: RealPlayer(tm) as Plug-in (audio/x-pn-realaudio-plugin)
>>
>>>>                                                         
>>>>
>>Encoding: base64
>>
>>>--
>>>Angelo Fraietta
>>>
>>>PO Box 859
>>>Hamilton NSW 2303
>>>
>>>Home Page
>>>
>>>http://users.hunterlink.net.au/~maaaf/
>>>
>>>There are those who seek knowledge for the sake of knowledge 
>>>
>>- that is CURIOSITY
>>
>>>There are those who seek knowledge to be known by others - 
>>>
>>that is VANITY
>>
>>>There are those who seek knowledge in order to serve - that is LOVE
>>>    Bernard of Clairvaux (1090 - 1153)
>>>
>>--
>>Angelo Fraietta
>>
>>PO Box 859
>>Hamilton NSW 2303
>>
>>Home Page
>>
>>http://users.hunterlink.net.au/~maaaf/
>>
>>There are those who seek knowledge for the sake of knowledge - 
>>that is CURIOSITY
>>There are those who seek knowledge to be known by others - 
>>that is VANITY
>>There are those who seek knowledge in order to serve - that is LOVE
>>   Bernard of Clairvaux (1090 - 1153)
>>
>>
>

-- 
Angelo Fraietta

PO Box 859
Hamilton NSW 2303

Home Page


http://www.users.bigpond.com/angelo_f/

There are those who seek knowledge for the sake of knowledge - that is CURIOSITY
There are those who seek knowledge to be known by others - that is VANITY
There are those who seek knowledge in order to serve - that is LOVE
    Bernard of Clairvaux (1090 - 1153)


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/users/attachments/20020205/01645e26/attachment-0001.html>


More information about the users mailing list