1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-18 10:35:55 +00:00

Add a soft trap for restoring the fpu registers from the pcb.

This commit is contained in:
Jake Burkholder 2002-01-01 20:15:39 +00:00
parent f264c6fbf8
commit cee5e561b6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=88780
2 changed files with 24 additions and 0 deletions

View File

@ -361,6 +361,18 @@
.endr .endr
.endm .endm
.macro tl0_fp_restore
wr %g0, FPRS_FEF, %fprs
wr %g0, ASI_BLK_S, %asi
ldda [PCB_REG + PCB_FPSTATE + FP_FB0] %asi, %f0
ldda [PCB_REG + PCB_FPSTATE + FP_FB1] %asi, %f16
ldda [PCB_REG + PCB_FPSTATE + FP_FB2] %asi, %f32
ldda [PCB_REG + PCB_FPSTATE + FP_FB3] %asi, %f48
membar #Sync
done
.align 32
.endm
.macro tl0_insn_excptn .macro tl0_insn_excptn
wr %g0, ASI_IMMU, %asi wr %g0, ASI_IMMU, %asi
rdpr %tpc, %g3 rdpr %tpc, %g3

View File

@ -361,6 +361,18 @@
.endr .endr
.endm .endm
.macro tl0_fp_restore
wr %g0, FPRS_FEF, %fprs
wr %g0, ASI_BLK_S, %asi
ldda [PCB_REG + PCB_FPSTATE + FP_FB0] %asi, %f0
ldda [PCB_REG + PCB_FPSTATE + FP_FB1] %asi, %f16
ldda [PCB_REG + PCB_FPSTATE + FP_FB2] %asi, %f32
ldda [PCB_REG + PCB_FPSTATE + FP_FB3] %asi, %f48
membar #Sync
done
.align 32
.endm
.macro tl0_insn_excptn .macro tl0_insn_excptn
wr %g0, ASI_IMMU, %asi wr %g0, ASI_IMMU, %asi
rdpr %tpc, %g3 rdpr %tpc, %g3