Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
qw
section .text global _start ;must be declared for using gcc _start: ;tell linker entry point mov ecx, msg nextc: mov al,[ecx] cmp al,0 je exit cmp al,97 jb skip sub al,32 mov [ecx],al skip: inc ecx jmp nextc exit: mov ecx, msg nextc1: mov al,[ecx] cmp al,0 je exit1 push ax inc ecx jmp nextc1 exit1: mov ecx, msg nextc2: pop ax cmp [ecx],byte 0 je exit2 mov [ecx],al inc ecx jmp nextc2 exit2: mov edx, len ;message length mov ecx, msg ;message to write mov ebx, 1 ;file descriptor (stdout) mov eax, 4 ;system call number (sys_write) int 0x80 ;call kernel mov eax, 1 ;system call number (sys_exit) int 0x80 ;call kernel section .data msg db 'Hello, world!',0xa ;our dear string len equ $ - msg ;length of our dear string
run
|
edit
|
history
|
help
0
FirstProgram Lab no crash
sdaffdssadfsfd
fdafdafdafsfdsa
countingnumbers
First Program Group Lab
gfsdfgdgfdgdgfdfgd
x
fib
BranchesLab_mSmith_bBrownV2
lec4bb