develooper Front page | perl.perl5.porters | Postings from July 2010

Re: [perl #76438] peephole optimiser could prune more dead code

Thread Previous | Thread Next
Leon Timmermans
July 10, 2010 11:09
Re: [perl #76438] peephole optimiser could prune more dead code
Message ID:
On Sat, Jul 10, 2010 at 4:17 PM, demerphq <> wrote:
> I also proposed a "no magic" pragma/syntax that would allow the
> optimiser to assume that all variables were "normal", and that funky
> stuff wasnt going to occur during the scope of the pragma. And in such
> a block i would expect this to block to be optimised away.

The use of magic is too pervasive for that. Not only because many
special variables use active magic ($!, $1, %ENV, %SIG, etc…) but also
autovivication, m//g state, tainting and utf8 caching, $#array, pos(),
lvalue substr(), scalar(keys) and a number of more obscure things.

I don't think it's workable.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About