▲ | IshKebab 5 days ago | |||||||
Nah I dunno where you're getting your information from but LLVM only supports 5 components. See the code starting at line 1144 here: https://llvm.org/doxygen/Triple_8cpp_source.html The components are arch-vendor-os-environment-objectformat. It's absolutely full of special cases and hacks. Really at this point I think the only sane option is an explicit list of fixed strings. I think Rust does that. | ||||||||
▲ | jcranmer 5 days ago | parent | next [-] | |||||||
You're not really contradicting o11c here; what LLVM calls "environment" is a mixture of what they called libc/abi/fabi. There's also what LLVM calls "subarch" to distinguish between different architectures that may be relevant (e.g., i386 is not the same as i686, although LLVM doesn't record this difference since it's generally less interested in targeting old hardware), and there's also OS version numbers that may or may not be relevant. The underlying problem with target triples is that architecture-vendor-system isn't sufficient to uniquely describe the relevant details for specifying a toolchain, so the necessary extra information has been somewhat haphazardly added to the format. On top of that, since the relevance of some of the information is questionable for some tasks (especially the vendor field), different projects have chosen not to care about subtle differences, so the normalization of a triple is different between different projects. LLVM's definition is not more or less correct than gcc's here, nor are these the only definitions floating around. | ||||||||
| ||||||||
▲ | o11c 5 days ago | parent | prev [-] | |||||||
LLVM didn't invent the scheme; why should we pay attention to their copy and not look at the original? The GNU Config project is the original. | ||||||||
|