tag-release: a simple script to tag the repository for release
[nasm/avx512.git] / test / binexe.asm
blobab852fb9e4e0a478785d4791f7a5389afe65cc93
1 ; Demonstration of how to write an entire .EXE format program by using
2 ; the `exebin.mac' macro package.
3 ; To build:
4 ; nasm -fbin binexe.asm -o binexe.exe -ipath
5 ; (where `path' is such as to allow the %include directive to find
6 ; exebin.mac)
7 ; To test:
8 ; binexe
9 ; (should print `hello, world')
11 %include "exebin.mac"
13 EXE_begin
14 EXE_stack 64 ; demonstrates overriding the 0x800 default
16 section .text
18 mov ax,cs
19 mov ds,ax
21 mov dx,hello
22 mov ah,9
23 int 0x21
25 mov ax,0x4c00
26 int 0x21
28 section .data
30 hello: db 'hello, world', 13, 10, '$'
32 EXE_end