]> git.lizzy.rs Git - rust.git/log
rust.git
4 years agofix some comments, and run_compiler return type
Ralf Jung [Sun, 10 May 2020 22:07:59 +0000 (00:07 +0200)]
fix some comments, and run_compiler return type

4 years agoAuto merge of #1406 - RalfJung:miri-as-rustc, r=RalfJung
bors [Sun, 10 May 2020 17:00:14 +0000 (17:00 +0000)]
Auto merge of #1406 - RalfJung:miri-as-rustc, r=RalfJung

cargo-miri: never invoke rustc

Always go through 'MIRI_BE_RUSTC=1 miri' instead. This is based on @oli-obk's great idea to add a way to make Miri behave like rustc, which already helped us in https://github.com/rust-lang/miri/pull/1405. Now it means in `cargo-miri` we run *all* crates through the same binary, and use the env var to determine if we compile or interpret them. This makes sure the compiler is consistent.

The `rustc` binary of the current toolchain is now not used at all, only the `miri` binary is. In particular this means we can kill the sysroot consistency check. :)

4 years agowe do not need to set RUSTFLAGS for xargo any more as miri-as-rustc already uses...
Ralf Jung [Sun, 10 May 2020 16:56:38 +0000 (18:56 +0200)]
we do not need to set RUSTFLAGS for xargo any more as miri-as-rustc already uses these flags

4 years agofix dead link in README
Ralf Jung [Sun, 10 May 2020 16:52:21 +0000 (18:52 +0200)]
fix dead link in README

4 years agocargo-miri: never invoke rustc, always go through 'MIRI_BE_RUSTC=1 miri' instead
Ralf Jung [Sun, 10 May 2020 16:41:03 +0000 (18:41 +0200)]
cargo-miri: never invoke rustc, always go through 'MIRI_BE_RUSTC=1 miri' instead

4 years agoAuto merge of #1402 - rust-lang:alloc_map_unlock, r=RalfJung
bors [Sun, 10 May 2020 08:32:58 +0000 (08:32 +0000)]
Auto merge of #1402 - rust-lang:alloc_map_unlock, r=RalfJung

Update to rustc changes

changes needed once https://github.com/rust-lang/rust/pull/71508 gets merged

4 years agorustup
Ralf Jung [Sun, 10 May 2020 08:32:29 +0000 (10:32 +0200)]
rustup

4 years agoUpdate to rustc changes
Oliver Scherer [Fri, 8 May 2020 11:56:10 +0000 (13:56 +0200)]
Update to rustc changes

4 years agoAuto merge of #1405 - RalfJung:stage-0, r=RalfJung
bors [Sat, 9 May 2020 12:09:15 +0000 (12:09 +0000)]
Auto merge of #1405 - RalfJung:stage-0, r=RalfJung

make Miri work in rustc bootstrap stage 0

Fixes https://github.com/rust-lang/rust/issues/52856

4 years agoTypo
Ralf Jung [Sat, 9 May 2020 12:08:58 +0000 (14:08 +0200)]
Typo

4 years agoadjust default sysroot when being rustc
Ralf Jung [Sat, 9 May 2020 11:20:34 +0000 (13:20 +0200)]
adjust default sysroot when being rustc

Also while at it, refactor how we pass the default Miri flags

4 years agomake Miri work in rustc bootstrap stage 0
Ralf Jung [Sat, 9 May 2020 10:24:30 +0000 (12:24 +0200)]
make Miri work in rustc bootstrap stage 0

4 years agoAuto merge of #1404 - RalfJung:cargo-miri-host-detect, r=RalfJung
bors [Sat, 9 May 2020 10:06:04 +0000 (10:06 +0000)]
Auto merge of #1404 - RalfJung:cargo-miri-host-detect, r=RalfJung

re-do cargo-miri host/target detection logic to match rustbuild

@oli-obk I think that's better than looking at `--emit` like we did before... what do you think?

4 years agoavoid env::var which requires valid UTF-8
Ralf Jung [Sat, 9 May 2020 09:58:18 +0000 (11:58 +0200)]
avoid env::var which requires valid UTF-8

4 years agomore comment
Ralf Jung [Sat, 9 May 2020 09:54:35 +0000 (11:54 +0200)]
more comment

4 years agoWording
Ralf Jung [Sat, 9 May 2020 09:53:24 +0000 (11:53 +0200)]
Wording

Co-authored-by: Oliver Scherer <github35764891676564198441@oli-obk.de>
4 years agocargo-miri: honor RUSTC env var
Ralf Jung [Sat, 9 May 2020 09:52:26 +0000 (11:52 +0200)]
cargo-miri: honor RUSTC env var

4 years agore-do cargo-miri host/target detection logic to match rustbuild
Ralf Jung [Sat, 9 May 2020 09:45:43 +0000 (11:45 +0200)]
re-do cargo-miri host/target detection logic to match rustbuild

4 years agoAuto merge of #1403 - RalfJung:rustup, r=RalfJung
bors [Sat, 9 May 2020 08:15:45 +0000 (08:15 +0000)]
Auto merge of #1403 - RalfJung:rustup, r=RalfJung

bump Rust, fix for renames

4 years agobump Rust, fix for renames
Ralf Jung [Sat, 9 May 2020 08:15:09 +0000 (10:15 +0200)]
bump Rust, fix for renames

4 years agoAuto merge of #1401 - RalfJung:cargo-miri-help, r=RalfJung
bors [Fri, 8 May 2020 07:56:38 +0000 (07:56 +0000)]
Auto merge of #1401 - RalfJung:cargo-miri-help, r=RalfJung

fix cargo-miri intercepting --help/--version arguments

With this, `cargo miri test -- -- --help` should behave as expected and pass `--help` to the test runner.

Thanks to @brson for the report.

4 years agofix cargo-miri intercepting --help/--version arguments
Ralf Jung [Fri, 8 May 2020 07:55:28 +0000 (09:55 +0200)]
fix cargo-miri intercepting --help/--version arguments

4 years agoAuto merge of #1400 - RalfJung:rustup, r=RalfJung
bors [Thu, 7 May 2020 21:59:57 +0000 (21:59 +0000)]
Auto merge of #1400 - RalfJung:rustup, r=RalfJung

rustup

4 years agorustup
Ralf Jung [Thu, 7 May 2020 21:59:26 +0000 (23:59 +0200)]
rustup

4 years agoAuto merge of #1397 - brson:tikv-2, r=RalfJung
bors [Thu, 7 May 2020 09:22:17 +0000 (09:22 +0000)]
Auto merge of #1397 - brson:tikv-2, r=RalfJung

Add two more TiKV bugs to trophy case

4 years agoadjust wording
Ralf Jung [Thu, 7 May 2020 09:21:31 +0000 (11:21 +0200)]
adjust wording

4 years agoAuto merge of #1398 - RalfJung:rustup, r=RalfJung
bors [Thu, 7 May 2020 06:42:59 +0000 (06:42 +0000)]
Auto merge of #1398 - RalfJung:rustup, r=RalfJung

rustup; fix error messages

4 years agorustup; fix error messages
Ralf Jung [Thu, 7 May 2020 06:38:52 +0000 (08:38 +0200)]
rustup; fix error messages

4 years agoAdd two more TiKV bugs to trophy case
Brian Anderson [Thu, 7 May 2020 02:42:12 +0000 (02:42 +0000)]
Add two more TiKV bugs to trophy case

4 years agoAuto merge of #1396 - RalfJung:float-cast-tests, r=RalfJung
bors [Wed, 6 May 2020 20:47:34 +0000 (20:47 +0000)]
Auto merge of #1396 - RalfJung:float-cast-tests, r=RalfJung

copy some float cast tests from rustc

The more the merrirer!

4 years agocopy some float cast tests from rustc
Ralf Jung [Wed, 6 May 2020 20:46:42 +0000 (22:46 +0200)]
copy some float cast tests from rustc

4 years agoAuto merge of #1394 - RalfJung:fs-mode, r=RalfJung
bors [Tue, 5 May 2020 14:49:48 +0000 (14:49 +0000)]
Auto merge of #1394 - RalfJung:fs-mode, r=RalfJung

fs shim: check that mode is default

4 years agofs shim: check that mode is default
Ralf Jung [Tue, 5 May 2020 14:49:01 +0000 (16:49 +0200)]
fs shim: check that mode is default

4 years agoAuto merge of #1393 - RalfJung:arg-count-cleanup, r=RalfJung
bors [Tue, 5 May 2020 10:21:46 +0000 (10:21 +0000)]
Auto merge of #1393 - RalfJung:arg-count-cleanup, r=RalfJung

Make sure we check argument count everywhere and argument size for non-stub shims

4 years agomake sure we check the size of all arguments
Ralf Jung [Tue, 5 May 2020 10:19:54 +0000 (12:19 +0200)]
make sure we check the size of all arguments

4 years agofix a comment now that we have concurrency
Ralf Jung [Tue, 5 May 2020 09:57:39 +0000 (11:57 +0200)]
fix a comment now that we have concurrency

4 years agomake sure we check argument count everywhere
Ralf Jung [Tue, 5 May 2020 09:57:08 +0000 (11:57 +0200)]
make sure we check argument count everywhere

4 years agodeduplicate FD extraction
Ralf Jung [Tue, 5 May 2020 09:44:33 +0000 (11:44 +0200)]
deduplicate FD extraction

4 years agoAuto merge of #1298 - toc-the-younger:check-arg-count, r=RalfJung
bors [Tue, 5 May 2020 09:08:10 +0000 (09:08 +0000)]
Auto merge of #1298 - toc-the-younger:check-arg-count, r=RalfJung

Check that shims are called with the correct number of arguments

Fixes #1272

Some shims don't use all their arguments, I've assumed they are being called in tests with the correct number of arguments here.

4 years agoCorrect the test.
Chase Albert [Tue, 5 May 2020 03:22:00 +0000 (23:22 -0400)]
Correct the test.

4 years agoAddress comments.
Chase Albert [Mon, 4 May 2020 18:24:22 +0000 (14:24 -0400)]
Address comments.

4 years agoTest for too many args.
Chase Albert [Thu, 30 Apr 2020 22:16:56 +0000 (18:16 -0400)]
Test for too many args.

4 years agoAddress consistency of naming for unused/merely validated arguments.
Chase Albert [Thu, 30 Apr 2020 21:30:27 +0000 (17:30 -0400)]
Address consistency of naming for unused/merely validated arguments.

4 years agoAdd a test for check_arg_count.
Chase Albert [Thu, 30 Apr 2020 21:30:21 +0000 (17:30 -0400)]
Add a test for check_arg_count.

4 years agoCheck that shims are called with the correct number of arguments
Chase Albert [Thu, 2 Apr 2020 21:09:20 +0000 (17:09 -0400)]
Check that shims are called with the correct number of arguments

4 years agoAuto merge of #1392 - RalfJung:win-lock-check, r=RalfJung
bors [Mon, 4 May 2020 07:45:35 +0000 (07:45 +0000)]
Auto merge of #1392 - RalfJung:win-lock-check, r=RalfJung

Windows lock primitives: check that we are truly single-threaded

Also rustup because why not.

4 years agorename single-threaded sync test
Ralf Jung [Mon, 4 May 2020 07:45:15 +0000 (09:45 +0200)]
rename single-threaded sync test

4 years agorustup
Ralf Jung [Mon, 4 May 2020 07:43:09 +0000 (09:43 +0200)]
rustup

4 years agoWindows lock primitives: check that we are truly sinle-threaded
Ralf Jung [Mon, 4 May 2020 07:37:40 +0000 (09:37 +0200)]
Windows lock primitives: check that we are truly sinle-threaded

4 years agoAuto merge of #1390 - RalfJung:conc, r=RalfJung
bors [Sun, 3 May 2020 11:23:47 +0000 (11:23 +0000)]
Auto merge of #1390 - RalfJung:conc, r=RalfJung

Make spin_loop yield, and a panicking thread test

@vakaras agreed it would make sense to make `spin_loop` yield, so this implements that.

Also add a test for a panic being raised in one thread, caught by the panic machinery, and then expose through the join handle. Miraculously, that just works. :)

4 years agofix setting thread name on macOS
Ralf Jung [Sun, 3 May 2020 11:22:56 +0000 (13:22 +0200)]
fix setting thread name on macOS

4 years agode-duplicate <unnamed> default thread name
Ralf Jung [Sun, 3 May 2020 10:56:38 +0000 (12:56 +0200)]
de-duplicate <unnamed> default thread name

4 years agoalso test panic from thread with name
Ralf Jung [Sun, 3 May 2020 10:51:48 +0000 (12:51 +0200)]
also test panic from thread with name

4 years agoalso test std::hint::spin_loop
Ralf Jung [Sun, 3 May 2020 10:40:15 +0000 (12:40 +0200)]
also test std::hint::spin_loop

4 years agotest panics in threads
Ralf Jung [Sun, 3 May 2020 10:25:07 +0000 (12:25 +0200)]
test panics in threads

4 years agoyield on x86 'pause' hint
Ralf Jung [Sun, 3 May 2020 10:24:57 +0000 (12:24 +0200)]
yield on x86 'pause' hint

4 years agoexplain what happens in a test
Ralf Jung [Sun, 3 May 2020 10:24:40 +0000 (12:24 +0200)]
explain what happens in a test

4 years agoAuto merge of #1387 - RalfJung:rustup, r=RalfJung
bors [Sun, 3 May 2020 10:10:57 +0000 (10:10 +0000)]
Auto merge of #1387 - RalfJung:rustup, r=RalfJung

bump Rust, fix warnings

4 years agobump Rust, fix warnings
Ralf Jung [Sun, 3 May 2020 10:10:24 +0000 (12:10 +0200)]
bump Rust, fix warnings

4 years agoAuto merge of #1386 - RalfJung:trophy, r=RalfJung
bors [Sat, 2 May 2020 09:41:31 +0000 (09:41 +0000)]
Auto merge of #1386 - RalfJung:trophy, r=RalfJung

trophy case: consistent wording (X doing Y)

4 years agoAuto merge of #1383 - brson:tikv-trophy, r=RalfJung
bors [Sat, 2 May 2020 09:21:54 +0000 (09:21 +0000)]
Auto merge of #1383 - brson:tikv-trophy, r=RalfJung

Add another tikv stacked borrowing error to trophy case

@RalfJung please update it with whatever language is most correct :)

4 years agotrophy case: consistent wording (X doing Y)
Ralf Jung [Sat, 2 May 2020 09:08:20 +0000 (11:08 +0200)]
trophy case: consistent wording (X doing Y)

4 years agoAdjust wording
Ralf Jung [Sat, 2 May 2020 09:04:45 +0000 (11:04 +0200)]
Adjust wording

4 years agoAuto merge of #1385 - RalfJung:rustup, r=RalfJung
bors [Sat, 2 May 2020 09:01:14 +0000 (09:01 +0000)]
Auto merge of #1385 - RalfJung:rustup, r=RalfJung

rustup

before making a rustc PR, just to be sure

4 years agorustup
Ralf Jung [Sat, 2 May 2020 09:00:37 +0000 (11:00 +0200)]
rustup

4 years agoAuto merge of #1384 - RalfJung:rustup, r=RalfJung
bors [Sat, 2 May 2020 00:17:20 +0000 (00:17 +0000)]
Auto merge of #1384 - RalfJung:rustup, r=RalfJung

rustup for fixed error messages

4 years agorustup for fixed error messages
Ralf Jung [Sat, 2 May 2020 00:13:48 +0000 (02:13 +0200)]
rustup for fixed error messages

