I have been reading the Lifeline Global Load Balancing Paper (the paper is available on the link http://www.cs.columbia.edu/~martha/courses/4130/au12/p201-saraswat.pdf). I am new to x10 language. I am actually confused between the terminology of places and workers. As far as I can comprehend, places are different nodes in a distributed system, and workers are threads (or processes, I don't know) on these places. Am I right?
Also, in addition to this, what is the core difference between the environment variables X10_NUM_THREADS
and X10_STATIC_THREADS
? I know that these are the way to implement the workers in x10. But how do we implement this in APGAS framework for Java? Do we use the same variables in Java as well?
Thanks in advance
Your understanding that places are nodes in a distributed system and workers are threads is essentially correct. The paper is a little confusing in that it imposes an arbitrary restriction of one worker per place.
The environment variable
X10_NUM_THREADS
controls how many worker threads should be active at each X10 place. The X10 runtime may start additional threads at a place to replace threads that are waiting on long-running blocking operations, for example, remote activities started usingat(Place(p)) { ... }
. Once the blocking operation is complete, the runtime will attempt to reduce the number of active threads to ensure that there are alwaysX10_NUM_THREADS
are actively executing (or available to execute) activities at each place.The environment variable
X10_STATIC_THREADS
stops X10 from creating additional worker threads as described above. This is necessary on some architectures that don't support dynamic thread creation, like the Blue Gene/P used in the Lifeline-based Global Load Balancing Paper. For more typical architectures e.g. clusters of x86-based nodes, this variable would not usually be set.In the APGAS library for Java, the environment variable
APGAS_THREADS
controls the number of threads for each place. I don't believe there's any equivalent toX10_STATIC_THREADS
.