3 points · by speckx · 1w ago · 1 comment
Beyond that, the agents are applying computational theory to a problem, solving it, and then using the syntax of the chosen language.
For my own personal language (https://compile-xc.org), the LLM has written some pretty solid code (including a lot of the compiler itself, in xc). The key issue with xc is that it automatically parallelises and vectorises the same source-code to both CPU threads and GPU(s). That's not a common paradigm and Claude manages it just fine.
I see this "if it's not trained on it, it can't do it" attitude (to a greater or lesser extent) fairly commonly. LLMs don't necessarily need example code, they need to understand the problem, and understand the syntax of the output format they're asked for. The first of those is fairly commonly in their training data, and the second can be learnt within the session context if it's not humungous.
In xc's case (and why Claude handles it well) you write ordinary loops and let xcc handle the heavy lifting of auto-parallelisation and GPU dispatch. Ironically, an LLM is probably more reliable writing a clean GPU-based loop in xc than writing raw CUDA, Vulkan, and OpenMP boilerplate from scratch, even though CUDA has orders of magnitude more training data