4 ms·
Cwerg tries to hit a different sweet spot: It has an intentionally bigger LOC/complexity budget to allow for more features and better performance. Instead of h
by muth02446 3y ago
Cwerg tries to hit a different sweet spot: It has an intentionally bigger LOC/complexity budget to allow for more features and better performance.
Instead of having the whole system be understandable by a single person, each major component should be.
In fact the 10kLOC applies to the frontend and each backend separately which I think is fair as most compiler writers use off the shelf backends like QBE, LLVM or even C.
- lproven 3y agoAll right. I am no expert in compilers, but how does it compare to, say... • TinyC – https://bellard.org/tcc/ https://bellard.org/tcc/ • Small-C – https://en.wikipedia.org/wiki/Small-C https://en.wikipedia.org/wiki/Small-C • Smaller C – https://github.com/alexfru/SmallerC https://github.com/alexfru/SmallerC …?
- buescher 3y agoOr, for that matter, the original 70's K&R compiler, right? It's probably at the right size for exploring some language ideas.
- muth02446 3y agoThe title omits a crucial word. Cwerg aims to be the best c-like language that can be implemented in 10kLOC. Obviously, best is highly subjective but I want to improve on C not just re-implement it.