Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 7 pull requests #66990

Closed
wants to merge 15 commits into from
Closed

Conversation

Centril
Copy link
Contributor

@Centril Centril commented Dec 3, 2019

Successful merges:

Failed merges:

r? @ghost

Centril and others added 15 commits November 30, 2019 14:55
LLVM 7 is over a year old, which should be plenty for compatibility. The
last LLVM 6 holdout was llvm-emscripten, which went away in rust-lang#65501.

I've also included a fix for LLVM 8 lacking `MemorySanitizerOptions`,
which was broken by rust-lang#66522.
For SGX, the relocation using the relocation table is done by
the code in rust/src/libstd/sys/sgx/abi/reloc.rs and this code
should not require relocation. Setting RelaxELFRelocations flag
if allows this to happen, hence adding a Target Option for it.
This commit updates the `wasi` crate used by the standard library which
is used to implement most of the functionality of libstd on the
`wasm32-wasi` target. This update comes with a brand new crate structure
in the `wasi` crate which caused quite a few changes for the wasi target
here, but it also comes with a significant change to where the
functionality is coming from.

The WASI specification is organized into "snapshots" and a new snapshot
happened recently, so the WASI APIs themselves have changed since the
previous revision. This had only minor impact on the public facing
surface area of libstd, only changing on `u32` to a `u64` in an unstable
API. The actual source for all of these types and such, however, is now
coming from the `wasi_preview_snapshot1` module instead of the
`wasi_unstable` module like before. This means that any implementors
generating binaries will need to ensure that their embedding environment
handles the `wasi_preview_snapshot1` module.
Update the `wasi` crate for `wasm32-wasi`

This commit updates the `wasi` crate used by the standard library which
is used to implement most of the functionality of libstd on the
`wasm32-wasi` target. This update comes with a brand new crate structure
in the `wasi` crate which caused quite a few changes for the wasi target
here, but it also comes with a significant change to where the
functionality is coming from.

The WASI specification is organized into "snapshots" and a new snapshot
happened recently, so the WASI APIs themselves have changed since the
previous revision. This had only minor impact on the public facing
surface area of libstd, only changing on `u32` to a `u64` in an unstable
API. The actual source for all of these types and such, however, is now
coming from the `wasi_preview_snapshot1` module instead of the
`wasi_unstable` module like before. This means that any implementors
generating binaries will need to ensure that their embedding environment
handles the `wasi_preview_snapshot1` module.
…xcrichton

Change Linker for x86_64-fortanix-unknown-sgx target to rust-lld

Changed linker for `x86_64-fortanix-unknown-sgx` target to `rust-lld`
This change needed the RelaxELFRelocations flag to be set for it to work correctly

r? @jethrogb
…obk,RalfJung

[const-prop] Fix ICE calculating enum discriminant

Fixes rust-lang#66787

Different approach than rust-lang#66857

r? @oli-obk
cc @RalfJung @eddyb
Update the minimum external LLVM to 7

LLVM 7 is over a year old, which should be plenty for compatibility. The
last LLVM 6 holdout was llvm-emscripten, which went away in rust-lang#65501.

I've also included a fix for LLVM 8 lacking `MemorySanitizerOptions`,
which was broken by rust-lang#66522.
…Gomez

Add long error for E0631 and update ui tests.

This PR adds a long error for `E0631`, which covers errors where closure argument types are mismatched. It also updates UI tests where this error is applicable.

Part of rust-lang#61137
@Centril
Copy link
Contributor Author

Centril commented Dec 3, 2019

@bors r+ p=7 rollup=never

@bors
Copy link
Contributor

bors commented Dec 3, 2019

📌 Commit 9dd829f has been approved by Centril

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Dec 3, 2019
@Centril Centril added the rollup A PR which is a rollup label Dec 3, 2019
@bors
Copy link
Contributor

bors commented Dec 3, 2019

