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

feat: redesign nonce cache #5602

Draft
wants to merge 3 commits into
base: develop
Choose a base branch
from
Draft

Conversation

obycode
Copy link
Contributor

@obycode obycode commented Dec 19, 2024

This is the same as #5599 except built against develop.

This redesign uses a proper LRU cache and is more careful about flushing the cache more efficiently.

This redesign uses a proper LRU cache and is more careful about flushing
the cache more efficiently.
@aldur aldur linked an issue Dec 20, 2024 that may be closed by this pull request
@aldur aldur requested a review from hstove December 20, 2024 15:48
clarity_instance
.begin_test_genesis_block(
&StacksBlockId::sentinel(),
&StacksBlockId([0 as u8; 32]),
Copy link
Contributor

Choose a reason for hiding this comment

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

I know you didn't write this and just moved this file, but the proper way to do this is

Suggested change
&StacksBlockId([0 as u8; 32]),
&StacksBlockId([0u8; 32]),

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated in e4f0b7b.

// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.

use std::collections::HashMap;
Copy link
Contributor

Choose a reason for hiding this comment

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

A while ago we switched to using hashbrown in Clarity for performance reasons. It's a drop-in replacement with the same API. See #4389

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Switched to hashbrown in e4f0b7b.

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.

Maintain mempool caches across Stacks blocks
2 participants