Handmade Hero»Forums»Code
Marius Adaškevičius
22 posts
IO completion ports explanation
This is probably a bit off-topic but maybe someone has a link to Casey's explanation of IO completion ports on one of Shawn McGrath streams? I found it really informative but I don't think Shawn has uploaded it to YouTube as promised and it's not available on Twitch anymore :(
Magnus
1 posts
None
IO completion ports explanation
Hello Marius,

I was looking for that myself a month or so ago but figured that I had delted the twitch VOD but your question prompted me to have another look. Apparently it was not lost.

Here's the audio for the io completion ports portion: sssmcgrath_cmuratori_io_completion_ports.ogg

I'll check with sssmcgrath if he wants to put up the whole video.

Regards,
Magnus
Marius Adaškevičius
22 posts
IO completion ports explanation
Thank you, Magnus!
Shawn McGrath
1 posts
IO completion ports explanation
I'm like 99% sure I posted that video on youtube but I can't find it =/ I'll gladly upload any missing videos.
Casey Muratori
801 posts / 1 project
Casey Muratori is a programmer at Molly Rocket on the game 1935 and is the host of the educational programming series Handmade Hero.
IO completion ports explanation
There is one downside to IO completion ports, which is unfortunate, which is that you cannot use an IO completion port handle in a call to WaitForMultipleObjects :( I have no idea why they didn't implement this. Probably because they maybe didn't realize how good the API was? Maybe they just lucked into it? I don't know.

- Casey
vivek
1 posts
None
IO completion ports explanation
How Can I subscribe to this thread??
Andrew Chronister
194 posts / 1 project
Developer, administrator, and style wrangler
IO completion ports explanation
typedefstructer
How Can I subscribe to this thread??


No way at the moment, we'll have something for you in the next couple weeks.
Carlos Gabriel Hasbun Comandari
35 posts
|· noise ·|
IO completion ports explanation
"Please note that while the packets are queued in FIFO order they may be dequeued in a different order."

·| What on earth does that mean?
511 posts
IO completion ports explanation
gazto
"Please note that while the packets are queued in FIFO order they may be dequeued in a different order."

·| What on earth does that mean?


It means that not all IO operations complete in the same order as they were submitted.

Or if talking about UDP it's a property of the protocol that packets may arrive out of order (or not arrive at all).
Casey Muratori
801 posts / 1 project
Casey Muratori is a programmer at Molly Rocket on the game 1935 and is the host of the educational programming series Handmade Hero.
IO completion ports explanation
ratchetfreak
It means that not all IO operations complete in the same order as they were submitted.
Or if talking about UDP it's a property of the protocol that packets may arrive out of order (or not arrive at all).

I don't know if that is a reasonable explanation to OP's question though. Those are things that happen before the IOCP message gets queued, so I doubt that is what that line would have been talking about. The IO completion port does not have anything queued on it until an IO operation completes, and then it gets queued. So unless that sentence was just a very poor choice of words, it can't be talking about the fact that the IO's don't complete in order, because they are not queued on the port, only their completion is. Hence the name "IO completion port" :)

OP: Where'd that line come from, BTW?

- Casey
Carlos Gabriel Hasbun Comandari
35 posts
|· noise ·|
IO completion ports explanation
Edited by Carlos Gabriel Hasbun Comandari on
I found it to be weird because FIFO is supposed to mean "first in, first out", yet immediately after it is written: "they may be dequeued in a different order.", it's an oxymoron.

Source:
https://msdn.microsoft.com/en-us/...ws/desktop/aa365198(v=vs.85).aspx