Skip to content

Conversation

bjorn3
Copy link
Member

@bjorn3 bjorn3 commented Aug 6, 2025

These are extracted out of a wip branch I have to get rid of the extern "unadjusted" ABI for anything other than LLVM intrinsics.

bjorn3 added 2 commits August 6, 2025 16:05
Directly creating the ArgAttributes rather than adjusting one is a bit
clearer.
This restricts the uses of the unadjusted ABI to LLVM intrinsics. The
Rust ABI works fine for the thread-local shim as it always returns
pointers directly like the backend expects.
@rustbot
Copy link
Collaborator

rustbot commented Aug 6, 2025

r? @lcnr

rustbot has assigned @lcnr.
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 Aug 6, 2025
@bjorn3
Copy link
Member Author

bjorn3 commented Aug 6, 2025

The panic happens while calling fn_abi_for_instance on the tls shim, which now calls deduced_param_attrs due to using a rustic ABI, which in turn requires optimized_mir(instance.def_id()), which isn't allowed for the tls shim.

@lcnr
Copy link
Contributor

lcnr commented Aug 7, 2025

r? compiler

@rustbot rustbot assigned fee1-dead and unassigned lcnr Aug 7, 2025
@fee1-dead
Copy link
Member

r? codegen might help

@rustbot rustbot assigned dianqk and unassigned fee1-dead Aug 7, 2025
Copy link
Member

@compiler-errors compiler-errors left a comment

Choose a reason for hiding this comment

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

Seems reasonable.

@compiler-errors
Copy link
Member

@bors r+

@bors
Copy link
Collaborator

bors commented Aug 8, 2025

📌 Commit 7d88f65 has been approved by compiler-errors

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented Aug 8, 2025

🌲 The tree is currently closed for pull requests below priority 100. This pull request will be tested once the tree is reopened.

@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 Aug 8, 2025
bors added a commit that referenced this pull request Aug 9, 2025
Rollup of 23 pull requests

Successful merges:

 - #141658 (rustdoc search: prefer stable items in search results)
 - #141828 (Add diagnostic explaining STATUS_STACK_BUFFER_OVERRUN not only being used for stack buffer overruns if link.exe exits with that exit code)
 - #144823 (coverage: Extract HIR-related helper code out of the main module)
 - #144883 (Remove unneeded `drop_in_place` calls)
 - #144923 (Move several more float tests to floats/mod.rs)
 - #144988 (Add annotations to the graphviz region graph on region origins)
 - #145010 (Couple of minor abi handling cleanups)
 - #145017 (Explicitly disable vector feature on s390x baseline of bad-reg test)
 - #145027 (Optimize `char::is_alphanumeric`)
 - #145050 (add member constraints tests)
 - #145073 (update enzyme submodule to handle llvm 21)
 - #145080 (Escape diff strings in MIR dataflow graphviz)
 - #145082 (Fix some bad formatting in `-Zmacro-stats` output.)
 - #145083 (Fix cross-compilation of Cargo)
 - #145096 (Fix wasm target build with atomics feature)
 - #145097 (remove unnecessary `TypeFoldable` impls)
 - #145100 (Rank doc aliases lower than equivalently matched items)
 - #145103 (rustc_metadata: remove unused private trait impls)
 - #145115 (defer opaque type errors, generally greatly reduce tainting)
 - #145119 (rustc_public: fix missing parenthesis in pretty discriminant)
 - #145124 (Recover `for PAT = EXPR {}`)
 - #145132 (Refactor map_unit_fn lint)
 - #145134 (Reduce indirect assoc parent queries)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit that referenced this pull request Aug 9, 2025
Rollup of 23 pull requests

Successful merges:

 - #141658 (rustdoc search: prefer stable items in search results)
 - #141828 (Add diagnostic explaining STATUS_STACK_BUFFER_OVERRUN not only being used for stack buffer overruns if link.exe exits with that exit code)
 - #144823 (coverage: Extract HIR-related helper code out of the main module)
 - #144883 (Remove unneeded `drop_in_place` calls)
 - #144923 (Move several more float tests to floats/mod.rs)
 - #144988 (Add annotations to the graphviz region graph on region origins)
 - #145010 (Couple of minor abi handling cleanups)
 - #145017 (Explicitly disable vector feature on s390x baseline of bad-reg test)
 - #145027 (Optimize `char::is_alphanumeric`)
 - #145050 (add member constraints tests)
 - #145073 (update enzyme submodule to handle llvm 21)
 - #145080 (Escape diff strings in MIR dataflow graphviz)
 - #145082 (Fix some bad formatting in `-Zmacro-stats` output.)
 - #145083 (Fix cross-compilation of Cargo)
 - #145096 (Fix wasm target build with atomics feature)
 - #145097 (remove unnecessary `TypeFoldable` impls)
 - #145100 (Rank doc aliases lower than equivalently matched items)
 - #145103 (rustc_metadata: remove unused private trait impls)
 - #145115 (defer opaque type errors, generally greatly reduce tainting)
 - #145119 (rustc_public: fix missing parenthesis in pretty discriminant)
 - #145124 (Recover `for PAT = EXPR {}`)
 - #145132 (Refactor map_unit_fn lint)
 - #145134 (Reduce indirect assoc parent queries)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 61e9c6c into rust-lang:master Aug 9, 2025
10 checks passed
@rustbot rustbot added this to the 1.91.0 milestone Aug 9, 2025
rust-timer added a commit that referenced this pull request Aug 9, 2025
Rollup merge of #145010 - bjorn3:couple_abi_cleanups, r=compiler-errors

Couple of minor abi handling cleanups

These are extracted out of a wip branch I have to get rid of the `extern "unadjusted"` ABI for anything other than LLVM intrinsics.
@jieyouxu
Copy link
Member

jieyouxu commented Aug 9, 2025

Couple of minor abi handling cleanups bors merged PR cleanups:
@bors r-

@bors bors 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-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Aug 9, 2025
@jieyouxu
Copy link
Member

jieyouxu commented Aug 9, 2025

@rustbot label: -S-waiting-on-author +S-waiting-on-bors +merged-by-bors

@rustbot rustbot added merged-by-bors This PR was explicitly merged by bors. 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Aug 9, 2025
@bjorn3 bjorn3 deleted the couple_abi_cleanups branch August 9, 2025 12:45
rust-cloud-vms bot pushed a commit to makai410/rustc_public that referenced this pull request Aug 16, 2025
Rollup of 23 pull requests

Successful merges:

 - rust-lang/rust#141658 (rustdoc search: prefer stable items in search results)
 - rust-lang/rust#141828 (Add diagnostic explaining STATUS_STACK_BUFFER_OVERRUN not only being used for stack buffer overruns if link.exe exits with that exit code)
 - rust-lang/rust#144823 (coverage: Extract HIR-related helper code out of the main module)
 - rust-lang/rust#144883 (Remove unneeded `drop_in_place` calls)
 - rust-lang/rust#144923 (Move several more float tests to floats/mod.rs)
 - rust-lang/rust#144988 (Add annotations to the graphviz region graph on region origins)
 - rust-lang/rust#145010 (Couple of minor abi handling cleanups)
 - rust-lang/rust#145017 (Explicitly disable vector feature on s390x baseline of bad-reg test)
 - rust-lang/rust#145027 (Optimize `char::is_alphanumeric`)
 - rust-lang/rust#145050 (add member constraints tests)
 - rust-lang/rust#145073 (update enzyme submodule to handle llvm 21)
 - rust-lang/rust#145080 (Escape diff strings in MIR dataflow graphviz)
 - rust-lang/rust#145082 (Fix some bad formatting in `-Zmacro-stats` output.)
 - rust-lang/rust#145083 (Fix cross-compilation of Cargo)
 - rust-lang/rust#145096 (Fix wasm target build with atomics feature)
 - rust-lang/rust#145097 (remove unnecessary `TypeFoldable` impls)
 - rust-lang/rust#145100 (Rank doc aliases lower than equivalently matched items)
 - rust-lang/rust#145103 (rustc_metadata: remove unused private trait impls)
 - rust-lang/rust#145115 (defer opaque type errors, generally greatly reduce tainting)
 - rust-lang/rust#145119 (rustc_public: fix missing parenthesis in pretty discriminant)
 - rust-lang/rust#145124 (Recover `for PAT = EXPR {}`)
 - rust-lang/rust#145132 (Refactor map_unit_fn lint)
 - rust-lang/rust#145134 (Reduce indirect assoc parent queries)

r? `@ghost`
`@rustbot` modify labels: rollup
rust-cloud-vms bot pushed a commit to makai410/rustc_public that referenced this pull request Aug 20, 2025
Rollup of 23 pull requests

Successful merges:

 - rust-lang/rust#141658 (rustdoc search: prefer stable items in search results)
 - rust-lang/rust#141828 (Add diagnostic explaining STATUS_STACK_BUFFER_OVERRUN not only being used for stack buffer overruns if link.exe exits with that exit code)
 - rust-lang/rust#144823 (coverage: Extract HIR-related helper code out of the main module)
 - rust-lang/rust#144883 (Remove unneeded `drop_in_place` calls)
 - rust-lang/rust#144923 (Move several more float tests to floats/mod.rs)
 - rust-lang/rust#144988 (Add annotations to the graphviz region graph on region origins)
 - rust-lang/rust#145010 (Couple of minor abi handling cleanups)
 - rust-lang/rust#145017 (Explicitly disable vector feature on s390x baseline of bad-reg test)
 - rust-lang/rust#145027 (Optimize `char::is_alphanumeric`)
 - rust-lang/rust#145050 (add member constraints tests)
 - rust-lang/rust#145073 (update enzyme submodule to handle llvm 21)
 - rust-lang/rust#145080 (Escape diff strings in MIR dataflow graphviz)
 - rust-lang/rust#145082 (Fix some bad formatting in `-Zmacro-stats` output.)
 - rust-lang/rust#145083 (Fix cross-compilation of Cargo)
 - rust-lang/rust#145096 (Fix wasm target build with atomics feature)
 - rust-lang/rust#145097 (remove unnecessary `TypeFoldable` impls)
 - rust-lang/rust#145100 (Rank doc aliases lower than equivalently matched items)
 - rust-lang/rust#145103 (rustc_metadata: remove unused private trait impls)
 - rust-lang/rust#145115 (defer opaque type errors, generally greatly reduce tainting)
 - rust-lang/rust#145119 (rustc_public: fix missing parenthesis in pretty discriminant)
 - rust-lang/rust#145124 (Recover `for PAT = EXPR {}`)
 - rust-lang/rust#145132 (Refactor map_unit_fn lint)
 - rust-lang/rust#145134 (Reduce indirect assoc parent queries)

r? `@ghost`
`@rustbot` modify labels: rollup
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. 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.

8 participants