-
-
Notifications
You must be signed in to change notification settings - Fork 214
perf: copy-on-write for sentry_value_t clone #1794
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
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
b1bdf5a
fix: clone user and fingerprint in scope_apply_to_event
jpnurmi ec8e399
ref: copy-on-write for sentry_value_t clone
jpnurmi d4f7f46
fix(value): Fix nested clone failure in thing_clone_children
jpnurmi 9e9c260
fix: Handle object detach key clone failures
jpnurmi 837e73d
Update CHANGELOG.md
jpnurmi 70d6ce6
clean up memset(0)'s
jpnurmi 9403a34
extract list/obj_clone helpers for better readability
jpnurmi eac1999
Merge branch 'master' into jpnurmi/ref/copy-on-write
jpnurmi ae5cee6
Merge remote-tracking branch 'origin/master' into jpnurmi/ref/copy-on…
jpnurmi bc33cd8
Merge remote-tracking branch 'origin/master' into jpnurmi/ref/copy-on…
jpnurmi 5a7bc81
Update CHANGELOG.md
jpnurmi c2427f5
Merge remote-tracking branch 'origin/master' into jpnurmi/ref/copy-on…
jpnurmi File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
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.
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.
Potentially: Since keys are immutable, we could store them with a refcount and, instead of a copy here, increase the key's refcount. That would reduce allocations on mutate, especially in deep/wide objects where a single set_by_key could trigger N string copies. Just an idea to consider.
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.
Thanks for the proposal. 👍 Sounds like worth experimenting! Replacing plain C string keys with
thing_tstrings could achieve this at the cost of one additional allocation per 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.
Worth as an experiment, but I wouldn't treat it as a blocker. It's great already!