Cleanups within TCG middle-end
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest16 patches 22 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/16 | tcg: Merge opcode arguments into TCGOptcg/ tcg/ tcg/ +1 more | +94 | 2 replies | |
| 2/16 | tcg: Propagate args to op->args in optimizertcg/ | +227 | 1 reply | |
| 3/16 | tcg: Propagate args to op->args in tcg.ctcg/ | +58 | 2 replies | |
| 4/16 | tcg: Propagate TCGOp down to allocatorstcg/ | +40 | 1 reply | |
| 5/16 | tcg: Introduce arg_temptcg/ tcg/ tcg/ | +32 | 1 reply | |
| 6/16 | tcg: Add temp_global bit to TCGTemptcg/ tcg/ tcg/ | +24 | 3 replies | |
| 7/16 | tcg: Return NULL temp for TCG_CALL_DUMMY_ARGtcg/ | +1 | 2 replies | |
| 8/16 | tcg: Introduce temp_argtcg/ tcg/ | +9 | 0 replies | |
| 9/16 | tcg: Use per-temp state data in livenesstcg/ tcg/ | +120 | 2 replies | |
| 10/16 | tcg: Avoid loops against variable boundstcg/ | +10 | 1 reply | |
| 11/16 | tcg: Change temp_allocate_frame arg to TCGTemptcg/ | +3 | 0 replies | |
| 12/16 | tcg: Remove unused TCG_CALL_DUMMY_TCGVtcg/ | +0 | 1 reply | |
| 13/16 | tcg: Export temp_idxtcg/ tcg/ | +10 | 2 replies | |
| 14/16 | tcg: Use per-temp state data in optimizetcg/ tcg/ | +249 | 1 reply | |
| 15/16 | tcg: Define separate structures for TCGv_*tcg/ tcg/ | +146 | 0 replies | |
| 16/16 | tcg: Store pointers to temporaries directly in TCGArgtcg/ tcg/ | +12 | 0 replies |
Reviews trailers per patch
6 of 16 patches have a Reviewed-by or Acked-by.
| Patch | Alex Bennée |
|---|---|
| 1/16 | |
| 2/16 | R-b |
| 3/16 | R-b |
| 4/16 | R-b |
| 5/16 | R-b |
| 6/16 | |
| 7/16 | |
| 8/16 | |
| 9/16 | |
| 10/16 | R-b |
| 11/16 | |
| 12/16 | R-b |
| 13/16 | |
| 14/16 | |
| 15/16 | |
| 16/16 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [Qemu-devel] [PATCH 00/16] Cleanups within TCG middle-end
There are two conceptually unrelated cleanups in here, though the second touches many of the same lines as the first, so separating the two would be ugly.
The first is to split gen_opparam_buf and move the pieces into TCGOp. This has two effects: the operands for an op is in the same cacheline as the op, and we get to drop the pointer into gen_opparam_buf, freeing up a register and/or function argument.
The second is to change what value is stored in TCGArg for each TCG temporary. Rather than store the index into tcg_ctx.temps, store the pointer to the temp itself. This allows us to drop some arithmetic on many uses of a temp within the backend.
Making that second change is tricky, as we don't want to miss any of the places that ought to be changed. To do that I introduce a number of helpers.
As a final step I changed the type of TCGOp.args to a structure, and annotated the places that access constant arguments. I found that final patch to be really ugly, so I dropped it. But I'm fairly confident that I've updated all of the non-constant args.
The effect of this is nearly noise, but does reduce code size,
text data bss dec hex filename
6648688 2106408 4486112 13241208 ca0b78 qemu-system-alpha (before)
6627656 2106408 4502496 13236560 c9f950 qemu-system-alpha (after)
or about 21k.
r~
Richard Henderson (16):
tcg: Merge opcode arguments into TCGOp
tcg: Propagate args to op->args in optimizer
tcg: Propagate args to op->args in tcg.c
tcg: Propagate TCGOp down to allocators
tcg: Introduce arg_temp
tcg: Add temp_global bit to TCGTemp
tcg: Return NULL temp for TCG_CALL_DUMMY_ARG
tcg: Introduce temp_arg
tcg: Use per-temp state data in liveness
tcg: Avoid loops against variable bounds
tcg: Change temp_allocate_frame arg to TCGTemp
tcg: Remove unused TCG_CALL_DUMMY_TCGV
tcg: Export temp_idx
tcg: Use per-temp state data in optimize
tcg: Define separate structures for TCGv_*
tcg: Store pointers to temporaries directly in TCGArg
tcg/optimize.c | 647 ++++++++++++++++++++++++++++++++------------------------- tcg/tcg-op.c | 99 ++++----- tcg/tcg.c | 610 ++++++++++++++++++++++++----------------------------- tcg/tcg.h | 287 ++++++++++++++----------- 4 files changed, 841 insertions(+), 802 deletions(-)
Signature · 1 line
2.9.4