Soft Float for PC386
Angelo Fraietta
angelo_f at bigpond.com
Tue Feb 5 18:56:00 UTC 2002
I would recommend using the pc386dx bsp as it is identical to the pc386
except that it is using the fp libraries. I am using this bsp also for a
DIMMPC (386sx) with no co-processor. Give the pc386dx bsp a go and let
us know if it works for you.
Smith, Gene wrote:
>I installed the 4.5.0-preview rpms and now have the variant libraries under
>/opt/rtems/i386-rtems/lib. When I build from scratch (bit_rtems i386
>cp386sx) I still see f*** instructions. I suspect I might need to copy the
>desired variant files (soft-float) into the lib directory and replace the
>default libraries that are there (I will try this). Or is there a better way
>to select the desired variant?
>
>-gene
>
>>-----Original Message-----
>>From: Joel Sherrill [mailto:joel.sherrill at OARcorp.com]
>>Sent: Monday, February 04, 2002 4:07 PM
>>To: Angelo Fraietta
>>Cc: Smith, Gene; rtems-users
>>Subject: Re: Soft Float for PC386
>>
>>
>>
>>
>>Angelo Fraietta wrote:
>>
>>>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.)
>>>>
>>If you are using a 4.5 system, go with the RPMs in the
>>4.5.1-previews directory. You need the right organization of
>>c library header files so gccnewlib RPMs are 4.5 specific. binutils
>>and gdb RPMs are generally more version independent.
>>
>>>>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)
>>>
>>--
>>Joel Sherrill, Ph.D. Director of Research & Development
>>joel at OARcorp.com On-Line Applications Research
>>Ask me about RTEMS: a free RTOS Huntsville AL 35805
>>Support Available (256) 722-9985
>>
>
--
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/20020206/7524622e/attachment-0001.html>
More information about the users
mailing list