CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
Optimizer.hpp
Go to the documentation of this file.
1//
2// CeresEngine - A game development framework
3//
4// Created by Rogiel Sulzbach.
5// Copyright (c) 2018-2022 Rogiel Sulzbach. All rights reserved.
6//
7
8#pragma once
9
10#include "Visitor.hpp"
11
13
15
16 //TODO: replace this class by "ExpressionConverter".
17
18 // This AST optimizer supports only little optimizations such as null-statement removal.
59
60} // namespace CeresEngine::ShaderCompiler
#define DECLARATION_VISIT_PROC(CLASS_NAME)
Definition Visitor.hpp:88
Definition Optimizer.hpp:19
void optimizeStatementList(Vector< StatementPtr > &statements)
bool canRemoveStatement(const Statement &ast) const
void optimizeExpression(ExpressionPtr &expression)
Definition Visitor.hpp:92
Definition AST.hpp:33
SPtr< Expression > ExpressionPtr
Definition Visitor.hpp:26
std::vector< T, ScopedAllocatorAdaptor< StdAllocator< T, RawAllocator > > > Vector
Vector is a sequence container that encapsulates dynamic size arrays.
Definition Vector.hpp:17
constexpr size_t hash(const T &v)
Generates a hash for the provided type.
Definition Hash.hpp:25
Definition AST.hpp:1159