From nobody  Wed Jan  6 22:58:21 1999
Received: (from nobody@localhost)
          by hub.freebsd.org (8.8.8/8.8.8) id WAA16148;
          Wed, 6 Jan 1999 22:58:21 -0800 (PST)
          (envelope-from nobody)
Message-Id: <199901070658.WAA16148@hub.freebsd.org>
Date: Wed, 6 Jan 1999 22:58:21 -0800 (PST)
From: grehan@iprg.nokia.com
To: freebsd-gnats-submit@freebsd.org
Subject: /boot/loader contains floating point instructions
X-Send-Pr-Version: www-1.0

>Number:         9360
>Category:       i386
>Synopsis:       /boot/loader contains floating point instructions
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    dcs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jan  6 23:00:01 PST 1999
>Closed-Date:    Mon Feb 15 05:45:44 PST 1999
>Last-Modified:  Mon Feb 15 05:48:00 PST 1999
>Originator:     Peter Grehan
>Release:        3.0-current
>Organization:
Nokia IPRG
>Environment:
Use kern.flp from the -current snapshot.
>Description:
Floating point code is used in the tertiary boot-loader, /boot/loader

_setjmp and _longjmp save/restore floating point state, but the
system may not have an FPU, in which case the boot will fail.
There are many 386 and 486 embedded CPUs which do not have an
FPU (e.g. Nokia 9000 communicator).

 One of the routines in the Forth interpreter, ficl/dict.c:dictHashSummary()
uses floating point. This routine should be reworked, or removed.
>How-To-Repeat:
Boot kern.flp on a 386 or 486 system without an FPU. Alternatively,
try the bochs emulator, which is a 386 emulator without an FPU
(www.bochs.com)
>Fix:
Use a custom _setjmp and _longjmp in libstand.a that does not
save/restore floating point register state.

 Remove, or modify, the routine in the Forth interpreter that uses
floating point calculations.
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->dcs 
Responsible-Changed-By: dcs 
Responsible-Changed-When: Mon Feb 8 13:28:00 PST 1999 
Responsible-Changed-Why:  
It's my backyard... :-) 
State-Changed-From-To: open->closed 
State-Changed-By: dcs 
State-Changed-When: Mon Feb 15 05:45:44 PST 1999 
State-Changed-Why:  
Suggested course of action taken. No further complains were heard. Thanks. 
>Unformatted:
