[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Need advice on using threads
- Subject: Need advice on using threads
- From: DOYLE@SISU.MGH.HARVARD.EDU
- Date: 16 May 1993 13:20:34 -0500 (EST)
Greetings!
I need some advice on incorporating some functionality from
the new threads manager into our product. I know that this will
be built into MCL, but I may need it sooner. I know that building
threads into MCL itself is too hard a problem (for me at least!),
but I think I can use something simpler.
Most of the areas where I need to use threads are in networking, image
processing, and driver routines. These portions of my system are written in
C (MCL uses them either via the component manager or the foreign function
interface).
I believe I have two alternatives:
1. Make MCL the main thread and use *eventhook* (and perhaps certain
state transistions) for yielding time to the other lightweight tasks
which are written in C.
2. Create a background C application which used threads and would
communicate with MCL via AppleEvents.
I would prefer alternative #1 since less would have to be implemented, and
after MCL supported threads the code could be folded back into MCL.
Suggestions? Thanks!
Sean Doyle
RSTAR, Inc.
doyle@sisu.mgh.harvard.edu