diff options
author | Jordan Justen <jordan.l.justen@intel.com> | 2014-09-01 17:23:10 +0000 |
---|---|---|
committer | jljusten <jljusten@6f19259b-4bc3-4df7-8a09-765794883524> | 2014-09-01 17:23:10 +0000 |
commit | 02eef553114dea1e4d55071e91398a0625e4e18c (patch) | |
tree | b06b4ff8b471931a3596d01b171c9fe18dc41e84 /MdePkg/Include/Base.h | |
parent | b3f9cdaebb8a136c0ff8add4291a8b77dbf4721a (diff) | |
download | edk2-platforms-02eef553114dea1e4d55071e91398a0625e4e18c.tar.xz |
MdePkg Base.h: Always define ASM_PFX
Some compilers may define __USER_LABEL_PREFIX__ to determine the
prefix used with ASM_PFX. Otherwise, IA32 will use a single underscore
'_' character, and all other architectures will use an empty prefix.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16019 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg/Include/Base.h')
-rw-r--r-- | MdePkg/Include/Base.h | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/MdePkg/Include/Base.h b/MdePkg/Include/Base.h index e1ffa7d23b..4dda3c2f40 100644 --- a/MdePkg/Include/Base.h +++ b/MdePkg/Include/Base.h @@ -79,21 +79,20 @@ VERIFY_SIZE_OF (CHAR16, 2); #endif
//
-// For symbol name in GNU assembly code, an extra "_" is necessary
+// For symbol name in assembly code, an extra "_" is sometimes necessary
//
-#if defined(__GNUC__)
- ///
- /// Private worker functions for ASM_PFX()
- ///
- #define _CONCATENATE(a, b) __CONCATENATE(a, b)
- #define __CONCATENATE(a, b) a ## b
- ///
- /// The __USER_LABEL_PREFIX__ macro predefined by GNUC represents the prefix
- /// on symbols in assembly language.
- ///
- #define ASM_PFX(name) _CONCATENATE (__USER_LABEL_PREFIX__, name)
-#endif
+///
+/// Private worker functions for ASM_PFX()
+///
+#define _CONCATENATE(a, b) __CONCATENATE(a, b)
+#define __CONCATENATE(a, b) a ## b
+
+///
+/// The __USER_LABEL_PREFIX__ macro predefined by GNUC represents the prefix
+/// on symbols in assembly language.
+///
+#define ASM_PFX(name) _CONCATENATE (__USER_LABEL_PREFIX__, name)
#if __APPLE__
//
|