News for hackers. Stuff that matters.
Re:IR is better than assembly (2013) by mahdix on Monday January 02, 2017 @01:36AM (#13299472)
This may be a little off-topic but does anyone know a good and up-to-date tutorial for using LLVM in C language?
Re:IR is better than assembly (2013) by oherrala on Monday January 02, 2017 @02:52AM (#13299678)
LLVM's C is compiler clang. You can find it from

http://clang.llvm.org/

In many cases it's just drop-in replacement for gcc.

Re:IR is better than assembly (2013) by ygra on Monday January 02, 2017 @02:57AM (#13299695)
I rather understood it that they wanted to know whether there is a C API to use LLVM, so perhaps something like this: https://pauladamsmith.com/blog/2015/01/how-to-get-started-wi...
Re:IR is better than assembly (2013) by mahdix on Monday January 02, 2017 @05:53AM (#13300414)
That's exactly what I am looking for but it's almost two years old and I think I tried it a few months back and got lots of errors. I was hoping to find a more up-to-date tutorial. Unfortunately LLVM people don't pay much attention to documentation and tutorials for their product.
Re:IR is better than assembly (2013) by the_duke on Monday January 02, 2017 @09:56AM (#13301420)
I've been there.

Pretty much the only way is to just read the C api header and figure things out from there.

It does contain comments, which are mostly helpful, but sometimes incomplete or out of date.

Re:IR is better than assembly (2013) by hyperpape on Monday January 02, 2017 @10:19AM (#13301563)
This series may also be relevant, but I never read it in full: https://msm.runhello.com/p/category/plt/no-compiler.