[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problem with FFI in CLISP-1997-08-07
- To: <clisp-list@ma2s2.mathematik.uni-karlsruhe.de>
- Subject: Re: Problem with FFI in CLISP-1997-08-07
- From: Bruno Haible <haible@ilog.fr>
- Date: Wed, 13 Aug 1997 15:49:00 +0200 (MET DST)
- >received: from halles.ilog.fr (halles.ilog.fr [172.16.1.96]) by ilog.ilog.fr (8.8.7/8.7.3) with ESMTP id PAA06323; Wed, 13 Aug 1997 15:49:01 +0200 (MET DST)
- In-reply-to: <199708131128.NAA04816@orion.plopp.de>
- References: <199708131128.NAA04816@orion.plopp.de>
Matthias Lindner <matthias@intellektik.informatik.th-darmstadt.de> writes:
> using the newest CLISP (1997-08-07) on my Linux Box (Linux 2.0.30,
> PPro200, 64MB, libc.so.5.4.17) I get severe problems, with FFI CALL-INs.
> The following code is a minimal example to reproduce the error:
> [excellent, reproducible code snipped]
Thank you very much for this minimal example. It's a bug, affecting
the CALL-INs on all platforms with special register usage: hppa,
alpha, m88k, arm and now also i386.
Below is a fix. Please apply patch1 and patch2 if you have got the clisp
source, patch1 and patch3 if you have the i386-linux-elf binaries.
> Another question:
> I am writing some kind of daemon using clisp. It uses the ffi a
> lot (mySQL interface, tcpip interface etc.) and it would be very
> helpful, if there was a way to deal with SIGSEGVs within clisp
> (do a restart e.g.). Is there a "canonical" way to do this?
Please do not do this normally. SIGSEGVs within CLISP should not occur,
and if they occur please make sure that this mailing list gets notified.
Otherwise the bugs will never get fixed. But if you want to chase bugs
outside clisp (i.e. in your mySQL interface or tcp/ip interface etc.), you
are welcome to put a breakpoint or hook at the function
`sigsegv_handler_failed' in spvw.d.
Bruno
begin 644 patch1.gz
M'XL(",:X\3,"`W!A=&-H,0#54TU/PS`,/;-?88;0DK*P=F4;V4X[@A`7#AQ1
MEJ:E(DU+FH(`L=].LJT=^P#M"):2U):?[;S7>)X'7*9E00)*1\2_)/ZH5VK>
MBW,MTD0%Y[(LCNXJ!==V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