From bb8ae92d0b480a953215b4a8a22c153354814ad7 Mon Sep 17 00:00:00 2001 From: "refcell.eth" Date: Wed, 19 Jul 2023 15:22:04 -0400 Subject: [PATCH] Move the fault dispute game game duration to the deploy config and set immutably. (#6351) Co-authored-by: clabby --- op-bindings/bindings/faultdisputegame.go | 39 +++++++++++++-- op-bindings/bindings/faultdisputegame_more.go | 2 +- op-challenger/fault/abi_test.go | 1 + packages/contracts-bedrock/.gas-snapshot | 47 +++++++++---------- .../contracts/dispute/FaultDisputeGame.sol | 8 ++-- .../contracts/test/FaultDisputeGame.t.sol | 7 ++- .../deploy-config/devnetL1.json | 5 +- .../contracts-bedrock/scripts/Deploy.s.sol | 1 + .../scripts/DeployConfig.s.sol | 2 + 9 files changed, 77 insertions(+), 35 deletions(-) diff --git a/op-bindings/bindings/faultdisputegame.go b/op-bindings/bindings/faultdisputegame.go index c067a1295420..88c060e54704 100644 --- a/op-bindings/bindings/faultdisputegame.go +++ b/op-bindings/bindings/faultdisputegame.go @@ -30,8 +30,8 @@ var ( // FaultDisputeGameMetaData contains all meta data concerning the FaultDisputeGame contract. var FaultDisputeGameMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_maxGameDepth\",\"type\":\"uint256\"},{\"internalType\":\"contractIBigStepper\",\"name\":\"_vm\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotDefendRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockNotExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockTimeExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameDepthExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameNotInProgress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidParent\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPrestate\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValidStep\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"parentIndex\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"claimant\",\"type\":\"address\"}],\"name\":\"Move\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"enumGameStatus\",\"name\":\"status\",\"type\":\"uint8\"}],\"name\":\"Resolved\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"ABSOLUTE_PRESTATE\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_GAME_DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"VM\",\"outputs\":[{\"internalType\":\"contractIBigStepper\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"attack\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bondManager\",\"outputs\":[{\"internalType\":\"contractIBondManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"claimData\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"parentIndex\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"countered\",\"type\":\"bool\"},{\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"internalType\":\"Position\",\"name\":\"position\",\"type\":\"uint128\"},{\"internalType\":\"Clock\",\"name\":\"clock\",\"type\":\"uint128\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimDataLen\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"len_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createdAt\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"createdAt_\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"defend\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"extraData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameData\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameStart\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameType\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l2BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_challengeIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"}],\"name\":\"move\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resolve\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"status_\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rootClaim\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"status\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x61014060405234801561001157600080fd5b50604051620021c7380380620021c78339810160408190526100329161005d565b6000608081905260a052600360c05260e092909252610100526001600160a01b0316610120526100a3565b60008060006060848603121561007257600080fd5b83516020850151604086015191945092506001600160a01b038116811461009857600080fd5b809150509250925092565b60805160a05160c05160e05161010051610120516120b162000116600039600081816103aa01526113d60152600081816102c20152818161061701528181610b7501526111da0152600081816101bd01526113140152600061095d015260006109340152600061090b01526120b16000f3fe60806040526004361061016a5760003560e01c80638129fc1c116100cb578063bcef3b551161007f578063cf09e0d011610059578063cf09e0d01461049c578063d8cc1a3c146104bb578063fa24f743146104db57600080fd5b8063bcef3b55146103e8578063c55cd0c714610425578063c6f0308c1461043857600080fd5b80638b85902b116100b05780638b85902b146103585780639293129814610398578063bbdc02db146103cc57600080fd5b80638129fc1c1461032e5780638980e0cc1461034357600080fd5b8063363cc4271161012257806354fd4d501161010757806354fd4d50146102e4578063609d333414610306578063632247ea1461031b57600080fd5b8063363cc427146102515780634778efe8146102b057600080fd5b80632810e1d6116101535780632810e1d6146101ed5780633218b99d1461020257806335fef5671461023c57600080fd5b8063200d2ed21461016f578063266198f9146101ab575b600080fd5b34801561017b57600080fd5b506000546101959068010000000000000000900460ff1681565b6040516101a29190611b3a565b60405180910390f35b3480156101b757600080fd5b506101df7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020016101a2565b3480156101f957600080fd5b506101956104ff565b34801561020e57600080fd5b506000546102239067ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016101a2565b61024f61024a366004611b7b565b6108f4565b005b34801561025d57600080fd5b5060005461028b906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101a2565b3480156102bc57600080fd5b506101df7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102f057600080fd5b506102f9610904565b6040516101a29190611c17565b34801561031257600080fd5b506102f96109a7565b61024f610329366004611c46565b6109b9565b34801561033a57600080fd5b5061024f610f73565b34801561034f57600080fd5b506001546101df565b34801561036457600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003602001356101df565b3480156103a457600080fd5b5061028b7f000000000000000000000000000000000000000000000000000000000000000081565b3480156103d857600080fd5b50604051600081526020016101a2565b3480156103f457600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356101df565b61024f610433366004611b7b565b6110b4565b34801561044457600080fd5b50610458610453366004611c7b565b6110c0565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a0016101a2565b3480156104a857600080fd5b5060005467ffffffffffffffff16610223565b3480156104c757600080fd5b5061024f6104d6366004611cdd565b611131565b3480156104e757600080fd5b506104f0611655565b6040516101a293929190611d67565b60008060005468010000000000000000900460ff16600281111561052557610525611b0b565b1461055c576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001805460009161056c91611dc1565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff811015610656576000600182815481106105a6576105a6611dd8565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff64010000000090910416156105f75750610581565b600281015460009061063b906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611693565b90508381101561064f578093508260010194505b5050610581565b5060006001838154811061066c5761066c611dd8565b600091825260208220600390910201805490925063ffffffff908116919082146106d657600182815481106106a3576106a3611dd8565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610702565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b905062049d4061071c67ffffffffffffffff831642611dc1565b610738836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff1661074c9190611e07565b11610783576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600283810154610825906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b61082f9190611e4e565b67ffffffffffffffff1615801561085657506fffffffffffffffffffffffffffffffff8414155b156108645760029550610869565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff16680100000000000000008360028111156108ae576108ae611b0b565b0217905560028111156108c3576108c3611b0b565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b610900828260006109b9565b5050565b606061092f7f0000000000000000000000000000000000000000000000000000000000000000611748565b6109587f0000000000000000000000000000000000000000000000000000000000000000611748565b6109817f0000000000000000000000000000000000000000000000000000000000000000611748565b60405160200161099393929190611e75565b604051602081830303815290604052905090565b60606109b4602080611885565b905090565b6000805468010000000000000000900460ff1660028111156109dd576109dd611b0b565b14610a14576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610a20575080155b15610a57576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060018481548110610a6c57610a6c611dd8565b60009182526020918290206040805160a0810182526003909302909101805463ffffffff8116845260ff64010000000090910416151593830193909352600180840154918301919091526002909201546fffffffffffffffffffffffffffffffff80821660608401527001000000000000000000000000000000009091041660808201528154909250819086908110610b0757610b07611dd8565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909316929092179091556060820151610b71906fffffffffffffffffffffffffffffffff1684151760011b90565b90507f0000000000000000000000000000000000000000000000000000000000000000610c30826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610c72576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610cd2576001836000015163ffffffff1681548110610ca157610ca1611dd8565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610d0b846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610d1f9190611e07565b610d299190611dc1565b905062049d4067ffffffffffffffff82161115610d72576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b421790506000610d93888660009182526020526040902090565b60008181526002602052604090205490915060ff1615610ddf576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581528184018e81526fffffffffffffffffffffffffffffffff808d16606085019081528a82166080860190815286548088018855968a52945160039096027fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf68101805495511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000909616979099169690961793909317909655517fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf78401555190518416700100000000000000000000000000000000029316929092177fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf8909201919091555133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b600080547fffffffffffffffffffffffffffffffffffffffffffffff000000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff81526020810192909252600191908101610ff87ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff908116909152825460018181018555600094855260209485902084516003909302018054958501511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090961663ffffffff909316929092179490941781556040830151938101939093556060820151608090920151811670010000000000000000000000000000000002911617600290910155565b610900828260016109b9565b600181815481106110d057600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff16600281111561115557611155611b0b565b1461118c576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600187815481106111a1576111a1611dd8565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506112007f00000000000000000000000000000000000000000000000000000000000000006001611e07565b61129c826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff16146112dd576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080891561136357611301836fffffffffffffffffffffffffffffffff1661191c565b67ffffffffffffffff1660000361133a577f0000000000000000000000000000000000000000000000000000000000000000915061135c565b611355611348600186611eeb565b865463ffffffff166119c2565b6001015491505b508361137d565b8460010154915061137a8460016113489190611f1c565b90505b81898960405161138e929190611f50565b6040518091039020146113cd576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b81526004016114339493929190611fa9565b6020604051808303816000875af1158015611452573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114769190611fdb565b600284810154929091149250600091611521906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6115bd886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6115c79190611ff4565b6115d19190611e4e565b67ffffffffffffffff161590508115158103611619576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b6000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335606061168c6109a7565b9050909192565b600080611720847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b60608160000361178b57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156117b5578061179f81612015565b91506117ae9050600a8361204d565b915061178f565b60008167ffffffffffffffff8111156117d0576117d0612061565b6040519080825280601f01601f1916602001820160405280156117fa576020820181803683370190505b5090505b841561187d5761180f600183611dc1565b915061181c600a86612090565b611827906030611e07565b60f81b81838151811061183c5761183c611dd8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611876600a8661204d565b94506117fe565b949350505050565b606060006118bc84367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003611e07565b90508267ffffffffffffffff1667ffffffffffffffff8111156118e1576118e1612061565b6040519080825280601f01601f19166020018201604052801561190b576020820181803683370190505b509150828160208401375092915050565b6000806119a9837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b6000806119e0846fffffffffffffffffffffffffffffffff16611a5f565b9050600183815481106119f5576119f5611dd8565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff828116911614611a5857815460018054909163ffffffff16908110611a4357611a43611dd8565b90600052602060002090600302019150611a06565b5092915050565b60008119600183011681611af3827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310611b75577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60008060408385031215611b8e57600080fd5b50508035926020909101359150565b60005b83811015611bb8578181015183820152602001611ba0565b83811115611bc7576000848401525b50505050565b60008151808452611be5816020860160208601611b9d565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611c2a6020830184611bcd565b9392505050565b80358015158114611c4157600080fd5b919050565b600080600060608486031215611c5b57600080fd5b8335925060208401359150611c7260408501611c31565b90509250925092565b600060208284031215611c8d57600080fd5b5035919050565b60008083601f840112611ca657600080fd5b50813567ffffffffffffffff811115611cbe57600080fd5b602083019150836020828501011115611cd657600080fd5b9250929050565b60008060008060008060808789031215611cf657600080fd5b86359550611d0660208801611c31565b9450604087013567ffffffffffffffff80821115611d2357600080fd5b611d2f8a838b01611c94565b90965094506060890135915080821115611d4857600080fd5b50611d5589828a01611c94565b979a9699509497509295939492505050565b60ff84168152826020820152606060408201526000611d896060830184611bcd565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015611dd357611dd3611d92565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008219821115611e1a57611e1a611d92565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff80841680611e6957611e69611e1f565b92169190910692915050565b60008451611e87818460208901611b9d565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551611ec3816001850160208a01611b9d565b60019201918201528351611ede816002840160208801611b9d565b0160020195945050505050565b60006fffffffffffffffffffffffffffffffff83811690831681811015611f1457611f14611d92565b039392505050565b60006fffffffffffffffffffffffffffffffff808316818516808303821115611f4757611f47611d92565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b604081526000611fbd604083018688611f60565b8281036020840152611fd0818587611f60565b979650505050505050565b600060208284031215611fed57600080fd5b5051919050565b600067ffffffffffffffff83811690831681811015611f1457611f14611d92565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361204657612046611d92565b5060010190565b60008261205c5761205c611e1f565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008261209f5761209f611e1f565b50069056fea164736f6c634300080f000a", + ABI: "[{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_maxGameDepth\",\"type\":\"uint256\"},{\"internalType\":\"Duration\",\"name\":\"_gameDuration\",\"type\":\"uint64\"},{\"internalType\":\"contractIBigStepper\",\"name\":\"_vm\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotDefendRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockNotExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockTimeExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameDepthExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameNotInProgress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidParent\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPrestate\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValidStep\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"parentIndex\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"claimant\",\"type\":\"address\"}],\"name\":\"Move\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"enumGameStatus\",\"name\":\"status\",\"type\":\"uint8\"}],\"name\":\"Resolved\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"ABSOLUTE_PRESTATE\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"GAME_DURATION\",\"outputs\":[{\"internalType\":\"Duration\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_GAME_DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"VM\",\"outputs\":[{\"internalType\":\"contractIBigStepper\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"attack\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bondManager\",\"outputs\":[{\"internalType\":\"contractIBondManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"claimData\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"parentIndex\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"countered\",\"type\":\"bool\"},{\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"internalType\":\"Position\",\"name\":\"position\",\"type\":\"uint128\"},{\"internalType\":\"Clock\",\"name\":\"clock\",\"type\":\"uint128\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimDataLen\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"len_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createdAt\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"createdAt_\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"defend\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"extraData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameData\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameStart\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameType\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l2BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_challengeIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"}],\"name\":\"move\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resolve\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"status_\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rootClaim\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"status\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x6101606040523480156200001257600080fd5b50604051620022a8380380620022a8833981016040819052620000359162000071565b6000608081905260a052600360c05260e093909352610100919091526001600160401b0316610120526001600160a01b031661014052620000d8565b600080600080608085870312156200008857600080fd5b84516020860151604087015191955093506001600160401b0381168114620000af57600080fd5b60608601519092506001600160a01b0381168114620000cd57600080fd5b939692955090935050565b60805160a05160c05160e05161010051610120516101405161214462000164600039600081816103b501526114690152600081816104420152818161074e0152610d9f0152600081816102cd0152818161065601528181610bde015261126d0152600081816101c801526113a7015260006109c60152600061099d0152600061097401526121446000f3fe6080604052600436106101755760003560e01c80638980e0cc116100cb578063c31b29ce1161007f578063cf09e0d011610059578063cf09e0d0146104db578063d8cc1a3c146104fa578063fa24f7431461051a57600080fd5b8063c31b29ce14610430578063c55cd0c714610464578063c6f0308c1461047757600080fd5b806392931298116100b057806392931298146103a3578063bbdc02db146103d7578063bcef3b55146103f357600080fd5b80638980e0cc1461034e5780638b85902b1461036357600080fd5b8063363cc4271161012d578063609d333411610107578063609d333414610311578063632247ea146103265780638129fc1c1461033957600080fd5b8063363cc4271461025c5780634778efe8146102bb57806354fd4d50146102ef57600080fd5b80632810e1d61161015e5780632810e1d6146101f85780633218b99d1461020d57806335fef5671461024757600080fd5b8063200d2ed21461017a578063266198f9146101b6575b600080fd5b34801561018657600080fd5b506000546101a09068010000000000000000900460ff1681565b6040516101ad9190611bcd565b60405180910390f35b3480156101c257600080fd5b506101ea7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020016101ad565b34801561020457600080fd5b506101a061053e565b34801561021957600080fd5b5060005461022e9067ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016101ad565b61025a610255366004611c0e565b61095d565b005b34801561026857600080fd5b50600054610296906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101ad565b3480156102c757600080fd5b506101ea7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102fb57600080fd5b5061030461096d565b6040516101ad9190611caa565b34801561031d57600080fd5b50610304610a10565b61025a610334366004611cd9565b610a22565b34801561034557600080fd5b5061025a611006565b34801561035a57600080fd5b506001546101ea565b34801561036f57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003602001356101ea565b3480156103af57600080fd5b506102967f000000000000000000000000000000000000000000000000000000000000000081565b3480156103e357600080fd5b50604051600081526020016101ad565b3480156103ff57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356101ea565b34801561043c57600080fd5b5061022e7f000000000000000000000000000000000000000000000000000000000000000081565b61025a610472366004611c0e565b611147565b34801561048357600080fd5b50610497610492366004611d0e565b611153565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a0016101ad565b3480156104e757600080fd5b5060005467ffffffffffffffff1661022e565b34801561050657600080fd5b5061025a610515366004611d70565b6111c4565b34801561052657600080fd5b5061052f6116e8565b6040516101ad93929190611dfa565b60008060005468010000000000000000900460ff16600281111561056457610564611b9e565b1461059b576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180546000916105ab91611e54565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff811015610695576000600182815481106105e5576105e5611e6b565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff640100000000909104161561063657506105c0565b600281015460009061067a906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611726565b90508381101561068e578093508260010194505b50506105c0565b506000600183815481106106ab576106ab611e6b565b600091825260208220600390910201805490925063ffffffff9081169190821461071557600182815481106106e2576106e2611e6b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610741565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1661078567ffffffffffffffff831642611e54565b6107a1836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff166107b59190611e9a565b116107ec576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028381015461088e906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6108989190611ee1565b67ffffffffffffffff161580156108bf57506fffffffffffffffffffffffffffffffff8414155b156108cd57600295506108d2565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff166801000000000000000083600281111561091757610917611b9e565b02179055600281111561092c5761092c611b9e565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b61096982826000610a22565b5050565b60606109987f00000000000000000000000000000000000000000000000000000000000000006117db565b6109c17f00000000000000000000000000000000000000000000000000000000000000006117db565b6109ea7f00000000000000000000000000000000000000000000000000000000000000006117db565b6040516020016109fc93929190611f08565b604051602081830303815290604052905090565b6060610a1d602080611918565b905090565b6000805468010000000000000000900460ff166002811115610a4657610a46611b9e565b14610a7d576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610a89575080155b15610ac0576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060018481548110610ad557610ad5611e6b565b60009182526020918290206040805160a0810182526003909302909101805463ffffffff8116845260ff64010000000090910416151593830193909352600180840154918301919091526002909201546fffffffffffffffffffffffffffffffff80821660608401527001000000000000000000000000000000009091041660808201528154909250819086908110610b7057610b70611e6b565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909316929092179091556060820151610bda906fffffffffffffffffffffffffffffffff1684151760011b90565b90507f0000000000000000000000000000000000000000000000000000000000000000610c99826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610cdb576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610d3b576001836000015163ffffffff1681548110610d0a57610d0a611e6b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610d74846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610d889190611e9a565b610d929190611e54565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff82161115610e05576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b421790506000610e26888660009182526020526040902090565b60008181526002602052604090205490915060ff1615610e72576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581528184018e81526fffffffffffffffffffffffffffffffff808d16606085019081528a82166080860190815286548088018855968a52945160039096027fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf68101805495511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000909616979099169690961793909317909655517fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf78401555190518416700100000000000000000000000000000000029316929092177fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf8909201919091555133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b600080547fffffffffffffffffffffffffffffffffffffffffffffff000000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff8152602081019290925260019190810161108b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff908116909152825460018181018555600094855260209485902084516003909302018054958501511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090961663ffffffff909316929092179490941781556040830151938101939093556060820151608090920151811670010000000000000000000000000000000002911617600290910155565b61096982826001610a22565b6001818154811061116357600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff1660028111156111e8576111e8611b9e565b1461121f576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006001878154811061123457611234611e6b565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506112937f00000000000000000000000000000000000000000000000000000000000000006001611e9a565b61132f826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1614611370576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008089156113f657611394836fffffffffffffffffffffffffffffffff166119af565b67ffffffffffffffff166000036113cd577f000000000000000000000000000000000000000000000000000000000000000091506113ef565b6113e86113db600186611f7e565b865463ffffffff16611a55565b6001015491505b5083611410565b8460010154915061140d8460016113db9190611faf565b90505b818989604051611421929190611fe3565b604051809103902014611460576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b81526004016114c6949392919061203c565b6020604051808303816000875af11580156114e5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611509919061206e565b6002848101549290911492506000916115b4906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611650886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b61165a9190612087565b6116649190611ee1565b67ffffffffffffffff1615905081151581036116ac576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b6000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335606061171f610a10565b9050909192565b6000806117b3847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b60608160000361181e57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156118485780611832816120a8565b91506118419050600a836120e0565b9150611822565b60008167ffffffffffffffff811115611863576118636120f4565b6040519080825280601f01601f19166020018201604052801561188d576020820181803683370190505b5090505b8415611910576118a2600183611e54565b91506118af600a86612123565b6118ba906030611e9a565b60f81b8183815181106118cf576118cf611e6b565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611909600a866120e0565b9450611891565b949350505050565b6060600061194f84367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003611e9a565b90508267ffffffffffffffff1667ffffffffffffffff811115611974576119746120f4565b6040519080825280601f01601f19166020018201604052801561199e576020820181803683370190505b509150828160208401375092915050565b600080611a3c837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b600080611a73846fffffffffffffffffffffffffffffffff16611af2565b905060018381548110611a8857611a88611e6b565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff828116911614611aeb57815460018054909163ffffffff16908110611ad657611ad6611e6b565b90600052602060002090600302019150611a99565b5092915050565b60008119600183011681611b86827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310611c08577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60008060408385031215611c2157600080fd5b50508035926020909101359150565b60005b83811015611c4b578181015183820152602001611c33565b83811115611c5a576000848401525b50505050565b60008151808452611c78816020860160208601611c30565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611cbd6020830184611c60565b9392505050565b80358015158114611cd457600080fd5b919050565b600080600060608486031215611cee57600080fd5b8335925060208401359150611d0560408501611cc4565b90509250925092565b600060208284031215611d2057600080fd5b5035919050565b60008083601f840112611d3957600080fd5b50813567ffffffffffffffff811115611d5157600080fd5b602083019150836020828501011115611d6957600080fd5b9250929050565b60008060008060008060808789031215611d8957600080fd5b86359550611d9960208801611cc4565b9450604087013567ffffffffffffffff80821115611db657600080fd5b611dc28a838b01611d27565b90965094506060890135915080821115611ddb57600080fd5b50611de889828a01611d27565b979a9699509497509295939492505050565b60ff84168152826020820152606060408201526000611e1c6060830184611c60565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015611e6657611e66611e25565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008219821115611ead57611ead611e25565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff80841680611efc57611efc611eb2565b92169190910692915050565b60008451611f1a818460208901611c30565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551611f56816001850160208a01611c30565b60019201918201528351611f71816002840160208801611c30565b0160020195945050505050565b60006fffffffffffffffffffffffffffffffff83811690831681811015611fa757611fa7611e25565b039392505050565b60006fffffffffffffffffffffffffffffffff808316818516808303821115611fda57611fda611e25565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b604081526000612050604083018688611ff3565b8281036020840152612063818587611ff3565b979650505050505050565b60006020828403121561208057600080fd5b5051919050565b600067ffffffffffffffff83811690831681811015611fa757611fa7611e25565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036120d9576120d9611e25565b5060010190565b6000826120ef576120ef611eb2565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008261213257612132611eb2565b50069056fea164736f6c634300080f000a", } // FaultDisputeGameABI is the input ABI used to generate the binding from. @@ -43,7 +43,7 @@ var FaultDisputeGameABI = FaultDisputeGameMetaData.ABI var FaultDisputeGameBin = FaultDisputeGameMetaData.Bin // DeployFaultDisputeGame deploys a new Ethereum contract, binding an instance of FaultDisputeGame to it. -func DeployFaultDisputeGame(auth *bind.TransactOpts, backend bind.ContractBackend, _absolutePrestate [32]byte, _maxGameDepth *big.Int, _vm common.Address) (common.Address, *types.Transaction, *FaultDisputeGame, error) { +func DeployFaultDisputeGame(auth *bind.TransactOpts, backend bind.ContractBackend, _absolutePrestate [32]byte, _maxGameDepth *big.Int, _gameDuration uint64, _vm common.Address) (common.Address, *types.Transaction, *FaultDisputeGame, error) { parsed, err := FaultDisputeGameMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -52,7 +52,7 @@ func DeployFaultDisputeGame(auth *bind.TransactOpts, backend bind.ContractBacken return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(FaultDisputeGameBin), backend, _absolutePrestate, _maxGameDepth, _vm) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(FaultDisputeGameBin), backend, _absolutePrestate, _maxGameDepth, _gameDuration, _vm) if err != nil { return common.Address{}, nil, nil, err } @@ -232,6 +232,37 @@ func (_FaultDisputeGame *FaultDisputeGameCallerSession) ABSOLUTEPRESTATE() ([32] return _FaultDisputeGame.Contract.ABSOLUTEPRESTATE(&_FaultDisputeGame.CallOpts) } +// GAMEDURATION is a free data retrieval call binding the contract method 0xc31b29ce. +// +// Solidity: function GAME_DURATION() view returns(uint64) +func (_FaultDisputeGame *FaultDisputeGameCaller) GAMEDURATION(opts *bind.CallOpts) (uint64, error) { + var out []interface{} + err := _FaultDisputeGame.contract.Call(opts, &out, "GAME_DURATION") + + if err != nil { + return *new(uint64), err + } + + out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) + + return out0, err + +} + +// GAMEDURATION is a free data retrieval call binding the contract method 0xc31b29ce. +// +// Solidity: function GAME_DURATION() view returns(uint64) +func (_FaultDisputeGame *FaultDisputeGameSession) GAMEDURATION() (uint64, error) { + return _FaultDisputeGame.Contract.GAMEDURATION(&_FaultDisputeGame.CallOpts) +} + +// GAMEDURATION is a free data retrieval call binding the contract method 0xc31b29ce. +// +// Solidity: function GAME_DURATION() view returns(uint64) +func (_FaultDisputeGame *FaultDisputeGameCallerSession) GAMEDURATION() (uint64, error) { + return _FaultDisputeGame.Contract.GAMEDURATION(&_FaultDisputeGame.CallOpts) +} + // MAXGAMEDEPTH is a free data retrieval call binding the contract method 0x4778efe8. // // Solidity: function MAX_GAME_DEPTH() view returns(uint256) diff --git a/op-bindings/bindings/faultdisputegame_more.go b/op-bindings/bindings/faultdisputegame_more.go index 5301d8c519d7..4d725e0f19ba 100644 --- a/op-bindings/bindings/faultdisputegame_more.go +++ b/op-bindings/bindings/faultdisputegame_more.go @@ -13,7 +13,7 @@ const FaultDisputeGameStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contr var FaultDisputeGameStorageLayout = new(solc.StorageLayout) -var FaultDisputeGameDeployedBin = "0x60806040526004361061016a5760003560e01c80638129fc1c116100cb578063bcef3b551161007f578063cf09e0d011610059578063cf09e0d01461049c578063d8cc1a3c146104bb578063fa24f743146104db57600080fd5b8063bcef3b55146103e8578063c55cd0c714610425578063c6f0308c1461043857600080fd5b80638b85902b116100b05780638b85902b146103585780639293129814610398578063bbdc02db146103cc57600080fd5b80638129fc1c1461032e5780638980e0cc1461034357600080fd5b8063363cc4271161012257806354fd4d501161010757806354fd4d50146102e4578063609d333414610306578063632247ea1461031b57600080fd5b8063363cc427146102515780634778efe8146102b057600080fd5b80632810e1d6116101535780632810e1d6146101ed5780633218b99d1461020257806335fef5671461023c57600080fd5b8063200d2ed21461016f578063266198f9146101ab575b600080fd5b34801561017b57600080fd5b506000546101959068010000000000000000900460ff1681565b6040516101a29190611b3a565b60405180910390f35b3480156101b757600080fd5b506101df7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020016101a2565b3480156101f957600080fd5b506101956104ff565b34801561020e57600080fd5b506000546102239067ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016101a2565b61024f61024a366004611b7b565b6108f4565b005b34801561025d57600080fd5b5060005461028b906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101a2565b3480156102bc57600080fd5b506101df7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102f057600080fd5b506102f9610904565b6040516101a29190611c17565b34801561031257600080fd5b506102f96109a7565b61024f610329366004611c46565b6109b9565b34801561033a57600080fd5b5061024f610f73565b34801561034f57600080fd5b506001546101df565b34801561036457600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003602001356101df565b3480156103a457600080fd5b5061028b7f000000000000000000000000000000000000000000000000000000000000000081565b3480156103d857600080fd5b50604051600081526020016101a2565b3480156103f457600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356101df565b61024f610433366004611b7b565b6110b4565b34801561044457600080fd5b50610458610453366004611c7b565b6110c0565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a0016101a2565b3480156104a857600080fd5b5060005467ffffffffffffffff16610223565b3480156104c757600080fd5b5061024f6104d6366004611cdd565b611131565b3480156104e757600080fd5b506104f0611655565b6040516101a293929190611d67565b60008060005468010000000000000000900460ff16600281111561052557610525611b0b565b1461055c576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001805460009161056c91611dc1565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff811015610656576000600182815481106105a6576105a6611dd8565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff64010000000090910416156105f75750610581565b600281015460009061063b906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611693565b90508381101561064f578093508260010194505b5050610581565b5060006001838154811061066c5761066c611dd8565b600091825260208220600390910201805490925063ffffffff908116919082146106d657600182815481106106a3576106a3611dd8565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610702565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b905062049d4061071c67ffffffffffffffff831642611dc1565b610738836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff1661074c9190611e07565b11610783576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600283810154610825906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b61082f9190611e4e565b67ffffffffffffffff1615801561085657506fffffffffffffffffffffffffffffffff8414155b156108645760029550610869565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff16680100000000000000008360028111156108ae576108ae611b0b565b0217905560028111156108c3576108c3611b0b565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b610900828260006109b9565b5050565b606061092f7f0000000000000000000000000000000000000000000000000000000000000000611748565b6109587f0000000000000000000000000000000000000000000000000000000000000000611748565b6109817f0000000000000000000000000000000000000000000000000000000000000000611748565b60405160200161099393929190611e75565b604051602081830303815290604052905090565b60606109b4602080611885565b905090565b6000805468010000000000000000900460ff1660028111156109dd576109dd611b0b565b14610a14576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610a20575080155b15610a57576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060018481548110610a6c57610a6c611dd8565b60009182526020918290206040805160a0810182526003909302909101805463ffffffff8116845260ff64010000000090910416151593830193909352600180840154918301919091526002909201546fffffffffffffffffffffffffffffffff80821660608401527001000000000000000000000000000000009091041660808201528154909250819086908110610b0757610b07611dd8565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909316929092179091556060820151610b71906fffffffffffffffffffffffffffffffff1684151760011b90565b90507f0000000000000000000000000000000000000000000000000000000000000000610c30826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610c72576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610cd2576001836000015163ffffffff1681548110610ca157610ca1611dd8565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610d0b846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610d1f9190611e07565b610d299190611dc1565b905062049d4067ffffffffffffffff82161115610d72576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b421790506000610d93888660009182526020526040902090565b60008181526002602052604090205490915060ff1615610ddf576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581528184018e81526fffffffffffffffffffffffffffffffff808d16606085019081528a82166080860190815286548088018855968a52945160039096027fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf68101805495511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000909616979099169690961793909317909655517fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf78401555190518416700100000000000000000000000000000000029316929092177fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf8909201919091555133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b600080547fffffffffffffffffffffffffffffffffffffffffffffff000000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff81526020810192909252600191908101610ff87ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff908116909152825460018181018555600094855260209485902084516003909302018054958501511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090961663ffffffff909316929092179490941781556040830151938101939093556060820151608090920151811670010000000000000000000000000000000002911617600290910155565b610900828260016109b9565b600181815481106110d057600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff16600281111561115557611155611b0b565b1461118c576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600187815481106111a1576111a1611dd8565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506112007f00000000000000000000000000000000000000000000000000000000000000006001611e07565b61129c826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff16146112dd576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080891561136357611301836fffffffffffffffffffffffffffffffff1661191c565b67ffffffffffffffff1660000361133a577f0000000000000000000000000000000000000000000000000000000000000000915061135c565b611355611348600186611eeb565b865463ffffffff166119c2565b6001015491505b508361137d565b8460010154915061137a8460016113489190611f1c565b90505b81898960405161138e929190611f50565b6040518091039020146113cd576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b81526004016114339493929190611fa9565b6020604051808303816000875af1158015611452573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114769190611fdb565b600284810154929091149250600091611521906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6115bd886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6115c79190611ff4565b6115d19190611e4e565b67ffffffffffffffff161590508115158103611619576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b6000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335606061168c6109a7565b9050909192565b600080611720847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b60608160000361178b57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156117b5578061179f81612015565b91506117ae9050600a8361204d565b915061178f565b60008167ffffffffffffffff8111156117d0576117d0612061565b6040519080825280601f01601f1916602001820160405280156117fa576020820181803683370190505b5090505b841561187d5761180f600183611dc1565b915061181c600a86612090565b611827906030611e07565b60f81b81838151811061183c5761183c611dd8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611876600a8661204d565b94506117fe565b949350505050565b606060006118bc84367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003611e07565b90508267ffffffffffffffff1667ffffffffffffffff8111156118e1576118e1612061565b6040519080825280601f01601f19166020018201604052801561190b576020820181803683370190505b509150828160208401375092915050565b6000806119a9837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b6000806119e0846fffffffffffffffffffffffffffffffff16611a5f565b9050600183815481106119f5576119f5611dd8565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff828116911614611a5857815460018054909163ffffffff16908110611a4357611a43611dd8565b90600052602060002090600302019150611a06565b5092915050565b60008119600183011681611af3827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310611b75577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60008060408385031215611b8e57600080fd5b50508035926020909101359150565b60005b83811015611bb8578181015183820152602001611ba0565b83811115611bc7576000848401525b50505050565b60008151808452611be5816020860160208601611b9d565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611c2a6020830184611bcd565b9392505050565b80358015158114611c4157600080fd5b919050565b600080600060608486031215611c5b57600080fd5b8335925060208401359150611c7260408501611c31565b90509250925092565b600060208284031215611c8d57600080fd5b5035919050565b60008083601f840112611ca657600080fd5b50813567ffffffffffffffff811115611cbe57600080fd5b602083019150836020828501011115611cd657600080fd5b9250929050565b60008060008060008060808789031215611cf657600080fd5b86359550611d0660208801611c31565b9450604087013567ffffffffffffffff80821115611d2357600080fd5b611d2f8a838b01611c94565b90965094506060890135915080821115611d4857600080fd5b50611d5589828a01611c94565b979a9699509497509295939492505050565b60ff84168152826020820152606060408201526000611d896060830184611bcd565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015611dd357611dd3611d92565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008219821115611e1a57611e1a611d92565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff80841680611e6957611e69611e1f565b92169190910692915050565b60008451611e87818460208901611b9d565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551611ec3816001850160208a01611b9d565b60019201918201528351611ede816002840160208801611b9d565b0160020195945050505050565b60006fffffffffffffffffffffffffffffffff83811690831681811015611f1457611f14611d92565b039392505050565b60006fffffffffffffffffffffffffffffffff808316818516808303821115611f4757611f47611d92565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b604081526000611fbd604083018688611f60565b8281036020840152611fd0818587611f60565b979650505050505050565b600060208284031215611fed57600080fd5b5051919050565b600067ffffffffffffffff83811690831681811015611f1457611f14611d92565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361204657612046611d92565b5060010190565b60008261205c5761205c611e1f565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008261209f5761209f611e1f565b50069056fea164736f6c634300080f000a" +var FaultDisputeGameDeployedBin = "0x6080604052600436106101755760003560e01c80638980e0cc116100cb578063c31b29ce1161007f578063cf09e0d011610059578063cf09e0d0146104db578063d8cc1a3c146104fa578063fa24f7431461051a57600080fd5b8063c31b29ce14610430578063c55cd0c714610464578063c6f0308c1461047757600080fd5b806392931298116100b057806392931298146103a3578063bbdc02db146103d7578063bcef3b55146103f357600080fd5b80638980e0cc1461034e5780638b85902b1461036357600080fd5b8063363cc4271161012d578063609d333411610107578063609d333414610311578063632247ea146103265780638129fc1c1461033957600080fd5b8063363cc4271461025c5780634778efe8146102bb57806354fd4d50146102ef57600080fd5b80632810e1d61161015e5780632810e1d6146101f85780633218b99d1461020d57806335fef5671461024757600080fd5b8063200d2ed21461017a578063266198f9146101b6575b600080fd5b34801561018657600080fd5b506000546101a09068010000000000000000900460ff1681565b6040516101ad9190611bcd565b60405180910390f35b3480156101c257600080fd5b506101ea7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020016101ad565b34801561020457600080fd5b506101a061053e565b34801561021957600080fd5b5060005461022e9067ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016101ad565b61025a610255366004611c0e565b61095d565b005b34801561026857600080fd5b50600054610296906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101ad565b3480156102c757600080fd5b506101ea7f000000000000000000000000000000000000000000000000000000000000000081565b3480156102fb57600080fd5b5061030461096d565b6040516101ad9190611caa565b34801561031d57600080fd5b50610304610a10565b61025a610334366004611cd9565b610a22565b34801561034557600080fd5b5061025a611006565b34801561035a57600080fd5b506001546101ea565b34801561036f57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003602001356101ea565b3480156103af57600080fd5b506102967f000000000000000000000000000000000000000000000000000000000000000081565b3480156103e357600080fd5b50604051600081526020016101ad565b3480156103ff57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356101ea565b34801561043c57600080fd5b5061022e7f000000000000000000000000000000000000000000000000000000000000000081565b61025a610472366004611c0e565b611147565b34801561048357600080fd5b50610497610492366004611d0e565b611153565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a0016101ad565b3480156104e757600080fd5b5060005467ffffffffffffffff1661022e565b34801561050657600080fd5b5061025a610515366004611d70565b6111c4565b34801561052657600080fd5b5061052f6116e8565b6040516101ad93929190611dfa565b60008060005468010000000000000000900460ff16600281111561056457610564611b9e565b1461059b576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180546000916105ab91611e54565b90506fffffffffffffffffffffffffffffffff815b67ffffffffffffffff811015610695576000600182815481106105e5576105e5611e6b565b6000918252602090912060039091020180547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9093019290915060ff640100000000909104161561063657506105c0565b600281015460009061067a906fffffffffffffffffffffffffffffffff167f0000000000000000000000000000000000000000000000000000000000000000611726565b90508381101561068e578093508260010194505b50506105c0565b506000600183815481106106ab576106ab611e6b565b600091825260208220600390910201805490925063ffffffff9081169190821461071557600182815481106106e2576106e2611e6b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff16610741565b600283015470010000000000000000000000000000000090046fffffffffffffffffffffffffffffffff165b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1661078567ffffffffffffffff831642611e54565b6107a1836fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff166107b59190611e9a565b116107ec576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60028381015461088e906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6108989190611ee1565b67ffffffffffffffff161580156108bf57506fffffffffffffffffffffffffffffffff8414155b156108cd57600295506108d2565b600195505b600080548791907fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff166801000000000000000083600281111561091757610917611b9e565b02179055600281111561092c5761092c611b9e565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a2505050505090565b61096982826000610a22565b5050565b60606109987f00000000000000000000000000000000000000000000000000000000000000006117db565b6109c17f00000000000000000000000000000000000000000000000000000000000000006117db565b6109ea7f00000000000000000000000000000000000000000000000000000000000000006117db565b6040516020016109fc93929190611f08565b604051602081830303815290604052905090565b6060610a1d602080611918565b905090565b6000805468010000000000000000900460ff166002811115610a4657610a46611b9e565b14610a7d576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610a89575080155b15610ac0576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060018481548110610ad557610ad5611e6b565b60009182526020918290206040805160a0810182526003909302909101805463ffffffff8116845260ff64010000000090910416151593830193909352600180840154918301919091526002909201546fffffffffffffffffffffffffffffffff80821660608401527001000000000000000000000000000000009091041660808201528154909250819086908110610b7057610b70611e6b565b6000918252602082206003909102018054921515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909316929092179091556060820151610bda906fffffffffffffffffffffffffffffffff1684151760011b90565b90507f0000000000000000000000000000000000000000000000000000000000000000610c99826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610cdb576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610d3b576001836000015163ffffffff1681548110610d0a57610d0a611e6b565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610d74846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610d889190611e9a565b610d929190611e54565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff82161115610e05576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b421790506000610e26888660009182526020526040902090565b60008181526002602052604090205490915060ff1615610e72576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581528184018e81526fffffffffffffffffffffffffffffffff808d16606085019081528a82166080860190815286548088018855968a52945160039096027fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf68101805495511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000909616979099169690961793909317909655517fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf78401555190518416700100000000000000000000000000000000029316929092177fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf8909201919091555133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b600080547fffffffffffffffffffffffffffffffffffffffffffffff000000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff8152602081019290925260019190810161108b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff908116909152825460018181018555600094855260209485902084516003909302018054958501511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090961663ffffffff909316929092179490941781556040830151938101939093556060820151608090920151811670010000000000000000000000000000000002911617600290910155565b61096982826001610a22565b6001818154811061116357600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff1660028111156111e8576111e8611b9e565b1461121f576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006001878154811061123457611234611e6b565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506112937f00000000000000000000000000000000000000000000000000000000000000006001611e9a565b61132f826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1614611370576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008089156113f657611394836fffffffffffffffffffffffffffffffff166119af565b67ffffffffffffffff166000036113cd577f000000000000000000000000000000000000000000000000000000000000000091506113ef565b6113e86113db600186611f7e565b865463ffffffff16611a55565b6001015491505b5083611410565b8460010154915061140d8460016113db9190611faf565b90505b818989604051611421929190611fe3565b604051809103902014611460576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b81526004016114c6949392919061203c565b6020604051808303816000875af11580156114e5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611509919061206e565b6002848101549290911492506000916115b4906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611650886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b61165a9190612087565b6116649190611ee1565b67ffffffffffffffff1615905081151581036116ac576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b6000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335606061171f610a10565b9050909192565b6000806117b3847e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff1690508083036001841b600180831b0386831b17039250505092915050565b60608160000361181e57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156118485780611832816120a8565b91506118419050600a836120e0565b9150611822565b60008167ffffffffffffffff811115611863576118636120f4565b6040519080825280601f01601f19166020018201604052801561188d576020820181803683370190505b5090505b8415611910576118a2600183611e54565b91506118af600a86612123565b6118ba906030611e9a565b60f81b8183815181106118cf576118cf611e6b565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611909600a866120e0565b9450611891565b949350505050565b6060600061194f84367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003611e9a565b90508267ffffffffffffffff1667ffffffffffffffff811115611974576119746120f4565b6040519080825280601f01601f19166020018201604052801561199e576020820181803683370190505b509150828160208401375092915050565b600080611a3c837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b600080611a73846fffffffffffffffffffffffffffffffff16611af2565b905060018381548110611a8857611a88611e6b565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff828116911614611aeb57815460018054909163ffffffff16908110611ad657611ad6611e6b565b90600052602060002090600302019150611a99565b5092915050565b60008119600183011681611b86827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310611c08577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60008060408385031215611c2157600080fd5b50508035926020909101359150565b60005b83811015611c4b578181015183820152602001611c33565b83811115611c5a576000848401525b50505050565b60008151808452611c78816020860160208601611c30565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611cbd6020830184611c60565b9392505050565b80358015158114611cd457600080fd5b919050565b600080600060608486031215611cee57600080fd5b8335925060208401359150611d0560408501611cc4565b90509250925092565b600060208284031215611d2057600080fd5b5035919050565b60008083601f840112611d3957600080fd5b50813567ffffffffffffffff811115611d5157600080fd5b602083019150836020828501011115611d6957600080fd5b9250929050565b60008060008060008060808789031215611d8957600080fd5b86359550611d9960208801611cc4565b9450604087013567ffffffffffffffff80821115611db657600080fd5b611dc28a838b01611d27565b90965094506060890135915080821115611ddb57600080fd5b50611de889828a01611d27565b979a9699509497509295939492505050565b60ff84168152826020820152606060408201526000611e1c6060830184611c60565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082821015611e6657611e66611e25565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008219821115611ead57611ead611e25565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600067ffffffffffffffff80841680611efc57611efc611eb2565b92169190910692915050565b60008451611f1a818460208901611c30565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551611f56816001850160208a01611c30565b60019201918201528351611f71816002840160208801611c30565b0160020195945050505050565b60006fffffffffffffffffffffffffffffffff83811690831681811015611fa757611fa7611e25565b039392505050565b60006fffffffffffffffffffffffffffffffff808316818516808303821115611fda57611fda611e25565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b604081526000612050604083018688611ff3565b8281036020840152612063818587611ff3565b979650505050505050565b60006020828403121561208057600080fd5b5051919050565b600067ffffffffffffffff83811690831681811015611fa757611fa7611e25565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036120d9576120d9611e25565b5060010190565b6000826120ef576120ef611eb2565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60008261213257612132611eb2565b50069056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(FaultDisputeGameStorageLayoutJSON), FaultDisputeGameStorageLayout); err != nil { diff --git a/op-challenger/fault/abi_test.go b/op-challenger/fault/abi_test.go index 0ad2a0fbe92a..cb33ecb4c607 100644 --- a/op-challenger/fault/abi_test.go +++ b/op-challenger/fault/abi_test.go @@ -31,6 +31,7 @@ func setupFaultDisputeGame() (common.Address, *bind.TransactOpts, *backends.Simu backend, [32]byte{0x01}, big.NewInt(15), + uint64(604800), // 7 days common.Address{0xdd}, ) if err != nil { diff --git a/packages/contracts-bedrock/.gas-snapshot b/packages/contracts-bedrock/.gas-snapshot index 80a56c3ae19c..f8d9e93d0e1e 100644 --- a/packages/contracts-bedrock/.gas-snapshot +++ b/packages/contracts-bedrock/.gas-snapshot @@ -83,37 +83,36 @@ FaucetTest:test_nonAdmin_drip_fails() (gas: 262520) FaucetTest:test_receive_succeeds() (gas: 17401) FaucetTest:test_withdraw_nonAdmin_reverts() (gas: 13145) FaucetTest:test_withdraw_succeeds() (gas: 78359) -FaultDisputeGame_ResolvesCorrectly_Chaos:test_resolvesCorrectly_succeeds() (gas: 111450391) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 498867) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 505669) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 502410) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 505545) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 504906) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 497632) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 504434) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 501175) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 502310) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 501671) -FaultDisputeGame_Test:test_extraData_succeeds() (gas: 17426) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 498839) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 505685) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 502382) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 505561) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 504878) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 497604) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 504450) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 501147) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 502326) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 501643) +FaultDisputeGame_Test:test_extraData_succeeds() (gas: 17404) FaultDisputeGame_Test:test_gameData_succeeds() (gas: 17917) FaultDisputeGame_Test:test_gameStart_succeeds() (gas: 10315) -FaultDisputeGame_Test:test_gameType_succeeds() (gas: 8282) +FaultDisputeGame_Test:test_gameType_succeeds() (gas: 8260) FaultDisputeGame_Test:test_initialRootClaimData_succeeds() (gas: 17669) -FaultDisputeGame_Test:test_move_clockCorrectness_succeeds() (gas: 415981) -FaultDisputeGame_Test:test_move_clockTimeExceeded_reverts() (gas: 26387) +FaultDisputeGame_Test:test_move_clockCorrectness_succeeds() (gas: 416029) +FaultDisputeGame_Test:test_move_clockTimeExceeded_reverts() (gas: 26399) FaultDisputeGame_Test:test_move_defendRoot_reverts() (gas: 13360) -FaultDisputeGame_Test:test_move_duplicateClaim_reverts() (gas: 103230) -FaultDisputeGame_Test:test_move_gameDepthExceeded_reverts() (gas: 408100) +FaultDisputeGame_Test:test_move_duplicateClaim_reverts() (gas: 103254) +FaultDisputeGame_Test:test_move_gameDepthExceeded_reverts() (gas: 408148) FaultDisputeGame_Test:test_move_gameNotInProgress_reverts() (gas: 10968) FaultDisputeGame_Test:test_move_nonExistentParent_reverts() (gas: 24655) -FaultDisputeGame_Test:test_move_simpleAttack_succeeds() (gas: 107344) -FaultDisputeGame_Test:test_resolve_challengeContested_succeeds() (gas: 224784) +FaultDisputeGame_Test:test_move_simpleAttack_succeeds() (gas: 107356) +FaultDisputeGame_Test:test_resolve_challengeContested_succeeds() (gas: 224820) FaultDisputeGame_Test:test_resolve_notInProgress_reverts() (gas: 9657) -FaultDisputeGame_Test:test_resolve_rootContested_succeeds() (gas: 109749) -FaultDisputeGame_Test:test_resolve_rootUncontestedClockNotExpired_succeeds() (gas: 21422) -FaultDisputeGame_Test:test_resolve_rootUncontested_succeeds() (gas: 27251) -FaultDisputeGame_Test:test_resolve_teamDeathmatch_succeeds() (gas: 395442) -FaultDisputeGame_Test:test_rootClaim_succeeds() (gas: 8181) +FaultDisputeGame_Test:test_resolve_rootContested_succeeds() (gas: 109773) +FaultDisputeGame_Test:test_resolve_rootUncontestedClockNotExpired_succeeds() (gas: 21434) +FaultDisputeGame_Test:test_resolve_rootUncontested_succeeds() (gas: 27263) +FaultDisputeGame_Test:test_resolve_teamDeathmatch_succeeds() (gas: 395502) +FaultDisputeGame_Test:test_rootClaim_succeeds() (gas: 8225) FeeVault_Test:test_constructor_succeeds() (gas: 18185) GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_0() (gas: 352113) GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_1() (gas: 2950320) diff --git a/packages/contracts-bedrock/contracts/dispute/FaultDisputeGame.sol b/packages/contracts-bedrock/contracts/dispute/FaultDisputeGame.sol index 9a5f5bcb2c31..0a0a6db04064 100644 --- a/packages/contracts-bedrock/contracts/dispute/FaultDisputeGame.sol +++ b/packages/contracts-bedrock/contracts/dispute/FaultDisputeGame.sol @@ -30,12 +30,12 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, Semver { /// @notice The max depth of the game. uint256 public immutable MAX_GAME_DEPTH; + /// @notice The duration of the game. + Duration public immutable GAME_DURATION; + /// @notice A hypervisor that performs single instruction steps on a fault proof program trace. IBigStepper public immutable VM; - /// @notice The duration of the game. - Duration internal constant GAME_DURATION = Duration.wrap(7 days); - /// @notice The root claim's position is always at gindex 1. Position internal constant ROOT_POSITION = Position.wrap(1); @@ -58,10 +58,12 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, Semver { constructor( Claim _absolutePrestate, uint256 _maxGameDepth, + Duration _gameDuration, IBigStepper _vm ) Semver(0, 0, 3) { ABSOLUTE_PRESTATE = _absolutePrestate; MAX_GAME_DEPTH = _maxGameDepth; + GAME_DURATION = _gameDuration; VM = _vm; } diff --git a/packages/contracts-bedrock/contracts/test/FaultDisputeGame.t.sol b/packages/contracts-bedrock/contracts/test/FaultDisputeGame.t.sol index 65dca4baac6b..a45b65a29a89 100644 --- a/packages/contracts-bedrock/contracts/test/FaultDisputeGame.t.sol +++ b/packages/contracts-bedrock/contracts/test/FaultDisputeGame.t.sol @@ -29,7 +29,12 @@ contract FaultDisputeGame_Init is DisputeGameFactory_Init { function init(Claim rootClaim, Claim absolutePrestate) public { super.setUp(); // Deploy an implementation of the fault game - gameImpl = new FaultDisputeGame(absolutePrestate, 4, new AlphabetVM(absolutePrestate)); + gameImpl = new FaultDisputeGame( + absolutePrestate, + 4, + Duration.wrap(7 days), + new AlphabetVM(absolutePrestate) + ); // Register the game implementation with the factory. factory.setImplementation(GAME_TYPE, gameImpl); // Create a new game. diff --git a/packages/contracts-bedrock/deploy-config/devnetL1.json b/packages/contracts-bedrock/deploy-config/devnetL1.json index b3315cca7bcb..24b30d793f7d 100644 --- a/packages/contracts-bedrock/deploy-config/devnetL1.json +++ b/packages/contracts-bedrock/deploy-config/devnetL1.json @@ -45,5 +45,6 @@ "l1StartingBlockTag": "earliest", "l2GenesisRegolithTimeOffset": "0x0", "faultGameAbsolutePrestate": 140, - "faultGameMaxDepth": 4 -} \ No newline at end of file + "faultGameMaxDepth": 4, + "faultGameMaxDuration": 604800 +} diff --git a/packages/contracts-bedrock/scripts/Deploy.s.sol b/packages/contracts-bedrock/scripts/Deploy.s.sol index 09fc69d7614b..e6e3c3ada509 100644 --- a/packages/contracts-bedrock/scripts/Deploy.s.sol +++ b/packages/contracts-bedrock/scripts/Deploy.s.sol @@ -697,6 +697,7 @@ contract Deploy is Deployer { factory.setImplementation(GameTypes.FAULT, new FaultDisputeGame({ _absolutePrestate: absolutePrestate, _maxGameDepth: cfg.faultGameMaxDepth(), + _gameDuration: Duration.wrap(uint64(cfg.faultGameMaxDuration())), _vm: faultVm })); console.log("DisputeGameFactory: set `FaultDisputeGame` implementation"); diff --git a/packages/contracts-bedrock/scripts/DeployConfig.s.sol b/packages/contracts-bedrock/scripts/DeployConfig.s.sol index 11f9e22f5537..1d2a138b1b68 100644 --- a/packages/contracts-bedrock/scripts/DeployConfig.s.sol +++ b/packages/contracts-bedrock/scripts/DeployConfig.s.sol @@ -47,6 +47,7 @@ contract DeployConfig is Script { uint256 public l2GenesisRegolithTimeOffset; uint256 public faultGameAbsolutePrestate; uint256 public faultGameMaxDepth; + uint256 public faultGameMaxDuration; constructor(string memory _path) { console.log("DeployConfig: reading file %s", _path); @@ -88,6 +89,7 @@ contract DeployConfig is Script { if (block.chainid == 900) { faultGameAbsolutePrestate = stdJson.readUint(_json, "$.faultGameAbsolutePrestate"); faultGameMaxDepth = stdJson.readUint(_json, "$.faultGameMaxDepth"); + faultGameMaxDuration = stdJson.readUint(_json, "$.faultGameMaxDuration"); } }