function test_call_parpack(NP,NM)
# Parallel calls to Arpack
Threads.@threads for k=1:NP
# Generate random matrix
A = sprand(NM,NM,0.2)
# Call Arpack
eigs(A)
end
end
results in
julia> test_call_parpack(1000,1000)
Segmentation fault (core dumped)
If I run the sequence
# Generate random matrix
A = sprand(NM,NM,0.2)
# Call Arpack
eigs(A)
by hand many times, everything works fine. I suspect there must be some constraint on using external libraries in parallel, but all the variables are local to the loop and Julia just have to call multiple instances of it. Is it expected?
Hi.
The following example
results in
by hand many times, everything works fine. I suspect there must be some constraint on using external libraries in parallel, but all the variables are local to the loop and Julia just have to call multiple instances of it. Is it expected?
Julia 1.3 here Thanks for your assistance.