cfmms-rs
cfmms-rs copied to clipboard
Integrate Batched Calls in v3 Swap simulation
simulate_swap
and simulate_swap_mut
both require two external calls to the node to retrieve the Tick.Info
and the word corresponding to tickBitmap[currentTick]
during simulation. Two separate calls are made each time an initialized tick in crossed.
This can be optimized by batching the two calls into a single call to the node as both calls can happen in parallel. I think this will be most easily accomplished by abstracting the calls to the node outside of uniswap_v3_math
into cfmms-rs
.