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

Output tree representation on thir-tree #107006

Merged
merged 4 commits into from
Jan 29, 2023
Merged

Conversation

b-naber
Copy link
Contributor

@b-naber b-naber commented Jan 17, 2023

The current output of -Zunpretty=thir-tree is really cumbersome to work with, using an actual tree representation should make it easier to see what the thir looks like.

@rustbot
Copy link
Collaborator

rustbot commented Jan 17, 2023

r? @jackh726

(rustbot has picked a reviewer for you, use r? to override)

@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. labels Jan 17, 2023
@rust-log-analyzer

This comment has been minimized.

@compiler-errors
Copy link
Member

I like this a lot. Needs tests blessed though. Maybe we should keep the old behavior, like thir-tree,flat or something?

@compiler-errors
Copy link
Member

@rustbot author

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 26, 2023
@b-naber
Copy link
Contributor Author

b-naber commented Jan 26, 2023

@compiler-errors Addressed your points.

compiler/rustc_middle/src/thir/print.rs Outdated Show resolved Hide resolved
compiler/rustc_middle/src/ty/adt.rs Outdated Show resolved Hide resolved
tests/ui/thir-tree.stdout Outdated Show resolved Hide resolved
@b-naber
Copy link
Contributor Author

b-naber commented Jan 27, 2023

@rustbot review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jan 27, 2023
@jackh726
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Jan 29, 2023

📌 Commit 92f2d27 has been approved by jackh726

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 Jan 29, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 29, 2023
…iaskrgr

Rollup of 11 pull requests

Successful merges:

 - rust-lang#96763 (Fix maintainer validation message)
 - rust-lang#106540 (Insert whitespace to avoid ident concatenation in suggestion)
 - rust-lang#106763 (print why a test was ignored if its the only test specified)
 - rust-lang#106769 (libtest: Print why a test was ignored if it's the only test specified.)
 - rust-lang#106798 (Implement `signum` with `Ord`)
 - rust-lang#107006 (Output tree representation on thir-tree)
 - rust-lang#107078 (Update wording of invalid_doc_attributes docs.)
 - rust-lang#107169 (Pass `--locked` to the x test tidy call)
 - rust-lang#107431 (docs: remove colon from time header)
 - rust-lang#107432 (rustdoc: remove unused class `has-srclink`)
 - rust-lang#107448 (When stamp doesn't exist, should say Error, and print path to stamp file)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 4544682 into rust-lang:master Jan 29, 2023
@rustbot rustbot added this to the 1.69.0 milestone Jan 29, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 27, 2023
Move THIR printing to rustc_mir_build.

rust-lang#107451 increased the compilation time of `rustc_middle` by 10% = 3s.

As rust-lang#107006 adds quite a lot of code to rustc_middle, I suspect it to be the cause.

This PR moves the THIR printing code to `rustc_mir_build`, where the query provider lives, in order to benefit from higher parallelism when compiling rustc.
saethlin pushed a commit to saethlin/miri that referenced this pull request Mar 5, 2023
Move THIR printing to rustc_mir_build.

rust-lang/rust#107451 increased the compilation time of `rustc_middle` by 10% = 3s.

As rust-lang/rust#107006 adds quite a lot of code to rustc_middle, I suspect it to be the cause.

This PR moves the THIR printing code to `rustc_mir_build`, where the query provider lives, in order to benefit from higher parallelism when compiling rustc.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants