The fact that the "language" is still Python code which has to be traced in some way is a bit off-putting. It feels a bit hacky. I'd rather a separate compiler, honestly.

Mojo for python syntax without the ast walking decorator, cuda for c++ syntax over controlling the machine, ah hoc code generators writing mlir for data driven parametric approaches. The design space is filling out over time.

The fact that these are all add on syntaxes is strange. I have my ideas about why (like you want to write code that cooperates with host code).

Do any of y’all have clear ideas about why it is that way? Why not have a really great bespoke language?

Hard to beat trifecta of familiar language, same source files and toolchain, JIT compiled

That’s sort of what I assumed, yeah. And I think that makes sense.

But they end up adding super sophisticated concepts to the familiar language. Makes me wonder if the end result is actually better than having a bespoke language.

I mean you used to be able to write TTGIR directly this is mostly sugar on top of that

This is pretty common among these ml toolchain, and not a big deal. They use pythons ast lib and the function annotations to implement an ast walker and code generator. It works quite well.

Yeah that struck me as odd. It's more like a Python library or something.

It’s a dsl not a library. The kernel launch parameters and the ast walk generate ir from the Python.