Add inlining for old optimizer.

This commit is contained in:
Daniel Kirchner
2021-02-09 19:08:58 +01:00
parent e777cad78a
commit cb74a45fd6
43 changed files with 1463 additions and 74 deletions
+6 -6
View File
@@ -101,7 +101,7 @@ BOOST_AUTO_TEST_CASE(string_storage)
if (CommonOptions::get().useABIEncoderV1)
CHECK_DEPLOY_GAS(133045, 129731, evmVersion);
else
CHECK_DEPLOY_GAS(155553, 135201, evmVersion);
CHECK_DEPLOY_GAS(155553, 132103, evmVersion);
}
// This is only correct on >=Constantinople.
else if (!CommonOptions::get().useABIEncoderV1)
@@ -110,9 +110,9 @@ BOOST_AUTO_TEST_CASE(string_storage)
{
// Costs with 0 are cases which cannot be triggered in tests.
if (evmVersion < EVMVersion::istanbul())
CHECK_DEPLOY_GAS(0, 122869, evmVersion);
CHECK_DEPLOY_GAS(0, 120189, evmVersion);
else
CHECK_DEPLOY_GAS(0, 110701, evmVersion);
CHECK_DEPLOY_GAS(0, 108541, evmVersion);
}
else
{
@@ -131,16 +131,16 @@ BOOST_AUTO_TEST_CASE(string_storage)
{
callContractFunction("f()");
if (evmVersion == EVMVersion::byzantium())
CHECK_GAS(21741, 21555, 20);
CHECK_GAS(21741, 21522, 20);
// This is only correct on >=Constantinople.
else if (!CommonOptions::get().useABIEncoderV1)
{
if (CommonOptions::get().optimize)
{
if (evmVersion < EVMVersion::istanbul())
CHECK_GAS(0, 21567, 20);
CHECK_GAS(0, 21526, 20);
else
CHECK_GAS(0, 21351, 20);
CHECK_GAS(0, 21318, 20);
}
else
{