Commit Graph

222895 Commits

Author SHA1 Message Date
Ryan Lowe
34136ab598 Add support for allocators in LinkedList 2023-04-24 22:30:16 -04:00
bors
f6830a2129 Auto merge of #110232 - Amanieu:old-llvm-components, r=petrochenkov
Allow older LLVM versions to have missing components

This check was introduced by #77280 to ensure that all tests that are filtered by LLVM component are actually tested in CI. However this causes issues for new targets (e.g. #101069) where support is only available on the latest LLVM version.

This PR restricts the tests to only CI jobs that use the latest LLVM version.
2023-04-25 02:09:27 +00:00
Josh Stone
603e5d764e Revert "Download the GCC sources insecurely"
This reverts commit 3da037f829.
2023-04-24 17:17:56 -07:00
bors
fdeef3ed18 Auto merge of #106152 - SUPERCILEX:lazycell, r=Amanieu
Add LazyCell::into_inner

This enables uses cases that need to extract the evaluated value and do something owned with it.
2023-04-24 23:47:32 +00:00
Matthias Krüger
23a363821d Revert "Report allocation errors as panics"
This reverts commit c9a6e41026.
2023-04-25 00:08:37 +02:00
Matthias Krüger
f54dbe6e31 Revert "Remove #[alloc_error_handler] from the compiler and library"
This reverts commit abc0660118.
2023-04-25 00:08:35 +02:00
Matthias Krüger
33253fa6a4 Revert "Rename -Zoom=panic to -Zoom=unwind"
This reverts commit 4b981c2648.
2023-04-25 00:08:33 +02:00
Matthias Krüger
653cfdb436 Revert "Adjust expected result for coverage test"
This reverts commit 4da05e0b88.
2023-04-25 00:08:29 +02:00
bors
f5559e3382 Auto merge of #110718 - flip1995:clippyup, r=Manishearth
Update Clippy

r? `@Manishearth`

A few days late, I was on a business trip, sorry.
2023-04-24 21:25:56 +00:00
bors
521de433f4 Auto merge of #110778 - JohnTitor:rollup-7f51qwk, r=JohnTitor
Rollup of 10 pull requests

Successful merges:

 - #110480 (Add `known-bug` tests for 11 unsound issues)
 - #110539 (Move around `{Idx, IndexVec, IndexSlice}` adjacent code)
 - #110590 (Add some tests around (lack of) object safety of associated types and consts)
 - #110602 (Ignore src/bootstrap formatting commit in .git-blame-ignore-revs)
 - #110667 (pointer-auth-link-with-c: Fix cross compilation.)
 - #110681 (drop few unused crates, gate libc under unix for rustc_codegen_ssa)
 - #110685 (Some cleanups to DataflowConstProp)
 - #110744 (bootstrap: update paths cargo-credential crate)
 - #110750 (Add size asserts for MIR `SourceScopeData` & `VarDebugInfo`)
 - #110760 (rustdoc: Add regression test for #60522)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-04-24 19:09:19 +00:00
Michael Goulet
794cb890de Consider polarity in new solver 2023-04-24 18:59:42 +00:00
Camille GILLOT
0f857791ad Fully clear the body. 2023-04-24 18:53:47 +00:00
Yuki Okushi
513c0cc5ba
Rollup merge of #110760 - GuillaumeGomez:regression-60522, r=notriddle
rustdoc: Add regression test for #60522

Fixes https://github.com/rust-lang/rust/issues/60522.

r? `@notriddle`
2023-04-25 02:33:31 +09:00
Yuki Okushi
16fdef7868
Rollup merge of #110750 - scottmcm:vardebug-size, r=cjgillot
Add size asserts for MIR `SourceScopeData` & `VarDebugInfo`

There's vectors of both of these in `mir::Body`, so might as well track them.

(I was pondering adding something to one or the other, so wanted this to see the memory impact.)
2023-04-25 02:33:31 +09:00
Yuki Okushi
b708aadfbe
Rollup merge of #110744 - weihanglo:cargo-credential-install, r=ehuss
bootstrap: update paths cargo-credential crate

This should be done in #110653 but forgot.

Fixes #110742

## How to verify this patch

Run `./x.py build cargo`. Previously it would fail with

```console
error: manifest path `/projects/rust/src/tools/cargo/crates/credential/cargo-credential-1password/Cargo.toml` does not exist
```
2023-04-25 02:33:30 +09:00
Yuki Okushi
4d3ab3da4e
Rollup merge of #110685 - cjgillot:clean-dcp, r=oli-obk
Some cleanups to DataflowConstProp

