Skip to content

Commit c791d1c

Browse files
committed
---
yaml --- r: 273611 b: refs/heads/beta c: 4124466 h: refs/heads/master i: 273609: ca375ab 273607: 1e8c82e
1 parent d501ae3 commit c791d1c

File tree

720 files changed

+18336
-27699
lines changed

Some content is hidden

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

720 files changed

+18336
-27699
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ refs/tags/0.9: 36870b185fc5f5486636d4515f0e22677493f225
2323
refs/tags/0.10: ac33f2b15782272ae348dbd7b14b8257b2148b5a
2424
refs/tags/0.11.0: e1247cb1d0d681be034adb4b558b5a0c0d5720f9
2525
refs/tags/0.12.0: f0c419429ef30723ceaf6b42f9b5a2aeb5d2e2d1
26-
refs/heads/beta: 128b2ad8298f33984c64b98cfb354bb932b740ef
26+
refs/heads/beta: 41244661979cda16bf2b15bd802337a0ee9764dd
2727
refs/tags/1.0.0-alpha: e42bd6d93a1d3433c486200587f8f9e12590a4d7
2828
refs/heads/tmp: e06d2ad9fcd5027bcaac5b08fc9aa39a49d0ecd3
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f

branches/beta/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ build.
7777
7878
Download [MinGW from
7979
here](http://mingw-w64.org/doku.php/download/mingw-builds), and choose the
80-
`version=4.9.x,threads=win32,exceptions=dwarf/seh` flavor when installing. Also, make sure to install to a path without spaces in it. After installing,
80+
`threads=win32,exceptions=dwarf/seh` flavor when installing. Also, make sure to install to a path without spaces in it. After installing,
8181
add its `bin` directory to your `PATH`. This is due to [#28260](https://github.com/rust-lang/rust/issues/28260), in the future,
8282
installing from pacman should be just fine.
8383

branches/beta/RELEASES.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,8 @@ Compatibility Notes
116116
that were not intended. In this release, [defaulted type parameters
117117
appearing outside of type definitions will generate a
118118
warning][1.7d], which will become an error in future releases.
119-
* [Parsing "." as a float results in an error instead of 0][1.7p].
120-
That is, `".".parse::<f32>()` returns `Err`, not `Ok(0.0)`.
119+
* [Parsing "." as a float results in an error instead of
120+
0][1.7p]. That is, `".".parse::<f32>()` returns `Err`, not `Ok(0)`.
121121
* [Borrows of closure parameters may not outlive the closure][1.7bc].
122122

123123
[1.7a]: https://github.com/rust-lang/rust/pull/30928

branches/beta/configure

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -607,7 +607,6 @@ opt dist-host-only 0 "only install bins for the host architecture"
607607
opt inject-std-version 1 "inject the current compiler version of libstd into programs"
608608
opt llvm-version-check 1 "check if the LLVM version is supported, build anyway"
609609
opt rustbuild 0 "use the rust and cargo based build system"
610-
opt orbit 0 "get MIR where it belongs - everywhere; most importantly, in orbit"
611610

612611
# Optimization and debugging options. These may be overridden by the release channel, etc.
613612
opt_nosave optimize 1 "build optimized rust code"
@@ -714,8 +713,6 @@ if [ -n "$CFG_ENABLE_DEBUG_ASSERTIONS" ]; then putvar CFG_ENABLE_DEBUG_ASSERTION
714713
if [ -n "$CFG_ENABLE_DEBUGINFO" ]; then putvar CFG_ENABLE_DEBUGINFO; fi
715714
if [ -n "$CFG_ENABLE_DEBUG_JEMALLOC" ]; then putvar CFG_ENABLE_DEBUG_JEMALLOC; fi
716715

717-
if [ -n "$CFG_ENABLE_ORBIT" ]; then putvar CFG_ENABLE_ORBIT; fi
718-
719716
# A magic value that allows the compiler to use unstable features
720717
# during the bootstrap even when doing so would normally be an error
721718
# because of feature staging or because the build turns on
@@ -1034,7 +1031,7 @@ then
10341031
if [ -n "$CFG_OSX_CLANG_VERSION" ]
10351032
then
10361033
case $CFG_OSX_CLANG_VERSION in
1037-
(7.0* | 7.1* | 7.2* | 7.3*)
1034+
(7.0* | 7.1* | 7.2*)
10381035
step_msg "found ok version of APPLE CLANG: $CFG_OSX_CLANG_VERSION"
10391036
;;
10401037
(*)

branches/beta/mk/cfg/i586-unknown-linux-gnu.mk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ CFG_LIB_NAME_i586-unknown-linux-gnu=lib$(1).so
77
CFG_STATIC_LIB_NAME_i586-unknown-linux-gnu=lib$(1).a
88
CFG_LIB_GLOB_i586-unknown-linux-gnu=lib$(1)-*.so
99
CFG_LIB_DSYM_GLOB_i586-unknown-linux-gnu=lib$(1)-*.dylib.dSYM
10-
CFG_JEMALLOC_CFLAGS_i586-unknown-linux-gnu := -m32 $(CFLAGS) -march=pentium
11-
CFG_GCCISH_CFLAGS_i586-unknown-linux-gnu := -Wall -Werror -g -fPIC -m32 $(CFLAGS) -march=pentium
12-
CFG_GCCISH_CXXFLAGS_i586-unknown-linux-gnu := -fno-rtti $(CXXFLAGS) -march=pentium
10+
CFG_JEMALLOC_CFLAGS_i586-unknown-linux-gnu := -m32 $(CFLAGS)
11+
CFG_GCCISH_CFLAGS_i586-unknown-linux-gnu := -Wall -Werror -g -fPIC -m32 $(CFLAGS)
12+
CFG_GCCISH_CXXFLAGS_i586-unknown-linux-gnu := -fno-rtti $(CXXFLAGS)
1313
CFG_GCCISH_LINK_FLAGS_i586-unknown-linux-gnu := -shared -fPIC -ldl -pthread -lrt -g -m32
1414
CFG_GCCISH_DEF_FLAG_i586-unknown-linux-gnu := -Wl,--export-dynamic,--dynamic-list=
1515
CFG_LLC_FLAGS_i586-unknown-linux-gnu :=

branches/beta/mk/crates.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ DEPS_rustc := syntax fmt_macros flate arena serialize getopts rbml rustc_front\
9797
log graphviz rustc_llvm rustc_back rustc_data_structures\
9898
rustc_const_eval
9999
DEPS_rustc_back := std syntax rustc_llvm rustc_front flate log libc
100-
DEPS_rustc_borrowck := rustc rustc_front rustc_mir log graphviz syntax
100+
DEPS_rustc_borrowck := rustc rustc_front log graphviz syntax
101101
DEPS_rustc_data_structures := std log serialize
102102
DEPS_rustc_driver := arena flate getopts graphviz libc rustc rustc_back rustc_borrowck \
103103
rustc_typeck rustc_mir rustc_resolve log syntax serialize rustc_llvm \

branches/beta/mk/main.mk

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -134,11 +134,6 @@ ifdef CFG_ENABLE_DEBUGINFO
134134
CFG_RUSTC_FLAGS += -g
135135
endif
136136

137-
ifdef CFG_ENABLE_ORBIT
138-
$(info cfg: launching MIR (CFG_ENABLE_ORBIT))
139-
CFG_RUSTC_FLAGS += -Z orbit
140-
endif
141-
142137
ifdef SAVE_TEMPS
143138
CFG_RUSTC_FLAGS += --save-temps
144139
endif

branches/beta/mk/tests.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ $(3)/stage$(1)/test/$(4)test-$(2)$$(X_$(2)): \
383383
@$$(call E, rustc: $$@)
384384
$(Q)CFG_LLVM_LINKAGE_FILE=$$(LLVM_LINKAGE_PATH_$(2)) \
385385
$$(subst @,,$$(STAGE$(1)_T_$(2)_H_$(3))) -o $$@ $$< --test \
386-
-Cmetadata="test-crate" -L "$$(RT_OUTPUT_DIR_$(2))" \
386+
-L "$$(RT_OUTPUT_DIR_$(2))" \
387387
$$(LLVM_LIBDIR_RUSTFLAGS_$(2)) \
388388
$$(RUSTFLAGS_$(4))
389389

branches/beta/src/bootstrap/build/channel.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,23 +36,19 @@ pub fn collect(build: &mut Build) {
3636
match &build.config.channel[..] {
3737
"stable" => {
3838
build.release = release_num.to_string();
39-
build.package_vers = build.release.clone();
4039
build.unstable_features = false;
4140
}
4241
"beta" => {
4342
build.release = format!("{}-beta{}", release_num,
4443
prerelease_version);
45-
build.package_vers = "beta".to_string();
4644
build.unstable_features = false;
4745
}
4846
"nightly" => {
4947
build.release = format!("{}-nightly", release_num);
50-
build.package_vers = "nightly".to_string();
5148
build.unstable_features = true;
5249
}
5350
_ => {
5451
build.release = format!("{}-dev", release_num);
55-
build.package_vers = build.release.clone();
5652
build.unstable_features = true;
5753
}
5854
}

branches/beta/src/bootstrap/build/check.rs

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,14 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
use std::process::Command;
12+
1113
use build::{Build, Compiler};
1214

1315
pub fn linkcheck(build: &Build, stage: u32, host: &str) {
1416
println!("Linkcheck stage{} ({})", stage, host);
1517
let compiler = Compiler::new(stage, host);
16-
build.run(build.tool_cmd(&compiler, "linkchecker")
17-
.arg(build.out.join(host).join("doc")));
18-
}
19-
20-
pub fn cargotest(build: &Build, stage: u32, host: &str) {
21-
let ref compiler = Compiler::new(stage, host);
22-
build.run(build.tool_cmd(compiler, "cargotest")
23-
.env("RUSTC", build.compiler_path(compiler))
24-
.env("RUSTDOC", build.rustdoc(compiler))
25-
.arg(&build.cargo));
18+
let linkchecker = build.tool(&compiler, "linkchecker");
19+
build.run(Command::new(&linkchecker)
20+
.arg(build.out.join(host).join("doc")));
2621
}

branches/beta/src/bootstrap/build/compile.rs

Lines changed: 34 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,26 @@ use build::{Build, Compiler, Mode};
2323
/// This will build the standard library for a particular stage of the build
2424
/// using the `compiler` targeting the `target` architecture. The artifacts
2525
/// created will also be linked into the sysroot directory.
26-
pub fn std<'a>(build: &'a Build, target: &str, compiler: &Compiler<'a>) {
27-
println!("Building stage{} std artifacts ({} -> {})", compiler.stage,
28-
compiler.host, target);
26+
pub fn std<'a>(build: &'a Build, stage: u32, target: &str,
27+
compiler: &Compiler<'a>) {
28+
let host = compiler.host;
29+
println!("Building stage{} std artifacts ({} -> {})", stage,
30+
host, target);
2931

3032
// Move compiler-rt into place as it'll be required by the compiler when
3133
// building the standard library to link the dylib of libstd
32-
let libdir = build.sysroot_libdir(compiler, target);
34+
let libdir = build.sysroot_libdir(stage, &host, target);
3335
let _ = fs::remove_dir_all(&libdir);
3436
t!(fs::create_dir_all(&libdir));
3537
t!(fs::hard_link(&build.compiler_rt_built.borrow()[target],
3638
libdir.join(staticlib("compiler-rt", target))));
3739

3840
build_startup_objects(build, target, &libdir);
3941

40-
let out_dir = build.cargo_out(compiler, Mode::Libstd, target);
42+
let out_dir = build.cargo_out(stage, &host, Mode::Libstd, target);
4143
build.clear_if_dirty(&out_dir, &build.compiler_path(compiler));
42-
let mut cargo = build.cargo(compiler, Mode::Libstd, target, "build");
44+
let mut cargo = build.cargo(stage, compiler, Mode::Libstd, Some(target),
45+
"build");
4346
cargo.arg("--features").arg(build.std_features())
4447
.arg("--manifest-path")
4548
.arg(build.src.join("src/rustc/std_shim/Cargo.toml"));
@@ -56,20 +59,20 @@ pub fn std<'a>(build: &'a Build, target: &str, compiler: &Compiler<'a>) {
5659
}
5760

5861
build.run(&mut cargo);
59-
std_link(build, target, compiler, compiler.host);
62+
std_link(build, stage, target, compiler, host);
6063
}
6164

6265
/// Link all libstd rlibs/dylibs into the sysroot location.
6366
///
6467
/// Links those artifacts generated in the given `stage` for `target` produced
6568
/// by `compiler` into `host`'s sysroot.
6669
pub fn std_link(build: &Build,
70+
stage: u32,
6771
target: &str,
6872
compiler: &Compiler,
6973
host: &str) {
70-
let target_compiler = Compiler::new(compiler.stage, host);
71-
let libdir = build.sysroot_libdir(&target_compiler, target);
72-
let out_dir = build.cargo_out(compiler, Mode::Libstd, target);
74+
let libdir = build.sysroot_libdir(stage, host, target);
75+
let out_dir = build.cargo_out(stage, compiler.host, Mode::Libstd, target);
7376

7477
// If we're linking one compiler host's output into another, then we weren't
7578
// called from the `std` method above. In that case we clean out what's
@@ -82,8 +85,7 @@ pub fn std_link(build: &Build,
8285
}
8386
add_to_sysroot(&out_dir, &libdir);
8487

85-
if target.contains("musl") &&
86-
(target.contains("x86_64") || target.contains("i686")) {
88+
if target.contains("musl") && (target.contains("x86_64") || target.contains("i686")) {
8789
copy_third_party_objects(build, target, &libdir);
8890
}
8991
}
@@ -128,14 +130,17 @@ fn build_startup_objects(build: &Build, target: &str, into: &Path) {
128130
/// This will build the compiler for a particular stage of the build using
129131
/// the `compiler` targeting the `target` architecture. The artifacts
130132
/// created will also be linked into the sysroot directory.
131-
pub fn rustc<'a>(build: &'a Build, target: &str, compiler: &Compiler<'a>) {
132-
println!("Building stage{} compiler artifacts ({} -> {})",
133-
compiler.stage, compiler.host, target);
133+
pub fn rustc<'a>(build: &'a Build, stage: u32, target: &str,
134+
compiler: &Compiler<'a>) {
135+
let host = compiler.host;
136+
println!("Building stage{} compiler artifacts ({} -> {})", stage,
137+
host, target);
134138

135-
let out_dir = build.cargo_out(compiler, Mode::Librustc, target);
136-
build.clear_if_dirty(&out_dir, &libstd_shim(build, compiler, target));
139+
let out_dir = build.cargo_out(stage, &host, Mode::Librustc, target);
140+
build.clear_if_dirty(&out_dir, &libstd_shim(build, stage, &host, target));
137141

138-
let mut cargo = build.cargo(compiler, Mode::Librustc, target, "build");
142+
let mut cargo = build.cargo(stage, compiler, Mode::Librustc, Some(target),
143+
"build");
139144
cargo.arg("--features").arg(build.rustc_features())
140145
.arg("--manifest-path")
141146
.arg(build.src.join("src/rustc/Cargo.toml"));
@@ -179,27 +184,27 @@ pub fn rustc<'a>(build: &'a Build, target: &str, compiler: &Compiler<'a>) {
179184
}
180185
build.run(&mut cargo);
181186

182-
rustc_link(build, target, compiler, compiler.host);
187+
rustc_link(build, stage, target, compiler, compiler.host);
183188
}
184189

185190
/// Link all librustc rlibs/dylibs into the sysroot location.
186191
///
187192
/// Links those artifacts generated in the given `stage` for `target` produced
188193
/// by `compiler` into `host`'s sysroot.
189194
pub fn rustc_link(build: &Build,
195+
stage: u32,
190196
target: &str,
191197
compiler: &Compiler,
192198
host: &str) {
193-
let target_compiler = Compiler::new(compiler.stage, host);
194-
let libdir = build.sysroot_libdir(&target_compiler, target);
195-
let out_dir = build.cargo_out(compiler, Mode::Librustc, target);
199+
let libdir = build.sysroot_libdir(stage, host, target);
200+
let out_dir = build.cargo_out(stage, compiler.host, Mode::Librustc, target);
196201
add_to_sysroot(&out_dir, &libdir);
197202
}
198203

199204
/// Cargo's output path for the standard library in a given stage, compiled
200205
/// by a particular compiler for the specified target.
201-
fn libstd_shim(build: &Build, compiler: &Compiler, target: &str) -> PathBuf {
202-
build.cargo_out(compiler, Mode::Libstd, target).join("libstd_shim.rlib")
206+
fn libstd_shim(build: &Build, stage: u32, host: &str, target: &str) -> PathBuf {
207+
build.cargo_out(stage, host, Mode::Libstd, target).join("libstd_shim.rlib")
203208
}
204209

205210
fn compiler_file(compiler: &Path, file: &str) -> String {
@@ -214,29 +219,25 @@ fn compiler_file(compiler: &Path, file: &str) -> String {
214219
/// compiler.
215220
pub fn assemble_rustc(build: &Build, stage: u32, host: &str) {
216221
assert!(stage > 0, "the stage0 compiler isn't assembled, it's downloaded");
217-
// The compiler that we're assembling
218-
let target_compiler = Compiler::new(stage, host);
219-
220-
// The compiler that compiled the compiler we're assembling
221-
let build_compiler = Compiler::new(stage - 1, &build.config.build);
222222

223223
// Clear out old files
224-
let sysroot = build.sysroot(&target_compiler);
224+
let sysroot = build.sysroot(stage, host);
225225
let _ = fs::remove_dir_all(&sysroot);
226226
t!(fs::create_dir_all(&sysroot));
227227

228228
// Link in all dylibs to the libdir
229229
let sysroot_libdir = sysroot.join(libdir(host));
230230
t!(fs::create_dir_all(&sysroot_libdir));
231-
let src_libdir = build.sysroot_libdir(&build_compiler, host);
231+
let src_libdir = build.sysroot_libdir(stage - 1, &build.config.build, host);
232232
for f in t!(fs::read_dir(&src_libdir)).map(|f| t!(f)) {
233233
let filename = f.file_name().into_string().unwrap();
234234
if is_dylib(&filename) {
235235
t!(fs::hard_link(&f.path(), sysroot_libdir.join(&filename)));
236236
}
237237
}
238238

239-
let out_dir = build.cargo_out(&build_compiler, Mode::Librustc, host);
239+
let out_dir = build.cargo_out(stage - 1, &build.config.build,
240+
Mode::Librustc, host);
240241

241242
// Link the compiler binary itself into place
242243
let rustc = out_dir.join(exe("rustc", host));
@@ -314,7 +315,7 @@ pub fn tool(build: &Build, stage: u32, host: &str, tool: &str) {
314315
// let out_dir = build.cargo_out(stage, &host, Mode::Librustc, target);
315316
// build.clear_if_dirty(&out_dir, &libstd_shim(build, stage, &host, target));
316317

317-
let mut cargo = build.cargo(&compiler, Mode::Tool, host, "build");
318+
let mut cargo = build.cargo(stage, &compiler, Mode::Tool, None, "build");
318319
cargo.arg("--manifest-path")
319320
.arg(build.src.join(format!("src/tools/{}/Cargo.toml", tool)));
320321
build.run(&mut cargo);

0 commit comments

Comments
 (0)