EuroAssembler Index Manual Download Source Macros


Sitemap Links Forum Tests Projects

Test t7924: Compile to MZ linking from 1 OMF in MEDIUM model, ungrouped unaligned segments.


Description
Linked in MEDIUM model (far calls and returns). Executable as t7924.exe.
Tested procedures
PfmzCompile  
Source & expected listing t7924.htm.lst
| | EUROASM LIST=ON,DUMP=ON,DUMPWIDTH=22 | |t7924A PROGRAM FORMAT=OMF,MODEL=MEDIUM,LISTMAP=ON,LISTGLOBALS=ON |[SUBPROC] |[SUBPROC] SEGMENT WIDTH=16,PURPOSE=CODE,ALIGN=BYTE |0000:90 | NOP |0001: | Write::PROC ; Write $-terminated string DS:DX to sysout. |0001:B409 | MOV AH,9 |0003:CD21 | INT 0x21 |0005:CB | RET |0006: | ENDP Write:: |0006: | Terminate::PROC ; Terminate program with errorlevel 0. |0006:B8004C | MOV AX,0x4C00 |0009:CD21 | INT 0x21 |000B:CB | RET |000C: | ENDP Terminate:: |[STACK] |[STACK] SEGMENT WIDTH=16,PURPOSE=STACK |0000:..............~| D 32*WORD | | ENDPROGRAM t7924A | **** ListMap "t7924A.obj",groups=0,segments=2,entry=,stack=[STACK]:00000040h | [SUBPROC],RVA=00000000h,size=0000000Ch=12,width=16,align=1,purpose=CODE | [STACK],RVA=00000000h,size=00000040h=64,width=16,align=0010h,purpose=STACK | **** ListGlobals "t7924A.obj",Global=0,Public=2,Extern=0,eXport=0,Import=0 | Terminate,[SUBPROC]:00000006h,scope='P' | Write,[SUBPROC]:00000001h,scope='P' | |t7924 PROGRAM FORMAT=MZ,MODEL=MEDIUM,LISTMAP=ON,LISTGLOBALS=ON,ENTRY=Start: |[DATA] |[DATA] SEGMENT WIDTH=16,PURPOSE=DATA |0000:4575726F417373~|Txt1: DB "EuroAssembler test t7924",13,10,'$' |001B:45786563757461~|Txt2: DB "Executable as t7924.exe",13,10,'$' |[CODE] |[CODE] SEGMENT WIDTH=16,PURPOSE=CODE,ALIGN=OWORD |0000:90 | NOP |0001: |Start: |0001:B8{0000} | MOV AX,PARA# Txt1: |0004:8ED8 | MOV DS,AX |0006:BA[0000] | MOV DX,Txt1: |0009:9A[0000]{0000} | CALL Write:: |000E:BA[1B00] | MOV DX,Txt2: |0011:9A[0000]{0000} | CALL Write:: |0016:9A[0000]{0000} | CALL Terminate:: | | LINK "t7924A.obj" | | %DISPLAY RELOCATIONS |# D1550 **** %DISPLAY Relocations |# D1560 [CODE]:00000002h,target=[DATA]:00000000h,frame=[DATA],width=16,type=para |# D1560 [CODE]:00000007h,target=[DATA]:00000000h,frame=[DATA],width=16,type=abs |# D1560 [CODE]:0000000Ah,target=[Write]:00000000h,frame=[Write],width=16,type=far |# D1560 [CODE]:0000000Fh,target=[DATA]:00000000h,frame=[DATA],width=16,type=abs |# D1560 [CODE]:00000012h,target=[Write]:00000000h,frame=[Write],width=16,type=far |# D1560 [CODE]:00000017h,target=[Terminate]:00000000h,frame=[Terminate],width=16,type=far |# D1790 **** End of %DISPLAY | |ENDPROGRAM t7924 |# I0560 Linking OMF module ".\t7924A.obj". | **** ListMap "t7924.exe",groups=4,segments=4,entry=[CODE]:00000001h,stack=[STACK]:00000040h | [DATA],RVA=00000000h,size=00000035h=53,group [DATA] | [DATA],RVA=00000000h,size=00000035h=53,width=16,align=0010h,purpose=DATA | [CODE],RVA=00000040h,size=0000001Bh=27,group [CODE] | [CODE],RVA=00000040h,size=0000001Bh=27,width=16,align=0010h,purpose=CODE | [SUBPROC],RVA=0000005Bh,size=0000000Ch=12,group [SUBPROC] | [SUBPROC],RVA=0000005Bh,size=0000000Ch=12,width=16,align=1,purpose=CODE+DATA | [STACK],RVA=00000070h,size=00000040h=64,group [STACK] | [STACK],RVA=00000070h,size=00000040h=64,width=16,align=0010h,purpose=STACK | **** ListGlobals "t7924.exe",Global=2,Public=1,Extern=0,eXport=0,Import=0 | Start,[CODE]:00000001h,RVA=00000041h,scope='P' | Terminate,[SUBPROC]:00000006h,RVA=00000061h,scope='G' | Write,[SUBPROC]:00000001h,RVA=0000005Ch,scope='G'
Expected messages t7924.out
I0180 Assembling source file "t7924.htm". I0270 Assembling source "t7924". I0310 Assembling source pass 1. D1550 **** %DISPLAY Relocations "t7924.htm"{90} D1790 **** End of %DISPLAY "t7924.htm"{90} I0330 Assembling source pass 2 - final. I0470 Assembling program "t7924A". "t7924.htm"{53} I0510 Assembling program pass 1. "t7924.htm"{53} I0510 Assembling program pass 2. "t7924.htm"{53} I0530 Assembling program pass 3 - final. "t7924.htm"{53} I0660 16bit MEDIUM OMF file "t7924A.obj" created, size=135. "t7924.htm"{68} I0650 Program "t7924A" assembled in 3 passes with errorlevel 0. "t7924.htm"{68} I0470 Assembling program "t7924". "t7924.htm"{75} I0510 Assembling program pass 1. "t7924.htm"{75} D1550 **** %DISPLAY Relocations "t7924.htm"{90} D1790 **** End of %DISPLAY "t7924.htm"{90} I0510 Assembling program pass 2. "t7924.htm"{75} D1550 **** %DISPLAY Relocations "t7924.htm"{90} D1790 **** End of %DISPLAY "t7924.htm"{90} I0530 Assembling program pass 3 - final. "t7924.htm"{75} D1550 **** %DISPLAY Relocations "t7924.htm"{90} D1560 [CODE]:00000002h,target=[DATA]:00000000h,frame=[DATA],width=16,type=para "t7924.htm"{90} D1560 [CODE]:00000007h,target=[DATA]:00000000h,frame=[DATA],width=16,type=abs "t7924.htm"{90} D1560 [CODE]:0000000Ah,target=[Write]:00000000h,frame=[Write],width=16,type=far "t7924.htm"{90} D1560 [CODE]:0000000Fh,target=[DATA]:00000000h,frame=[DATA],width=16,type=abs "t7924.htm"{90} D1560 [CODE]:00000012h,target=[Write]:00000000h,frame=[Write],width=16,type=far "t7924.htm"{90} D1560 [CODE]:00000017h,target=[Terminate]:00000000h,frame=[Terminate],width=16,type=far "t7924.htm"{90} D1790 **** End of %DISPLAY "t7924.htm"{90} I0560 Linking OMF module ".\t7924A.obj". "t7924.htm"{99} I0660 16bit MEDIUM MZ file "t7924.exe" created, size=199. "t7924.htm"{99} I0650 Program "t7924" assembled in 3 passes with errorlevel 1. "t7924.htm"{99} I0750 Source "t7924" (170 lines) assembled in 2 passes with errorlevel 1. I0860 Listing file "t7924.htm.lst" created, size=3677. I0990 EuroAssembler terminated with errorlevel 1.
Expected output file t7924. exe
0000: 4D 5A C7 00 01 00 04 00 06 00 05 00 FF FF 07 00  MZ¤°·°·°·°·°¤¤·°
0010: 40 00 A5 25 01 00 04 00 40 00 00 00 00 00 00 00  @°¤%·°·°@°°°°°°°
0020: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0030: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0040: 02 00 04 00 0C 00 04 00 14 00 04 00 19 00 04 00  ·°·°·°·°·°·°·°·°
0050: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0060: 45 75 72 6F 41 73 73 65 6D 62 6C 65 72 20 74 65  EuroAssembler¯te
0070: 73 74 20 74 37 39 32 34 0D 0A 24 45 78 65 63 75  st¯t7924·¬$Execu
0080: 74 61 62 6C 65 20 61 73 20 74 37 39 32 34 2E 65  table¯as¯t7924.e
0090: 78 65 0D 0A 24 00 00 00 00 00 00 00 00 00 00 00  xe·¬$°°°°°°°°°°°
00A0: 90 B8 00 00 8E D8 BA 00 00 9A 0C 00 05 00 BA 1B  ¤¤°°¤¤¤°°¤·°·°¤·
00B0: 00 9A 0C 00 05 00 9A 11 00 05 00 90 B4 09 CD 21  °¤·°·°¤·°·°¤¤·¤!
00C0: CB B8 00 4C CD 21 CB                             ¤¤°L¤!¤

▲Back to the top▲