Most Efficient FIFO Algorithm?
Most Efficient FIFO Algorithm?
- Subject: Most Efficient FIFO Algorithm?
- From: Chilton Webb <email@hidden>
- Date: Sun, 23 Jun 2002 07:46:30 -0500
I'm setting up a system that blocks on a socket waiting for data. As it
receives data, I want to immediately dump it into an arbitrary chunk of
memory and come back to look for more data. This is being done in a
pthread. On the 'other side', my app reads this data and processes it.
I'm looking for a mechanism that will allow me to hand off that data as
quickly as possible on the blocking side, though. Should I use an array
for that, or would it be faster/better to just manage one giant chunk of
data and create my own delimiter for marking the end of the data? Or
something else?
Any suggestions welcome, even ones from people who name their computers
with pronouns.
-Chilton
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.