summaryrefslogtreecommitdiff
path: root/main.asm
diff options
context:
space:
mode:
authorArslaan Pathan <[email protected]>2026-09-30 12:37:06 +1300
committerArslaan Pathan <[email protected]>2026-09-30 12:39:55 +1300
commit7e9043d484c30d018a012f835dda5eae9fa17860 (patch)
treed44842c091e6cfa48d16062cfc96bf31bdb2d760 /main.asm
parent2bb4f7e34806054fa15174b2586241c2b82e040c (diff)
downloadx86-asm-7e9043d484c30d018a012f835dda5eae9fa17860.tar.xz
x86-asm-7e9043d484c30d018a012f835dda5eae9fa17860.zip
idk whats even in this commit
Diffstat (limited to 'main.asm')
-rw-r--r--main.asm19
1 files changed, 19 insertions, 0 deletions
diff --git a/main.asm b/main.asm
index f0b6221..1b3f997 100644
--- a/main.asm
+++ b/main.asm
@@ -1,3 +1,4 @@
+<<<<<<< HEAD
global _start
section .text
@@ -10,3 +11,21 @@ label:
cmp ecx, 0 ; compare ecx with 0
jg label ; jump if greater than label
+=======
+global main
+
+extern printf
+
+section .data
+ msg db "Hello, x86_64 Assembly!", 10, 0
+
+section .text
+
+main:
+ sub rsp, 8
+ lea rdi, [rel msg]
+ call printf wrt ..plt
+ mov eax, 0
+ add rsp, 8
+ ret
+>>>>>>> 181d482 (Initial commit (i got too carried away with asm and forgot to commit))