From owner-freebsd-alpha Thu Feb 24 8:58:59 2000 Delivered-To: freebsd-alpha@freebsd.org Received: from wall.polstra.com (rtrwan160.accessone.com [206.213.115.74]) by hub.freebsd.org (Postfix) with ESMTP id 108E737BBBE for ; Thu, 24 Feb 2000 08:58:56 -0800 (PST) (envelope-from jdp@polstra.com) Received: from vashon.polstra.com (vashon.polstra.com [206.213.73.13]) by wall.polstra.com (8.9.3/8.9.3) with ESMTP id IAA01627; Thu, 24 Feb 2000 08:58:55 -0800 (PST) (envelope-from jdp@polstra.com) From: John Polstra Received: (from jdp@localhost) by vashon.polstra.com (8.9.3/8.9.1) id IAA39924; Thu, 24 Feb 2000 08:58:54 -0800 (PST) (envelope-from jdp@polstra.com) Date: Thu, 24 Feb 2000 08:58:54 -0800 (PST) Message-Id: <200002241658.IAA39924@vashon.polstra.com> To: dfr@nlsystems.com Subject: Re: pcb_onfault bug on alpha? In-Reply-To: References: Organization: Polstra & Co., Seattle, WA Cc: alpha@freebsd.org Sender: owner-freebsd-alpha@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On a related topic, do you have any idea why they did all this ".set noat" nonsense in copyout instead of simply using t0 to set pcb_onfault as is done elsewhere? I can't see any reason why they'd need to preserve t0 at this point. NESTED(copyout, 3, 16, ra, 0, 0) LDGP(pv) lda sp, -16(sp) /* set up stack frame */ stq ra, (16-8)(sp) /* save ra */ ldiq t0, VM_MAXUSER_ADDRESS /* make sure that dest addr */ cmpult a1, t0, t1 /* is in user space. */ beq t1, copyerr /* if it's not, error out. */ lda v0, copyerr /* set up fault handler. */ .set noat ldq at_reg, curproc ldq at_reg, P_ADDR(at_reg) stq v0, U_PCB_ONFAULT(at_reg) .set at CALL(bcopy) /* do the copy. */ .set noat ldq at_reg, curproc /* kill the fault handler. */ ldq at_reg, P_ADDR(at_reg) stq zero, U_PCB_ONFAULT(at_reg) .set at ldq ra, (16-8)(sp) /* restore ra. */ lda sp, 16(sp) /* kill stack frame. */ mov zero, v0 /* return 0. */ RET END(copyout) John -- John Polstra jdp@polstra.com John D. Polstra & Co., Inc. Seattle, Washington USA "Disappointment is a good sign of basic intelligence." -- Chögyam Trungpa To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-alpha" in the body of the message