audk/UefiCpuPkg/Library/CpuExceptionHandlerLib/Ia32
Ray Ni 21a9b605b8 CpuException: Avoid allocating code pages for DXE instance
Today the DXE instance allocates code page and then copies the IDT
vectors to the allocated code page. Then it fixes up the vector number
in the IDT vector.

But if we update the NASM file to generate 256 IDT vectors, there is
no need to do the copy and fix-up.

A side effect is 4096 bytes (HOOKAFTER_STUB_SIZE * 256) is used for
256 IDT vectors while 32 IDT vectors only require 512 bytes without
this change, in following library instances:
1. 32bit SecPeiCpuExceptionHandlerLib and PeiCpuExceptionHandlerLib
2. 64bit PeiCpuExceptionHandlerLib

But considering the code logic simplification, 3.5K extra space is
not a big deal.
If 3.5K is too much, we can enhance the code further to generate 32
vectors for above mentioned library instances.

Signed-off-by: Ray Ni <ray.ni@intel.com>
Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
Acked-by: Eric Dong <eric.dong@intel.com>
2022-06-10 07:54:48 +00:00
..
ArchExceptionHandler.c UefiCpuPkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
ArchInterruptDefs.h UefiCpuPkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
ExceptionHandlerAsm.nasm CpuException: Avoid allocating code pages for DXE instance 2022-06-10 07:54:48 +00:00
ExceptionTssEntryAsm.nasm UefiCpuPkg: Replace Opcode with the corresponding instructions. 2022-03-01 01:45:47 +00:00