x86_push(p->func, p->outbuf_EBX);
x86_push(p->func, p->count_EBP);
-/* on non-Win64 x86-64, these are already in the right registers */
+ /* on non-Win64 x86-64, these are already in the right registers */
if(x86_target(p->func) != X86_64_STD_ABI)
{
x86_push(p->func, p->machine_EDI);
x86_push(p->func, p->idx_ESI);
- x86_mov(p->func, p->machine_EDI, x86_fn_arg(p->func, 1));
- x86_mov(p->func, p->idx_ESI, x86_fn_arg(p->func, 2));
+ if(x86_target(p->func) != X86_32)
+ {
+ x64_mov64(p->func, p->machine_EDI, x86_fn_arg(p->func, 1));
+ x64_mov64(p->func, p->idx_ESI, x86_fn_arg(p->func, 2));
+ }
+ else
+ {
+ x86_mov(p->func, p->machine_EDI, x86_fn_arg(p->func, 1));
+ x86_mov(p->func, p->idx_ESI, x86_fn_arg(p->func, 2));
+ }
}
x86_mov(p->func, p->count_EBP, x86_fn_arg(p->func, 3));