Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zombie Interest #685

Merged
merged 20 commits into from
Dec 12, 2023
Merged

Zombie Interest #685

merged 20 commits into from
Dec 12, 2023

Conversation

jrhea
Copy link
Contributor

@jrhea jrhea commented Dec 1, 2023

This pr adds logic to allow hyperdrive LPs to collect interest from zombie positions

Copy link

github-actions bot commented Dec 1, 2023

Hyperdrive Gas Benchmark

Benchmark suite Current: f086b1f Previous: 099d850 Deviation Status
addLiquidity: min 1600 gas 1622 gas -1.3564%
addLiquidity: avg 53399 gas 54725 gas -2.4230%
addLiquidity: max 99828 gas 98648 gas 1.1962% 🚨
checkpoint: min 1216 gas 1216 gas 0% 🟰
checkpoint: avg 49754 gas 48259 gas 3.0979% 🚨
checkpoint: max 114768 gas 97592 gas 17.5998% 🚨
closeLong: min 1690 gas 1690 gas 0% 🟰
closeLong: avg 27018 gas 24890 gas 8.5496% 🚨
closeLong: max 137971 gas 114354 gas 20.6525% 🚨
closeShort: min 1693 gas 1693 gas 0% 🟰
closeShort: avg 29286 gas 27649 gas 5.9206% 🚨
closeShort: max 110588 gas 108976 gas 1.4792% 🚨
initialize: min 1605 gas 1605 gas 0% 🟰
initialize: avg 181867 gas 179780 gas 1.1609% 🚨
initialize: max 256838 gas 254322 gas 0.9893% 🚨
openLong: min 736 gas 736 gas 0% 🟰
openLong: avg 54445 gas 56291 gas -3.2794%
openLong: max 179948 gas 196013 gas -8.1959%
openShort: min 702 gas 702 gas 0% 🟰
openShort: avg 53759 gas 55560 gas -3.2415%
openShort: max 177871 gas 194932 gas -8.7523%
redeemWithdrawalShares: min 1598 gas 1598 gas 0% 🟰
redeemWithdrawalShares: avg 20958 gas 22367 gas -6.2995%
redeemWithdrawalShares: max 51824 gas 49853 gas 3.9536% 🚨
removeLiquidity: min 1661 gas 1661 gas 0% 🟰
removeLiquidity: avg 76538 gas 77183 gas -0.8357%
removeLiquidity: max 212872 gas 204563 gas 4.0618% 🚨

This comment was automatically generated by workflow using github-action-benchmark.

@coveralls
Copy link
Collaborator

coveralls commented Dec 1, 2023

Coverage Status

coverage: 95.764% (+0.1%) from 95.661%
when pulling f086b1f on zombie-interest
into 844fc0e on main.

@jrhea jrhea marked this pull request as ready for review December 7, 2023 23:51
@jrhea jrhea changed the title add logic for collecting logic from zombie positions Zombie Interest Dec 7, 2023
@jrhea jrhea requested a review from jalextowle December 7, 2023 23:52
Copy link
Contributor

@jalextowle jalextowle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice job on this! A few features that I was expecting are missing from this including paying out zombie interest on zombie shorts and giving some of the zombie interest to governance as a form of governance fees. It would be good to chat or talk about whether or not we want to do these things async.

@jrhea
Copy link
Contributor Author

jrhea commented Dec 8, 2023

Nice job on this! A few features that I was expecting are missing from this including paying out zombie interest on zombie shorts and giving some of the zombie interest to governance as a form of governance fees. It would be good to chat or talk about whether or not we want to do these things async.

I was thinking that the decision on how/if to payout zombie interest to governance is a discussion that needs to happen independent of this

@jalextowle
Copy link
Contributor

Nice job on this! A few features that I was expecting are missing from this including paying out zombie interest on zombie shorts and giving some of the zombie interest to governance as a form of governance fees. It would be good to chat or talk about whether or not we want to do these things async.

I was thinking that the decision on how/if to payout zombie interest to governance is a discussion that needs to happen independent of this

Okay, that sounds good to me.

Copy link
Contributor

@jalextowle jalextowle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work! This is a dope feature, and it actually dropped our gas costs for a bunch of core functions.

@jrhea jrhea enabled auto-merge (squash) December 12, 2023 02:37
@jrhea jrhea merged commit f3905d8 into main Dec 12, 2023
7 checks passed
@jrhea jrhea deleted the zombie-interest branch December 12, 2023 03:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants