queue and pipe的区别

xiaofk 2002-04-25 02:18:41
在任务间的通信中,队列和管道具体的用法和用途有什么区别吗?还有 管道提供了与队列互换的功能是什么意思?
...全文
289 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
xiaofk 2002-04-28
  • 打赏
  • 举报
回复
thanks!
liaojidong 2002-04-26
  • 打赏
  • 举报
回复
关注
xiaofk 2002-04-26
  • 打赏
  • 举报
回复
没有人知道吗?
mike_jiang_feng 2002-04-26
  • 打赏
  • 举报
回复
In vxworks, it seems it can not be realized that exchanging between pipe and queue. Still, from useage, they have many thing alike.
mike_jiang_feng 2002-04-26
  • 打赏
  • 举报
回复
Actually it is based upon your useage and OS system.
In vxworks,
"message queue" is the primary intertask communication mechanism. It is FIFO order. Any task and interrupt can send a message to a queue. Please note that full duplex communication between two tasks need two message queues.
"pipe" is a mechanism to let tasks to communicate with each other through the standard I/O interface. It can be read/write... For general meaning, pipe has more overhead than message queue because it use I/O lib. But pipe can allow a task to wait for data to be available on any of a set of I/O devices. So using pipe, a task can wait for data on a combination of several pipes, sockets and serial devices.
Message has more flexible options for timeouts and message priorities. Pipe can fit your complex need.

------Not very sure whether it can fit your want. And is there anyone knows about these two useage in other Embed-OS?

19,502

社区成员

发帖
与我相关
我的任务
社区描述
硬件/嵌入开发 嵌入开发(WinCE)
社区管理员
  • 嵌入开发(WinCE)社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