4 years agoAdd another tikv stacked borrowing error to trophy case
Brian Anderson [Fri, 1 May 2020 21:34:16 +0000 (21:34 +0000)]
Add another tikv stacked borrowing error to trophy case

4 years agoAuto merge of #1381 - RalfJung:rustup, r=RalfJung
bors [Fri, 1 May 2020 12:44:29 +0000 (12:44 +0000)]
Auto merge of #1381 - RalfJung:rustup, r=RalfJung

rustup; fix for changed error messages

4 years agorustup; fix for changed error messages
Ralf Jung [Fri, 1 May 2020 12:43:59 +0000 (14:43 +0200)]
rustup; fix for changed error messages

4 years agoAuto merge of #1380 - RalfJung:rustup, r=RalfJung
bors [Fri, 1 May 2020 08:30:25 +0000 (08:30 +0000)]
Auto merge of #1380 - RalfJung:rustup, r=RalfJung

rustup, adjust error messages

4 years agorustup, adjust error messages
Ralf Jung [Fri, 1 May 2020 08:29:39 +0000 (10:29 +0200)]
rustup, adjust error messages

4 years agoAuto merge of #1379 - RalfJung:macos-fn-name, r=RalfJung
bors [Thu, 30 Apr 2020 17:40:40 +0000 (17:40 +0000)]
Auto merge of #1379 - RalfJung:macos-fn-name, r=RalfJung

make sure macos function has 'macos' in its name

also tiny README tweak

4 years agoREADME tweak
Ralf Jung [Thu, 30 Apr 2020 17:39:56 +0000 (19:39 +0200)]
README tweak

4 years agomake sure macos function has 'macos' in its name
Ralf Jung [Thu, 30 Apr 2020 17:38:17 +0000 (19:38 +0200)]
make sure macos function has 'macos' in its name

4 years agoAuto merge of #1284 - vakaras:add-threads-cr2, r=RalfJung
bors [Thu, 30 Apr 2020 16:21:43 +0000 (16:21 +0000)]
Auto merge of #1284 - vakaras:add-threads-cr2, r=RalfJung

Implement basic support for concurrency (Linux/macos only)

Changes  (most new code is in `src/threads.rs` and `src/shims/foreign_items/posix.rs`):

1. Move the stack from `Machine` to a newly created `Thread` struct.
2. Add a `ThreadSet` struct that manages the threads.
3. Change `canonical_alloc_id` to create a unique allocation id for each thread local and thread (the responsible struct is `ThreadLocalStorage`)
4. Change the code to execute the thread local destructors immediately when a thread terminates.
5. Add the most basic round-robin scheduler.

