Changeset 110 in xtideuniversalbios for trunk/Assembly_Library/Inc
- Timestamp:
- Feb 22, 2011, 7:06:50 PM (14 years ago)
- google:author:
- aitotat
- Location:
- trunk/Assembly_Library/Inc
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Assembly_Library/Inc/AssemblyLibrary.inc
r105 r110 6 6 ; Include .inc files 7 7 %include "Emulate.inc" ; Must be included first! 8 %include "Macros.inc" 8 9 %include "BiosData.inc" 9 10 %include "BiosFunctions.inc" … … 12 13 %include "DosFunctions.inc" 13 14 %include "File.inc" 14 %include "Macros.inc"15 15 %include "Math.inc" 16 16 %include "Registers.inc" -
trunk/Assembly_Library/Inc/Emulate.inc
r94 r110 236 236 push dx 237 237 push bx 238 ; SP before first push should be pushed here238 push bx ; SP before first push should be pushed here 239 239 push bp 240 240 push si … … 263 263 pop si 264 264 pop bp 265 ; Old SP should be skipped here265 pop di ; Skip SP 266 266 pop bx 267 267 pop dx … … 318 318 leave 319 319 %endif 320 %endmacro321 322 323 ;--------------------------------------------------------------------324 ; eENTER_STRUCT325 ; Parameters:326 ; %1: Number of bytes to reserve from stack327 ; Returns:328 ; SS:BP: Ptr to beginning of struct reserved from stack329 ; Corrupts registers:330 ; FLAGS331 ;--------------------------------------------------------------------332 %macro eENTER_STRUCT 1333 push bp334 sub sp, %1335 mov bp, sp336 %endmacro337 338 ;--------------------------------------------------------------------339 ; eLEAVE_STRUCT340 ; Parameters:341 ; %1: Number of bytes reserved with eENTER_STRUCT342 ; Returns:343 ; BP: What it was before eENTER_STRUCT344 ; Corrupts registers:345 ; FLAGS346 ;--------------------------------------------------------------------347 %macro eLEAVE_STRUCT 1348 add sp, %1349 pop bp350 320 %endmacro 351 321 -
trunk/Assembly_Library/Inc/Macros.inc
r104 r110 2 2 ; Description : This is the place to put various generic macros. 3 3 ; Should be included immediately after emulate.inc 4 %ifndef MACROS_INC 5 %define MACROS_INC 4 6 5 7 ;-------------------------------------------------------------------- … … 40 42 %endif 41 43 %endmacro 44 45 46 ;-------------------------------------------------------------------- 47 ; eENTER_STRUCT 48 ; Parameters: 49 ; %1: Number of bytes to reserve from stack 50 ; Returns: 51 ; SS:BP: Ptr to beginning of struct reserved from stack 52 ; Corrupts registers: 53 ; FLAGS 54 ;-------------------------------------------------------------------- 55 %macro eENTER_STRUCT 1 56 push bp 57 sub sp, %1 58 mov bp, sp 59 %endmacro 60 61 ;-------------------------------------------------------------------- 62 ; eLEAVE_STRUCT 63 ; Parameters: 64 ; %1: Number of bytes reserved with eENTER_STRUCT 65 ; Returns: 66 ; BP: What it was before eENTER_STRUCT 67 ; Corrupts registers: 68 ; FLAGS 69 ;-------------------------------------------------------------------- 70 %macro eLEAVE_STRUCT 1 71 add sp, %1 72 pop bp 73 %endmacro 74 75 76 %endif ; MACROS_INC
Note:
See TracChangeset
for help on using the changeset viewer.