-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
Upstream support for --print=target-cpus to LLVM #104785
Copy link
Copy link
Open
Labels
A-LLVMArea: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.A-target-specsArea: Compile-target specificationsArea: Compile-target specificationsT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-LLVMArea: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.A-target-specsArea: Compile-target specificationsArea: Compile-target specificationsT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
The target-cpus feature is only exposed when building llvm through
x.pybecause it depends on a patch in our fork of llvm. As a result, linking to an upstream llvm build withllvm.llvm-config = "..."won't work with--print=target-cpus. The relevant patch on the current branch is rust-lang/llvm-project@a8f170c; it would be nice if someone lobbied for that in upstream LLVM.The last attempt to do that was https://reviews.llvm.org/D93789; the feedback there was to use fillValidCPUArchList() instead.
See below for the original issue description.
Hi,
is there a good reason release versions of rust do not support these options?
OK, so let's try adding that option, then:
Gah!
Googling a little gave a sliver of hope:
Nope!
It does, though support
rustc --print target-list, so this looks a little ... inconsistent?The
rustc(1)man page does mention both the above unsupported options withoutany qualification.
I suspect this can relatively easily (and cheaply?) be improved?