Commit Graph
325 Commits
Author SHA1 Message Date
Kamil Śliwak 2cd1c644b6 Remove unused includes and sort existing includes in a few places 2021-10-11 20:34:48 +02:00
chriseth 1531863835 Split Common.h into Numeric.h. 2021-09-23 15:27:29 +02:00
chriseth c8e6ef9657 Merge pull request #12004 from ethereum/disambiguateBytesRequired
Disambiguate bytesRequired
2021-09-23 15:25:44 +02:00
Kamil Śliwak ce4420f857 Separate DebugData fields for Solidity and Yul source locations 2021-09-22 13:11:39 +02:00
chriseth 50ce1f5ddd Disambiguate bytesRequired 2021-09-22 11:22:07 +02:00
chriseth e6f0fe8ae3 Use source id in yul to evm code transform. 2021-09-22 11:11:51 +02:00
chriseth a66e6f08c0 Merge pull request #11951 from ethereum/scopeFillerNullptr
Use locationOf helper instead of accessing debugData directly.
2021-09-14 15:43:01 +02:00
Daniel Kirchner 854b8b65b5 Better source locations in Yul ControlFlowGraph and OptimizedEVMCodeTransform. 2021-09-14 13:43:16 +02:00
Daniel Kirchner 75c3286311 Optimized EVM Code Transform. 2021-09-14 13:37:04 +02:00
Daniel Kirchner 7abc55d89a Use locationOf helper instead of accessing debugData directly. 2021-09-14 10:04:09 +02:00
Daniel Kirchner d512f7a4fd Merge pull request #11890 from ethereum/stackLayoutGeneratorReportTooDeep
Report stack too deep and conditional stack compression in StackLayoutGenerator.
2021-09-08 10:28:30 +02:00
Daniel Kirchner a683ea7646 Remove the expression callback from the code generator functions of Yul builtins. 2021-09-06 17:07:53 +02:00
Daniel Kirchner e022ba1bfb Report stack too deep and conditionally aggressively compress stack in StackLayoutGenerator. 2021-09-06 09:08:04 +02:00
Daniel Kirchner d384664dcb Merge pull request #11615 from ethereum/yulStackLayoutGenerator
Yul Stack Layout Generator (New Code Transform Step 2)
2021-09-03 13:13:18 +02:00
chriseth 7f137d352a Merge pull request #11869 from ethereum/remodelUseSrc
Allow and require use-src to be repeated for each object.
2021-09-02 18:34:07 +02:00
Daniel Kirchner f881409ea4 Stack layout generator for new code generation. 2021-09-02 17:47:19 +02:00
chriseth 5caa15879b Allow and require use-src to be repeated for each object. 2021-09-02 11:29:42 +02:00
Daniel Kirchner c82f9b9fab Mark recursive calls in yul control flow graph. 2021-08-19 16:54:43 +02:00
chriseth 90c4623460 Some more base fees. 2021-08-12 16:37:21 +02:00
chriseth a4c94a1b5b Fixed inline assembly external identifier access. 2021-08-11 18:18:29 +02:00
hrkrshnn 7f1a2be0fe Allow basefee as Yul identifier for EVMVersion < london
This was done to prevent basefee from being a breaking change. This change will be removed in 0.9.0.

