about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2024-08-03allow setting `link-shared` and `static-libstdcpp` with CI LLVMonur-ozkan-3/+17
These options also affect `compiler/rustc_llvm` builds. They should be configurable even when using CI LLVM. Signed-off-by: onur-ozkan <work@onurozkan.dev>
2024-08-02Auto merge of #128352 - Oneirical:daLTOnist-vision, r=jieyouxubors-60/+148
Migrate `cross-lang-lto` `run-make` test to rmake Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). Please try: try-job: x86_64-msvc try-job: i686-mingw try-job: x86_64-mingw try-job: armhf-gnu try-job: test-various try-job: aarch64-apple try-job: x86_64-gnu-llvm-18
2024-08-02Auto merge of #128254 - Amanieu:orig-binary-search, r=tgross35bors-37/+50
Rewrite binary search implementation This PR builds on top of #128250, which should be merged first. This restores the original binary search implementation from #45333 which has the nice property of having a loop count that only depends on the size of the slice. This, along with explicit conditional moves from #128250, means that the entire binary search loop can be perfectly predicted by the branch predictor. Additionally, LLVM is able to unroll the loop when the slice length is known at compile-time. This results in a very compact code sequence of 3-4 instructions per binary search step and zero branches. Fixes #53823 Fixes #115271
2024-08-02Auto merge of #128529 - matthiaskrgr:rollup-gzq2slo, r=matthiaskrgrbors-225/+358
Rollup of 6 pull requests Successful merges: - #126818 (Better handle suggestions for the already present code and fix some suggestions) - #128436 (Update sysinfo version to 0.31.2) - #128453 (raw_eq: using it on bytes with provenance is not UB (outside const-eval)) - #128491 ([`macro_metavar_expr_concat`] Dogfooding) - #128494 (MIR required_consts, mentioned_items: ensure we do not forget to fill these lists) - #128521 (rustdoc: Remove dead opaque_tys rendering logic) r? `@ghost` `@rustbot` modify labels: rollup
2024-08-02Rollup merge of #128521 - aDotInTheVoid:opaque-fallout, r=camelidMatthias Krüger-11/+0
rustdoc: Remove dead opaque_tys rendering logic #127276 removed OpaqueTy from clean, and the code populating AllTypes::opaque_tys, but not this field itself.
2024-08-02Rollup merge of #128494 - RalfJung:mir-lazy-lists, r=compiler-errorsMatthias Krüger-44/+113
MIR required_consts, mentioned_items: ensure we do not forget to fill these lists Bodies initially get created with empty required_consts and mentioned_items, but at some point those should be filled. Make sure we notice when that is forgotten.
2024-08-02Rollup merge of #128491 - c410-f3r:unlock-rfc-2011, r=workingjubileeMatthias Krüger-16/+3
[`macro_metavar_expr_concat`] Dogfooding cc #124225 Starts inner usage to test the robustness of the implementation.
2024-08-02Rollup merge of #128453 - RalfJung:raw_eq, r=saethlinMatthias Krüger-35/+9
raw_eq: using it on bytes with provenance is not UB (outside const-eval) The current behavior of raw_eq violates provenance monotonicity. See https://github.com/rust-lang/rust/pull/124921 for an explanation of provenance monotonicity. It is violated in raw_eq because comparing bytes without provenance is well-defined, but adding provenance makes the operation UB. So remove the no-provenance requirement from raw_eq. However, the requirement stays in-place for compile-time invocations of raw_eq, that indeed cannot deal with provenance. Cc `@rust-lang/opsem`
2024-08-02Rollup merge of #128436 - GuillaumeGomez:update-sysinfo, r=clubby789Matthias Krüger-61/+158
Update sysinfo version to 0.31.2 I needed to update `memchr` version (which was pinned in https://github.com/rust-lang/rust/commit/36a16798f798eb59db21ff2a8a163135b4a599fe). So let's see if it triggers the linker issue. try-job: x86_64-mingw
2024-08-02Rollup merge of #126818 - estebank:suggestions-fix, r=wesleywiserMatthias Krüger-58/+75
Better handle suggestions for the already present code and fix some suggestions When a suggestion part is for code that is already present, skip it. If all the suggestion parts for a suggestion are for code that is already there, do not emit the suggestion. Fix two suggestions that treat `span_suggestion` as if it were `span_help`.
2024-08-02Auto merge of #128147 - lolbinarycat:fmt-write-bloat-rmake, r=jieyouxubors-26/+89
migrate fmt-write-bloat to rmake try-job: aarch64-apple try-job: x86_64-gnu-llvm-18 try-job: dist-x86_64-linux
2024-08-01DogfoodCaio-16/+3
2024-08-02Auto merge of #127624 - Oneirical:a-test-of-lime, r=jieyouxubors-37/+59
Migrate and rename `issue-47551`, `issue-35164` and `issue-69368` `run-make` tests to rmake Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). try-job: dist-x86_64-msvc
2024-08-01rustdoc: Remove dead opaque_tys rendering logicAlona Enraght-Moony-11/+0
2024-08-01Auto merge of #127276 - aDotInTheVoid:no-opaque, r=camelidbors-87/+56
rustdoc: Remove OpaqueTy r? `@ghost` Apparently this works lol?!? try-job: aarch64-apple
2024-08-01Do not underline suggestions for code that is already thereEsteban Küber-58/+75
When a suggestion part is for already present code, do not highlight it. If after that there are no highlights left, do not show the suggestion at all. Fix clippy lint suggestion incorrectly treated as `span_help`.
2024-08-01Auto merge of #128504 - matthiaskrgr:rollup-pawylnk, r=matthiaskrgrbors-417/+500
Rollup of 6 pull requests Successful merges: - #127490 (Add target page for riscv64gc-unknown-linux-gnu) - #128433 (fix(hermit): `deny(unsafe_op_in_unsafe_fn)`) - #128482 (interpret: on a signed deref check, mention the right pointer in the error) - #128496 (Fix removed `box_syntax` diagnostic if source isn't available) - #128497 (fix dropck documentation for `[T;0]` special-case) - #128499 (chore: refactor backtrace formatting) r? `@ghost` `@rustbot` modify labels: rollup
2024-08-01Rollup merge of #128499 - Konippi:refactor-backtrace-formatting, r=tgross35Matthias Krüger-7/+2
chore: refactor backtrace formatting Replace `write_str()` with the `writeln!()` macro, consolidating multiple write operations.
2024-08-01Rollup merge of #128497 - Bryanskiy:fix-dropck-doc, r=lcnrMatthias Krüger-3/+4
fix dropck documentation for `[T;0]` special-case fixes https://github.com/rust-lang/rust/issues/110288. r? ``@lcnr``
2024-08-01Rollup merge of #128496 - clubby789:box-syntax-multipart, r=compiler-errorsMatthias Krüger-17/+28
Fix removed `box_syntax` diagnostic if source isn't available Fix #128442
2024-08-01Rollup merge of #128482 - RalfJung:ptr-signed-offset, r=oli-obkMatthias Krüger-334/+277
interpret: on a signed deref check, mention the right pointer in the error When a negative offset (like `ptr.offset(-10)`) goes out-of-bounds, we currently show an error saying that we expect the *resulting* pointer to be inbounds for 10 bytes. That's confusing, so this PR makes it so that instead we say that we expect the *original* pointer `ptr` to have 10 bytes *to the left*. I also realized I can simplify the pointer arithmetic logic and handling of "staying inbounds of a target `usize`" quite a bit; the second commit does that.
2024-08-01Rollup merge of #128433 - hermit-os:hermit-unsafe_op_in_unsafe_fn, r=joboetMatthias Krüger-55/+58
fix(hermit): `deny(unsafe_op_in_unsafe_fn)` Tracking issue: https://github.com/rust-lang/rust/issues/127747 r? workingjubilee CC: ``@stlankes``
2024-08-01Rollup merge of #127490 - ↵Matthias Krüger-1/+131
ferrocene:hoverbear/add-riscv64gc-unknown-linux-target-page, r=pietroalbini Add target page for riscv64gc-unknown-linux-gnu I was reading https://github.com/rust-lang/rust/issues/113739 and realized I knew most of the information necessary to create the `riscv64gc-unknown-linux-gnu` target page.
2024-08-01rustdoc: Remove OpaqueTyAlona Enraght-Moony-87/+10
2024-08-01rustdoc: Add test for `impl_trait_in_accos_type`Alona Enraght-Moony-0/+46
2024-08-02chore: refactor backtrace formattingKonippi-7/+2
2024-08-01fix dropck documentation for `[T;0]` special-caseBryanskiy-3/+4
2024-08-01Update sysinfo version to 0.31.2Guillaume Gomez-61/+158
2024-08-01MIR required_consts, mentioned_items: ensure we do not forget to fill these ↵Ralf Jung-44/+113
lists
2024-08-01Auto merge of #128490 - lnicola:sync-from-ra, r=lnicolabors-7886/+15238
Subtree update of `rust-analyzer` r? `@ghost`
2024-08-01Fix removed `box_syntax` diagnostic if source isn't availableclubby789-17/+28
2024-08-01fix the way we detect overflow for inbounds arithmetic (and tweak the error ↵Ralf Jung-11/+17
message)
2024-08-01interpret: simplify pointer arithmetic logicRalf Jung-187/+73
2024-08-01on a signed deref check, mention the right pointer in the errorRalf Jung-141/+192
2024-08-01Auto merge of #127543 - carbotaniuman:more_unsafe_attr_verification, ↵bors-92/+471
r=estebank,traviscross More unsafe attr verification This code denies unsafe on attributes such as `#[test]` and `#[ignore]`, while also changing the `MetaItem` parsing so `unsafe` in args like `#[allow(unsafe(dead_code))]` is not accidentally allowed. Tracking: - https://github.com/rust-lang/rust/issues/123757
2024-08-01Auto merge of #17761 - RalfJung:josh-roudntrip-error, r=lnicolabors-1/+4
when josh-proxy screws up the roundtrip, say what the involved commits are Helps debugging https://github.com/rust-lang/rust-analyzer/issues/17733
2024-08-01fix(os/hermit): `deny(unsafe_op_in_unsafe_fn)`Martin Kröning-0/+1
Signed-off-by: Martin Kröning <martin.kroening@eonerc.rwth-aachen.de>
2024-08-01fix(pal/hermit): `deny(unsafe_op_in_unsafe_fn)`Martin Kröning-20/+40
Signed-off-by: Martin Kröning <martin.kroening@eonerc.rwth-aachen.de>
2024-08-01refactor(pal/hermit): make `ENV` a non-mutable staticMartin Kröning-19/+15
Signed-off-by: Martin Kröning <martin.kroening@eonerc.rwth-aachen.de>
2024-08-01when josh-proxy screws up the roundtrip, say what the involved commits areRalf Jung-1/+4
2024-08-01Auto merge of #17756 - Wilfred:fix_adoc_json, r=Veykrilbors-9/+7
docs: Fix JSON example for rust-analyzer.workspace.discoverConfig The user does not specify `{arg}` in their JSON, and be pedantic about commas in JSON sample.
2024-08-01Auto merge of #128481 - matthiaskrgr:rollup-efa706r, r=matthiaskrgrbors-114/+122
Rollup of 6 pull requests Successful merges: - #128416 (android: Remove libstd hacks for unsupported Android APIs) - #128437 (improve bootstrap to allow selecting llvm tools individually) - #128450 (Create COFF archives for non-LLVM backends) - #128458 (Emit an error if `#[optimize]` is applied to an incompatible item) - #128477 (Finish blessing `coverage/mcdc` tests after LLVM 19 upgrade) - #128478 (Ignore `use` declaration reformatting in `.git-blame-ignore-revs`.) r? `@ghost` `@rustbot` modify labels: rollup
2024-08-01Rollup merge of #128478 - nnethercote:update-git-blame-ignore-revs, r=jieyouxuMatthias Krüger-0/+2
Ignore `use` declaration reformatting in `.git-blame-ignore-revs`. The reformatting was done in #125443. r? `@lcnr`
2024-08-01Rollup merge of #128477 - Zalathar:bless-mcdc-19, r=cuviperMatthias Krüger-0/+5
Finish blessing `coverage/mcdc` tests after LLVM 19 upgrade Context: https://github.com/rust-lang/rust/pull/127513#issuecomment-2260887708 These changes aren't needed for Rust CI, because after the LLVM 19 upgrade we have no jobs that run these tests in `coverage-run` mode against LLVM 18. But they might help external builds. The longer-term plan is to completely drop (unstable) MC/DC support on LLVM 18, as part of getting it working on LLVM 19 in #126733. cc `@cuviper`
2024-08-01Rollup merge of #128458 - clubby789:optimize-unused-attr, r=compiler-errorsMatthias Krüger-0/+78
Emit an error if `#[optimize]` is applied to an incompatible item #54882 The RFC specifies that this should emit a lint. I used the same allow logic as the `coverage` attribute (also allowing modules and impl blocks) - this should possibly be changed depending on if it's decided to allow 'propogation' of the attribute.
2024-08-01Rollup merge of #128450 - dpaoliello:coff, r=bjorn3Matthias Krüger-5/+1
Create COFF archives for non-LLVM backends `ar_archive_writer` now supports creating COFF archives, so enable them for the non-LLVM backends when requested. r? ``@bjorn3``
2024-08-01Rollup merge of #128437 - onur-ozkan:handle-llvm-tools-properly, ↵Matthias Krüger-3/+34
r=albertlarsan68,Kobzol improve bootstrap to allow selecting llvm tools individually Everything works as before, + now bootstrap allows for individually selecting LLVM tools (e.g., `x dist opt llvm-dis`) to include in the dist artifact.
2024-08-01Rollup merge of #128416 - maurer:remove-android-hack, r=tgross35Matthias Krüger-106/+2
android: Remove libstd hacks for unsupported Android APIs Our minimum supported API version is 21, remove hacks to support older Android APIs. try-job: arm-android r? tgross35
2024-08-01Auto merge of #127060 - Oneirical:testificate, r=jieyouxubors-124/+188
Migrate `symbol-visibility` `run-make` test to rmake Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html). Pretty scary! - The expected number of symbols on each check has been changed slightly to reflect the differences between `llvm_readobj` and `nm`, as I think the former will print hidden symbols once and visible symbols twice, while the latter will only print visible symbols. - The original test ran the same exact checks on `cdylib` twice, for seemingly no reason. I have removed it. - This may be possible to optimize some more? `llvm_readobj` could get called only once for each library type, and the regex could avoid being created repeatedly. I am not sure if these kinds of considerations are important for a `run-make` test. Demands a Windows try-job. try-job: x86_64-mingw
2024-08-01Ignore `use` declaration reformatting in `.git-blame-ignore-revs`.Nicholas Nethercote-0/+2