4 ms·
> To make a long story short: very old versions of http_parser were based on a Ragel grammar but the handwritten version outperformed it by a significant margin
by jacobr 13y ago
> To make a long story short: very old versions of http_parser were based on a Ragel grammar but the handwritten version outperformed it by a significant margin, as in over 10% fewer branches taken.
> Ragel is great but it can't take shortcuts like a human programmer can and once you start jumping around in your grammar, things become complicated fast (and impossible to debug.)
https://github.com/joyent/http-parser/pull/156#issuecomment-22933119 https://github.com/joyent/http-parser/pull/156#issuecomment-...
- Filligree 13y agoSo yeah, at least they get the wrong answer quickly.