Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uplift RegionVid, TermKind to rustc_type_ir, and EagerResolver to rustc_next_trait_solver #125284

Merged
merged 3 commits into from
May 21, 2024

Conversation

compiler-errors
Copy link
Member

  • Uplift RegionVid. This was complicated due to the fact that we implement polonius_engine::Atom for RegionVid -- but I just separated that into PoloniusRegionVid, and added From/Into impls so it can be defined in rustc_borrowck separately. Coherence 😵
  • Change InferCtxtLike to expose opportunistically_resolve_{ty,ct,lt,int,float}_var so that we can uplift EagerResolver for use in the canonicalization methods.
  • Uplift TermKind much like GenericArgKind

All of this is miscellaneous dependencies for making more EvalCtxt methods generic.

@compiler-errors
Copy link
Member Author

r? lcnr

@rustbot
Copy link
Collaborator

rustbot commented May 19, 2024

r? @davidtwco

rustbot has assigned @davidtwco.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative labels May 19, 2024
@rustbot
Copy link
Collaborator

rustbot commented May 19, 2024

Some changes occurred to the core trait solver

cc @rust-lang/initiative-trait-system-refactor

@compiler-errors compiler-errors changed the title Uplift misc Uplift RegionVid, TermKind to rustc_type_ir, and EagerResolver to rustc_next_trait_solver May 19, 2024
@rust-log-analyzer

This comment has been minimized.

@compiler-errors compiler-errors force-pushed the uplift-misc branch 2 times, most recently from 073ee90 to 53c6c46 Compare May 19, 2024 18:42
@rust-log-analyzer

This comment has been minimized.

use std::fmt;

use crate::{DebruijnIndex, DebugWithInfcx, InferCtxtLike, Interner, WithInfcx};

use self::RegionKind::*;

rustc_index::newtype_index! {
/// A **ty**pe **v**ariable **ID**.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this comment is wrong :3

@lcnr
Copy link
Contributor

lcnr commented May 20, 2024

r=me after nits

@compiler-errors
Copy link
Member Author

@bors r=lcnr

@bors
Copy link
Contributor

bors commented May 20, 2024

📌 Commit 9fa07a4 has been approved by lcnr

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 20, 2024
@compiler-errors
Copy link
Member Author

@bors rollup=never

@bors
Copy link
Contributor

bors commented May 21, 2024

⌛ Testing commit 9fa07a4 with merge 9cb6bb8...

@bors
Copy link
Contributor

bors commented May 21, 2024

☀️ Test successful - checks-actions
Approved by: lcnr
Pushing 9cb6bb8 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label May 21, 2024
@bors bors merged commit 9cb6bb8 into rust-lang:master May 21, 2024
7 checks passed
@rustbot rustbot added this to the 1.80.0 milestone May 21, 2024
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (9cb6bb8): comparison URL.

Overall result: ❌ regressions - no action needed

@rustbot label: -perf-regression

Instruction count

This is a highly reliable metric that was used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.8% [0.2%, 1.3%] 2
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Max RSS (memory usage)

This benchmark run did not return any relevant results for this metric.

Cycles

Results (primary -2.8%, secondary -3.4%)

This 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.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-2.8% [-2.8%, -2.8%] 1
Improvements ✅
(secondary)
-3.4% [-3.4%, -3.4%] 1
All ❌✅ (primary) -2.8% [-2.8%, -2.8%] 1

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 671.714s -> 670.228s (-0.22%)
Artifact size: 315.43 MiB -> 316.14 MiB (0.23%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants