Check whether we need to do a full restore after handling ASTs. If

an AST results in a signal being delivered, we'll need to do a full register
restore so as to properly setup the signal handler.  This is somewhat of
a pessimization, because ast() will be called twice in this case.

This fixes several problems that have been reported where signal intensive
userland apps (most notably dump) have been SEGV'ing for no fault of their
own.

Thanks to Peter Jeremy <peter.jeremy@alcatel.com.au> for presenting the
AST scenario which led to me fiinally figuring this out.

Reviewed by: jhb
This commit is contained in:
Andrew Gallatin 2001-03-28 01:19:41 +00:00
parent 3cd4410688
commit 919eea6db9

View File

@ -130,15 +130,15 @@
XentSys1: LDGP(pv)
CALL(syscall)
/* Handle any AST's. */
mov sp, a0 /* only arg is frame */
CALL(ast)
/* see if we need a full exception_return */
ldq t1, (FRAME_FLAGS*8)(sp)
and t1, FRAME_FLAGS_SYSCALL
beq t1, exception_return
/* Handle any AST's. */
mov sp, a0 /* only arg is frame */
CALL(ast)
/* set the hae register if this process has specified a value */
ldq t0, GD_CURPROC(globalp)
beq t0, 3f