#ifndef V8_COMPILER_CONTROL_PATH_STATE_H_
#define V8_COMPILER_CONTROL_PATH_STATE_H_
#include "src/compiler/functional-list.h"
#include "src/compiler/graph-reducer.h"
#include "src/compiler/graph.h"
#include "src/compiler/node-aux-data.h"
#include "src/compiler/node-properties.h"
#include "src/compiler/node.h"
#include "src/compiler/persistent-map.h"
#include "src/zone/zone.h"
namespace v8 {
namespace internal {
namespace compiler {
enum NodeUniqueness { … };
template <typename NodeState, NodeUniqueness node_uniqueness>
class ControlPathState { … };
template <typename NodeState, NodeUniqueness node_uniqueness>
class AdvancedReducerWithControlPathState : public AdvancedReducer { … };
template <typename NodeState, NodeUniqueness node_uniqueness>
NodeState ControlPathState<NodeState, node_uniqueness>::LookupState(
Node* node) const { … }
template <typename NodeState, NodeUniqueness node_uniqueness>
void ControlPathState<NodeState, node_uniqueness>::AddState(
Zone* zone, Node* node, NodeState state,
ControlPathState<NodeState, node_uniqueness> hint) { … }
template <typename NodeState, NodeUniqueness node_uniqueness>
void ControlPathState<NodeState, node_uniqueness>::AddStateInNewBlock(
Zone* zone, Node* node, NodeState state) { … }
template <typename NodeState, NodeUniqueness node_uniqueness>
void ControlPathState<NodeState, node_uniqueness>::ResetToCommonAncestor(
ControlPathState<NodeState, node_uniqueness> other) { … }
#if DEBUG
template <typename NodeState, NodeUniqueness node_uniqueness>
bool ControlPathState<NodeState, node_uniqueness>::BlocksAndStatesInvariant() { … }
#endif
template <typename NodeState, NodeUniqueness node_uniqueness>
Reduction AdvancedReducerWithControlPathState<
NodeState, node_uniqueness>::TakeStatesFromFirstControl(Node* node) { … }
template <typename NodeState, NodeUniqueness node_uniqueness>
Reduction
AdvancedReducerWithControlPathState<NodeState, node_uniqueness>::UpdateStates(
Node* state_owner, ControlPathState<NodeState, node_uniqueness> new_state) { … }
template <typename NodeState, NodeUniqueness node_uniqueness>
Reduction
AdvancedReducerWithControlPathState<NodeState, node_uniqueness>::UpdateStates(
Node* state_owner, ControlPathState<NodeState, node_uniqueness> prev_states,
Node* additional_node, NodeState additional_state, bool in_new_block) { … }
}
}
}
#endif