]> git.proxmox.com Git - rustc.git/blob - vendor/crossbeam-queue/README.md
New upstream version 1.47.0+dfsg1
[rustc.git] / vendor / crossbeam-queue / README.md
1 # Crossbeam Queue
2
3 [![Build Status](https://travis-ci.org/crossbeam-rs/crossbeam.svg?branch=master)](
4 https://travis-ci.org/crossbeam-rs/crossbeam)
5 [![License](https://img.shields.io/badge/license-MIT%2FApache--2.0-blue.svg)](
6 https://github.com/crossbeam-rs/crossbeam-queue/tree/master/src)
7 [![Cargo](https://img.shields.io/crates/v/crossbeam-queue.svg)](
8 https://crates.io/crates/crossbeam-queue)
9 [![Documentation](https://docs.rs/crossbeam-queue/badge.svg)](
10 https://docs.rs/crossbeam-queue)
11 [![Rust 1.28+](https://img.shields.io/badge/rust-1.28+-lightgray.svg)](
12 https://www.rust-lang.org)
13 [![chat](https://img.shields.io/discord/569610676205781012.svg?logo=discord)](https://discord.gg/BBYwKq)
14
15 This crate provides concurrent queues that can be shared among threads:
16
17 * [`ArrayQueue`], a bounded MPMC queue that allocates a fixed-capacity buffer on construction.
18 * [`SegQueue`], an unbounded MPMC queue that allocates small buffers, segments, on demand.
19
20 [`ArrayQueue`]: https://docs.rs/crossbeam-queue/*/crossbeam_queue/struct.ArrayQueue.html
21 [`SegQueue`]: https://docs.rs/crossbeam-queue/*/crossbeam_queue/struct.SegQueue.html
22
23 ## Usage
24
25 Add this to your `Cargo.toml`:
26
27 ```toml
28 [dependencies]
29 crossbeam-queue = "0.2"
30 ```
31
32 Next, add this to your crate:
33
34 ```rust
35 extern crate crossbeam_queue;
36 ```
37
38 ## Compatibility
39
40 The minimum supported Rust version is 1.28. Any change to this is considered a breaking change.
41
42 ## License
43
44 Licensed under either of
45
46 * Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)
47 * MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)
48
49 at your option.
50
51 #### Contribution
52
53 Unless you explicitly state otherwise, any contribution intentionally submitted
54 for inclusion in the work by you, as defined in the Apache-2.0 license, shall be
55 dual licensed as above, without any additional terms or conditions.
56
57 #### Third party software
58
59 This product includes copies and modifications of software developed by third parties:
60
61 * [src/array_queue.rs](src/array_queue.rs) is based on
62 [Bounded MPMC queue](http://www.1024cores.net/home/lock-free-algorithms/queues/bounded-mpmc-queue)
63 by Dmitry Vyukov, licensed under the Simplified BSD License and the Apache License, Version 2.0.
64
65 See the source code files for more details.
66
67 Copies of third party licenses can be found in [LICENSE-THIRD-PARTY](LICENSE-THIRD-PARTY).