Subject: Re: lwp_emuldata
To: Matt Thomas <email@example.com>
From: Emmanuel Dreyfus <firstname.lastname@example.org>
Date: 12/17/2003 13:34:36
Matt Thomas <email@example.com> wrote:
> > - call e_newlwp just before returning from newlwp
> Wouldn't e_lwp_fork be a better name since it corresponds to
Let's go for cpu_lwp_fork()
> > - call e_lwp_exit at the very beginning of lwp_exit (after the DPRINTF)
> There should also be a call to e_lwp_exit with the emulation before exec
> commits to execing a new program. (assume you run the OSX sh and then
> exec a NetBSD program, shouldn't the OSX emul data be removed?)
Maybe this could be handled from e_proc_exit? In e_proc_exit we would
call e_lwp_exit(proc_representative_lwp(p) to cleanup lwp_emuldata for
the last lwp.
And we can also say it is the responsability of e_proc_exec to cleanup
lwp_emuldata if this is nescessary when execing from the same emulation.
There is only one problem with this approach: if one day we have an
emulation that do not need emuldata but only lwp_emuldata, we will force
it to use proc hooks.
Il y a 10 sortes de personnes dans le monde: ceux qui comprennent
le binaire et ceux qui ne le comprennent pas.