coins.simd
Class LirBoneList

java.lang.Object
  extended bycoins.simd.LirMatch
      extended bycoins.simd.LirBoneList
Direct Known Subclasses:
LirBoneList_x86

public abstract class LirBoneList
extends LirMatch

BoneList class.


Field Summary
 ImList[] auxtemplateList
           
 ImList[] rewriteList
          Rewrite patterns.
 ImList[] templateList
          Matching patterns and attributes (called "bone info.").
 
Fields inherited from class coins.simd.LirMatch
newLir
 
Constructor Summary
LirBoneList()
           
 
Method Summary
 LirNode boneBody(ImList b)
          Get a pattern from a template.
 java.lang.String boneChng(ImList b)
          Get the changeability attribute from a template.
 java.lang.String boneHolenum(ImList b)
          Get the hole number attribute from a template.
 ImList boneInfo(ImList b)
          Get attributes from a template.
 ImList boneNosubsthnum(ImList b)
          Get non substituted hole numbers attribute from a template.
 ImList boneParacnts(ImList b)
          Get the parallel count attribute from a template.
 java.lang.String boneReplnum(ImList b)
          Get the replace number attribute from a template.
 java.lang.String boneSharedhnum(ImList b)
          Get the shared hole number attribute from a template.
 ImList boneSubgroups(ImList b)
          Get the subgroups attribute from a template.
abstract  boolean chkAuxCond(int i, LirNode inst)
           
 boolean chkBoneCnstr(ImList bone, LirNode inst, LirNode[] env, RegGroups rgs)
          Test consistency between a LirNode and an environment.
 java.lang.String chng(ImList binfo)
          Get the changeability attribute from a template.
 ImList find(LirNode inst)
          Find a matched template(a pattern and attributes).
 ImList find(LirNode inst, LirNode[] env)
          Find a matched template(a pattern and attributes).
 java.lang.String holenum(ImList binfo)
          Get the hole number attribute from a template.
 void init(Function f)
           
abstract  ImList[] initAuxBoneList()
           
abstract  ImList[] initBoneList()
          Initializes boneList.
abstract  ImList[] initRewriteList()
          Initializes rewriteList.
 ImList mkBone(java.lang.String infostr, java.lang.String bodystr)
          Makes bones and registers them into boneList.
 ImList mkRw(java.lang.String s)
          Makes LirNodes for rewrite and registers them into rewriteList.
 ImList nosubsthnum(ImList binfo)
          Get non substituted hole numbers attribute from a template.
 ImList paracnts(ImList binfo)
          Get the parallel count attribute from a template.
 java.lang.String replnum(ImList binfo)
          Get the replace number attribute from a template.
 java.lang.String sharedhnum(ImList binfo)
          Get the shared hole number attribute from a template.
 ImList subgroups(ImList binfo)
          Get the subgroups attribute from a template.
 
Methods inherited from class coins.simd.LirMatch
match, matchReg, replace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

templateList

public ImList[] templateList
Matching patterns and attributes (called "bone info.").


auxtemplateList

public ImList[] auxtemplateList

rewriteList

public ImList[] rewriteList
Rewrite patterns.

Constructor Detail

LirBoneList

public LirBoneList()
Method Detail

initBoneList

public abstract ImList[] initBoneList()
Initializes boneList.


initRewriteList

public abstract ImList[] initRewriteList()
Initializes rewriteList.


initAuxBoneList

public abstract ImList[] initAuxBoneList()

init

public void init(Function f)

find

public ImList find(LirNode inst,
                   LirNode[] env)
Find a matched template(a pattern and attributes).

Parameters:
inst - LIR
env -
Returns:
ImList, which represents a matched template.

chkAuxCond

public abstract boolean chkAuxCond(int i,
                                   LirNode inst)

find

public ImList find(LirNode inst)
Find a matched template(a pattern and attributes).

Parameters:
inst - LIR
Returns:
ImList, which represents a matched template.

mkBone

public ImList mkBone(java.lang.String infostr,
                     java.lang.String bodystr)
Makes bones and registers them into boneList.

Parameters:
infostr - String which represents a bone info.
bodystr - String which represents a bone body.
Returns:
ImList which represents a bone.

mkRw

public ImList mkRw(java.lang.String s)
Makes LirNodes for rewrite and registers them into rewriteList.

Parameters:
s - String which represents rewrited LirNodes.
Returns:
ImList which represents rewrited LirNodes.

chkBoneCnstr

public boolean chkBoneCnstr(ImList bone,
                            LirNode inst,
                            LirNode[] env,
                            RegGroups rgs)
Test consistency between a LirNode and an environment.

Parameters:
bone - A template(i.e. a pattern and attributes)
inst - LirNode
env - An environment
Returns:
true if consistent.

boneInfo

public ImList boneInfo(ImList b)
Get attributes from a template.

Parameters:
b - A template
Returns:
Attributes

boneBody

public LirNode boneBody(ImList b)
Get a pattern from a template.

Parameters:
b - A template
Returns:
A pattern

boneParacnts

public ImList boneParacnts(ImList b)
Get the parallel count attribute from a template.

Parameters:
b - A template
Returns:
String, which represents the parallel count.

paracnts

public ImList paracnts(ImList binfo)
Get the parallel count attribute from a template.

Parameters:
binfo - Attributes
Returns:
String, which represents the parallel count.

boneHolenum

public java.lang.String boneHolenum(ImList b)
Get the hole number attribute from a template.

Parameters:
b - A template
Returns:
String, which represents the hole number used as the output.

holenum

public java.lang.String holenum(ImList binfo)
Get the hole number attribute from a template.

Parameters:
binfo - Attributes
Returns:
String, which represents the hole number used as the output.

boneChng

public java.lang.String boneChng(ImList b)
Get the changeability attribute from a template.

Parameters:
b - A template
Returns:
String, which represents "changeable or not".

chng

public java.lang.String chng(ImList binfo)
Get the changeability attribute from a template.

Parameters:
binfo - Attributes
Returns:
String, which represents "changeable or not".

boneReplnum

public java.lang.String boneReplnum(ImList b)
Get the replace number attribute from a template.

Parameters:
b - A template
Returns:
String, which represents a number of a patten in the rewriteList.

replnum

public java.lang.String replnum(ImList binfo)
Get the replace number attribute from a template.

Parameters:
binfo - Attributes
Returns:
String, which represents a number of a patten in the rewriteList.

boneSharedhnum

public java.lang.String boneSharedhnum(ImList b)
Get the shared hole number attribute from a template. Registers, which match with the HOLE having this hole number, must be same.

Parameters:
b - A template
Returns:
String, which represents a shared hole number.

sharedhnum

public java.lang.String sharedhnum(ImList binfo)
Get the shared hole number attribute from a template. Registers, which match with the HOLE having this hole number, must be same.

Parameters:
binfo - Attributes
Returns:
String, which represents a shared hole number.

boneNosubsthnum

public ImList boneNosubsthnum(ImList b)
Get non substituted hole numbers attribute from a template. A Hole, which have a non substituted hole number, is not substituted to a subregister.

Parameters:
b - A template
Returns:
ImList, whose elements are non substituted hole numbers.

nosubsthnum

public ImList nosubsthnum(ImList binfo)
Get non substituted hole numbers attribute from a template. A Hole, which have a non substituted hole number, is not substituted to a subregister.

Parameters:
binfo - Attributes
Returns:
ImList, whose elements are non substituted hole numbers.

boneSubgroups

public ImList boneSubgroups(ImList b)
Get the subgroups attribute from a template. A subgroup is a set of hole numbers,which corresponds to a subregister.

Parameters:
b - A template
Returns:
ImList represents a set of subgroups.

subgroups

public ImList subgroups(ImList binfo)
Get the subgroups attribute from a template. A subgroup is a set of hole numbers,which corresponds to a subregister.

Parameters:
binfo - Attributes
Returns:
ImList represents a set of subgroups.