AVIunorderedNoLock::process Struct Reference

Functor for loop body. More...

#include <AVIunorderedNoLock.h>

List of all members.

Public Member Functions

 process (Graph &graph, std::vector< AtomicInteger > &inDegVec, MeshInit &meshInit, GlobalVec &g, GaloisRuntime::PerCPU< LocalVec > &perIterLocalVec, GaloisRuntime::PerCPU< std::vector< GNode > > &perIterAddList, const AVIComparator &aviCmp, bool createSyncFiles, IterCounter &iter)
 process (const process &that)
template<typename ContextTy >
void operator() (const GNode &src, ContextTy &lwl)
 Loop body.

Public Attributes

Graphgraph
std::vector< AtomicInteger > & inDegVec
MeshInitmeshInit
GlobalVecg
GaloisRuntime::PerCPU< LocalVec > & perIterLocalVec
GaloisRuntime::PerCPU
< std::vector< GNode > > & 
perIterAddList
const AVIComparatoraviCmp
bool createSyncFiles
IterCounteriter

Detailed Description

Functor for loop body.


Constructor & Destructor Documentation

AVIunorderedNoLock::process::process ( Graph graph,
std::vector< AtomicInteger > &  inDegVec,
MeshInit meshInit,
GlobalVec g,
GaloisRuntime::PerCPU< LocalVec > &  perIterLocalVec,
GaloisRuntime::PerCPU< std::vector< GNode > > &  perIterAddList,
const AVIComparator aviCmp,
bool  createSyncFiles,
IterCounter iter 
) [inline]
AVIunorderedNoLock::process::process ( const process that  )  [inline]

Member Function Documentation

template<typename ContextTy >
void AVIunorderedNoLock::process::operator() ( const GNode src,
ContextTy &  lwl 
) [inline]

Loop body.

The key condition is that a node and its neighbor cannot be active at the same time, and it must be impossible for two of them to be processed in parallel Therefore a node can add its newly active neighbors to the workset as the last step only when it has finished performing all other updates For the same reason, active node src must update its own in degree before updating the indegree of any of the neighbors. Imagine the alternative, where active node updates its in degree and that of it's neighbor in the same loop. For example A is current active node and has a neighbor B. A > B, therefore A increments its own in degree and decrements that of B to 1. Another active node C is neighbor of B but not of A, and C decreases in degree of B to 0 and adds B to the workset while A is not finished yet. This violates our key condition mentioned above

Parameters:
src is active elemtn
lwl is the worklist handle

Member Data Documentation


The documentation for this struct was generated from the following file:
Generated on Tue Aug 2 11:51:26 2011 for Galois by  doxygen 1.6.3