diff --git a/.gas-snapshot b/.gas-snapshot index 1a15068f5..e8f6c4669 100644 --- a/.gas-snapshot +++ b/.gas-snapshot @@ -1,239 +1,237 @@ -GenericPoolOrderBookV4ArbOrderTakerExpressionTest:testGenericPoolTakeOrdersExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256[],uint256[]) (runs: 5108, μ: 364548, ~: 363555) -GenericPoolOrderBookV4ArbOrderTakerExpressionTest:testGenericPoolTakeOrdersWrongExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,address,bytes)) (runs: 5108, μ: 160657, ~: 159645) -GenericPoolOrderBookV4ArbOrderTakerSenderTest:testGenericPoolMinimumOutput((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5108, μ: 296404, ~: 295241) -GenericPoolOrderBookV4ArbOrderTakerSenderTest:testGenericPoolTakeOrdersSender((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5108, μ: 251218, ~: 249876) -GenericPoolOrderBookV4FlashBorrowerTest:testGenericPoolOrderBookV4FlashBorrowerMinimumOutput((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5108, μ: 495646, ~: 492574) -GenericPoolOrderBookV4FlashBorrowerTest:testGenericPoolOrderBookV4FlashBorrowerTakeOrdersSender((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5108, μ: 449478, ~: 446089) -LibOrderTest:testHashEqual((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32)) (runs: 5108, μ: 199682, ~: 196369) -LibOrderTest:testHashNotEqual((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32)) (runs: 5108, μ: 302795, ~: 302032) -OrderBookAddOrderEnactTest:testAddLiveOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 914161, ~: 902996) -OrderBookAddOrderEnactTest:testAddLiveOrderRevertNoAdd(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 715113, ~: 706575) -OrderBookAddOrderEnactTest:testAddOrderContext(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1016936, ~: 1006873) -OrderBookAddOrderEnactTest:testAddOrderEmptyNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 640572, ~: 632416) -OrderBookAddOrderEnactTest:testAddOrderOneReadState(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 699000, ~: 690841) -OrderBookAddOrderEnactTest:testAddOrderOneStateless(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 688070, ~: 679911) -OrderBookAddOrderEnactTest:testAddOrderWriteStateDifferentOwnersNamespaced(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 3062291, ~: 3055050) -OrderBookAddOrderEnactTest:testAddOrderWriteStateSequential(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 923580, ~: 915410) -OrderBookAddOrderEnactTest:testAddOrderWriteStateSingle(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1322322, ~: 1307883) -OrderBookAddOrderMockTest:testAddOrderSameAccountWithDifferentConfig(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,bytes) (runs: 5108, μ: 2579974, ~: 2572953) -OrderBookAddOrderMockTest:testAddOrderTwoAccountsWithDifferentConfig(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,bytes) (runs: 5108, μ: 2461275, ~: 2456303) -OrderBookAddOrderMockTest:testAddOrderTwoAccountsWithSameConfig(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 2325905, ~: 2307743) -OrderBookAddOrderMockTest:testAddOrderWithCalculationsInputsAndOutputsSucceeds(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 1194015, ~: 1173744) -OrderBookAddOrderMockTest:testAddOrderWithNonEmptyMetaEmitsMetaV1(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 1202217, ~: 1182463) -OrderBookAddOrderMockTest:testAddOrderWithNonEmptyMetaReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 668713, ~: 659383) -OrderBookAddOrderMockTest:testAddOrderWithoutCalculationsDeploys(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 658525, ~: 650005) -OrderBookAddOrderMockTest:testAddOrderWithoutInputsReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 157101, ~: 156228) -OrderBookAddOrderMockTest:testAddOrderWithoutOutputsReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 157521, ~: 156371) -OrderBookAddOrderNonceTest:testAddOrderNonceDifferentNonceStateChange(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes32) (runs: 5108, μ: 1222168, ~: 1213114) -OrderBookAddOrderNonceTest:testAddOrderNonceSameNonceDifferentOrderStateChange(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1455284, ~: 1450041) -OrderBookAddOrderNonceTest:testAddOrderNonceSameOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 943936, ~: 930835) -OrderBookAddOrderOwnerTest:testAddOrderOwnerDifferentOwnerStateChange(((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),address,address) (runs: 5108, μ: 1214089, ~: 1213666) -OrderBookAddOrderOwnerTest:testAddOrderOwnerSameOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 944032, ~: 930931) -OrderBookAddOrderTest:testAddOrderRealCalculateInputsReverts1(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 640893, ~: 632736) -OrderBookAddOrderTest:testAddOrderRealCalculateInputsReverts2(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 642710, ~: 634553) -OrderBookAddOrderTest:testAddOrderRealCalculateInputsRevertsPreference(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 642211, ~: 634054) -OrderBookAddOrderTest:testAddOrderRealNoHandleIODeploys(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 633168, ~: 625011) -OrderBookAddOrderTest:testAddOrderRealNoSourcesDeploys(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 612706, ~: 604550) -OrderBookAddOrderTest:testAddOrderRealOneStackCalculateReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 645143, ~: 636986) -OrderBookAddOrderTest:testAddOrderRealThreeStackCalculate(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 657571, ~: 649414) -OrderBookAddOrderTest:testAddOrderRealTwoStackCalculateReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 651268, ~: 643111) -OrderBookAddOrderTest:testAddOrderRealZeroStackCalculateReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 639597, ~: 631440) -OrderBookClearHandleIORevertTest:testClearOrderAliceNoHandleIORevert() (gas: 501293) -OrderBookClearHandleIORevertTest:testClearOrderBobNoHandleIORevert() (gas: 501272) -OrderBookClearHandleIORevertTest:testClearOrderBothNoHandleIORevert() (gas: 481271) -OrderBookClearHandleIORevertTest:testClearOrderHandleIO0() (gas: 534351) -OrderBookClearHandleIORevertTest:testClearOrderHandleIO1() (gas: 529715) -OrderBookClearHandleIORevertTest:testClearOrderHandleIO2() (gas: 529834) -OrderBookClearHandleIORevertTest:testClearOrderHandleIO3() (gas: 534395) -OrderBookClearHandleIORevertTest:testClearOrderHandleIO4() (gas: 544024) -OrderBookClearHandleIORevertTest:testClearOrderHandleIO5() (gas: 507401) -OrderBookClearOrderBadStackTest:testClearOrderBadStackEmptyStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2298365, ~: 2299737) -OrderBookClearOrderBadStackTest:testClearOrderBadStackOneEmpty(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2382630, ~: 2383540) -OrderBookClearOrderBadStackTest:testClearOrderBadStackOneOne(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2389689, ~: 2390604) -OrderBookClearOrderBadStackTest:testClearOrderBadStackOneOtherOne(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2318255, ~: 2319627) -OrderBookClearOrderBadStackTest:testClearOrderBadStackOneStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2311881, ~: 2313253) -OrderBookClearOrderBadStackTest:testClearOrderBadStackOtherEmpty(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2311245, ~: 2312607) -OrderBookClearOrderContextTest:testContextEmptyStack(address,address,uint256,uint256,uint256,uint256) (runs: 5108, μ: 2058476, ~: 2059489) -OrderBookClearTest:testClearSimple(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256,bytes,address,uint256,uint256) (runs: 5108, μ: 518584, ~: 517984) -OrderBookClearTest:testFlashLoanToNonReceiver(uint256,bytes,bytes32,bytes) (runs: 5108, μ: 26163, ~: 26154) -OrderBookDepositEnactTest:testDepositRevertInAction(address,uint256,uint256) (runs: 5108, μ: 94311, ~: 94311) -OrderBookDepositEnactTest:testOrderBookDepositEnactEmptyNoop(address,uint256,uint256) (runs: 5108, μ: 41047, ~: 41047) -OrderBookDepositEnactTest:testOrderBookDepositEnactOneReadState(address,uint256,uint256) (runs: 5108, μ: 101319, ~: 101319) -OrderBookDepositEnactTest:testOrderBookDepositEnactOneStateless(address,uint256,uint256) (runs: 5108, μ: 90425, ~: 90425) -OrderBookDepositEnactTest:testOrderBookDepositEvalWriteStateDifferentOwnersNamespaced(address,address,uint256,uint256) (runs: 5108, μ: 925173, ~: 924944) -OrderBookDepositEnactTest:testOrderBookDepositEvalWriteStateSequential(address,uint256,uint256) (runs: 5108, μ: 572302, ~: 572076) -OrderBookDepositEnactTest:testOrderBookDepositEvalWriteStateSingle(address,uint256,uint256) (runs: 5108, μ: 206376, ~: 206150) -OrderBookDepositEnactTest:testOrderDepositContext(address,uint256,uint256,uint256) (runs: 5108, μ: 809491, ~: 810169) -OrderBookDepositTest:testDepositEvent(address,uint256,uint256) (runs: 5108, μ: 38853, ~: 38853) -OrderBookDepositTest:testDepositFail(address,uint256,uint256) (runs: 5108, μ: 1040440701, ~: 1040440664) -OrderBookDepositTest:testDepositGas00() (gas: 8771) -OrderBookDepositTest:testDepositGas01() (gas: 35148) -OrderBookDepositTest:testDepositMany((address,address,uint256,uint248)[]) (runs: 5097, μ: 2479134, ~: 1708734) -OrderBookDepositTest:testDepositOverflow(address,uint256,uint256,uint256) (runs: 5108, μ: 51608, ~: 51929) -OrderBookDepositTest:testDepositReentrancy(address,uint256,uint256,address,uint256,uint256) (runs: 5108, μ: 606377, ~: 606775) -OrderBookDepositTest:testDepositSimple(address,uint256,uint256) (runs: 5108, μ: 38105, ~: 38105) -OrderBookDepositTest:testDepositZero(address,uint256) (runs: 5108, μ: 12924, ~: 12924) -OrderBookDepositTest:testVaultBalanceNoDeposits(address,uint256) (runs: 5108, μ: 8938, ~: 8938) -OrderBookEnactTest:testOrderBookEvalEmptyNoop(address) (runs: 5108, μ: 14063, ~: 14063) -OrderBookEnactTest:testOrderBookEvalOneReadState(address) (runs: 5108, μ: 71033, ~: 71033) -OrderBookEnactTest:testOrderBookEvalOneStateless(address) (runs: 5108, μ: 60115, ~: 60115) -OrderBookEnactTest:testOrderBookEvalWriteStateDifferentOwnersNamespaced(address,address) (runs: 5108, μ: 831324, ~: 831324) -OrderBookEnactTest:testOrderBookEvalWriteStateSequential() (gas: 519879) -OrderBookEnactTest:testOrderBookEvalWriteStateSingle(address) (runs: 5108, μ: 165041, ~: 165041) -OrderBookQuoteTest:testQuoteContextSender(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256) (runs: 5108, μ: 10167185, ~: 10064132) -OrderBookQuoteTest:testQuoteDeadOrder(((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,uint256[],bytes)[])) (runs: 5108, μ: 6663419, ~: 5832695) -OrderBookQuoteTest:testQuoteMaxOutput(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256) (runs: 5108, μ: 1108902, ~: 1096998) -OrderBookQuoteTest:testQuoteSimple(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256) (runs: 5108, μ: 1102322, ~: 1090401) -OrderBookRemoveOrderEnactTest:testRemoveOrderContext(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 645135, ~: 638606) -OrderBookRemoveOrderEnactTest:testRemoveOrderDeadOrder(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 354707, ~: 350017) -OrderBookRemoveOrderEnactTest:testRemoveOrderEmptyNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1080804, ~: 1066445) -OrderBookRemoveOrderEnactTest:testRemoveOrderOneReadState(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1139439, ~: 1125079) -OrderBookRemoveOrderEnactTest:testRemoveOrderOneStateless(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1128561, ~: 1114201) -OrderBookRemoveOrderEnactTest:testRemoveOrderRevertInAction(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1265141, ~: 1248808) -OrderBookRemoveOrderEnactTest:testRemoveOrderWriteStateDifferentOwnersNamespaced(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 4830163, ~: 4817389) -OrderBookRemoveOrderEnactTest:testRemoveOrderWriteStateSequential(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 1364947, ~: 1350575) -OrderBookRemoveOrderEnactTest:testRemoveOrderWriteStateSingle(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 2203262, ~: 2176419) -OrderBookRemoveOrderMockTest:testRemoveOrderAddRemoveMulti(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 6809007, ~: 6662571) -OrderBookRemoveOrderMockTest:testRemoveOrderDifferent(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 4771475, ~: 4707793) -OrderBookRemoveOrderMockTest:testRemoveOrderDifferentOwners(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 4605540, ~: 4556938) -OrderBookRemoveOrderMockTest:testRemoveOrderDifferentOwnersDifferent(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 9901135, ~: 9779715) -OrderBookRemoveOrderMockTest:testRemoveOrderDoesNotExist(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 374485, ~: 368808) -OrderBookRemoveOrderMockTest:testRemoveOrderOnlyOwner(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5108, μ: 2473575, ~: 2452298) -OrderBookRemoveOrderOwnerTest:testRemoveOrderOwnerDifferentOwnerStateChange(((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),address,address) (runs: 5108, μ: 5915110, ~: 5838087) -OrderBookRemoveOrderOwnerTest:testRemoveOrderOwnerSameOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 3398031, ~: 3339431) -OrderBookRemoveOrderOwnerTest:testRemoveOrderWrongOwner(((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),address,address) (runs: 5108, μ: 758239, ~: 757542) -OrderBookSubParserContextCalculatedIORatioTest:testSubParserContextHappy() (gas: 2190404) -OrderBookSubParserContextCalculatedIORatioTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169061) -OrderBookSubParserContextCalculatedIORatioTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155576) -OrderBookSubParserContextCalculatedMaxOutputTest:testSubParserContextHappy() (gas: 2190731) -OrderBookSubParserContextCalculatedMaxOutputTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169384) -OrderBookSubParserContextCalculatedMaxOutputTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155903) -OrderBookSubParserContextInputTokenDecimalsTest:testSubParserContextHappy() (gas: 2190570) -OrderBookSubParserContextInputTokenDecimalsTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169223) -OrderBookSubParserContextInputTokenDecimalsTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155741) -OrderBookSubParserContextInputTokenTest:testSubParserContextHappy() (gas: 2189107) -OrderBookSubParserContextInputTokenTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2167761) -OrderBookSubParserContextInputTokenTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154280) -OrderBookSubParserContextInputVaultBalanceIncreaseTest:testSubParserContextHappy() (gas: 2190570) -OrderBookSubParserContextInputVaultBalanceIncreaseTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169223) -OrderBookSubParserContextInputVaultBalanceIncreaseTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155741) -OrderBookSubParserContextOrderBookTest:testSubParserContextHappy() (gas: 2188783) -OrderBookSubParserContextOrderBookTest:testSubParserContextHappy() (gas: 2189594) -OrderBookSubParserContextOrderBookTest:testSubParserContextHappy() (gas: 2189756) -OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2167437) -OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2168248) -OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2168410) -OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2153956) -OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154766) -OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154928) -OrderBookSubParserContextOrderClearerTest:testSubParserContextHappy() (gas: 2189431) -OrderBookSubParserContextOrderClearerTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2168085) -OrderBookSubParserContextOrderClearerTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154604) -OrderBookSubParserContextOrderCounterpartyTest:testSubParserContextHappy() (gas: 2190242) -OrderBookSubParserContextOrderCounterpartyTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2168899) -OrderBookSubParserContextOrderCounterpartyTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155414) -OrderBookSubParserContextOrderHashTest:testSubParserContextHappy() (gas: 2188945) -OrderBookSubParserContextOrderHashTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2167599) -OrderBookSubParserContextOrderHashTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154118) -OrderBookSubParserContextOrderOwnerTest:testSubParserContextHappy() (gas: 2189108) -OrderBookSubParserContextOrderOwnerTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2167762) -OrderBookSubParserContextOrderOwnerTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154280) -OrderBookSubParserContextOutputTokenDecimalsTest:testSubParserContextHappy() (gas: 2190732) -OrderBookSubParserContextOutputTokenDecimalsTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169385) -OrderBookSubParserContextOutputTokenDecimalsTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155903) -OrderBookSubParserContextOutputTokenTest:testSubParserContextHappy() (gas: 2189269) -OrderBookSubParserContextOutputTokenTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2167923) -OrderBookSubParserContextOutputTokenTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2154442) -OrderBookSubParserContextOutputVaultBalanceBeforeTest:testSubParserContextHappy() (gas: 2190404) -OrderBookSubParserContextOutputVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169061) -OrderBookSubParserContextOutputVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155576) -OrderBookSubParserContextOutputVaultBalanceDecreaseTest:testSubParserContextHappy() (gas: 2190732) -OrderBookSubParserContextOutputVaultBalanceDecreaseTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2169385) -OrderBookSubParserContextOutputVaultBalanceDecreaseTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155903) -OrderBookSubParserContextVaultBalanceBeforeTest:testSubParserContextHappy() (gas: 2190242) -OrderBookSubParserContextVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2168899) -OrderBookSubParserContextVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2155414) -OrderBookSubParserDescribedByMetaV1Test:testOrderBookSubParserDescribedByMetaV1Happy() (gas: 2107037) -OrderBookSubParserIERC165Test:testOrderBookSubParserIERC165(bytes4) (runs: 5108, μ: 2110113, ~: 2110113) -OrderBookSubParserPointersTest:testSubParserFunctionPointers() (gas: 2121602) -OrderBookSubParserPointersTest:testSubParserOperandParsers() (gas: 2121602) -OrderBookSubParserPointersTest:testSubParserParseMeta() (gas: 254036) -OrderBookSubParserPointersTest:testWordOperandLengthEquivalence() (gas: 4098) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy0() (gas: 2195800) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy1() (gas: 2195834) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy2() (gas: 2195835) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy3() (gas: 2195957) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextUnhappyInput() (gas: 2174344) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextUnhappyNoOperand() (gas: 2151658) -OrderBookSubParserSignedContextTest:testSubParserContextSignedContextUnhappyTooManyOperands() (gas: 2160553) -OrderBookSubParserSignersTest:testSubParserContextSignerHappy0() (gas: 2191256) -OrderBookSubParserSignersTest:testSubParserContextSignerHappy1() (gas: 2191312) -OrderBookSubParserSignersTest:testSubParserContextSignerUnhappyInput() (gas: 2169797) -OrderBookSubParserSignersTest:testSubParserContextSignerUnhappyNoOperand() (gas: 2150334) -OrderBookSubParserSignersTest:testSubParserContextSignerUnhappyTooManyOperands() (gas: 2156254) -OrderBookTakeOrderBadStackTest:testTakeOrderBadStackEmptyStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 939878, ~: 935548) -OrderBookTakeOrderBadStackTest:testTakeOrderBadStackOneStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 946573, ~: 942243) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO0() (gas: 229757) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO1() (gas: 387348) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO10(uint256) (runs: 5108, μ: 615496, ~: 578476) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO2() (gas: 400742) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO3() (gas: 538649) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO4() (gas: 555540) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO5() (gas: 555539) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO6() (gas: 542186) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO7(uint256) (runs: 5108, μ: 788395, ~: 788356) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO8(uint256) (runs: 5108, μ: 940102, ~: 940062) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO9(uint256) (runs: 5108, μ: 697951, ~: 629175) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderNoHandleIORevert0() (gas: 224599) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderNoHandleIORevert1() (gas: 375661) -OrderBookTakeOrderHandleIORevertTest:testTakeOrderNoHandleIORevert2() (gas: 362312) -OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputMultipleOrders(uint256,uint256) (runs: 5108, μ: 394878, ~: 405610) -OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputMultipleOrdersMultipleOwners(uint256,uint256,uint256) (runs: 5108, μ: 449781, ~: 462377) -OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleAnyDeposit(uint256,uint256) (runs: 5108, μ: 248164, ~: 250417) -OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleOrderLessThanMaximumInput(uint256,uint256) (runs: 5108, μ: 230806, ~: 231998) -OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleOrderLessThanMaximumOutput(uint256) (runs: 5108, μ: 230399, ~: 230357) -OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleOrderUnlimitedMax(uint256) (runs: 5108, μ: 228250, ~: 228026) -OrderBookTakeOrderMaximumInputTest:testTakeOrderNoopZeroMaxTakerInput((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),(address,uint256[],bytes)) (runs: 5108, μ: 184639, ~: 184719) -OrderBookTakeOrderNoopTest:testTakeOrderNoopNonLiveOrderOne((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,uint256[],bytes)) (runs: 5108, μ: 424745, ~: 422709) -OrderBookTakeOrderNoopTest:testTakeOrderNoopNonLiveOrderTwo((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256,(address,uint256[],bytes),(address,uint256[],bytes)) (runs: 5108, μ: 851264, ~: 847042) -OrderBookTakeOrderNoopTest:testTakeOrderNoopZeroOrders() (gas: 12341) -OrderBookTakeOrderPrecisionTest:testTakeOrderPrecisionKnownBad01() (gas: 2120482) -OrderBookTakeOrderTokenMismatchDecimalsTest:testTokenMismatchInputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5108, μ: 613785, ~: 609484) -OrderBookTakeOrderTokenMismatchDecimalsTest:testTokenMismatchOutputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5108, μ: 615268, ~: 611651) -OrderBookTakeOrderTokenMismatchTest:testTokenMismatchInputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5108, μ: 612692, ~: 611023) -OrderBookTakeOrderTokenMismatchTest:testTokenMismatchOutputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5108, μ: 613956, ~: 612339) -OrderBookV4ArbOrderTakerIERC165Test:testOrderBookV4ArbOrderTakerIERC165(bytes4) (runs: 5108, μ: 1977114, ~: 1977114) -OrderBookV4FlashBorrowerIERC165Test:testOrderBookV4FlashBorrowerIERC165(bytes4) (runs: 5108, μ: 2490318, ~: 2490318) -OrderBookV4FlashLenderFeeTest:testFlashFee(address,uint256) (runs: 5108, μ: 6573, ~: 6573) -OrderBookV4FlashLenderIERC165Test:testOrderBookV4FlashLenderIERC165(bytes4) (runs: 5108, μ: 563157, ~: 563157) -OrderBookV4FlashLenderMaxFlashLoanTest:testFlashMaxLoan(uint256) (runs: 5108, μ: 7744, ~: 7744) -OrderBookV4FlashLenderMockSuccessTest:testFlashLoanToReceiver(uint256,bytes) (runs: 5108, μ: 13564, ~: 13557) -OrderBookV4FlashLenderReentrant:testReenterAddOrder(uint256,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 18624420, ~: 18599593) -OrderBookV4FlashLenderReentrant:testReenterCheckOrderExists(bytes32,uint256) (runs: 5108, μ: 535399, ~: 535614) -OrderBookV4FlashLenderReentrant:testReenterClear(uint256,address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 37650938, ~: 37548644) -OrderBookV4FlashLenderReentrant:testReenterDeposit(uint256,uint256,uint256) (runs: 5108, μ: 635660, ~: 636074) -OrderBookV4FlashLenderReentrant:testReenterReadVaultBalances(uint256,uint256) (runs: 5108, μ: 580236, ~: 580599) -OrderBookV4FlashLenderReentrant:testReenterRemoveOrder(uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32)) (runs: 5108, μ: 18055022, ~: 17982604) -OrderBookV4FlashLenderReentrant:testReenterTakeOrder(uint256,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5108, μ: 19199000, ~: 19169665) -OrderBookV4FlashLenderReentrant:testReenterWithdraw(uint256,uint256,uint256) (runs: 5108, μ: 612338, ~: 612752) -OrderBookV4FlashLenderTransferTest:testFlashLoanTransferFail(uint256,uint256,bool) (runs: 5108, μ: 1315070, ~: 1314004) -OrderBookV4FlashLenderTransferTest:testFlashLoanTransferSuccess(uint256,bool) (runs: 5108, μ: 1261028, ~: 1267965) -OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalEmptyNoop(address,uint256,uint256,uint256) (runs: 5108, μ: 52132, ~: 52592) -OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalOneReadState(address,uint256,uint256,uint256) (runs: 5108, μ: 112536, ~: 113358) -OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalOneStateless(address,uint256,uint256,uint256) (runs: 5108, μ: 101641, ~: 102463) -OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalWriteStateDifferentOwnersNamespaced(address,address,uint256,uint256,uint256) (runs: 5108, μ: 957760, ~: 959248) -OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalWriteStateSequential(address,uint256,uint256,uint256) (runs: 5108, μ: 589806, ~: 590627) -OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalWriteStateSingle(address,uint256,uint256,uint256) (runs: 5108, μ: 222094, ~: 222915) -OrderBookWithdrawEvalTest:testOrderBookWithdrawalEvalRevertInAction(address,uint256,uint256,uint256) (runs: 5108, μ: 105270, ~: 106092) -OrderBookWithdrawEvalTest:testOrderBookWithdrawalEvalZeroAmountEvalNoop(address,uint256,uint256) (runs: 5108, μ: 57930, ~: 57699) -OrderBookWithdrawEvalTest:testOrderWithdrawContext(address,uint256,uint256,uint256) (runs: 5108, μ: 963970, ~: 960739) -OrderBookWithdrawTest:testWithdrawEmptyVault(address,address,uint256,uint256) (runs: 5108, μ: 17492, ~: 17492) -OrderBookWithdrawTest:testWithdrawFailure(address,uint256,uint256,uint256) (runs: 5108, μ: 1040417244, ~: 1040398271) -OrderBookWithdrawTest:testWithdrawFullVault(address,uint256,uint256,uint256) (runs: 5101, μ: 39862, ~: 39848) -OrderBookWithdrawTest:testWithdrawMany((bool,address,address,uint256,uint248)[]) (runs: 5108, μ: 3133203, ~: 3125728) -OrderBookWithdrawTest:testWithdrawPartialVault(address,uint256,uint256,uint256) (runs: 5103, μ: 50202, ~: 50202) -OrderBookWithdrawTest:testWithdrawZero(address,address,uint256) (runs: 5108, μ: 13038, ~: 13038) -RouteProcessorOrderBookV4ArbOrderTakerExpressionTest:testRouteProcessorTakeOrdersExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256[],uint256[]) (runs: 5108, μ: 364592, ~: 363612) -RouteProcessorOrderBookV4ArbOrderTakerExpressionTest:testRouteProcessorTakeOrdersWrongExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,address,bytes)) (runs: 5108, μ: 160677, ~: 159681) -RouteProcessorOrderBookV4ArbOrderTakerSenderTest:testRouteProcessorMinimumOutput((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5108, μ: 296534, ~: 295366) -RouteProcessorOrderBookV4ArbOrderTakerSenderTest:testRouteProcessorTakeOrdersSender((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5108, μ: 251374, ~: 250031) \ No newline at end of file +GenericPoolOrderBookV4ArbOrderTakerExpressionTest:testGenericPoolTakeOrdersExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256[],uint256[]) (runs: 5098, μ: 414799, ~: 414130) +GenericPoolOrderBookV4ArbOrderTakerExpressionTest:testGenericPoolTakeOrdersWrongExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,address,bytes)) (runs: 5098, μ: 163339, ~: 162325) +GenericPoolOrderBookV4ArbOrderTakerSenderTest:testGenericPoolTakeOrdersSender((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5098, μ: 265146, ~: 263786) +GenericPoolOrderBookV4FlashBorrowerTest:testGenericPoolOrderBookV4FlashBorrowerTakeOrdersSender((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5098, μ: 505100, ~: 501748) +LibOrderTest:testHashEqual((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32)) (runs: 5098, μ: 200019, ~: 196561) +LibOrderTest:testHashNotEqual((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32)) (runs: 5098, μ: 303167, ~: 302381) +OrderBookAddOrderEnactTest:testAddLiveOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 918953, ~: 907494) +OrderBookAddOrderEnactTest:testAddLiveOrderRevertNoAdd(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 719260, ~: 710511) +OrderBookAddOrderEnactTest:testAddOrderContext(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1026268, ~: 1016050) +OrderBookAddOrderEnactTest:testAddOrderEmptyNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 642023, ~: 633667) +OrderBookAddOrderEnactTest:testAddOrderOneReadState(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 702775, ~: 694416) +OrderBookAddOrderEnactTest:testAddOrderOneStateless(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 688123, ~: 679764) +OrderBookAddOrderEnactTest:testAddOrderWriteStateDifferentOwnersNamespaced(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 3104764, ~: 3097313) +OrderBookAddOrderEnactTest:testAddOrderWriteStateSequential(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 936582, ~: 928211) +OrderBookAddOrderEnactTest:testAddOrderWriteStateSingle(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1330963, ~: 1316168) +OrderBookAddOrderMockTest:testAddOrderSameAccountWithDifferentConfig(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,bytes) (runs: 5098, μ: 2690435, ~: 2683845) +OrderBookAddOrderMockTest:testAddOrderTwoAccountsWithDifferentConfig(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,bytes) (runs: 5098, μ: 2573014, ~: 2568129) +OrderBookAddOrderMockTest:testAddOrderTwoAccountsWithSameConfig(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 2437645, ~: 2418681) +OrderBookAddOrderMockTest:testAddOrderWithCalculationsInputsAndOutputsSucceeds(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 1248121, ~: 1229414) +OrderBookAddOrderMockTest:testAddOrderWithNonEmptyMetaEmitsMetaV1(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 1257410, ~: 1237498) +OrderBookAddOrderMockTest:testAddOrderWithNonEmptyMetaReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 670685, ~: 661444) +OrderBookAddOrderMockTest:testAddOrderWithoutCalculationsDeploys(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 659815, ~: 651084) +OrderBookAddOrderMockTest:testAddOrderWithoutInputsReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 157582, ~: 156760) +OrderBookAddOrderMockTest:testAddOrderWithoutOutputsReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 158066, ~: 156903) +OrderBookAddOrderNonceTest:testAddOrderNonceDifferentNonceStateChange(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes32) (runs: 5098, μ: 1225000, ~: 1217394) +OrderBookAddOrderNonceTest:testAddOrderNonceSameNonceDifferentOrderStateChange(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1459125, ~: 1453757) +OrderBookAddOrderNonceTest:testAddOrderNonceSameOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 946591, ~: 933192) +OrderBookAddOrderOwnerTest:testAddOrderOwnerDifferentOwnerStateChange(((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),address,address) (runs: 5098, μ: 1216691, ~: 1216089) +OrderBookAddOrderOwnerTest:testAddOrderOwnerSameOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 946687, ~: 933288) +OrderBookAddOrderTest:testAddOrderRealCalculateInputsReverts1(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 644191, ~: 635834) +OrderBookAddOrderTest:testAddOrderRealCalculateInputsReverts2(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 645974, ~: 637617) +OrderBookAddOrderTest:testAddOrderRealCalculateInputsRevertsPreference(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 645537, ~: 637180) +OrderBookAddOrderTest:testAddOrderRealNoHandleIODeploys(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 636273, ~: 627916) +OrderBookAddOrderTest:testAddOrderRealNoSourcesDeploys(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 613944, ~: 605588) +OrderBookAddOrderTest:testAddOrderRealOneStackCalculateReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 648501, ~: 640144) +OrderBookAddOrderTest:testAddOrderRealThreeStackCalculate(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 661103, ~: 652746) +OrderBookAddOrderTest:testAddOrderRealTwoStackCalculateReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 654745, ~: 646388) +OrderBookAddOrderTest:testAddOrderRealZeroStackCalculateReverts(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 642911, ~: 634554) +OrderBookClearHandleIORevertTest:testClearOrderAliceNoHandleIORevert() (gas: 520609) +OrderBookClearHandleIORevertTest:testClearOrderBobNoHandleIORevert() (gas: 520610) +OrderBookClearHandleIORevertTest:testClearOrderBothNoHandleIORevert() (gas: 499936) +OrderBookClearHandleIORevertTest:testClearOrderHandleIO0() (gas: 560831) +OrderBookClearHandleIORevertTest:testClearOrderHandleIO1() (gas: 552774) +OrderBookClearHandleIORevertTest:testClearOrderHandleIO2() (gas: 552982) +OrderBookClearHandleIORevertTest:testClearOrderHandleIO3() (gas: 560875) +OrderBookClearHandleIORevertTest:testClearOrderHandleIO4() (gas: 568740) +OrderBookClearHandleIORevertTest:testClearOrderHandleIO5() (gas: 526338) +OrderBookClearOrderBadStackTest:testClearOrderBadStackEmptyStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2308778, ~: 2309858) +OrderBookClearOrderBadStackTest:testClearOrderBadStackOneEmpty(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2394422, ~: 2397339) +OrderBookClearOrderBadStackTest:testClearOrderBadStackOneOne(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2402165, ~: 2405083) +OrderBookClearOrderBadStackTest:testClearOrderBadStackOneOtherOne(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2329938, ~: 2331022) +OrderBookClearOrderBadStackTest:testClearOrderBadStackOneStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2323511, ~: 2324595) +OrderBookClearOrderBadStackTest:testClearOrderBadStackOtherEmpty(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2322267, ~: 2323355) +OrderBookClearOrderContextTest:testContextEmptyStack(address,address,uint256,uint256,uint256,uint256) (runs: 5098, μ: 2176637, ~: 2177740) +OrderBookClearTest:testClearSimple(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256,bytes,address,uint256,uint256) (runs: 5098, μ: 530333, ~: 529545) +OrderBookClearTest:testFlashLoanToNonReceiver(uint256,bytes,bytes32,bytes) (runs: 5098, μ: 28247, ~: 28145) +OrderBookDepositEnactTest:testDepositRevertInAction(address,uint256,uint256) (runs: 5098, μ: 97295, ~: 97295) +OrderBookDepositEnactTest:testOrderBookDepositEnactEmptyNoop(address,uint256,uint256) (runs: 5098, μ: 41751, ~: 41751) +OrderBookDepositEnactTest:testOrderBookDepositEnactOneReadState(address,uint256,uint256) (runs: 5098, μ: 104020, ~: 104020) +OrderBookDepositEnactTest:testOrderBookDepositEnactOneStateless(address,uint256,uint256) (runs: 5098, μ: 89382, ~: 89382) +OrderBookDepositEnactTest:testOrderBookDepositEvalWriteStateDifferentOwnersNamespaced(address,address,uint256,uint256) (runs: 5098, μ: 959820, ~: 959588) +OrderBookDepositEnactTest:testOrderBookDepositEvalWriteStateSequential(address,uint256,uint256) (runs: 5098, μ: 594342, ~: 594113) +OrderBookDepositEnactTest:testOrderBookDepositEvalWriteStateSingle(address,uint256,uint256) (runs: 5098, μ: 212949, ~: 212720) +OrderBookDepositEnactTest:testOrderDepositContext(address,uint256,uint256,uint256) (runs: 5098, μ: 651691, ~: 652102) +OrderBookDepositTest:testDepositEvent(address,uint256,uint256) (runs: 5098, μ: 39527, ~: 39527) +OrderBookDepositTest:testDepositFail(address,uint256,uint256) (runs: 5098, μ: 1040441637, ~: 1040441600) +OrderBookDepositTest:testDepositGas00() (gas: 8940) +OrderBookDepositTest:testDepositGas01() (gas: 35406) +OrderBookDepositTest:testDepositMany((address,address,uint256,uint248)[]) (runs: 5096, μ: 2608801, ~: 1766149) +OrderBookDepositTest:testDepositOverflow(address,uint256,uint256,uint256) (runs: 5097, μ: 53328, ~: 53654) +OrderBookDepositTest:testDepositReentrancy(address,uint256,uint256,address,uint256,uint256) (runs: 5098, μ: 623886, ~: 624277) +OrderBookDepositTest:testDepositSimple(address,uint256,uint256) (runs: 5098, μ: 38760, ~: 38760) +OrderBookDepositTest:testDepositZero(address,uint256) (runs: 5098, μ: 13201, ~: 13201) +OrderBookDepositTest:testVaultBalanceNoDeposits(address,uint256) (runs: 5098, μ: 8947, ~: 8947) +OrderBookEnactTest:testOrderBookEvalEmptyNoop(address) (runs: 5098, μ: 14051, ~: 14051) +OrderBookEnactTest:testOrderBookEvalOneReadState(address) (runs: 5098, μ: 73408, ~: 73408) +OrderBookEnactTest:testOrderBookEvalOneStateless(address) (runs: 5098, μ: 58746, ~: 58746) +OrderBookEnactTest:testOrderBookEvalWriteStateDifferentOwnersNamespaced(address,address) (runs: 5098, μ: 867107, ~: 867107) +OrderBookEnactTest:testOrderBookEvalWriteStateSequential() (gas: 543024) +OrderBookEnactTest:testOrderBookEvalWriteStateSingle(address) (runs: 5098, μ: 170894, ~: 170894) +OrderBookQuoteTest:testQuoteContextSender(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256) (runs: 5098, μ: 10250360, ~: 10145015) +OrderBookQuoteTest:testQuoteDeadOrder(((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,uint256[],bytes)[])) (runs: 5098, μ: 6690092, ~: 5858346) +OrderBookQuoteTest:testQuoteMaxOutput(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256) (runs: 5098, μ: 1116746, ~: 1104627) +OrderBookQuoteTest:testQuoteSimple(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),uint256) (runs: 5098, μ: 1109950, ~: 1097725) +OrderBookRemoveOrderEnactTest:testRemoveOrderContext(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 659628, ~: 653180) +OrderBookRemoveOrderEnactTest:testRemoveOrderDeadOrder(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 357726, ~: 352918) +OrderBookRemoveOrderEnactTest:testRemoveOrderEmptyNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1082921, ~: 1068241) +OrderBookRemoveOrderEnactTest:testRemoveOrderOneReadState(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1144010, ~: 1129329) +OrderBookRemoveOrderEnactTest:testRemoveOrderOneStateless(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1129366, ~: 1114685) +OrderBookRemoveOrderEnactTest:testRemoveOrderRevertInAction(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1268373, ~: 1251693) +OrderBookRemoveOrderEnactTest:testRemoveOrderWriteStateDifferentOwnersNamespaced(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 4878475, ~: 4863634) +OrderBookRemoveOrderEnactTest:testRemoveOrderWriteStateSequential(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 1379174, ~: 1364481) +OrderBookRemoveOrderEnactTest:testRemoveOrderWriteStateSingle(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 2213534, ~: 2186094) +OrderBookRemoveOrderMockTest:testRemoveOrderAddRemoveMulti(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 7128115, ~: 6977151) +OrderBookRemoveOrderMockTest:testRemoveOrderDifferent(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 4982473, ~: 4919186) +OrderBookRemoveOrderMockTest:testRemoveOrderDifferentOwners(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 4822347, ~: 4771268) +OrderBookRemoveOrderMockTest:testRemoveOrderDifferentOwnersDifferent(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 10331040, ~: 10210350) +OrderBookRemoveOrderMockTest:testRemoveOrderDoesNotExist(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 375408, ~: 369597) +OrderBookRemoveOrderMockTest:testRemoveOrderOnlyOwner(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),bytes) (runs: 5098, μ: 2583139, ~: 2560568) +OrderBookRemoveOrderOwnerTest:testRemoveOrderOwnerDifferentOwnerStateChange(((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),address,address) (runs: 5098, μ: 5922447, ~: 5846913) +OrderBookRemoveOrderOwnerTest:testRemoveOrderOwnerSameOrderNoop(address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 3406001, ~: 3346434) +OrderBookRemoveOrderOwnerTest:testRemoveOrderWrongOwner(((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),address,address) (runs: 5098, μ: 759863, ~: 759272) +OrderBookSubParserContextCalculatedIORatioTest:testSubParserContextHappy() (gas: 2102274) +OrderBookSubParserContextCalculatedIORatioTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080218) +OrderBookSubParserContextCalculatedIORatioTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065830) +OrderBookSubParserContextCalculatedMaxOutputTest:testSubParserContextHappy() (gas: 2102602) +OrderBookSubParserContextCalculatedMaxOutputTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080542) +OrderBookSubParserContextCalculatedMaxOutputTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2066157) +OrderBookSubParserContextInputTokenDecimalsTest:testSubParserContextHappy() (gas: 2102440) +OrderBookSubParserContextInputTokenDecimalsTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080380) +OrderBookSubParserContextInputTokenDecimalsTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065995) +OrderBookSubParserContextInputTokenTest:testSubParserContextHappy() (gas: 2100978) +OrderBookSubParserContextInputTokenTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2078919) +OrderBookSubParserContextInputTokenTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2064534) +OrderBookSubParserContextInputVaultBalanceIncreaseTest:testSubParserContextHappy() (gas: 2102440) +OrderBookSubParserContextInputVaultBalanceIncreaseTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080380) +OrderBookSubParserContextInputVaultBalanceIncreaseTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065995) +OrderBookSubParserContextOrderBookTest:testSubParserContextHappy() (gas: 2100654) +OrderBookSubParserContextOrderBookTest:testSubParserContextHappy() (gas: 2101464) +OrderBookSubParserContextOrderBookTest:testSubParserContextHappy() (gas: 2101626) +OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2078595) +OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2079405) +OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2079567) +OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2064210) +OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065020) +OrderBookSubParserContextOrderBookTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065182) +OrderBookSubParserContextOrderClearerTest:testSubParserContextHappy() (gas: 2101302) +OrderBookSubParserContextOrderClearerTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2079243) +OrderBookSubParserContextOrderClearerTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2064858) +OrderBookSubParserContextOrderCounterpartyTest:testSubParserContextHappy() (gas: 2102112) +OrderBookSubParserContextOrderCounterpartyTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080056) +OrderBookSubParserContextOrderCounterpartyTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065668) +OrderBookSubParserContextOrderHashTest:testSubParserContextHappy() (gas: 2100816) +OrderBookSubParserContextOrderHashTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2078757) +OrderBookSubParserContextOrderHashTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2064372) +OrderBookSubParserContextOrderOwnerTest:testSubParserContextHappy() (gas: 2100978) +OrderBookSubParserContextOrderOwnerTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2078919) +OrderBookSubParserContextOrderOwnerTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2064534) +OrderBookSubParserContextOutputTokenDecimalsTest:testSubParserContextHappy() (gas: 2102602) +OrderBookSubParserContextOutputTokenDecimalsTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080542) +OrderBookSubParserContextOutputTokenDecimalsTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2066157) +OrderBookSubParserContextOutputTokenTest:testSubParserContextHappy() (gas: 2101140) +OrderBookSubParserContextOutputTokenTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2079081) +OrderBookSubParserContextOutputTokenTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2064696) +OrderBookSubParserContextOutputVaultBalanceBeforeTest:testSubParserContextHappy() (gas: 2102274) +OrderBookSubParserContextOutputVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080218) +OrderBookSubParserContextOutputVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065830) +OrderBookSubParserContextOutputVaultBalanceDecreaseTest:testSubParserContextHappy() (gas: 2102602) +OrderBookSubParserContextOutputVaultBalanceDecreaseTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080542) +OrderBookSubParserContextOutputVaultBalanceDecreaseTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2066157) +OrderBookSubParserContextVaultBalanceBeforeTest:testSubParserContextHappy() (gas: 2102112) +OrderBookSubParserContextVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedInputs() (gas: 2080056) +OrderBookSubParserContextVaultBalanceBeforeTest:testSubParserContextUnhappyDisallowedOperand() (gas: 2065668) +OrderBookSubParserDescribedByMetaV1Test:testOrderBookSubParserDescribedByMetaV1Happy() (gas: 2018322) +OrderBookSubParserIERC165Test:testOrderBookSubParserIERC165(bytes4) (runs: 5098, μ: 2018691, ~: 2018691) +OrderBookSubParserPointersTest:testSubParserFunctionPointers() (gas: 2029308) +OrderBookSubParserPointersTest:testSubParserOperandParsers() (gas: 2029308) +OrderBookSubParserPointersTest:testSubParserParseMeta() (gas: 172448) +OrderBookSubParserPointersTest:testWordOperandLengthEquivalence() (gas: 4076) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy0() (gas: 2107911) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy1() (gas: 2107946) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy2() (gas: 2107947) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextHappy3() (gas: 2108070) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextUnhappyInput() (gas: 2085743) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextUnhappyNoOperand() (gas: 2061657) +OrderBookSubParserSignedContextTest:testSubParserContextSignedContextUnhappyTooManyOperands() (gas: 2071050) +OrderBookSubParserSignersTest:testSubParserContextSignerHappy0() (gas: 2103198) +OrderBookSubParserSignersTest:testSubParserContextSignerHappy1() (gas: 2103255) +OrderBookSubParserSignersTest:testSubParserContextSignerUnhappyInput() (gas: 2081027) +OrderBookSubParserSignersTest:testSubParserContextSignerUnhappyNoOperand() (gas: 2060334) +OrderBookSubParserSignersTest:testSubParserContextSignerUnhappyTooManyOperands() (gas: 2066585) +OrderBookTakeOrderBadStackTest:testTakeOrderBadStackEmptyStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 945476, ~: 940920) +OrderBookTakeOrderBadStackTest:testTakeOrderBadStackOneStack(address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 952790, ~: 948234) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO0() (gas: 240891) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO1() (gas: 404863) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO10(uint256) (runs: 5098, μ: 647502, ~: 608849) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO2() (gas: 418589) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO3() (gas: 563097) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO4() (gas: 582608) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO5() (gas: 582607) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO6() (gas: 568812) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO7(uint256) (runs: 5098, μ: 827165, ~: 827124) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO8(uint256) (runs: 5098, μ: 985760, ~: 985718) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderHandleIO9(uint256) (runs: 5098, μ: 734533, ~: 663954) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderNoHandleIORevert0() (gas: 232804) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderNoHandleIORevert1() (gas: 390799) +OrderBookTakeOrderHandleIORevertTest:testTakeOrderNoHandleIORevert2() (gas: 377074) +OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputMultipleOrders(uint256,uint256) (runs: 5098, μ: 413917, ~: 424640) +OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputMultipleOrdersMultipleOwners(uint256,uint256,uint256) (runs: 5098, μ: 470108, ~: 482687) +OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleAnyDeposit(uint256,uint256) (runs: 5098, μ: 259496, ~: 261742) +OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleOrderLessThanMaximumInput(uint256,uint256) (runs: 5098, μ: 242216, ~: 243376) +OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleOrderLessThanMaximumOutput(uint256) (runs: 5098, μ: 241744, ~: 241704) +OrderBookTakeOrderMaximumInputTest:testTakeOrderMaximumInputSingleOrderUnlimitedMax(uint256) (runs: 5098, μ: 238736, ~: 238508) +OrderBookTakeOrderMaximumInputTest:testTakeOrderNoopZeroMaxTakerInput((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),(address,uint256[],bytes)) (runs: 5098, μ: 185109, ~: 185244) +OrderBookTakeOrderNoopTest:testTakeOrderNoopNonLiveOrderOne((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,uint256[],bytes)) (runs: 5098, μ: 426388, ~: 424494) +OrderBookTakeOrderNoopTest:testTakeOrderNoopNonLiveOrderTwo((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256,(address,uint256[],bytes),(address,uint256[],bytes)) (runs: 5098, μ: 854467, ~: 850191) +OrderBookTakeOrderNoopTest:testTakeOrderNoopZeroOrders() (gas: 12427) +OrderBookTakeOrderPrecisionTest:testTakeOrderPrecisionKnownBad01() (gas: 2221895) +OrderBookTakeOrderTokenMismatchDecimalsTest:testTokenDecimalsMismatchOutputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5098, μ: 617295, ~: 613912) +OrderBookTakeOrderTokenMismatchDecimalsTest:testTokenMismatchInputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5098, μ: 615938, ~: 612089) +OrderBookTakeOrderTokenMismatchTest:testTokenDecimalMismatchOutputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5098, μ: 614040, ~: 612469) +OrderBookTakeOrderTokenMismatchTest:testTokenMismatchInputs((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256,uint256) (runs: 5098, μ: 612768, ~: 611215) +OrderBookV4ArbOrderTakerContextTest:testOrderBookV4ArbOrderTakerContext() (gas: 2602327) +OrderBookV4ArbOrderTakerIERC165Test:testOrderBookV4ArbOrderTakerIERC165(bytes4) (runs: 5098, μ: 2374572, ~: 2374572) +OrderBookV4FlashBorrowerIERC165Test:testOrderBookV4FlashBorrowerIERC165(bytes4) (runs: 5098, μ: 2786827, ~: 2786827) +OrderBookV4FlashLenderFeeTest:testFlashFee(address,uint256) (runs: 5098, μ: 6536, ~: 6536) +OrderBookV4FlashLenderIERC165Test:testOrderBookV4FlashLenderIERC165(bytes4) (runs: 5098, μ: 580452, ~: 580452) +OrderBookV4FlashLenderMaxFlashLoanTest:testFlashMaxLoan(uint256) (runs: 5098, μ: 7981, ~: 7981) +OrderBookV4FlashLenderMockSuccessTest:testFlashLoanToReceiver(uint256,bytes) (runs: 5098, μ: 14786, ~: 14732) +OrderBookV4FlashLenderReentrant:testReenterAddOrder(uint256,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 18749924, ~: 18693607) +OrderBookV4FlashLenderReentrant:testReenterCheckOrderExists(bytes32,uint256) (runs: 5098, μ: 553697, ~: 553900) +OrderBookV4FlashLenderReentrant:testReenterClear(uint256,address,address,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes),((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 38004449, ~: 37927377) +OrderBookV4FlashLenderReentrant:testReenterDeposit(uint256,uint256,uint256) (runs: 5098, μ: 655149, ~: 655599) +OrderBookV4FlashLenderReentrant:testReenterReadVaultBalances(uint256,uint256) (runs: 5098, μ: 598769, ~: 599187) +OrderBookV4FlashLenderReentrant:testReenterRemoveOrder(uint256,(address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32)) (runs: 5098, μ: 18186416, ~: 18137914) +OrderBookV4FlashLenderReentrant:testReenterTakeOrder(uint256,((address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32,bytes32,bytes)) (runs: 5098, μ: 19378697, ~: 19321453) +OrderBookV4FlashLenderReentrant:testReenterWithdraw(uint256,uint256,uint256) (runs: 5098, μ: 631616, ~: 632066) +OrderBookV4FlashLenderTransferTest:testFlashLoanTransferFail(uint256,uint256,bool) (runs: 5098, μ: 1345185, ~: 1344056) +OrderBookV4FlashLenderTransferTest:testFlashLoanTransferSuccess(uint256,bool) (runs: 5098, μ: 1290664, ~: 1297531) +OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalEmptyNoop(address,uint256,uint256,uint256) (runs: 5098, μ: 53634, ~: 54109) +OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalOneReadState(address,uint256,uint256,uint256) (runs: 5098, μ: 115846, ~: 116671) +OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalOneStateless(address,uint256,uint256,uint256) (runs: 5098, μ: 101229, ~: 102054) +OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalWriteStateDifferentOwnersNamespaced(address,address,uint256,uint256,uint256) (runs: 5098, μ: 992910, ~: 994386) +OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalWriteStateSequential(address,uint256,uint256,uint256) (runs: 5098, μ: 611835, ~: 612659) +OrderBookWithdrawEvalTest:testOrderBookWithdrawEvalWriteStateSingle(address,uint256,uint256,uint256) (runs: 5098, μ: 229589, ~: 230413) +OrderBookWithdrawEvalTest:testOrderBookWithdrawalEvalRevertInAction(address,uint256,uint256,uint256) (runs: 5098, μ: 108833, ~: 109658) +OrderBookWithdrawEvalTest:testOrderBookWithdrawalEvalZeroAmountEvalNoop(address,uint256,uint256) (runs: 5098, μ: 60997, ~: 60768) +OrderBookWithdrawEvalTest:testOrderWithdrawContext(address,uint256,uint256,uint256) (runs: 5098, μ: 723218, ~: 721592) +OrderBookWithdrawTest:testWithdrawEmptyVault(address,address,uint256,uint256) (runs: 5098, μ: 17802, ~: 17802) +OrderBookWithdrawTest:testWithdrawFailure(address,uint256,uint256,uint256) (runs: 5098, μ: 1040417757, ~: 1040398990) +OrderBookWithdrawTest:testWithdrawFullVault(address,uint256,uint256,uint256) (runs: 5097, μ: 40862, ~: 40845) +OrderBookWithdrawTest:testWithdrawMany((bool,address,address,uint256,uint248)[]) (runs: 5098, μ: 3240941, ~: 3230705) +OrderBookWithdrawTest:testWithdrawPartialVault(address,uint256,uint256,uint256) (runs: 5097, μ: 51385, ~: 51385) +OrderBookWithdrawTest:testWithdrawZero(address,address,uint256) (runs: 5098, μ: 13382, ~: 13382) +RouteProcessorOrderBookV4ArbOrderTakerExpressionTest:testRouteProcessorTakeOrdersExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,uint256[],uint256[]) (runs: 5098, μ: 371115, ~: 370139) +RouteProcessorOrderBookV4ArbOrderTakerExpressionTest:testRouteProcessorTakeOrdersWrongExpression((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256,(address,address,bytes)) (runs: 5098, μ: 163363, ~: 162347) +RouteProcessorOrderBookV4ArbOrderTakerSenderTest:testRouteProcessorTakeOrdersSender((address,(address,address,bytes),(address,uint8,uint256)[],(address,uint8,uint256)[],bytes32),uint256,uint256) (runs: 5098, μ: 265260, ~: 263901) \ No newline at end of file diff --git a/test/abstract/OrderBookV4ArbOrderTaker.context.t.sol b/test/abstract/OrderBookV4ArbOrderTaker.context.t.sol new file mode 100644 index 000000000..30fcfa75f --- /dev/null +++ b/test/abstract/OrderBookV4ArbOrderTaker.context.t.sol @@ -0,0 +1,114 @@ +// SPDX-License-Identifier: CAL +pragma solidity =0.8.25; + +import { + ChildOrderBookV4ArbOrderTaker, + TaskV1, + SignedContextV1, + EvaluableV3 +} from "../util/concrete/ChildOrderBookV4ArbOrderTaker.sol"; +import {OrderBookExternalRealTest} from "../util/abstract/OrderBookExternalRealTest.sol"; +import { + TakeOrdersConfigV3, + TakeOrderConfigV3, + IO, + OrderConfigV3, + OrderV3, + IInterpreterV3 +} from "rain.orderbook.interface/interface/IOrderBookV4.sol"; +import {IERC20} from "openzeppelin-contracts/contracts/token/ERC20/IERC20.sol"; +import {IERC20Metadata} from "openzeppelin-contracts/contracts/token/ERC20/extensions/IERC20Metadata.sol"; +import {StateNamespace, LibNamespace} from "src/concrete/ob/OrderBook.sol"; + +contract OrderBookV4ArbOrderTakerContextTest is OrderBookExternalRealTest { + function testOrderBookV4ArbOrderTakerContext() external { + address alice = address(999999); + address bob = address(999998); + ChildOrderBookV4ArbOrderTaker arbOrderTaker = new ChildOrderBookV4ArbOrderTaker(); + + OrderConfigV3 memory aliceOrderConfig; + { + IO[] memory aliceValidInputs = new IO[](1); + aliceValidInputs[0] = IO({token: address(iToken0), decimals: 12, vaultId: 0}); + + IO[] memory aliceValidOutputs = new IO[](1); + aliceValidOutputs[0] = IO({token: address(iToken1), decimals: 12, vaultId: 0}); + + aliceOrderConfig = OrderConfigV3({ + evaluable: EvaluableV3(iInterpreter, iStore, ""), + validInputs: aliceValidInputs, + validOutputs: aliceValidOutputs, + nonce: 0, + secret: 0, + meta: "" + }); + } + + OrderV3 memory aliceOrder = OrderV3({ + owner: alice, + evaluable: aliceOrderConfig.evaluable, + validInputs: aliceOrderConfig.validInputs, + validOutputs: aliceOrderConfig.validOutputs, + nonce: aliceOrderConfig.nonce + }); + + TakeOrderConfigV3 memory aliceTakeOrderConfig = TakeOrderConfigV3({ + order: aliceOrder, + inputIOIndex: 0, + outputIOIndex: 0, + signedContext: new SignedContextV1[](0) + }); + + TakeOrderConfigV3[] memory orders = new TakeOrderConfigV3[](1); + orders[0] = aliceTakeOrderConfig; + TakeOrdersConfigV3 memory takeOrdersConfig = TakeOrdersConfigV3({ + minimumInput: 0, + maximumInput: type(uint256).max, + maximumIORatio: type(uint256).max, + orders: orders, + data: "" + }); + + TaskV1 memory task = TaskV1({ + evaluable: EvaluableV3({ + interpreter: iInterpreter, + store: iStore, + bytecode: iParserV2.parse2( + bytes( + string.concat( + ":ensure(equal-to(context<1 0>() 3) \"input token\"),", + ":ensure(equal-to(context<1 1>() 4) \"output token\"),", + ":ensure(equal-to(context<1 2>() 5) \"gas balance\");" + ) + ) + ) + }), + signedContext: new SignedContextV1[](0) + }); + + vm.mockCall(address(iToken0), abi.encodeWithSelector(IERC20.approve.selector), abi.encode(true)); + vm.mockCall( + address(iToken0), + abi.encodeWithSelector(IERC20.allowance.selector), + abi.encode(0) + ); + vm.mockCall( + address(iToken0), + abi.encodeWithSelector(IERC20.balanceOf.selector, address(arbOrderTaker)), + abi.encode(3e12) + ); + vm.mockCall( + address(iToken1), + abi.encodeWithSelector(IERC20.balanceOf.selector, address(arbOrderTaker)), + abi.encode(4e12) + ); + vm.mockCall(address(iToken0), abi.encodeWithSelector(IERC20.transfer.selector), abi.encode(true)); + vm.mockCall(address(iToken1), abi.encodeWithSelector(IERC20.transfer.selector), abi.encode(true)); + vm.mockCall(address(iToken0), abi.encodeWithSelector(IERC20Metadata.decimals.selector), abi.encode(12)); + vm.mockCall(address(iToken1), abi.encodeWithSelector(IERC20Metadata.decimals.selector), abi.encode(12)); + + vm.deal(address(arbOrderTaker), 5e18); + vm.prank(bob); + arbOrderTaker.arb3(iOrderbook, takeOrdersConfig, task); + } +} diff --git a/test/abstract/OrderBookV4ArbOrderTaker.ierc165.t.sol b/test/abstract/OrderBookV4ArbOrderTaker.ierc165.t.sol index 4e94550bd..f5923e825 100644 --- a/test/abstract/OrderBookV4ArbOrderTaker.ierc165.t.sol +++ b/test/abstract/OrderBookV4ArbOrderTaker.ierc165.t.sol @@ -14,23 +14,7 @@ import { } from "src/abstract/OrderBookV4ArbOrderTaker.sol"; import {IInterpreterV3} from "rain.interpreter.interface/interface/IInterpreterV3.sol"; import {IInterpreterStoreV2} from "rain.interpreter.interface/interface/IInterpreterStoreV2.sol"; - -/// @dev We need a contract that is deployable in order to test the abstract -/// base contract. -contract ChildOrderBookV4ArbOrderTaker is OrderBookV4ArbOrderTaker { - constructor() - OrderBookV4ArbOrderTaker( - OrderBookV4ArbConfigV2( - address(0), - TaskV1({ - evaluable: EvaluableV3(IInterpreterV3(address(0)), IInterpreterStoreV2(address(0)), ""), - signedContext: new SignedContextV1[](0) - }), - abi.encode(address(0)) - ) - ) - {} -} +import {ChildOrderBookV4ArbOrderTaker} from "../util/concrete/ChildOrderBookV4ArbOrderTaker.sol"; contract OrderBookV4ArbOrderTakerIERC165Test is Test { /// Test that ERC165 and IOrderBookV4ArbOrderTaker are supported interfaces diff --git a/test/util/concrete/ChildOrderBookV4ArbOrderTaker.sol b/test/util/concrete/ChildOrderBookV4ArbOrderTaker.sol new file mode 100644 index 000000000..0a371ab2a --- /dev/null +++ b/test/util/concrete/ChildOrderBookV4ArbOrderTaker.sol @@ -0,0 +1,29 @@ +// SPDX-License-Identifier: CAL +pragma solidity =0.8.25; + +import { + OrderBookV4ArbOrderTaker, + SignedContextV1, + EvaluableV3, + TaskV1, + OrderBookV4ArbConfigV2 +} from "src/abstract/OrderBookV4ArbOrderTaker.sol"; +import {IInterpreterStoreV2} from "rain.interpreter.interface/interface/IInterpreterStoreV2.sol"; +import {IInterpreterV3} from "rain.interpreter.interface/interface/IInterpreterV3.sol"; + +/// @dev We need a contract that is deployable in order to test the abstract +/// base contract. +contract ChildOrderBookV4ArbOrderTaker is OrderBookV4ArbOrderTaker { + constructor() + OrderBookV4ArbOrderTaker( + OrderBookV4ArbConfigV2( + address(0), + TaskV1({ + evaluable: EvaluableV3(IInterpreterV3(address(0)), IInterpreterStoreV2(address(0)), ""), + signedContext: new SignedContextV1[](0) + }), + abi.encode(address(0)) + ) + ) + {} +}