I built a 2x faster lexer, then discovered I/O was the real bottleneck

2 pointsposted 13 days ago
by p4bl0

2 Comments

arter45

13 days ago

>Memory-mapping the files made things worse due to the per-file mmap/munmap overhead

Could you elaborate on this?

p4bl0

13 days ago

I'm not the author, I just shared this article I came across on Mastodon because it was an interesting read!

I just found out it was already posted on HN by its author here: https://news.ycombinator.com/item?id=46693460

I don't know why HN let me post the same link less than two hours after it was already posted. Usually when this happens I'm redirected to the existing post and it is automatically upvoted, which I think is a nice behavior.