I'm learning x86-64 assembly using online exercises on OST2's website.
All the exercise questions in regards to multiplication are confusing me.
mov rax, 0x89204E764CB58DF0 mov esp, 0xF627BAE4 mul espQuestion: What value is stored in edx:eax after the code is ran? Answer: The correct value in edx:eax after this code executes was 0x49C25E0D7A62C9C0
I can't understand how they have this result. My attempt was to just do the obvious of taking 0x89204E764CB58DF0 and multiplying it by 0xF627BAE4, then only accounting for the 32 right bits (as I believe edx:eax is for 32 bit).
My result was 0x7A62C9C0, which is half right - that's supposed to be the other half of the correct answer. So I thought.. maybe I should account for the entire 64 bits? No - that makes my result 0x3B83FB257A62C9C0 - the first 32 bits are wrong.
How can I better understand multiplication (signed and unsigned) in ASM? The site provides answers for the questions, but I don't want to be spoonfed but rather understand what's going on instead.