Rename AsmData -> AST

Also attempt to only include ASTForward where appropriate.
This commit is contained in:
Alex Beregszaszi 2020-10-29 14:00:27 +00:00
parent 7eb5fc31f8
commit a22077f736
157 changed files with 175 additions and 152 deletions

View File

@ -17,7 +17,7 @@
// SPDX-License-Identifier: GPL-3.0 // SPDX-License-Identifier: GPL-3.0
#include <libsolidity/analysis/ControlFlowBuilder.h> #include <libsolidity/analysis/ControlFlowBuilder.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
using namespace solidity; using namespace solidity;

View File

@ -27,7 +27,7 @@
#include <libyul/AsmAnalysis.h> #include <libyul/AsmAnalysis.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>

View File

@ -23,7 +23,7 @@
#include <libsolidity/interface/Version.h> #include <libsolidity/interface/Version.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>
#include <liblangutil/SemVerHandler.h> #include <liblangutil/SemVerHandler.h>

View File

@ -28,7 +28,7 @@
#include <libyul/AsmAnalysis.h> #include <libyul/AsmAnalysis.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>

View File

@ -18,7 +18,7 @@
#include <libsolidity/analysis/ViewPureChecker.h> #include <libsolidity/analysis/ViewPureChecker.h>
#include <libsolidity/ast/ExperimentalFeatures.h> #include <libsolidity/ast/ExperimentalFeatures.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>
#include <libevmasm/SemanticInformation.h> #include <libevmasm/SemanticInformation.h>

View File

@ -45,7 +45,7 @@
namespace solidity::yul namespace solidity::yul
{ {
// Forward-declaration to <yul/AsmData.h> // Forward-declaration to <yul/AST.h>
struct Block; struct Block;
struct Dialect; struct Dialect;
} }

View File

@ -26,8 +26,8 @@
#include <libsolidity/ast/TypeProvider.h> #include <libsolidity/ast/TypeProvider.h>
#include <libyul/AsmJsonConverter.h> #include <libyul/AsmJsonConverter.h>
#include <libyul/AsmData.h>
#include <libyul/AsmPrinter.h> #include <libyul/AsmPrinter.h>
#include <libyul/AST.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <libsolutil/JSON.h> #include <libsolutil/JSON.h>

View File

@ -25,6 +25,7 @@
#include <libyul/AsmJsonImporter.h> #include <libyul/AsmJsonImporter.h>
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>
#include <libyul/AST.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>

View File

@ -32,6 +32,7 @@
#include <libyul/AsmPrinter.h> #include <libyul/AsmPrinter.h>
#include <libyul/AsmAnalysis.h> #include <libyul/AsmAnalysis.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AST.h>
#include <libyul/backends/evm/AsmCodeGen.h> #include <libyul/backends/evm/AsmCodeGen.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <libyul/backends/evm/EVMMetrics.h> #include <libyul/backends/evm/EVMMetrics.h>

View File

@ -31,7 +31,7 @@
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AsmAnalysis.h> #include <libyul/AsmAnalysis.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/backends/evm/AsmCodeGen.h> #include <libyul/backends/evm/AsmCodeGen.h>
#include <libyul/backends/evm/EVMMetrics.h> #include <libyul/backends/evm/EVMMetrics.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>

View File

@ -35,7 +35,7 @@
#include <libevmasm/GasMeter.h> #include <libevmasm/GasMeter.h>
#include <libyul/AsmPrinter.h> #include <libyul/AsmPrinter.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/optimiser/ASTCopier.h> #include <libyul/optimiser/ASTCopier.h>

View File

@ -60,6 +60,7 @@
#include <libyul/AsmJsonConverter.h> #include <libyul/AsmJsonConverter.h>
#include <libyul/AssemblyStack.h> #include <libyul/AssemblyStack.h>
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>
#include <libyul/AST.h>
#include <liblangutil/Scanner.h> #include <liblangutil/Scanner.h>
#include <liblangutil/SemVerHandler.h> #include <liblangutil/SemVerHandler.h>

View File

@ -25,6 +25,7 @@
#include <libsolidity/interface/Version.h> #include <libsolidity/interface/Version.h>
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>
#include <libyul/AST.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>
#include <liblangutil/Scanner.h> #include <liblangutil/Scanner.h>

View File

@ -23,7 +23,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>
#include <liblangutil/SourceLocation.h> #include <liblangutil/SourceLocation.h>

View File

@ -28,6 +28,7 @@
namespace solidity::yul namespace solidity::yul
{ {
enum class LiteralKind;
struct Literal; struct Literal;
struct Label; struct Label;
struct Identifier; struct Identifier;

View File

@ -21,7 +21,7 @@
#include <libyul/AsmAnalysis.h> #include <libyul/AsmAnalysis.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/AsmScopeFiller.h> #include <libyul/AsmScopeFiller.h>
#include <libyul/AsmScope.h> #include <libyul/AsmScope.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
@ -668,3 +668,8 @@ bool AsmAnalyzer::validateInstructions(evmasm::Instruction _instr, SourceLocatio
return true; return true;
} }
bool AsmAnalyzer::validateInstructions(FunctionCall const& _functionCall)
{
return validateInstructions(_functionCall.functionName.name.str(), _functionCall.functionName.location);
}

View File

@ -26,7 +26,7 @@
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/AsmScope.h> #include <libyul/AsmScope.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/backends/evm/AbstractAssembly.h> #include <libyul/backends/evm/AbstractAssembly.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
@ -114,10 +114,7 @@ private:
bool validateInstructions(evmasm::Instruction _instr, langutil::SourceLocation const& _location); bool validateInstructions(evmasm::Instruction _instr, langutil::SourceLocation const& _location);
bool validateInstructions(std::string const& _instrIdentifier, langutil::SourceLocation const& _location); bool validateInstructions(std::string const& _instrIdentifier, langutil::SourceLocation const& _location);
bool validateInstructions(FunctionCall const& _functionCall) bool validateInstructions(FunctionCall const& _functionCall);
{
return validateInstructions(_functionCall.functionName.name.str(), _functionCall.functionName.location);
}
yul::ExternalIdentifierAccess::Resolver m_resolver; yul::ExternalIdentifierAccess::Resolver m_resolver;
Scope* m_currentScope = nullptr; Scope* m_currentScope = nullptr;

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <map> #include <map>
#include <memory> #include <memory>

View File

@ -21,7 +21,7 @@
*/ */
#include <libyul/AsmJsonConverter.h> #include <libyul/AsmJsonConverter.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -23,7 +23,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <liblangutil/SourceLocation.h> #include <liblangutil/SourceLocation.h>
#include <json/json.h> #include <json/json.h>
#include <boost/variant.hpp> #include <boost/variant.hpp>

View File

@ -23,8 +23,7 @@
*/ */
#include <libyul/AsmJsonImporter.h> #include <libyul/AsmJsonImporter.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/AsmDataForward.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <liblangutil/Scanner.h> #include <liblangutil/Scanner.h>

View File

@ -25,7 +25,7 @@
#include <json/json.h> #include <json/json.h>
#include <liblangutil/SourceLocation.h> #include <liblangutil/SourceLocation.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <utility> #include <utility>

View File

@ -22,6 +22,7 @@
*/ */
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>
#include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <liblangutil/Scanner.h> #include <liblangutil/Scanner.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>

View File

@ -23,7 +23,7 @@
#pragma once #pragma once
#include <libyul/AsmData.h> #include <libyul/ASTForward.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <liblangutil/SourceLocation.h> #include <liblangutil/SourceLocation.h>

View File

@ -22,7 +22,7 @@
*/ */
#include <libyul/AsmPrinter.h> #include <libyul/AsmPrinter.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>

View File

@ -23,7 +23,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>

View File

@ -21,7 +21,7 @@
#include <libyul/AsmScopeFiller.h> #include <libyul/AsmScopeFiller.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/AsmScope.h> #include <libyul/AsmScope.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <functional> #include <functional>
#include <memory> #include <memory>

View File

@ -2,8 +2,8 @@ add_library(yul
AsmAnalysis.cpp AsmAnalysis.cpp
AsmAnalysis.h AsmAnalysis.h
AsmAnalysisInfo.h AsmAnalysisInfo.h
AsmData.h AST.h
AsmDataForward.h ASTForward.h
AsmJsonConverter.h AsmJsonConverter.h
AsmJsonConverter.cpp AsmJsonConverter.cpp
AsmJsonImporter.h AsmJsonImporter.h

View File

@ -22,7 +22,7 @@
#pragma once #pragma once
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/Object.h> #include <libyul/Object.h>
#include <map> #include <map>

View File

@ -20,7 +20,7 @@
*/ */
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
using namespace solidity::yul; using namespace solidity::yul;
using namespace std; using namespace std;

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>
#include <libsolutil/Common.h> #include <libsolutil/Common.h>

View File

@ -22,6 +22,7 @@
#include <libyul/ObjectParser.h> #include <libyul/ObjectParser.h>
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>
#include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <liblangutil/Token.h> #include <liblangutil/Token.h>

View File

@ -21,7 +21,7 @@
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -22,7 +22,7 @@
#pragma once #pragma once
#include <libsolutil/Common.h> #include <libsolutil/Common.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
namespace solidity::yul namespace solidity::yul
{ {

View File

@ -21,8 +21,8 @@
#include <libyul/backends/evm/AsmCodeGen.h> #include <libyul/backends/evm/AsmCodeGen.h>
#include <libyul/AsmData.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AST.h>
#include <libyul/backends/evm/AbstractAssembly.h> #include <libyul/backends/evm/AbstractAssembly.h>
#include <libyul/backends/evm/EVMCodeTransform.h> #include <libyul/backends/evm/EVMCodeTransform.h>

View File

@ -23,7 +23,7 @@
#include <libyul/optimiser/ASTCopier.h> #include <libyul/optimiser/ASTCopier.h>
#include <libyul/backends/evm/EVMMetrics.h> #include <libyul/backends/evm/EVMMetrics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -25,7 +25,7 @@
#include <libyul/YulString.h> #include <libyul/YulString.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <libyul/AsmData.h> #include <libyul/ASTForward.h>
#include <liblangutil/SourceLocation.h> #include <liblangutil/SourceLocation.h>

View File

@ -23,7 +23,7 @@
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <liblangutil/Exceptions.h> #include <liblangutil/Exceptions.h>

View File

@ -25,7 +25,7 @@
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/AsmScope.h> #include <libyul/AsmScope.h>
#include <optional> #include <optional>

View File

@ -22,7 +22,7 @@
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Object.h> #include <libyul/Object.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>

View File

@ -24,7 +24,7 @@
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/backends/evm/AbstractAssembly.h> #include <libyul/backends/evm/AbstractAssembly.h>
#include <libyul/AsmData.h> #include <libyul/ASTForward.h>
#include <liblangutil/EVMVersion.h> #include <liblangutil/EVMVersion.h>
#include <map> #include <map>

View File

@ -21,7 +21,7 @@
#include <libyul/backends/evm/EVMMetrics.h> #include <libyul/backends/evm/EVMMetrics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>

View File

@ -21,6 +21,7 @@
#include <libyul/backends/evm/NoOutputAssembly.h> #include <libyul/backends/evm/NoOutputAssembly.h>
#include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libevmasm/Instruction.h> #include <libevmasm/Instruction.h>

View File

@ -35,6 +35,7 @@
#include <libyul/AsmParser.h> #include <libyul/AsmParser.h>
#include <libyul/AsmAnalysis.h> #include <libyul/AsmAnalysis.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/AST.h>
#include <libyul/Object.h> #include <libyul/Object.h>
#include <liblangutil/ErrorReporter.h> #include <liblangutil/ErrorReporter.h>

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>

View File

@ -25,7 +25,7 @@
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>

View File

@ -22,7 +22,7 @@
#pragma once #pragma once
#include <libyul/backends/wasm/WasmAST.h> #include <libyul/backends/wasm/WasmAST.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libyul/optimiser/NameDispenser.h> #include <libyul/optimiser/NameDispenser.h>
#include <libyul/optimiser/TypeInfo.h> #include <libyul/optimiser/TypeInfo.h>

View File

@ -21,7 +21,7 @@
#include <libyul/backends/wasm/WasmDialect.h> #include <libyul/backends/wasm/WasmDialect.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
using namespace std; using namespace std;

View File

@ -16,7 +16,7 @@
*/ */
// SPDX-License-Identifier: GPL-3.0 // SPDX-License-Identifier: GPL-3.0
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/backends/wasm/WordSizeTransform.h> #include <libyul/backends/wasm/WordSizeTransform.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>

View File

@ -23,7 +23,7 @@
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/Common.h> #include <libsolutil/Common.h>

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>

View File

@ -21,7 +21,7 @@
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <boost/range/adaptor/reversed.hpp> #include <boost/range/adaptor/reversed.hpp>

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>

View File

@ -15,10 +15,13 @@
along with solidity. If not, see <http://www.gnu.org/licenses/>. along with solidity. If not, see <http://www.gnu.org/licenses/>.
*/ */
// SPDX-License-Identifier: GPL-3.0 // SPDX-License-Identifier: GPL-3.0
#include <libyul/optimiser/BlockFlattener.h> #include <libyul/optimiser/BlockFlattener.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/Visitor.h> #include <libsolutil/Visitor.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
#include <functional> #include <functional>
using namespace std; using namespace std;

View File

@ -21,7 +21,9 @@
#include <libyul/optimiser/BlockHasher.h> #include <libyul/optimiser/BlockHasher.h>
#include <libyul/optimiser/SyntacticalEquality.h> #include <libyul/optimiser/SyntacticalEquality.h>
#include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
using namespace std; using namespace std;

View File

@ -21,9 +21,8 @@
#pragma once #pragma once
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>
#include <libyul/AsmData.h>
namespace solidity::yul namespace solidity::yul
{ {

View File

@ -19,7 +19,7 @@
* Specific AST walker that generates the call graph. * Specific AST walker that generates the call graph.
*/ */
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/optimiser/CallGraphGenerator.h> #include <libyul/optimiser/CallGraphGenerator.h>
#include <stack> #include <stack>

View File

@ -19,7 +19,7 @@
#include <libyul/optimiser/CallGraphGenerator.h> #include <libyul/optimiser/CallGraphGenerator.h>
#include <libyul/optimiser/OptimizerUtilities.h> #include <libyul/optimiser/OptimizerUtilities.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/Algorithms.h> #include <libsolutil/Algorithms.h>

View File

@ -27,7 +27,7 @@
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/SideEffects.h> #include <libyul/SideEffects.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
using namespace std; using namespace std;

View File

@ -17,7 +17,7 @@
// SPDX-License-Identifier: GPL-3.0 // SPDX-License-Identifier: GPL-3.0
#include <libyul/optimiser/ConditionalSimplifier.h> #include <libyul/optimiser/ConditionalSimplifier.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -19,6 +19,7 @@
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/ASTForward.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libsolutil/Common.h> #include <libsolutil/Common.h>

View File

@ -17,7 +17,7 @@
// SPDX-License-Identifier: GPL-3.0 // SPDX-License-Identifier: GPL-3.0
#include <libyul/optimiser/ConditionalUnsimplifier.h> #include <libyul/optimiser/ConditionalUnsimplifier.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -19,7 +19,7 @@
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/optimiser/TypeInfo.h> #include <libyul/optimiser/TypeInfo.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -24,8 +24,8 @@
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
@ -39,7 +39,6 @@ using namespace solidity;
using namespace solidity::util; using namespace solidity::util;
using namespace solidity::yul; using namespace solidity::yul;
void DataFlowAnalyzer::operator()(ExpressionStatement& _statement) void DataFlowAnalyzer::operator()(ExpressionStatement& _statement)
{ {
if (auto vars = isSimpleStore(evmasm::Instruction::SSTORE, _statement)) if (auto vars = isSimpleStore(evmasm::Instruction::SSTORE, _statement))

View File

@ -26,7 +26,7 @@
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/optimiser/KnowledgeBase.h> #include <libyul/optimiser/KnowledgeBase.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>
#include <libyul/AsmData.h> #include <libyul/AST.h> // Needed for m_zero below.
#include <libyul/SideEffects.h> #include <libyul/SideEffects.h>
// TODO avoid // TODO avoid

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/DeadCodeEliminator.h> #include <libyul/optimiser/DeadCodeEliminator.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libevmasm/SemanticInformation.h> #include <libevmasm/SemanticInformation.h>
#include <libevmasm/AssemblyItem.h> #include <libevmasm/AssemblyItem.h>

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/Disambiguator.h> #include <libyul/optimiser/Disambiguator.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/AsmScope.h> #include <libyul/AsmScope.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/AsmAnalysisInfo.h> #include <libyul/AsmAnalysisInfo.h>
#include <libyul/optimiser/ASTCopier.h> #include <libyul/optimiser/ASTCopier.h>
#include <libyul/optimiser/NameDispenser.h> #include <libyul/optimiser/NameDispenser.h>

View File

@ -20,7 +20,7 @@
*/ */
#include <libyul/optimiser/EquivalentFunctionCombiner.h> #include <libyul/optimiser/EquivalentFunctionCombiner.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
using namespace std; using namespace std;

View File

@ -23,7 +23,7 @@
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/optimiser/EquivalentFunctionDetector.h> #include <libyul/optimiser/EquivalentFunctionDetector.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
namespace solidity::yul namespace solidity::yul
{ {

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/EquivalentFunctionDetector.h> #include <libyul/optimiser/EquivalentFunctionDetector.h>
#include <libyul/optimiser/SyntacticalEquality.h> #include <libyul/optimiser/SyntacticalEquality.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/optimiser/Metrics.h> #include <libyul/optimiser/Metrics.h>
using namespace std; using namespace std;

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/optimiser/BlockHasher.h> #include <libyul/optimiser/BlockHasher.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
namespace solidity::yul namespace solidity::yul
{ {

View File

@ -28,7 +28,7 @@
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
using namespace std; using namespace std;
using namespace solidity; using namespace solidity;

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <optional> #include <optional>
#include <set> #include <set>

View File

@ -25,7 +25,7 @@
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libyul/optimiser/OptimizerUtilities.h> #include <libyul/optimiser/OptimizerUtilities.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -21,7 +21,7 @@
*/ */
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <map> #include <map>
@ -32,7 +32,6 @@ namespace solidity::yul
class NameCollector; class NameCollector;
struct OptimiserStepContext; struct OptimiserStepContext;
/** /**
* Optimiser component that modifies an AST in place, turning sequences * Optimiser component that modifies an AST in place, turning sequences
* of variable declarations into complex expressions, if the variables * of variable declarations into complex expressions, if the variables

View File

@ -23,7 +23,7 @@
#include <libyul/optimiser/SimplificationRules.h> #include <libyul/optimiser/SimplificationRules.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
using namespace std; using namespace std;
using namespace solidity; using namespace solidity;

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/DataFlowAnalyzer.h> #include <libyul/optimiser/DataFlowAnalyzer.h>

View File

@ -26,7 +26,7 @@
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/optimiser/TypeInfo.h> #include <libyul/optimiser/TypeInfo.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -21,7 +21,7 @@
*/ */
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <libyul/optimiser/NameDispenser.h> #include <libyul/optimiser/NameDispenser.h>

View File

@ -18,7 +18,8 @@
#include <libyul/optimiser/ForLoopConditionIntoBody.h> #include <libyul/optimiser/ForLoopConditionIntoBody.h>
#include <libyul/optimiser/OptimiserStep.h> #include <libyul/optimiser/OptimiserStep.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
using namespace std; using namespace std;

View File

@ -18,8 +18,9 @@
#include <libyul/optimiser/ForLoopConditionOutOfBody.h> #include <libyul/optimiser/ForLoopConditionOutOfBody.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
using namespace std; using namespace std;

View File

@ -16,8 +16,10 @@
*/ */
// SPDX-License-Identifier: GPL-3.0 // SPDX-License-Identifier: GPL-3.0
#include <libyul/optimiser/ForLoopInitRewriter.h> #include <libyul/optimiser/ForLoopInitRewriter.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
#include <functional> #include <functional>
using namespace std; using namespace std;

View File

@ -30,7 +30,7 @@
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/optimiser/CallGraphGenerator.h> #include <libyul/optimiser/CallGraphGenerator.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Dialect.h> #include <libyul/Dialect.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -20,7 +20,7 @@
*/ */
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/ASTCopier.h> #include <libyul/optimiser/ASTCopier.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>

View File

@ -16,7 +16,7 @@
*/ */
#include <libyul/optimiser/FunctionCallFinder.h> #include <libyul/optimiser/FunctionCallFinder.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
using namespace std; using namespace std;
using namespace solidity; using namespace solidity;

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/FunctionGrouper.h> #include <libyul/optimiser/FunctionGrouper.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <boost/range/algorithm_ext/erase.hpp> #include <boost/range/algorithm_ext/erase.hpp>

View File

@ -22,7 +22,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
namespace solidity::yul namespace solidity::yul
{ {

View File

@ -23,7 +23,7 @@
#include <libyul/optimiser/FunctionHoister.h> #include <libyul/optimiser/FunctionHoister.h>
#include <libyul/optimiser/OptimizerUtilities.h> #include <libyul/optimiser/OptimizerUtilities.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -22,7 +22,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
namespace solidity::yul namespace solidity::yul

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/InlinableExpressionFunctionFinder.h> #include <libyul/optimiser/InlinableExpressionFunctionFinder.h>
#include <libyul/optimiser/OptimizerUtilities.h> #include <libyul/optimiser/OptimizerUtilities.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
using namespace std; using namespace std;
using namespace solidity; using namespace solidity;

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/optimiser/ASTWalker.h> #include <libyul/optimiser/ASTWalker.h>
#include <set> #include <set>

View File

@ -21,7 +21,7 @@
#include <libyul/optimiser/KnowledgeBase.h> #include <libyul/optimiser/KnowledgeBase.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/optimiser/SimplificationRules.h> #include <libyul/optimiser/SimplificationRules.h>
#include <libyul/optimiser/DataFlowAnalyzer.h> #include <libyul/optimiser/DataFlowAnalyzer.h>

View File

@ -21,8 +21,9 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
#include <libyul/YulString.h> #include <libyul/YulString.h>
#include <map> #include <map>
namespace solidity::yul namespace solidity::yul

View File

@ -26,7 +26,7 @@
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/optimiser/CallGraphGenerator.h> #include <libyul/optimiser/CallGraphGenerator.h>
#include <libyul/SideEffects.h> #include <libyul/SideEffects.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
using namespace std; using namespace std;
using namespace solidity; using namespace solidity;

View File

@ -22,7 +22,7 @@
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libyul/optimiser/Semantics.h> #include <libyul/optimiser/Semantics.h>
#include <libyul/optimiser/SSAValueTracker.h> #include <libyul/optimiser/SSAValueTracker.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>
#include <utility> #include <utility>

View File

@ -25,7 +25,7 @@
#include <libyul/optimiser/NameCollector.h> #include <libyul/optimiser/NameCollector.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libsolutil/CommonData.h> #include <libsolutil/CommonData.h>

View File

@ -22,7 +22,7 @@
#pragma once #pragma once
#include <libyul/AsmDataForward.h> #include <libyul/ASTForward.h>
namespace solidity::yul namespace solidity::yul
{ {

View File

@ -20,7 +20,7 @@
#include <libyul/optimiser/Metrics.h> #include <libyul/optimiser/Metrics.h>
#include <libyul/AsmData.h> #include <libyul/AST.h>
#include <libyul/Exceptions.h> #include <libyul/Exceptions.h>
#include <libyul/Utilities.h> #include <libyul/Utilities.h>
#include <libyul/backends/evm/EVMDialect.h> #include <libyul/backends/evm/EVMDialect.h>

Some files were not shown because too many files have changed in this diff Show More