-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
Conversation
- src\doc\nomicon\src\ffi.md should also have its ABI list updated
r? @wesleywiser rustbot has assigned @wesleywiser. Use |
These commits modify compiler targets. This PR modifies cc @jieyouxu Some changes occurred to the intrinsics. Make sure the CTFE / Miri interpreter cc @rust-lang/miri, @RalfJung, @oli-obk, @lcnr Some changes occurred in compiler/rustc_passes/src/check_attr.rs 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 |
@bors r+ |
… 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. |
There was a problem hiding this comment.
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.
There was a problem hiding this comment.
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. |
There was a problem hiding this comment.
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?
There was a problem hiding this comment.
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.
There was a problem hiding this comment.
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.
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
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
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.
… r=oli-obk Update some comment/docs related to "extern intrinsic" removal Follow-up to rust-lang#139455. r? `@oli-obk`
… r=oli-obk Update some comment/docs related to "extern intrinsic" removal Follow-up to rust-lang#139455. r? ``@oli-obk``
… r=oli-obk Update some comment/docs related to "extern intrinsic" removal Follow-up to rust-lang#139455. r? ```@oli-obk```
…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
…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
… r=oli-obk Update some comment/docs related to "extern intrinsic" removal Follow-up to rust-lang#139455. r? `@oli-obk`
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`
…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
…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
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.