i m using ubuntu and while executing the following code for finding the smallest number in the array i m getting
n.o: In function `reading':
n.asm:(.text+0xae): relocation truncated to fit: R_X86_64_8 against `.bss'
when i executed ld function
section .bss
digit0: resb 1
digit1: resb 1
array: resb 10
small_num: resb 1
d: resb 1
section .data
msg1: db "enter 10 two-digit numbers:", 10
len1: equ $-msg1
msg2: db "smallest is:"
len2: equ $-msg2
temp: db 10
section .text
global _start
_start:
mov eax, 4
mov ebx, 1
mov ecx, msg1
mov edx, len1
int 80h
mov rbx, array
reading:push rbx
mov eax, 3
mov ebx, 0
mov ecx, digit1
mov edx, 1
int 80h
mov eax, 3
mov ebx, 0
mov ecx, digit0
mov edx, 1
int 80h
mov eax, 3
mov ebx, 0
mov ecx, d
mov edx, 1
int 80h
sub byte[digit1], 30h
sub byte[digit0], 30h
mov al, byte[digit1]
mov dl, 10
mul dl
add al, byte[digit0]
pop rbx
mov byte[rbx], al
add rbx, 1
dec byte[temp]
cmp byte[temp], 0
jg reading
mov rbx, array
mov byte[small_num], array
add byte[temp], 10
push rbx
smallest:pop rbx
mov al, byte[small_num]
mov bl, byte[rbx]
cmp al, bl
jb cont
change: mov byte[small_num], bl
add rbx, 1
dec byte[temp]
cmp byte[temp], 0
push rbx
jne smallest
jmp print
cont: add rbx, 1
dec byte[temp]
cmp byte[temp], 0
push rbx
jne smallest
print: mov eax, 4
mov ebx, 1
mov ecx, msg2
mov edx, len2
int 80h
movzx ax, byte[small_num]
mov bl, 10
div bl
mov byte[digit1], al
mov byte[digit0], ah
add byte[digit0], 30h
add byte[digit1], 30h
mov eax, 4
mov ebx, 1
mov ecx, digit1
mov edx, 1
int 80h
mov eax, 4
mov ebx, 1
mov ecx, digit0
mov edx, 1
int 80h
mov eax, 4
mov ebx, 1
mov ecx, 10
mov edx, 1
int 80h
mov eax, 1
mov ebx, 0
int 80h
please help me to find the error