-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Optimized the work of InMemoryTransaction
for lookups and empty insertion
#1974
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xgreenx
commented
Jun 15, 2024
Comment on lines
310
to
+312
self.changes | ||
.get(&column.id()) | ||
.and_then(|btree| btree.get(&k)) | ||
.and_then(|btree| btree.get(key)) |
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.
Comment on lines
+269
to
+272
hash_map::Entry::Vacant(vacant) => { | ||
vacant.insert(value); | ||
continue | ||
} |
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.
If BTreeMap
is not exist, we just set it to be value
because it can't have any conflicts=)
Voxelot
approved these changes
Jun 16, 2024
Merged
xgreenx
added a commit
that referenced
this pull request
Jun 16, 2024
## Version v0.30.0 ### Added - [#1975](#1975): Added `DependentCost` benchmarks for the `cfe` and `cfei` opcodes. - [#1975](#1975): Added `DependentCost` for the `cfe` opcode to the `GasCosts` endpoint. - [#1974](#1974): Optimized the work of `InMemoryTransaction` for lookups and empty insertion. ### Changed - [#1973](#1973): Updated VM initialization benchmark to include many inputs and outputs. #### Breaking - [#1975](#1975): Updated gas prices according to new release. - [#1975](#1975): Changed `GasCosts` endpoint to return `DependentCost` for the `cfei` opcode via `cfeiDependentCost`. - [#1975](#1975): Use `fuel-vm 0.54.0`. More information in the [release](https://github.com/FuelLabs/fuel-vm/releases/tag/v0.54.0). ## What's Changed * Add `creation_instant` as second sort key in tx pool. by @AurelienFT in #1964 * Updated VM initialization benchmark to include many inputs and outputs by @xgreenx in #1973 * Fixes the error message for incorrect keypair's path by @xgreenx in #1962 * Optimized the work of `InMemoryTransaction` for lookups and empty insertion by @xgreenx in #1974 * Weekly `cargo update` by @github-actions in #1976 * Use `fuel-vm 0.54.0` by @xgreenx in #1975 **Full Changelog**: v0.29.0...v0.30.0
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Just was walking around this code and noticed that we can remove not needed
to_vec
and improve the case when we commit changes into emptyInMemoryTransaction
.Before requesting review