We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
for reference, see this discourse thread: https://discourse.julialang.org/t/perf-improvement-suggestion-for-simple-extrema/34776/2 the key is just writing a simple loop in the case of extrema(x::AbstractArray). the post uses an standard indexing, but i think this can be changed?
extrema(x::AbstractArray)
The text was updated successfully, but these errors were encountered:
a prototype
function extrema(x::AbstractArray) a = b = first(x) @inbounds @simd for i in eachindex(x) if x[i] > b b = x[i] elseif x[i] < a a = x[i] end end a, b end
Sorry, something went wrong.
Isn't it more or less a dup of #31442?
not technically, but it seems so
extrema
No branches or pull requests
for reference, see this discourse thread:
https://discourse.julialang.org/t/perf-improvement-suggestion-for-simple-extrema/34776/2
the key is just writing a simple loop in the case of
extrema(x::AbstractArray)
. the post uses an standard indexing, but i think this can be changed?The text was updated successfully, but these errors were encountered: