comp.lang.ada
 help / color / mirror / Atom feed
From: "Bobby D. Bryant" <bdbryant@mail.utexas.edu>
Subject: Q re glade for slaves.
Date: Sun, 08 Apr 2001 09:56:07 +0600
Date: 2001-04-08T15:54:23+00:00	[thread overview]
Message-ID: <3ACFE157.E58FF313@mail.utexas.edu> (raw)

I've just started in on distributed programming, and I can modify some
of the gnat-glade examples to do what I need (structurally), but the
solution I came up with doesn't seem very elegant, so I wonder if anyone
has a better suggestion before I get too far in to it.

I need a master and some number of slaves.  The slaves will all execute
identical code on different data, and their work is very CPU-intensive,
so I would like to run each slave on a different processor.  In most
cases I will simply let the number of processors available dictate the
number of slaves to be used.  The master will communicate with the
slaves intermittently while the distributed job runs, and do a bit of
collation when the slaves are all finished with their share of the
work.  The slaves do not need to share any common state.  (FYI, this is
not a non-terminating server system; rather, for each run of the job it
will start, run for a few hours, and be finished.)

The solution that I came up with is to create a generic package for the
common code for the slaves, create an instance of that package for each
slave, and have the .cfg file assign each instance to a different
processor.  However, since the Remote_Call_Interface pragma seems to
apply to library units rather than to instances of a generic package
that can be created at run time, my solution means I have to decide in
advance how many slaves I want, and provide a separate file to
instantiate each one.

This is not a show-stopper, because changing the number of slaves this
way is a very small amount of work.  However, I would be surprised if
something more flexible is not possible.  Am I missing something?

Thanks,

Bobby Bryant
Austin, Texas





             reply	other threads:[~2001-04-08  3:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-08  3:56 Bobby D. Bryant [this message]
2001-04-08 20:46 ` Q re glade for slaves Wilhelm Spickermann
2001-04-08 18:40   ` Bobby D. Bryant
2001-04-09 12:11     ` Wilhelm Spickermann
2001-04-09  2:37       ` Bobby D. Bryant
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox