Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Apr 1998 15:42:11 -0700 (PDT)
From:      gilham@csl.sri.com
To:        freebsd-gnats-submit@FreeBSD.ORG
Subject:   kern/6389: Need to be able to access trap-to-signal mapping to for Linux emulation to allow Allegro Common Lisp (and maybe other apps) to run.
Message-ID:  <199804222242.PAA22024@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         6389
>Category:       kern
>Synopsis:       Need to be able to access trap-to-signal mapping to for Linux emulation to allow Allegro Common Lisp (and maybe other apps) to run.
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:
>Keywords:
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Apr 22 15:50:02 PDT 1998
>Last-Modified:
>Originator:     Fred Gilham
>Organization:
SRI International
>Release:        FreeBSD 2.2?, FreeBSD 3.0
>Environment:
N/A
>Description:
The mapping between traps and signals is slightly different in FreeBSD
and Linux.  Ordinarily this doesn't cause problems but some applications
depend on being able to handle certain traps.  In particular, Allegro
Common Lisp, a commercial version of Common Lisp that was released to
the Linux community for free non-commercial use, depends on being able
to intercept T_PROTFLT traps to expand its heap if necessary.  In Linux
these traps are mapped to segmentation violations.  In FreeBSD they are
bus errors.  As a result, ACL will come up under the FreeBSD Linux
emulator and execute small programs but will die with a bus error if you
try to do anything significant.

I've worked with Mike Smith to resolve this problem.  He suggested
adding a mapping function to the sigentvec structure that emulators
could use to remap traps to the signals they wish.  I've implemented a
test version of this change and it allows ACL to work and run
significant applications.
>How-To-Repeat:
Run Allegro Common Lisp (available from www.franz.com) under the Linux
emulator.  Try to compile a lisp program.  You will get a bus error.
>Fix:
My test fixes are available from
ftp.csl.sri.com:/pub/gilham/trap-fixes.tar.gz.  They are directly
applicable to FreeBSD 3.0-980414-SNAP but they are relatively trivial
to apply to other releases.

>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199804222242.PAA22024>