⌛ Testing commit 9dd829f with merge 028311a3850c4d77b6e85dd989abd9f765b0b642...

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-nopt of your PR failed (pretty log, raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
2019-12-03T18:36:36.3266324Z 42 
2019-12-03T18:36:36.3266586Z 
2019-12-03T18:36:36.3266719Z 
2019-12-03T18:36:36.3266904Z The actual stderr differed from the expected stderr.
2019-12-03T18:36:36.3267489Z Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/closure-expected-type/expect-fn-supply-fn.nll/expect-fn-supply-fn.nll.stderr
2019-12-03T18:36:36.3268058Z To update references, rerun the tests and pass the `--bless` flag
2019-12-03T18:36:36.3268612Z To only update this specific test, also pass `--test-args closure-expected-type/expect-fn-supply-fn.rs`
2019-12-03T18:36:36.3269172Z error: 1 errors occurred comparing output.
2019-12-03T18:36:36.3269342Z status: exit code: 1
2019-12-03T18:36:36.3269342Z status: exit code: 1
2019-12-03T18:36:36.3270849Z command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/closure-expected-type/expect-fn-supply-fn.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "--out-dir" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/closure-expected-type/expect-fn-supply-fn.nll" "-Zborrowck=mir" "-Crpath" "-Cdebuginfo=0" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/closure-expected-type/expect-fn-supply-fn.nll/auxiliary" "-A" "unused"
2019-12-03T18:36:36.3271788Z ------------------------------------------
2019-12-03T18:36:36.3271968Z 
2019-12-03T18:36:36.3272365Z ------------------------------------------
2019-12-03T18:36:36.3272573Z stderr:
2019-12-03T18:36:36.3272573Z stderr:
2019-12-03T18:36:36.3272960Z ------------------------------------------
2019-12-03T18:36:36.3273187Z error[E0631]: type mismatch in closure arguments
2019-12-03T18:36:36.3273630Z   --> /checkout/src/test/ui/closure-expected-type/expect-fn-supply-fn.rs:30:5
2019-12-03T18:36:36.3274059Z    |
2019-12-03T18:36:36.3274228Z LL | fn with_closure_expecting_fn_with_free_region<F>(_: F)
2019-12-03T18:36:36.3274757Z    |    ------------------------------------------
2019-12-03T18:36:36.3275188Z LL |     where F: for<'a> FnOnce(fn(&'a u32), &i32)
2019-12-03T18:36:36.3275730Z    |                      ------------------------- required by this bound in `with_closure_expecting_fn_with_free_region`
2019-12-03T18:36:36.3276667Z ...
2019-12-03T18:36:36.3276771Z LL |     with_closure_expecting_fn_with_free_region(|x: fn(&u32), y| {});
2019-12-03T18:36:36.3277213Z    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ---------------- found signature of `fn(for<'r> fn(&'r u32), _) -> _`
2019-12-03T18:36:36.3277329Z    |     |
2019-12-03T18:36:36.3277586Z    |     expected signature of `fn(fn(&'a u32), &i32) -> _`
2019-12-03T18:36:36.3277743Z error[E0631]: type mismatch in closure arguments
2019-12-03T18:36:36.3278053Z   --> /checkout/src/test/ui/closure-expected-type/expect-fn-supply-fn.rs:37:5
2019-12-03T18:36:36.3278315Z    |
2019-12-03T18:36:36.3278315Z    |
2019-12-03T18:36:36.3278399Z LL | fn with_closure_expecting_fn_with_bound_region<F>(_: F)
2019-12-03T18:36:36.3278663Z    |    -------------------------------------------
2019-12-03T18:36:36.3278738Z LL |     where F: FnOnce(fn(&u32), &i32)
2019-12-03T18:36:36.3279062Z    |              ---------------------- required by this bound in `with_closure_expecting_fn_with_bound_region`
2019-12-03T18:36:36.3279153Z ...
2019-12-03T18:36:36.3279429Z LL |     with_closure_expecting_fn_with_bound_region(|x: fn(&'x u32), y| {});
2019-12-03T18:36:36.3279752Z    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ------------------- found signature of `fn(fn(&'x u32), _) -> _`
2019-12-03T18:36:36.3279864Z    |     |
2019-12-03T18:36:36.3282153Z    |     expected signature of `fn(for<'r> fn(&'r u32), &i32) -> _`
2019-12-03T18:36:36.3282464Z error[E0631]: type mismatch in closure arguments
2019-12-03T18:36:36.3282919Z   --> /checkout/src/test/ui/closure-expected-type/expect-fn-supply-fn.rs:46:5
2019-12-03T18:36:36.3283022Z    |
2019-12-03T18:36:36.3283022Z    |
2019-12-03T18:36:36.3283096Z LL | fn with_closure_expecting_fn_with_bound_region<F>(_: F)
2019-12-03T18:36:36.3283380Z    |    -------------------------------------------
2019-12-03T18:36:36.3283462Z LL |     where F: FnOnce(fn(&u32), &i32)
2019-12-03T18:36:36.3283809Z    |              ---------------------- required by this bound in `with_closure_expecting_fn_with_bound_region`
2019-12-03T18:36:36.3283907Z ...
2019-12-03T18:36:36.3284355Z LL |     with_closure_expecting_fn_with_bound_region(|x: Foo<'_>, y| {
2019-12-03T18:36:36.3284928Z    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ --------------- found signature of `for<'r> fn(fn(&'r u32), _) -> _`
2019-12-03T18:36:36.3285023Z    |     |
2019-12-03T18:36:36.3285307Z    |     expected signature of `fn(for<'r> fn(&'r u32), &i32) -> _`
2019-12-03T18:36:36.3285451Z error: aborting due to 3 previous errors
2019-12-03T18:36:36.3285685Z 
2019-12-03T18:36:36.3285946Z For more information about this error, try `rustc --explain E0631`.
2019-12-03T18:36:36.3286018Z 
---
2019-12-03T18:36:36.3309895Z thread 'main' panicked at 'Some tests failed', src/tools/compiletest/src/main.rs:537:22
2019-12-03T18:36:36.3310413Z note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
2019-12-03T18:36:36.3325840Z 
2019-12-03T18:36:36.3325940Z 
2019-12-03T18:36:36.3328500Z command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/compiletest" "--compile-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" "--run-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" "--rustc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "--src-base" "/checkout/src/test/ui" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "ui" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/checkout/obj/build/x86_64-unknown-linux-gnu/llvm/build/bin/FileCheck" "--host-rustcflags" "-Crpath -Cdebuginfo=0 -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--target-rustcflags" "-Crpath -Cdebuginfo=0 -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--docck-python" "/usr/bin/python2.7" "--lldb-python" "/usr/bin/python2.7" "--gdb" "/usr/bin/gdb" "--llvm-version" "9.0.0-rust-1.41.0-dev\n" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always" "--compare-mode" "nll"
2019-12-03T18:36:36.3329202Z 
2019-12-03T18:36:36.3329240Z 
2019-12-03T18:36:36.3335776Z failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
2019-12-03T18:36:36.3335908Z Build completed unsuccessfully in 1:52:48
2019-12-03T18:36:36.3335908Z Build completed unsuccessfully in 1:52:48
2019-12-03T18:36:36.3414223Z == clock drift check ==
2019-12-03T18:36:36.3432020Z   local time: Tue Dec  3 18:36:36 UTC 2019
2019-12-03T18:36:36.6217693Z   network time: Tue, 03 Dec 2019 18:36:36 GMT
2019-12-03T18:36:36.6220214Z == end clock drift check ==
2019-12-03T18:36:38.4803471Z 
2019-12-03T18:36:38.4881142Z ##[error]Bash exited with code '1'.
2019-12-03T18:36:38.4922623Z ##[section]Starting: Checkout
2019-12-03T18:36:38.4924979Z ==============================================================================
2019-12-03T18:36:38.4925136Z Task         : Get sources
2019-12-03T18:36:38.4925233Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@bors
Copy link
Contributor

bors commented Dec 3, 2019

💔 Test failed - checks-azure

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Dec 3, 2019
@Centril Centril closed this Dec 3, 2019
@Centril Centril deleted the rollup-ua6im47 branch December 3, 2019 18:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants