| Age | Commit message (Collapse) | Author | Lines |
|
[stable] Prepare Rust 1.58.0 release
Backported the release notes currently on master plus:
* https://github.com/rust-lang/rust/pull/92693
* https://github.com/rust-lang/rust/pull/92703
r? `@ghost`
cc `@rust-lang/release`
|
|
|
|
|
|
[beta] backports
Backports these PRs:
* Fix HashStable implementation on InferTy #91892
* Revert setting a default for the MACOSX_DEPLOYMENT_TARGET env var for linking #91870
* Make rustdoc headings black, and markdown blue #91534
* Disable LLVM newPM by default #91190
* Deduplicate projection sub-obligations #90423
* Sync portable-simd to remove autosplats #91484 by dropping portable_simd entirely (keeping the subtree, just from std/core)
* Quote bat script command line #92208
* Fix failing tests #92201 (CI fix)
r? `@Mark-Simulacrum`
|
|
|
|
|
|
Stand-in for a backport of "Sync portable-simd to remove autosplats #91484".
|
|
|
|
|
|
|
|
As suggested via reviewer feedback.
|
|
Adds the minimial repro test case from #85360. The fix for #85360 was
supposed to be #85868 however the repro was resolved in the 2021-07-05
nightly while #85360 didn't land until 2021-09-03. The reason for that
is d34a3a401b4e44f289a4d5bf53da83367cbb6aa7 **also** resolves that
issue.
To test if #85868 actually fixes #85360, I reverted
d34a3a401b4e44f289a4d5bf53da83367cbb6aa7 and found that #85868 does
indeed resolve #85360.
With that question resolved, add a test case to our incremental test
suite for the original Ok(EvaluatedToOkModuloRegions) ICE.
Thanks to @lqd for helping track this down!
|
|
cc #91128
|
|
|
|
This reverts commit b376f5621b801460b911a75048a70698021bbc69, which is
the main part of #90499, because it turns out that this causes a good
amount of breakage in crates relying on the old behavior.
Fixes #91372.
|
|
|
|
[beta] Bump bootstrap to released stable compiler
Finish release process.
r? `@Mark-Simulacrum`
|
|
|
|
[beta] branch master to beta
Bumps channel and includes a backport of:
* Don't treat unnormalized function arguments as well-formed #91243
r? `@Mark-Simulacrum`
|
|
|
|
|
|
Rollup of 7 pull requests
Successful merges:
- #90611 (Fix another ICE in rustdoc scrape_examples)
- #91197 (rustdoc: Rename `Type::ResolvedPath` to `Type::Path` and don't re-export it)
- #91223 (Fix headings indent)
- #91240 (Saner formatting for UTF8_CHAR_WIDTH table)
- #91248 (Bump compiler-builtins to 0.1.53)
- #91252 (Fix bug where submodules wouldn't be updated when running x.py from a subdirectory)
- #91259 (Remove `--display-doctest-warnings`)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Remove `--display-doctest-warnings`
`--display-doctest-warnings` can be replicated in full with other existing features, there's no
need to have a separate option for it. This removes the option and documents the combination of other features to replicate it.
This also fixes a bug where `--test-args=--show-output` had no effect.
cc `@ollie27,` https://github.com/rust-lang/rust/pull/73314#issuecomment-668317262
Fixes https://github.com/rust-lang/rust/issues/41574
r? `@GuillaumeGomez`
|
|
Fix bug where submodules wouldn't be updated when running x.py from a subdirectory
Previously, it would concatenate the relative path to the current
subdirectory, which looked at the wrong folder.
I tested this by checking out `1.56.1`, changing the current directory
to `src/`, and running `../x.py build`.
Fixes https://github.com/rust-lang/rust/issues/90481 (cc `@pnkfelix).`
r? `@Mark-Simulacrum`
|
|
r=Mark-Simulacrum
Bump compiler-builtins to 0.1.53
Fixes a LLVM crash with the bpf targets, see https://github.com/rust-lang/compiler-builtins/pull/440
|
|
Saner formatting for UTF8_CHAR_WIDTH table
The way these lines were currently wrapped definitely does not look like someone's intentional formatting. It's likely they got disfigured by rustfmt at some point.
This commit rearranges it to a rustfmt-compatible formatting that I find easier to read.
|
|
Fix headings indent
Fixes #91200.
Screenshots with the fix:


