|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectat.dms.kjc.sir.lowering.partition.PartitionGroup
public class PartitionGroup
This represents a partitioning of the children of a single SIR Container. A PartitionGroup is immutable.
Method Summary | |
---|---|
static PartitionGroup |
createFromArray(int[] partitions)
Creates a partition group where |
static PartitionGroup |
createFromAssignments(List<SIRStream> children,
HashMap<Object,Integer> map)
Given a list of children and a mapping from each child to an Integer denoting the partition, creates a partition group where children mapped to the same integer are allocated to the same partition. |
static PartitionGroup |
createUniformPartition(int n)
Create a uniform partition with one child in each. |
int |
get(int i)
Returns the size of the i'th partition in this. |
int |
getFirst(int k)
Returns the index of the first child in the k'th partition. |
int |
getLast(int k)
Returns the index of the last child in the k'th partition. |
int |
getNumChildren()
Returns the number of children accounted for in this partitioning. |
int |
getPartForChild(int k)
Returns which partition the k'th child belongs to. |
int |
size()
Returns number of partitions in this. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public static PartitionGroup createFromArray(int[] partitions)
public static PartitionGroup createUniformPartition(int n)
public static PartitionGroup createFromAssignments(List<SIRStream> children, HashMap<Object,Integer> map)
public int size()
public int get(int i)
public int getFirst(int k)
public int getLast(int k)
public int getPartForChild(int k)
public int getNumChildren()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |