Skip to content

Rollup of 6 pull requests - #130649

Merged
bors merged 17 commits into
rust-lang:masterfrom
matthiaskrgr:rollup-57zc7lz
Sep 21, 2024
Merged

Rollup of 6 pull requests#130649
bors merged 17 commits into
rust-lang:masterfrom
matthiaskrgr:rollup-57zc7lz

Conversation

@matthiaskrgr

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

lolbinarycatand others added 17 commits August 28, 2024 21:30
Fixes stack overflow in the case of recursive types
no functional changes should arise, just moves the lint impl details out
of a very crowded file with lots of different lints in it.
A couple tests were using `BOOTSTRAP_CARGO` with `-Zbuild-std`, but that
stage0 cargo might not always be in sync with in-tree changes. In
particular, those tests started failing on the beta branch because the
older cargo couldn't find the library `Cargo.lock`, and then couldn't
build the latest version of `compiler_builtins` that had nightly changes.
no need for a weird macro when a self-explanatory `match` will do.
…ratrieb
add guarantee about remove_dir and remove_file error kinds
approved in ACP rust-lang/libs-team#433
…overflow, r=compiler-errors
Add recursion limit to FFI safety lint
Fixesrust-lang#130310
Now we check against `tcx.recursion_limit()` and raise an error if it the limit is reached instead of overflowing the stack.
Pass the current cargo to `run-make` tests
A couple tests were using `BOOTSTRAP_CARGO` with `-Zbuild-std`, but that
stage0 cargo might not always be in sync with in-tree changes. In
particular, those tests started failing on the beta branch because the
older cargo couldn't find the library `Cargo.lock`, and then couldn't
build the latest version of `compiler_builtins` that had nightly changes.
Fixesrust-lang#130634
r? `@saethlin`
… r=BoxyUwU
Only expect valtree consts in codegen
Turn a bunch of `Const::eval_*` calls into `Const::try_to_*` calls, which implicitly assert that we only have valtrees by the time we get to codegen.
r? `@BoxyUwU`
…eback, r=BoxyUwU
Normalize consts in writeback when GCE is enabled
GCE lazily normalizes its unevaluated consts. This PR ensures that, like the new solver with its lazy norm types, we can assume that the writeback results are fully normalized.
This is important since we're trying to eliminate unnecessary calls to `ty::Const::{eval,normalize}` since they won't work with mGCE. Previously, we'd keep those consts unnormalized in writeback all the way through MIR build, and they'd only get normalized if we explicitly called `ty::Const::{eval,normalize}`, or during codegen since that calls `normalize_erasing_regions` (which invokes the `QueryNormalizer`, which evaluates the const accordingly).
This hack can (hopefully obviously) be removed when mGCE is implemented and we yeet the old GCE; it's only reachable with the GCE flag anyways, so I'm not worried about the implications here.
r? `@BoxyUwU`
…-int-lint, r=compiler-errors
compiler: factor out `OVERFLOWING_LITERALS` impl
This puts it into `rustc_lint/src/types/literal.rs`. It then uses the fact that it's easier to navigate the logic to identify something that can easily be factored out, as an instance of "why".
@rustbotrustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Sep 21, 2024
@matthiaskrgr

Copy link
Copy Markdown
MemberAuthor

@bors r+ rollup=never p=6

@bors

bors commented Sep 21, 2024

Copy link
Copy Markdown
Collaborator

📌 Commit 5770ba8 has been approved by matthiaskrgr

It is now in the queue for this repository.

@borsbors 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 Sep 21, 2024
@bors

bors commented Sep 21, 2024

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 5770ba8 with merge 74fd001...

@bors

bors commented Sep 21, 2024

Copy link
Copy Markdown
Collaborator

☀️ Test successful - checks-actions
Approved by: matthiaskrgr
Pushing 74fd001 to master...

@borsbors added the merged-by-bors This PR was explicitly merged by bors. label Sep 21, 2024
@bors
bors merged commit 74fd001 into rust-lang:masterSep 21, 2024
@rustbotrustbot added this to the 1.83.0 milestone Sep 21, 2024
@rust-timer

Copy link
Copy Markdown
Collaborator

📌 Perf builds for each rolled up PR:

PR#MessagePerf Build Sha
#129718add guarantee about remove_dir and remove_file error kinds44ece8466d5431a18c400936380d5e5affd5b7bb (link)
#130598Add recursion limit to FFI safety lint6e15f041aa6efc236a31046e0745562b46aca815 (link)
#130642Pass the current cargo to run-make tests736e7c8fdb0ff33469248f685dabc300a30ced65 (link)
#130644Only expect valtree consts in codegen2393b8cfdd3cd0ddb63099a0288df3913be56ba4 (link)
#130645Normalize consts in writeback when GCE is enablede626ecd471bc41936f8c974358d021bae357d158 (link)
#130646compiler: factor out OVERFLOWING_LITERALS impl9f3840a2d22808dfe65c472ec1e69add15d738e4 (link)

previous master: c0838c8ebe

In the case of a perf regression, run the following command for each PR you suspect might be the cause: @rust-timer build $SHA

@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (74fd001): comparison URL.

Overall result: ❌ regressions - ACTION NEEDED

Next Steps: If you can justify the regressions found in this perf run, please indicate this with @rustbot label: +perf-regression-triaged along with sufficient written justification. If you cannot justify the regressions please open an issue or create a new PR that fixes the regressions, add a comment linking to the newly created issue or PR, and then add the perf-regression-triaged label to this PR.

@rustbot label: +perf-regression
cc @rust-lang/wg-compiler-performance

Instruction count

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

meanrangecount
Regressions ❌
(primary)
--0
Regressions ❌
(secondary)
0.3%[0.1%, 0.4%]13
Improvements ✅
(primary)
--0
Improvements ✅
(secondary)
--0
All ❌✅ (primary)--0

Max RSS (memory usage)

Results (primary 0.5%, secondary 0.6%)

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.

meanrangecount
Regressions ❌
(primary)
1.8%[1.2%, 2.5%]2
Regressions ❌
(secondary)
3.2%[3.2%, 3.2%]1
Improvements ✅
(primary)
-2.2%[-2.2%, -2.2%]1
Improvements ✅
(secondary)
-2.0%[-2.0%, -2.0%]1
All ❌✅ (primary)0.5%[-2.2%, 2.5%]3

Cycles

Results (secondary -6.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.

meanrangecount
Regressions ❌
(primary)
--0
Regressions ❌
(secondary)
--0
Improvements ✅
(primary)
--0
Improvements ✅
(secondary)
-6.2%[-6.7%, -5.6%]2
All ❌✅ (primary)--0

Binary size

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

Bootstrap: 768.11s -> 769.225s (0.15%)
Artifact size: 341.37 MiB -> 341.35 MiB (-0.00%)

@rustbotrustbot added the perf-regression Performance regression. label Sep 21, 2024
@pnkfelix

Copy link
Copy Markdown
Contributor
  • Weird, this is just minor regressions solely to secondary benchmarks; I had thought our policy was to not treat that on its own as worth flagging as a regression.
  • Marking as triaged.

@rustbot label: +perf-regression-triaged

@rustbotrustbot added the perf-regression-triaged The performance regression has been triaged. label Sep 24, 2024
@matthiaskrgr
matthiaskrgr deleted the rollup-57zc7lz branch January 25, 2025 09:13
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-run-makeArea: port run-make Makefiles to rmake.rsA-testsuiteArea: The testsuite used to check the correctness of rustcmerged-by-borsThis PR was explicitly merged by bors.perf-regressionPerformance regression.perf-regression-triagedThe performance regression has been triaged.PG-exploit-mitigationsProject group: Exploit mitigationsrollupA PR which is a rollupS-waiting-on-borsStatus: Waiting on bors to run and complete tests. Bors will change the label on completion.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-libsRelevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

11 participants

@matthiaskrgr@bors@rust-timer@pnkfelix@rustbot@lolbinarycat@gurry@Noratrieb@workingjubilee@cuviper@compiler-errors