aa
com.cliffc.aa.node.Work Class Referenceabstract
Inheritance diagram for com.cliffc.aa.node.Work:
[legend]
Collaboration diagram for com.cliffc.aa.node.Work:
[legend]

Public Member Functions

 Work (String name, boolean replacing)
 
abstract Node apply (Node n)
 
Node at (int i)
 
void clear ()
 
void del (int i)
 
void del (Node n)
 
boolean isEmpty ()
 
int len ()
 
boolean on (Node n)
 
Node pop ()
 
String toString ()
 

Public Attributes

final String _name
 
final boolean _replacing
 
final Ary< Node_work = new Ary<>(new Node[1],0)
 

Package Functions

public< N extends Node > N add (N n)
 

Package Attributes

final VBitSet _on = new VBitSet()
 

Detailed Description

Definition at line 8 of file Work.java.

Constructor & Destructor Documentation

◆ Work()

com.cliffc.aa.node.Work.Work ( String  name,
boolean  replacing 
)

Definition at line 13 of file Work.java.

13 { _name=name; _replacing = replacing; }

References com.cliffc.aa.node.Work._name, and com.cliffc.aa.node.Work._replacing.

Member Function Documentation

◆ add()

public<N extends Node> N com.cliffc.aa.node.Work.add ( n)
package

Definition at line 15 of file Work.java.

15  {
16  if( !_on.tset(n._uid) ) _work.push(n);
17  return n;
18  }

References com.cliffc.aa.node.Work._on, com.cliffc.aa.node.Work._work, and com.cliffc.aa.util.VBitSet.tset().

Referenced by com.cliffc.aa.GVNGCM.add_work().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ apply()

abstract Node com.cliffc.aa.node.Work.apply ( Node  n)
abstract

Referenced by com.cliffc.aa.GVNGCM.iter().

Here is the caller graph for this function:

◆ at()

Node com.cliffc.aa.node.Work.at ( int  i)

Definition at line 27 of file Work.java.

27 { return _work.at(i); }

References com.cliffc.aa.node.Work._work.

Referenced by com.cliffc.aa.node.Work.del(), and com.cliffc.aa.GVNGCM.iter().

Here is the caller graph for this function:

◆ clear()

void com.cliffc.aa.node.Work.clear ( )

Definition at line 37 of file Work.java.

37 { _work.clear(); _on.clear(); }

References com.cliffc.aa.node.Work._on, and com.cliffc.aa.node.Work._work.

Referenced by com.cliffc.aa.GVNGCM.reset_to_init0().

Here is the caller graph for this function:

◆ del() [1/2]

void com.cliffc.aa.node.Work.del ( int  i)

Definition at line 28 of file Work.java.

28 { _on.clear(at(i)._uid); _work.del(i); }

References com.cliffc.aa.node.Work._on, com.cliffc.aa.node.Work._work, and com.cliffc.aa.node.Work.at().

Referenced by com.cliffc.aa.GVNGCM.check_not_monotonic(), and com.cliffc.aa.GVNGCM.iter().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ del() [2/2]

void com.cliffc.aa.node.Work.del ( Node  n)

Definition at line 29 of file Work.java.

29  {
30  if( !_on.get(n._uid) ) return;
31  _on.clear(n._uid);
32  _work.del(n);
33  }

References com.cliffc.aa.node.Work._on, com.cliffc.aa.node.Node._uid, and com.cliffc.aa.node.Work._work.

◆ isEmpty()

boolean com.cliffc.aa.node.Work.isEmpty ( )

Definition at line 35 of file Work.java.

35 { return _work._len==0; }

References com.cliffc.aa.node.Work._work.

Referenced by com.cliffc.aa.GVNGCM.gcp(), and com.cliffc.aa.GVNGCM.iter().

Here is the caller graph for this function:

◆ len()

int com.cliffc.aa.node.Work.len ( )

Definition at line 14 of file Work.java.

14 { return _work._len; }

References com.cliffc.aa.node.Work._work.

Referenced by com.cliffc.aa.GVNGCM.iter().

Here is the caller graph for this function:

◆ on()

boolean com.cliffc.aa.node.Work.on ( Node  n)

Definition at line 36 of file Work.java.

36 { return _on.test(n._uid); }

References com.cliffc.aa.node.Work._on, com.cliffc.aa.node.Node._uid, and com.cliffc.aa.util.VBitSet.test().

Referenced by com.cliffc.aa.GVNGCM.on_dead(), com.cliffc.aa.GVNGCM.on_flow(), and com.cliffc.aa.GVNGCM.on_reduce().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ pop()

Node com.cliffc.aa.node.Work.pop ( )

Definition at line 21 of file Work.java.

21  {
22  if( _work._len==0 ) return null;
23  Node n = _work.pop();
24  _on.clear(n._uid);
25  return n;
26  }

References com.cliffc.aa.node.Work._on, com.cliffc.aa.node.Node._uid, and com.cliffc.aa.node.Work._work.

Referenced by com.cliffc.aa.GVNGCM.gcp(), and com.cliffc.aa.GVNGCM.iter().

Here is the caller graph for this function:

◆ toString()

String com.cliffc.aa.node.Work.toString ( )

Definition at line 38 of file Work.java.

38 { return _name+_on.toString(); }

References com.cliffc.aa.node.Work._name, and com.cliffc.aa.node.Work._on.

Member Data Documentation

◆ _name

final String com.cliffc.aa.node.Work._name

Definition at line 11 of file Work.java.

Referenced by com.cliffc.aa.node.Work.toString(), and com.cliffc.aa.node.Work.Work().

◆ _on

◆ _replacing

final boolean com.cliffc.aa.node.Work._replacing

Definition at line 12 of file Work.java.

Referenced by com.cliffc.aa.node.Work.Work().

◆ _work


The documentation for this class was generated from the following file:
com.cliffc.aa.node.Work._work
final Ary< Node > _work
Definition: Work.java:9
com.cliffc.aa.node.Work._replacing
final boolean _replacing
Definition: Work.java:12
com.cliffc.aa.util.VBitSet.test
boolean test(int idx)
Definition: VBitSet.java:8
com.cliffc.aa.util.VBitSet.tset
boolean tset(int idx)
Definition: VBitSet.java:7
com.cliffc.aa.node.Work._name
final String _name
Definition: Work.java:11
com.cliffc.aa.node.Work._on
final VBitSet _on
Definition: Work.java:10
com.cliffc.aa.node.Work.at
Node at(int i)
Definition: Work.java:27