C89 compiler produces printable executables from C code [pdf] (2017)

CharlesW | 125 points

The author is an absolute legend. Absolutely every video on his Youtube channel is a masterpiece

https://www.youtube.com/@tom7

And this includes the video that explains this code (Compiling C to printable x86, to make an executable research paper)

https://www.youtube.com/watch?v=LA_DrBwkiJA

nextaccountic | 2 years ago

(2017), but still worth reading again.

There is actually a more "traditional" way of doing this, which is to convert a regular executable to an ASCII one using a separate tool: https://news.ycombinator.com/item?id=16312562

userbinator | 2 years ago

Recently I was working on something like that [1]. Basically I created simple C compiler (with IR and other stuff) that compiles code to basic X86 16bit instructions which can be directly booted into real mode.

[1] https://github.com/Mati365/ts-c-compiler

mati365 | 2 years ago

What is sigbovik like, and did he present this at that conference?

kzrdude | 2 years ago

I've read this paper a few years ago, it's a timeless classic :)

Pannoniae | 2 years ago

It’s only a matter of time before someone writes a meta-verilog wrapper for this and the universe implodes.

K0balt | 2 years ago
[deleted]
| 2 years ago