about summary refs log tree commit diff
path: root/src/bootstrap
AgeCommit message (Collapse)AuthorLines
2019-01-12Rollup merge of #57368 - petrhosek:cmake-compiler-launcher, r=alexcrichtonMazdak Farrokhzad-8/+6
Use CMAKE_{C,CXX}_COMPILER_LAUNCHER for ccache CMake 3.4 and newer which is the required minimum version for LLVM supports CMAKE_{C,CXX}_COMPILER_LAUNCHER for settting the compiler launcher such as ccache which doesn't require shifting arguments.
2019-01-10Integrate miri into build-manifestAlex Crichton-1/+1
This fixes a mistake where miri was accidentally left out of the build-manifest parsing, meaning that today's nightly generated a manifest with invalid urls!
2019-01-09Auto merge of #57086 - oli-obk:miri_dist, r=kennytmbors-0/+152
Prepare everything for distributing miri via rustup The next step is to tell rustup about `cargo-miri` in https://github.com/rust-lang/rustup.rs/blob/31935e5f633a5acd3a203d23b61d1556c64a821c/src/rustup/lib.rs#L28 and https://github.com/rust-lang/rustup.rs/blob/1ccd706d1d572c777c5134bd7db7aa1a8df7f278/src/rustup-win-installer/src/lib.rs#L29
2019-01-08fixupOliver Scherer-2/+46
2019-01-08Prepare everything for distributing miri via rustupOliver Scherer-0/+108
2019-01-07Build LLVM with -static-libstdc++ on dist buildsAlex Crichton-8/+8
This commit is intended on fixing a regression from #57286 where the distributed LLVM shared library unfortunately depends on a dynamic copy of libstdc++, meaning we're no longer as binary compatible as we thought! This tweaks the build of LLVM as out distribution is slightly different now, and is hoped to fix the issue. Closes #57426
2019-01-07Rollup merge of #57369 - petrhosek:llvm-libcxx, r=alexcrichtonPietro Albini-0/+8
Provide the option to use libc++ even on all platforms This is the default on platforms which use libc++ as the default C++ library but this option allows using libc++ on others as well.
2019-01-05Provide the option to use libc++ even on all platformsPetr Hosek-0/+8
This is the default on platforms which use libc++ as the default C++ library but this option allows using libc++ on others as well.
2019-01-05Use CMAKE_{C,CXX}_COMPILER_LAUNCHER for ccachePetr Hosek-8/+6
CMake 3.4 and newer which is the required minimum version for LLVM supports CMAKE_{C,CXX}_COMPILER_LAUNCHER for settting the compiler launcher such as ccache which doesn't require shifting arguments.
2019-01-02Don't package up libLLVM.so with libstdAlex Crichton-4/+12
It's only meant for rustc, so we should only install it once!
2019-01-02bootstrap: Link LLVM as a dylib with ThinLTOAlex Crichton-51/+13
When building a distributed compiler on Linux where we use ThinLTO to create the LLVM shared object this commit switches the compiler to dynamically linking that LLVM artifact instead of statically linking to LLVM. The primary goal here is to reduce CI compile times, avoiding two+ ThinLTO builds of all of LLVM. By linking dynamically to LLVM we'll reuse the one ThinLTO step done by LLVM's build itself. Lots of discussion about this change can be found [here] and down. A perf run will show whether this is worth it or not! [here]: https://github.com/rust-lang/rust/pull/53245#issuecomment-417015334
2018-12-28Update cargo, rls, miriEric Huss-8/+1
2018-12-25Remove licensesMark Rousskov-299/+0
2018-12-25Revert "Rollup merge of #56944 - alexcrichton:less-thin2, r=michaelwoerister"kennytm-13/+51
This reverts commit f1051b574c26e20608ff26415a3dddd13f140925, reversing changes made to 833e0b3b8a9f1487a61152ca76f7f74a6b32cc0c.
2018-12-24Auto merge of #56836 - alexcrichton:std-backtrace-sys, r=Mark-Simulacrumbors-1/+0
std: Use backtrace-sys from crates.io This commit switches the standard library to using the `backtrace-sys` crate from crates.io instead of duplicating the logic here in the Rust repositor with the `backtrace-sys`'s crate's logic. Eventually this will hopefully be a good step towards using the `backtrace` crate directly from crates.io itself, but we're not quite there yet! Hopefully this is a small incremental first step we can take.
2018-12-24x.py: fixup 6130fc884bc1dff9bb835894a7bb2042c110b011Matthias Krüger-1/+1
./x.py used to automatically check out the right commit when a submodule was outdated and ./x.py build was run and submodules handling was enabled in config.toml (submodules = true). But it threw an error: [...] failed to run: git submodule -q sync --progress src/tools/clippy The commit removes the --progress from git submodule call. Fixes #57080
2018-12-24std: Use backtrace-sys from crates.ioAlex Crichton-1/+0
This commit switches the standard library to using the `backtrace-sys` crate from crates.io instead of duplicating the logic here in the Rust repositor with the `backtrace-sys`'s crate's logic. Eventually this will hopefully be a good step towards using the `backtrace` crate directly from crates.io itself, but we're not quite there yet! Hopefully this is a small incremental first step we can take.
2018-12-24Rollup merge of #56944 - alexcrichton:less-thin2, r=michaelwoeristerMazdak Farrokhzad-51/+13
bootstrap: Link LLVM as a dylib with ThinLTO When building a distributed compiler on Linux where we use ThinLTO to create the LLVM shared object this commit switches the compiler to dynamically linking that LLVM artifact instead of statically linking to LLVM. The primary goal here is to reduce CI compile times, avoiding two+ ThinLTO builds of all of LLVM. By linking dynamically to LLVM we'll reuse the one ThinLTO step done by LLVM's build itself. Lots of discussion about this change can be found [here] and down. A perf run will show whether this is worth it or not! [here]: https://github.com/rust-lang/rust/pull/53245#issuecomment-417015334
2018-12-23Rollup merge of #56933 - clarcharr:xpy_progress, r=Mark-Simulacrumkennytm-2/+2
Add --progress to git submodule commands in x.py This is a relatively new flag, but it means that git will indicate the progress of the update as it would with regular clones. This is especially helpful as some of the submodules are really big and it's difficult to tell if it's hanging or still updating.
2018-12-19Rollup merge of #56947 - hsivonen:neon, r=alexcrichtonPietro Albini-1/+6
Add targets thumbv7neon-linux-androideabi and thumbv7neon-unknown-linux-gnueabihf These two targets enable both thumb-mode and NEON for ARMv7 CPUs. This another attempt at #49902, which cannot be reopened. Between that PR and this one, some subrepos with C code whose build systems were failing went away.
2018-12-17bootstrap: Link LLVM as a dylib with ThinLTOAlex Crichton-51/+13
When building a distributed compiler on Linux where we use ThinLTO to create the LLVM shared object this commit switches the compiler to dynamically linking that LLVM artifact instead of statically linking to LLVM. The primary goal here is to reduce CI compile times, avoiding two+ ThinLTO builds of all of LLVM. By linking dynamically to LLVM we'll reuse the one ThinLTO step done by LLVM's build itself. Lots of discussion about this change can be found [here] and down. A perf run will show whether this is worth it or not! [here]: https://github.com/rust-lang/rust/pull/53245#issuecomment-417015334
2018-12-17Add --progress to git submodule commandsClar Fon-2/+2
2018-12-17Auto merge of #56642 - nikic:llvm-6, r=alexcrichtonbors-2/+2
Bump minimum required LLVM version to 6.0 Based on the discussion in #55842, while the overall position of Rust wrt LLVM continues to be contentious, there does seem to be a consensus that there is no need for continued support of LLVM 5. This PR bumps our version requirement to LLVM 6.0 and makes Travis run against that. I hope that this is going to unblock #52694. If I understand correctly, while this issue still exists in LLVM 6, Ubuntu has backported the relevant patch. r? @alexcrichton
2018-12-15Auto merge of #56600 - ljedrz:fix_edition, r=Mark-Simulacrumbors-97/+99
bootstrap: fix edition A byproduct of work on https://github.com/rust-lang/rust/pull/56595; done with `cargo fix --edition`.
2018-12-15Rollup merge of #56792 - phansch:add_compiletest_testsuite, r=alexcrichtonPietro Albini-0/+40
Bootstrap: Add testsuite for compiletest tool This adds a test suite for compiletest so that the tester is tested, too. The (currently) single unit test of the compiletest tool was never executed on CI. At least I couldn't find any references of it in the logs. The compiletest tests can then also be executed with: ./x.py test src/tools/compiletest --stage 0 cc #47606
2018-12-14Bootstrap: Add testsuite for compiletest toolPhilipp Hansch-0/+40
The (currently) single unit test of the compiletest tool was never executed on CI. At least I couldn't find any references of it in the logs. This adds a test suite for compiletest so that our tester is tested, too. The compiletest tests can then also be executed with: ./x.py test src/tools/compiletest
2018-12-14std: Activate compiler_builtins `mem` feature for no_std targetsAlex Crichton-1/+3
This was an accidental regression from #56092, but for `no_std` targets being built and distributed we want to be sure to activate the compiler-builtins `mem` feature which demangles important memory-related intrinsics.
2018-12-14Auto merge of #56536 - alexcrichton:update-master, r=Mark-Simulacrumbors-1/+1
Bump to 1.33.0 * Update bootstrap compiler * Update version to 1.33.0 * Remove some `#[cfg(stage0)]` annotations
2018-12-13Add targets thumbv7neon-linux-androideabi and ↵Henri Sivonen-1/+6
thumbv7neon-unknown-linux-gnueabihf These two targets enable both thumb-mode and NEON for ARMv7 CPUs.
2018-12-13Auto merge of #56090 - nnethercote:filesearch, r=eddybbors-0/+5
Overhaul `FileSearch` and `SearchPaths` `FileSearch::search()` traverses one or more directories. For each directory it generates a `Vec<PathBuf>` containing one element per file in that directory. In some benchmarks this occurs enough that the allocations done for the `PathBuf`s are significant, and in practice a small number of directories are being traversed over and over again. For example, when compiling the `tokio-webpush-simple` benchmark, two directories are traversed 58 times each. Each of these directories have more than 100 files. We can do all the necessary traversals up front, when `Session` is created, and get the `Vec<PathBuf>`s then. This reduces instruction counts on several benchmarks by 1--5%. r? @alexcrichton CC @eddyb, @michaelwoerister, @nikomatsakis
2018-12-12Bump to 1.33.0Alex Crichton-1/+1
* Update bootstrap compiler * Update version to 1.33.0 * Remove some `#[cfg(stage0)]` annotations Actually updating the version number is blocked on updating Cargo
2018-12-12Remove some env vars for rustdoc invocations.Nicholas Nethercote-0/+5
In an attempt to avoid "thread '<unnamed>' panicked at 'failed to acquire jobserver token: Bad file descriptor" errors.
2018-12-11std: Depend directly on crates.io cratesAlex Crichton-23/+10
Ever since we added a Cargo-based build system for the compiler the standard library has always been a little special, it's never been able to depend on crates.io crates for runtime dependencies. This has been a result of various limitations, namely that Cargo doesn't understand that crates from crates.io depend on libcore, so Cargo tries to build crates before libcore is finished. I had an idea this afternoon, however, which lifts the strategy from #52919 to directly depend on crates.io crates from the standard library. After all is said and done this removes a whopping three submodules that we need to manage! The basic idea here is that for any crate `std` depends on it adds an *optional* dependency on an empty crate on crates.io, in this case named `rustc-std-workspace-core`. This crate is overridden via `[patch]` in this repository to point to a local crate we write, and *that* has a `path` dependency on libcore. Note that all `no_std` crates also depend on `compiler_builtins`, but if we're not using submodules we can publish `compiler_builtins` to crates.io and all crates can depend on it anyway! The basic strategy then looks like: * The standard library (or some transitive dep) decides to depend on a crate `foo`. * The standard library adds ```toml [dependencies] foo = { version = "0.1", features = ['rustc-dep-of-std'] } ``` * The crate `foo` has an optional dependency on `rustc-std-workspace-core` * The crate `foo` has an optional dependency on `compiler_builtins` * The crate `foo` has a feature `rustc-dep-of-std` which activates these crates and any other necessary infrastructure in the crate. A sample commit for `dlmalloc` [turns out to be quite simple][commit]. After that all `no_std` crates should largely build "as is" and still be publishable on crates.io! Notably they should be able to continue to use stable Rust if necessary, since the `rename-dependency` feature of Cargo is soon stabilizing. As a proof of concept, this commit removes the `dlmalloc`, `libcompiler_builtins`, and `libc` submodules from this repository. Long thorns in our side these are now gone for good and we can directly depend on crates.io! It's hoped that in the long term we can bring in other crates as necessary, but for now this is largely intended to simply make it easier to manage these crates and remove submodules. This should be a transparent non-breaking change for all users, but one possible stickler is that this almost for sure breaks out-of-tree `std`-building tools like `xargo` and `cargo-xbuild`. I think it should be relatively easy to get them working, however, as all that's needed is an entry in the `[patch]` section used to build the standard library. Hopefully we can work with these tools to solve this problem! [commit]: https://github.com/alexcrichton/dlmalloc-rs/commit/28ee12db813a3b650a7c25d1c36d2c17dcb88ae3
2018-12-10bootstrap: fix editionljedrz-97/+99
2018-12-09Remove compile-fail-fulldeps test suiteVadim Petrochenkov-7/+0
2018-12-09Bump minimum required LLVM version to 6.0Nikita Popov-2/+2
2018-12-08Auto merge of #56578 - alexreg:cosmetic-1, r=alexregbors-16/+16
Various minor/cosmetic improvements to code r? @Centril 😄
2018-12-07Various minor/cosmetic improvements to codeAlexander Regueiro-16/+16
2018-12-07use top level `fs` functions where appropriateAndy Russell-52/+33
This commit replaces many usages of `File::open` and reading or writing with `fs::read_to_string`, `fs::read` and `fs::write`. This reduces code complexity, and will improve performance for most reads, since the functions allocate the buffer to be the size of the file. I believe that this commit will not impact behavior in any way, so some matches will check the error kind in case the file was not valid UTF-8. Some of these cases may not actually care about the error.
2018-12-07Add x86_64-fortanix-unknown-sgx target to libstd and dependenciesJethro Beekman-0/+1
The files src/libstd/sys/sgx/*.rs are mostly copied/adapted from the wasm target. This also updates the dlmalloc submodule to the very latest version.
2018-12-06Rollup merge of #56441 - ollie27:rustbuild_compiler_docs, r=alexcrichtonPietro Albini-6/+11
rustbuild: Fix issues with compiler docs * Create output directories for crates beforehand so rustdoc uses relative links (fixes #56107) * Readd rustc_codegen_ssa (fixes #56196) * Don't build out of tree dependencies for rustdoc like we don't for rustc
2018-12-04build the edition guideSteve Klabnik-1/+2
and update it so that links are correct
2018-12-03Rollup merge of #56419 - mark-i-m:remove-try, r=Centrilkennytm-6/+6
Remove some uses of try!
2018-12-02rustbuild: Fix issues with compiler docsOliver Middleton-6/+11
* Create output directories for crates beforehand so rustdoc uses relative links * Readd rustc_codegen_ssa * Don't build out of tree dependencies for rustdoc like we don't for rustc
2018-12-01remove some uses of try!Mark Mansi-6/+6
2018-11-30ci: Only run compare-mode tests on one builderAlex Crichton-1/+10
The run-pass test suite currently takes 30 minutes on Windows, and that appears to be roughly split between two 15 minute runs of the test suite: one without NLL and one with NLL. In discussion on Discord the platform coverage of the NLL compare mode may not necessarily be worth it, so this commit removes the NLL compare mode from tests by default, and then reenables it on only one builder.
2018-11-30Add the edition guide to doc.rust-lang.orgSteve Klabnik-0/+1
2018-11-30bootstrap: provide host `rust_test_helpers` to compiletest, not just target.Eduard-Mihai Burtescu-1/+7
2018-11-30bootstrap: don't use libraries from MUSL_ROOT on non-musl targets.Eduard-Mihai Burtescu-4/+6
2018-11-30bootstrap: ensure that `libproc_macro` is available on the host for tests ↵Eduard-Mihai Burtescu-0/+3
even when cross-compiling.