1 #ifndef CPPAD_CG_OPERATION_INCLUDED 2 #define CPPAD_CG_OPERATION_INCLUDED 90 inline std::ostream& operator<<(std::ostream& os,
const CGOpCode& op) {
91 static const char* OpNameTable[] = {
99 "new sparseArray[size]",
105 "atomicFunction.forward(q, p, vx, vy, tx, ty)",
106 "atomicFunction.reverse(p, tx, ty, px, py)",
107 "result = ($1 < $2)? $3 : $4",
108 "result = ($1 <= $2)? $3 : $4",
109 "result = ($1 == $2)? $3 : $4",
110 "result = ($1 >= $2)? $3 : $4",
111 "result = ($1 > $2)? $3 : $4",
112 "result = ($1 != $2)? $3 : $4",
133 "dep($1) = ($2) + ...",
137 "index = expression()",
145 "bool(index expression)",
155 CPPADCG_ASSERT_UNKNOWN(
size_t(CGOpCode::NumberOp) + 1 ==
sizeof(OpNameTable)/
sizeof(OpNameTable[0]));
158 CPPADCG_ASSERT_UNKNOWN(
int(op) >= 0 &&
size_t(op) <
size_t(CGOpCode::NumberOp));
160 os << OpNameTable[size_t(op)];