/freebsd/sys/arm64/arm64/ |
H A D | vfp.c | 676 struct pcb *curpcb; in vfp_restore_state_common() local 686 curpcb = td->td_pcb; in vfp_restore_state_common() 694 if ((curpcb->pcb_fpflags & PCB_FP_SVEVALID) != 0 && in vfp_restore_state_common() 695 curpcb->pcb_fpusaved == &curpcb->pcb_fpustate) { in vfp_restore_state_common() 696 MPASS(curpcb->pcb_svesaved != NULL); in vfp_restore_state_common() 703 MPASS((curpcb->pcb_fpflags & PCB_FP_SVEVALID) != 0); in vfp_restore_state_common() 706 curpcb->pcb_fpflags |= PCB_FP_STARTED; in vfp_restore_state_common() 715 if (PCPU_GET(fpcurthread) != curthread || cpu != curpcb->pcb_vfpcpu) { in vfp_restore_state_common() 729 curpcb->pcb_vfpcpu = cpu; in vfp_restore_state_common() 747 struct pcb *curpcb; in sve_restore_state() local [all …]
|
H A D | exec_machdep.c | 584 struct pcb *curpcb; in get_fpcontext() local 588 curpcb = curthread->td_pcb; in get_fpcontext() 589 if ((curpcb->pcb_fpflags & PCB_FP_STARTED) != 0) { in get_fpcontext() 594 vfp_save_state(td, curpcb); in get_fpcontext() 597 KASSERT(curpcb->pcb_fpusaved == &curpcb->pcb_fpustate, in get_fpcontext() 599 KASSERT((curpcb->pcb_fpflags & ~PCB_FP_USERMASK) == 0, in get_fpcontext() 601 memcpy(mcp->mc_fpregs.fp_q, curpcb->pcb_fpustate.vfp_regs, in get_fpcontext() 603 mcp->mc_fpregs.fp_cr = curpcb->pcb_fpustate.vfp_fpcr; in get_fpcontext() 604 mcp->mc_fpregs.fp_sr = curpcb->pcb_fpustate.vfp_fpsr; in get_fpcontext() 605 mcp->mc_fpregs.fp_flags = curpcb->pcb_fpflags; in get_fpcontext() [all …]
|
H A D | pmap.c | 9047 PCPU_SET(curpcb, pcb); in pmap_switch()
|
/freebsd/sys/riscv/riscv/ |
H A D | exec_machdep.c | 267 struct pcb *curpcb; in get_fpcontext() local 271 curpcb = curthread->td_pcb; in get_fpcontext() 273 KASSERT(td->td_pcb == curpcb, ("Invalid fpe pcb")); in get_fpcontext() 275 if ((curpcb->pcb_fpflags & PCB_FP_STARTED) != 0) { in get_fpcontext() 282 KASSERT((curpcb->pcb_fpflags & ~PCB_FP_USERMASK) == 0, in get_fpcontext() 284 memcpy(mcp->mc_fpregs.fp_x, curpcb->pcb_x, in get_fpcontext() 286 mcp->mc_fpregs.fp_fcsr = curpcb->pcb_fcsr; in get_fpcontext() 287 mcp->mc_fpregs.fp_flags = curpcb->pcb_fpflags; in get_fpcontext() 297 struct pcb *curpcb; in set_fpcontext() local 305 curpcb = curthread->td_pcb; in set_fpcontext() [all …]
|
/freebsd/sys/arm/arm/ |
H A D | vfp.c | 209 struct pcb *curpcb; in vfp_bounce() local 245 curpcb = curthread->td_pcb; in vfp_bounce() 247 (curpcb->pcb_fpflags & PCB_FP_KERN) == 0) { in vfp_bounce() 259 if (curpcb->pcb_vfpcpu != cpu || curthread != PCPU_GET(fpcurthread)) { in vfp_bounce() 260 vfp_restore(curpcb->pcb_vfpsaved); in vfp_bounce() 261 curpcb->pcb_vfpcpu = cpu; in vfp_bounce() 268 curpcb->pcb_vfpsaved == &curpcb->pcb_vfpstate, in vfp_bounce() 543 struct pcb *curpcb; in is_fpu_kern_thread() local 547 curpcb = curthread->td_pcb; in is_fpu_kern_thread() 548 return ((curpcb->pcb_fpflags & PCB_FP_KERN) != 0); in is_fpu_kern_thread()
|
/freebsd/sys/i386/i386/ |
H A D | trap.c | 292 (curpcb->pcb_flags & PCB_VM86CALL) == 0) in trap() 307 if (TRAPF_USERMODE(frame) && (curpcb->pcb_flags & PCB_VM86CALL) == 0) { in trap() 524 if (curpcb->pcb_flags & PCB_VM86CALL) in trap() 537 curpcb->pcb_gs = 0; in trap() 594 if (curpcb->pcb_onfault != NULL) { in trap() 595 frame->tf_eip = (int)curpcb->pcb_onfault; in trap() 633 !(curpcb->pcb_flags & PCB_VM86CALL)) in trap() 874 curpcb->pcb_onfault != NULL) { in trap_pfault() 875 frame->tf_eip = (int)curpcb->pcb_onfault; in trap_pfault() 1131 (curpcb->pcb_flags & PCB_VM86CALL) == 0)) { in syscall()
|
H A D | npx.c | 532 fpusave(curpcb->pcb_save); in npxexit() 856 KASSERT((curpcb->pcb_flags & PCB_NPXNOSAVE) == 0, in npxdna() 1418 fpusave(curpcb->pcb_save); in fpu_kern_enter() 1508 KASSERT(curpcb->pcb_save == get_pcb_user_save_pcb(curpcb), in fpu_kern_thread() 1510 KASSERT(PCB_USER_FPU(curpcb), ("recursive call")); in fpu_kern_thread() 1512 curpcb->pcb_flags |= PCB_KERNNPX | PCB_KERNNPX_THR; in fpu_kern_thread() 1522 return ((curpcb->pcb_flags & PCB_KERNNPX_THR) != 0); in is_fpu_kern_thread()
|
H A D | vm86.c | 193 if (curpcb->pcb_ext == 0) in vm86_emulate() 195 vm86 = &curpcb->pcb_ext->ext_vm86; in vm86_emulate() 667 vm86 = &curpcb->pcb_ext->ext_vm86; in vm86_prepcall()
|
H A D | machdep.c | 1580 PCPU_SET(curpcb, thread0.td_pcb); in init386()
|
H A D | exec_machdep.c | 904 if (pcb == curpcb) { in x86_clear_dbregs()
|
/freebsd/sys/amd64/amd64/ |
H A D | fpu.c | 497 fpusave(curpcb->pcb_save); in fpuexit() 713 pcb_save = curpcb->pcb_save; in fputrap_x87() 732 mxcsr = curpcb->pcb_save->sv_env.en_mxcsr; in fputrap_sse() 802 KASSERT((curpcb->pcb_flags & PCB_FPUNOSAVE) == 0, in fpudna() 1166 fpusave(curpcb->pcb_save); in fpu_kern_enter() 1256 KASSERT(curpcb->pcb_save == get_pcb_user_save_pcb(curpcb), in fpu_kern_thread() 1258 KASSERT(PCB_USER_FPU(curpcb), ("recursive call")); in fpu_kern_thread() 1260 set_pcb_flags(curpcb, PCB_KERNFPU | PCB_KERNFPU_THR); in fpu_kern_thread() 1270 return ((curpcb->pcb_flags & PCB_KERNFPU_THR) != 0); in is_fpu_kern_thread()
|
H A D | trap.c | 433 curpcb->pcb_onfault != NULL && type != T_PAGEFLT) { in trap() 436 frame->tf_rip = (long)curpcb->pcb_onfault; in trap() 514 if (curpcb->pcb_onfault != NULL) { in trap() 515 frame->tf_rip = (long)curpcb->pcb_onfault; in trap() 688 (curpcb->pcb_saved_ucr3 & ~CR3_PCID_MASK) == in trap_is_pti() 789 trap_is_smap(frame) || curpcb->pcb_onfault == NULL)) { in trap_pfault() 861 curpcb->pcb_onfault != NULL) { in trap_pfault() 866 frame->tf_rip = (long)curpcb->pcb_onfault; in trap_pfault()
|
H A D | machdep.c | 1213 PCPU_SET(curpcb, thread0.td_pcb); in amd64_bsp_pcpu_init2() 1787 if (curpcb == pcb && in set_pcb_flags_fsgsbase()
|
H A D | exec_machdep.c | 354 if (pcb == curpcb) { in x86_clear_dbregs()
|
/freebsd/sys/powerpc/include/ |
H A D | pcb.h | 126 #ifndef curpcb 127 extern struct pcb *curpcb;
|
/freebsd/sys/powerpc/powerpc/ |
H A D | fpu.c | 377 struct pcb *curpcb; in is_fpu_kern_thread() local 381 curpcb = curthread->td_pcb; in is_fpu_kern_thread() 382 return ((curpcb->pcb_flags & PCB_KERN_FPU) != 0); in is_fpu_kern_thread()
|
/freebsd/sys/amd64/include/ |
H A D | pcpu_aux.h | 62 #define curpcb (&curthread->td_md.md_pcb) macro
|
/freebsd/sys/i386/include/ |
H A D | pcpu_aux.h | 67 #define curpcb (__curpcb()) macro
|
/freebsd/sys/contrib/openzfs/include/os/freebsd/spl/sys/ |
H A D | simd_x86.h | 53 if (__predict_false(curpcb->pcb_flags & PCB_FPUNOSAVE)) \
|
/freebsd/sys/amd64/vmm/intel/ |
H A D | vmx_msr.c | 346 update_pcb_bases(curpcb); in vmx_msr_guest_enter()
|
/freebsd/sys/powerpc/aim/ |
H A D | aim_machdep.c | 797 PCPU_SET(curpcb, curthread->td_pcb); in mpc745x_sleep()
|
/freebsd/sys/amd64/vmm/ |
H A D | vmm.c | 1571 pcb = PCPU_GET(curpcb); in vm_run()
|