Hacker News new | ask | show | jobs
by _g6sn 1457 days ago
Kefir author here. Quite surprised to see it on HN. A few notes in response to Brian's post and comments:

- Kefir name is simply a reference to milk drink, no other connotation is intended. Updated project README with this information.

- The compiler is indeed quite primitive, especially, in terms of code generation. My main goal was implementing a C compiler that is reasonably compliant with language standard and platform ABIs, so I decided to simply ignore any performance considerations as I wouldn't compete with well-established compilers anyway.

Usage of threaded code is also caused by the same reason -- it is very simple to obtain assembly from intermediate representation when the assembly is mostly composed from references to runtime routines. Even without considering more sophisticated schemes of code generation, current approach is not optimal -- threaded code encoding scheme is very wasteful in terms of generated code (which was also noted in the blog post) and has awful runtime performance.

- I have tried to keep compiler compliant with the standard as well as compatible some of widespread C extensions (with some exceptions which I listed in README). Will try to address compilation errors found by Brian. Unfortunately, currently I do not have much time to work on the compiler. Identifying and fixing such bugs might also be quite tedious, so I expect that there are enough unnoticed compatibility problems there.

- Patches implementing OpenBSD support are appreciated. I plan to integrate those into the main code tree at some point.

2 comments

bumping the author's chain and bluntly suggesting that others (like myself) without much/any stake in openBSD's C compilers should stfu with the name flaming now, because the fact that it's still continuing in replies at this point is more a matter of narcissism and disrespect for the submission than anything else.
Heh, when I saw a C compiler named "kefir", I immediately thought that it must be made by someone from the former USSR.
Summertime: refrigeration is nowhere, so kefir is everywhere...

Good times.