EuroAssembler Index Manual Download Source Macros


Sitemap Links Forum Tests Projects

Test t9050: LIBCOF library for 16bit DOS


Tested procedures
PflibcofCompile  
Source & expected listing t9050.htm.lst
| | EUROASM AUTOSEGMENT=ON,CPU=086,DUMPWIDTH=24 |7439303530 |%test %SET t9050 ; LIBCOF.D16 |00000000: | | |%test PROGRAM FORMAT=LIBCOF,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:: | |;; |001C: |Exit.D16:: PROC ; Display message "End", terminate Terminate the program. |001C:BE[0000] | MOV SI,.M: ; String "End" will be defined in segment [BSS] at DS:SI. |001F:C704456E | MOVW [SI+0],"En" ; Dynamically initialize the notification string. |0023:C744026420 | MOVW [SI+2],"d " ; Assume DS=PARA# [BSS]. |0028:C744040A0D | MOVW [SI+4],0x0D0A ; CR+LF. |002D:C6440600 | MOVB [SI+6],0 ; Zero-terminate the notification. |0031:E8CCFF | CALL Write.D16:: ; Display notification "End". |0034:B44C | MOV AH,4Ch ; DOS function EXIT. |0036: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. |0038: | ENDP Exit.D16:: |[@LT2] ====ListLiterals in section [@LT2]. |0000:0700 =W(0x0007) |[@LT1] ====ListLiterals in section [@LT1]. |0000:42656570696E672E~=B"Beeping..." | | ENDPROGRAM %test | **** ListMap "t9050.lib",model=SMALL,groups=2,segments=3,entry=,stack= | [CGROUP],FA=0000008Ch,RVA=00000000h,size=00000038h=56,group [CODE] | [CODE],FA=0000008Ch,RVA=00000000h,size=00000038h=56,width=16,align=0010h,purpose=CODE | [DGROUP],FA=00000000h,RVA=00000000h,size=0000000Dh=13,group [RODATA] [BSS] | [RODATA],FA=000000E2h,RVA=00000000h,size=0000000Dh=13,width=16,align=0010h,purpose=RODATA+LITERAL | [BSS],FA=00000000h,RVA=00000000h,size=00000007h=7,width=16,align=0010h,purpose=BSS | **** ListGlobals "t9050.lib",Global=0,Public=3,Extern=0,eXport=0,Import=0 | Beep.D16,[CGROUP]:0000000Fh,scope='P' | Exit.D16,[CGROUP]:0000001Ch,scope='P' | Write.D16,[CGROUP]:00000000h,scope='P'
Expected messages t9050.out
I0180 Assembling source file "t9050.htm". I0270 Assembling source "t9050". I0310 Assembling source pass 1. I0330 Assembling source pass 2 - final. I0470 Assembling program "t9050". "t9050.htm"{51} I0510 Assembling program pass 1. "t9050.htm"{51} I0510 Assembling program pass 2. "t9050.htm"{51} I0530 Assembling program pass 3 - final. "t9050.htm"{51} I0660 16bit SMALL LIBCOF file "t9050.lib" created, size=1069. "t9050.htm"{90} I0650 Program "t9050" assembled in 3 passes with errorlevel 0. "t9050.htm"{90} I0750 Source "t9050" (190 lines) assembled in 2 passes with errorlevel 0. I0860 Listing file "t9050.htm.lst" created, size=3859. I0990 EuroAssembler terminated with errorlevel 0.
Expected output file t9050. lib
0000: 21 3C 61 72 63 68 3E 0A 2F 20 20 20 20 20 20 20  !<arch>¬/¯¯¯¯¯¯¯
0010: 20 20 20 20 20 20 20 20 30 20 20 20 20 20 20 20  ¯¯¯¯¯¯¯¯0¯¯¯¯¯¯¯
0020: 20 20 20 20 30 20 20 20 20 20 30 20 20 20 20 20  ¯¯¯¯0¯¯¯¯¯0¯¯¯¯¯
0030: 31 30 30 36 36 36 20 20 39 34 20 20 20 20 20 20  100666¯¯94¯¯¯¯¯¯
0040: 20 20 60 0A 00 00 00 08 00 00 01 72 00 00 01 72  ¯¯`¬°°°·°°·r°°·r
0050: 00 00 01 72 00 00 01 72 00 00 01 72 00 00 01 72  °°·r°°·r°°·r°°·r
0060: 00 00 01 72 00 00 01 72 43 47 52 4F 55 50 00 44  °°·r°°·rCGROUP°D
0070: 47 52 4F 55 50 00 43 4F 44 45 00 52 4F 44 41 54  GROUP°CODE°RODAT
0080: 41 00 42 53 53 00 57 72 69 74 65 2E 44 31 36 00  A°BSS°Write.D16°
0090: 42 65 65 70 2E 44 31 36 00 45 78 69 74 2E 44 31  Beep.D16°Exit.D1
00A0: 36 00 2F 20 20 20 20 20 20 20 20 20 20 20 20 20  6°/¯¯¯¯¯¯¯¯¯¯¯¯¯
00B0: 20 20 30 20 20 20 20 20 20 20 20 20 20 20 30 20  ¯¯0¯¯¯¯¯¯¯¯¯¯¯0¯
00C0: 20 20 20 20 30 20 20 20 20 20 31 30 30 36 36 36  ¯¯¯¯0¯¯¯¯¯100666
00D0: 20 20 38 36 20 20 20 20 20 20 20 20 60 0A 01 00  ¯¯86¯¯¯¯¯¯¯¯`¬·°
00E0: 00 00 72 01 00 00 08 00 00 00 01 00 01 00 01 00  °°r·°°·°°°·°·°·°
00F0: 01 00 01 00 01 00 01 00 01 00 42 53 53 00 42 65  ·°·°·°·°·°BSS°Be
0100: 65 70 2E 44 31 36 00 43 47 52 4F 55 50 00 43 4F  ep.D16°CGROUP°CO
0110: 44 45 00 44 47 52 4F 55 50 00 45 78 69 74 2E 44  DE°DGROUP°Exit.D
0120: 31 36 00 52 4F 44 41 54 41 00 57 72 69 74 65 2E  16°RODATA°Write.
0130: 44 31 36 00 2F 2F 20 20 20 20 20 20 20 20 20 20  D16°//¯¯¯¯¯¯¯¯¯¯
0140: 20 20 20 20 30 20 20 20 20 20 20 20 20 20 20 20  ¯¯¯¯0¯¯¯¯¯¯¯¯¯¯¯
0150: 30 20 20 20 20 20 30 20 20 20 20 20 31 30 30 36  0¯¯¯¯¯0¯¯¯¯¯1006
0160: 36 36 20 20 32 20 20 20 20 20 20 20 20 20 60 0A  66¯¯2¯¯¯¯¯¯¯¯¯`¬
0170: 00 0A 74 39 30 35 30 2F 20 20 20 20 20 20 20 20  °¬t9050/¯¯¯¯¯¯¯¯
0180: 20 20 30 20 20 20 20 20 20 20 20 20 20 20 30 20  ¯¯0¯¯¯¯¯¯¯¯¯¯¯0¯
0190: 20 20 20 20 30 20 20 20 20 20 31 30 30 36 36 36  ¯¯¯¯0¯¯¯¯¯100666
01A0: 20 20 36 33 39 20 20 20 20 20 20 20 60 0A 4C 01  ¯¯639¯¯¯¯¯¯¯`¬L·
01B0: 03 00 00 00 00 00 F0 00 00 00 12 00 00 00 00 00  ·°°°°°¤°°°·°°°°°
01C0: 00 00 43 4F 44 45 00 00 00 00 00 00 00 00 00 00  °°CODE°°°°°°°°°°
01D0: 00 00 38 00 00 00 8C 00 00 00 C4 00 00 00 00 00  °°8°°°¤°°°¤°°°°°
01E0: 00 00 03 00 00 00 20 00 50 60 52 4F 44 41 54 41  °°·°°°¯°P`RODATA
01F0: 00 00 00 00 00 00 00 00 00 00 0D 00 00 00 E2 00  °°°°°°°°°°·°°°¤°
0200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 40 00  °°°°°°°°°°°°°°@°
0210: 50 40 42 53 53 00 00 00 00 00 00 00 00 00 00 00  P@BSS°°°°°°°°°°°
0220: 00 00 07 00 00 00 00 00 00 00 00 00 00 00 00 00  °°·°°°°°°°°°°°°°
0230: 00 00 00 00 00 00 80 00 50 C0 B4 02 8A 14 80 FA  °°°°°°¤°P¤¤·¤·¤¤
0240: 00 74 05 CD 21 46 EB F4 C3 BE 02 00 E8 EB FF BE  °t·¤!F¤¤¤¤·°¤¤¤¤
0250: 00 00 E8 E5 FF C3 BE 00 00 C7 04 45 6E C7 44 02  °°¤¤¤¤¤°°¤·En¤D·
0260: 64 20 C7 44 04 0A 0D C6 44 06 00 E8 CC FF B4 4C  d¯¤D·¬·¤D·°¤¤¤¤L
0270: CD 21 10 00 00 00 06 00 00 00 01 00 16 00 00 00  ¤!·°°°·°°°·°·°°°
0280: 06 00 00 00 01 00 1D 00 00 00 02 00 00 00 01 00  ·°°°·°·°°°·°°°·°
0290: 07 00 42 65 65 70 69 6E 67 2E 2E 2E 00 00 2E 66  ·°Beeping...°°.f
02A0: 69 6C 65 00 00 00 00 00 00 00 FE FF 00 00 67 01  ile°°°°°°°¤¤°°g·
02B0: 74 39 30 35 30 2E 68 74 6D 00 00 00 00 00 00 00  t9050.htm°°°°°°°
02C0: 00 00 42 53 53 00 00 00 00 00 00 00 00 00 03 00  °°BSS°°°°°°°°°·°
02D0: 00 00 03 01 07 00 00 00 00 00 00 00 00 00 00 00  °°···°°°°°°°°°°°
02E0: 00 00 00 00 00 00 43 4F 44 45 00 00 00 00 00 00  °°°°°°CODE°°°°°°
02F0: 00 00 01 00 00 00 03 01 38 00 00 00 03 00 00 00  °°·°°°··8°°°·°°°
0300: 00 00 00 00 00 00 00 00 00 00 52 4F 44 41 54 41  °°°°°°°°°°RODATA
0310: 00 00 00 00 00 00 02 00 00 00 03 01 0D 00 00 00  °°°°°°·°°°···°°°
0320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  °°°°°°°°°°°°°°°°
0330: 00 00 04 00 00 00 02 00 00 00 02 00 0C 00 03 00  °°·°°°·°°°·°·°·°
0340: 00 00 00 00 13 00 00 00 00 00 00 00 02 00 0D 00  °°°°·°°°°°°°·°·°
0350: 03 00 40 4C 54 31 00 00 00 00 02 00 00 00 02 00  ·°@LT1°°°°·°°°·°
0360: 01 01 03 00 40 4C 54 32 00 00 00 00 00 00 00 00  ···°@LT2°°°°°°°°
0370: 02 00 01 01 03 00 00 00 00 00 1E 00 00 00 00 00  ·°···°°°°°·°°°°°
0380: 00 00 03 00 0C 00 03 00 00 00 00 00 29 00 00 00  °°·°·°·°°°°°)°°°
0390: 02 00 00 00 01 00 00 00 03 00 00 00 00 00 35 00  ·°°°·°°°·°°°°°5°
03A0: 00 00 0E 00 00 00 01 00 00 00 03 00 42 65 65 70  °°·°°°·°°°·°Beep
03B0: 2E 44 31 36 0F 00 00 00 01 00 01 02 02 00 45 78  .D16·°°°·°···°Ex
03C0: 69 74 2E 44 31 36 1C 00 00 00 01 00 01 02 02 00  it.D16·°°°·°···°
03D0: 00 00 00 00 41 00 00 00 00 00 00 00 01 00 01 02  °°°°A°°°°°°°·°··
03E0: 02 00 4B 00 00 00 3D 42 22 42 65 65 70 69 6E 67  ·°K°°°=B"Beeping
03F0: 2E 2E 2E 22 00 3D 57 28 30 78 30 30 30 37 29 00  ..."°=W(0x0007)°
0400: 45 78 69 74 2E 44 31 36 2E 4D 00 57 72 69 74 65  Exit.D16.M°Write
0410: 2E 44 31 36 2E 31 00 57 72 69 74 65 2E 44 31 36  .D16.1°Write.D16
0420: 2E 39 00 57 72 69 74 65 2E 44 31 36 00           .9°Write.D16°

▲Back to the top▲