Skip to content

Cleanup windows abort_internal #121856

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

Merged
merged 1 commit into from
Mar 3, 2024
Merged

Cleanup windows abort_internal #121856

merged 1 commit into from
Mar 3, 2024

Conversation

ChrisDenton
Copy link
Member

@ChrisDenton ChrisDenton commented Mar 1, 2024

As the comments on the functions say, we define abort in both in panic_abort and in libstd. This PR makes the two implementation (mostly) the same.

Additionally it:

  • uses options(noreturn) on the asm instead of using core::intrinsics::unreachable.
  • removed unnecessary allow lints
  • added FAST_FAIL_FATAL_APP_EXIT to our generated Windows API bindings instead of defining it manually (std only)

@rustbot
Copy link
Collaborator

rustbot commented Mar 1, 2024

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
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 O-windows Operating system: Windows S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Mar 1, 2024
@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@ChrisDenton
Copy link
Member Author

ChrisDenton commented Mar 1, 2024

It seems that miri is very sensitive to std's abort function being exactly what it expects, So I've moved the miri implementation to a separate function and added a note about avoiding disturbing it.

Copy link
Member

@joboet joboet left a comment

Choose a reason for hiding this comment

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

As this touches the inline assembly options anyway, we might as well add a nostack attribute so that LLVM doesn't think that it needs to adjust the stack pointer. But that's really nitpicky, you don't have to bother...

r=me otherwise

@joboet joboet assigned joboet and unassigned Mark-Simulacrum Mar 2, 2024
@joboet
Copy link
Member

joboet commented Mar 2, 2024

@bors r+

@bors
Copy link
Collaborator

bors commented Mar 2, 2024

📌 Commit ce26c78 has been approved by joboet

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 Mar 2, 2024
@bors
Copy link
Collaborator

bors commented Mar 3, 2024

⌛ Testing commit ce26c78 with merge 3793e5b...

@bors
Copy link
Collaborator

bors commented Mar 3, 2024

☀️ Test successful - checks-actions
Approved by: joboet
Pushing 3793e5b to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Mar 3, 2024
@bors bors merged commit 3793e5b into rust-lang:master Mar 3, 2024
@rustbot rustbot added this to the 1.78.0 milestone Mar 3, 2024
@ChrisDenton ChrisDenton deleted the abort branch March 3, 2024 06:46
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (3793e5b): comparison URL.

Overall result: ❌✅ regressions and improvements - 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.

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

Max RSS (memory usage)

Results

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)
3.9% [2.7%, 4.7%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.7% [-3.4%, -2.0%] 2
All ❌✅ (primary) - - 0

Cycles

Results

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)
1.1% [1.1%, 1.1%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-2.5% [-2.5%, -2.5%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -0.7% [-2.5%, 1.1%] 2

Binary size

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

Bootstrap: 648.592s -> 650.632s (0.31%)
Artifact size: 175.05 MiB -> 175.02 MiB (-0.02%)

@rustbot rustbot added the perf-regression Performance regression. label Mar 3, 2024
@lqd
Copy link
Member

lqd commented Mar 3, 2024

Wins and losses are noise

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label Mar 3, 2024
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. O-windows Operating system: Windows perf-regression Performance regression. perf-regression-triaged The performance regression has been triaged. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant 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.

8 participants