Remove fold code and add Const::internal() to StableMIR - #117113
Conversation
commented
Oct 24, 2023
|
r? @davidtwco (rustbot has picked a reviewer for you, use r? to override) |
commented
Oct 24, 2023
|
This PR changes Stable MIR cc @oli-obk, @celinval, @spastorino, @ouz-a |
commented
Oct 24, 2023
|
r? @oli-obk |
| pub alloc_ids: IndexMap<AllocId, stable_mir::AllocId>, | ||
| pub spans: IndexMap<rustc_span::Span, Span>, | ||
| pub types: Vec<MaybeStable<TyKind, Ty<'tcx>>>, | ||
| pub types: Vec<Ty<'tcx>>, |
commented
Oct 24, 2023
|
@bors delegate+ r=me with |
commented
Oct 24, 2023
commented
Oct 24, 2023
commented
Oct 24, 2023
We are not planning to support user generated constant in the foreseeable future, so we are removing the Fold logic for now in favor of the Instance::resolve logic. The Instance::resolve was however incomplete, since we weren't handling internalizing constants yet. Thus, I added that. I decided to keep the Const fields private in case we decide to translate them lazily.
commented
Oct 24, 2023
|
☔ The latest upstream changes (presumably #117135) made this pull request unmergeable. Please resolve the merge conflicts. |
cf6a04e to
17f6df9
Compare
commented
Oct 24, 2023
commented
Oct 24, 2023
commented
Oct 25, 2023
commented
Oct 25, 2023
|
☀️ Test successful - checks-actions |
commented
Oct 25, 2023
|
Finished benchmarking commit (b66fe58): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: missing data |
We are not planning to support user generated constant in the foreseeable future, so we are cleaning up the fold logic and user created type for now. Users should use
Instance::resolvein order to trigger monomorphization.The Instance::resolve was however incomplete, since we weren't handling internalizing constants yet. Thus, I added that.
I decided to keep the
Constfields private in case we decide to translate them lazily.