Dan Sugalski <[EMAIL PROTECTED]> wrote:
Dunno what parrot thinks--it's not done yet. grep says 569 .locals and 473 temp PMC registers.
I've now enabled some more code that speeds up temp allocation more (~2.5 for 2000 temps in a unit). This needs that the usage range is limited to 10 lines. If the code from a compiler looks like the output from the program below, this works fine.
This sped it up a lot. The output is:
Starting parse... sub _MAIN: registers in .imc: I34, N0, S7, P1014 0 labels, 0 lines deleted, 0 if_branch, 0 branch_branch 0 used once deleted 0 invariants_moved registers needed: I43, N0, S12, P3327 registers in .pasm: I25, N0, S20, P32 - 464 spilled 2007 basic_blocks, 2079 edges 13691 lines compiled. Writing sample.pbc packed code 348208 bytes sample.pbc written.
Which actually came out in reasonable time, rather than me giving up after 45 minutes. :) Still takes ages, so I've a lot of work to do here.
> ... I'm rejigging the compiler to cut down on thenumber of .local declarations, but that'll increase the temp pmc usage, at least with the relatively simple temp system I've got now.
Temps are fine. ".local"s ranging from top of the program (not counting the declaration) down do hurt. Many small short ranged temps are much better then long ranged vars because they have more interferences on each other.
Hrm. Does the code currently consider something like:
$P0 = foo
to start a new lifetime for $P0?
-- Dan
--------------------------------------"it's like this"------------------- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk