-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
add shuffle(::NTuple)
to Random
#56906
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
base: master
Are you sure you want to change the base?
Conversation
7c9cbf9
to
b2eb86a
Compare
Unlike EDIT: decided to just forgo |
I'm surprised to see that your implementation allocates on the master branch, but not on v1.12, do you have an idea why that is the case? Not necessariy a problem though, it seems to be roughly the same speed. |
Co-authored-by: Rafael Fourquet <fourquet.rafael@gmail.com>
Co-authored-by: Rafael Fourquet <fourquet.rafael@gmail.com>
Co-authored-by: Rafael Fourquet <fourquet.rafael@gmail.com>
Co-authored-by: Rafael Fourquet <fourquet.rafael@gmail.com>
The PR JuliaLang#58596 was merged.
The PR #58596:
|
bump? |
# WIP PR: https://github.com/JuliaLang/julia/pull/56167 | ||
@inline let | ||
# use a narrow integer type to save stack space and prevent heap allocation | ||
Ind = if N ≤ typemax(UInt8) |
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.
for which sizes of tuples does this Ind
help? is there a cutoff?
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.
Yeah, there's a cutoff. The transformation of Memory
heap allocations to stack allocations currently only works for Memory
with small statically-known size. See PR #56847.
Fixes #56728