Mostly moving code around and short-circuiting useless cases.
2023-04-25 02:33:30 +09:00
Yuki Okushi
a373623d55
Rollup merge of #110681 - klensy:cut-dep, r=lcnr
drop few unused crates, gate libc under unix for rustc_codegen_ssa

Small cleanup.
2023-04-25 02:33:29 +09:00
Yuki Okushi
2a2df56db5
Rollup merge of #110667 - pcc:fix-pointer-auth-link-with-c, r=Mark-Simulacrum
pointer-auth-link-with-c: Fix cross compilation.
2023-04-25 02:33:29 +09:00
Yuki Okushi
e0bb7bb089
Rollup merge of #110602 - jyn514:ignore-fmt, r=Mark-Simulacrum
Ignore src/bootstrap formatting commit in .git-blame-ignore-revs

b39a1d6f1a
2023-04-25 02:33:26 +09:00
Yuki Okushi
1a906f2b3c
Rollup merge of #110590 - oli-obk:object_safe_assoc_types, r=jackh726
Add some tests around (lack of) object safety of associated types and consts

See https://rust-lang.zulipchat.com/#narrow/stream/144729-t-types/topic/.60where.20Self.3ASized.60.20on.20assoc.20types/near/351260928 for some discussion around why this isn't allowed.

We didn't have any tests for these, so I decided to add them now, even if we don't end up doing anything about it.
2023-04-25 02:33:26 +09:00
Yuki Okushi
cefb479242
Rollup merge of #110539 - WaffleLapkin:split_index_vec&slice, r=cjgillot
Move around `{Idx, IndexVec, IndexSlice}` adjacent code

r? ``@scottmcm``
2023-04-25 02:33:25 +09:00
Yuki Okushi
42467d57cb
Rollup merge of #110480 - whtahy:105107/known-bug-tests-for-unsound-issues, r=jackh726
Add `known-bug` tests for 11 unsound issues

r? ``@jackh726``

Should tests for other issues be in separate PRs?  Thanks.

Edit: Partially addresses #105107.  This PR adds `known-bug` tests for 11 unsound issues:
- #25860
- #49206
- #57893
- #84366
- #84533
- #84591
- #85099
- #98117
- #100041
- #100051
- #104005
2023-04-25 02:33:25 +09:00
jchzhou
d2516c1191 configure.py: add flag for riscv{64,32}gc musl-root 2023-04-25 01:20:28 +08:00
bors
253b727f46 Auto merge of #110713 - cjgillot:track-mir-opt, r=scottmcm
Add mir-opt tests to track MIR quality.

cc `@scottmcm` `@saethlin`

If you have other ideas, please say so.
2023-04-24 17:01:02 +00:00
rustbot
d4e81bd3fd Update books 2023-04-24 13:00:24 -04:00
Maybe Waffle
2b8d27b402 Switch impl_tag! from explicit tags to ${index()} 2023-04-24 16:48:37 +00:00
Mara Bos
7bae143cfb Update miri test. 2023-04-24 17:22:57 +02:00
Mara Bos
9cc5949f9f Update tests. 2023-04-24 16:16:14 +02:00
Mara Bos
0a28977740 Restructure std::fmt::rt a bit.
This moves more of the internal/lang items into the private rt module.
2023-04-24 16:16:14 +02:00
Mara Bos
5cf3cbf3b7 Remove "V1" from ArgumentsV1 and FlagsV1. 2023-04-24 16:16:14 +02:00
Maybe Waffle
c0daff08c7 Fix rustc_index imports outside the compiler 2023-04-24 13:53:37 +00:00
Maybe Waffle
5d809b1764 Decorative changes to IndexVec 2023-04-24 13:53:37 +00:00
Maybe Waffle
7d23b52376 const-ify some {IndexVec, IndexSlice} methods 2023-04-24 13:53:37 +00:00
Maybe Waffle
99ebfe2f15 move index code around 2023-04-24 13:53:37 +00:00
Maybe Waffle
e496fbec92 Split {Idx, IndexVec, IndexSlice} into their own modules 2023-04-24 13:53:35 +00:00
bors
b72460fe46 Auto merge of #110672 - Ezrashaw:allow-array-simd-in-inline-asm, r=workingjubilee
allow array-style simd in inline asm

