4 ms·
> the lowest common denominator of operations? Note that in recent years the chosen LCD for some distros has changed - they're starting to target the v2 featur
by o11c 2y ago
> the lowest common denominator of operations?
Note that in recent years the chosen LCD for some distros has changed - they're starting to target the v2 feature set rather than the original.
See https://developers.redhat.com/blog/2021/01/05/building-red-hat-enterprise-linux-9-for-the-x86-64-v2-microarchitecture-level https://developers.redhat.com/blog/2021/01/05/building-red-h...
> Do dynamic languages (Javascript, Python, PHP...) get a speed boost because they can compile just in time and use all the features of the user's CPU?
Dynamically-typed languages can't benefit from this at all (they may include a C library that uses runtime dispatch though). Statically-typed JIT'ed languages like Java can (and you see occasional "look, Java is faster than C" benchmarks citing this), but only if you avoid classes and use only arrays. C# can do better than Java but still suffers from its Windows-centric history.
- neonsunset 2y ago> but only if you avoid classes and use only arrays Please do look into the kind of codegen emitted by OpenJDK and .NET before assuming this. It's a bit difficult with -XX:+PrintAssembly and much easier with DOTNET_JitDisasm='pattern'/Disasmo/NativeAOT+Ghidra. Once you do, you will clearly see how the exact set of ISA extensions influences instruction selection for all sorts of operations like stack zeroing, loads/stores, loop vectorization (automatic or manual), etc. .NET has extensive intrinsics and portable SIMD APIs that use effectively static dispatch even if the path is still picked at runtime, but just once during JIT compilation. > still suffers from its Windows-centric history. This is a provably wrong, especially in peformance-related scenarios.
- o11c 2y agoIn non-performance contexts, C# still suffers from the fact that I can't just reach out and install it from any random distro. The only other major languages with a comparable problem are Kotlin and Swift, which suffer from a similar association with Android and Mac OS, respectively.
- neonsunset 2y agoYou can, except Debian but that’s Debian for you. sudo apt/dnf install dotnet-sdk-8.0 For Debian use this: https://learn.microsoft.com/en-us/dotnet/core/install/linux-debian https://learn.microsoft.com/en-us/dotnet/core/install/linux-... It is a better user experience than dealing with C/C++ or Java tooling too. For shipping packages you don’t even need this since you can just publish them as self-contained or as native binaries.