VirtualBox

source: vbox/trunk/include/iprt/x86extra.mac@ 98463

Last change on this file since 98463 was 98103, checked in by vboxsync, 23 months ago

Copyright year updates by scm.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 6.6 KB
Line 
1;; @file
2; IPRT - X86 and AMD64 Structures and Definitions that are not automatically
3; converted from the C header file.
4;
5
6;
7; Copyright (C) 2012-2023 Oracle and/or its affiliates.
8;
9; This file is part of VirtualBox base platform packages, as
10; available from https://www.virtualbox.org.
11;
12; This program is free software; you can redistribute it and/or
13; modify it under the terms of the GNU General Public License
14; as published by the Free Software Foundation, in version 3 of the
15; License.
16;
17; This program is distributed in the hope that it will be useful, but
18; WITHOUT ANY WARRANTY; without even the implied warranty of
19; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20; General Public License for more details.
21;
22; You should have received a copy of the GNU General Public License
23; along with this program; if not, see <https://www.gnu.org/licenses>.
24;
25; The contents of this file may alternatively be used under the terms
26; of the Common Development and Distribution License Version 1.0
27; (CDDL), a copy of it is provided in the "COPYING.CDDL" file included
28; in the VirtualBox distribution, in which case the provisions of the
29; CDDL are applicable instead of those of the GPL.
30;
31; You may elect to license modified versions of this file under the
32; terms and conditions of either the GPL or the CDDL or both.
33;
34; SPDX-License-Identifier: GPL-3.0-only OR CDDL-1.0
35;
36
37%ifndef ___iprt_x86extra_mac
38%define ___iprt_x86extra_mac
39
40
41%define X86_XCPT_DE 0x00
42%define X86_XCPT_DB 0x01
43%define X86_XCPT_NMI 0x02
44%define X86_XCPT_BP 0x03
45%define X86_XCPT_OF 0x04
46%define X86_XCPT_BR 0x05
47%define X86_XCPT_UD 0x06
48%define X86_XCPT_NM 0x07
49%define X86_XCPT_DF 0x08
50%define X86_XCPT_CO_SEG_OVERRUN 0x09
51%define X86_XCPT_TS 0x0a
52%define X86_XCPT_NP 0x0b
53%define X86_XCPT_SS 0x0c
54%define X86_XCPT_GP 0x0d
55%define X86_XCPT_PF 0x0e
56%define X86_XCPT_MF 0x10
57%define X86_XCPT_AC 0x11
58%define X86_XCPT_MC 0x12
59%define X86_XCPT_XF 0x13
60%define X86_XCPT_VE 0x14
61%define X86_XCPT_SX 0x1f
62
63%define PAGE_SIZE 0x1000
64
65;; Same a ~(X86_CR0_PE | X86_CR0_PG) except it won't cause assembler warnings.
66%define X86_CR0_NO_PE_NO_PG 0x7ffffffe
67
68
69
70;;
71; 32-bit protected mode fstenv image.
72;
73struc X86FSTENV32P
74 .FCW resw 1
75 .padding1 resw 1
76 .FSW resw 1
77 .padding2 resw 1
78 .FTW resw 1
79 .padding3 resw 1
80 .FPUIP resd 1
81 .FPUCS resw 1
82 .FOP resw 1
83 .FPUDP resd 1
84 .FPUDS resw 1
85 .padding4 resw 1
86endstruc
87
88
89;;
90; The image saved by FXSAVE.
91;
92struc X86FXSTATE
93 .FCW resw 1
94 .FSW resw 1
95 .FTW resw 1
96 .FOP resw 1
97 .FPUIP resd 1
98 .FPUCS resw 1
99 .Rsrvd1 resw 1
100 .FPUDP resd 1
101 .FPUDS resw 1
102 .Rsrvd2 resw 1
103 .MXCSR resd 1
104 .MXCSR_MASK resd 1
105 .st0 resd 4
106 .st1 resd 4
107 .st2 resd 4
108 .st3 resd 4
109 .st4 resd 4
110 .st5 resd 4
111 .st6 resd 4
112 .st7 resd 4
113 .xmm0 resd 4
114 .xmm1 resd 4
115 .xmm2 resd 4
116 .xmm3 resd 4
117 .xmm4 resd 4
118 .xmm5 resd 4
119 .xmm6 resd 4
120 .xmm7 resd 4
121 .xmm8 resd 4
122 .xmm9 resd 4
123 .xmm10 resd 4
124 .xmm11 resd 4
125 .xmm12 resd 4
126 .xmm13 resd 4
127 .xmm14 resd 4
128 .xmm15 resd 4
129 .au32RsrvdRest resd 24
130endstruc
131
132
133struc X86TSS16
134 .selPrev resw 1
135 .sp0 resw 1
136 .ss0 resw 1
137 .sp1 resw 1
138 .ss1 resw 1
139 .sp2 resw 1
140 .ss2 resw 1
141 .ip resw 1
142 .flags resw 1
143 .ax resw 1
144 .cx resw 1
145 .dx resw 1
146 .bx resw 1
147 .sp resw 1
148 .bp resw 1
149 .si resw 1
150 .di resw 1
151 .es resw 1
152 .cs resw 1
153 .ss resw 1
154 .ds resw 1
155 .selLdt resw 1
156endstruc
157AssertCompileSize(X86TSS16, 44)
158
159
160struc X86TSS32
161 .selPrev resw 1
162 .padding1 resw 1
163 .esp0 resd 1
164 .ss0 resw 1
165 .padding_ss0 resw 1
166 .esp1 resd 1
167 .ss1 resw 1
168 .padding_ss1 resw 1
169 .esp2 resd 1
170 .ss2 resw 1
171 .padding_ss2 resw 1
172 .cr3 resd 1
173 .eip resd 1
174 .eflags resd 1
175 .eax resd 1
176 .ecx resd 1
177 .edx resd 1
178 .ebx resd 1
179 .esp resd 1
180 .ebp resd 1
181 .esi resd 1
182 .edi resd 1
183 .es resw 1
184 .padding_es resw 1
185 .cs resw 1
186 .padding_cs resw 1
187 .ss resw 1
188 .padding_ss resw 1
189 .ds resw 1
190 .padding_ds resw 1
191 .fs resw 1
192 .padding_fs resw 1
193 .gs resw 1
194 .padding_gs resw 1
195 .selLdt resw 1
196 .padding_ldt resw 1
197 .fDebugTrap resw 1
198 .offIoBitmap resw 1
199 ;.IntRedirBitmap resb 32 - this is optional.
200endstruc
201AssertCompileSize(X86TSS32,104)
202
203
204struc X86TSS64
205 .u32Reserved resd 1
206 .rsp0 resq 1
207 .rsp1 resq 1
208 .rsp2 resq 1
209 .u32Reserved2 resd 2
210 .ist1 resq 1
211 .ist2 resq 1
212 .ist3 resq 1
213 .ist4 resq 1
214 .ist5 resq 1
215 .ist6 resq 1
216 .ist7 resq 1
217 .u16Reserved resw 5
218 .offIoBitmap resw 1
219 ;.IntRedirBitmap resb 32 - this isn't really there!! VBox addition for x86TSS32 structure compatibility in x86.h.
220endstruc
221AssertCompileSize(X86TSS64, 104)
222
223
224%endif
225
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette