Akuli / jou

Yet another programming language
MIT License
11 stars 4 forks source link

Compiling the self-hosted compiler is really slow #319

Closed Akuli closed 1 year ago

Akuli commented 1 year ago

Emitting parser.o (the object file for parser.jou) takes about 1 minute, which is surprising because parser.jou isn't that complicated and the corresponding C code compiles in less than a second.

I think the reason is that the optimized LLVM IR looks very repetitive. It seems to initialize and copy large structs with one instruction for each struct element instead of using a memcpy.