3 ms·
> given that the machine code is an intermediate product The machine code isn't the intermediate product - it's the final product. Some internal IR is the inte
by chrisseaton 8y ago
> given that the machine code is an intermediate product
The machine code isn't the intermediate product - it's the final product. Some internal IR is the intermediate product.
But yes it's normal convention in the industry to talk about JIT compilation to machine code as 'compiling to machine code'.
- amelius 8y agoBut let's say, they added "decompilers" to the graph, and there is (say) a decompiler from machine code to C. Then I'd assume, because there is a path in the graph from JavaScript to C (going through machine code), that I can translate from JavaScript to C. Except this isn't true because V8 is a JIT, and doesn't output its internal representation.
- chrisseaton 8y agoIt's not a graph of compilers to a file on disk. It's a graph of compilers. Just because it exists only in memory doesn't mean it doesn't exist. Has the JavaScript been compiled to machine code. Yes, it has. You mean that the JavaScript compilation is only valid for a given application at a given point in time? Yes that's true.
- amelius 8y agoWhat I meant is: the graph is more useful if you can apply the relations transitively (i.e. find one or more paths between any two languages, and use the compilers to walk along the path). The demo even suggests that by allowing you to find a path, and leave the "directly" box unchecked.