background image

38-8 Vol. 3D

ENCLAVE ACCESS CONTROL AND DATA STRUCTURES

38.9.1 GPRSGX 

Region

The layout of the GPRSGX region is shown in Table 38-8.

38.9.1.1   EXITINFO

EXITINFO contains the information used to report exit reasons to software inside the enclave. It is a 4 byte field laid 
out as in Table 38-9. The VALID bit is set only for the exceptions conditions which are reported inside an enclave. 
See Table 38-10 for which exceptions are reported inside the enclave. If the exception condition is not one reported 
inside the enclave then VECTOR and EXIT_TYPE are cleared.

Table 38-8.  Layout of GPRSGX Portion of the State Save Area

Field

OFFSET (Bytes) Size (Bytes)

Description

RAX

0

8

RCX

8

8

RDX

16

8

RBX

24

8

RSP

32

8

RBP

40

8

RSI

48

8

RDI

56

8

R8

64

8

R9

72

8

R10

80

8

R11

88

8

R12

96

8

R13

104

8

R14

112

8

R15

120

8

RFLAGS

128

8

Flag register.

RIP

136

8

Instruction pointer.

URSP

144

8

Non-Enclave (outside) stack pointer. Saved by EENTER, restored on AEX.

URBP

152

8

Non-Enclave (outside) RBP pointer. Saved by EENTER, restored on AEX.

EXITINFO

160

4

Contains information about exceptions that cause AEXs, which might be 

needed by enclave software (see Section 38.9.1.1).

RESERVED

164

4

FSBASE

168

8

FS BASE.

GSBASE

176

8

GS BASE.