Compare commits

..

No commits in common. "e480dd3bcd1fc17dd11131da2c34918208e51753" and "10d41fd6b383c7db1867dc5799eedbcb4e9d7bf5" have entirely different histories.

5 changed files with 1 additions and 1400 deletions

View file

@ -50,7 +50,7 @@ própria, sob os termos da licença [[https://bolha.dev/blau_araujo/pbn/src/bran
| Data | Tópico | | Data | Tópico |
|-------+--------------------------------------------| |-------+--------------------------------------------|
| 30/06 | 0. [[curso/aula-00.org][Introdução à linguagem Assembly (NASM)]] | | 30/06 | 0. Sobre o curso |
| 02/07 | 1. [[curso/aula-01.org][Arquitetura de computadores]] | | 02/07 | 1. [[curso/aula-01.org][Arquitetura de computadores]] |
| 04/07 | 2. [[curso/aula-02.org][Linguagens de montagem e a compilação]] | | 04/07 | 2. [[curso/aula-02.org][Linguagens de montagem e a compilação]] |
| 07/07 | 3. [[curso/aula-03.org][O formato binário ELF64]] | | 07/07 | 3. [[curso/aula-03.org][O formato binário ELF64]] |

File diff suppressed because it is too large Load diff

View file

@ -1,24 +0,0 @@
# salve-att.s
# Montar com: as salve-att.s -o salve-att.o
# Linkar com: ld salve-att.o -o salve-att
.section .data
msg:
.ascii "Salve, simpatia!\n"
len = . - msg
.section .text
.global _start
_start:
# write(1, msg, len)
mov $1, %rax # syscall: write
mov $1, %rdi # stdout
lea msg(%rip), %rsi # endereço da mensagem
mov $len, %rdx # tamanho da mensagem
syscall
# exit(0)
mov $60, %rax # syscall: exit
xor %rdi, %rdi # status 0
syscall

View file

@ -1,23 +0,0 @@
; salve-intel.asm
; Montar com: nasm -f elf64 salve-intel.asm
; Linkar com: ld salve-intel.o -o salve-intel
section .data
msg db "Salve, simpatia!", 10 ; 10 = '\n'
len equ $ - msg
section .text
global _start
_start:
; write(1, msg, len)
mov rax, 1 ; syscall número 1: write
mov rdi, 1 ; stdout
mov rsi, msg ; endereço da mensagem
mov rdx, len ; tamanho da mensagem
syscall
; exit(0)
mov rax, 60 ; syscall número 60: exit
xor rdi, rdi ; status 0
syscall

Binary file not shown.