We accept the LLVM-style arch-vendor-os-env form because that is what build systems
pass, and we normalise it to the three fields we actually branch on. The vendor field is
parsed and discarded: no decision in the compiler depends on it, and keeping it would
invite one.
The same machine as a TargetTuple, which is what the layout and ABI descriptions are
written over.
The tuple carries ten fields and this carries three, so this fills the other seven in from
their defaults, and every one of those defaults is the answer for the targets this type can
spell. There is no x32 here and no big-endian AArch64, so the data model and the byte
order follow the architecture, and the sub-architecture, the versions and the float ABI have
nothing to say about any of the combinations.
The environment is narrowed rather than copied across. This type will hold
Triple { os: Darwin, env: Gnu }, because its parser takes the fields by content and
aarch64-apple-darwin-gnu is a string somebody can type, and that is not a machine: a
Darwin target has one libc and it is not glibc. A tuple refuses to describe one, so the
pairs that are not machines are mapped to the environment the operating system actually
has.
The triple of the machine this compiler is running on.
Used as the default target, which is what makes rucc hello.c work with no flags.
Unknown host combinations are not an error here: they are reported by the driver,
where there is somewhere to report them to.