Skip to content

Commit b522f6e

Browse files
committed
Better threshold
1 parent 88227c3 commit b522f6e

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/lu.jl

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,14 @@ end
1818

1919
# Use a function here to make sure it gets optimized away
2020
# AVX512 needs a smaller recursion limit
21-
pick_threshold() = LoopVectorization.VectorizationBase.AVX512F ? 48 : 192
21+
function pick_threshold()
22+
blasvendor = BLAS.vendor()
23+
if blasvendor === :openblas || blasvendor === :openblas64
24+
LoopVectorization.VectorizationBase.AVX512F ? 110 : 192
25+
else
26+
LoopVectorization.VectorizationBase.AVX512F ? 48 : 72
27+
end
28+
end
2229

2330
function lu!(A::AbstractMatrix{T}, ipiv::AbstractVector{<:Integer},
2431
pivot::Union{Val{false}, Val{true}} = Val(true);

0 commit comments

Comments
 (0)