This pull request depends on [these changes to the compiler](https://github.com/rust-lang/rust/pull/70598).

4 years agoFix prctl SET_NAME and GET_NAME behaviour.
Vytautas Astrauskas [Thu, 30 Apr 2020 15:35:59 +0000 (08:35 -0700)]
Fix prctl SET_NAME and GET_NAME behaviour.

4 years agoAuto merge of #1377 - brson:servo-trophy, r=RalfJung
bors [Thu, 30 Apr 2020 08:41:33 +0000 (08:41 +0000)]
Auto merge of #1377 - brson:servo-trophy, r=RalfJung

Add servo_arc to trophy case

4 years agoTweak error wording
Ralf Jung [Thu, 30 Apr 2020 08:24:57 +0000 (10:24 +0200)]
Tweak error wording

4 years agoAuto merge of #1378 - RalfJung:workspace-error, r=RalfJung
bors [Thu, 30 Apr 2020 08:20:25 +0000 (08:20 +0000)]
Auto merge of #1378 - RalfJung:workspace-error, r=RalfJung

more helpful error on workspaces

4 years agomore helpful error on workspaces
Ralf Jung [Thu, 30 Apr 2020 08:19:34 +0000 (10:19 +0200)]
more helpful error on workspaces

4 years agoAdd servo_arc to trophy case
Brian Anderson [Thu, 30 Apr 2020 00:03:43 +0000 (00:03 +0000)]
Add servo_arc to trophy case

4 years agoFix a regression in Windows dtors.
Vytautas Astrauskas [Wed, 29 Apr 2020 22:20:26 +0000 (15:20 -0700)]
Fix a regression in Windows dtors.

4 years agoUse Entry API in set_dtors_running.
Vytautas Astrauskas [Wed, 29 Apr 2020 22:12:09 +0000 (15:12 -0700)]
Use Entry API in set_dtors_running.

4 years agoImprove code readability and comments.
Vytautas Astrauskas [Wed, 29 Apr 2020 20:16:22 +0000 (13:16 -0700)]
Improve code readability and comments.

4 years agoAuto merge of #1375 - RalfJung:rustup, r=RalfJung
bors [Tue, 28 Apr 2020 08:31:05 +0000 (08:31 +0000)]
Auto merge of #1375 - RalfJung:rustup, r=RalfJung

rustup for more LocalDefId changes

4 years agorustup for more LocalDefId changes
Ralf Jung [Tue, 28 Apr 2020 08:30:21 +0000 (10:30 +0200)]
rustup for more LocalDefId changes

4 years agoFix MacOS and Windows builds.
Vytautas Astrauskas [Mon, 27 Apr 2020 22:21:01 +0000 (15:21 -0700)]
Fix MacOS and Windows builds.

4 years agoDelete remaining tls entries after all destructors completed.
Vytautas Astrauskas [Mon, 27 Apr 2020 21:00:39 +0000 (14:00 -0700)]
Delete remaining tls entries after all destructors completed.

4 years agoMake From implementations non-failing.
Vytautas Astrauskas [Mon, 27 Apr 2020 19:32:57 +0000 (12:32 -0700)]
Make From implementations non-failing.

4 years agoImprove comments.
Vytautas Astrauskas [Mon, 27 Apr 2020 18:01:35 +0000 (11:01 -0700)]
Improve comments.

4 years agoAdd a test for joining in a destructor.
Vytautas Astrauskas [Mon, 27 Apr 2020 05:05:09 +0000 (22:05 -0700)]
Add a test for joining in a destructor.

4 years agoMerge dtors_running and last_dtor_key fields.
Vytautas Astrauskas [Mon, 27 Apr 2020 04:49:36 +0000 (21:49 -0700)]
Merge dtors_running and last_dtor_key fields.

4 years agoAdd a FIXME.
Vytautas Astrauskas [Mon, 27 Apr 2020 04:25:46 +0000 (21:25 -0700)]
Add a FIXME.

4 years agoImprove comments and code clarity.
Vytautas Astrauskas [Mon, 27 Apr 2020 04:13:33 +0000 (21:13 -0700)]
Improve comments and code clarity.

4 years agoChange representation and conversion of ThreadId and BlockSetId.
Vytautas Astrauskas [Mon, 27 Apr 2020 04:01:03 +0000 (21:01 -0700)]
Change representation and conversion of ThreadId and BlockSetId.

4 years agoUse DLL_THREAD_DETACH when calling windows TLS destructor.
Vytautas Astrauskas [Mon, 27 Apr 2020 03:51:21 +0000 (20:51 -0700)]
Use DLL_THREAD_DETACH when calling windows TLS destructor.

4 years agoMake sure to remove thread local data only if we have destructor.
Vytautas Astrauskas [Mon, 27 Apr 2020 03:50:58 +0000 (20:50 -0700)]
Make sure to remove thread local data only if we have destructor.

4 years agoImprove style and comments.
Vytautas Astrauskas [Mon, 27 Apr 2020 03:49:53 +0000 (20:49 -0700)]
Improve style and comments.

4 years agoMany small changes to clean up code.
Vytautas Astrauskas [Sun, 26 Apr 2020 22:52:45 +0000 (15:52 -0700)]
Many small changes to clean up code.