-
Notifications
You must be signed in to change notification settings - Fork 21k
trie: use common.Hash as the key in secKeyCache map #31786
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
trie: use common.Hash as the key in secKeyCache map #31786
Conversation
Could you show that there is a benefit to this with a benchmark? |
Ok, I'll add a benchmark test case to show the difference. |
This is the benchmark result:
This is the test case:
|
01b4440
to
e99dd39
Compare
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.
SGTM
Simplify
secKeyCache
to avoid unnecessary transfers among[]byte
,string
andcommon.Hash
.