Question

Why this following nasm code does not compile :

cmp byte [rdi], byte [rsi]

whereas this code compiles:

mov al, byte [rsi]
cmp byte [rdi], al
Was it helpful?

Solution

Two indirect arguments are not supported. And why not use cmpsb, which compares these two bytes directly?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top