News for hackers. Stuff that matters.
Re:Meta Releases LLM Compiler by cec on Friday June 28, 2024 @04:17PM (#40824813)
Hey! The idea isn't to replace the compiler with an LLM, the tech is not there yet. Where we see value is in using these models to guide an existing compiler. E.g. orchestrating optimization passes. That way the LLM won't break your code, nor will the compiler (to the extent that your compiler is free from bugs, which can tricky to detect - cf Sec 3.1 of our paper).
Re:Meta Releases LLM Compiler by swyx on Friday June 28, 2024 @08:03PM (#40826694)
then maybe dont name it "LLM Compiler", just "Compiler Guidance with LLMs" or "LLM-aided Compiler optimization" or something - will get much more to the point without overpromising
Re:Meta Releases LLM Compiler by nickpsecurity on Friday June 28, 2024 @11:37PM (#40827714)
Yeah, the name was misleading. I thought it was going to be source to object translation maybe with techniques like how they translate foreign languages.
Re:Meta Releases LLM Compiler by verditelabs on Friday June 28, 2024 @05:07PM (#40825317)
I've done some similar LLM compiler work, obviously not on Meta's scale, teaching an LLM to do optimization by feeding an encoder/decoder pairs of -O0 and -O3 code and even on my small scale I managed to get the LLM to spit out the correct optimization every once and a while.

I think there's a lot of value in LLM compilers to specifically be used for superoptimization where you can generate many possible optimizations, verify the correctness, and pick the most optimal one. I'm excited to see where y'all go with this.

Re:Meta Releases LLM Compiler by viraptor on Friday June 28, 2024 @05:25PM (#40825442)
Thank you for freeing me from one of my to-do projects. I wanted to do a similar autoencoder with optimisations. Did you write about it anywhere? I'd love to read the details.
Re:Meta Releases LLM Compiler by verditelabs on Friday June 28, 2024 @05:34PM (#40825516)
No writeup, but the code is here:

https://github.com/SuperOptimizer/supercompiler

There's code there to generate unoptimized / optimized pairs via C generators like yarpgen and csmith, then compile, train, inference, and disassemble the results

Re:Meta Releases LLM Compiler by hughleat on Saturday June 29, 2024 @11:50AM (#40831425)
Yes! An AI building a compiler by learning from a super-optimiser is something I have wanted to do for a while now :-)
Re:Meta Releases LLM Compiler by moffkalast on Friday June 28, 2024 @06:02PM (#40825744)
> The idea isn't to replace the compiler with an LLM, the tech is not there yet

What do you mean the tech isn't there yet, why would it ever even go into that direction? I mean we do those kinds of things for shits and giggles but for any practical use? I mean come on. From fast and reliable to glacial and not even working a quarter of the time.

I guess maybe if all compiler designers die in a freak accident and there's literally nobody to replace them, then we'll have to resort to that after the existing versions break.