官术网_书友最值得收藏!

Control registers

Processors based on the Intel architecture have a set of control registers that are used for configuration of the processor at run time (such as switching between execution modes). These registers are 32-bit wide on x86 and 64-bit wide on AMD64 (long mode).

There are six control registers and one Extended Feature Enable Register (EFER):

  • CR0: This register contains various control flags that modify the basic operation of the processor.
  • CR1: This register is reserved for future use.
  • CR2: This register contains the Page Fault Linear Address when a page fault occurs.
  • CR3: This register is used when virtual addressing is enabled (paging) and contains the physical address of the page directory, page directory pointer table, or page map level 4 table, depending on the current mode of operation.
  • CR4: This register is used in the protected mode for controlling different options of the processor.
  • CR8: This register is new and is only available in long mode. It is used for prioritization of external interrupts.
  • EFER: This register is one of the several model-specific registers. It is used for enabling/disabling SYSCALL/SYSRET instructions, entering/exiting long mode, and a few other features. Other model-specific registers are of no interest for us.

However, these registers are not accessible in ring3 (user land).

主站蜘蛛池模板: 循化| 阿尔山市| 新密市| 安庆市| 金沙县| 鄂托克前旗| 日照市| 枣庄市| 延安市| 乳源| 鸡泽县| 张家口市| 安化县| 上蔡县| 福州市| 阿城市| 青田县| 固安县| 洪洞县| 区。| 中西区| 合川市| 瓦房店市| 黑河市| 且末县| 大兴区| 红安县| 凌海市| 临洮县| 土默特右旗| 特克斯县| 琼海市| 吴堡县| 鄂伦春自治旗| 和政县| 松江区| 辉县市| 广宁县| 永平县| 石柱| 鹿邑县|