Skip to Content.
Sympa Menu

charm - Re: [charm] help with virtual processor and physical processos

charm AT lists.cs.illinois.edu

Subject: Charm++ parallel programming system

List archive

Re: [charm] help with virtual processor and physical processos


Chronological Thread 
  • From: Laércio Lima Pilla <llpilla AT inf.ufrgs.br>
  • To: Sabrina Bergoch <sabrinabms AT gmail.com>
  • Cc: "charm AT cs.uiuc.edu" <charm AT cs.uiuc.edu>
  • Subject: Re: [charm] help with virtual processor and physical processos
  • Date: Fri, 19 Dec 2014 10:09:19 -0200
  • List-archive: <http://lists.cs.uiuc.edu/pipermail/charm/>
  • List-id: CHARM parallel programming system <charm.cs.uiuc.edu>

Sabrina,

Each chare on a chare array has its identifiers on "thisIndex". Multidimensional arrays (2D and up) have thisIndex.x, thisIndex.y, etc.
For the processor, you can call "CkMyPe()".

For a 1D chare array, your output would be something like 

std::cout << "(2)Hello, World! from -  rank:"<< thisIndex <<"- pid:"<< CkMyPe() <<endl;

Best regards,

2014-12-19 9:52 GMT-02:00 Sabrina Bergoch <sabrinabms AT gmail.com>:

Hello,

 

In AMPI you can easily identify the virtual processor and physical processor, as shown below:

 

MPI_Comm_rank(MPI_COMM_WORLD, &myrank);

pid = getpid();

std::cout << "(2)Hello, World! from -  rank:"<< myrank <<"- pid:"<< pid<<endl;

 

How can I do something similar in charm++?


Regards,


Sabrina Sambatti


_______________________________________________
charm mailing list
charm AT cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/charm



--
Laércio Lima Pilla, PhD.
Associate Professor (Professor Adjunto)
UFSC - CTC - INE, Brazil
Tel: +55 (48) 9152 8120, +55 (48) 3721 7564




Archive powered by MHonArc 2.6.16.

Top of Page