41#include "../../expressions/activeType.hpp"
43#include "../../traits/expressionTraits.hpp"
44#include "directStatementEvaluator.hpp"
45#include "statementEvaluatorInterface.hpp"
72 template<
typename Tape,
typename Expr>
81 template<
typename Generator,
typename Expr>
102 template<
typename T_Real>
115 template<
typename Tape,
typename... Args>
118 h->maxConstantArguments, std::forward<Args>(args)...);
122 template<
typename Tape,
typename... Args>
124 return Tape::statementEvaluatePrimalFull((
FunctionPrimal<Tape>)h->primal, h->maxActiveArguments,
125 h->maxConstantArguments, std::forward<Args>(args)...);
129 template<
typename Tape,
typename... Args>
132 h->maxConstantArguments, std::forward<Args>(args)...);
136 template<
typename Tape,
typename Generator,
typename Expr>
142 template<
typename Tape,
typename... Args>
152 template<
typename Tape>
153 using FunctionForward =
decltype(&Tape::template statementEvaluateForwardInner<ActiveType<Tape>>);
156 template<
typename Tape>
157 using FunctionPrimal =
decltype(&Tape::template statementEvaluatePrimalInner<ActiveType<Tape>>);
160 template<
typename Tape>
161 using FunctionReverse =
decltype(&Tape::template statementEvaluateReverseInner<ActiveType<Tape>>);
164 template<
typename Tape>
#define CODI_DD(Type, Default)
Abbreviation for CODI_DECLARE_DEFAULT.
Definition macros.hpp:94
CoDiPack - Code Differentiation Package.
Definition codi.hpp:91
Counts the number of nodes that inherit from LhsExpressionInterface in the expression.
Definition expressionTraits.hpp:184
Counts the number of types that inherit from ConstantExpression in the expression.
Definition expressionTraits.hpp:210
Additional data required by an InnerStatementEvaluator.
Definition innerStatementEvaluator.hpp:53
size_t maxConstantArguments
Maximum number of constant arguments.
Definition innerStatementEvaluator.hpp:59
InnerPrimalTapeStatementData(size_t maxActiveArguments, size_t maxConstantArguments, typename Base::Handle forward, typename Base::Handle primal, typename Base::Handle reverse, typename Base::Handle writeInformation)
Constructor.
Definition innerStatementEvaluator.hpp:62
size_t maxActiveArguments
Maximum number of active arguments.
Definition innerStatementEvaluator.hpp:58
Definition innerStatementEvaluator.hpp:73
static InnerPrimalTapeStatementData const staticStore
Static storage.
Definition innerStatementEvaluator.hpp:78
Expression evaluation in the inner function. Data loading in the compilation context of the tape....
Definition innerStatementEvaluator.hpp:103
decltype(&Tape::template statementEvaluatePrimalInner< ActiveType< Tape > >) FunctionPrimal
Full primal function type.
Definition innerStatementEvaluator.hpp:157
static WriteInfo getWriteInformation(Handle const &h, Args &&... args)
Definition innerStatementEvaluator.hpp:143
static void callReverse(Handle const &h, Args &&... args)
Definition innerStatementEvaluator.hpp:130
decltype(&Tape::template statementGetWriteInformation< ActiveType< Tape > >) FunctionWriteInformation
Write information function type.
Definition innerStatementEvaluator.hpp:165
static Real callForward(Handle const &h, Args &&... args)
Definition innerStatementEvaluator.hpp:116
T_Real Real
See InnerStatementEvaluator.
Definition innerStatementEvaluator.hpp:106
decltype(&Tape::template statementEvaluateForwardInner< ActiveType< Tape > >) FunctionForward
Full forward function type.
Definition innerStatementEvaluator.hpp:153
decltype(&Tape::template statementEvaluateReverseInner< ActiveType< Tape > >) FunctionReverse
Full reverse function type.
Definition innerStatementEvaluator.hpp:161
static Handle createHandle()
Definition innerStatementEvaluator.hpp:137
static Real callPrimal(Handle const &h, Args &&... args)
Definition innerStatementEvaluator.hpp:123
InnerPrimalTapeStatementData const * Handle
Pointer to static storage location.
Definition innerStatementEvaluator.hpp:112
Data required for all possible handle calls.
Definition directStatementEvaluator.hpp:51
Handle forward
Forward function handle.
Definition directStatementEvaluator.hpp:56
void * Handle
Function pointer.
Definition directStatementEvaluator.hpp:54
Handle primal
Primal function handle.
Definition directStatementEvaluator.hpp:57
PrimalTapeStatementFunctions(Handle forward, Handle primal, Handle reverse, Handle writeInformation)
Constructor.
Definition directStatementEvaluator.hpp:61
Handle reverse
Reverse function handle.
Definition directStatementEvaluator.hpp:58
Handle writeInformation
Definition directStatementEvaluator.hpp:59
Creation of handles for the evaluation of expressions in a context where the expression type is not a...
Definition statementEvaluatorInterface.hpp:104
This class is used during the writing process of a primal value tape. The WriteInfo is returned by co...
Definition tapeReaderWriterInterface.hpp:69