Benchmarks with TextMate's manual

2007-08-27 Thread Michel Fortin
The following benchmarks have been obtained using the TextMate manual as the input source: Using PHP Markdown, parsing the 24 files separately (with the reference file appended to each of them), I get this (on an iBook G4 1.2 Ghz):

Re: Benchmarks with TextMate's manual

2007-08-27 Thread Andrea Censi
On 8/27/07, Michel Fortin <[EMAIL PROTECTED]> wrote: > The following benchmarks have been obtained using the TextMate manual > as the input source: > > > ... > Now, the interesting part of the test: combining all the documents > together and pars

Re: Benchmarks with TextMate's manual

2007-08-27 Thread John Fraser
On 8/27/07, Andrea Censi <[EMAIL PROTECTED]> wrote: > Maruku takes 8 seconds for parsing (on my PowerBook G4 1.5GHz). > (please note that Ruby, per se, is much slower than Perl) > > I guess that if you plot [time for parsing] versus [length of the > document], you get a curve which grows more than

Re: Benchmarks with TextMate's manual

2007-08-28 Thread Andrea Censi
On 8/28/07, John Fraser <[EMAIL PROTECTED]> wrote: > One implementation of the current Markdown algorithm can actually beat > Maruku's time: [Showdown] is a straight JavaScript port of > Markdown.pl, but it converts the TextMate in under 4 seconds (in > Firefox, on an ancient machine). Maruku's pe

Re: Benchmarks with TextMate's manual

2007-08-28 Thread John Fraser
On 8/28/07, Andrea Censi <[EMAIL PROTECTED]> wrote: > No, there isn't room for improvement. Because of the successive > regexps being applied over and over again, it's quite hard to make one > little change in the syntax without screwing up something down the > line. > If you have a parser, you kno

Re: Benchmarks with TextMate's manual

2007-08-28 Thread Michel Fortin
Here's a little followup on what I wrote earlier with a few more details and some good news for PHP Markdown. First, there has been an error in my previous benchmarks. Merging all the documents together creates a 176 Kb file, not 352 Kb as previously mentioned. I'm not sure how this happend

Re: Benchmarks with TextMate's manual

2007-08-28 Thread Michel Fortin
Le 2007-08-28 à 5:27, Andrea Censi a écrit : No, there isn't room for improvement. Because of the successive regexps being applied over and over again, it's quite hard to make one little change in the syntax without screwing up something down the line. That's not really true anymore with PHP M

Re: Benchmarks with TextMate's manual

2007-08-28 Thread John Fraser
On 8/28/07, Michel Fortin <[EMAIL PROTECTED]> wrote: > With "unhash" fixed now (using a regular expression!) and with some > other speed improvements, I can announce that the next version of PHP > Markdown will parse the one-document TextMate manual in about 1.5 > seconds. This is now 0.5 second fa

Re: Benchmarks with TextMate's manual

2007-08-28 Thread Michel Fortin
Le 2007-08-28 à 13:43, John Fraser a écrit : That's great news! I think your numbers show that my claim that Markdown.pl can be made "five to ten times faster with a few hours of work" is actually pretty conservative. Perhaps. I'm not quite sure what's the culprit in Markdown.pl, although I

Re: Benchmarks with TextMate's manual

2007-08-28 Thread John Fraser
On 8/28/07, Michel Fortin <[EMAIL PROTECTED]> wrote: > I'm not quite sure what's the culprit in Markdown.pl, although I > suspect the overuse of the HTML block parser to hash Markdown- > generated markup is part of it. That's one thing I've removed in the > many architectural changes PHP Markdown p