
Public Member Functions | |
| void | addOp (ShOperation op, const ShEvalOp *evalOp, ShValueType dest, ShValueType src0, ShValueType src1=SH_VALUETYPE_END, ShValueType src2=SH_VALUETYPE_END) |
| Registers a evalOp for a certain operation/source type index combination. | |
| std::string | availableOps () const |
| debugging function | |
| void | operator() (ShOperation op, ShVariant *dest, const ShVariant *a, const ShVariant *b, const ShVariant *c) const |
| Decides which evaluation evalOp to use and calls it up. | |
| void | operator() (ShOperation op, ShVariantPtr dest, ShVariantCPtr a, ShVariantCPtr b, ShVariantCPtr c) const |
| const ShEvalOpInfo * | getEvalOpInfo (ShOperation op, ShValueType dest, ShValueType src0, ShValueType src1=SH_VALUETYPE_END, ShValueType src2=SH_VALUETYPE_END) const |
| Returns a new op info representing the types that arguments should be cast into for an operation. | |
| const ShEvalOpInfo * | getEvalOpInfo (const ShStatement &stmt) const |
Static Public Member Functions | |
| static ShEval * | instance () |
Definition at line 85 of file ShEval.hpp.
|
||||||||||||||||||||||||
|
Returns a new op info representing the types that arguments should be cast into for an operation. Caches the result. Definition at line 113 of file ShEval.cpp. References SH::ShOperationInfo::arity, SH::ShCastManager::castDist(), SH::ShEvalOpInfo::encode(), SH::ShCastManager::instance(), SH::opInfo, and SH::shValueTypeName(). Referenced by SH::FloatConverter::fixStatement(), getEvalOpInfo(), and operator()(). |
|
||||||||||||||||||||||||
|
Decides which evaluation evalOp to use and calls it up. If an op is unary, leave b, c = 0. If an op is binary leave c = 0. If an op has no dest, leave dest = 0. TODO (should really break this out into separate functions. EvalOps can have a single function in th einterface) Definition at line 32 of file ShEval.cpp. References SH::ShCastManager::doAllocCast(), SH::ShCastManager::doCast(), SH::ShVariant::encodeArray(), SH::ShVariantFactory::generate(), getEvalOpInfo(), SH::ShCastManager::instance(), SH::ShEvalOpInfo::m_dest, SH::ShEvalOpInfo::m_evalOp, SH::ShEvalOpInfo::m_src, SH::opInfo, SH::shValueTypeName(), SH::shVariantFactory(), SH::ShVariant::size(), SH::ShVariant::typeMatches(), and SH::ShVariant::valueType(). Referenced by operator()(). |
1.4.3-20050530