+#if defined(tahoe)
+ /* move this to cpu_exit */
+ p->p_addr->u_pcb.pcb_savacc.faddr = (float *)NULL;
+#endif
+ /*
+ * Clear curproc after we've done all operations
+ * that could block, and before tearing down the rest
+ * of the process state that might be used from clock, etc.
+ * Also, can't clear curproc while we're still runnable,
+ * as we're not on a run queue (we are current, just not
+ * a proper proc any longer!).
+ *
+ * Other substructures are freed from wait().
+ */
+ curproc = NULL;
+ if (--p->p_limit->p_refcnt == 0)
+ FREE(p->p_limit, M_SUBPROC);
+
+ /*
+ * Finally, call machine-dependent code to release the remaining
+ * resources including address space, the kernel stack and pcb.
+ * The address space is released by "vmspace_free(p->p_vmspace)";
+ * This is machine-dependent, as we may have to change stacks
+ * or ensure that the current one isn't reallocated before we
+ * finish. cpu_exit will end with a call to cpu_swtch(), finishing
+ * our execution (pun intended).
+ */
+ cpu_exit(p);
+ /* NOTREACHED */