Required for [MCP#621](https://github.com/rust-lang/compiler-team/issues/621) to be implemented.

r? `@workingjubilee`
2023-04-24 13:51:04 +00:00
Guillaume Gomez
5c70287c51 Add regression test for #60522 2023-04-24 13:12:24 +02:00
bors
64bcb32651 Auto merge of #110752 - matthiaskrgr:rollup-959s77u, r=matthiaskrgr
Rollup of 6 pull requests

Successful merges:

 - #110255 (Suggest using integration tests for test crate using own proc-macro)
 - #110514 (Remove `find_map_relevant_impl`)
 - #110566 (Don't create projection ty for const projection)
 - #110637 (Group some sections of our logs in github actions)
 - #110706 (Add `intrinsics::transmute_unchecked`)
 - #110714 (Normalize types and consts in MIR opts.)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-04-24 10:03:12 +00:00
Tim Neumann
047ed32148 [LLVM17] Adapt to ExplicitEmulatedTLS removal. 2023-04-24 08:45:15 +00:00
Philipp Krones
bb63b5908c
Clippy book: hotfix for broken link 2023-04-24 09:47:54 +02:00
Matthias Krüger
2ce9b574a4
Rollup merge of #110714 - cjgillot:reveal-consts, r=oli-obk
Normalize types and consts in MIR opts.

Some passes were using a non-RevealAll param_env, which is needlessly restrictive in mir-opts.

As a drive-by, we normalize all constants, since just normalizing their types is not enough.
2023-04-24 07:53:25 +02:00
Matthias Krüger
3ecae2932c
Rollup merge of #110706 - scottmcm:transmute_unchecked, r=oli-obk
Add `intrinsics::transmute_unchecked`

This takes a whole 3 lines in `compiler/` since it lowers to `CastKind::Transmute` in MIR *exactly* the same as the existing `intrinsics::transmute` does, it just doesn't have the fancy checking in `hir_typeck`.

Added to enable experimenting with the request in <https://github.com/rust-lang/rust/pull/106281#issuecomment-1496648190> and because the portable-simd folks might be interested for dependently-sized array-vector conversions.

It also simplifies a couple places in `core`.

See also https://github.com/rust-lang/rust/pull/108442#issuecomment-1474777273, where `CastKind::Transmute` was added having exactly these semantics before the lang meeting (which I wasn't in) independently expressed interest.
2023-04-24 07:53:25 +02:00
Matthias Krüger
775682dc5e
Rollup merge of #110637 - oli-obk:gha, r=jyn514
Group some sections of our logs in github actions

This makes logs a little bit more readable as you can now collapse all the parts that don't interest you (and they get collapsed automatically)

Obviously there's a lot more sites where we can/need to do this, too, but this is already helpful imo

r? ```@jyn514```
2023-04-24 07:53:25 +02:00
Matthias Krüger
8aab707131
Rollup merge of #110566 - compiler-errors:bad-projection-term, r=cjgillot,BoxyUwU
Don't create projection ty for const projection

Fixes #110549
2023-04-24 07:53:24 +02:00
Matthias Krüger
d60c64a0c5
Rollup merge of #110514 - compiler-errors:remove-find_map_relevant_impl, r=b-naber
Remove `find_map_relevant_impl`

Fixes #108895
2023-04-24 07:53:24 +02:00
Matthias Krüger
0f271619e4
Rollup merge of #110255 - clubby789:proc-macro-test-help, r=jackh726
Suggest using integration tests for test crate using own proc-macro

cc #110247
2023-04-24 07:53:23 +02:00
Scott McMurray
31531ce939 Add size asserts for MIR SourceScopeData & VarDebugInfo
There's vectors of both of these in `mir::Body`, so might as well track them.
2023-04-23 21:23:54 -07:00
bors
f65615f02d Auto merge of #109590 - Nilstrieb:copy-hir, r=oli-obk
Impl `Copy` for most HIR types

This simplifies the invocation of the `arena_types` macro and probably
makes working with HIR nicer in general.

Based on #109588
2023-04-24 03:10:55 +00:00
bors
8991768e67 Auto merge of #110736 - matthiaskrgr:rollup-gorv8zp, r=matthiaskrgr
Rollup of 6 pull requests

Successful merges:

 - #110661 (rustdoc: clean up settings.css and settings.js)
 - #110663 (Add note about change in bootstrap defaults)
 - #110664 (stop `x fmt` formatting untracked directories)
 - #110668 (Fix printing native CPU on cross-compiled compiler.)
 - #110689 (Fix grammar in core::hint::unreachable_unchecked() docs)
 - #110700 (Don't infer fn return type to return itself)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
2023-04-24 00:05:59 +00:00
Weihang Lo
f5e535cb3e
bootstrap: update paths cargo-credential crate
This should be done in #110653 but forgot.
2023-04-23 23:31:15 +01:00