| Age | Commit message (Collapse) | Author | Lines |
|
This reverts #121666 due to #123495
This has already been done on master but beta needs something that will backport cleanly.
(cherry picked from commit 081ad8527d7b79e4761c497c12930e630de9a230)
|
|
|
|
Use the OS thread name by default if `THREAD_INFO` has not been initialized
Currently if `THREAD_INFO` hasn't been initialized then the name will be set to `None`. This PR changes it to use the OS thread name by default. This mostly affects foreign threads at the moment but we could expand this to make more use of the OS thread name in the future.
Note: I've only implemented `Thread::get_name` for windows, linux and macos (and macos adjacent) targets. The rest just return `None`.
|
|
|
|
Delete architecture-specific memchr code in std::sys
Currently all architecture-specific memchr code is only used in `std::io`. Most of the actual `memchr` capacity exposed to the user through the slice API is instead implemented in `core::slice::memchr`.
Hence this commit deletes `memchr` from `std::sys[_common]` and replace calls to it by calls to `core::slice::memchr` functions. This deletes `(r)memchr` from the list of symbols linked to libc.
The interest of putting architecture specific code back in core is linked to the discussion to be had in #113654
|
|
Improve UEFI stdio
Fixed some things suggested in last PR: #116207
cc `@dvdhrm`
cc `@nicholasbishop`
|
|
Currently all architecture-specific memchr code is only used in
`std::io`. Most of the actual `memchr` capacity exposed to the user
through the slice API is instead implemented in core::slice::memchr.
Hence this commit deletes memchr from std::sys[_common] and replace
calls to it by calls to core::slice::memchr functions. This deletes
(r)memchr from the list of symbols linked to libc.
|
|
|
|
Use generic `NonZero` internally.
Tracking issue: https://github.com/rust-lang/rust/issues/120257
|
|
Implement Instant for UEFI
- Uses Timestamp Protocol if present. Else use rdtsc for x86 and x86-64
|
|
|
|
|
|
- Uses Timestamp Protocol if present. Else use rdtsc for x86 and x86-64
Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
|
|
Since UEFI has no concept of threads, most of this module can be
ignored. However, implementing parts that make sense.
- Implement sleep
- Implement available_parallelism
Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
|
|
Move path implementations into `sys`
Part of #117276.
r? `@ChrisDenton`
|
|
- Uses SystemTable->RuntimeServices->GetTime()
Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
|
|
|
|
|
|
- is_ebadf always returns false
- Allow reading partial characters to buffer
- Allow full UTF-16 in stdin
Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
|
|
Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
|
|
- Do not drop any character while reading
- eabdf == Unsupported status
- loop untill read character or error encountered
Signed-off-by: Ayush Singh <ayushdevel1325@gmail.com>
|
|
|
|
|
|
|