develooper Front page | perl.perl5.porters | Postings from September 2014

PL_comppad_name at run time?

Thread Next
From:
Father Chrysostomos
Date:
September 23, 2014 15:38
Subject:
PL_comppad_name at run time?
Message ID:
20140923153823.6115.qmail@lists-nntp.develooper.com
Currently we set up PL_curpad to point to the sub’s pad in
pp_entersub.  But anything that needs to access the name pad (only
lexical subs, I think) has to call find_runcv, which searches the call
stack, and then extract the name pad from it.

If we introduce lvalue references (which I am working on now), lexical
scalars and state variables will have to access the name pad.  That
will slow things down considerably.

I know that pp_entersub avoids unnecessary work because it is very hot
code, but I think that having it set PL_comppad_name (or maybe a new
PL_curpad_name) would be a reasonable tradeoff.

Thoughts?


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About