1 /* $NetBSD: fpu.h,v 1.6 2014/02/25 22:16:52 dsl Exp $ */
6 #include <x86/cpu_extended_state.h>
14 void fpuinit(struct cpu_info
*);
15 void fpusave_lwp(struct lwp
*, bool);
16 void fpusave_cpu(bool);
18 void fpu_set_default_cw(struct lwp
*, unsigned int);
20 void fputrap(struct trapframe
*);
21 void fpudna(struct trapframe
*);
23 void process_xmm_to_s87(const struct fxsave
*, struct save87
*);
24 void process_s87_to_xmm(const struct save87
*, struct fxsave
*);
26 /* Set all to defaults (eg during exec) */
27 void fpu_save_area_clear(struct lwp
*, unsigned int);
28 /* Reset control words only - for signal handlers */
29 void fpu_save_area_reset(struct lwp
*);
31 /* Copy data outside pcb during fork */
32 void fpu_save_area_fork(struct pcb
*, const struct pcb
*);
34 /* Load FP registers with user-supplied values */
35 void process_write_fpregs_xmm(struct lwp
*lwp
, const struct fxsave
*fpregs
);
36 void process_write_fpregs_s87(struct lwp
*lwp
, const struct save87
*fpregs
);
38 /* Save FP registers for copy to userspace */
39 void process_read_fpregs_xmm(struct lwp
*lwp
, struct fxsave
*fpregs
);
40 void process_read_fpregs_s87(struct lwp
*lwp
, struct save87
*fpregs
);
44 #endif /* _X86_FPU_H_ */