mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 16:23:55 -06:00
tcg: Introduce arg_temp
Reviewed-by: Emilio G. Cota <cota@braap.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Richard Henderson <rth@twiddle.net>
This commit is contained in:
parent
dd18629201
commit
434391390b
3 changed files with 32 additions and 28 deletions
|
@ -133,7 +133,7 @@ static TCGArg find_better_copy(TCGContext *s, TCGArg temp)
|
|||
}
|
||||
|
||||
/* If it is a temp, search for a temp local. */
|
||||
if (!s->temps[temp].temp_local) {
|
||||
if (!arg_temp(temp)->temp_local) {
|
||||
for (i = temps[temp].next_copy ; i != temp ; i = temps[i].next_copy) {
|
||||
if (s->temps[i].temp_local) {
|
||||
return i;
|
||||
|
@ -207,7 +207,7 @@ static void tcg_opt_gen_mov(TCGContext *s, TCGOp *op, TCGArg dst, TCGArg src)
|
|||
}
|
||||
temps[dst].mask = mask;
|
||||
|
||||
if (s->temps[src].type == s->temps[dst].type) {
|
||||
if (arg_temp(src)->type == arg_temp(dst)->type) {
|
||||
temps[dst].next_copy = temps[src].next_copy;
|
||||
temps[dst].prev_copy = src;
|
||||
temps[temps[dst].next_copy].prev_copy = dst;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue