Opened 8 years ago
Closed 8 years ago
#4000 closed enhancement (fixed)
Module EvaluateFunctions.evaluateConstantFunctionCallExp takes very long for some kinds of models
Reported by: | Patrick Täuber | Owned by: | Patrick Täuber |
---|---|---|---|
Priority: | high | Milestone: | Future |
Component: | Backend | Version: | |
Keywords: | function evaluation, SiemensPower | Cc: |
Description
Function evaluateFunctions_updateStatement
, which is called from evaluateConstantFunctionCallExp
, takes very long for some models with many nested functions, because of a very deep recursion level.
The module is called to evaluate parameter function-bindings to a constant value, if possible. In most cases the module spots at the end that it is not possible, so all the effort is for nothing.
Because of that, the module only should be called if the function can be definetly evaluated, i.e. if the function arguments are already evaluated constants (final parameters and parameters dependent on them).
In OMCompiler/295b0a4 a flag is added to only evaluate parameter function-bindings with constant arguments. Default: --evalConstArgsOnly=true