logo       

Re: Fusion-ifying proto parse trees: msg#00067

parsers.spirit.devel

Subject: Re: Fusion-ifying proto parse trees

Eric Niebler wrote:

Joel de Guzman wrote:
Eric Niebler wrote:
Time taken to construct the ET and traverse it was measured. The winner by a wide margin is (3) segmented proto.

Great! It would be nice if the 1) time taken to construct the ET
and 2) the time to traverse it, are reported separately. For spirit,
while 1 is important, 2 is more important by a wide margin. It's
a balance, I can tolerate a few clock cycles for 1 if that would
improve 2. So, it's very important to see both timings.


What is it about Spirit's usage scenario that makes traversal time more important than ET construction time? I ask because it could affect the design. My understanding is that you wanted the first-phase proto ET to be immediately executable because people declare rules inline in calls to spirit::parse, where they are immediately executed without the opportunity for a 2nd ET phase. In this scenario, it seems to me the only thing that matters is end-to-end time: ET construction + traversal. Or have I been working with the wrong usage scenario in mind?

You spend more time traversing the nodes than in the one-time-only
construction. That's why. Consider a trivial parser:

parse(f,l, int_ >> *(',' >> int_));

You construct the parser only once, but you traverse the parser nodes
N times. And N can be significant in a lot of cases. Megabytes of
stuff to parse is not unimaginable.

It would also be nice to see the App footprint, but I guess it's
too early to do that now.

What is "App footprint"? Code size? Memory usage?

Code size, I think. But forget that for now.

Cheers,
--
Joel de Guzman
http://www.boost-consulting.com
http://spirit.sf.net



-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise