有RFLAGS 32-63位的内部描述吗?

问题描述 投票:0回答:1

搜索了Intel手册但找不到保留的

RFLAGS
32-63位的任何内部描述。

在此 godbolt 演示中,当在 64 位模式下执行时,输出显示

RFLAGS
寄存器的当前状态,其中位 32-63 设置为 0。

Bit 0  - Carry Flag (CF): 0
Bit 1  - Reserved, always 1 in EFLAGS: 1
Bit 2  - Parity Flag (PF): 0
Bit 3  - Reserved: 0
Bit 4  - Adjust Flag (AF): 0
Bit 5  - Reserved: 0
Bit 6  - Zero Flag (ZF): 0
Bit 7  - Sign Flag (SF): 0
Bit 8  - Trap Flag (TF): 0
Bit 9  - Interrupt-enable Flag (IF): 1
Bit 10 - Direction Flag (DF): 0
Bit 11 - Overflow Flag (OF): 0
Bit 12 - I/O Privilege Level (IOPL) - low bit: 0
Bit 13 - I/O Privilege Level (IOPL) - high bit: 0
Bit 14 - Nested Task (NT): 0
Bit 15 - Mode flag (MD) - Reserved: 0

Bit 16 - Resume Flag (RF): 0
Bit 17 - Virtual 8086 Mode (VM): 0
Bit 18 - Alignment Check/Access Control (AC): 0
Bit 19 - Virtual Interrupt Flag (VIF): 0
Bit 20 - Virtual Interrupt Pending (VIP): 0
Bit 21 - ID Flag (ID): 0
Bit 22 - Reserved: 0
Bit 23 - Reserved: 0
Bit 24 - Reserved: 0
Bit 25 - Reserved: 0
Bit 26 - Reserved: 0
Bit 27 - Reserved: 0
Bit 28 - Reserved: 0
Bit 29 - Reserved: 0
Bit 30 - AES key schedule loaded flag (none): 0
Bit 31 - Alternate Instruction Set (AI): 0

Bit 32 - Reserved: 0
Bit 33 - Reserved: 0
Bit 34 - Reserved: 0
Bit 35 - Reserved: 0
Bit 36 - Reserved: 0
Bit 37 - Reserved: 0
Bit 38 - Reserved: 0
Bit 39 - Reserved: 0
Bit 40 - Reserved: 0
Bit 41 - Reserved: 0
Bit 42 - Reserved: 0
Bit 43 - Reserved: 0
Bit 44 - Reserved: 0
Bit 45 - Reserved: 0
Bit 46 - Reserved: 0
Bit 47 - Reserved: 0
Bit 48 - Reserved: 0
Bit 49 - Reserved: 0
Bit 50 - Reserved: 0
Bit 51 - Reserved: 0
Bit 52 - Reserved: 0
Bit 53 - Reserved: 0
Bit 54 - Reserved: 0
Bit 55 - Reserved: 0
Bit 56 - Reserved: 0
Bit 57 - Reserved: 0
Bit 58 - Reserved: 0
Bit 59 - Reserved: 0
Bit 60 - Reserved: 0
Bit 61 - Reserved: 0
Bit 62 - Reserved: 0
Bit 63 - Reserved: 0
assembly x86-64 flags eflags
1个回答
0
投票

这些标志是保留的,并且始终为 0。目前会忽略向其中写入 1 - 无论如何它们都保持为零。这些标志有可能甚至不存在于硬件中。

最有可能的是,添加它们是为了在 CPU 以 64 位模式推送 RFLAGS 时保持堆栈 8 字节对齐。未来的 CPU 可能会发现这些位的用途,因此不鼓励将它们用于一些有趣的业务。

© www.soinside.com 2019 - 2024. All rights reserved.