all the sparc64 register window handling code is in the src/sys/arch/sparc64 directory, along with the rest of the sparc64 MD code. traps are mostly handled in locore.s and trap.c. register windows are handled in locore.s. interrupts are initially handled in locore.s and then handed off elsewhere. hope this helps,