.section .rodata
fmt:
.string "result: %d\n"
.globl main
.text
main:
pushq $6
pushq $3
popq %rax
popq %rcx
xorq %rbx, %rbx
divq %rcx
pushq %rax
movq $fmt, %rdi
popq %rsi
movq $0, %rax
call printf
ret
I have a x86 assembly code that does 6/3 and prints the result. But I am getting a error that says Floating point exception (core dumped) and I don't know why