tcg/optimize: rework copy progagation
The copy propagation pass tries to keep track what is a copy of whatand what has copy of what, and in addition it keep a circular list ofof all the copies. Unfortunately this doesn't fully work: a mov froma temp which has a state "COPY" changed it into a state "HAS_COPY"....
tcg/optimize: do copy propagation for all operations
It is possible to due copy propagation for all operations, even the onethat have side effects or clobber arguments (it only concerns inputarguments). That said, the call operation should be handled differently...
tcg/mips: optimize brcond arg, 0
MIPS has some conditional branch instructions when comparing with zero.Use them.
Reviewed-by: Richard Henderson <rth@twiddle.net>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
tcg/mips: optimize bswap{16,16s,32} on MIPS32R2
bswap operations can be optimized on MIPS32 Release 2 using the ROTR,WSBH and SEH instructions. We can't use the non-R2 code to implement theops due to registers constraints, so don't define the corresponding...
tcg/mips: implement rotl/rotr ops on MIPS32R2
rotr operations can be optimized on MIPS32 Release 2 using the ROTR andROTRV instructions. Also implemented rotl operations by subtracting theshift from 32.
Reviewed-by: Richard Henderson <rth@twiddle.net>...
tcg/mips: implement deposit op on MIPS32R2
deposit operations can be optimized on MIPS32 Release 2 using the INSinstruction.
tcg/mips: implement movcond op on MIPS32R2
movcond operation can be implemented on MIPS32 Release 2 using the MOVN,MOVZ, SLT and SLTU instructions.
tcg/optimize: remove TCG_TEMP_ANY
TCG_TEMP_ANY has no different meaning than TCG_TEMP_UNDEF, so usethe later instead.
tcg/optimize: check types in copy propagation
The copy propagation doesn't check the types of the temps during copypropagation. However TCG is using the mov_i32 for the i64 to i32conversion and thus the two are not equivalent.
With this patch tcg_opt_gen_mov() doesn't consider two temps of...
tcg/mips: use stack for TCG temps
Use stack instead of temp_buf array in CPUState for TCGtemps.
View all revisions | View revisions
Also available in: Atom