If the first element of a top docblock is a heading, we still need to keep the indent, but only on this one (I added a test to check it). We need it because otherwise the anchor will go over the `[-]` toggle.
cc `@camelid`
r? `@jsha`
|
|
rustdoc: Rename `Type::ResolvedPath` to `Type::Path` and don't re-export it
The new name is shorter, simpler, and consistent with `hir::Ty`. It can't be
re-exported since the name would conflict with the `clean::Path` struct. But
usually enum variants are referred to using their qualified names in Rust anyway
(and parts of rustdoc already do that with `clean::Type`), so this is also more
consistent with the language.
r? `@GuillaumeGomez`
cc `@jyn514`
|
|
Fix another ICE in rustdoc scrape_examples
This has occurred to me when documenting a crate with the arguments. Not sure what could have caused it.
r? `@willcrichton`
|
|
Faster `Layout::array`
`Layout::array` is called (indirectly) by `Vec::push()`, which is typically instantiated many times, and so making it smaller can help with compile times because less LLVM IR is generated.
r? `@ghost`
|
|
This can be replicated in full with other existing features, there's no
need to have a separate option for it.
This also fixes a bug where `--test-args=--show-output` had no effect,
and updates the documentation.
|
|
At last! The new name is shorter, simpler, and consistent with
`hir::Ty`.
|
|
|
|
heading of the top doc block
|
|
|
|
Rollup of 4 pull requests
Successful merges:
- #91169 (Change cg_ssa's get_param to borrow the builder mutably)
- #91176 (If the thread does not get the lock in the short term, yield the CPU)
- #91212 (Fix ICE due to out-of-bounds statement index when reporting borrowck error)
- #91225 (Fix invalid scrollbar display on source code page)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
|
|
|
|
|
|
Fix invalid scrollbar display on source code page
Fixes bug introduced in #90983:


To fix it, I simply unset the `overflow-y` on the source code page so it's not displayed anymore.
r? ``@jsha``
|
|
Fix ICE due to out-of-bounds statement index when reporting borrowck error
Replace an `[index]` with a `.get` when `statement_index` points to a basic-block terminator (and is therefore out-of-bounds in the statements list).
Fixes #91206
Cc ``@camsteffen``
r? ``@oli-obk``
|
|
If the thread does not get the lock in the short term, yield the CPU
Reduces on [RustyHermit](https://github.com/hermitcore/rusty-hermit) the amount of wasted processor cycles
|
|
Change cg_ssa's get_param to borrow the builder mutably
This is a small change to make `get_param` more flexible for codegens that may need to modify things when retrieving function parameters.
This will currently only be used by [rustc_codegen_nvvm](https://github.com/Rust-GPU/Rust-CUDA) (my own project), but may be useful to more codegens in the future.
This is needed because cg_nvvm needs to remap certain types to libnvvm-friendly types, such as `i128` -> `<2 x i64>`. Because cg_ssa does not give mutable access to the builder, i resorted to using a mutex:
```rs
fn get_param(&self, index: usize) -> Self::Value {
let val = llvm::get_param(self.llfn(), index as c_uint);
trace!("Get param `{:?}`", val);
unsafe {
let llfnty = LLVMRustGetFunctionType(self.llfn());
let map = self.remapped_integer_args.borrow();
if let Some((_, key)) = map.get(llfnty) {
if let Some((_, new_ty)) = key.iter().find(|t| t.0 == index) {
trace!("Casting irregular param {:?} to {:?}", val, new_ty);
return transmute_llval(
*self.llbuilder.lock().unwrap(),
&self.cx,
val,
*new_ty,
);
}
}
val
}
}
```
However, i predict this is pretty bad for performance, considering how much builders are called during codegen, so i would greatly appreciate having a more flexible API for this.
|
|
subdirectory
Previously, it would concatenate the relative path to the current
subdirectory, which looked at the wrong folder.
I tested this by checking out `1.56.1`, changing the current directory
to `src/`, and running `../x.py build`.
|
|
Fix stack overflow in `usefulness.rs`
Fix #88747
Applied the suggestion from `@nbdd0121,` not sure if this has any drawbacks. The first call to `ensure_sufficient_stack` is not needed to fix the test case, but I added it to be safe.
|
|
Fixes a LLVM crash with the bpf targets
|
|
Visit `param_env` field in Obligation's `TypeFoldable` impl
This oversight appears to have gone unnoticed for a long time
without causing issues, but it should still be fixed.
|
|
Because there's some subtle behaviour specific to zero-sized types and
it's currently not well tested.
|
|
The current implementation is much more conservative than it needs to
be, because it's dealing with the size and alignment of a given `T`,
which are more restricted than an arbitrary `Layout`.
For example, imagine a struct with a `u32` and a `u4`. You can safely
create a `Layout { size_: 5, align_: 4 }` by hand, but
`Layout::new::<T>` will give `Layout { size_: 8, align_: 4}`, where the
size already has padding that accounts for the alignment. (And the
existing `debug_assert_eq!` in `Layout::array` already demonstrates that
no additional padding is required.)
|
|
Other, similar methods for `Layout` do likewise, and there's already an
`unwrap()` around the result demonstrating the safety.
|