fpu.h revision 1.18
1/* $NetBSD: fpu.h,v 1.18 2019/10/04 11:47:08 maxv Exp $ */ 2 3#ifndef _X86_FPU_H_ 4#define _X86_FPU_H_ 5 6#include <x86/cpu_extended_state.h> 7 8#ifdef _KERNEL 9 10struct cpu_info; 11struct lwp; 12struct trapframe; 13 14void fpuinit(struct cpu_info *); 15void fpuinit_mxcsr_mask(void); 16 17void fpu_area_save(void *, uint64_t); 18void fpu_area_restore(void *, uint64_t); 19 20void fpusave_lwp(struct lwp *, bool); 21void fpusave_cpu(bool); 22 23void fpu_set_default_cw(struct lwp *, unsigned int); 24 25void fputrap(struct trapframe *); 26void fpudna(struct trapframe *); 27 28void fpu_clear(struct lwp *, unsigned int); 29void fpu_sigreset(struct lwp *); 30 31void fpu_save_area_fork(struct pcb *, const struct pcb *); 32 33void process_write_fpregs_xmm(struct lwp *, const struct fxsave *); 34void process_write_fpregs_s87(struct lwp *, const struct save87 *); 35 36void process_read_fpregs_xmm(struct lwp *, struct fxsave *); 37void process_read_fpregs_s87(struct lwp *, struct save87 *); 38 39int process_read_xstate(struct lwp *, struct xstate *); 40int process_verify_xstate(const struct xstate *); 41int process_write_xstate(struct lwp *, const struct xstate *); 42 43#endif 44 45#endif /* _X86_FPU_H_ */ 46