Ejemplo n.º 1
0
/* unique numeric SMP-node identifier */
long vt_pform_node_id() {
#ifdef BGL_GROUP_ON_NODEBOARD
  return ((mybgl.location >> 6) & 0x1fff);
#else
  if ( BGLPersonality_virtualNodeMode(&mybgl) )
    return ( BGLPersonality_psetNum(&mybgl) *
           BGLPersonality_numNodesInPset(&mybgl) +
           BGLPersonality_rankInPset(&mybgl)) * 2
           + rts_get_processor_id();
  else
    return BGLPersonality_psetNum(&mybgl) *
           BGLPersonality_numNodesInPset(&mybgl) +
           BGLPersonality_rankInPset(&mybgl);
#endif
}
Ejemplo n.º 2
0
/** Rank in I/O  */
int DDI_BGL_File_IO_rank(DDI_Comm *comm) {
    BGLPersonality personality;

    rts_get_personality(&personality, sizeof(personality));
    return BGLPersonality_rankInPset(&personality);
}