Review for libpthread support

Daniel Eischen eischen at vigrid.com
Sun Oct 5 09:21:32 PDT 2003


Hi guys,

I have a patch for adding libpthread support for sparc64.  It's jake's
patch, with a few mods by myself.  I'd like for some folks to look it
over.  I haven't tested it; I need a couple of questions answered
first so I can fill in a missing piece.

  o Can someone look at the end of __thr_getcontext (line 524 of
    the patch)?  I need to test %i2 for NULL and branch to 1 if true.

	+/*	bz	%i2, 1f */
	+	stx	%i1, [%i2]
	+1:	ldx	[%sp], %i1			/* restore %i1 */
	+	ldx	[%sp + 8], %i2			/* restore %i2 */

    What's the magic instruction I should use?

  o Can someone look over the context saving/restoring in general?
    I have a feeling there should be more to __thr_getcontext than
    there is.

The patch is at:

  http://people.freebsd.org/~deischen/kse/libpthread_sparc64.diffs

I'm not subscribed to this list, so please keep me on the CC.

Thanks,

-- 
Dan Eischen



More information about the freebsd-sparc64 mailing list