Hand-align the fxsave area to be able to determine its offset in structures
more precisely.
This commit is contained in:
parent
6857cedfef
commit
4ddf293c2e
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: fpu.h,v 1.4 2002/07/06 10:43:32 fvdl Exp $ */
|
||||
/* $NetBSD: fpu.h,v 1.5 2002/07/10 01:54:00 fvdl Exp $ */
|
||||
|
||||
#ifndef _X86_64_FPU_H_
|
||||
#define _X86_64_FPU_H_
|
||||
@ -7,6 +7,7 @@
|
||||
* NetBSD/x86_64 only uses the extended save/restore format used
|
||||
* by fxsave/fsrestore, to always deal with the SSE registers,
|
||||
* which are part of the ABI to pass floating point values.
|
||||
* Must be stored in memory on a 16-byte boundary.
|
||||
*/
|
||||
|
||||
struct fxsave64 {
|
||||
@ -22,7 +23,7 @@ struct fxsave64 {
|
||||
/*BITFIELDTYPE*/ u_int64_t fx_st[8 * 2]; /* 8 normal FP regs */
|
||||
/*BITFIELDTYPE*/ u_int64_t fx_xmm[16 * 2]; /* 16 SSE2 registers */
|
||||
/*BITFIELDTYPE*/ u_int8_t fx_unused3[96];
|
||||
} __attribute__ ((aligned (16)));
|
||||
};
|
||||
|
||||
struct savefpu {
|
||||
struct fxsave64 fp_fxsave; /* see above */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pcb.h,v 1.4 2002/06/12 19:13:27 fvdl Exp $ */
|
||||
/* $NetBSD: pcb.h,v 1.5 2002/07/10 01:54:00 fvdl Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1998 The NetBSD Foundation, Inc.
|
||||
@ -90,6 +90,10 @@
|
||||
|
||||
#define NIOPORTS 1024 /* # of ports we allow to be mapped */
|
||||
|
||||
/*
|
||||
* Please note that the pcb_savefpu field in struct below must be
|
||||
* on a 16-byte boundary.
|
||||
*/
|
||||
struct pcb {
|
||||
/*
|
||||
* XXXfvdl
|
||||
@ -105,8 +109,8 @@ struct pcb {
|
||||
u_int64_t pcb_rbp;
|
||||
u_int64_t pcb_usersp;
|
||||
u_int64_t pcb_ldt_sel;
|
||||
int pcb_cr0; /* saved image of CR0 */
|
||||
struct savefpu pcb_savefpu; /* floating point state */
|
||||
int pcb_cr0; /* saved image of CR0 */
|
||||
int pcb_flags;
|
||||
#define PCB_USER_LDT 0x01 /* has user-set LDT */
|
||||
caddr_t pcb_onfault; /* copyin/out fault recovery */
|
||||
|
Loading…
Reference in New Issue
Block a user