-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
gh-128150: improve performances of uuid.uuid*
constructor functions.
#128151
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
30 commits
Select commit
Hold shift + click to select a range
0d49ccb
improve performance of UUIDs creation
picnixz 603335f
add What's New entry
picnixz 154ff8b
blurb
picnixz b965887
fix issue number
picnixz a8a1894
fix typos
picnixz c8aa752
ensure 14-bit clock sequence
picnixz 8c9d5cf
Merge branch 'main' into perf/uuid/init-128150
picnixz a2278b8
add dedicated private fast constructor
picnixz 0710549
revert UUIDv1 construction
picnixz 5b6922f
change eager check into an assertion check for internal constructor
picnixz e631593
update performance results
picnixz 1c10901
describe constants
picnixz 0bc7321
revert UUIDv1 optimizations to reduce the diff
picnixz 26b1eb1
simplify `_from_int` private constructor as per Pieter's review
picnixz df50a7a
revert micro-optimization of `not a <= x <= b`
picnixz c1ffa7d
use built-in `int` when it is not shadowed
picnixz cff86e9
remove rationale comment for HACL* MD5
picnixz 7095aa4
remove rationale comment for OpenSSL SHA-1
picnixz 4af1535
clear variant and version bits using dedicated mask
picnixz 0d4c008
fix typos
picnixz 9854f69
update benchmarks
picnixz 897902b
remove un-necessary assertions
picnixz a8a19e1
use `object.__new__` instead of `cls.__new__`
picnixz ccb972b
Merge branch 'main' into perf/uuid/init-128150
picnixz e2b8b08
remove dedicated constant folding
picnixz 1d4216a
update benchmarks
picnixz 5c87adf
Always use `hashlib.md5` for consistency as per Petr's comment.
picnixz ea23629
update benchmarks
picnixz 6d89e9d
Merge branch 'main' into perf/uuid/init-128150
picnixz bdf7c6e
update NEWS
picnixz 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
2 changes: 2 additions & 0 deletions
2
Misc/NEWS.d/next/Library/2024-12-21-11-12-50.gh-issue-128151.aq7vpG.rst
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Improve generation of :class:`~uuid.UUID` objects version 3, 4, 5, and 8 | ||
via their dedicated functions by 30%. Patch by Bénédikt Tran. |
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.
Uh oh!
There was an error while loading. Please reload this page.