Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 05 Sep 2002 23:12:55 +0100 (BST)
From:      Duncan Barclay <dmlb@dmlb.org>
To:        John E Hein <jhein@timing.com>
Cc:        emulation@FreeBSD.ORG
Subject:   Re: fix for Linux matlab exit behaviour - problem with linux_clo
Message-ID:  <XFMail.20020905231255.dmlb@computer.my.domain>
In-Reply-To: <15735.51083.489854.267762@brain.timing.com>

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

On 05-Sep-2002 John E Hein wrote:
> Duncan Barclay wrote at 21:55 +0100 on Sep  5:
>  > Please review the following PR for a hack to let matlab exit.
>  > 
>  >         http://www.freebsd.org/cgi/query-pr.cgi?pr=42457
>  > 
>  > The code in PR is deliberatly not a patch because it is not the right way
>  > to cleanly fix the problem.
>  > 
>  > The problem is that we do not fully emulate all of linux_clone(2)
> behaviour,
>  > in particular, linux_clone(2) allows a thread to not send a signal to
>  > its parent on exit. /sys/kern_exit.c does not allow this and will
>  > send a specified signal or SIGCHLD. Matlab has a SIGCHLD handler that
>  > does not reap threads. If the SIGCHLD is not sent, matlab reaps its last
>  > thread and exits cleanly.
> 
> Interesting... so why then does the /dev/ptmx -> /dev/null hack allow
>  us to exit matlab?
> 
Hmm, I forgot about that hack. I have no idea! Can you get a ktrace
of it exiting please, preferably after unsetting DISPLAY so that
X11 is turned off. Turning X11 off means that there is less cruft in the 
ktrace.

Otherwise, I'll take a look tomorrow.

Duncan

-- 
________________________________________________________________________
Duncan Barclay  | God smiles upon the little children,
dmlb@dmlb.org   | the alcoholics, and the permanently stoned.
dmlb@freebsd.org| Steven King

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




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