CreateIoCompletionPort C#等价物 [英] CreateIoCompletionPort C# equivalent

查看:82
本文介绍了CreateIoCompletionPort C#等价物的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我很奇怪...... C#CreateIoCompletionPort等价物是什么?是否有托管IO完成机制?我可以将'System.Net.Sockets''与IOCompletion端口结合使用吗?

任何指针或样品都会被评估...


Nadav
http://www.ddevel.com

推荐答案

Nadav,


BeginSend / EndSend,BeginReceive / EndReceive方法使用IO完成

端口他们的异步实现。


希望这会有所帮助。

-

- Nicholas Paldino [.NET / C#MVP]

- mv*@spam.guard.caspershouse.com


Nadav <的Na *** @ discussions.microsoft.com>在消息中写道

新闻:DA ********************************** @ microsof t.com ...
Nadav,

The BeginSend/EndSend, BeginReceive/EndReceive methods use IO completion
ports for their asynchronous implementation.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Nadav" <Na***@discussions.microsoft.com> wrote in message
news:DA**********************************@microsof t.com...


我想知道...... C#CreateIoCompletionPort等价物是什么?是否有
托管IO完成机制?我可以在

组合中使用''System.Net.Sockets''和IOCompletion端口吗?任何指针或样品都会受到限制......

Nadav
http ://www.ddevel.com



感谢您立即回复,但是,我还没有找到提供作为IO完成端口的SAME功能:使用完成端口可以将多个文件句柄(例如文件,套接字,标准输出,......)绑定到单个端口,通过这样做,系统将使用单个线程(或多个线程)对于相关句柄的所有异步任务,相当于处理器的数量,这将通过减少完成的上下文切换量来实现最佳性能...


使用BeginSend / BeginRecieve可以(内部)使用IO完成机制但是不能为多个异步任务启用[SINGLE] IO完成端口,SOooo它不符合上述相同的方式......我该怎么办实现功能刚刚使用.NET框架描述的实际情况????任何指针/样品或想法将不胜感激。


Nadav
http://www.ddevel.com

" Nicholas Paldino [.NET / C#MVP]"写道:
Thanks for the immediate response, Still, I didn''t find any class that provide the SAME functionality as an IO Completion port: using a completion port one may bind several File handles ( e.g. file, socket, stdout, ... ), to a single port, by doing so the system will use a single thread ( or multiple threads, equivalent to the amount of processors ) for all async tasks for the associated handles, this will achieve best performance by decreasing the amount of context-switches done...

Usage of BeginSend/BeginRecieve may ( internally ) use the IO Completion mechanism BUT doesn''t enable the usage of a [SINGLE] IO Completion port for several asynchronous tasks, SOooo it doesn''t fit the same manner described above... what should I do to achieve the functionality just described using the .NET framework???? any pointers/samples or ideas will be appreciated.

Nadav
http://www.ddevel.com

"Nicholas Paldino [.NET/C# MVP]" wrote:
Nadav,


BeginSend / EndSend,BeginReceive / EndReceive方法使用IO完成端口进行异步实现。

希望这会有所帮助。

-
- Nicholas Paldino [.NET / C#MVP]
- mv*@spam.guard.caspershouse.com

Nadav <的Na *** @ discussions.microsoft.com>在消息中写道
新闻:DA ********************************** @ microsof t.com。 ..
Nadav,

The BeginSend/EndSend, BeginReceive/EndReceive methods use IO completion
ports for their asynchronous implementation.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Nadav" <Na***@discussions.microsoft.com> wrote in message
news:DA**********************************@microsof t.com...


我不知道...... C#CreateIoCompletionPort等价于什么?是否有
Hi,

I Wonder... What is the C# CreateIoCompletionPort equivalent? is there a


托管IO完成机制?我可以使用''System.SNet.Sockets''与IOCompletion端口组合吗?


managed IO completion mechanism? can I use ''System.Net.Sockets'' in
combination with an IOCompletion port?

任何指针或样品都会被评估...

Nadav
http://www.ddevel.com
Any pointers or samples will be appriciated...

Nadav
http://www.ddevel.com



感谢您的立即响应,我还没有找到任何提供相同功能的类作为IO完成端口:使用完成端口1可以将多个文件句柄(例如文件,套接字,标准输出,...)绑定到单个端口,通过这样做,系统将使用单个线程(或多个线程,相当于处理器的数量)用于所有异步关联句柄的任务,这将通过减少完成的上下文切换量来实现最佳性能...

使用BeginSend / BeginRecieve可以(内部)使用IO完成机制但是不能使用[SINGLE] IO Comple几个异步任务的端口,SOooo它不符合上面描述的相同方式......我应该怎样做才能实现刚刚使用.NET框架描述的功能?任何指针/样品或想法将不胜感激。


Nadav
http://www.ddevel.com

" Nicholas Paldino [.NET / C#MVP]"写道:
Thanks for the immediate response, Still, I didn''t find any class that provide the SAME functionality as an IO Completion port: using a completion port one may bind several File handles ( e.g. file, socket, stdout, ... ), to a single port, by doing so the system will use a single thread ( or multiple threads, equivalent to the amount of processors ) for all async tasks for the associated handles, this will achieve best performance by decreasing the amount of context-switches done...

Usage of BeginSend/BeginRecieve may ( internally ) use the IO Completion mechanism BUT doesn''t enable the usage of a [SINGLE] IO Completion port for several asynchronous tasks, SOooo it doesn''t fit the same manner described above... what should I do to achieve the functionality just described using the .NET framework???? any pointers/samples or ideas will be appreciated.

Nadav
http://www.ddevel.com

"Nicholas Paldino [.NET/C# MVP]" wrote:
Nadav,


BeginSend / EndSend,BeginReceive / EndReceive方法使用IO完成端口进行异步实现。

希望这会有所帮助。

-
- Nicholas Paldino [.NET / C#MVP]
- mv*@spam.guard.caspershouse.com

Nadav <的Na *** @ discussions.microsoft.com>在消息中写道
新闻:DA ********************************** @ microsof t.com。 ..
Nadav,

The BeginSend/EndSend, BeginReceive/EndReceive methods use IO completion
ports for their asynchronous implementation.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Nadav" <Na***@discussions.microsoft.com> wrote in message
news:DA**********************************@microsof t.com...


我不知道...... C#CreateIoCompletionPort等价于什么?是否有
Hi,

I Wonder... What is the C# CreateIoCompletionPort equivalent? is there a


托管IO完成机制?我可以使用''System.SNet.Sockets''与IOCompletion端口组合吗?


managed IO completion mechanism? can I use ''System.Net.Sockets'' in
combination with an IOCompletion port?

任何指针或样品都会被评估...

Nadav
http://www.ddevel.com
Any pointers or samples will be appriciated...

Nadav
http://www.ddevel.com



这篇关于CreateIoCompletionPort C#等价物的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