From: Nicholas Clark Date: Tue, 7 Mar 2006 19:31:49 +0000 (+0000) Subject: Two more TODOs for those with C knowledge. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=98fed0adfc8a6b4cff1d77d3f468d26b27488d51;p=p5sagit%2Fp5-mst-13.2.git Two more TODOs for those with C knowledge. p4raw-id: //depot/perl@27406 --- diff --git a/pod/perltodo.pod b/pod/perltodo.pod index f4f9f59..c87c9a1 100644 --- a/pod/perltodo.pod +++ b/pod/perltodo.pod @@ -372,6 +372,31 @@ anyone feeling like exercising their skill with coverage and profiling tools might want to determine what ops I are the most commonly used. And in turn suggest evictions and promotions to achieve a better F. +=head2 Shrink struct context + +In F, we have + + struct context { + U32 cx_type; /* what kind of context this is */ + union { + struct block cx_blk; + struct subst cx_subst; + } cx_u; + }; + +There are less than 256 values for C, and the constituent parts +C and C both contain some C and C fields, +so it should be possible to move them to the first word, and share space with +a C C, saving 1 word. + +=head2 Allocate OPs from arenas + +Currently all new OP structures are individually malloc()ed and free()d. +All C implementations have space overheads, and are now as fast as +custom allocates so it would both use less memory and less CPU to allocate +the various OP structures from arenas. The SV arena code can probably be +re-used for this. +