Gallium.jl
Gallium.jl copied to clipboard
Julia exits when hitting breakpoint
When running Gallium in Windows with Julia 0.5.0, hitting a breakpoint causes Julia to exit (crash).
julia> using Gallium
julia> foo(x) = x+1
foo (generic function with 1 method)
julia> Gallium.breakpoint(foo)
Locations (+: active, -: inactive, *: source):
* Any matching method added to #foo
* Any matching specialization of foo(x) at REPL[2]:1
julia> foo(1)
$
Does this happen with all functions, or just small functions like this one?
Also versioninfo(), what version of windows, etc. since I can't reproduce this locally.
I can't reproduce this either on my windows machine.
I'm on Windows 7, pretty up-to-date with patches. Here's versioninfo:
julia> versioninfo()
Julia Version 0.5.0
Commit 3c9d753* (2016-09-19 18:14 UTC)
Platform Info:
System: NT (x86_64-w64-mingw32)
CPU: Intel(R) Core(TM) i7 CPU 870 @ 2.93GHz
WORD_SIZE: 64
BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Nehalem)
LAPACK: libopenblas64_
LIBM: libopenlibm
LLVM: libLLVM-3.7.1 (ORCJIT, nehalem)
It happens on larger functions as well. I was able to produce it on a 23 line function.
In some other cases, (setting it on a Base function like println, for instance) I get a crash.
julia> Gallium.breakpoint(println)
Locations (+: active, -: inactive, *: source):
+ println(io::Base.AbstractIOBuffer{Array{UInt8,1}}) at coreio.jl:6
+ println(io::IOContext{Base.AbstractIOBuffer{Array{UInt8,1}}}) at coreio.jl:6
+ println(io::Base.Terminals.TTYTerminal) at coreio.jl:6
+ println(io::Base.TTY) at coreio.jl:6
+ println(io::Base.AbstractIOBuffer{Array{UInt8,1}}, xs::Tuple{String,Vararg{String,N}}) at strings/io.jl:27
+ println(io::IOContext{Base.AbstractIOBuffer{Array{UInt8,1}}}, xs::Tuple{String,Vararg{String,N}}) at strings/io.jl:27
+ println(io::Base.AbstractIOBuffer{Array{UInt8,1}}, xs::Tuple{String,Vararg{Any,N}}) at strings/io.jl:27
+ println(io::Base.AbstractIOBuffer{Array{UInt8,1}}, xs::Tuple{SubString{String},Vararg{SubString{String},N}}) at strings/io.jl:27
+ println(io::Base.Terminals.TTYTerminal, xs::Tuple{String,Vararg{String,N}}) at strings/io.jl:27
+ println(xs::Tuple{}) at coreio.jl:5
+ println(xs::Tuple{String}) at coreio.jl:5
* Any matching method added to Base.#println
* Any matching specialization of println(t) at C:\Users\s2maki\.julia\v0.5\TerminalUI\src\widgets.jl:822
* Any matching specialization of println(io) at coreio.jl:6
* Any matching specialization of println(io, xs) at strings/io.jl:27
* Any matching specialization of println(xs) at coreio.jl:5
julia> println("test")
Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks.
Exception: EXCEPTION_ILLEGAL_INSTRUCTION at 0x6a5416ea -- hooking_jl_savecontext at C:\Users\s2maki\.julia\v0.5\Gallium\src\Hooking\hooking.DLL (unknown line)
while loading no file, in expression starting on line 0
hooking_jl_savecontext at C:\Users\s2maki\.julia\v0.5\Gallium\src\Hooking\hooking.DLL (unknown line) jl_call_method_internal at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\julia_internal.h:189 [inlined]
jl_apply_generic at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\gf.c:1942
commit_line at .\LineEdit.jl:1300
#92 at .\LineEdit.jl:1352
#13 at .\LineEdit.jl:736
jl_call_method_internal at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\julia_internal.h:189 [inlined]
jl_apply_generic at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\gf.c:1942
#165 at .\LineEdit.jl:1458
#13 at .\LineEdit.jl:736
jl_call_method_internal at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\julia_internal.h:189 [inlined]
jl_apply_generic at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\gf.c:1942
prompt! at .\LineEdit.jl:1605
run_interface at .\LineEdit.jl:1574
unknown function (ip: 00000000034AC105)
jl_call_method_internal at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\julia_internal.h:189 [inlined]
jl_apply_generic at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\gf.c:1942
run_frontend at .\REPL.jl:903
run_repl at .\REPL.jl:188
unknown function (ip: 000000001A2703B6)
jl_call_method_internal at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\julia_internal.h:189 [inlined]
jl_apply_generic at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\gf.c:1942
_start at .\client.jl:360
unknown function (ip: 00000000034C85EE)
jl_call_method_internal at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\julia_internal.h:189 [inlined]
jl_apply_generic at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src/cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/src\gf.c:1942
jl_apply at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/ui/../src\julia.h:1392 [inlined]
true_main at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/ui\repl.c:112
wmain at /cygdrive/c/BuildAgent/work/f9dddb33ef3dffec/ui\repl.c:232
__tmainCRTStartup at /usr/src/debug/mingw64-x86_64-runtime-4.0.5-1/crt\crtexe.c:329
mainCRTStartup at /usr/src/debug/mingw64-x86_64-runtime-4.0.5-1/crt\crtexe.c:212
BaseThreadInitThunk at C:\Windows\system32\kernel32.dll (unknown line)
RtlUserThreadStart at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
Allocations: 5325643 (Pool: 5324366; Big: 1277); GC: 6
Keith's original example works okay for me in Linux, Windows and macOS.
Encountering a breakpoint set in println produces a segfault for me in Linux and macOS,
and an infinite loop of 4 In coreio.jl:5 on Windows.