-
Notifications
You must be signed in to change notification settings - Fork 40
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
Refactor access list search #637
Conversation
Reminder for |
#[allow(dead_code)] | ||
pub const ADDRESSES_ACCESS_LIST_LEN: usize = 2; | ||
#[allow(dead_code)] | ||
pub const STORAGE_KEYS_ACCESS_LIST_LEN: usize = 4; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: we probably don't wanna keep all these dead code lines
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was using those when debugging. How can I keep it for future use?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm ideally if you want to keep it then we could group all of these unused into some
#[allow(unused)]
pub(crate) mod debugging {
}
but is it really going to be useful in the future? Or was it helpful only for the transition of access list searching?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the end there was a test using ADDRESSES_ACCESS_LIST_LEN
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After our walk-through I think this looks good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, modulo the remaining points mentioned by @einar-polygon
This PR removes the linear search required for finding a node's pointer in the access list. Closes #611.