Re:A Complete Guide to LLVM for Programming Language Creators
by tylersmith on Friday December 25, 2020 @11:48PM
(#25541463)
I see, in this case the author's compiler was written in c++, but you can use ocaml instead to build the IR. There is even a version of their great tutorial series using ocaml you can check out. All the concepts he outlines are the same, just convert the c++ bits to the corresponding ocaml version of the IRBuilder. Then you can go from your language to llvm IR all in ocaml.
Re:A Complete Guide to LLVM for Programming Language Creators
by CGamesPlay on Saturday December 26, 2020 @12:38AM
(#25541671)
Ah, I understand now. Thanks for helping!
[0] https://news.ycombinator.com/item?id=25540637