Move ExceptionStubHeaderSize from 16 to 32 bits to work around clang relocation limitation. Use movw, not move for 32-bit segment register operations.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Anderw Fish <afish@apple.com>
Reviewed-by: Jeff Fan <jeff.fan@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16067
6f19259b-4bc3-4df7-8a09-
765794883524
\r
extern UINTN Exception0Handle;\r
extern UINTN TimerInterruptHandle;\r
-extern UINT16 ExceptionStubHeaderSize;\r
+extern UINT32 ExceptionStubHeaderSize;\r
extern BOOLEAN mSkipBreakpoint;\r
extern EFI_VECTOR_HANDOFF_INFO mVectorHandoffInfoDebugAgent[];\r
extern UINTN mVectorHandoffInfoCount;\r
\r
.data\r
\r
-ASM_PFX(ExceptionStubHeaderSize): .word ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)\r
+ASM_PFX(ExceptionStubHeaderSize): .long ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)\r
\r
.text\r
\r
\r
.data\r
\r
-ExceptionStubHeaderSize DW Exception1Handle - Exception0Handle\r
+ExceptionStubHeaderSize DD Exception1Handle - Exception0Handle\r
CommonEntryAddr DD CommonEntry\r
\r
.code\r
\r
.data\r
\r
-ASM_PFX(ExceptionStubHeaderSize): .word ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)\r
+ASM_PFX(ExceptionStubHeaderSize): .long ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)\r
\r
\r
.text\r
movzwq 32(%rbp), %rax\r
# movq %cs, %rax\r
pushq %rax\r
- movq %ds, %rax\r
+ movw %ds, %rax\r
pushq %rax\r
- movq %es, %rax\r
+ movw %es, %rax\r
pushq %rax\r
- movq %fs, %rax\r
+ movw %fs, %rax\r
pushq %rax\r
- movq %gs, %rax\r
+ movw %gs, %rax\r
pushq %rax\r
\r
## UINT64 Rip;\r
db 41h, 47h, 54h, 48h ; SIGNATURE_32('A','G','T','H')\r
ENDM\r
\r
-ExceptionStubHeaderSize dw Exception1Handle - Exception0Handle ;\r
+ExceptionStubHeaderSize dd Exception1Handle - Exception0Handle ;\r
CommonEntryAddr dq CommonEntry ;\r
\r
.code\r