| Age | Commit message (Collapse) | Author | Lines |
|
|
|
This isn't a perfect heuristic, but since the amount of run-fail tests
is far lower than run-pass tests for now, it should be sufficient to
ensure that we don't run into CI limits. This makes it possible to run
the test binary manually (e.g., under gdb/lldb) if it failed to attempt
to find out why.
|
|
This should save a lot of space on musl test cases (whose standard library
are linked statically).
|
|
|
|
|
|
|
|
Backport rustdoc ICE fixes to beta
backport of #47959
|
|
|
|
fixes #47639
|
|
[beta] Backports
Cherry-picked into beta:
- #47762
- #47794
- #47891
|
|
Backport 47738 to beta
Backport of #47738 to beta branch.
|
|
|
|
|
|
|
|
MIR's `Const::get_field()` attempts to retrieve the value for a given
field in a constant. In the case of a union constant it was falling
through to a generic `const_get_elt` based on the field index. As union
fields don't have an index this caused an ICE in `llvm_field_index`.
Fix by simply returning the current value when accessing any field in a
union. This works because all union fields start at byte offset 0.
The added test uses `const_fn` it ensure the field is extracted using
MIR's const evaluation. The crash is reproducible without it, however.
Fixes #47788
|
|
We can't use git commands to compute a prerelease version when we're
building from a source tarball, or if git is otherwise unavailable.
We'll just call such builds `x.y.z-beta`, without a prerelease.
|
|
|
|
|
|
|
|
Fixes #47139
|
|
When spawning a linker rustc has historically been known to blow OS limits for
the command line being too large, notably on Windows. This is especially true of
incremental compilation where there can be dozens of object files per
compilation. The compiler currently has logic for detecting a failure to spawn
and instead passing arguments via a file instead, but this failure detection
only triggers if a process actually fails to spawn.
Unfortunately on Windows we've got something else to worry about which is
`cmd.exe`. The compiler may be running a linker through `cmd.exe` where
`cmd.exe` has a limit of 8192 on the command line vs 32k on `CreateProcess`.
Moreso rustc actually succeeds in spawning `cmd.exe` today, it's just that after
it's running `cmd.exe` fails to spawn its child, which rustc doesn't currently
detect.
Consequently this commit updates the logic for the spawning the linker on
Windows to instead have a heuristic to see if we need to pass arguments via a
file. This heuristic is an overly pessimistic and "inaccurate" calculation which
just calls `len` on a bunch of `OsString` instances (where `len` is not
precisely the length in u16 elements). This number, when exceeding the 6k
threshold, will force rustc to always pass arguments through a file.
This strategy should avoid us trying to parse the output on Windows of the
linker to see if it successfully spawned yet failed to actually sub-spawn the
linker. We may just be passing arguments through files a little more commonly
now...
The motivation for this commit was a recent bug in Gecko [1] when beta testing,
notably when incremental compilation was enabled it blew out the limit on
`cmd.exe`. This commit will also fix #46999 as well though as emscripten uses a
bat script as well (and we're blowing the limit there).
[1]: https://bugzilla.mozilla.org/show_bug.cgi?id=1430886
Closes #46999
(cherry picked from commit 66366f9)
|
|
The match lowering code, when lowering matches against bytestrings,
works by coercing both the scrutinee and the pattern to `&[u8]` and
then comparing them using `<[u8] as Eq>::eq`.
If the scrutinee is already of type `&[u8]`, then unsizing it is both
unneccessary and a trait error caught by the new and updated MIR typeck,
so this PR changes lowering to avoid doing that (match lowering tried to
avoid that before, but that attempt was quite broken).
Fixes #46920.
|
|
|
|
|
|
Closes #47278
|
|
[beta] Turn back on "fat" LTO by default
This commit reverts a small portion of the switch to ThinLTO by default which
changed the meaning of `-C lto` from "put the whole crate graph into one codegen
unit" to "perform ThinLTO over the whole crate graph". This backport has no
corresponding commit on master as #47521 is making the same change but in a
slightly different manner. This commit is intended to be a surgical change with
low impact on beta.
Closes #47409
|
|
We got #47396 merged but it looks like rcs failed to deploy the beta because
when it tried to calculate the beta version its cwd was different. Let's try to
fix this bug and fix auto-deploy by explicitly setting the `current_dir` for git
commands.
|
|
This is only applicable when neither of --emit=llvm-ir or --emit=llvm-bc are not
requested.
In case either of these outputs are wanted, but the benefits of such context are
desired as well, -Zfewer_names option provides the same functionality regardless
of the outputs requested.
|
|
This fixes an accidental regression #46335 where the behavior of
`Path::ends_with` is different from `str::ends_with` (paths operate over
components, strs operate over chars).
|
|
|
|
This commit reverts a small portion of the switch to ThinLTO by default which
changed the meaning of `-C lto` from "put the whole crate graph into one codegen
unit" to "perform ThinLTO over the whole crate graph". This backport has no
corresponding commit on master as #47521 is making the same change but in a
slightly different manner. This commit is intended to be a surgical change with
low impact on beta.
Closes #47409
|
|
This commit automatically calculates the beta prerelease number meaning we'll no
longer need to manually change the beta version. Instead beta will automatically
deploy any time a backport is merged, ensuring that backports are released for
testing ASAP. More details about this can be found on the internal [forums]
The only bit of trickiness here was that on CI we do shallow clones by default
but the git history probing here requires some more information. Do cope with
that this commit chooses the strategy of converting the repository to a full
clone via the `--unshallow` flag to `git`. That way this should work for local
developers as well as CI changes.
Note that this commit is coming first to the beta branch to test it, and if
successful we can go back and land it on master.
[forums]: https://internals.rust-lang.org/t/tweaking-how-betas-are-produced/6526
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Upgrade `log` to `0.4` in multiple crates.
|
|
|
|
Routine update from dev to non-dev now that 1.23.0 is published
|
|
|
|
I believe this was forgotten from #45191 but hopefully is a simple fix!
|
|
* Update the channel of this release
* Update the bootstrap compiler to the dev artifacts
* Fix compile for last-minute backports
|
|
Use memchr for str::find(char)
This is a 10x improvement for searching for characters.
This also contains the patches from https://github.com/rust-lang/rust/pull/46713 . Feel free to land both separately or together.
cc @mystor @alexcrichton
r? @bluss
fixes #46693
|
|
Add compiler docs testing to CI.
Fixes #47025.
I don't know if `x86_64-gnu` is the right builder for this, but there seems to be time left on [Travis](https://travis-ci.org/rust-lang/rust/jobs/307488864).
Remaining problems blocking this PR:
- [x] broken links caused by rustdoc issues:
- [x] `pub use self::Enum::...`: #46766 and #46767 (fixed by #47050, thanks @ollie27!)
- [x] `impl Deref for DerefToStdType`: #32129 (ignored in linkchecker)
- [x] `#[feature(decl_macro)]` and `use std::vec`: #47038 (ignored in linkchecker)
- [x] `rustc_data_structures::sync::{Lrc, RwLock}` aliases `std` types: #32130 (ignored in linkchecker)
- [x] markdown differences, in rust repository and in external crates, now failing the build with #46880 merged (all fixed)
- [x] multiple crate updates needed: `rand`, `log`, `parking_lot_core`, `flate2`
- [x] submodule updates needed to deduplicate dependencies: `rust-installer`, ~`cargo`~ (done by #47052)
- [x] #44953 test broken by `log` update (removed, this can be controversial)
- [x] Waiting `x86_64-gnu` build results ([done](https://travis-ci.org/rust-lang/rust/builds/323451069))
See individual commits for more details.
|
|
|
|
|
|
|
|
As pointed out by @ollie27.
|