Go to the source code of this file.
typedef struct _hostnameMsg hostnameMsg |
typedef struct _nodeTopoMsg nodeTopoMsg |
typedef struct _topoDoneMsg topoDoneMsg |
This scheme relies on using IP address to identify physical nodes written by Gengbin Zheng 9/2008.
last updated 10/4/2009 Gengbin Zheng added function CmiCpuTopologyEnabled() which retuens 1 when supported when not supported return 0 all functions when cputopology not support, now act like a normal non-smp case and all PEs are unique.
major changes 10/28/09 Gengbin Zheng
3/5/2010 Gengbin Zheng
int CmiNumCores | ( | void | ) |
Definition at line 57 of file cputopology.C.
References PUP::a, and PUP::b.
Referenced by _initCharm(), CmiInitCPUAffinity(), CmiSetCPUAffinity(), FuncCkLoop::createPThreads(), LrtsInitCpuTopo(), printTopology(), and XTTorusManager::XTTorusManager().
static void printTopology | ( | int | numNodes | ) | [static] |
Definition at line 238 of file cputopology.C.
References CmiHwlocTopologyLocal, CmiNumCores(), CmiPrintf(), CmiHwlocTopology::num_cores, CmiHwlocTopology::num_pus, and CmiHwlocTopology::num_sockets.
Referenced by cpuTopoHandler(), and LrtsInitCpuTopo().
static void cpuTopoHandler | ( | void * | m | ) | [static] |
Definition at line 259 of file cputopology.C.
References CmiAlloc(), CmiFree(), Converse::CmiSyncBroadcastAllAndFree(), CmmEntries(), CmmFree(), CmmNew(), CmmPut(), hostTable, int, _procInfo::ip, msg, _hostnameMsg::n, _procInfo::nodeID, _nodeTopoMsg::nodes, _procInfo::pe, printTopology(), _hostnameMsg::procs, _procInfo::rank, tag, and CpuTopoDetails::topomsg.
Referenced by LrtsInitCpuTopo().
static void topoDoneHandler | ( | void * | m | ) | [static] |
Definition at line 311 of file cputopology.C.
References CmiLock(), CmiUnlock(), CpuTopoDetails::topoDone, and CpuTopoDetails::topoLock.
Referenced by LrtsInitCpuTopo().
static void cpuTopoRecvHandler | ( | void * | msg | ) | [static] |
Definition at line 318 of file cputopology.C.
References CmiFree(), CmiLock(), CmiUnlock(), CpuTopoDetails::cpuTopo, CpuTopoDetails::done, PUP::m, CpuTopology::nodeIDs, _nodeTopoMsg::nodes, CpuTopology::sort(), and CpuTopoDetails::topoLock.
Referenced by LrtsInitCpuTopo().
Definition at line 337 of file cputopology.C.
References CmiAlloc(), PUP::m, msg, _hostnameMsg::n, n, and _hostnameMsg::procs.
Referenced by LrtsInitCpuTopo().
Definition at line 364 of file cputopology.C.
References CmiAlloc(), CmiLock(), CmiMyPe(), CmiUnlock(), msg, CpuTopoDetails::topoDone, and CpuTopoDetails::topoLock.
Referenced by LrtsInitCpuTopo().
int LrtsCpuTopoEnabled | ( | ) |
Definition at line 379 of file cputopology.C.
References CpuTopology::supported.
Referenced by CmiCpuTopologyEnabled().
Definition at line 384 of file cputopology.C.
References CmiNodeOf(), CpuTopoDetails::cpuTopo, CpuTopology::nodeIDs, and CpuTopology::supported.
Referenced by CmiPeOnSamePhysicalNode().
int LrtsNumNodes | ( | ) |
Definition at line 392 of file cputopology.C.
References CpuTopoDetails::cpuTopo, CpuTopology::numUniqNodes(), and CpuTopology::supported.
Referenced by CmiNumPhysicalNodes().
Definition at line 398 of file cputopology.C.
References CpuTopology::bynodes, CmiNodeSize(), CpuTopoDetails::cpuTopo, int, and CpuTopology::supported.
Referenced by CmiNumPesOnPhysicalNode().
Definition at line 404 of file cputopology.C.
References CpuTopology::bynodes, and CpuTopoDetails::cpuTopo.
Referenced by CmiGetPesOnPhysicalNode().
Definition at line 410 of file cputopology.C.
References CpuTopology::bynodes, CmiRankOf(), CpuTopoDetails::cpuTopo, CpuTopology::nodeIDs, npes, rank, and CpuTopology::supported.
Referenced by CmiPhysicalRank().
Definition at line 421 of file cputopology.C.
References CmiNodeOf(), CpuTopoDetails::cpuTopo, CpuTopology::nodeIDs, and CpuTopology::supported.
Referenced by CmiPhysicalNodeID().
Definition at line 428 of file cputopology.C.
References CpuTopology::bynodes, CmiNodeFirst(), CpuTopoDetails::cpuTopo, and CpuTopology::supported.
Referenced by CmiGetFirstPeOnPhysicalNode().
void LrtsInitCpuTopo | ( | char ** | argv | ) |
Definition at line 435 of file cputopology.C.
References CpuTopoDetails::_noip, PUP::a, PUP::b, BGConverse::BgNodeRank(), c, CcdRaiseCondition(), Converse::CkNumPes(), CmiAlloc(), CmiBarrier(), CmiCreateLock(), CmiGetArgFlagDesc(), CmiLock(), CmiMyPe(), CmiMyRank(), CmiNodeAllBarrier(), CmiNodeOf(), CmiNumCores(), CmiNumSpanTreeChildren(), CmiPrintf(), CmiReduce(), CmiRegisterHandler(), CmiUnlock(), CmiWallTimer(), combineMessage(), TopoManager::coordinatesToRank(), CpuTopoDetails::cpuTopo, cpuTopoHandler(), cpuTopoRecvHandler(), CsdSchedulePoll(), PUP::d, CpuTopoDetails::done, emptyReduction(), getXTNodeID(), msg, _hostnameMsg::n, CpuTopology::nodeIDs, CpuTopology::numNodes, CpuTopology::numPes, CpuTopology::print(), printTopology(), _hostnameMsg::procs, TopoManager::rankToCoordinates(), skt_innode_my_ip(), skt_my_ip(), CpuTopology::sort(), startT, CpuTopology::supported, PUP::t, tmgr, CpuTopoDetails::topoDone, topoDoneHandler(), and CpuTopoDetails::topoLock.
Referenced by CmiInitCPUTopology().
int CmiCpuTopologyEnabled | ( | void | ) |
Definition at line 672 of file cputopology.C.
References LrtsCpuTopoEnabled().
Referenced by _initCharm(), and CmiCheckAffinity().
Definition at line 676 of file cputopology.C.
References LrtsPeOnSameNode().
Referenced by CmiInterSendNetworkFunc(), and findTransferMode().
int CmiNumPhysicalNodes | ( | void | ) |
Definition at line 680 of file cputopology.C.
References LrtsNumNodes().
Referenced by CkMemCheckPT::BuddyPE(), CkMemCheckPT::CkMemCheckPT(), ST_RecursivePartition< Iterator >::initPhyNodes(), CkMemCheckPT::isMaster(), KLevelTree::KLevelTree(), LBTOPO_MACRO(), ThreeLevelTree::ThreeLevelTree(), and TopoManager::TopoManager().
Definition at line 684 of file cputopology.C.
References LrtsNodeSize().
Referenced by CmiCheckAffinity(), CmiSendMessagePxshm(), TopoManager::coordinatesToRank(), topo::getSpanningTreeStrategy(), CkMemCheckPT::isMaster(), LBTOPO_MACRO(), and TopoManager::TopoManager().
Definition at line 688 of file cputopology.C.
References LrtsPeOnNode().
Referenced by _initCharm(), CkMemCheckPT::BuddyPE(), topo::impl::buildNextGen_nodeAware_minBytes(), topo::impl::buildNextGen_nodeAware_minGens(), and LBTOPO_MACRO().
Definition at line 692 of file cputopology.C.
References LrtsRankOf().
Referenced by CkMemCheckPT::BuddyPE(), LBTOPO_MACRO(), and TopoManager::rankToCoordinates().
Definition at line 696 of file cputopology.C.
References LrtsNodeOf().
Referenced by AMPI_API_IMPL(), CkMemCheckPT::BuddyPE(), topo::impl::buildNextGen_nodeAware_minBytes(), topo::impl::buildNextGen_nodeAware_minGens(), CmiCheckAffinity(), CmiInitCPUAffinity(), CmiSendMessagePxshm(), topo::getSpanningTreeStrategy(), ST_RecursivePartition< Iterator >::initPhyNodes(), CkMemCheckPT::isMaster(), LBTOPO_MACRO(), TopoManager::rankToCoordinates(), set_process_affinity(), and set_thread_affinity().
Definition at line 700 of file cputopology.C.
References LrtsNodeFirst().
Referenced by TopoManager::coordinatesToRank(), KLevelTree::KLevelTree(), LBTOPO_MACRO(), and ThreeLevelTree::ThreeLevelTree().