• Home
  • Raw
  • Download

Lines Matching refs:Expr

30   void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts) {  in apply()
31 ST.evaluate(Expr->arg_begin(), Expr->arg_end(), Elts); in apply()
37 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts) { in apply()
38 if (Expr->arg_size() < 2) in apply()
40 Expr->getAsString(); in apply()
42 ST.evaluate(*Expr->arg_begin(), Add); in apply()
43 ST.evaluate(Expr->arg_begin() + 1, Expr->arg_end(), Sub); in apply()
52 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts) { in apply()
53 if (Expr->arg_size() != 2) in apply()
54 throw "Set intersection requires two arguments: " + Expr->getAsString(); in apply()
56 ST.evaluate(Expr->arg_begin()[0], S1); in apply()
57 ST.evaluate(Expr->arg_begin()[1], S2); in apply()
66 virtual void apply2(SetTheory &ST, DagInit *Expr,
70 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts) { in apply()
71 if (Expr->arg_size() != 2) in apply()
72 throw "Operator requires (Op Set, Int) arguments: " + Expr->getAsString(); in apply()
74 ST.evaluate(Expr->arg_begin()[0], Set); in apply()
75 IntInit *II = dynamic_cast<IntInit*>(Expr->arg_begin()[1]); in apply()
77 throw "Second argument must be an integer: " + Expr->getAsString(); in apply()
78 apply2(ST, Expr, Set, II->getValue(), Elts); in apply()
84 void apply2(SetTheory &ST, DagInit *Expr, in apply2()
88 throw "Positive shift required: " + Expr->getAsString(); in apply2()
96 void apply2(SetTheory &ST, DagInit *Expr, in apply2()
100 throw "Positive length required: " + Expr->getAsString(); in apply2()
113 void apply2(SetTheory &ST, DagInit *Expr, in apply2()
132 void apply2(SetTheory &ST, DagInit *Expr, in apply2()
136 throw "Positive stride required: " + Expr->getAsString(); in apply2()
144 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts) { in apply()
146 SmallVector<RecSet, 4> Args(Expr->getNumArgs()); in apply()
148 for (unsigned i = 0, e = Expr->getNumArgs(); i != e; ++i) { in apply()
149 ST.evaluate(Expr->getArg(i), Args[i]); in apply()
154 for (unsigned i = 0, e = Expr->getNumArgs(); i != e; ++i) in apply()
162 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts) { in apply()
163 if (Expr->arg_size() != 3) in apply()
165 Expr->getAsString(); in apply()
167 if (StringInit *SI = dynamic_cast<StringInit*>(Expr->arg_begin()[0])) in apply()
170 throw "Format must be a string: " + Expr->getAsString(); in apply()
173 if (IntInit *II = dynamic_cast<IntInit*>(Expr->arg_begin()[1])) in apply()
176 throw "From must be an integer: " + Expr->getAsString(); in apply()
180 if (IntInit *II = dynamic_cast<IntInit*>(Expr->arg_begin()[2])) in apply()
183 throw "From must be an integer: " + Expr->getAsString(); in apply()
188 dynamic_cast<DefInit&>(*Expr->getOperator()).getDef()->getRecords(); in apply()
197 throw "No def named '" + Name + "': " + Expr->getAsString(); in apply()
248 void SetTheory::evaluate(Init *Expr, RecSet &Elts) { in evaluate() argument
250 if (DefInit *Def = dynamic_cast<DefInit*>(Expr)) { in evaluate()
258 if (ListInit *LI = dynamic_cast<ListInit*>(Expr)) in evaluate()
262 DagInit *DagExpr = dynamic_cast<DagInit*>(Expr); in evaluate()
264 throw "Invalid set element: " + Expr->getAsString(); in evaluate()
267 throw "Bad set expression: " + Expr->getAsString(); in evaluate()
270 throw "Unknown set operator: " + Expr->getAsString(); in evaluate()