Skip to content

Simplify allocate and deallocate flow for solvers #115

@0xJepsen

Description

@0xJepsen

The log normal solver has redundant implementations for the allocation and deallocation data getters. They should only return abi byte encoded deltas. In general each solver should have three pure getters that return the

  • valid abi encoded data for the update data call(s)
  • valid abi encoded data for the allocate and deallocate calls and
  • valid abi encoded data for the swap calls.

I think the update and swap calls are correct right now I have only implemented the pool type here #35, after merging in the spearbit fixes and getting new bindings. But the Constant sum allocations are not there and the log normal allocations are redundant. I have yet to finish the G3M and n-pools G3M.

Should we use the strategy lib here? there are redundant implementations it seems.

  • Rename allocate and deallocate helpers to prepare

functions in each solver should call the strategy lib and return the abi-encoded result

Metadata

Metadata

Assignees

No one assigned

    Labels

    📃 contractsAnything related to the DFMM contracts (or strategies)🛠️ kitAnything related to the DFMM kit🧹 improvementCode improvements or cleanup

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions