pthread同步阻塞队列
我正在寻找使用 pthread 同步语义的 C 线程安全阻塞队列(多生产者/消费者)的推荐实现。
I'm looking for a recommended implementation of a thread-safe blocking queue (multi producer/consumer) in C using pthread synchronization semantics.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这是我使用的
threadqueue.h
threadqueue.c
Here's one I use
threadqueue.h
threadqueue.c
尝试 APR 队列。它由 apache Web 服务器使用并且经过了很好的测试。
http://apr.apache.org/docs/apr-util/1.3 /apr__queue_8h.html
Try APR queues. It's used by the apache web server and pretty well tested.
http://apr.apache.org/docs/apr-util/1.3/apr__queue_8h.html