You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think this is a bug in Base, either in the Base.FFTW (which is split into its own package in julia 0.7) or in the threading code. I realize threading is an experimental feature so I'm not really surprised it fails, but I'd be willing to make a proper bug report. @timholy could you recommend how/where I should report this?
Note that the crash won't happen unless you start julia with more than one thread using the JULIA_NUM_THREADS environmental variable.
I've only been able to test on Julia 0.6
I've also tried using FFTW.set_num_threads() to change the number of threads to 1 or to be equal to JULIA_NUM_THREADS, but neither worked.
Code:
using BlockRegistration, RegisterMismatch
a =rand(3,3,10)
fixed =rand(3,3)
Threads.@threadsfor i =1:10mismatch(fixed, a[:,:,i], (1,1))
end
Error:
signal (11): Segmentation fault
while loading /home/cody/.julia/reg_and_seg/v0.6/EmpiricalTiming/test/threading_bug.jl, in expression starting on line 6
fftwf_hash at /home/cody/src/julia_06/usr/bin/../lib/libfftw3f.so.3 (unknown line)
unknown function (ip: 0x7f71049e45dd)
fftwf_solvtab_exec at /home/cody/src/julia_06/usr/bin/../lib/libfftw3f.so.3 (unknown line)
fftwf_init_threads at /home/cody/src/julia_06/usr/bin/../lib/libfftw3f_threads.so (unknown line)
_init_ at ./fft/FFTW.jl:99
set_timelimit at ./fft/FFTW.jl:171 [inlined]
Type at ./fft/FFTW.jl:494
rplan_fwd at /home/cody/.julia/reg_and_seg/v0.6/RFFT/src/RFFT.jl:73
unknown function (ip: 0x7f71130dc95c)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
#plan_rfft!#7 at /home/cody/.julia/reg_and_seg/v0.6/RFFT/src/RFFT.jl:79
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:343 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
#plan_rfft! at ./<missing>:0
unknown function (ip: 0x7f71130dc536)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
#call#35 at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatch.jl:88
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:343 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
#CMStorage#41 at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatch.jl:98
unknown function (ip: 0x7f71130a2726)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/l_call_method_internal at /home/jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
while loading /home/cody/.julia/reg_and_seg/v0.6/EmpiricalTiming/test/threading_bug.jl, in expression starting on line 6
jl_apply at /home/cody/src/julia_06/src/julia.h:1424 [inlined]
jl_invoke at /home/cody/src/julia_06/src/gf.c:51
#mismatch#42 at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatch.jl:119
unknown function (ip: 0x7f71130a1f4a)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
#mismatch at ./<missing>:0
mismatch at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatchCommon.jl:10
unknown function (ip: 0x7f71130a151d)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
macro expansion at /home/cody/.julia/reg_and_seg/v0.6/EmpiricalTiming/test/threading_bug.jl:7 [inlined]
#15#threadsfor_fun at 0x7f71050080f8)
ucts.jl:63
#15#threadsfor_fun at 0x7f71050080f8)
#15#threadsfor_fun at ./threadingconstructs.jl:30
unknown function (ip: 0x7f71130a000f)
unknown function (ip: 0x7f71050084e0)
fftw_mkapiplan at /home/cody/src/julia_06/usr/bin/../lib/libfftw3.so.3 (unknown linefftw_mkapiplan at /home/cody/src/julia_06/usr/bin/../lib/libfftw3.so.3 (unknown line)
ti_run_fun at /home/cody/src/julia_06/src/threading.c:318
fftw_plan_guru64_dft_r2c at /home/cody/src/julia_06/usr/bin/../lib/libfftw3.so.3 (unknown line)
Type at ./fft/FFTW.jl:496
jl_threading_run at : 0x7f71130dd3ejuljl_threading_run at /home/cody/src/julia_06/src/threading.c:720
macro expansion at ./threadingconstructs.jl:73 [inlined]
anonymous at ./<missing> (unknown line)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_toplevel_eval_flex at /home/cody/src/julia_06/src/toplevel.c:589
#plan_rfft!#7 at /home/cody/.julia/reg_and_seg/v0.6/RFFT/src/RFFT.jl:79
jl_parse_eval_all at /0x7f71130dc8f7)
jl_parse_eval_all at /0x7f71130dc8f7)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
jl_load at /home/cody/src/julia_06/src/toplevel.c:616
#plan_rfft! at ./<missing>:0
unknown function (ip: 0x7f71130dc536)
include_from_node1 at ./loading.jl:576
jl_call_fptr_internal 0x7/home/cobe2)
jl_call_fptr_internal 0x7/home/cobe2)
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
#call#35 at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatch.jl:88
jl_call_fptr_internal 0x7f71130ada03)
jl_call_fptr_internal 0x7f71130ada03)
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
include at ./sysimg.jl:14
#CMStorage#41 at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatch.jl:98
unknown function (ip: 0x7f71130a2726)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
unknown function (ip: 0x7f714a3f49db)
jl_apply at /home/cody/src/julia_06/src/julia.h:1424 [inlined]
jl_invoke at /home/cody/src/julia_06/src/gf.c:51
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
l_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
#mismatch#42 at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatch.jl:119
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
unknown function (ip: 0x7f71130a1f4a)
do_call at /home/cody/src/julia_06/src/interpreter.c:75
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
eval at /home/cody/src/julia_06/src/interpreter.c:242
#mismatch at ./<missing>:0
mismatch at /home/cody/.julia/reg_and_seg/v0.6/BlockRegistration/src/RegisterMismatchCommon.jl:10
jl_interpret_toplevel_expr at /home/cojl_interpret_toplevel_expr at /home/cody/src/julia_06/src/interpreter.c:34
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
jl_toplevel_eval_flex at /home/cody/src/julia_06/src/toplevel.c:577
macro expansion at /home/cody/.julia/reg_and_seg/v0.6/EmpiricalTiming/test/threading_bug.jl:7 [inlined]
#15#threadsfor_fun at ./threadingconstructs.jl:63
#15#threadsfor_fun at ./threadingconstructs.jl:30
jl_toplevel_eval_in at x7f71130a000rc/jl_toplevel_eval_in at /home/cody/src/julia_06/src/builtins.c:496
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
ti_run_fun at /home/cody/src/julia_06/src/threading.c:318
ti_threadfun at /home/cody/src/julia_06/src/threading.c:429
uv__thread_start at /home/cody/src/julia_06/deps/srccache/libuv-d8ab1c6a33e77bf155facb54215dd8798e13825d/src/unix/thread.c:53
eval at ./boot.jl:235
unknown function (ip: 0x7f714a51d61f)
unknown function (ip: 0x7f714fcf37fb)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
eval_user_input at ./REPL.jl:66
unknown function (ip: 0x7f714a5a10ef)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
macro expansion at ./REPL.jl:97 [inlined]
#1 at ./event.jl:73
unknown function (ip: 0x7f711304473f)
jl_call_fptr_internal at /home/cody/src/julia_06/src/julia_internal.h:339 [inlined]
jl_call_method_internal at /home/cody/src/julia_06/src/julia_internal.h:358 [inlined]
jl_apply_generic at /home/cody/src/julia_06/src/gf.c:1926
jl_apply at /home/cody/src/julia_06/src/julia.h:1424 [inlined]
start_task at /home/cody/src/julia_06/src/task.c:267
unknown function (ip: 0xffffffffffffffff)
Allocations: 14882784 (Pool: 14880530; Big: 2254); GC: 29
Segmentation fault (core dumped)
The text was updated successfully, but these errors were encountered:
I think this is a bug in Base, either in the Base.FFTW (which is split into its own package in julia 0.7) or in the threading code. I realize threading is an experimental feature so I'm not really surprised it fails, but I'd be willing to make a proper bug report. @timholy could you recommend how/where I should report this?
Note that the crash won't happen unless you start julia with more than one thread using the
JULIA_NUM_THREADS
environmental variable.I've only been able to test on Julia 0.6
I've also tried using
FFTW.set_num_threads()
to change the number of threads to 1 or to be equal to JULIA_NUM_THREADS, but neither worked.Code:
Error:
The text was updated successfully, but these errors were encountered: