#include <ReductionMgr.h>
Public Member Functions | |
| ReductionSetData * | getData (int seqNum) |
| ReductionSetData * | removeData (int seqNum) |
| ReductionSet (int setID, int size, int numChildren) | |
| ~ReductionSet () | |
Public Attributes | |
| int | reductionSetID |
| int | nextSequenceNumber |
| int | submitsRegistered |
| int | dataSize |
| ReductionSetData * | dataQueue |
| int | requireRegistered |
| int | threadIsWaiting |
| int | waitingForSequenceNumber |
| CthThread | waitingThread |
| int * | addToRemoteSequenceNumber |
|
||||||||||||||||
|
Definition at line 77 of file ReductionMgr.C. References addToRemoteSequenceNumber, dataQueue, dataSize, NAMD_bug(), nextSequenceNumber, reductionSetID, requireRegistered, submitsRegistered, and threadIsWaiting. 00077 {
00078 if ( setID == REDUCTIONS_BASIC ) {
00079 if ( size != -1 ) {
00080 NAMD_bug("ReductionSet size specified for REDUCTIONS_BASIC.");
00081 }
00082 size = REDUCTION_MAX_RESERVED;
00083 }
00084 if ( size == -1 ) NAMD_bug("ReductionSet size not specified.");
00085 dataSize = size;
00086 reductionSetID = setID;
00087 nextSequenceNumber = 0;
00088 submitsRegistered = 0;
00089 dataQueue = 0;
00090 requireRegistered = 0;
00091 threadIsWaiting = 0;
00092 addToRemoteSequenceNumber = new int[numChildren];
00093 }
|
|
|
Definition at line 95 of file ReductionMgr.C. References ReductionSetData::next. 00095 {
00096
00097 ReductionSetData *current = dataQueue;
00098
00099 while ( current ) {
00100 ReductionSetData *next = current->next;
00101 delete current;
00102 current = next;
00103 }
00104 delete [] addToRemoteSequenceNumber;
00105 }
|
|
|
Definition at line 108 of file ReductionMgr.C. References dataSize. Referenced by ReductionMgr::remoteRegister(), ReductionMgr::remoteSubmit(), ReductionMgr::remoteUnregister(), ReductionMgr::willRequire(), and ReductionMgr::willSubmit(). 00108 {
00109
00110 ReductionSetData **current = &dataQueue;
00111
00112 while ( *current ) {
00113 if ( (*current)->sequenceNumber == seqNum ) return *current;
00114 current = &((*current)->next);
00115 }
00116
00117 //iout << "seq " << seqNum << " created on " << CkMyPe() << "\n" << endi;
00118 *current = new ReductionSetData(seqNum, dataSize);
00119 return *current;
00120 }
|
|
|
Definition at line 123 of file ReductionMgr.C. References NAMD_die(), and ReductionSetData::next. 00123 {
00124
00125 ReductionSetData **current = &dataQueue;
00126
00127 while ( *current ) {
00128 if ( (*current)->sequenceNumber == seqNum ) break;
00129 current = &((*current)->next);
00130 }
00131
00132 if ( ! *current ) { NAMD_die("ReductionSet::removeData on missing seqNum"); }
00133
00134 ReductionSetData *toremove = *current;
00135 *current = (*current)->next;
00136 return toremove;
00137 }
|
|
|
Definition at line 201 of file ReductionMgr.h. Referenced by ReductionSet(), ReductionMgr::remoteRegister(), and ReductionMgr::remoteSubmit(). |
|
|
Definition at line 192 of file ReductionMgr.h. Referenced by ReductionSet(). |
|
|
Definition at line 191 of file ReductionMgr.h. Referenced by getData(), ReductionSet(), and ReductionMgr::remoteSubmit(). |
|
|
Definition at line 189 of file ReductionMgr.h. Referenced by ReductionSet(), ReductionMgr::remoteRegister(), ReductionMgr::remoteUnregister(), ReductionMgr::willRequire(), and ReductionMgr::willSubmit(). |
|
|
Definition at line 188 of file ReductionMgr.h. Referenced by ReductionSet(). |
|
|
Definition at line 195 of file ReductionMgr.h. Referenced by ReductionSet(), and ReductionMgr::willRequire(). |
|
|
Definition at line 190 of file ReductionMgr.h. Referenced by ReductionSet(), ReductionMgr::remoteRegister(), ReductionMgr::remoteSubmit(), ReductionMgr::remoteUnregister(), and ReductionMgr::willSubmit(). |
|
|
Definition at line 196 of file ReductionMgr.h. Referenced by ReductionSet(). |
|
|
Definition at line 197 of file ReductionMgr.h. |
|
|
Definition at line 198 of file ReductionMgr.h. |
1.3.9.1