Pass "optimize stack allocation" flag down to the stack compressor.

This commit is contained in:
chriseth committed 2019-03-20 15:03:27 +01:00
1 parent 556d11dae0
commit 38cbf8d230
11 files changed
+27 -14

No files matched your search

+4 -1
View File
@@ -135,7 +135,10 @@ void AssemblyStack::optimize(Object& _object)
for (auto& subNode: _object.subObjects)
if (auto subObject = dynamic_cast<Object*>(subNode.get()))
optimize(*subObject);
OptimiserSuite::run(languageToDialect(m_language, m_evmVersion), *_object.code, *_object.analysisInfo);
// TODO: Store this as setting - it should be the same as the flag passed to
// ::assemble(...)
bool optimizeStackAllocation = false;
OptimiserSuite::run(languageToDialect(m_language, m_evmVersion), *_object.code, *_object.analysisInfo, optimizeStackAllocation);
}
MachineAssemblyObject AssemblyStack::assemble(Machine _machine, bool _optimize) const