Index: kernel/arch/sparc64/src/trap/trap_table.S
===================================================================
--- kernel/arch/sparc64/src/trap/trap_table.S	(revision 4ee4046e33acd575f0fc5f064a7d5d665238ef63)
+++ kernel/arch/sparc64/src/trap/trap_table.S	(revision 577b531c31f06ba14573dcf44830503f428e4120)
@@ -479,5 +479,5 @@
 	rdpr %tl, %g3
 	cmp %g3, 1
-	be 1f
+	be %xcc, 1f
 	nop
 0:	ba 0b					! this is for debugging, if we ever get here
@@ -500,5 +500,5 @@
 
 	andcc %g3, TSTATE_PRIV_BIT, %g0		! if this trap came from the privileged mode...
-	bnz 0f					! ...skip setting of kernel stack and primary context
+	bnz %xcc, 0f				! ...skip setting of kernel stack and primary context
 	nop
 	
@@ -673,5 +673,5 @@
 	rdpr %cwp, %l1
 	cmp %l0, %l1
-	bz 0f				! CWP is ok
+	bz %xcc, 0f			! CWP is ok
 	nop
 
@@ -713,5 +713,5 @@
 	rdpr %tstate, %g1
 	andcc %g1, TSTATE_PRIV_BIT, %g0		! if we are not returning to userspace...,
-	bnz 1f					! ...skip restoring userspace windows
+	bnz %xcc, 1f				! ...skip restoring userspace windows
 	nop
 .endif
@@ -750,5 +750,5 @@
 	clr %g4
 0:	andcc %g7, UWB_ALIGNMENT - 1, %g0	! alignment check
-	bz 0f					! %g7 is UWB_ALIGNMENT-aligned, no more windows to refill
+	bz %xcc, 0f				! %g7 is UWB_ALIGNMENT-aligned, no more windows to refill
 	nop
 
@@ -786,5 +786,5 @@
 	add %g4, %g2, %g2
 	cmp %g2, NWINDOWS - 2
-	bg 2f					! fix the CANRESTORE=NWINDOWS-1 anomaly
+	bg %xcc, 2f				! fix the CANRESTORE=NWINDOWS-1 anomaly
 	mov NWINDOWS - 2, %g1			! use dealy slot for both cases
 	sub %g1, %g2, %g1
