3 ms·
> Is it actually a JIT? It's just compiling everything unconditionally. Still counts as JIT in my book, but you're right that it's a bit subtle. Unix-style co
by MaxBarraclough 9y ago
> Is it actually a JIT? It's just compiling everything unconditionally.
Still counts as JIT in my book, but you're right that it's a bit subtle.
Unix-style configure/build/install isn't considered JIT.
Installing a .Net application is pretty similar, but we don't consider it JIT.
In the usual .Net model, what's distributed is IR rather than source-code. Compilation to native code happens at install time. The build-and-install process is less explicit than the Unix way, and it's less error-prone (fewer dependency issues and issues with the compiler not liking your source code).
Really it's a very similar model to the Unix one, but we call one JIT and not the other.
Oracle Java, of course, only ever compiles to native code at runtime, and never caches native code. 'Proper' JIT. (This may be set to change in the near future though.)
Interestingly, .Net seems to be moving in the direction of full static compilation, or they wouldn't be asking devs to rebuild UWP apps to incorporate framework fixes - https://aka.ms/sqfj4h/ https://aka.ms/sqfj4h/
- caf 9y agoIt might be fun to make a source-based distribution where every binary in /usr/bin started off as a link to a script that built and installed the requested executable (over the top of the link), before executing it.
- _jal 9y agoWouldn't be difficult to modify FreeBSD to do that. /usr/ports is just a little more than one indirection away.
- uep 9y agoOr how about a fuser filesystem on Linux to do the same? That sounds like an interesting idea. Just don't make the mistake of accidentally typing some obscenely large binary like firefox, chrome, or clang... I think it would need to be integrated into the package management system pretty tightly (or have one of its own) to get all of the shared library dependencies.
- MaxBarraclough 9y agoSource-based distros essentially do that, they just cache the binaries. Various research OSs are JIT-based, of course. It looks like JX (a Java operating system) caches its native code, so it's not 'pure JIT' https://github.com/mczero80/jx/blob/5fbeae79/libs/compiler_env/jx/compiler/persistent/CodeFile.java#L343 https://github.com/mczero80/jx/blob/5fbeae79/libs/compiler_e... It looks like Cosmos (a C# operating system) does the same https://en.wikipedia.org/wiki/IL2CPU https://en.wikipedia.org/wiki/IL2CPU