Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 29 Apr 2000 13:21:51 -0500 (CDT)
From:      Steve Price <sprice@hiwaay.net>
To:        Doug Rabson <dfr@nlsystems.com>
Cc:        freebsd-alpha@freebsd.org
Subject:   Re: need help porting JDK2 to alpha
Message-ID:  <Pine.OSF.4.21.0004291305380.18420-100000@fly.HiWAAY.net>
In-Reply-To: <Pine.BSF.4.21.0004241232400.62105-100000@salmon.nlsystems.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 24 Apr 2000, Doug Rabson wrote:

# You can initialise the pc by setting sc->sc_pc. What are death_func and
# arg used for? If these are intended to be arguments to some function
# located at *pc, you can initialise sc->sc_regs[R_A0..R-A5] with up to six
# argument values. If you need the function at *pc to return to some
# specific location, set sc->sc_regs[R_RA] to a suitable return address.

Oops, I was re-reading your response and just noticed there was
a question in there.  The idea is to setup the sigjmp_buf structure
so that on a call to siglongjmp the function death_func is called with
the arguments pc and arg.  The code I have now looks like this and
appears to almost work.

    uc->jmpbuf->_sjb[2]  = death_func;	/* sc_pc */
    uc->jmpbuf->_sjb[20] = pc;		/* sc_regs[R_A0] */
    uc->jmpbuf->_sjb[21] = arg;		/* sc_regs[R_A1] */
    uc->jmpbuf->_sjb[34] = sp;		/* sc_regs[R_SP] */
    uc->jmpbuf->_sjb[35] = 0xACEDBADD;  /* magic number for longjmp */

I don't think we need to set sc_regs[R_RA].

-steve



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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.OSF.4.21.0004291305380.18420-100000>