Skip to content

FunctionEvaluationOrderTraversal

Traverses a given AST and finds all function calls in the order in which they're evaluated Also, for each function we find where to put declarations of temporary variables so that they're accessible at the function call

Synopsis

Declared in <src/midend/programTransformation/extractFunctionArgumentsNormalization/functionEvaluationOrderTraversal.h>

Base Classes

Name

Description

AstTopDownBottomUpProcessing<FunctionCallInheritedAttribute, bool>

Attribute evaluator for inherited and synthesized attributes.

Member Functions

Name

Description

IsFunctionCallSideEffectFree [virtual]

Returns true if the function call has no side effects.

evaluateInheritedAttribute [virtual]

Visits AST nodes in pre‐order

evaluateSynthesizedAttribute [virtual]

Visits AST nodes in post‐order. This is function‐evaluation order.

Static Member Functions

Name

Description

GetFunctionCalls

Traverses the subtree of the given AST node and finds all function calls in function‐evaluation order.

Private Member Functions

Name

Description

FunctionEvaluationOrderTraversal [constructor]

Private constructor. Use the static method to access the functionality of this class.

Private Data Members

Name

Description

nonNormalizableFunctionCalls

All the function calls seen so far that can't be normalized.

normalizableFunctionCalls

All the function calls seen so far that can be normalized.

Created with MrDocs