Skip to content

[EXPERIMENT] Introduce TypingMode::Codegen to avoid layout cycles #145477

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

Draft
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

cjgillot
Copy link
Contributor

r? @ghost

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) labels Aug 16, 2025
@cjgillot
Copy link
Contributor Author

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

rust-bors bot added a commit that referenced this pull request Aug 16, 2025
[EXPERIMENT] Introduce `TypingMode::Codegen` to avoid layout cycles
@rust-bors

This comment has been minimized.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Aug 16, 2025
@rust-log-analyzer
Copy link
Collaborator

The job aarch64-gnu-llvm-19-1 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
test [crashes] tests/crashes/119783.rs ... ok
test [crashes] tests/crashes/119692.rs ... ok
test [crashes] tests/crashes/119786.rs ... ok
test [crashes] tests/crashes/119824.rs ... ok
2025-08-16T00:45:50.144316Z ERROR compiletest::runtest: fatal error, panic: "crashtest no longer crashes/triggers ICE, hooray! Please give it a meaningful name, add a doc-comment to the start of the test explaining why it exists and move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR description ensures that the corresponding ticket is auto-closed upon merge. If you want to see verbose output, set `COMPILETEST_VERBOSE_CRASHES=1`."
test [crashes] tests/crashes/120016.rs ... FAILED
test [crashes] tests/crashes/120175.rs ... ok
test [crashes] tests/crashes/117696-1.rs ... ok
test [crashes] tests/crashes/120033.rs ... ok
test [crashes] tests/crashes/120254.rs ... ok
---
test [crashes] tests/crashes/137514.rs ... ok
test [crashes] tests/crashes/137468.rs ... ok
test [crashes] tests/crashes/137580.rs ... ok
test [crashes] tests/crashes/137888.rs ... ok
2025-08-16T00:45:54.222273Z ERROR compiletest::runtest: fatal error, panic: "crashtest no longer crashes/triggers ICE, hooray! Please give it a meaningful name, add a doc-comment to the start of the test explaining why it exists and move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR description ensures that the corresponding ticket is auto-closed upon merge. If you want to see verbose output, set `COMPILETEST_VERBOSE_CRASHES=1`."
test [crashes] tests/crashes/137916.rs ... FAILED
test [crashes] tests/crashes/137582.rs ... ok
test [crashes] tests/crashes/138088.rs ... ok
test [crashes] tests/crashes/138009.rs ... ok
test [crashes] tests/crashes/138008.rs ... ok
---
failures:

---- [crashes] tests/crashes/120016.rs stdout ----

error: crashtest no longer crashes/triggers ICE, hooray! Please give it a meaningful name, add a doc-comment to the start of the test explaining why it exists and move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR description ensures that the corresponding ticket is auto-closed upon merge. If you want to see verbose output, set `COMPILETEST_VERBOSE_CRASHES=1`.

thread '[crashes] tests/crashes/120016.rs' panicked at src/tools/compiletest/src/runtest/crashes.rs:17:18:
fatal error
stack backtrace:
   0: __rustc::rust_begin_unwind
---
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

---- [crashes] tests/crashes/137916.rs stdout ----

error: crashtest no longer crashes/triggers ICE, hooray! Please give it a meaningful name, add a doc-comment to the start of the test explaining why it exists and move it to tests/ui or wherever you see fit. Adding 'Fixes #<issueNr>' to your PR description ensures that the corresponding ticket is auto-closed upon merge. If you want to see verbose output, set `COMPILETEST_VERBOSE_CRASHES=1`.

thread '[crashes] tests/crashes/137916.rs' panicked at src/tools/compiletest/src/runtest/crashes.rs:17:18:
fatal error
stack backtrace:
   0: __rustc::rust_begin_unwind

@rust-bors
Copy link

rust-bors bot commented Aug 16, 2025

☀️ Try build successful (CI)
Build commit: 34dd67f (34dd67f42f0f2050c773b332e2dd333618c22743, parent: cd7cbe818e4a66d46fe2df993d1b8518eba8a5cd)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (34dd67f): comparison URL.

Overall result: ❌ regressions - please read the text below

Benchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf.

Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @rustbot label: +perf-regression-triaged. If not, please fix the regressions and do another perf run. If its results are neutral or positive, the label will be automatically removed.

@bors rollup=never
@rustbot label: -S-waiting-on-perf +perf-regression

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
0.5% [0.2%, 3.3%] 58
Regressions ❌
(secondary)
1.8% [0.0%, 19.4%] 58
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.2% [-0.3%, -0.0%] 4
All ❌✅ (primary) 0.5% [0.2%, 3.3%] 58

Max RSS (memory usage)

Results (primary 1.4%, secondary 4.3%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
1.7% [0.5%, 7.3%] 17
Regressions ❌
(secondary)
5.4% [1.2%, 12.3%] 6
Improvements ✅
(primary)
-1.3% [-1.4%, -1.3%] 2
Improvements ✅
(secondary)
-2.3% [-2.3%, -2.3%] 1
All ❌✅ (primary) 1.4% [-1.4%, 7.3%] 19

Cycles

Results (primary 2.9%, secondary 4.5%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
2.9% [2.9%, 2.9%] 1
Regressions ❌
(secondary)
5.3% [2.1%, 12.0%] 12
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-4.0% [-4.0%, -4.0%] 1
All ❌✅ (primary) 2.9% [2.9%, 2.9%] 1

Binary size

Results (primary 0.1%, secondary -1.0%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
0.4% [0.1%, 0.6%] 2
Regressions ❌
(secondary)
0.3% [0.1%, 0.4%] 3
Improvements ✅
(primary)
-0.0% [-0.0%, -0.0%] 3
Improvements ✅
(secondary)
-1.8% [-7.1%, -0.1%] 5
All ❌✅ (primary) 0.1% [-0.0%, 0.6%] 5

Bootstrap: 469.562s -> 472.464s (0.62%)
Artifact size: 377.55 MiB -> 377.67 MiB (0.03%)

@rustbot rustbot added perf-regression Performance regression. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Aug 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
perf-regression Performance regression. S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants