mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Remove unused entry point to evmasm Assembly.
This commit is contained in:
parent
7c91dd05a7
commit
06820e1b1e
@ -397,26 +397,6 @@ AssemblyItem Assembly::newImmutableAssignment(string const& _identifier)
|
|||||||
return AssemblyItem{AssignImmutable, h};
|
return AssemblyItem{AssignImmutable, h};
|
||||||
}
|
}
|
||||||
|
|
||||||
Assembly& Assembly::optimise(bool _enable, EVMVersion _evmVersion, bool _isCreation, size_t _runs)
|
|
||||||
{
|
|
||||||
OptimiserSettings settings;
|
|
||||||
settings.isCreation = _isCreation;
|
|
||||||
settings.runInliner = true;
|
|
||||||
settings.runJumpdestRemover = true;
|
|
||||||
settings.runPeephole = true;
|
|
||||||
if (_enable)
|
|
||||||
{
|
|
||||||
settings.runDeduplicate = true;
|
|
||||||
settings.runCSE = true;
|
|
||||||
settings.runConstantOptimiser = true;
|
|
||||||
}
|
|
||||||
settings.evmVersion = _evmVersion;
|
|
||||||
settings.expectedExecutionsPerDeployment = _runs;
|
|
||||||
optimise(settings);
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
Assembly& Assembly::optimise(OptimiserSettings const& _settings)
|
Assembly& Assembly::optimise(OptimiserSettings const& _settings)
|
||||||
{
|
{
|
||||||
optimiseInternal(_settings, {});
|
optimiseInternal(_settings, {});
|
||||||
|
@ -134,13 +134,6 @@ public:
|
|||||||
/// is optimised according to the settings in @a _settings.
|
/// is optimised according to the settings in @a _settings.
|
||||||
Assembly& optimise(OptimiserSettings const& _settings);
|
Assembly& optimise(OptimiserSettings const& _settings);
|
||||||
|
|
||||||
/// Modify (if @a _enable is set) and return the current assembly such that creation and
|
|
||||||
/// execution gas usage is optimised. @a _isCreation should be true for the top-level assembly.
|
|
||||||
/// @a _runs specifes an estimate on how often each opcode in this assembly will be executed,
|
|
||||||
/// i.e. use a small value to optimise for size and a large value to optimise for runtime.
|
|
||||||
/// If @a _enable is not set, will perform some simple peephole optimizations.
|
|
||||||
Assembly& optimise(bool _enable, langutil::EVMVersion _evmVersion, bool _isCreation, size_t _runs);
|
|
||||||
|
|
||||||
/// Create a text representation of the assembly.
|
/// Create a text representation of the assembly.
|
||||||
std::string assemblyString(
|
std::string assemblyString(
|
||||||
langutil::DebugInfoSelection const& _debugInfoSelection = langutil::DebugInfoSelection::Default(),
|
langutil::DebugInfoSelection const& _debugInfoSelection = langutil::DebugInfoSelection::Default(),
|
||||||
|
Loading…
Reference in New Issue
Block a user