aboutsummaryrefslogtreecommitdiff
path: root/embassy-sync
Commit message (Collapse)AuthorAgeFilesLines
...
* Update Rust nightly.Dario Nieuwenhuis2023-05-191-1/+0
|
* Release embassy-sync v0.2.0Dario Nieuwenhuis2023-04-132-1/+23
|
* executor,sync: add support for turbo-wakers.Dario Nieuwenhuis2023-03-305-42/+78
| | | | | | | | | | | | | | | | | | | | | | | | This is a `core` patch to make wakers 1 word (the task pointer) instead of 2 (task pointer + vtable). It allows having the "waker optimization" we had a while back on `WakerRegistration/AtomicWaker`, but EVERYWHERE, without patching all crates. Advantages: - Less memory usage. - Faster. - `AtomicWaker` can actually use atomics to load/store the waker, No critical section needed. - No `dyn` call, which means `cargo-call-stack` can now see through wakes. Disadvantages: - You have to patch `core`... - Breaks all executors and other things that create wakers, unless they opt in to using the new `from_ptr` API. How to use: - Run this shell script to patch `core`. https://gist.github.com/Dirbaio/c67da7cf318515181539122c9d32b395 - Enable `build-std` - Enable `build-std-features = core/turbowakers` - Enable feature `turbowakers` in `embassy-executor`, `embassy-sync`. - Make sure you have no other crate creating wakers other than `embassy-executor`. These will panic at runtime. Note that the patched `core` is equivalent to the unpached one when the `turbowakers` feature is not enabled, so it should be fine to leave it there.
* sync/pipe: update to clarify docs that it is byte-oriented.Dario Nieuwenhuis2023-03-261-28/+43
| | | | | There was some language copypasted from Channel talking about "messages" or "values", that is not really accurate with Pipe.
* perf(pubsub): Skip clone on last messageRasmus Melchior Jacobsen2023-03-211-4/+28
|
* fix(pubsub): Pop messages which count is 0 after unsubscribeRasmus Melchior Jacobsen2023-03-151-0/+47
|
* Add `#[must_use]` to all futuresGrant Miller2023-02-242-0/+6
|
* Remove unnecessary use of atomic-polyfill.Dario Nieuwenhuis2022-12-231-1/+0
| | | | Only use it when CAS is actually needed.
* sync: Fix nightly feature compilation after upgrade to embedded-io 0.4.0Gabriel Smith2022-11-272-57/+20
|
* Switch to async-fn-in-traitDario Nieuwenhuis2022-11-251-1/+1
|
* sync/signal: Implement Default for SignalMatt Johnston2022-11-221-0/+9
|
* Derive Default for WakerRegistrationMatt Johnston2022-11-061-1/+1
| | | | This simplifies creating arrays of WakerRegistrations
* Release embassy-sync, embassy-time v0.1.0Dario Nieuwenhuis2022-10-261-0/+3
|
* Update Rust nightly.Dario Nieuwenhuis2022-10-262-10/+10
|
* Forgot to add space function to immediate publisherDion Dokter2022-10-051-0/+8
|
* Add required info to embassy-sync packageUlf Lilleengen2022-10-042-2/+32
| | | | Updates the README.md based on embassy-futures structure.
* Went back to named futures but now with must_useDion Dokter2022-09-293-7/+8
|
* Futures in pub & sub are now awaited instead of returned for better user ↵Dion Dokter2022-09-293-5/+92
| | | | | | compiler diagnostics. Added functions for reading how many messages are available
* Remove default, reorder generic paramsivmarkov2022-09-251-9/+10
|
* Remove default, reorder generic paramsivmarkov2022-09-241-1/+0
|
* Parameterize Signal with RawMutexivmarkov2022-09-241-28/+41
|
* Replace futures::future::poll_fn -> core::future::poll_fn.Dario Nieuwenhuis2022-09-222-4/+3
|
* Update Rust nightly.Dario Nieuwenhuis2022-09-221-1/+1
| | | | Removes feature(generic_associated_types)
* Make rustfmt happyJoakim Hulthe2022-09-161-1/+3
|
* Add .into_inner() and .get_mut() to MutexJoakim Hulthe2022-09-161-0/+14
|
* sync/signal: wake old waker on overflow instead of panicking.Dario Nieuwenhuis2022-09-121-1/+5
| | | | | | This makes behavior consistent with `WakerRegistration`. It allows canceling `wait` in one task and then calling `wait` in another. If two tasks are `wait`ing concurrently the signal will be received by only one of them, randomly.
* Add missing std feature for embassy-syncUlf Lilleengen2022-08-291-0/+1
| | | | Fixes #930
* Add README for embassy-syncUlf Lilleengen2022-08-232-1/+13
|
* Fix warnings after crate splitUlf Lilleengen2022-08-231-2/+2
|
* sync: flatten module structure.Dario Nieuwenhuis2022-08-227-9/+6
|
* split `embassy-util` into `embassy-futures`, `embassy-sync`.Dario Nieuwenhuis2022-08-2218-0/+3219