[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Simulavr-devel] GDB to stdin connection & threading
From: |
David Madden |
Subject: |
Re: [Simulavr-devel] GDB to stdin connection & threading |
Date: |
Sun, 29 Jan 2012 12:01:16 -0800 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:9.0) Gecko/20111222 Thunderbird/9.0.1 |
On 1/29/2012 11:54, Petr Hluzín wrote:
all communication-capable classes would put
event objects (Windows) or file descriptors (Unixes) to a central
location which would do WaitForMultipleObjects() or select() on them.
It's been a long (LONG!) time since I did this stuff, but IIRC, that was
the best option I could come up with back in the day. Windows and Unix
are different in an inconvenient way right here (although the Windows
model works fine, more or less; it's really not as stupid as my younger
self thought it was!)
If you run communications through a central thread as you propose, you
can get the semantics you want relatively easily on either platform.
(The downside is code tweaking that may happen in a lot of places.)
Regards,
--
Mersenne Law LLC · www.mersenne.com · +1-503-679-1671
- Small Business, Startup and Intellectual Property Law -
1500 SW First Ave. · Suite 1170 · Portland, Oregon 97201