summaryrefslogtreecommitdiff
path: root/SourceLevelDebugPkg/Library
diff options
context:
space:
mode:
authorAnderw Fish <afish@apple.com>2014-09-09 06:27:45 +0000
committervanjeff <vanjeff@6f19259b-4bc3-4df7-8a09-765794883524>2014-09-09 06:27:45 +0000
commit19ee4a904982cfacdcb8c578c5d421162fa9488d (patch)
tree1e79770d9e67c3800b58bb420ecfad4ceb6e7ced /SourceLevelDebugPkg/Library
parent41f80fbd9905cdc9a457e3cdf8110539f948c6b9 (diff)
downloadedk2-platforms-19ee4a904982cfacdcb8c578c5d421162fa9488d.tar.xz
SourceLevelDebugPkg: DebugAgentLib: Fix clang/Xcode 5 compile/link errors
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
Diffstat (limited to 'SourceLevelDebugPkg/Library')
-rw-r--r--SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/DebugAgent.h2
-rw-r--r--SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.S2
-rw-r--r--SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.asm2
-rw-r--r--SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.S10
-rw-r--r--SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.asm2
5 files changed, 9 insertions, 9 deletions
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/DebugAgent.h b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/DebugAgent.h
index 6f1d3e5aab..53d96609be 100644
--- a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/DebugAgent.h
+++ b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/DebugAgent.h
@@ -67,7 +67,7 @@
extern UINTN Exception0Handle;
extern UINTN TimerInterruptHandle;
-extern UINT16 ExceptionStubHeaderSize;
+extern UINT32 ExceptionStubHeaderSize;
extern BOOLEAN mSkipBreakpoint;
extern EFI_VECTOR_HANDOFF_INFO mVectorHandoffInfoDebugAgent[];
extern UINTN mVectorHandoffInfoCount;
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.S b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.S
index 284939126f..efeaebc2c8 100644
--- a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.S
+++ b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.S
@@ -33,7 +33,7 @@ ASM_GLOBAL ASM_PFX(CommonEntry)
.data
-ASM_PFX(ExceptionStubHeaderSize): .word ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)
+ASM_PFX(ExceptionStubHeaderSize): .long ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)
.text
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.asm b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.asm
index 9b219fc07d..2aaf5b7b4c 100644
--- a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.asm
+++ b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/Ia32/AsmFuncs.asm
@@ -38,7 +38,7 @@ ENDM
.data
-ExceptionStubHeaderSize DW Exception1Handle - Exception0Handle
+ExceptionStubHeaderSize DD Exception1Handle - Exception0Handle
CommonEntryAddr DD CommonEntry
.code
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.S b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.S
index 365bc940fe..276f036a83 100644
--- a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.S
+++ b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.S
@@ -34,7 +34,7 @@ ASM_GLOBAL ASM_PFX(CommonEntry)
.data
-ASM_PFX(ExceptionStubHeaderSize): .word ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)
+ASM_PFX(ExceptionStubHeaderSize): .long ASM_PFX(Exception1Handle) - ASM_PFX(Exception0Handle)
.text
@@ -271,13 +271,13 @@ NoExtrPush:
movzwq 32(%rbp), %rax
# movq %cs, %rax
pushq %rax
- movq %ds, %rax
+ movw %ds, %rax
pushq %rax
- movq %es, %rax
+ movw %es, %rax
pushq %rax
- movq %fs, %rax
+ movw %fs, %rax
pushq %rax
- movq %gs, %rax
+ movw %gs, %rax
pushq %rax
## UINT64 Rip;
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.asm b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.asm
index cf8c5f0194..0f076a76da 100644
--- a/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.asm
+++ b/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/X64/AsmFuncs.asm
@@ -32,7 +32,7 @@ AGENT_HANDLER_SIGNATURE MACRO
db 41h, 47h, 54h, 48h ; SIGNATURE_32('A','G','T','H')
ENDM
-ExceptionStubHeaderSize dw Exception1Handle - Exception0Handle ;
+ExceptionStubHeaderSize dd Exception1Handle - Exception0Handle ;
CommonEntryAddr dq CommonEntry ;
.code