David Cook
9e03b41338
Migrate readdir_r from pointers to places
2020-02-24 19:38:17 -06:00
David Cook
9fcc8a2a91
Review comments
2020-02-24 19:16:41 -06:00
David Cook
dd00e5830f
Use ID numbers in lieu of allocations for DIR*
2020-02-23 15:46:18 -06:00
David Cook
89cbe0ae56
Add comments
2020-02-23 15:45:04 -06:00
David Cook
725d6bfa9c
Move error up, early return
2020-02-23 15:39:50 -06:00
David Cook
d6da4ab4b8
Add comments
2020-02-23 15:38:32 -06:00
David Cook
94f611348f
Use os_str_length_as_c_str in readdir[64]_r
2020-02-23 15:37:22 -06:00
David Cook
947fa1fa26
Miscellaneous review comments
2020-02-23 15:36:03 -06:00
David Cook
341212acd6
Rewrite fs tests
2020-02-23 15:34:49 -06:00
David Cook
d4b73efa81
Fix interpreted OS detection
2020-02-23 15:33:37 -06:00
David Cook
9a6921a17f
Add doc comment inside DirHandler
2020-02-23 15:32:24 -06:00
David Cook
515d29aa2c
Fix dirent layout for macOS
2020-02-23 15:31:07 -06:00
David Cook
a82049587c
Use longer file names in test
2020-02-23 15:28:50 -06:00
David Cook
d461c12c83
Add more information to test asserts
2020-02-23 15:26:47 -06:00
David Cook
ba61a9b37c
Add shims for macOS-specific symbols
2020-02-23 15:26:42 -06:00
David Cook
974362ef64
Handle differing sizes of mode_t
...
mode_t is a u32 on Linux and a u16 on macOS
2020-02-23 15:08:44 -06:00
David Cook
5d35339111
Add shim for readdir64_r
2020-02-23 15:08:44 -06:00
David Cook
d7c3f588eb
Add shims for opendir and closedir
2020-02-23 15:02:49 -06:00
David Cook
5b34f06bae
Add shims for mkdir and rmdir
2020-02-23 15:02:49 -06:00
bors
29b0bbf859
Auto merge of #1189 - RalfJung:cleanup, r=RalfJung
...
some foreign_items cleanup
Cc @christianpoveda
2020-02-23 18:11:37 +00:00
Ralf Jung
4a9a0a9078
avoid lowercasing platforms
2020-02-23 18:54:08 +01:00
Ralf Jung
e575fb1f57
improve comments
2020-02-23 18:52:12 +01:00
Ralf Jung
beb82ea4a4
add private helper trait for fs shim
2020-02-23 18:52:12 +01:00
Ralf Jung
5d35548985
helpers.rs cleanup
2020-02-23 18:52:12 +01:00
bors
2752d1b74b
Auto merge of #1167 - christianpoveda:shims-refactor, r=RalfJung
...
Reorganize shims by platform
Fixes https://github.com/rust-lang/miri/issues/1161 . I am currently testing which shims belong to which platform. If you are reading this and know the answer for any of those please write me :P
Edit: this is a list of the shims I haven't been able to figure out to which platform they belong:
-~~`malloc`~~
-~~`calloc`~~
-~~`posix_memalign`~~
-~~`free`~~
-~~`realloc`~~
-~~`__rust_alloc`~~
-~~`__rust_alloc_zeroed`~~
-~~`__rust_dealloc`~~
-~~`__rust_realloc`~~
-~~`__rust_maybe_catch_panic`~~
-~~`syscall`~~
-~~`getrandom`~~
-~~`dlsym`~~
-~~`memcmp`~~
-~~`memrchr`~~
-~~`memchr`~~
-~~`strlen`~~
-~~`signal`~~
-~~`sigaction`~~
-~~`sigaltstack`~~
-~~`sysconf`~~
-~~`sched_getaffinity`~~
-~~`isatty`~~
-~~`pthread_key_create`~~
-~~`pthread_key_delete`~~
-~~`pthread_getspecific`~~
-~~`pthread_setspecific`~~
-~~`pthread_attr_init`~~
-~~`pthread_attr_destroy`~~
-~~`pthread_self`~~
-~~`pthread_attr_setstacksize`~~
-~~`pthread_attr_getstack`~~
-~~`pthread_create`~~
-~~`pthread_mutexattr_init`~~
-~~`pthread_mutexattr_settype`~~
-~~`pthread_mutex_init`~~
-~~`pthread_mutexattr_destroy`~~
-~~`pthread_mutex_lock`~~
-~~`pthread_mutex_unlock`~~
-~~`pthread_mutex_destroy`~~
-~~`pthread_rwlock_rdlock`~~
-~~`pthread_rwlock_unlock`~~
-~~`pthread_rwlock_wrlock`~~
-~~`pthread_rwlock_destroy`~~
-~~`pthread_condattr_init`~~
-~~`pthread_condattr_setclock`~~
-~~`pthread_cond_init`~~
-~~`pthread_condattr_destroy`~~
-~~`pthread_cond_destroy`~~
-~~`pthread_atfork`~~
-~~`posix_fadvise`~~
-~~`mmap`~~
-~~`mprotect`~~
2020-02-23 17:03:30 +00:00
Christian Poveda
208665836e
panic if target platform is incorrect instead
2020-02-22 09:02:29 -05:00
Christian Poveda
c2bcab55b0
improve docs
2020-02-22 08:55:45 -05:00
bors
c40a31e93c
Auto merge of #1185 - RalfJung:readme, r=RalfJung
...
fix README
With https://github.com/rust-lang/miri/pull/1127 , we do not abort execution any more when the tracked tag gets popped, we just show a backtrace.
2020-02-22 10:58:53 +00:00
Ralf Jung
86a4354746
fix README
2020-02-22 11:58:21 +01:00
Christian Poveda
9e9a090026
minor fixes
2020-02-22 02:18:42 -05:00
bors
a3dad216ee
Auto merge of #1188 - RalfJung:bootstrap, r=RalfJung
...
dont overwrite bootstrap flags
2020-02-21 19:07:37 +00:00
Ralf Jung
08332bc730
dont overwrite bootstrap flags
2020-02-21 20:06:31 +01:00
bors
5b8462066d
Auto merge of #1187 - RalfJung:rustup, r=RalfJung
...
fix for const-prop lint changes
Cc https://github.com/rust-lang/rust/issues/69331
2020-02-21 10:06:24 +00:00
Ralf Jung
3e2f29a079
remove some no-longer-needed allow(const_err)
2020-02-21 11:05:56 +01:00
Ralf Jung
0e7e5b9655
fix test-cargo-miri
2020-02-21 11:03:52 +01:00
Ralf Jung
627d7cba64
fix for const-prop lint changes
2020-02-21 10:33:00 +01:00
bors
fe8068d145
Auto merge of #1184 - divergentdave:rename-error-test, r=RalfJung
...
Test error case of std::fs::rename
As suggested [here](https://github.com/rust-lang/miri/pull/1158#issuecomment-586459463 ) this PR adds an additional test case for calling rename on a file path that doesn't exist.
2020-02-21 07:36:14 +00:00
David Cook
32a354efa3
Test error case of std::fs::rename
2020-02-20 21:54:52 -06:00
bors
056a68d7d0
Auto merge of #1182 - rust-lang:rustup, r=RalfJung
...
rustup
We got a CI failure from our cronjob. It looks spurious, but better safe than sorry.
2020-02-20 10:10:14 +00:00
Ralf Jung
a60dfcf6e7
rustup
2020-02-20 11:09:12 +01:00
Christian Poveda
bb3a711b3e
rename platform specific shims
2020-02-19 17:53:33 -05:00
Christian Poveda
3418b40dac
remove syscall shim from macos and move getrandom to linux module
2020-02-19 17:48:16 -05:00
Christian Poveda
b213f88b58
promote memrchr to work on any platform
2020-02-19 17:48:15 -05:00
Christian Poveda
9a7bc3972c
promote open and lseek shims to posix
2020-02-19 17:48:15 -05:00
Christian Poveda
dbef2340b2
add docs for `emulate_foreign_item_by_bame
2020-02-19 17:48:15 -05:00
Christian Poveda
32bc015e35
reorganize comments for shim's classification
2020-02-19 17:48:15 -05:00
Christian Poveda
bc7513bffd
move CreateThread to windows shims
2020-02-19 17:48:15 -05:00
Christian Poveda
1dbc0c9869
remove hack for panics
2020-02-19 17:48:15 -05:00
Christian Poveda
b819493585
move remaining shims
2020-02-19 17:48:15 -05:00
Christian Poveda
63160c66cd
move pthread related functions
2020-02-19 17:48:15 -05:00