Skip to Content.
Sympa Menu

charm - Re: [charm] [ppl] Message not making it

charm AT lists.cs.illinois.edu

Subject: Charm++ parallel programming system

List archive

Re: [charm] [ppl] Message not making it


Chronological Thread 
  • From: Ehsan Totoni <totoni2 AT illinois.edu>
  • To: "Geoff D. Hilyard" <gdhilyard AT RegalDecision.com>
  • Cc: "charm AT cs.uiuc.edu" <charm AT cs.uiuc.edu>
  • Subject: Re: [charm] [ppl] Message not making it
  • Date: Wed, 19 Sep 2012 08:43:10 -0500
  • List-archive: <http://lists.cs.uiuc.edu/pipermail/charm/>
  • List-id: CHARM parallel programming system <charm.cs.uiuc.edu>

Hi Geoff,

Seems like your program conflicts with some of the fundamental concepts of Charm++. "gridPointArray[iGridPointNumber].SetVars(tmpMessage)" is not a C++ function call, but an asynchronous method invocation. When you make this call in the simple scenario of standalone mode, that entry method call will be put on the queue of the scheduler. The scheduler will run that entry method when it gets a chance, but you don't give it a chance! Your Main classes entry method never gets finished because of the infinite loop. Note that in Charm++, an entry method runs until completion. You can remove the infinite loop and add a reduction to your setvars method after completion. Please take a look at the Charm++ examples, e.g. 1darray hello.

Good luck,
-Ehsan

On Sep 19, 2012, at 7:30 AM, Geoff D. Hilyard wrote:

 
Hello charm users.  I’m back J
 
I’ve progressed a bit further than last time, but I’ve hit another wall.
 
My test program is trying to read in ( from a binary file ) grid x,y,z locations ( among other stuff ) for about 6000 grid points.  As a test, I’m making each their own chare ( CCharmGridPoint, with CProxy_CCharmGridPoint being used for my array ).  I’m using CkPrintf in several places, just to make sure things are making it to where its suppose to be, and that correct values are being set.  In my CCharmEntry class ( My “Main” class ), I am reading in the number of grid points.  I make an array of grid points using CCharmGridPoint::ckNew ( numGridPoints ).  In my next step, I loop on the number of grid points and call ReadFromFile ( A protected function of CCharmEntry ).  This function reads the values from the file, puts them into a message ( class msgSetGridPointValues ), and calls gridPointArray[iGridPointNumber].SetVars(tmpMessage).  If I have a CkPrintf statement BEFORE and after, they are correctly printed out in the Cygwin window.  However, any CkPrintf statements inside CCharmGridPoint::SetVars ( msgSetGridPointValues * theMessage ) will never be printed, even if it’s the very first line.  Everything appears to be setup correctly with the corresponding .CI files.  I have also put a CkPrintf statement after the loop, and that will print out just fine.
 
Shouldn’t a CkPrintf echo something to the screen?  Since I’m using “standalone mode”, there are no network issues to use, and only one processor.  I can’t think of why the message wouldn’t get to the gridpoint in question.  I’m pretty sure the function is not being called in the first place.  I have a loop after reading the files where I wait for all grid points to report back that they are done.  The counter never get incremented, and so it gets stuck in an infinite loop.
 
Any help is appreciated.
 
Geoff Hilyard
Lead Softward Developer
Regal Decision Systems, Inc.
_______________________________________________
charm mailing list
charm AT cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/charm
_______________________________________________
ppl mailing list
ppl AT cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/ppl




Archive powered by MHonArc 2.6.16.

Top of Page