Search code examples
assemblynasminstructions

What if we want to load more instructions than the number of registers available at a time...?


I am referring to NASM. There are some standard registers in which we load instructions before calling the kernel.

I wanted to know if at some point we want to load more instructions than the number of registers available then what should we do.....???

Newbie to assembly. Pls Help..


Solution

  • In practice, for 32-bit system calls, if there are more parameters than we have registers (sooner than that, IME) we put the parameters in a structure and point ebx or ecx to it (sys_socketcall, e.g.). I'm new to 64-bit, but I imagine rdi... I think that's what you're asking. Got a specific example?