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

Re: Bringing the regex compiler into the current millenium.

Thread Previous | Thread Next
From:
Father Chrysostomos
Date:
October 23, 2014 15:31
Subject:
Re: Bringing the regex compiler into the current millenium.
Message ID:
20141023153105.22274.qmail@lists-nntp.develooper.com
Yves Orton wrote:
> I will work on a branch (name to be announced)

Minnow?

> 1. Change the current awkward multi-pass lexer, into a single pass lexer
> which constructs an AST

Sounds like toke.c+perly.y.

> which is then analysed and optimised, which woud
> then be used to produce the final encoded program.

op.c. :-)

This approach would make sense to me, at least.  I might start to
understand more of the regexp engine.

> 4. If possible I would like to have a process wide cache of pattern
> snippets that can be used to speed compilation and reduce memory pressure
> from regexes. There should be no need for a perl process to have more than
> one /\s+/ pattern compiled for instance.

Process-wide or thread-wide?  This sounds like PL_strtab for regexps.

> In general my objective is not to improve performance at first, but rather
> to simply make the process sane to understand, and easier to implement. I
> believe that once the code has been restructured to be easier to understand
> and work with we will find performance improvements come along for the
> ride, or at the very least, are much easier to implement.

I say go for it.

> I welcome any interest in this project. Please let me know if you have any
> thoughts or wish to contribute.

I cannot promise any contributions, but if you push updates to the
branch regularly (even WIP commits), I'll review it and may even com-
ment on it.


Thread Previous | 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