I wrote:

> Hi Blackdown guys,

> But still a problem is preventing the RC3 from working
> with some JITs.

I am sorry. Blackdown JDK is not wrong at all.
I guessed wrong.

> But JDK 1.2.2 RC3 raises SIGSEGV after the
> signal handler returns. Therefore the JITs which utilize
> signals for exception handling don't work well with the RC3.

This was a problem related to LinuxThreads library.
LinuxThreads places two pieses of sigcontext (whose type
is sigcontext *) on stack. The signals.c contains the
following code.

  static void pthread_sighandler(int signo, SIGCONTEXT ctx)
  {
    ...
    sighandler[signo](signo, SIGCONTEXT_EXTRA_ARGS ctx);

A second argument to pthread_sighandler is the first
sigcontext supplied by kernel and the function places
the sigcontext onto stack again. If the JIT wants to
modify sigcontext and affect it, the former should be
modified, not the latter. My JIT modified the former
sigcontext and couldn't affect the sequent execution.

> It is unfortunate that the Blackdown team doesn't know
> requirements of JIT well.

For instance, JIT developers have a strong desire to get
sigcontext in the signal handler for JIT. I guess, JDK
doesn't pass sigcontext to a signal handler because
Linux 2.0 and libc5 can't pass it to the handler. But
most OSes and JDKs can do it.

Kazuyuki SHUDO                          Happy Hacking!
  Muraoka Lab., Grad. School of Sci. & Eng., Waseda Univ.


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to