Lines Matching refs:Expr

39   void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts,  in apply()
41 ST.evaluate(Expr->arg_begin(), Expr->arg_end(), Elts, Loc); in apply()
47 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts, in apply()
49 if (Expr->arg_size() < 2) in apply()
51 Expr->getAsString()); in apply()
53 ST.evaluate(*Expr->arg_begin(), Add, Loc); in apply()
54 ST.evaluate(Expr->arg_begin() + 1, Expr->arg_end(), Sub, Loc); in apply()
63 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts, in apply()
65 if (Expr->arg_size() != 2) in apply()
67 Expr->getAsString()); in apply()
69 ST.evaluate(Expr->arg_begin()[0], S1, Loc); in apply()
70 ST.evaluate(Expr->arg_begin()[1], S2, Loc); in apply()
79 virtual void apply2(SetTheory &ST, DagInit *Expr, RecSet &Set, int64_t N,
82 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts, in apply()
84 if (Expr->arg_size() != 2) in apply()
86 Expr->getAsString()); in apply()
88 ST.evaluate(Expr->arg_begin()[0], Set, Loc); in apply()
89 IntInit *II = dyn_cast<IntInit>(Expr->arg_begin()[1]); in apply()
92 Expr->getAsString()); in apply()
93 apply2(ST, Expr, Set, II->getValue(), Elts, Loc); in apply()
99 void apply2(SetTheory &ST, DagInit *Expr, RecSet &Set, int64_t N, in apply2()
103 Expr->getAsString()); in apply2()
111 void apply2(SetTheory &ST, DagInit *Expr, RecSet &Set, int64_t N, in apply2()
115 Expr->getAsString()); in apply2()
128 void apply2(SetTheory &ST, DagInit *Expr, RecSet &Set, int64_t N, in apply2()
146 void apply2(SetTheory &ST, DagInit *Expr, RecSet &Set, int64_t N, in apply2()
150 Expr->getAsString()); in apply2()
158 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts, in apply()
161 SmallVector<RecSet, 4> Args(Expr->getNumArgs()); in apply()
163 for (unsigned i = 0, e = Expr->getNumArgs(); i != e; ++i) { in apply()
164 ST.evaluate(Expr->getArg(i), Args[i], Loc); in apply()
169 for (unsigned i = 0, e = Expr->getNumArgs(); i != e; ++i) in apply()
177 void apply(SetTheory &ST, DagInit *Expr, RecSet &Elts, in apply()
180 if (Expr->arg_size() > 4) in apply()
182 Expr->getAsString()); in apply()
183 else if (Expr->arg_size() == 4) { in apply()
184 if (IntInit *II = dyn_cast<IntInit>(Expr->arg_begin()[3])) { in apply()
188 Expr->getAsString()); in apply()
192 if (StringInit *SI = dyn_cast<StringInit>(Expr->arg_begin()[0])) in apply()
195 PrintFatalError(Loc, "Format must be a string: " + Expr->getAsString()); in apply()
198 if (IntInit *II = dyn_cast<IntInit>(Expr->arg_begin()[1])) in apply()
201 PrintFatalError(Loc, "From must be an integer: " + Expr->getAsString()); in apply()
205 if (IntInit *II = dyn_cast<IntInit>(Expr->arg_begin()[2])) in apply()
208 PrintFatalError(Loc, "To must be an integer: " + Expr->getAsString()); in apply()
213 cast<DefInit>(Expr->getOperator())->getDef()->getRecords(); in apply()
227 Expr->getAsString()); in apply()
281 void SetTheory::evaluate(Init *Expr, RecSet &Elts, ArrayRef<SMLoc> Loc) { in evaluate() argument
283 if (DefInit *Def = dyn_cast<DefInit>(Expr)) { in evaluate()
291 if (ListInit *LI = dyn_cast<ListInit>(Expr)) in evaluate()
295 DagInit *DagExpr = dyn_cast<DagInit>(Expr); in evaluate()
297 PrintFatalError(Loc, "Invalid set element: " + Expr->getAsString()); in evaluate()
300 PrintFatalError(Loc, "Bad set expression: " + Expr->getAsString()); in evaluate()
303 PrintFatalError(Loc, "Unknown set operator: " + Expr->getAsString()); in evaluate()