]> git.proxmox.com Git - qemu.git/commit
tcg/i386: Add shortcuts for registers used in L constraint
authorStefan Weil <sw@weilnetz.de>
Thu, 13 Sep 2012 17:37:44 +0000 (19:37 +0200)
committerAurelien Jarno <aurelien@aurel32.net>
Sat, 22 Sep 2012 14:52:37 +0000 (16:52 +0200)
commitb18212c66870f119111e0777fcc19462ae07eb70
tree3fc1f626cf94c3c59b29a9fba27e7cc9439e0d77
parent1b7621ad99d352629c096cba40eadc6fb2b0c294
tcg/i386: Add shortcuts for registers used in L constraint

While 64 bit hosts use the first three registers which are also used
as function input parameters, 32 bit hosts use TCG_REG_EAX and
TCG_REG_EDX which are not used in parameter passing.

After defining new register macros for the registers used in L
constraint, the patch replaces most occurrences of
tcg_target_call_iarg_regs[0], tcg_target_call_iarg_regs[1] and
tcg_target_call_iarg_regs[2] by those new macros.

tcg_target_call_iarg_regs remains unchanged when it is used for input
arguments (only with 64 bit hosts) before tcg_out_calli.

A comment related to those registers was fixed, too.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
[aurel32: build fix on i386, small optimization for i386 in the prologue]
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
tcg/i386/tcg-target.c