#generational-arena #generational #arena #reservation #key #thread #across

atomic-arena

Generational arena allows reserving keys from other threads

2 releases

0.1.1 May 15, 2022
0.1.0 Nov 28, 2021

#457 in Concurrency

Download history 1454/week @ 2024-07-22 1611/week @ 2024-07-29 1592/week @ 2024-08-05 1959/week @ 2024-08-12 1596/week @ 2024-08-19 1563/week @ 2024-08-26 1306/week @ 2024-09-02 1322/week @ 2024-09-09 1077/week @ 2024-09-16 1418/week @ 2024-09-23 1204/week @ 2024-09-30 719/week @ 2024-10-07 1588/week @ 2024-10-14 1236/week @ 2024-10-21 1640/week @ 2024-10-28 1114/week @ 2024-11-04

5,671 downloads per month

MIT/Apache

29KB
730 lines

atomic-arena

crates.io | docs

atomic-arena is a generational arena that uses a reservation system to allow getting valid keys from different threads.

License

This project is licensed under either of

  • Apache License, Version 2.0 (LICENSE-APACHE)
  • MIT license (LICENSE-MIT)

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in atomic-arena by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.


lib.rs:

atomic_arena provides a generational Arena that you can reserve a [Key] for ahead of time using a Controller. Controllers are backed by atomics, so they can be cloned and used across threads and still have consistent state.

This is useful when you want to insert an item into an Arena on a different thread, but you want to have a valid [Key] for that item immediately on the current thread.

No runtime deps