00001 #include "cldb.h" 00002 /* for sqrt() */ 00003 #include <math.h> 00004 00005 typedef struct loadmsg_s { 00006 char header[CmiMsgHeaderSizeBytes]; 00007 int pe, load; 00008 #if ! USE_MULTICAST 00009 short fromindex, toindex; 00010 struct loadmsg_s *next; 00011 #endif 00012 } loadmsg; 00013 00014 /* work request message when idle */ 00015 typedef struct requestmsg_s { 00016 char header[CmiMsgHeaderSizeBytes]; 00017 int from_pe; 00018 int to_rank; 00019 } requestmsg; 00020 00021 typedef struct CldNeighborData_s 00022 { 00023 int pe, load; 00024 #if ! USE_MULTICAST 00025 int index; // my index on this neighbor 00026 #endif 00027 } *CldNeighborData; 00028 00029 CpvDeclare(CldNeighborData, neighbors); 00030 CpvDeclare(CmiGroup, neighborGroup); 00031 CpvDeclare(int, numNeighbors);