|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object scale.score.dependence.omega.omegaLib.Formula scale.score.dependence.omega.omegaLib.FDeclaration scale.score.dependence.omega.omegaLib.Conjunct
public final class Conjunct
Conjunct.
$Id: Conjunct.java,v 1.16 2007-10-04 19:58:25 burrill Exp $
Copyright 2008 by the
Scale Compiler Group,
Department of Computer Science
University of Massachusetts,
Amherst MA. 01003, USA
All Rights Reserved.
This version of the Omega Libray is a translation from C++ to Java of the Omega Library developed at the University of Maryland.
Copyright (C) 1994-1996 by the Omega ProjectAbout variables in Conjunct:All rights reserved.
NOTICE: This software is provided ``as is'', without any warranty, including any implied warranty for merchantability or fitness for a particular purpose. Under no circumstances shall the Omega Project or its agents be liable for any use of, misuse of, or inability to use this software, including incidental and consequential damages.
License is hereby given to use, modify, and redistribute this software, in whole or in part, for any purpose, commercial or non-commercial, provided that the user agrees to the terms of this copyright notice, including disclaimer of warranty, and provided that this copyright notice, including disclaimer of warranty, is preserved in the source code and documentation of anything derived from this software. Any redistributor of this software or anything derived from this software assumes responsibility for ensuring that any parties to whom such a redistribution is made are fully aware of the terms of this license and disclaimer.
The Omega project can be contacted at omega@cs.umd.edu or http://www.cs.umd.edu/projects/omega
Field Summary | |
---|---|
static int |
ANY_NEGATION
|
static int |
AvoidNegating
|
static int |
CantBeNegated
|
static char[] |
dirGlyphs
|
static int |
EVAC_AFFINE
|
static int |
EVAC_NASTY
|
static int |
EVAC_OFFSET
|
static int |
EVAC_OFFSET_subseq
|
static int |
EVAC_SUBSEQ
|
static int |
EVAC_TRIVIAL
|
int |
id
|
static int |
MERGE_COMPOSE
|
static int |
MERGE_GIST
|
static int |
MERGE_REGULAR
|
static int |
ONE_GEQ_OR_EQ
|
static int |
ONE_GEQ_OR_STRIDE
|
Fields inherited from class scale.score.dependence.omega.omegaLib.FDeclaration |
---|
myLocals |
Fields inherited from class scale.score.dependence.omega.omegaLib.Formula |
---|
myChildren, myParent, myRelation, omegaLib, OP_AND, OP_CONJUNCT, OP_EXISTS, OP_FORALL, OP_NOT, OP_OR, OP_RELATION |
Constructor Summary | |
---|---|
Conjunct(Conjunct conj)
|
|
Conjunct(OmegaLib omegaLib)
|
|
Conjunct(OmegaLib omegaLib,
Formula f,
RelBody r)
|
Method Summary | |
---|---|
EQHandle |
addEQ(boolean preserves_level)
|
EQHandle |
addEQ(ConstraintHandle c,
boolean preserves_level)
|
GEQHandle |
addGEQ(boolean preserves_level)
|
GEQHandle |
addGEQ(ConstraintHandle c,
boolean preserves_level)
|
EQHandle |
addStride(int step,
boolean preserves_level)
Create new constraints with all co-efficients 0. |
void |
after(RelBody r,
int preservedPositions)
|
void |
assertLeadingInfo()
|
void |
beautify()
|
boolean |
canAddChild()
|
boolean |
checkLeading0s(int level)
|
boolean |
checkLeading0s(int direction,
int level)
|
void |
clearSubs()
|
protected void |
combineColumns()
|
boolean |
constraintIsEqual(Equation eq,
Conjunct that,
Equation eqt)
|
void |
convertEQstoGEQs()
|
Conjunct |
copy(Formula parent,
RelBody rel_body)
|
void |
copyConstraint(Equation eqns,
Conjunct from,
Equation eq)
|
int |
cost()
Cost = # of terms in DNF when negated. |
void |
countLeadingZeros()
|
static int |
created()
|
VarDecl |
declare()
|
VarDecl |
declare(java.lang.String s)
|
VarDecl |
declare(VarDecl v)
|
void |
delete()
|
void |
deltas()
|
int |
difficulty()
|
DNF |
DNFize()
|
void |
DNFizeH(Vector<VarDecl> locals_copy)
|
void |
domain(RelBody r,
int a)
|
void |
enforceLeadingInfo(int guaranteed,
int possible,
int dir)
|
void |
extractNonWildVars(Vector<VarDecl> allVars)
|
void |
farkas()
|
void |
fastTightHull(HashSet<VarDecl> vars)
|
Conjunct |
findAvailableConjunct()
|
int |
findColumn(VarDecl D)
|
int |
getColumn(VarDecl D)
Return column for D in conjunct. |
Equation[] |
getEQs()
|
Equation[] |
getGEQs()
|
int |
getGuaranteedLeading0s()
|
int |
getNumEQs()
|
int |
getNumGEQs()
|
Problem |
getProblem()
|
java.lang.String |
getVarName(int col)
|
boolean |
hasWildcards(Equation eq)
|
int |
hull(Equation eq,
Conjunct that,
Equation eqt)
|
void |
interpretUnknownAsTrue()
|
void |
invalidateLeadingInfo(int changed)
|
boolean |
isEmpty()
|
boolean |
isExact()
|
boolean |
isInexact()
|
boolean |
isTrue()
|
boolean |
isUnknown()
|
boolean |
leadingDirValidAndKnown()
|
void |
makeInexact()
|
void |
makeLevelCarriedTo(DNF newstuff,
int split_to,
int level)
|
int |
maxTuplePosition(Equation eq)
|
int |
maxUfsArityOfIn()
|
int |
maxUfsArityOfOut()
|
int |
maxUfsArityOfSet()
|
Conjunct |
mergeConjuncts(Conjunct conj2,
int action,
RelBody body)
Merge CONJ1 & CONJ2 => CONJ. |
DNF |
negateConjunct()
~CONJ => DNF |
int |
nodeType()
|
int |
numVars()
|
void |
orderedElimination(int symLen)
|
boolean |
parallel(Equation eq,
Conjunct that,
Equation eqt)
|
void |
prefixPrint()
|
void |
prefixPrint(boolean debug)
|
void |
print()
|
java.lang.String |
printEQtoString(Equation e)
|
java.lang.String |
printGEQtoString(Equation e)
|
java.lang.String |
printSubToString(int col)
|
java.lang.String |
printTermToString(Equation e)
|
java.lang.String |
printToString(boolean true_printed)
|
int |
priority()
|
void |
promiseThatUbSolutionsExist()
|
protected void |
pushExists(Vector<VarDecl> S)
Add given list of wildcards S to this Conjunct. |
boolean |
queryDifference(VarDecl v1,
VarDecl v2,
int[] bounds)
|
int |
queryGuaranteedLeadingZeros()
|
int |
queryLeadingDir()
|
int |
queryPossibleLeadingZeros()
|
void |
queryVariableBounds(VarDecl v,
int[] bounds)
|
void |
range(RelBody r,
int a)
|
Conjunct |
reallyConjunct()
|
void |
recomputeMappedVars()
|
int |
redSimplifyProblem(int effort,
boolean computeGist)
|
void |
remap()
Remap mappedVars in all conjuncts of formula. |
void |
remapDNFVars(RelBody ref_rel)
|
void |
removeColorConstraints()
|
void |
reorderAndSimplify(RelBody r,
boolean stridesAllowed)
|
void |
reorderForPrint(boolean reverseOrder,
int first_pass_input,
int first_pass_output,
boolean sort)
|
void |
reverseLeadingDirInfo()
|
boolean |
simplifyConjunct(boolean ver_sim,
int simplificationEffort,
int color)
Simplify Conjunct. |
boolean |
simplifyProblem(boolean verify,
int redundantElimination)
|
java.lang.String |
toString()
|
java.lang.String |
tryToPrintVarToStringWithDiv(VarDecl v)
|
Vector<VarDecl> |
variables()
|
boolean |
varIsConstant(VarDecl v,
Equation eq)
|
Methods inherited from class scale.score.dependence.omega.omegaLib.FDeclaration |
---|
declareTuple, doDeclare, locals, setupAnonymousWildcardNames, setupNames |
Methods inherited from class scale.score.dependence.omega.omegaLib.Formula |
---|
addAnd, addChild, addConjunct, addExists, addExists, addForall, addNot, addOr, andWith, assertNotFinalized, checkAndAddChild, children, getChildren, getFirstChild, numberOfChildren, olAssert, olAssert, parent, printSeparator, rearrange, relation, removeChild, removeFirstChild, setFinalized, setParent, setParent, setRelation, toStringClass, verifytree |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int CantBeNegated
public static final int AvoidNegating
public static final int MERGE_REGULAR
public static final int MERGE_COMPOSE
public static final int MERGE_GIST
public static final char[] dirGlyphs
public static final int EVAC_TRIVIAL
public static final int EVAC_OFFSET
public static final int EVAC_SUBSEQ
public static final int EVAC_OFFSET_subseq
public static final int EVAC_AFFINE
public static final int EVAC_NASTY
public static final int ANY_NEGATION
public static final int ONE_GEQ_OR_EQ
public static final int ONE_GEQ_OR_STRIDE
public int id
Constructor Detail |
---|
public Conjunct(OmegaLib omegaLib)
public Conjunct(OmegaLib omegaLib, Formula f, RelBody r)
public Conjunct(Conjunct conj)
Method Detail |
---|
public static int created()
public Conjunct copy(Formula parent, RelBody rel_body)
copy
in class Formula
public void delete()
delete
in class Formula
public java.lang.String toString()
toString
in class Formula
public boolean leadingDirValidAndKnown()
public Vector<VarDecl> variables()
public int numVars()
public Equation[] getEQs()
public int getNumEQs()
public Equation[] getGEQs()
public int getNumGEQs()
public Problem getProblem()
public boolean hasWildcards(Equation eq)
public int maxTuplePosition(Equation eq)
public boolean varIsConstant(VarDecl v, Equation eq)
public void promiseThatUbSolutionsExist()
public int maxUfsArityOfSet()
public int maxUfsArityOfIn()
public int maxUfsArityOfOut()
public int nodeType()
nodeType
in class Formula
public boolean isTrue()
public boolean isEmpty()
public void clearSubs()
public boolean queryDifference(VarDecl v1, VarDecl v2, int[] bounds)
public void queryVariableBounds(VarDecl v, int[] bounds)
public int difficulty()
public int queryGuaranteedLeadingZeros()
public int getGuaranteedLeading0s()
public int queryPossibleLeadingZeros()
public int queryLeadingDir()
public boolean isUnknown()
public boolean isExact()
public boolean isInexact()
public void makeInexact()
public boolean simplifyConjunct(boolean ver_sim, int simplificationEffort, int color)
public void recomputeMappedVars()
public void assertLeadingInfo()
public java.lang.String tryToPrintVarToStringWithDiv(VarDecl v)
public void print()
print
in class FDeclaration
public void prefixPrint()
public void prefixPrint(boolean debug)
prefixPrint
in class FDeclaration
public java.lang.String printToString(boolean true_printed)
public java.lang.String printEQtoString(Equation e)
public java.lang.String printGEQtoString(Equation e)
public java.lang.String printTermToString(Equation e)
public java.lang.String printSubToString(int col)
public void interpretUnknownAsTrue()
public Conjunct reallyConjunct()
reallyConjunct
in class Formula
public EQHandle addStride(int step, boolean preserves_level)
public EQHandle addEQ(boolean preserves_level)
public GEQHandle addGEQ(boolean preserves_level)
public EQHandle addEQ(ConstraintHandle c, boolean preserves_level)
public GEQHandle addGEQ(ConstraintHandle c, boolean preserves_level)
public void copyConstraint(Equation eqns, Conjunct from, Equation eq)
public boolean canAddChild()
canAddChild
in class FDeclaration
public void remap()
Formula
remap
in class Formula
public void beautify()
beautify
in class Formula
public DNF DNFize()
DNFize
in class Formula
public void DNFizeH(Vector<VarDecl> locals_copy)
public int priority()
priority
in class FDeclaration
public Conjunct findAvailableConjunct()
findAvailableConjunct
in class Formula
public java.lang.String getVarName(int col)
public VarDecl declare(java.lang.String s)
declare
in class FDeclaration
public VarDecl declare()
declare
in class FDeclaration
public VarDecl declare(VarDecl v)
declare
in class FDeclaration
protected void pushExists(Vector<VarDecl> S)
pushExists
in class Formula
public int getColumn(VarDecl D)
public int findColumn(VarDecl D)
protected void combineColumns()
combineColumns
in class Formula
public void reorderForPrint(boolean reverseOrder, int first_pass_input, int first_pass_output, boolean sort)
public void countLeadingZeros()
public void enforceLeadingInfo(int guaranteed, int possible, int dir)
enforceLeadingInfo
in class Formula
public void invalidateLeadingInfo(int changed)
invalidateLeadingInfo
in class Formula
public void reverseLeadingDirInfo()
reverseLeadingDirInfo
in class Formula
public void removeColorConstraints()
public void orderedElimination(int symLen)
public void convertEQstoGEQs()
public int cost()
public boolean simplifyProblem(boolean verify, int redundantElimination)
public int redSimplifyProblem(int effort, boolean computeGist)
public Conjunct mergeConjuncts(Conjunct conj2, int action, RelBody body)
Does not consume its arguments
Optional 4th argument gives the relation for the result - if null, conj1 and conj2 must have the same relation, which will be used for the result
The only members of conj1 and conj2 that are used are: problem, mappedVars and declare(), and the leading_0s/leading_dir members and exact.
NOTE: variables that are shared between conjuncts are necessarily declared above, not here; so we can simply create columns for the locals of each conj after doing the protected vars.
public DNF negateConjunct()
public void reorderAndSimplify(RelBody r, boolean stridesAllowed)
public void domain(RelBody r, int a)
public void range(RelBody r, int a)
public void after(RelBody r, int preservedPositions)
public void deltas()
public boolean checkLeading0s(int direction, int level)
public boolean checkLeading0s(int level)
public void remapDNFVars(RelBody ref_rel)
public void extractNonWildVars(Vector<VarDecl> allVars)
public void makeLevelCarriedTo(DNF newstuff, int split_to, int level)
public boolean parallel(Equation eq, Conjunct that, Equation eqt)
public int hull(Equation eq, Conjunct that, Equation eqt)
public boolean constraintIsEqual(Equation eq, Conjunct that, Equation eqt)
public void farkas()
public void fastTightHull(HashSet<VarDecl> vars)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |