fix macros...

svn path=/branches/ros-amd64-bringup/; revision=45334
This commit is contained in:
Timo Kreuzer 2010-01-30 01:46:16 +00:00
parent f0c278391b
commit fcd9ab3f50

View file

@ -18,7 +18,7 @@ OPTION DOTNAME
#define VAL(x) x #define VAL(x) x
/* MASM/ML doesn't want explicit [rip] addressing */ /* MASM/ML doesn't want explicit [rip] addressing */
#define RIP(address) address #define RIP(address) [address]
/* Due to MASM's reverse syntax, we are forced to use a precompiler macro */ /* Due to MASM's reverse syntax, we are forced to use a precompiler macro */
#define MACRO(name, ...) name MACRO __VA_ARGS__ #define MACRO(name, ...) name MACRO __VA_ARGS__
@ -33,8 +33,13 @@ ENDM
name ENDP name ENDP
ENDM ENDM
/* MASM doesn't have an ASCIIZ macro */ /* MASM doesn't have an ASCII macro */
.ASCIIZ MACRO text .ASCII MACRO text
DB text
ENDM
/* MASM doesn't have an ASCIZ macro */
.ASCIZ MACRO text
DB text, 0 DB text, 0
ENDM ENDM
@ -98,13 +103,14 @@ ENDM
.set cfa_current_offset, cfa_current_offset - \size .set cfa_current_offset, cfa_current_offset - \size
.endm .endm
.macro .pushframe code code = 1
.if (\code == 0) .macro .pushframe param=0
.cfi_adjust_cfa_offset 0x28 .if (\param)
.set cfa_current_offset, cfa_current_offset - 0x28
.else
.cfi_adjust_cfa_offset 0x30 .cfi_adjust_cfa_offset 0x30
.set cfa_current_offset, cfa_current_offset - 0x30 .set cfa_current_offset, cfa_current_offset - 0x30
.else
.cfi_adjust_cfa_offset 0x28
.set cfa_current_offset, cfa_current_offset - 0x28
.endif .endif
.endm .endm