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

mining: Remove unnecessary tx copy. #2792

Merged
merged 1 commit into from Nov 15, 2021
Merged

Conversation

rstaudt2
Copy link
Member

This removes an unnecessary transaction copy in the mining code. It is not needed since all of the regular transactions have already been copied prior to this point. Specifically, all regular transactions in the block are already copied here in the loop that proceeds the code modified in this PR.

This removes an unnecessary transaction copy in the mining code.  It is
not needed since all of the regular transactions have already been
copied prior to this point.
Copy link
Member

@davecgh davecgh left a comment

Choose a reason for hiding this comment

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

Nice. This will save a bunch of allocs when mining templates are enabled.

@davecgh davecgh added this to the 1.7.0 milestone Nov 10, 2021
@davecgh davecgh merged commit ab887c0 into decred:master Nov 15, 2021
@rstaudt2 rstaudt2 deleted the mining-tx-copy branch November 22, 2021 21:16
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.

None yet

3 participants