That was actually not the root cause of the problem. I refactored my 
library significantly and made and now the segfault is randomly triggered 
at different points in the test suite on *0.5*. This is the backtrace I get 
on a debug build of Julia:

signal (11): Segmentation fault: 11
while loading /Users/helge/.julia/v0.5/Dopri/test/lowlevel.jl, in 
expression starting on line 42
jl_object_id_ at /Users/helge/projects/julia/src/builtins.c:1023
jl_object_id at /Users/helge/projects/julia/src/builtins.c:1060
hash_svec at /Users/helge/projects/julia/src/builtins.c:1003
jl_object_id_ at /Users/helge/projects/julia/src/builtins.c:1025
jl_object_id at /Users/helge/projects/julia/src/builtins.c:1060
typekey_compare at /Users/helge/projects/julia/src/jltypes.c:1894
lookup_type_idx at /Users/helge/projects/julia/src/jltypes.c:1931
lookup_type at /Users/helge/projects/julia/src/jltypes.c:1959
inst_datatype at /Users/helge/projects/julia/src/jltypes.c:2118
jl_inst_concrete_tupletype_v at 
/Users/helge/projects/julia/src/jltypes.c:2278
arg_type_tuple at /Users/helge/projects/julia/src/gf.c:997
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1570
is_allocation at ./inference.jl:3245
unknown function (ip: 0x10bce7ae0)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
alloc_elim_pass! at ./inference.jl:3315
finish at ./inference.jl:1918
typeinf_frame at ./inference.jl:1823
typeinf_loop at ./inference.jl:1570
unknown function (ip: 0x10bccf906)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_edge at ./inference.jl:1522
unknown function (ip: 0x10bcdcfbc)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_edge at ./inference.jl:1527
unknown function (ip: 0x10bcdb038)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_call_gf_by_type at ./inference.jl:852
unknown function (ip: 0x10bcda534)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_call at ./inference.jl:1023
unknown function (ip: 0x10bcd5bcc)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_eval_call at ./inference.jl:1053
abstract_eval at ./inference.jl:1076
unknown function (ip: 0x10bcd31a4)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_eval_call at ./inference.jl:1027
abstract_eval at ./inference.jl:1076
unknown function (ip: 0x10bcd31a4)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_interpret at ./inference.jl:1201
unknown function (ip: 0x10bcd0314)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_frame at ./inference.jl:1645
typeinf_loop at ./inference.jl:1570
unknown function (ip: 0x10bccf906)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_edge at ./inference.jl:1522
unknown function (ip: 0x10bcdcfbc)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_edge at ./inference.jl:1527
unknown function (ip: 0x10bcdb038)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_call_gf_by_type at ./inference.jl:852
unknown function (ip: 0x10bcda534)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_call at ./inference.jl:1023
unknown function (ip: 0x10bcd5bcc)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
abstract_eval_call at ./inference.jl:1053
abstract_eval at ./inference.jl:1076
unknown function (ip: 0x10bcd31a4)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_frame at ./inference.jl:1722
typeinf_loop at ./inference.jl:1588
unknown function (ip: 0x10bccf906)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_edge at ./inference.jl:1522
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
typeinf_ext at ./inference.jl:1542
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
jl_apply at /Users/helge/projects/julia/src/./julia.h:1386
jl_type_infer at /Users/helge/projects/julia/src/gf.c:219
cache_method at /Users/helge/projects/julia/src/gf.c:678
jl_mt_assoc_by_type at /Users/helge/projects/julia/src/gf.c:711
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1574
do_test at /Users/helge/.julia/v0.5/BaseTestNext/src/BaseTestNext.jl:181
unknown function (ip: 0x3199d05ad)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1585
macro expansion; at /Users/helge/.julia/v0.5/Dopri/test/lowlevel.jl:104
unknown function (ip: 0x3199bfc31)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_toplevel_eval_flex at /Users/helge/projects/julia/src/toplevel.c:556
jl_parse_eval_all at /Users/helge/projects/julia/src/ast.c:780
jl_load at /Users/helge/projects/julia/src/toplevel.c:585
jl_load_ at /Users/helge/projects/julia/src/toplevel.c:591
include_from_node1 at ./loading.jl:426
unknown function (ip: 0x10bebc07c)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
do_call at /Users/helge/projects/julia/src/interpreter.c:58
eval at /Users/helge/projects/julia/src/interpreter.c:174
jl_interpret_toplevel_expr at 
/Users/helge/projects/julia/src/interpreter.c:25
jl_toplevel_eval_flex at /Users/helge/projects/julia/src/toplevel.c:545
jl_parse_eval_all at /Users/helge/projects/julia/src/ast.c:780
jl_load at /Users/helge/projects/julia/src/toplevel.c:585
jl_load_ at /Users/helge/projects/julia/src/toplevel.c:591
include_from_node1 at ./loading.jl:426
unknown function (ip: 0x10bebc07c)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
process_options at ./client.jl:266
_start at ./client.jl:322
unknown function (ip: 0x10bf138f4)
jl_call_method_internal at 
/Users/helge/projects/julia/src/./julia_internal.h:88
jl_apply_generic at /Users/helge/projects/julia/src/gf.c:1595
jl_apply at /Users/helge/projects/julia/usr/bin/julia-debug (unknown line)
true_main at /Users/helge/projects/julia/usr/bin/julia-debug (unknown line)
main at /Users/helge/projects/julia/usr/bin/julia-debug (unknown line)
Allocations: 2928538 (Pool: 2927071; Big: 1467); GC: 6

I have run the test suite 100x on a different Mac and on Linux without any 
problems. Could this be a hardware issue?

Am Montag, 30. Mai 2016 18:57:55 UTC+2 schrieb Helge Eichhorn:
>
> Thanks for testing, Rob!
>
> It was pre-compilation problem. I switched on pre-compilation for a 
> package that depends on Dopri.jl which itself does not use pre-compilation. 
> My bad...
>
> Am Montag, 30. Mai 2016 18:25:29 UTC+2 schrieb Rob J Goedman:
>>
>> Helge,
>>
>> Not sure if this helps, but below the (successful) output on my machine. 
>> I’m on OS X 11.6-beta, but I don’t think that is important. I do remember 
>> installing an updated Xcode.
>>
>> Regards,
>> Rob
>>
>> On May 30, 2016, at 08:41, Helge Eichhorn <[email protected]> wrote:
>>
>>
>>
>> Hi!
>>
>> I am having a strange problem with a segfault that seemingly appeared out 
>> of nowhere while calling Fortran code on OSX.
>>
>> When I try to run the tests of my Dopri.jl 
>> <https://github.com/helgee/Dopri.jl> package on Julia 0.4.5 on OSX 
>> 10.11.5 the process consistently fails with this error message:
>> signal (11): Segmentation fault: 11
>> unknown function (ip: 0x0)
>>
>> Tests pass on master and 0.3.12. Could somebody try to reproduce this 
>> behavior on their machine? What puzzles me is that this did not happen 23 
>> days ago when I fixed the lastest issue with the package. In the meantime I 
>> did not change anything about neither the code nor the Julia runtime. I did 
>> install an OS update, though.
>>
>> Any ideas?
>>
>> The only other data point I have is that the tests also segfault on 0.3 
>> on Travis but not consistently. On the third to fourth re-run the build 
>> usually succeeds. I have attached the log.
>>
>> Cheers,
>> Helge
>> <travis.log>
>>
>>
>>
>> *julia> **Pkg.add("Dopri")*
>> *INFO: No packages to install, update or remove*
>> *INFO: Package database updated*
>>
>> *julia> **using Dopri*
>>
>> *julia> **Pkg.test("Dopri")*
>> *INFO: Testing Dopri*
>> *ERROR: LoadError: could not spawn 
>> setenv(`/Users/rob/.julia/v0.4/Dopri/deps/testrunner`,Union{ASCIIString,UTF8String}["LD_LIBRARY_PATH=/Users/rob/.julia/v0.4/Dopri/deps"]):
>>  
>> no such file or directory (ENOENT)*
>> * in _jl_spawn at process.jl:262*
>> * in anonymous at process.jl:415*
>> * in setup_stdio at process.jl:403*
>> * in spawn at process.jl:414*
>> * in open at process.jl:478*
>> * in open at process.jl:492*
>> * in include at 
>> /Applications/Julia-0.4.5.app/Contents/Resources/julia/lib/julia/sys.dylib*
>> * in include_from_node1 at 
>> /Applications/Julia-0.4.5.app/Contents/Resources/julia/lib/julia/sys.dylib*
>> * in process_options at 
>> /Applications/Julia-0.4.5.app/Contents/Resources/julia/lib/julia/sys.dylib*
>> * in _start at 
>> /Applications/Julia-0.4.5.app/Contents/Resources/julia/lib/julia/sys.dylib*
>> *while loading /Users/rob/.julia/v0.4/Dopri/test/runtests.jl, in 
>> expression starting on line 9*
>> *=======================================================[ ERROR: Dopri 
>> ]=======================================================*
>>
>> *failed process: 
>> Process(`/Applications/Julia-0.4.5.app/Contents/Resources/julia/bin/julia 
>> --check-bounds=yes --code-coverage=none --color=yes 
>> /Users/rob/.julia/v0.4/Dopri/test/runtests.jl`, ProcessExited(1)) [1]*
>>
>>
>> *==============================================================================================================================*
>> *ERROR: Dopri had test errors*
>> * in error at 
>> /Applications/Julia-0.4.5.app/Contents/Resources/julia/lib/julia/sys.dylib*
>> * in test at pkg/entry.jl:803*
>> * in anonymous at pkg/dir.jl:31*
>> * in cd at file.jl:22*
>> * in cd at pkg/dir.jl:31*
>> * in test at pkg.jl:71*
>>
>> *julia> **Pkg.build("Dopri")*
>> *INFO: Building Dopri*
>>
>> *julia> **Pkg.test("Dopri")*
>> *INFO: Testing Dopri*
>> *INFO: Dopri tests passed*
>>
>> *julia> **versioninfo()*
>> Julia Version 0.4.5
>> Commit 2ac304d (2016-03-18 00:58 UTC)
>> Platform Info:
>>   System: Darwin (x86_64-apple-darwin13.4.0)
>>   CPU: Intel(R) Core(TM) i7-4980HQ CPU @ 2.80GHz
>>   WORD_SIZE: 64
>>   BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
>>   LAPACK: libopenblas64_
>>   LIBM: libopenlibm
>>   LLVM: libLLVM-3.3
>>
>> *shell> **gfortran -v*
>> Using built-in specs.
>> COLLECT_GCC=gfortran
>>
>> COLLECT_LTO_WRAPPER=/usr/local/Cellar/gcc/5.3.0/libexec/gcc/x86_64-apple-darwin15.0.0/5.3.0/lto-wrapper
>> Target: x86_64-apple-darwin15.0.0
>> Configured with: ../configure --build=x86_64-apple-darwin15.0.0 
>> --prefix=/usr/local/Cellar/gcc/5.3.0 
>> --libdir=/usr/local/Cellar/gcc/5.3.0/lib/gcc/5 
>> --enable-languages=c,c++,objc,obj-c++,fortran --program-suffix=-5 
>> --with-gmp=/usr/local/opt/gmp --with-mpfr=/usr/local/opt/mpfr 
>> --with-mpc=/usr/local/opt/libmpc --with-isl=/usr/local/opt/isl 
>> --with-system-zlib --enable-libstdcxx-time=yes --enable-stage1-checking 
>> --enable-checking=release --enable-lto --with-build-config=bootstrap-debug 
>> --disable-werror --with-pkgversion='Homebrew gcc 5.3.0' --with-bugurl=
>> https://github.com/Homebrew/homebrew/issues --enable-plugin 
>> --disable-nls --enable-multilib
>> Thread model: posix
>> gcc version 5.3.0 (Homebrew gcc 5.3.0) 
>>
>>

Reply via email to