4 ms·
I don't follow. Nim uses C as an intermediate representation, just like many languages use LLVM-IR, Gimple, javascript, etc. If you care about the assembly a p
by fluffything 7y ago
I don't follow. Nim uses C as an intermediate representation, just like many languages use LLVM-IR, Gimple, javascript, etc.
If you care about the assembly a piece of code generates, you can just look at that.
The generated C code that Nim emits looks like what it is: boring automatically-generated C code.
If you wanted to debug the compiler, you could take a look at that, but most users don't have to.
- lmm 7y agoC is a very complicated language with very complex compilers. The translation from C to assembly (under modern compilers) is hard to understand, even for "boring automatically-generated C code". Languages like LLVM-IR or Gimple are designed to be simple and translate more directly into assembly. I'd have the same complaint about javascript to a certain extent, but even though it's a full programming language it's a much simpler language than C and easier to introspect at runtime.