Page 1 of 1

Read from the file mov rax, mov rdi, mov rsi, mov rdx, syscall ; SYS_read qword [fileDescr] readBuffer BUFF_SIZE ; print

Posted: Fri Jun 10, 2022 11:55 am
by correctanswer
Read From The File Mov Rax Mov Rdi Mov Rsi Mov Rdx Syscall Sys Read Qword Filedescr Readbuffer Buff Size Print 1
Read From The File Mov Rax Mov Rdi Mov Rsi Mov Rdx Syscall Sys Read Qword Filedescr Readbuffer Buff Size Print 1 (76.45 KiB) Viewed 60 times
Read from the file mov rax, mov rdi, mov rsi, mov rdx, syscall ; SYS_read qword [fileDescr] readBuffer BUFF_SIZE ; print the buffer ; add null for the print string mov rsi, mov byte [rsi+rax], NULL mov rdi, call printString printNewLine Close the file mov rax, SYS_close mov rdi, qword [fileDescr] syscall Program done readBuffer readBuffer I