Re: MDI with child windows controlled by processes?
"L.Allan" <l.allan@worldnet.att.net> wrote in message
news:u8XYLCBRIHA.3400@TK2MSFTNGP03.phx.gbl...
I'm trying to update an SDI app so that it can take advantage of
multi-core cpu's to do parallel searching of 2 to 20+ relatively large
files. The searching is independent enough that separate processes work
well, and this relatively inexperienced multi-threader has found this
simpler to get sort-of-working than a threaded-approach with one process
and several threads.
I'm considering an approach that involves MDI, with a child window for
each of the files being searched. However, I'm fuzzy on whether the child
windows can be associated with separate processes.
Here is a scenario:
The "parent" would get the specifications for the search ... such as
case-insensitive regex for "first.+second.+(third|fourth)". Then it would
somehow or other broadcast this spec to the child processes, with the
results displayed in the child windows. The "parent" only needs to be
informed when all the "children" are done ... everything else is
indepedent.
Does this sound feasible ... or flawed? How would I get started to try it
out?
(I've mostly used SDI and Dialog-based applications, and am relatively
inexperienced with MDI-based apps.)
I would keep just one app and create secondary threads that perform the
searches and post results to the primary UI thread which updates the result
windows. I thought multi-core CPU's would be able to multitask a single app
with multiple threads. Is this true, or does Windows only use multi-cores
for separate processes?
-- David