jgm / djot.js

JavaScript implementation of djot
MIT License
155 stars 18 forks source link

inlines: make this.matches a dense rather than sparse array. #24

Closed jgm closed 1 year ago

jgm commented 1 year ago

This yields a 10-15% speeed boost in my tests. See #13.

However, we now fail a couple of smart quote tests. I need to look into that.

jgm commented 1 year ago

OK, this seems to work well now. I'm getting > 2X speedup in the most favorable benchmarks!

jgm commented 1 year ago

On a real-world case parsing goes from 55ms too 40ms.

matklad commented 1 year ago

Nice!