â›ŊGas Measurements

Compare to WETH/USDC Uniswap V3 Swap: ~150,000

Function
# of Calls
Minimum
Maximum
Average

cancelOrder

3

186,874

191,674

190,074

executeAllVirtualOrders

10

122,164

122,585

122,529

longTermSwapAToB

19

220,758

303,840

256,199

longTermSwapAToB-approve

19

46,201

46,213

46,212

longTermSwapAToB-transfer

19

34,594

51,706

35,505

longTermSwapBToA

11

249,548

276,601

258,191

longTermSwapBToA-approve

11

46,213

46,213

46,213

longTermSwapBToA-transfer

11

34,606

34,606

34,606

provideLiquidity

10

194,735

222,165

200,481

removeLiquidity

5

188,406

188,783

188,708

swapAToB

140

107,063

155,664

147,411

swapAToB-approve

140

46,189

46,201

46,200

swapAToB-transfer

140

34,582

51,682

34,715

swapBToA

260

107,134

182,788

148,877

swapBToA-approve

260

46,189

46,201

46,200

swapBToA-transfer

260

34,582

34,594

34,593

withdrawOrder

10

125,943

171,841

158,055

Benchmark Parameters

All values fixed-point 18 decimal values.
Benchmark test configured as follows:
   Simulation:
      length = 2000 blocks
      inactivity: 2 segments, min. 300 blocks

   TWAMM Pool:
      pool type = liquid
      block interval = 300
      initial reserve A = 5000
      initial reserve B = 3000
   Inactivity Segments:
      466 <---> 766   (start <---> end)
      1232 <---> 1532   (start <---> end)
   Overlap:
      45 events overlap (458 events total)
   Provide Liquidity Events:
      10 inserted (10 specified)
      LP tokens:
         initial supply = 3872
         provide mean = 774
         provide std. dev. = 77
   Remove Liquidity Events:
      5 inserted (5 specified)
   LT Swap Events:
      30 inserted (30 specified)
      65% A --> B swaps specified
      amount mean = 150 A, 90 B
      amount std. dev. = 15 A, 9 B
      length mean = 20 intervals
      length std. dev. = 2 intervals
   LT Swap Withdraw Events:
      10 inserted (10 specified)
   LT Swap Cancel Events:
      3 inserted (3 specified)
   Swap Events:
      400 inserted (400 specified)
      45 overlapping inserted
      35% A --> B swaps specified
      amount mean = 15 A, 9 B
      amount std. dev. = 1 A, 1 B
   Execute All Virtual Order Events:
      10 inserted (10 specified)

Last updated