TODO revert this commit in breaking.
2021-08-11 10:46:08 +02:00
chriseth 467cbf92bc Only provide code generator to CodeTransform. 2021-08-04 18:38:10 +02:00
Christian Parpart 6294aa871a Simplify AsmParser::parse(.) usage 2021-08-03 15:43:17 +02:00
chriseth ffc5cfd9a5 Remove scanner from compiler stack. 2021-08-03 15:43:17 +02:00
Daniel Kirchner f3707f2ab0 Control flow graph for Yul. 2021-07-15 15:24:12 +02:00
chriseth f75b55071e Remove CharStream from SourceLocation. 2021-07-14 15:12:07 +02:00
chriseth 8d5e82b406 Fix source location of builtin function calls. 2021-07-06 16:54:29 +02:00
Daniel Kirchner bc288aacf5 Have the stack optimization in the code transform only reuse slots that are reachable and fix argument slot reuse on functions without return variables. 2021-06-28 18:11:57 +02:00
chriseth 0df8a38e55 Support metadata via IR. 2021-06-21 18:20:31 +02:00
chriseth fe35512feb Remove EVMAssembly. 2021-06-08 18:41:22 +02:00
TerranCivilian c15501eea9 Remove unneeded include files 2021-06-07 12:53:18 -04:00
chriseth f9c94d7c42 Note function entry points. 2021-05-04 17:15:13 +02:00
Djordje Mijovic e404b6e7a6 Refactoring yul source locations. 2021-05-04 16:05:23 +02:00
Alex Beregszaszi 176ce4edf7 Split EthAssemblyAdapter from AsmCodeGen 2021-04-27 11:31:15 +01:00
chriseth cb1af8b88a Make verbatim compatible with KnownState. 2021-04-26 19:56:44 +02:00
chriseth e2d8005737 Add verbatim builtin. 2021-04-26 19:56:44 +02:00
Alexander Arlt fc7fb3cb7d [ewasm] Polyfill: callvalue, gasprice & difficulty. 2021-04-23 15:54:10 +01:00
hrkrshnn 011f8d3ff7 Changed the type of gas calculation to bigint instead of size_t
Since the gas calculation can involve multiplication by ``--optimize-runs``, it is possible that
`size_t` is not enough to represent the total gas.
2021-04-22 18:19:47 +02:00
hrkrshnn 94f9410abe Added hashFunction to Dialect. For EVMDialect, it is keccak256
In a later PR, the functions `storageLoadFunction`, `storageStoreFunctions`, etc will be refactored
to return a YulString instead of a pointer to a BuiltinFunction.
2021-04-22 17:27:57 +02:00
hrkrshnn dd6300a53e GasMeter can now account for gas of Keccak-256 2021-04-22 17:27:57 +02:00
hrkrshnn 1f5b874eaf Optimizer context has parameter expectedExecutionsPerDeployment 2021-04-22 17:27:57 +02:00
Daniel Kirchner 5bebbca273 Extract VariableReferenceCounter and StackTooDeep error from EVMCodeTransform. 2021-04-13 10:41:16 +02:00
chriseth 2856f56525 Merge pull request #10942 from ethereum/returnSlotAllocation
Delayed return slot allocation.
2021-04-08 16:42:07 +02:00
anurag4u80 b2ca7916aa Replaced boost::adaptors::transformed 2021-04-08 17:38:14 +05:30
Daniel Kirchner 35c2eeab68 Restrict to only popping, but not reusing argument slots, as well as only freeing up until the return slots are allocated. 2021-04-06 13:38:06 +02:00
Daniel Kirchner 4b0f8383a6 Reuse function argument slots and defer allocation of return variable slots in EVMCodeTransform. 2021-04-06 13:38:05 +02:00
anurag4u80 bbcdddeed9 Replaced keys, values and reverse with ranges 2021-03-31 23:33:04 +05:30
hrkrshnn 6d9e9e1b1e Fix small bug in GasMeter calculation in creation context
Old calculation did not ignore `optimize-runs` parameter, when creation code gas computations were
done. This would lead to expanding values such as `shl(180, 1)` inside constructor code, even for
the default value for `--optimize-runs`, i.e., 200.
2021-03-17 12:33:10 +01:00
Daniel Kirchner a75424eec4 Drop support for evm15 and eip-615. 2021-03-09 15:56:03 +01:00
Mathias Baumann e4f1257c83 Yul Backend: Get rid of heuristics for finding the matching runtime 2021-02-09 14:50:25 +01:00