Commit Graph

160 Commits

Author SHA1 Message Date
Alex Beregszaszi
2a5772cff7 Mark appropriate constructors explicit 2017-08-22 10:51:46 +01:00
Alex Beregszaszi
e2cfc9ee92 Mark a lot of functions const (where possible) 2017-08-22 10:51:46 +01:00
chriseth
2c5985de06 Be more strict about number literals in assembly. 2017-08-21 13:31:28 +02:00
Alex Beregszaszi
b5da5f6e42 Merge pull request #2504 from ethereum/inlineasm-decl-empty
Support variable declarations without an assignment in assembly
2017-07-13 16:58:24 +02:00
Alex Beregszaszi
8d90e6fc4e Rename expectedItems to numVariables 2017-07-13 15:18:40 +02:00
Alex Beregszaszi
cee93d946d Support parsing let statements without a value 2017-07-13 15:18:18 +02:00
chriseth
09e821619e Refactor exceptions and provide comment function. 2017-07-13 11:34:03 +02:00
Alex Beregszaszi
7798a27112 Add Julia mode as an option to EVMCodeTransform 2017-07-03 10:13:36 +01:00
Alex Beregszaszi
d4fecc7b11 Warn on JUMP/JUMPI in inline assembly 2017-06-30 20:47:14 +01:00
Alex Beregszaszi
5cf2332d6d Support appendAssemblySize() in AbstractAssembly 2017-06-23 00:09:35 +01:00
Alex Beregszaszi
d5f8ce90c7 Merge interface/Exceptions and interface/Utils 2017-06-22 11:25:07 +01:00
chriseth
868b5ad3aa Split block code generation into main and finalize. 2017-06-16 10:56:21 +01:00
chriseth
78b49db779 Helper to count the number of variables in a scope. 2017-06-16 10:56:21 +01:00
chriseth
8e5c4bf21d Add include file to forward-declare inline assembly structs. 2017-06-16 10:56:21 +01:00
chriseth
49b1112117 For loops analysis. 2017-06-16 10:56:21 +01:00
Alex Beregszaszi
47925bc14e Parse for statement in assembly parser / printer 2017-06-16 10:56:21 +01:00
Alex Beregszaszi
42b61171d9 Merge pull request #2192 from winsvega/develop
add STATICCALL instruction
2017-06-14 21:03:32 +01:00
chriseth
fd5bf16101 Merge pull request #2384 from ethereum/parseFunctionalInstructions
Enforce function arguments when parsing functional instructions.
2017-06-14 18:35:16 +02:00
Dimitry
c20cdd0a05 add new opcode instructions to the parser
STATICCALL        0xfa  6 inputs  (gas address mem1 mem2 mem3 mem4)
2017-06-14 18:18:12 +02:00
Alex Beregszaszi
a921bd0ae4 Display user friendly instruction name 2017-06-14 16:00:39 +02:00
Alex Beregszaszi
494b9dbfaa Issue warning for using CREATE2 in inline assembly 2017-06-14 16:00:39 +02:00
chriseth
1b1f35762e Enforce function arguments when parsing functional instructions. 2017-06-14 14:51:47 +02:00
chriseth
43cfab70d0 Merge pull request #2389 from ethereum/moveLabelIDs
Move LabelIDs to generation phase.
2017-06-14 14:12:33 +02:00
chriseth
154002cda0 Move "active variable" to analysis phase. 2017-06-14 00:10:33 +02:00
chriseth
1bf717fd65 Remove struct constructor. 2017-06-14 00:03:08 +02:00
chriseth
c554145f4d Move stack height to generation phase. 2017-06-14 00:01:06 +02:00
chriseth
45d96959f8 Move LabelIDs to generation phase. 2017-06-13 22:01:15 +02:00
Alex Beregszaszi
05af6c9255
Warn if returndatasize/returndatacopy is used 2017-06-13 16:57:07 +02:00
Alex Beregszaszi
fe3b46554a Merge pull request #2362 from ethereum/lowercase_instructions
Use lowercase when reporting instruction error.
2017-06-09 14:49:59 +01:00
chriseth
bf2b5c746a Use lowercase when reporting instruction error. 2017-06-09 15:17:29 +02:00
Alex Beregszaszi
1da3af161f Simplify CodeGenerator by remove seldom used case 2017-06-09 12:45:56 +01:00
Alex Beregszaszi
114c157b04 Remove obsolete AsmStack 2017-06-09 11:43:41 +01:00
chriseth
6b3e7f79cf Comments and consistent variable names. 2017-06-09 10:45:36 +01:00
chriseth
308a726ad1 Fix: Copy resolver. 2017-06-08 15:52:45 +02:00
chriseth
b32d5e4cc0 Visitor bugfix. 2017-06-08 15:52:45 +02:00
chriseth
ef3d5874fe Remove error reporter from code generation phase. 2017-06-08 15:52:45 +02:00
chriseth
19f707aeaa Some more comments. 2017-06-08 15:52:45 +02:00
chriseth
0185f3cbf6 Correct stack height adjustment after returnsub. 2017-06-08 15:52:45 +02:00
chriseth
fefd3b866d Introduce machine-dependent stack adjustment. 2017-06-08 15:52:45 +02:00
chriseth
97cc968a13 Initial EVM1.5 assembly implementation. 2017-06-08 15:52:44 +02:00
chriseth
d5408f78ad Add comma. 2017-06-01 15:56:49 +02:00
chriseth
40f3e4413b Improved error message. 2017-06-01 15:31:07 +02:00
chriseth
05004253ba Refactor to use expectExpression in analyzer. 2017-06-01 14:28:39 +02:00
chriseth
d4a57d81ba Merge pull request #2317 from ethereum/keccak256
Use keccak256 in tests and replace the SHA3 instruction in assembly
2017-05-30 19:34:28 +02:00
Rhett Aultman
89b60ffbd4 Refactor error reporting
This commit introduces ErrorReporter, a utility class which consolidates
all of the error logging functionality into a common set of functions.
It also replaces all direct interactions with an ErrorList with calls to
an ErrorReporter.

This commit resolves issue #2209
2017-05-30 07:28:31 -07:00
Alex Beregszaszi
75e4a2be1b Alias sha3 to keccak256 in inline assembly 2017-05-30 10:54:29 +01:00
chriseth
8b29cc5535 Merge pull request #2319 from ethereum/virtualBlocks
Introduce virtual blocks for function arguments.
2017-05-29 16:52:51 +02:00
chriseth
4af55c78eb Introduce virtual blocks for function arguments. 2017-05-29 16:18:16 +02:00
chriseth
9adff68ecc Introduce LabelID typedef. 2017-05-29 15:40:32 +02:00
chriseth
2c4a107f43 Merge pull request #2311 from ethereum/julia-types
Validate types for Julia (part 1)
2017-05-29 14:12:38 +02:00