mirror of
https://git.proxmox.com/git/qemu
synced 2025-08-09 08:15:46 +00:00
tcg-i386: Tidy initialization of tcg_target_call_clobber_regs.
Setting the registers one by one is easier to read, and gets optimized by the compiler just the same. Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
This commit is contained in:
parent
6648e29608
commit
4ab50ccf61
@ -1360,10 +1360,11 @@ void tcg_target_init(TCGContext *s)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
tcg_regset_set32(tcg_target_available_regs[TCG_TYPE_I32], 0, 0xff);
|
tcg_regset_set32(tcg_target_available_regs[TCG_TYPE_I32], 0, 0xff);
|
||||||
tcg_regset_set32(tcg_target_call_clobber_regs, 0,
|
|
||||||
(1 << TCG_REG_EAX) |
|
tcg_regset_clear(tcg_target_call_clobber_regs);
|
||||||
(1 << TCG_REG_EDX) |
|
tcg_regset_set_reg(tcg_target_call_clobber_regs, TCG_REG_EAX);
|
||||||
(1 << TCG_REG_ECX));
|
tcg_regset_set_reg(tcg_target_call_clobber_regs, TCG_REG_EDX);
|
||||||
|
tcg_regset_set_reg(tcg_target_call_clobber_regs, TCG_REG_ECX);
|
||||||
|
|
||||||
tcg_regset_clear(s->reserved_regs);
|
tcg_regset_clear(s->reserved_regs);
|
||||||
tcg_regset_set_reg(s->reserved_regs, TCG_REG_ESP);
|
tcg_regset_set_reg(s->reserved_regs, TCG_REG_ESP);
|
||||||
|
Loading…
Reference in New Issue
Block a user