EuroAssembler Index Manual Download Source Macros


Sitemap Links Forum Tests Projects

Test t8562: LIBOMF library for 16bit DOS links COFF modules


Source & expected listing t8562.htm.lst
| | EUROASM AUTOSEGMENT=ON,CPU=086,DUMPWIDTH=24 |7438353632 |%test %SET t8562 ; LIBCOF.D16 link COFF | |;; | |;; Create the first auxilliary COFF module "%test.WB.obj | |%test.WB PROGRAM FORMAT=COFF,WIDTH=16,MODEL=SMALL | |;; |[CODE] ::::Section changed. |0000: |Write.D16:: PROC ; Display ASCIIZ string pointed to by DS:SI using DOS. |0000:B402 | MOV AH,02h ; DOS service Teletype output. |0002:8A14 |.1:MOV DL,[SI] ; Load a character from string to DL, increment SI. |0004:80FA00 | CMP DL,0 ; Test if zero-terminator reached. |0007:7405 | JE .9: ; Exit the procedure if AL=0. |0009:CD21 | INT 21h ; Otherwise display the character DL and advance screen cursor. |000B:46 | INC SI ; Let DS:SI point to the next character. |000C:EBF4 | JMP .1: ; Repeat with following characters. |000E:C3 |.9:RET ; AX,BX,SI are clobbered. |000F: | ENDP Write.D16:: | |;; |000F: |Beep.D16:: PROC ; Display message "Beeping.." and play a sound using BIOS. |000F:BE[0000] | MOV SI,=B"Beeping..." ; Define a literal string. Assume DS=PARA# [RODATA}. |0012:E8EBFF | CALL Write.D16:: ; Display the notification "Beeping...". |0015:BE[0000] | MOV SI,=W(0x0007) ; Define ASCIIZ string with BEL character in [RODATA]. |0018:E8E5FF | CALL Write.D16:: ; Play the beep sound. |001B:C3 | RET ; AX,BX,SI are clobbered. |001C: | ENDP Beep.D16:: |[@LT2] ====ListLiterals in section [@LT2]. |0000:0700 =W(0x0007) |[@LT1] ====ListLiterals in section [@LT1]. |0000:42656570696E672E~=B"Beeping..." | | ENDPROGRAM %test.WB | **** ListMap "t8562.WB.obj",model=SMALL,groups=2,segments=2,entry=,stack= | [CGROUP],FA=00000064h,RVA=00000000h,size=0000001Ch=28,group [CODE] | [CODE],FA=00000064h,RVA=00000000h,size=0000001Ch=28,width=16,align=0010h,purpose=CODE | [DGROUP],FA=00000094h,RVA=00000000h,size=0000000Dh=13,group [RODATA] | [RODATA],FA=00000094h,RVA=00000000h,size=0000000Dh=13,width=16,align=0010h,purpose=RODATA+LITERAL | **** ListGlobals "t8562.WB.obj",Global=0,Public=2,Extern=0,eXport=0,Import=0 | Beep.D16,[CGROUP]:0000000Fh,scope='P' | Write.D16,[CGROUP]:00000000h,scope='P' | |;; | |;; Create the second auxilliary COFF module "%test.EX.obj | |%test.EX PROGRAM FORMAT=COFF,WIDTH=16,MODEL=SMALL |[CODE] ::::Section changed. |0000: |Exit.D16:: PROC ; Display message "End", terminate Terminate the program. |0000:BE[0000] | MOV SI,.M: ; String "End" will be defined in segment [BSS] at DS:SI. |0003:C704456E | MOVW [SI+0],"En" ; Dynamically initialize the notification string. |0007:C744026420 | MOVW [SI+2],"d " ; Assume DS=PARA# [BSS]. |000C:C744040A0D | MOVW [SI+4],0x0D0A ; CR+LF. |0011:C6440600 | MOVB [SI+6],0 ; Zero-terminate the notification. |0015:E8(0000) | CALL Write.D16:: ; Display notification "End". |0018:B44C | MOV AH,4Ch ; DOS function EXIT. |001A:CD21 | INT 21h ; Terminate program and return to DOS. |[BSS] ::::Section changed. |0000:.............. |.M:DB 7*BYTE ; Reserve space for ASCIIZ string "End" in [BSS] segment. |[CODE] ::::Section changed. |001C: | ENDP Exit.D16:: | | ENDPROGRAM %test.EX | **** ListMap "t8562.EX.obj",model=SMALL,groups=2,segments=2,entry=,stack= | [CGROUP],FA=00000064h,RVA=00000000h,size=0000001Ch=28,group [CODE] | [CODE],FA=00000064h,RVA=00000000h,size=0000001Ch=28,width=16,align=0010h,purpose=CODE | [DGROUP],FA=00000000h,RVA=00000000h,size=00000007h=7,group [BSS] | [BSS],FA=00000000h,RVA=00000000h,size=00000007h=7,width=16,align=0010h,purpose=BSS | **** ListGlobals "t8562.EX.obj",Global=0,Public=1,Extern=1,eXport=0,Import=0 | Exit.D16,[CGROUP]:00000000h,scope='P' | Write.D16,[Write.D16]:00000000h,scope='E' | |;; | |;; Create the main LIBOMF library "%test.lib" from auxilliary COFF modules. | |%test PROGRAM FORMAT=LIBOMF,WIDTH=16,MODEL=SMALL | | LINK %test.WB.obj, %test.EX.obj | | ENDPROGRAM %test |# I0560 Linking COFF module ".\t8562.WB.obj". |# I0560 Linking COFF module ".\t8562.EX.obj". | **** ListMap "t8562.lib",model=SMALL,groups=0,segments=0,entry=,stack= | **** ListGlobals "t8562.lib",Global=0,Public=0,Extern=0,eXport=0,Import=0
Expected messages t8562.out
I0180 Assembling source file "t8562.htm". I0270 Assembling source "t8562". I0310 Assembling source pass 1. I0330 Assembling source pass 2 - final. I0470 Assembling program "t8562.WB". "t8562.htm"{45} I0510 Assembling program pass 1. "t8562.htm"{45} I0510 Assembling program pass 2. "t8562.htm"{45} I0530 Assembling program pass 3 - final. "t8562.htm"{45} I0660 16bit SMALL COFF file "t8562.WB.obj" created, size=478. "t8562.htm"{70} I0650 Program "t8562.WB" assembled in 3 passes with errorlevel 0. "t8562.htm"{70} I0470 Assembling program "t8562.EX". "t8562.htm"{81} I0510 Assembling program pass 1. "t8562.htm"{81} I0510 Assembling program pass 2. "t8562.htm"{81} I0530 Assembling program pass 3 - final. "t8562.htm"{81} I0660 16bit SMALL COFF file "t8562.EX.obj" created, size=335. "t8562.htm"{96} I0650 Program "t8562.EX" assembled in 3 passes with errorlevel 0. "t8562.htm"{96} I0470 Assembling program "t8562". "t8562.htm"{107} I0510 Assembling program pass 1. "t8562.htm"{107} I0530 Assembling program pass 2 - final. "t8562.htm"{107} I0560 Linking COFF module ".\t8562.WB.obj". "t8562.htm"{109} I0560 Linking COFF module ".\t8562.EX.obj". "t8562.htm"{109} I0660 16bit SMALL LIBOMF file "t8562.lib" created, size=1536. "t8562.htm"{109} I0650 Program "t8562" assembled in 2 passes with errorlevel 0. "t8562.htm"{109} I0750 Source "t8562" (245 lines) assembled in 2 passes with errorlevel 0. I0860 Listing file "t8562.htm.lst" created, size=5247. I0990 EuroAssembler terminated with errorlevel 0.
Expected output file t8562. lib
0000: F0 0D 00 00 02 00 00 02 00 01 00 00 00 00 00 00  ¤·°°·°°·°·°°°°°°
0010: 82 0A 00 08 74 38 35 36 32 2E 57 42 5C 88 10 00  ¤¬°·t8562.WB\¤·°
0020: 00 00 45 75 72 6F 41 73 73 65 6D 62 6C 65 72 2F  °°EuroAssembler/
0030: 88 05 00 00 9D 30 73 33 96 0E 00 00 04 43 4F 44  ¤·°°¤0s3¤·°°·COD
0040: 45 06 52 4F 44 41 54 41 7C 98 07 00 68 1C 00 02  E·RODATA|¤·°h·°·
0050: 01 00 DA 98 07 00 68 0D 00 03 01 00 E8 90 0F 00  ·°¤¤·°h·°··°¤¤·°
0060: 00 01 08 42 65 65 70 2E 44 31 36 0F 00 00 F4 90  °··Beep.D16·°°¤¤
0070: 10 00 00 01 09 57 72 69 74 65 2E 44 31 36 00 00  ·°°··Write.D16°°
0080: 00 72 A0 20 00 01 00 00 B4 02 8A 14 80 FA 00 74  °r¤¯°·°°¤·¤·¤¤°t
0090: 05 CD 21 46 EB F4 C3 BE 02 00 E8 EB FF BE 00 00  ·¤!F¤¤¤¤·°¤¤¤¤°°
00A0: E8 E5 FF C3 43 9C 09 00 C4 10 54 02 C4 16 54 02  ¤¤¤¤C¤·°¤·T·¤·T·
00B0: 01 A0 11 00 02 00 00 07 00 42 65 65 70 69 6E 67  ·¤·°·°°·°Beeping
00C0: 2E 2E 2E 00 02 8A 08 00 00 00 00 00 00 00 00 6E  ...°·¤·°°°°°°°°n
00D0: 82 0A 00 08 74 38 35 36 32 2E 45 58 58 88 10 00  ¤¬°·t8562.EXX¤·°
00E0: 00 00 45 75 72 6F 41 73 73 65 6D 62 6C 65 72 2F  °°EuroAssembler/
00F0: 88 05 00 00 9D 30 73 33 96 0B 00 00 04 43 4F 44  ¤·°°¤0s3¤·°°·COD
0100: 45 03 42 53 53 55 98 07 00 68 1C 00 02 01 00 DA  E·BSSU¤·°h·°··°¤
0110: 98 07 00 68 07 00 03 01 00 EE 8C 0C 00 09 57 72  ¤·°h·°··°¤¤·°·Wr
0120: 69 74 65 2E 44 31 36 00 7B 90 0F 00 00 01 08 45  ite.D16°{¤·°°··E
0130: 78 69 74 2E 44 31 36 00 00 00 E5 A0 20 00 01 00  xit.D16°°°¤¤¯°·°
0140: 00 BE 00 00 C7 04 45 6E C7 44 02 64 20 C7 44 04  °¤°°¤·En¤D·d¯¤D·
0150: 0A 0D C6 44 06 00 E8 00 00 B4 4C CD 21 66 9C 09  ¬·¤D·°¤°°¤L¤!f¤·
0160: 00 C4 01 54 02 84 16 56 01 4F 8A 03 00 00 00 73  °¤·T·¤·V·O¤·°°°s
0170: F1 8D 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ¤¤°°°°°°°°°°°°°°
0180: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0190: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
01A0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
01B0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
01C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
01D0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
01E0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
01F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 82  °°°°°°°°°°°°°°°¤
0200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 13 00  °°°°°°°°°°°°°°·°
0210: 00 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °·°°°°°°°°°°°°°°
0220: 00 00 00 00 00 1F 08 42 65 65 70 2E 44 31 36 01  °°°°°··Beep.D16·
0230: 00 00 08 45 78 69 74 2E 44 31 36 0D 00 00 00 00  °°·Exit.D16·°°°°
0240: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0250: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0260: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0270: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0280: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0290: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
02A0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
02B0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
02C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
02D0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
02E0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
02F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0310: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0330: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0340: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0350: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
03A0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
03B0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
03C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
03D0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
03E0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
03F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0420: 00 00 13 00 00 19 09 57 72 69 74 65 2E 44 31 36  °°·°°··Write.D16
0430: 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ·°°°°°°°°°°°°°°°
0440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0450: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0460: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
04A0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
04B0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
04C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
04D0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
04E0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
04F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0510: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0520: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0530: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0540: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0550: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0560: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0570: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0590: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
05A0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
05B0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
05C0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
05D0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
05E0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
05F0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°

▲Back to the top▲