diff options
author | Dimitry <dimitry@ethereum.org> | 2018-02-16 02:42:28 +0800 |
---|---|---|
committer | Dimitry <dimitry@ethereum.org> | 2018-02-16 02:42:28 +0800 |
commit | 346bb9efa9be7b231139beddb9cc76ebd7836a01 (patch) | |
tree | 03510739cf33e7f0277b19d2d36d795ed641cabf /src/GeneralStateTestsFiller | |
parent | f62640eeabf3066fa9726c8a61dfa5d50e7daf44 (diff) | |
download | dexon-tests-346bb9efa9be7b231139beddb9cc76ebd7836a01.tar.gz dexon-tests-346bb9efa9be7b231139beddb9cc76ebd7836a01.tar.zst dexon-tests-346bb9efa9be7b231139beddb9cc76ebd7836a01.zip |
fix stPreCompiledContracts2
Diffstat (limited to 'src/GeneralStateTestsFiller')
5 files changed, 110 insertions, 6 deletions
diff --git a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexpRandomInputFiller.json b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexpRandomInputFiller.json index eed5fd0f5..a622c0bda 100644 --- a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexpRandomInputFiller.json +++ b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexpRandomInputFiller.json @@ -15,7 +15,7 @@ { "indexes" : { "data" : 0, - "gas" : 0, + "gas" : -1, "value" : -1 }, "network" : [">=Byzantium"], @@ -25,7 +25,7 @@ } } }, - { + { "indexes" : { "data" : 1, "gas" : 0, @@ -38,7 +38,20 @@ } } }, - { + { + "indexes" : { + "data" : 1, + "gas" : 1, + "value" : -1 + }, + "network" : [">=Byzantium"], + "result" : { + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "999999999999993000000" + } + } + }, + { "indexes" : { "data" : 2, "gas" : 1, @@ -50,6 +63,19 @@ "balance" : "999999999999993000000" } } + }, + { + "indexes" : { + "data" : 2, + "gas" : 0, + "value" : -1 + }, + "network" : [">=Byzantium"], + "result" : { + "a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "999999999999999290000" + } + } } ], "pre": { diff --git a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_20500Filler.json b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_20500Filler.json index 937f86db9..d1e8e5c4b 100644 --- a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_20500Filler.json +++ b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_20500Filler.json @@ -169,6 +169,84 @@ "storage": {} } } + }, + { + "indexes": { + "data": 0, + "gas": [1,2,3], + "value": 0 + }, + "network": [ + ">=Byzantium" + ], + "result": { + "0000000000000000000000000000000000000001": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "c305c901078781c232a2a521c2af7980f8385ee9": { + "balance": "0", + "nonce": "1", + "code": "0x600035601c52740100000000000000000000000000000000000000006020526fffffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff000000000000000000000000000000016060527402540be3fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffdabf41c00000000000000000000000002540be40060a0526330c8d1da600051141561012b5760846004356004013511151558576004356004013560200160043560040161014037600161024061014051610160600060056305f5e0fff11558576001610220526102206021806102808284600060046015f150505061028080516020820120905060005561028060206020820352604081510160206001820306601f820103905060208203f350005b", + "storage": { + "0x00" : "0xbc36789e7a1e281436464229828f817d6612f7b477d66591ff96a9e064bcc98a" + } + }, + "0000000000000000000000000000000000000005": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "0000000000000000000000000000000000000008": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "0000000000000000000000000000000000000003": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "82a978b3f5962a5b0957d9ee9eef472ee55b42f1": { + "nonce": "2", + "code": "0x", + "storage": {} + }, + "0000000000000000000000000000000000000006": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "0000000000000000000000000000000000000007": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "0000000000000000000000000000000000000004": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + }, + "3535353535353535353535353535353535353535": { + "nonce": "0", + "code": "0x", + "storage": {} + }, + "0000000000000000000000000000000000000002": { + "balance": "1", + "nonce": "0", + "code": "0x", + "storage": {} + } + } } ], "explanation": "Puts the base 0, exponent 0 and modulus 0 into the MODEXP precompile, saves the hash of the result. Gives the execution 20500 gas" diff --git a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_22000Filler.json b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_22000Filler.json index 9e0c00858..f8cbd915d 100644 --- a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_22000Filler.json +++ b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_22000Filler.json @@ -95,7 +95,7 @@ { "indexes": { "data": 0, - "gas": 0, + "gas": -1, "value": 0 }, "network": [ diff --git a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_25000Filler.json b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_25000Filler.json index 6e2314014..38306007d 100644 --- a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_25000Filler.json +++ b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_25000Filler.json @@ -95,7 +95,7 @@ { "indexes": { "data": 0, - "gas": 0, + "gas": -1, "value": 0 }, "network": [ diff --git a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_35000Filler.json b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_35000Filler.json index 967b90986..a174d5145 100644 --- a/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_35000Filler.json +++ b/src/GeneralStateTestsFiller/stPreCompiledContracts2/modexp_0_0_0_35000Filler.json @@ -95,7 +95,7 @@ { "indexes": { "data": 0, - "gas": 0, + "gas": -1, "value": 0 }, "network": [ |