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

compiler: replace few consts arrays with statics to remove const dupes #136191

Merged
merged 1 commit into from
Feb 7, 2025

Conversation

klensy
Copy link
Contributor

@klensy klensy commented Jan 28, 2025

Locally on x86_64-pc-windows-msvc -100kb for rustc_driver.dll

@rustbot
Copy link
Collaborator

rustbot commented Jan 28, 2025

r? @SparrowLii

rustbot has assigned @SparrowLii.
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. labels Jan 28, 2025
@rustbot
Copy link
Collaborator

rustbot commented Jan 28, 2025

These commits modify compiler targets.
(See the Target Tier Policy.)

@compiler-errors
Copy link
Member

probably no perf implications?

@bors try @rust-timer queue

@rust-timer

This comment has been minimized.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 28, 2025
@bors
Copy link
Contributor

bors commented Jan 28, 2025

⌛ Trying commit dc62b8f with merge 3e5336e...

bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 28, 2025
compiler: replace few consts arrays with statics to remove const dupes

Locally on `x86_64-pc-windows-msvc` -100kb for `rustc_driver.dll`
@bors
Copy link
Contributor

bors commented Jan 28, 2025

☀️ Try build successful - checks-actions
Build commit: 3e5336e (3e5336e798a13f3872d2da1cc374610b260b877e)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (3e5336e): comparison URL.

Overall result: ❌✅ regressions and improvements - no action needed

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf.

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

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.3% [0.2%, 0.3%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.3% [-0.3%, -0.3%] 1
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -0.9%, secondary 1.0%)

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)
2.1% [1.0%, 3.4%] 4
Improvements ✅
(primary)
-0.9% [-0.9%, -0.9%] 1
Improvements ✅
(secondary)
-1.1% [-1.6%, -0.6%] 2
All ❌✅ (primary) -0.9% [-0.9%, -0.9%] 1

Cycles

Results (primary 3.0%, secondary -0.2%)

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)
3.0% [3.0%, 3.0%] 1
Regressions ❌
(secondary)
2.6% [2.6%, 2.6%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-3.0% [-3.0%, -3.0%] 1
All ❌✅ (primary) 3.0% [3.0%, 3.0%] 1

Binary size

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

Bootstrap: 773.088s -> 773.417s (0.04%)
Artifact size: 328.30 MiB -> 326.30 MiB (-0.61%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jan 28, 2025
@klensy
Copy link
Contributor Author

klensy commented Jan 31, 2025

Less effect on linux target, about ~50kb, until next size increase, when alignment will strike back.

@rustbot ready

@compiler-errors
Copy link
Member

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Feb 6, 2025

📌 Commit dc62b8f has been approved by compiler-errors

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 Feb 6, 2025
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Feb 6, 2025
compiler: replace few consts arrays with statics to remove const dupes

Locally on `x86_64-pc-windows-msvc` -100kb for `rustc_driver.dll`
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 7, 2025
…iaskrgr

Rollup of 9 pull requests

Successful merges:

 - rust-lang#135973 (fix tail call checks wrt `#[track_caller]`)
 - rust-lang#136191 (compiler: replace few consts arrays with statics to remove const dupes)
 - rust-lang#136565 (compiler: Clean up weird `rustc_abi` reexports)
 - rust-lang#136582 (Revert "CI: build FreeBSD artifacts on FreeBSD 13.4")
 - rust-lang#136592 (Make sure we don't overrun the stack in canonicalizer)
 - rust-lang#136627 (MIR validation: add comment explaining the limitations of CfgChecker)
 - rust-lang#136634 (Stabilise `Cursor::{get_mut, set_position}` in `const` scenarios.)
 - rust-lang#136643 (ping me for attribute-related changes)
 - rust-lang#136644 (Add `rustc_hir_pretty::item_to_string` function)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 7, 2025
…iaskrgr

Rollup of 8 pull requests

Successful merges:

 - rust-lang#135973 (fix tail call checks wrt `#[track_caller]`)
 - rust-lang#136191 (compiler: replace few consts arrays with statics to remove const dupes)
 - rust-lang#136565 (compiler: Clean up weird `rustc_abi` reexports)
 - rust-lang#136582 (Revert "CI: build FreeBSD artifacts on FreeBSD 13.4")
 - rust-lang#136627 (MIR validation: add comment explaining the limitations of CfgChecker)
 - rust-lang#136634 (Stabilise `Cursor::{get_mut, set_position}` in `const` scenarios.)
 - rust-lang#136643 (ping me for attribute-related changes)
 - rust-lang#136644 (Add `rustc_hir_pretty::item_to_string` function)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 3ce7d9c into rust-lang:master Feb 7, 2025
7 checks passed
@rustbot rustbot added this to the 1.86.0 milestone Feb 7, 2025
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Feb 7, 2025
Rollup merge of rust-lang#136191 - klensy:const_a, r=compiler-errors

compiler: replace few consts arrays with statics to remove const dupes

Locally on `x86_64-pc-windows-msvc` -100kb for `rustc_driver.dll`
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.

6 participants