Skip to content

Commit

Permalink
Enable EIP-1559 and EIP-2930 cases, and fix access-list, max-fee-per-…
Browse files Browse the repository at this point in the history
…gas and max-priority-fee-per-gas parsing in testool. (#1079)
  • Loading branch information
silathdiir authored Jan 11, 2024
1 parent 556fc28 commit e42db81
Show file tree
Hide file tree
Showing 11 changed files with 239 additions and 49 deletions.
6 changes: 4 additions & 2 deletions geth-utils/l1geth/trace.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,10 @@ type Transaction struct {
GasTipCap *hexutil.Big `json:"gas_tip_cap"`
CallData hexutil.Bytes `json:"call_data"`
AccessList []struct {
Address common.Address `json:"address"`
StorageKeys []common.Hash `json:"storage_keys"`
Address common.Address `json:"address"`
// Must be `storageKeys`, since `camelCase` is specified in ethers-rs.
// <https://github.com/gakonst/ethers-rs/blob/88095ba47eb6a3507f0db1767353b387b27a6e98/ethers-core/src/types/transaction/eip2930.rs#L75>
StorageKeys []common.Hash `json:"storageKeys"`
} `json:"access_list"`
}

Expand Down
6 changes: 4 additions & 2 deletions geth-utils/l2geth/trace.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,10 @@ type Transaction struct {
GasTipCap *hexutil.Big `json:"gas_tip_cap"`
CallData hexutil.Bytes `json:"call_data"`
AccessList []struct {
Address common.Address `json:"address"`
StorageKeys []common.Hash `json:"storage_keys"`
Address common.Address `json:"address"`
// Must be `storageKeys`, since `camelCase` is specified in ethers-rs.
// <https://github.com/gakonst/ethers-rs/blob/88095ba47eb6a3507f0db1767353b387b27a6e98/ethers-core/src/types/transaction/eip2930.rs#L75>
StorageKeys []common.Hash `json:"storageKeys"`
} `json:"access_list"`
Type string `json:"tx_type"`
V int64 `json:"v"`
Expand Down
7 changes: 4 additions & 3 deletions testool/Config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -190,10 +190,11 @@ tests = []
[[skip_paths]]
desc = "unimplemented"
paths = [
"EIP1559",
"stExample/eip1559Filler.yml",
# "EIP1559",
# "stExample/eip1559Filler.yml",
"stEIP1559/valCausesOOFFiller.yml",
"stExample/mergeTestFiller.yml",
"EIP2930",
# "EIP2930",
#"stPreCompiledContracts",
#"stZeroKnowledge"
]
Expand Down
58 changes: 58 additions & 0 deletions testool/codehash.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8250,3 +8250,61 @@ ef05bea5645aa48c5e7325bb1a23119c961290af1c112594ee1aa06e054277db=5b61c3506080511
31d87b82490b345887422d30c21c0ce23b669af6171f9d386e845f68fdc272f7=6000600060006000600073bbbf5374fce5edbc8e2a8697c15331677e6ebf0b5af1600055600160015500
2be93bf90fda15c9f97e8936c2ed1850d6dac4aa07c7df2805f827f73c522c56=5b61c3506080511015603e576000600061c350600073aaaf5374fce5edbc8e2a8697c15331677e6ebf0b620186a0fa6000556001608051016080526000565b60805160205500
bfa65cd1585cc6bda1710e286b92a295032f7d4ddcd78151566fbd2bebfcb1af=60005460005500
845731d3a84982b2898a85c463d8552018afc8153efd3da3406be4937c9c7a2d=5a600052600080600080620f424061ba5e5af1505a60205260216020516000510303600055
60dddb7cb27e627921ce8a0ce7456a17f134e4880b54f4bffaa7782ebbcd1a41=486000526000516040526021603ff3
c83d13fe03c8582ad1196031d75cbd6a44c8841ac43ff7d629f84e419c33ddfd=3a6000526000516040526021603ff3
d96b4fa95327924ee96f6212dfe2a65146614e7ead071e7fa854cc779ed17772=60018001600055
01cae6f0724d785b4ce2ac83cea7d6f826f04bfcfdaefea4c1584d54461b35fb=600060006000600061c0575af400
525ff263800e28e7349317c5883862d3ed709f2e0109ebb14a57392d18590ef4=5a600052600260005560115a600051030360005260005160015500
02725d4132dbd9f67369c09aef936e2a68578c7e755bcc2eba7d09b953965bfe=3331600055
4721b7ec7dc8d7d56ac8b1417a78df240173b8a7aa74081292f32dfc321dbc08=60006000351461001157600050610018565b6101016020525b60016000351461002a5760005061002f565b326020525b60026000351461004157600050610046565b336020525b6003600035146100585760005061005d565b306020525b60046000351461006f57600050610075565b60016020525b60005160005260006020351461008d576000506100b6565b5a600052602051315060165a60005103036000555a600052602051315060165a60005103036001555b6001602035146100c8576000506100f1565b5a6000526020513b5060165a60005103036000555a6000526020513b5060165a60005103036001555b6002602035146101035760005061012c565b5a6000526020513f5060165a60005103036000555a6000526020513f5060165a60005103036001555b60036020351461013e5760005061017a565b6106a5610100525a600052602060006101006020513c60205a60005103036000555a600052602060006101006020513c60205a60005103036001555b00
da6eae5f15e950a9b763f8d14d747f821cd2fca4f39ade4b42d36629a7ac16f1=4860005260206000f3
605387e067d9c0410eb2df922839bde6d9bd4e31966d475b7ec466ed5e223410=3a60005260206000f3
da8a38488d632b23985f95fe4da99a9189c52b497247fdbe5eb563c51fb985db=6000600060006000600061c0575af100
3452769bf2d3ba773b1ca4df7a432faaabce711c787f5e075d81313453c9254f=5a6000526000545060135a600051030360005260005160015500
b57709911888ba34ad65885f4220b0af83516e3d8fbf7f3efc1225f4500022d4=600435610100526024356101205260406000604061010060006101005af15060005160005560205160015500
4ca45a618de30bcf972ef1fe54652b46f5de89d8490541d721683f83ff73db11=600435600180602061c0de3b63c0dec0de3b6160a7600052856000811461015b5760f181146101645760f281146101785760f4811461018c5760fa811461019f5761f1f181146101b25761f2f181146101c85761f4f181146101de5761faf181146101f35761f1f281146102085761f2f2811461021e5761f4f281146102345761faf281146102495761f1f4811461025e5761f2f481146102745761f4f4811461028a5761faf4811461029f5761f1fa81146102b45761f2fa81146102ca5761f4fa81146102e05761fafa81146102f55760fd811461030a5760fe81146103415760ff811461037a5760f081146103b25760f581146103d55761f0f181146103fb5761f5f181146104255761f0f281146104525761f5f281146104755761f0f4811461049b5761f5f481146104bd5761f0fa81146104e25761f5fa811461050b576460baccfa5781146105375765bad0bad0bad0600052610551565b48600052610551565b602060008060008061ca115af19550610551565b602060008060008061ca115af29550610551565b6020600080600061ca115af49550610551565b6020600080600061ca115afa9550610551565b602060008060008063ca1100f15af19550610551565b602060008060008063ca1100f15af29550610551565b6020600080600063ca1100f15af49550610551565b6020600080600063ca1100f15afa9550610551565b602060008060008063ca1100f25af19550610551565b602060008060008063ca1100f25af29550610551565b6020600080600063ca1100f25af49550610551565b6020600080600063ca1100f25afa9550610551565b602060008060008063ca1100f45af19550610551565b602060008060008063ca1100f45af29550610551565b6020600080600063ca1100f45af49550610551565b6020600080600063ca1100f45afa9550610551565b602060008060008063ca1100fa5af19550610551565b602060008060008063ca1100fa5af29550610551565b6020600080600063ca1100fa5af49550610551565b6020600080600063ca1100fa5afa9550610551565b4860005260005160005560008060008060006260bacc5af150486000526000516000541461033c57640badbadbad6000525b610551565b486000526000516000556000806000806000620600066161a8f150486000526000516000541461037557640badbadbad6000525b610551565b48600052600051600055600080600080600063deaddead5af15048600052600051600054146103ad57640badbadbad6000525b610551565b8260008561c0de3c8284670de0b6b3a7640000f09450602060016000873c610551565b8260008561c0de3c615a178385670de0b6b3a7640000f59450602060016000873c610551565b8160008563c0dec0de3c8184670de0b6b3a7640000f094506020600080600080895af19550610551565b8160008563c0dec0de3c615a178285670de0b6b3a7640000f594506020600080600080895af19550610551565b8160008563c0dec0de3c81846000f094506020600080600080895af29550610551565b8160008563c0dec0de3c615a1782856000f594506020600080600080895af29550610551565b8160008563c0dec0de3c81846000f0945060206000806000885af49550610551565b8160008563c0dec0de3c615a1782856000f5945060206000806000885af49550610551565b8160008563c0dec0de3c8184670de0b6b3a7640000f0945060206000806000885afa9550610551565b8160008563c0dec0de3c615a178285670de0b6b3a7640000f5945060206000806000885afa9550610551565b6103ff6000526020600060206000806460baccfa575af195505b508461055d5760206000fd5b836105685760206000fd5b600051600055505050505050
c93ba7f931ec2bc09d69e4d6edbf690566163f6bae42b5c8fc07f4b4d4a05927=600435600180602061c0de3b63c0dec0de3b6160a7600052856000811461015b5760f181146101645760f281146101785760f4811461018c5760fa811461019f5761f1f181146101b25761f2f181146101c85761f4f181146101de5761faf181146101f35761f1f281146102085761f2f2811461021e5761f4f281146102345761faf281146102495761f1f4811461025e5761f2f481146102745761f4f4811461028a5761faf4811461029f5761f1fa81146102b45761f2fa81146102ca5761f4fa81146102e05761fafa81146102f55760fd811461030a5760fe81146103415760ff811461037a5760f081146103b25760f581146103d55761f0f181146103fb5761f5f181146104255761f0f281146104525761f5f281146104755761f0f4811461049b5761f5f481146104bd5761f0fa81146104e25761f5fa811461050b576460baccfa5781146105375765bad0bad0bad0600052610551565b3a600052610551565b602060008060008061ca115af19550610551565b602060008060008061ca115af29550610551565b6020600080600061ca115af49550610551565b6020600080600061ca115afa9550610551565b602060008060008063ca1100f15af19550610551565b602060008060008063ca1100f15af29550610551565b6020600080600063ca1100f15af49550610551565b6020600080600063ca1100f15afa9550610551565b602060008060008063ca1100f25af19550610551565b602060008060008063ca1100f25af29550610551565b6020600080600063ca1100f25af49550610551565b6020600080600063ca1100f25afa9550610551565b602060008060008063ca1100f45af19550610551565b602060008060008063ca1100f45af29550610551565b6020600080600063ca1100f45af49550610551565b6020600080600063ca1100f45afa9550610551565b602060008060008063ca1100fa5af19550610551565b602060008060008063ca1100fa5af29550610551565b6020600080600063ca1100fa5af49550610551565b6020600080600063ca1100fa5afa9550610551565b3a60005260005160005560008060008060006260bacc5af1503a6000526000516000541461033c57640badbadbad6000525b610551565b3a6000526000516000556000806000806000620600066161a8f1503a6000526000516000541461037557640badbadbad6000525b610551565b3a600052600051600055600080600080600063deaddead5af1503a600052600051600054146103ad57640badbadbad6000525b610551565b8260008561c0de3c8284670de0b6b3a7640000f09450602060016000873c610551565b8260008561c0de3c615a178385670de0b6b3a7640000f59450602060016000873c610551565b8160008563c0dec0de3c8184670de0b6b3a7640000f094506020600080600080895af19550610551565b8160008563c0dec0de3c615a178285670de0b6b3a7640000f594506020600080600080895af19550610551565b8160008563c0dec0de3c81846000f094506020600080600080895af29550610551565b8160008563c0dec0de3c615a1782856000f594506020600080600080895af29550610551565b8160008563c0dec0de3c81846000f0945060206000806000885af49550610551565b8160008563c0dec0de3c615a1782856000f5945060206000806000885af49550610551565b8160008563c0dec0de3c8184670de0b6b3a7640000f0945060206000806000885afa9550610551565b8160008563c0dec0de3c615a178285670de0b6b3a7640000f5945060206000806000885afa9550610551565b6103ff6000526020600060206000806460baccfa575af195505b508461055d5760206000fd5b836105685760206000fd5b600051600055505050505050
3bdfc895faf417bafd0313c21f94e235ef9e89648aa071ea18294a6a31a612e5=6000600060006000600061c0575af200
e726686d2da798215abe8da6734aab9586e39e7955c034fc79dd662143876579=5a600052600060005560115a600051030360005260005160015500
4b3076d90148be6a57ee0f8664f418b79e5a681104311f0675cc3f4850a0fd32=4860005260206000f3
e33b84b2b1532e0da8a5c46692c0a5b44be00c989dec3423afeffbe66c7e2722=3a60005260206000f3
da38b2e85f60fa27816a05665e62bf6e4d91c708ebbe52a79db36eb7f7b71469=5a60005261beef60005560115a600051030360005260005160015500
432e921be7ac770f9ee868727c305ccadefb5707d8d39a4357acad736e29b4a7=5a600052600260005560115a60005103036000526000516001555a6000526160a75460205260105a600051030360005260005160025500
dd10fd1bb55c9f939057557203376a231ebb053f749d3bcc6c6327b7d2866ca3=48600052600051600055fe
0b08ede4b4ec174cd57606b4a4b72aff13dcb3178c7a1d4b9dacf3053cddd213=3a600052600051600055fe
67c963506a78d643699af333073558cd98add3b86f326feced32525ebe902472=602060006000600063ead0c0575afa5060005160005500
eda1d174cdcfe8b80d0320f3339558b25f1b2872b79c9cdd571ed1d1d1502022=4860005260005160005560206000fd
d402943e0b38dbf034c9871cc38209b2d5b2efe6cfbf52c11e54b1df8ee165a6=5a6000526160a760005560115a600051030360005260005160015500
ca6960368354058d37a1a6188785e0dafac7c3d5e4574bc4d01e789cc598f3df=3a60005260005160005560206000fd
e2293505d71d1d4628a1af87a4a9111e6d24773ba7a370ef63f8cdf3d6b73db1=5a600052600060005560115a600051030360005260005160015500
b4cb701811a4a98af09efef975fa30d9d1d8ac0be2b0f0af403df7bbff4785a6=5a6000526160a75460205260135a600051030360005260206000f300
aac70c97ac5694eda55c663bda4d482cfbfe184526b1b06ec945dd77db05d257=600035600081036013574860005260206000f35b600181036000526020600060206000806460baccfa575af160345760206000fd5b60206000f3
9012d5ed7b2d23330f06815b204434a4a17c92aefd690f980293939abc98189b=600035600081036013573a60005260206000f35b600181036000526020600060206000806460baccfa575af160345760206000fd5b60206000f3
b29c3aa79a8cc5809eeafead664dce4a662649de06a441c56f358ef51e0944ad=6160a76000555a600052600260005560115a600051030360005260005160015500
c11d3fec086da5e76de1c4a321b0abda9cf64c526e9b5fc2e81c29b51a0a3ff2=5a600052600260005560115a60005103036000525a6020526160a754604052601a5a602051030360205260406000fd00
bd794ebe35dc42e461d9b334512fbdf2e68fdaf1182f41625ad9a59092066616=5a6000526000600060006000600063dead01115af150617fe85a600051030360005500
1526df0d0e1512b9f1ec9e3a25c40cf1b0ed3f0f37ac7c0d34b70330e0704816=6160a76000555a6000526000545060135a600051030360005260005160015500
80c7b81c77933d7b16c609934268f26c36afbd28cc1f0937dac4f167bf48d454=6000546020525a600052600260005560115a600051030360005260005160015500
6a2c88b7c3dda43ba8f5e88c514613802fdaec87f23917be2429da4d0a833387=61dead6000556000ff00
83629d1d3423e43f136c63f07c6c05a247abdb2347ae5e41a6eb77320f437839=6000546020525a6000526000545060135a600051030360005260005160015500
2d08aff8b66e2efa92b8042c303dae98cd96bde81f5e59415257a690c27761fd=5a6000526000600060006000600063dead01125af150617fe85a600051030360005500
a15d05ad8a7684f4907c05b8127a97364aca717c083cf9cb52333bcfe78a1c94=600054506000ff00
55688b2ea5331023bcc58bd53a0fddc33b38f849a4a03200d064604d357a0730=60006000600060006000600435610100015af1505a6000526160a7545060135a60005103036000526000516001555a600052600260005560115a600051030360005260005160025500
b6a727038a928b7ed3c9ae098292026bbde0daebc67546abbee9586daa023051=610bad600052602060006000600061f1135afa5060005160005500
f5d3c5c6cb67b4955a128cb40923db25bc17f826f8fbc03e9001b378f513d579=63dead60a760005561600d60005260206000f300
3a4c42bb50e184de8bc1f19dfa8a797adabd010cfca71b5ff6df06b356396e5c=6020600060006000600061f114610b65f100
1a0defc6fa59aa9daad84d820685178d063138473c2244a47d948bc72675e2b1=61600d60005500
c9fd1a848bb6509f49a8eede9d0f4256cee5c280f9615b9289189fe04b4ea658=6020600060006000600061f115611800f100
2c883ea2085149bb4c927d5f8a6005b6f9d1284b0d9c9d3618e894127f6040cc=6160a75460005261600d60005500
263e3ba2f1be3838edbe97d9a5833704b94e35ec310aacf72bdeebd952d67ece=600054505a600052600261beef5560115a60005103036000525a6020526160a75460a05260235a60205103036020525a60405261beef60005461f000015560785a60405103036040525a60605260005461f010015450607a5a60605103036060526000516000546101000155602051600054610200015560405160005461030001556060516000546104000155600060005411609b57600060b4565b600160005403600055600060006000600060006101165af15b00
7c7e18ace7e9fd9ac70095435133aed076d6a6addf8b8a59cea56a900a173236=60068060336101003961020052602180603960003961022052610200516101000160006000f0610240526102405160015500fe60ff600055005a60005261ffff6000555a6000510360015561010061010060003960106000f300
3b9cdb86e075f42bba45af5f85799494fb8478f94ecbc19bc486454febed156e=60068060366101003961020052602180603c60003961022052615a17610200516101000160006000f5610240526102405160015500fe60ff600055005a60005261ffff6000555a6000510360015561010061010060003960106000f300
3fd049e1accc65249fb0f137b5716867a3bca1353dcaf8042319f7cf0a26f472=60138060446101003961020052600f80605760003961022052610200516101000160006000f06102405260006000600060006000610240515af1506102405160015500fe5a60005261ffff6000555a600051036001550061010061010060003960806000f300
b1186f97995f3827a2ccb9e648d8d766828aa5aaa956261629987a5cde03068e=60138060476101003961020052600f80605a60003961022052615a17610200516101000160006000f56102405260006000600060006000610240515af1506102405160015500fe5a60005261ffff6000555a600051036001550061010061010060003960806000f300
335ad7b7050975a2987ada3ce30d0258668f95982c398354346252f98e4d8506=60138060446101003961020052602180605760003961022052610200516101000160006000f06102405260006000600060006000610240515af1506102405160015500fe5a60005261ffff6000555a60005103600255005a60005261ffff6000555a6000510360015561010061010060003960806000f300
054b2b2175ff410a3e55f65b9b11989a29c5b862655bfc418bb03380f468d8e0=60138060476101003961020052602180605a60003961022052615a17610200516101000160006000f56102405260006000600060006000610240515af1506102405160015500fe5a60005261ffff6000555a60005103600255005a60005261ffff6000555a6000510360015561010061010060003960806000f300
2cb5795ea1f7cf399e5c74d79d2fa7c4250ee5a8d91f7daf6ecb00425c4d5f14=6000600060006000600061f1265af1506000600060006000600061f1265af100
49d91eb5811006981ac40efbe002466cb963cf8edfd290173c7ecd0e0acf5975=5a6000526160a76000555a60005103600052600060015414602457600051600255602b565b6000516001555b00
2135574766477befd8479b710ced5a46de981168fb1af38db06b9e42bdadf582=60406000600060006000600435610100015af15060005160005560205160015500
ae3feab7e0150c20f952d7456530c6a222a057caafe5a7854472a9b766126ead=3a6000554860015500
6 changes: 3 additions & 3 deletions testool/docker/lllc/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ FROM alpine:3.15.6 AS build

WORKDIR /solidity

RUN apk update && apk add boost-dev boost-static build-base cmake git
RUN apk update && apk add boost-dev boost-static build-base cmake git z3-dev

RUN git clone https://github.com/ethereum/solidity .
RUN git checkout 8f2595957bfc0f3cd18ca29240dabcd6b2122dfd
RUN git clone https://github.com/winsvega/lllc .
RUN git checkout 2b34e1d437bab8b92242262456fc922de86d0d30
COPY patch.diff patch.diff
RUN patch -p1 < patch.diff

Expand Down
2 changes: 1 addition & 1 deletion testool/docker/solc/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ WORKDIR /solidity
RUN apk update && apk add boost-dev boost-static build-base cmake git

RUN git clone https://github.com/ethereum/solidity .
RUN git checkout v0.8.13
RUN git checkout v0.8.19

WORKDIR /solidity/build
RUN cmake .. -DCMAKE_BUILD_TYPE=Release
Expand Down
Loading

0 comments on commit e42db81

Please sign in to comment.