NAMD
Public Member Functions | Public Attributes | List of all members
pe_sortop_bit_reversed Struct Reference

Public Member Functions

 pe_sortop_bit_reversed (int *r)
 
bool operator() (int a, int b) const
 

Public Attributes

int * rankInPhysOfNode
 

Detailed Description

Definition at line 138 of file WorkDistrib.C.

Constructor & Destructor Documentation

pe_sortop_bit_reversed::pe_sortop_bit_reversed ( int *  r)
inline

Definition at line 140 of file WorkDistrib.C.

140 : rankInPhysOfNode(r) {}

Member Function Documentation

bool pe_sortop_bit_reversed::operator() ( int  a,
int  b 
) const
inline

Definition at line 141 of file WorkDistrib.C.

References compare_bit_reversed(), and rankInPhysOfNode.

141  {
142  int c = compare_bit_reversed(CmiRankOf(a),CmiRankOf(b));
143  if ( c < 0 ) return true;
144  if ( c > 0 ) return false;
146  rankInPhysOfNode[CmiNodeOf(a)],rankInPhysOfNode[CmiNodeOf(b)]);
147  if ( c < 0 ) return true;
148  if ( c > 0 ) return false;
149  c = compare_bit_reversed(CmiPhysicalNodeID(a),CmiPhysicalNodeID(b));
150  return ( c < 0 );
151  }
int compare_bit_reversed(int a, int b)
Definition: ComputePme.C:318

Member Data Documentation

int* pe_sortop_bit_reversed::rankInPhysOfNode

Definition at line 139 of file WorkDistrib.C.

Referenced by operator()().


The documentation for this struct was generated from the following file: