anchor
anchor copied to clipboard
[WIP] Cache bumps in a generated struct instead of a BTreeMap
Finally got round to hacking out the suggestion I brought up in https://github.com/coral-xyz/anchor/pull/1367#issuecomment-1033359105.
Current status:
- Think the changes to
lang/
work but I'll need a lot of help refactoring the rest of the examples and tests and cli to work with this change. - Made this repo to demo the differences in terms of both code and perf
Given the massive breaking changes this will result in, it's totally understandable if you guys decide that this change isn't worth it
@billythedummy is attempting to deploy a commit to the coral-xyz Team on Vercel.
A member of the Team first needs to authorize it.
It's definitely an interesting idea. I will try to confer with armani at some stage about the relative benefits / arguments for using a generated struct for bumps instead of a btree map. There must have a good reason to go with a btreemap in the first place but can definitely consider the generated struct approach going forward.
Hey @billythedummy, any news about this?
Hey @billythedummy, any news about this?
sry i pretty much forgot about this PR bec i was working on other stuff. The impl is pretty much done here, i just couldnt be bothered to modify the tests if this wasn't going to be merged in anyway. Probably better to close this and restart from latest master at this point in time if this is something people want
Okay, I'll take care of it, so thank you very much for all your hard work