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

Remove support for extern "rust-intrinsic" blocks #139455

Merged
merged 4 commits into from
Apr 7, 2025

Conversation

Skgland
Copy link
Contributor

@Skgland Skgland commented Apr 6, 2025

Part of #132735

Looked manageable and there didn't appear to have been progress in the last two weeks,
so decided to give it a try.

@rustbot
Copy link
Collaborator

rustbot commented Apr 6, 2025

r? @wesleywiser

rustbot has assigned @wesleywiser.
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 A-attributes Area: Attributes (`#[…]`, `#![…]`) A-run-make Area: port run-make Makefiles to rmake.rs 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. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Apr 6, 2025
@rustbot
Copy link
Collaborator

rustbot commented Apr 6, 2025

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

This PR modifies run-make tests.

cc @jieyouxu

Some changes occurred to the intrinsics. Make sure the CTFE / Miri interpreter
gets adapted for the changes, if necessary.

cc @rust-lang/miri, @RalfJung, @oli-obk, @lcnr

Some changes occurred in compiler/rustc_passes/src/check_attr.rs

cc @jdonszelmann

Some changes occurred in compiler/rustc_codegen_cranelift

cc @bjorn3

rust-analyzer is developed in its own repository. If possible, consider making this change to rust-lang/rust-analyzer instead.

cc @rust-lang/rust-analyzer

@oli-obk
Copy link
Contributor

oli-obk commented Apr 7, 2025

@bors r+

@bors
Copy link
Collaborator

bors commented Apr 7, 2025

📌 Commit 7dd57f0 has been approved by oli-obk

It is now in the queue for this repository.

@oli-obk oli-obk assigned oli-obk and unassigned wesleywiser Apr 7, 2025
@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 Apr 7, 2025
Zalathar added a commit to Zalathar/rust that referenced this pull request Apr 7, 2025
… r=oli-obk

 Remove support for `extern "rust-intrinsic"` blocks

Part of rust-lang#132735

Looked manageable and there didn't appear to have been progress in the last two weeks,
so decided to give it a try.
or as a `#[rustc_intrinsic]`. The body is never used, as calls to the intrinsic do not exist
anymore after MIR analyses.
at all. These intrinsics only make sense without a body, and can be declared as a `#[rustc_intrinsic]`.
The body is never used, as calls to the intrinsic do not exist anymore after MIR analyses.
Copy link
Member

Choose a reason for hiding this comment

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

That last sentence seems outdated. The body, if it exists, is used if the codegen backend does not have its own implementation of the intrinsic.

Copy link
Member

Choose a reason for hiding this comment

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

Ah I missed that this is only about MIR-lowered intrinsics.

or as a `#[rustc_intrinsic]`. The body is never used, as calls to the intrinsic do not exist
anymore after MIR analyses.
at all. These intrinsics only make sense without a body, and can be as a `#[rustc_intrinsic]`.
The body is never used, as calls to the intrinsic do not exist anymore after MIR analyses.
Copy link
Member

Choose a reason for hiding this comment

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

@rust-lang/rust-analyzer is this an RA test having a fully copy of the docs of an unstable feature inside of it? IMO that's a bad idea, it creates unexpected friction when improving those docs. Is there a way to have this test in a way that causes less of a roadblock for unrelated PRs?

Copy link
Member

Choose a reason for hiding this comment

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

Yes, it tests that if you hover over a the name of a feature in #![feature(foo)] that rust-analyzer presents the documentation rustc has for this feature.

Copy link
Member

Choose a reason for hiding this comment

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

That could be tested without requiring a full copy of the docs to be kept in sync. Just check that the string we get is non-empty or contains "the" or something like that.

bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 7, 2025
Rollup of 8 pull requests

Successful merges:

 - rust-lang#138603 (Report line number of test when should_panic test failed)
 - rust-lang#139035 (Add new `PatKind::Missing` variants)
 - rust-lang#139112 (Implement `super let`)
 - rust-lang#139365 (Default auto traits: fix perf)
 - rust-lang#139397 (coverage: Build the CGU's global file table as late as possible)
 - rust-lang#139455 ( Remove support for `extern "rust-intrinsic"` blocks)
 - rust-lang#139461 (Stop calling `source_span` query in significant drop order code)
 - rust-lang#139466 (Trivial tweaks to stop tracking source span directly)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 7, 2025
Rollup of 9 pull requests

Successful merges:

 - rust-lang#139035 (Add new `PatKind::Missing` variants)
 - rust-lang#139108 (Simplify `thir::PatKind::ExpandedConstant`)
 - rust-lang#139112 (Implement `super let`)
 - rust-lang#139365 (Default auto traits: fix perf)
 - rust-lang#139397 (coverage: Build the CGU's global file table as late as possible)
 - rust-lang#139455 ( Remove support for `extern "rust-intrinsic"` blocks)
 - rust-lang#139461 (Stop calling `source_span` query in significant drop order code)
 - rust-lang#139465 (add sret handling for scalar autodiff)
 - rust-lang#139466 (Trivial tweaks to stop tracking source span directly)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 9209c5e into rust-lang:master Apr 7, 2025
6 checks passed
@rustbot rustbot added this to the 1.88.0 milestone Apr 7, 2025
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Apr 7, 2025
Rollup merge of rust-lang#139455 - Skgland:remove_rust-intrinsic_ABI, r=oli-obk

 Remove support for `extern "rust-intrinsic"` blocks

Part of rust-lang#132735

Looked manageable and there didn't appear to have been progress in the last two weeks,
so decided to give it a try.
@Skgland Skgland deleted the remove_rust-intrinsic_ABI branch April 7, 2025 18:52
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Apr 7, 2025
… r=oli-obk

Update some comment/docs related to "extern intrinsic" removal

Follow-up to rust-lang#139455.

r? `@oli-obk`
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Apr 7, 2025
… r=oli-obk

Update some comment/docs related to "extern intrinsic" removal

Follow-up to rust-lang#139455.

r? ``@oli-obk``
Zalathar added a commit to Zalathar/rust that referenced this pull request Apr 8, 2025
… r=oli-obk

Update some comment/docs related to "extern intrinsic" removal

Follow-up to rust-lang#139455.

r? ```@oli-obk```
Zalathar added a commit to Zalathar/rust that referenced this pull request Apr 8, 2025
…kril

Revert r-a changes of rust-lang#139455

I discovered rust-lang#132735 (comment) that I might have done too much in rust-lang#132735 by also removing support in r-a.
So this reverts the commit with the changes to r-a.

r? RalfJung
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 8, 2025
…errors

Rollup of 19 pull requests

Successful merges:

 - rust-lang#138676 (Implement overflow for infinite implied lifetime bounds)
 - rust-lang#139024 (Make error message for missing fields with `..` and without `..` more consistent)
 - rust-lang#139098 (Tell LLVM about impossible niche tags)
 - rust-lang#139124 (compiler: report error when trait object type param reference self)
 - rust-lang#139321 (Update to new rinja version (askama))
 - rust-lang#139346 (Don't construct preds w escaping bound vars in `diagnostic_hir_wf_check`)
 - rust-lang#139386 (make it possible to use stage0 libtest on compiletest)
 - rust-lang#139421 (Fix trait upcasting to dyn type with no principal when there are projections)
 - rust-lang#139468 (Don't call `Span::with_parent` on the good path in `has_stashed_diagnostic`)
 - rust-lang#139476 (rm `RegionInferenceContext::var_infos`)
 - rust-lang#139481 (Add job summary links to post-merge report)
 - rust-lang#139485 (compiletest: Stricter parsing for diagnostic kinds)
 - rust-lang#139490 (Update some comment/docs related to "extern intrinsic" removal)
 - rust-lang#139491 (Update books)
 - rust-lang#139496 (Revert r-a changes of rust-lang#139455)
 - rust-lang#139500 (document panic behavior of Vec::resize and Vec::resize_with)
 - rust-lang#139501 (Fix stack overflow in exhaustiveness due to recursive HIR opaque hidden types)
 - rust-lang#139504 (add missing word in doc comment)
 - rust-lang#139507 (compiletest: Trim whitespace from environment variable names)

r? `@ghost`
`@rustbot` modify labels: rollup
Zalathar added a commit to Zalathar/rust that referenced this pull request Apr 8, 2025
… r=oli-obk

Update some comment/docs related to "extern intrinsic" removal

Follow-up to rust-lang#139455.

r? `@oli-obk`
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Apr 8, 2025
Rollup merge of rust-lang#139490 - RalfJung:unstable-intrinsics-docs, r=oli-obk

Update some comment/docs related to "extern intrinsic" removal

Follow-up to rust-lang#139455.

r? `@oli-obk`
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Apr 8, 2025
…kril

Revert r-a changes of rust-lang#139455

I discovered rust-lang#132735 (comment) that I might have done too much in rust-lang#132735 by also removing support in r-a.
So this reverts the commit with the changes to r-a.

r? RalfJung
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 8, 2025
…iaskrgr

Rollup of 10 pull requests

Successful merges:

 - rust-lang#139494 (Restrict some queries by def-kind more)
 - rust-lang#139496 (Revert r-a changes of rust-lang#139455)
 - rust-lang#139506 (add missing word in doc comment (part 2))
 - rust-lang#139515 (Improve presentation of closure signature mismatch from `Fn` trait goal)
 - rust-lang#139520 (compiletest maintenance: sort deps and drop dep on `anyhow`)
 - rust-lang#139523 (Rustc dev guide subtree update)
 - rust-lang#139526 (Fix deprecation note for std::intrinsics)
 - rust-lang#139528 (compiletest: Remove the `--logfile` flag)
 - rust-lang#139541 (Instantiate higher-ranked transmute goal w/ placeholders before emitting sub-obligations)
 - rust-lang#139547 (Update library tracking issue template to set S-tracking-unimplemented)

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
A-attributes Area: Attributes (`#[…]`, `#![…]`) A-run-make Area: port run-make Makefiles to rmake.rs 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. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants