Why isn't it called wasm32-none-none?
What the hell is a target triple?
81–90 of 139 posts
Re: What the hell is a target triple?
#82Earlier quoted context omitted.
IBM's Power chips can run in either little or big modes, but "used a lot" is a stretch
Most PowerPC related stuff (e.g. Freescale MPC5xx found in a bunch of automotiver applications) can run in either big or little endian mode, as can most ARM and MIPS (routers, IP cameras) stuff. Can't think of the last time I've seen any of them configured to run in big endian mode tho.
Re: What the hell is a target triple?
#83Noticed endians listed in the table. It seems like little-endian has basically taken over the world in 2025: * https://en.wikipedia.org/wiki/Endianness#Hardware Is there anything that is used a lot that is not little? IBM's stuff? Network byte order is BE: * https://en.wikipedia.org/wiki/Endianness#Networking
Re: What the hell is a target triple?
#84Some other sources of target triples (some mentioned in the article, some not): rustc: `rustc --print target-list` golang: `go tool dist list` zig: `zig targets` As the article point out, the complete lack of standardization and consistency in what constitutes a "triple" (sometimes actually a quad!) is kind of hellishly hilarious.
Re: What the hell is a target triple?
#85Earlier quoted context omitted.
I do not think I like this author... > A critical piece of history here is to understand the really stupid way in which GCC does cross compiling. Traditionally, each GCC binary would be built for one target triple. [...] Nobody with a brain does this ^2 You're doing GCC a great disservice by ignoring its storied and essential history. It's over 40 years old, and was created at a time where there were no free/libre co…
"This was the right way to do it forty years ago, so that's why the experience is worse" isn't a compelling reason for a user to suffer today. Also, in this specific case, this ignores the history around LLVM offering itself up to the FSF. gcc could have benefitted from this fresh start too. But purely by accident, it did not.
On my system, "dnf repoquery --whatrequires cross-gcc-common" lists 26 gcc-*-linux-gnu packages (that is, kernel / firmware cross compilers for 26 architectures). The command "dnf repoquery --whatrequires cross-binutils-common" lists 31 binutils-*-linux-gnu packages.
The author writes, "LLVM and all cross compilers that follow it instead put all of the backends in one binary". Do those compilers support 25+ back-ends? And if they do, is it good design to install back-ends for (say) 23 such target architectures that you're never going to cross-compile for, in practice? Does that benefit the user?
My impression is that the author does not understand the modularity of gcc cross compilers / packages because he's unaware of (or doesn't care for) the scale that gcc aims at.
Re: What the hell is a target triple?
#86"And no, a “target quadruple” is not a thing and if I catch you saying that I’m gonna bonk you with an Intel optimization manual. " https://github.com/ziglang/zig/issues/20690
Re: What the hell is a target triple?
#87Great article but I was really put off by this bit, which aside from being very condescending, simply isn't true and reveals a lack of appreciation for the innovation that I would have thought someone posting about target triples and compilers would have appreciated: > Why the Windows people invented a whole other ABI instead of making things clean and simple like Apple did with Rosetta on ARM MacBooks? I have no ide…
I assumed the author was talking about the x86 emulator released for the arm migration a few years ago, not the powerpc one.
Re: What the hell is a target triple?
#88Earlier quoted context omitted.
Java VM is BE.
This is misleading at best. The JVM only exposes multibyte values to ordinary applications in such a way that byte order doesn't matter. You can't break out a pointer and step through the bytes of a long field to see what order it's in, at least not without the unsafe memory APIs. In practice, any real JVM implementation will simply use native byte order as much as possible. While bytecode and other data in class fil…
Re: What the hell is a target triple?
#89Re: What the hell is a target triple?
#90>There’s a few variants. wasm32-unknown-unknown (here using unknown instead of none as the system, oops) Why isn't it called wasm32-none-none?