Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions src/LinearSolve.jl
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,19 @@ import PrecompileTools
using ArrayInterface: ArrayInterface
# Explicit names, not the module: LinearSolve defines its own `LHLFactorization` (the
# algorithm object) and `using LHLFactorization` would shadow it.
using LHLFactorization: LHLWorkspace, lhl_reduce!, lhl_shift!, lhl_ldiv!, lhl_refine!,
lhl_ldivH!, lhl_refineH!, lhl, lhl!, lhl_isreduced
module LHLFactorizationBindings
using LHLFactorization: LHLWorkspace, lhl_reduce!, lhl_shift!, lhl_ldiv!, lhl_refine!,
lhl_ldivH!, lhl_refineH!, lhl, lhl!, lhl_isreduced
const bindings = (
LHLWorkspace, lhl_reduce!, lhl_shift!, lhl_ldiv!, lhl_refine!,
lhl_ldivH!, lhl_refineH!, lhl, lhl!, lhl_isreduced,
)
end
const (
LHLWorkspace, lhl_reduce!, lhl_shift!, lhl_ldiv!, lhl_refine!, lhl_ldivH!,
lhl_refineH!, lhl, lhl!, lhl_isreduced,
) =
LHLFactorizationBindings.bindings
using Base: Bool, convert, copyto!, adjoint, transpose, /, \, require_one_based_indexing
using LinearAlgebra: LinearAlgebra, BlasInt, LU, Adjoint, BLAS, Bidiagonal, BunchKaufman,
ColumnNorm, cond, Diagonal, Factorization, Hermitian, I, LAPACK, NoPivot,
Expand Down
2 changes: 1 addition & 1 deletion src/blocked_lufact.jl
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ function _blocked_generic_lufact!(
ipiv::AbstractVector{<:Integer}, pack::Union{Nothing, Vector{T}};
check::Bool = true, allowsingular::Bool = false
) where {T <: Union{Float32, Float64}}
Base.require_one_based_indexing(A, ipiv)
require_one_based_indexing(A, ipiv)
if check && !all(isfinite, A)
throw(ArgumentError("matrix contains Infs or NaNs"))
end
Expand Down
2 changes: 2 additions & 0 deletions src/lhl.jl
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,10 @@ not-yet-reduced state widens it.
mutable struct LHLCache{WS, JT}
ws::WS
jac::Union{Nothing, JT}
LHLCache{WS, JT}(ws, jac) where {WS, JT} = new{WS, JT}(ws, jac)
end

LHLCache(ws::WS, jac::JT) where {WS, JT} = LHLCache{WS, JT}(ws, jac)
LHLCache(ws, ::Type{JT}) where {JT} = LHLCache{typeof(ws), JT}(ws, nothing)

function init_cacheval(
Expand Down
Loading