Skip to content

Commit 60f1644

Browse files
committed
Merge remote-tracking branch 'upstream/master' into asm-compile-tests
2 parents eeb5f17 + 2c8bbf5 commit 60f1644

File tree

478 files changed

+5342
-4188
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

478 files changed

+5342
-4188
lines changed

Cargo.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ dependencies = [
251251
"fwdansi 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
252252
"git2 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
253253
"git2-curl 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
254-
"glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
254+
"glob 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
255255
"hex 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
256256
"home 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
257257
"ignore 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1009,7 +1009,7 @@ dependencies = [
10091009

10101010
[[package]]
10111011
name = "glob"
1012-
version = "0.2.11"
1012+
version = "0.3.0"
10131013
source = "registry+https://github.com/rust-lang/crates.io-index"
10141014

10151015
[[package]]
@@ -4083,7 +4083,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
40834083
"checksum getopts 0.2.17 (registry+https://github.com/rust-lang/crates.io-index)" = "b900c08c1939860ce8b54dc6a89e26e00c04c380fd0e09796799bd7f12861e05"
40844084
"checksum git2 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c7339329bfa14a00223244311560d11f8f489b453fb90092af97f267a6090ab0"
40854085
"checksum git2-curl 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d58551e903ed7e2d6fe3a2f3c7efa3a784ec29b19d0fbb035aaf0497c183fbdd"
4086-
"checksum glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "8be18de09a56b60ed0edf84bc9df007e30040691af7acd1c41874faac5895bfb"
4086+
"checksum glob 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574"
40874087
"checksum globset 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "4743617a7464bbda3c8aec8558ff2f9429047e025771037df561d383337ff865"
40884088
"checksum handlebars 0.32.4 (registry+https://github.com/rust-lang/crates.io-index)" = "d89ec99d1594f285d4590fc32bac5f75cdab383f1123d504d27862c644a807dd"
40894089
"checksum handlebars 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d82e5750d8027a97b9640e3fefa66bbaf852a35228e1c90790efd13c4b09c166"

RELEASES.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,11 @@ Compatibility Notes
110110
methods instead.
111111
- The `Error::cause` method has been deprecated in favor of `Error::source` which supports
112112
downcasting.
113+
- [Libtest no longer creates a new thread for each test when
114+
`--test-threads=1`. It also runs the tests in deterministic order][56243]
113115

114116
[55982]: https://github.com/rust-lang/rust/pull/55982/
117+
[56243]: https://github.com/rust-lang/rust/pull/56243
115118
[56303]: https://github.com/rust-lang/rust/pull/56303/
116119
[56351]: https://github.com/rust-lang/rust/pull/56351/
117120
[56362]: https://github.com/rust-lang/rust/pull/56362

appveyor.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
environment:
2+
# This is required for at least an AArch64 compiler in one image, and is also
3+
# going to soon be required for compiling LLVM.
4+
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 Preview
25

36
# By default schannel checks revocation of certificates unlike some other SSL
47
# backends, but we've historically had problems on CI where a revocation
@@ -81,7 +84,6 @@ environment:
8184
DIST_REQUIRE_ALL_TOOLS: 1
8285
DEPLOY: 1
8386
CI_JOB_NAME: dist-x86_64-msvc
84-
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 Preview
8587
- RUST_CONFIGURE_ARGS: >
8688
--build=i686-pc-windows-msvc
8789
--target=i586-pc-windows-msvc

src/bootstrap/bin/rustdoc.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ fn main() {
3535
.arg("--cfg")
3636
.arg("dox")
3737
.arg("--sysroot")
38-
.arg(sysroot)
38+
.arg(&sysroot)
3939
.env(bootstrap::util::dylib_path_var(),
4040
env::join_paths(&dylib_path).unwrap());
4141

@@ -72,7 +72,13 @@ fn main() {
7272
}
7373

7474
if verbose > 1 {
75-
eprintln!("rustdoc command: {:?}", cmd);
75+
eprintln!(
76+
"rustdoc command: {:?}={:?} {:?}",
77+
bootstrap::util::dylib_path_var(),
78+
env::join_paths(&dylib_path).unwrap(),
79+
cmd,
80+
);
81+
eprintln!("sysroot: {:?}", sysroot);
7682
eprintln!("libdir: {:?}", libdir);
7783
}
7884

src/bootstrap/builder.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -374,6 +374,7 @@ impl<'a> Builder<'a> {
374374
test::MirOpt,
375375
test::Codegen,
376376
test::CodegenUnits,
377+
test::Assembly,
377378
test::Incremental,
378379
test::Debuginfo,
379380
test::UiFullDeps,
@@ -408,12 +409,11 @@ impl<'a> Builder<'a> {
408409
test::RustdocJSStd,
409410
test::RustdocJSNotStd,
410411
test::RustdocTheme,
412+
test::RustdocUi,
411413
// Run bootstrap close to the end as it's unlikely to fail
412414
test::Bootstrap,
413415
// Run run-make last, since these won't pass without make on Windows
414416
test::RunMake,
415-
test::RustdocUi,
416-
test::Assembly,
417417
),
418418
Kind::Bench => describe!(test::Crate, test::CrateLibrustc),
419419
Kind::Doc => describe!(

src/bootstrap/lib.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,8 @@ pub struct Build {
241241
clippy_info: channel::GitInfo,
242242
miri_info: channel::GitInfo,
243243
rustfmt_info: channel::GitInfo,
244+
in_tree_llvm_info: channel::GitInfo,
245+
emscripten_llvm_info: channel::GitInfo,
244246
local_rebuild: bool,
245247
fail_fast: bool,
246248
doc_tests: DocTests,
@@ -363,6 +365,8 @@ impl Build {
363365
let clippy_info = channel::GitInfo::new(&config, &src.join("src/tools/clippy"));
364366
let miri_info = channel::GitInfo::new(&config, &src.join("src/tools/miri"));
365367
let rustfmt_info = channel::GitInfo::new(&config, &src.join("src/tools/rustfmt"));
368+
let in_tree_llvm_info = channel::GitInfo::new(&config, &src.join("src/llvm-project"));
369+
let emscripten_llvm_info = channel::GitInfo::new(&config, &src.join("src/llvm-emscripten"));
366370

367371
let mut build = Build {
368372
initial_rustc: config.initial_rustc.clone(),
@@ -386,6 +390,8 @@ impl Build {
386390
clippy_info,
387391
miri_info,
388392
rustfmt_info,
393+
in_tree_llvm_info,
394+
emscripten_llvm_info,
389395
cc: HashMap::new(),
390396
cxx: HashMap::new(),
391397
ar: HashMap::new(),

src/bootstrap/mk/Makefile.in

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ check:
4848
$(Q)$(BOOTSTRAP) test $(BOOTSTRAP_ARGS)
4949
check-aux:
5050
$(Q)$(BOOTSTRAP) test \
51-
src/test/pretty \
5251
src/test/run-pass/pretty \
5352
src/test/run-fail/pretty \
5453
src/test/run-pass-valgrind/pretty \

src/bootstrap/native.rs

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ use build_helper::output;
1818
use cmake;
1919
use cc;
2020

21+
use crate::channel;
2122
use crate::util::{self, exe};
2223
use build_helper::up_to_date;
2324
use crate::builder::{Builder, RunConfig, ShouldRun, Step};
@@ -231,7 +232,26 @@ impl Step for Llvm {
231232
}
232233

233234
if let Some(ref suffix) = builder.config.llvm_version_suffix {
234-
cfg.define("LLVM_VERSION_SUFFIX", suffix);
235+
// Allow version-suffix="" to not define a version suffix at all.
236+
if !suffix.is_empty() {
237+
cfg.define("LLVM_VERSION_SUFFIX", suffix);
238+
}
239+
} else {
240+
let mut default_suffix = format!(
241+
"-rust-{}-{}",
242+
channel::CFG_RELEASE_NUM,
243+
builder.config.channel,
244+
);
245+
let llvm_info = if self.emscripten {
246+
&builder.emscripten_llvm_info
247+
} else {
248+
&builder.in_tree_llvm_info
249+
};
250+
if let Some(sha) = llvm_info.sha_short() {
251+
default_suffix.push_str("-");
252+
default_suffix.push_str(sha);
253+
}
254+
cfg.define("LLVM_VERSION_SUFFIX", default_suffix);
235255
}
236256

237257
if let Some(ref linker) = builder.config.llvm_use_linker {

src/bootstrap/test.rs

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -897,12 +897,10 @@ host_test!(Rustdoc {
897897
suite: "rustdoc"
898898
});
899899

900-
test!(Pretty {
900+
host_test!(Pretty {
901901
path: "src/test/pretty",
902902
mode: "pretty",
903-
suite: "pretty",
904-
default: false,
905-
host: true
903+
suite: "pretty"
906904
});
907905
test!(RunPassPretty {
908906
path: "src/test/run-pass/pretty",
@@ -999,11 +997,7 @@ impl Step for Compiletest {
999997
});
1000998
}
1001999

1002-
if suite.ends_with("fulldeps") ||
1003-
// FIXME: Does pretty need librustc compiled? Note that there are
1004-
// fulldeps test suites with mode = pretty as well.
1005-
mode == "pretty"
1006-
{
1000+
if suite.ends_with("fulldeps") {
10071001
builder.ensure(compile::Rustc { compiler, target });
10081002
}
10091003

src/ci/docker/dist-x86_64-musl/Dockerfile

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
44
g++ \
55
make \
66
file \
7+
wget \
78
curl \
89
ca-certificates \
910
python2.7 \
@@ -18,19 +19,17 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
1819

1920
WORKDIR /build/
2021

21-
COPY scripts/musl.sh /build/
22+
COPY scripts/musl-toolchain.sh /build/
2223
# We need to mitigate rust-lang/rust#34978 when compiling musl itself as well
23-
RUN CC=gcc \
24-
CFLAGS="-Wa,-mrelax-relocations=no" \
25-
CXX=g++ \
24+
RUN CFLAGS="-Wa,-mrelax-relocations=no" \
2625
CXXFLAGS="-Wa,-mrelax-relocations=no" \
27-
bash musl.sh x86_64 && rm -rf /build
26+
bash musl-toolchain.sh x86_64 && rm -rf build
2827

2928
COPY scripts/sccache.sh /scripts/
3029
RUN sh /scripts/sccache.sh
3130

3231
ENV RUST_CONFIGURE_ARGS \
33-
--musl-root-x86_64=/musl-x86_64 \
32+
--musl-root-x86_64=/usr/local/x86_64-linux-musl \
3433
--enable-extended \
3534
--disable-docs
3635

@@ -41,6 +40,12 @@ ENV RUST_CONFIGURE_ARGS \
4140
# See: https://github.com/rust-lang/rust/issues/34978
4241
ENV CFLAGS_x86_64_unknown_linux_musl=-Wa,-mrelax-relocations=no
4342

44-
ENV SCRIPT \
45-
python2.7 ../x.py test --target x86_64-unknown-linux-musl && \
46-
python2.7 ../x.py dist --target x86_64-unknown-linux-musl
43+
ENV HOSTS=x86_64-unknown-linux-musl \
44+
CC_x86_64_unknown_linux_musl=x86_64-linux-musl-gcc \
45+
CXX_x86_64_unknown_linux_musl=x86_64-linux-musl-g++
46+
47+
# Musl defaults to static libs but we need them to be dynamic for host toolchain.
48+
# The toolchain will produce static libs by default.
49+
ENV RUSTFLAGS="-C target-feature=-crt-static"
50+
51+
ENV SCRIPT python2.7 ../x.py dist --host $HOSTS --target $HOSTS

0 commit comments

Comments
 (0)