about summary refs log tree commit diff
path: root/library/std/src/sys/vxworks
AgeCommit message (Collapse)AuthorLines
2021-04-19Move `sys::vxworks` code to `sys::unix`Christiaan Dirkx-416/+0
2021-04-18Rename `NotSupported` to `Unsupported`Christiaan Dirkx-1/+1
2021-04-18Update `decode_error_kind` to decode os errors to `NotSupported`Christiaan Dirkx-0/+1
2021-03-21Use io::Error::new_const everywhere to avoid allocations.Mara Bos-3/+6
2020-10-16Take some of sys/vxworks/process/* from sys/unix instead.Mara Bos-402/+50
2020-10-16Take sys/vxworks/{os,path,pipe} from sys/unix instead.Mara Bos-441/+3
2020-10-16Take sys/vxworks/{fd,fs,io} from sys/unix instead.Mara Bos-900/+3
2020-10-16Take sys/vxworks/cmath from sys/unix instead.Mara Bos-32/+1
2020-10-16Take sys/vxworks/args from sys/unix instead.Mara Bos-95/+1
2020-10-16Take sys/vxworks/memchar from sys/unix instead.Mara Bos-21/+1
2020-10-16Take sys/vxworks/net from sys/unix instead.Mara Bos-358/+1
2020-10-16Take sys/vxworks/ext/* from sys/unix instead.Mara Bos-1321/+1
2020-10-16Add weak macro to vxworks.Mara Bos-0/+4
2020-10-16Take sys/vxworks/alloc from sys/unix instead.Mara Bos-49/+1
2020-10-16Take sys/vxworks/thread_local_key from sys/unix instead.Mara Bos-34/+1
2020-10-16Take sys/vxworks/stdio from sys/unix instead.Mara Bos-69/+1
2020-10-16Take sys/vxworks/thread from sys/unix instead.Mara Bos-155/+1
2020-10-16Take sys/vxworks/stack_overflow from sys/unix instead.Mara Bos-38/+1
2020-10-16Take sys/vxworks/time from sys/unix instead.Mara Bos-197/+1
2020-10-16Take sys/vxworks/rwlock from sys/unix instead.Mara Bos-114/+1
2020-10-16Take sys/vxworks/condvar from sys/unix instead.Mara Bos-91/+1
2020-10-16Take sys/vxworks/mutex from sys/unix instead.Mara Bos-133/+1
2020-10-14Remove lifetime from StaticMutex and assume 'static.Mara Bos-1/+1
StaticMutex is only ever used with as a static (as the name already suggests). So it doesn't have to be generic over a lifetime, but can simply assume 'static. This 'static lifetime guarantees the object is never moved, so this is no longer a manually checked requirement for unsafe calls to lock().
2020-10-09unix/vxworks: make DirEntry slightly smallerJosh Stone-4/+3
`DirEntry` contains a `ReadDir` handle, which used to just be a wrapper on `Arc<InnerReadDir>`. Commit af75314ecdbc5 added `end_of_stream: bool` which is not needed by `DirEntry`, but adds 8 bytes after padding. We can let `DirEntry` have an `Arc<InnerReadDir>` directly to avoid that.
2020-10-02Make it possible to have unboxed condvars on specific platforms.Mara Bos-0/+2
This commit keeps all condvars boxed on all platforms, but makes it trivial to remove the box on some platforms later.
2020-10-02Make it possible to have unboxed mutexes on specific platforms.Mara Bos-0/+2
This commit keeps all mutexes boxed on all platforms, but makes it trivial to remove the box on some platforms later.
2020-10-02Rollup merge of #77147 - fusion-engineering-forks:static-mutex, r=dtolnayYuki Okushi-7/+6
Split sys_common::Mutex in StaticMutex and MovableMutex. The (unsafe) `Mutex` from `sys_common` had a rather complicated interface. You were supposed to call `init()` manually, unless you could guarantee it was neither moved nor used reentrantly. Calling `destroy()` was also optional, although it was unclear if 1) resources might be leaked or not, and 2) if `destroy()` should only be called when `init()` was called. This allowed for a number of interesting (confusing?) different ways to use this `Mutex`, all captured in a single type. In practice, this type was only ever used in two ways: 1. As a static variable. In this case, neither `init()` nor `destroy()` are called. The variable is never moved, and it is never used reentrantly. It is only ever locked using the `LockGuard`, never with `raw_lock`. 2. As a `Box`ed variable. In this case, both `init()` and `destroy()` are called, it will be moved and possibly used reentrantly. No other combinations are used anywhere in `std`. This change simplifies things by splitting this `Mutex` type into two types matching the two use cases: `StaticMutex` and `MovableMutex`. The interface of both new types is now both safer and simpler. The first one does not call nor expose `init`/`destroy`, and the second one calls those automatically in its `new()` and `Drop` functions. Also, the locking functions of `MovableMutex` are no longer unsafe. --- This will also make it easier to conditionally box mutexes later, by moving that decision into sys/sys_common. Some of the mutex implementations (at least those of Wasm and 'sys/unsupported') are safe to move, so wouldn't need a box. ~~(But that's blocked on #76932 for now.)~~ (See #77380.)
2020-09-27Split sys_common::Mutex in StaticMutex and MovableMutex.Mara Bos-7/+6
The (unsafe) Mutex from sys_common had a rather complicated interface. You were supposed to call init() manually, unless you could guarantee it was neither moved nor used reentrantly. Calling `destroy()` was also optional, although it was unclear if 1) resources might be leaked or not, and 2) if destroy() should only be called when `init()` was called. This allowed for a number of interesting (confusing?) different ways to use this Mutex, all captured in a single type. In practice, this type was only ever used in two ways: 1. As a static variable. In this case, neither init() nor destroy() are called. The variable is never moved, and it is never used reentrantly. It is only ever locked using the LockGuard, never with raw_lock. 2. As a Boxed variable. In this case, both init() and destroy() are called, it will be moved and possibly used reentrantly. No other combinations are used anywhere in `std`. This change simplifies things by splitting this Mutex type into two types matching the two use cases: StaticMutex and MovableMutex. The interface of both new types is now both safer and simpler. The first one does not call nor expose init/destroy, and the second one calls those automatically in its new() and Drop functions. Also, the locking functions of MovableMutex are no longer unsafe.
2020-09-20try again to appease tidyWithout Boats-1/+0
2020-09-20fix typosWithout Boats-2/+2
2020-09-20Make RawFd implement the RawFd traitsWithout Boats-0/+20
2020-09-12Remove Windows details from Unix and VmWorks symlink() docstringsNicholas Bishop-9/+0
This note is not relevant to other operating systems.
2020-09-04Fix nlink example typoChris Gillespie-1/+1
2020-08-31std: move "mod tests/benches" to separate filesLzu Tao-27/+26
Also doing fmt inplace as requested.
2020-08-27Rollup merge of #75758 - bpangWR:master, r=Mark-SimulacrumDylan DPC-14/+5
Fixes for VxWorks r? @alexcrichton
2020-08-25For VxWorks:Pang, Baoshan-14/+5
fix building errors use wr-c++ as linker
2020-08-21Make raw standard stream constructors constTomasz Miąsko-3/+3
2020-08-21Remove result type from raw standard streams constructorsTomasz Miąsko-7/+7
Raw standard streams constructors are infallible. Remove unnecessary result type.
2020-08-15inline linkingPrabakaran Kumaresshan-6/+2
2020-08-15remove empty linesPrabakaran Kumaresshan-7/+0
2020-08-15resolve commentsPrabakaran Kumaresshan-16/+8
2020-08-15Switch to intra-doc links in std/src/sys/vxworks/ext/{fs,process}.rsPrabakaran Kumaresshan-19/+19
2020-07-27mv std libs to library/mark-0/+4805