[SciPy-dev] Scipy 0.4.8 segfaults on 64bit Linux (Ubuntu).

Arnd Baecker arnd.baecker at web.de
Tue Mar 21 07:08:09 CST 2006


On Tue, 21 Mar 2006, Travis Oliphant wrote:

> Arnd Baecker wrote:
> > [...]
> >
>
> Try the test again with new SVN.

I fixed the header files (hope I got it right - please check)
and now the compile works fine, but still a segfault on test:

[...]
brute force distance transform 4 ... ERROR
brute force distance transform 5 ... ok
brute force distance transform 6 ... ok
chamfer type distance transform 1 ... ok
chamfer type distance transform 2 ... ok
chamfer type distance transform 3 ... ERROR
euclidean distance transform 1 ... ok
euclidean distance transform 2 ... ERROR
[...]
grey erosion 3 ... ok
grey opening 1 ... ok
grey opening 2 ... ok
histogram 1Segmentation fault

The backtrace gives

grey opening 2 ... ok
histogram 1
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 46912507335168 (LWP 22377)]
NI_Histogram (input=0x96bfc0, labels=0x0, min_label=-1,
max_label=46912557167512, indices=0x0, n_results=1, histograms=0x935430,
    min=0, max=10, nbins=46909632806922) at ni_measure.c:752
752           ph[jj][kk] = 0;

(gdb) print jj
$1 = 0
(gdb) print kk
$2 = 32612
(gdb) print ph
$3 = (Int32 **) 0x9313a0


(gdb) bt
#0  NI_Histogram (input=0x96bfc0, labels=0x0, min_label=-1,
max_label=46912557167512, indices=0x0, n_results=1,
    histograms=0x935430, min=0, max=10, nbins=46909632806922) at
ni_measure.c:752
#1  0x00002aaaae50ef81 in Py_Histogram (obj=0x96c050, args=0x96c050) at
nd_image.c:1103
#2  0x0000000000478cfb in PyEval_EvalFrame (f=0x717f30) at ceval.c:3558
#3  0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaae4e9c70,
globals=0x8d6080, locals=0x7f3c, args=0x717f30, argcount=4,
    kws=0x6d60e8, kwcount=0, defs=0x2aaaae4d2da0, defcount=2, closure=0x0)
at ceval.c:2736
#4  0x00000000004788f7 in PyEval_EvalFrame (f=0x6d5f10) at ceval.c:3650
#5  0x0000000000479fb1 in PyEval_EvalFrame (f=0x89aae0) at ceval.c:3640
#6  0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaab948ea0,
globals=0x8d6080, locals=0x7f3c, args=0x89aae0, argcount=2,
    kws=0x96cf90, kwcount=0, defs=0x2aaaab94ff68, defcount=1, closure=0x0)
at ceval.c:2736
#7  0x00000000004c6099 in function_call (func=0x2aaaab95f7d0,
arg=0x2aaaae4fae60, kw=0x956920) at funcobject.c:548
#8  0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#9  0x00000000004772ea in PyEval_EvalFrame (f=0x7397d0) at ceval.c:3835
#10 0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaab948f10,
globals=0x8d6080, locals=0x7f3c, args=0x7397d0, argcount=2,
    kws=0x0, kwcount=0, defs=0x0, defcount=0, closure=0x0) at ceval.c:2736
#11 0x00000000004c6099 in function_call (func=0x2aaaab95f848,
arg=0x2aaaae4fae18, kw=0x0) at funcobject.c:548
#12 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#13 0x0000000000420ee0 in instancemethod_call (func=0x96c050,
arg=0x2aaaae4fae18, kw=0x0) at classobject.c:2447
#14 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#15 0x00000000004777d9 in PyEval_EvalFrame (f=0x7306c0) at ceval.c:3766
#16 0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaab93b490,
globals=0x8d6080, locals=0x7f3c, args=0x7306c0, argcount=2,
    kws=0x0, kwcount=0, defs=0x2aaaab960a28, defcount=1, closure=0x0) at
ceval.c:2736
#17 0x00000000004c6099 in function_call (func=0x2aaaab962d70,
arg=0x2aaaae4fadd0, kw=0x0) at funcobject.c:548
#18 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#19 0x0000000000420ee0 in instancemethod_call (func=0x96c050,
arg=0x2aaaae4fadd0, kw=0x0) at classobject.c:2447
#20 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#21 0x000000000044fd80 in slot_tp_call (self=0x2aaaae6b3b90,
args=0x2aaaae6b6690, kwds=0x0) at typeobject.c:4536
#22 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#23 0x00000000004777d9 in PyEval_EvalFrame (f=0x7acdd0) at ceval.c:3766
#24 0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaab94c960,
globals=0x8d6080, locals=0x7f3c, args=0x7acdd0, argcount=2,
    kws=0x925160, kwcount=0, defs=0x0, defcount=0, closure=0x0) at
ceval.c:2736
#25 0x00000000004c6099 in function_call (func=0x2aaaab9610c8,
arg=0x2aaaae4fad88, kw=0x9566e0) at funcobject.c:548
#26 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#27 0x00000000004772ea in PyEval_EvalFrame (f=0x6eaad0) at ceval.c:3835
#28 0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaab94c9d0,
globals=0x8d6080, locals=0x7f3c, args=0x6eaad0, argcount=2,
    kws=0x0, kwcount=0, defs=0x0, defcount=0, closure=0x0) at ceval.c:2736
#29 0x00000000004c6099 in function_call (func=0x2aaaab961140,
arg=0x2aaaae4fad40, kw=0x0) at funcobject.c:548
#30 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#31 0x0000000000420ee0 in instancemethod_call (func=0x96c050,
arg=0x2aaaae4fad40, kw=0x0) at classobject.c:2447
#32 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#33 0x000000000044fd80 in slot_tp_call (self=0x2aaaae6a50d0,
args=0x2aaaae6a5150, kwds=0x0) at typeobject.c:4536
#34 0x0000000000417700 in PyObject_Call (func=0x96c050, arg=0x8d6080,
kw=0x7f3c) at abstract.c:1756
#35 0x00000000004777d9 in PyEval_EvalFrame (f=0x80a8c0) at ceval.c:3766
#36 0x0000000000479fb1 in PyEval_EvalFrame (f=0x6e8f10) at ceval.c:3640
#37 0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaab93bf10,
globals=0x8d6080, locals=0x7f3c, args=0x6e8f10, argcount=3,
    kws=0x6d2b80, kwcount=0, defs=0x2aaaab963728, defcount=2, closure=0x0)
at ceval.c:2736
#38 0x00000000004788f7 in PyEval_EvalFrame (f=0x6d29e0) at ceval.c:3650
#39 0x000000000047ad2f in PyEval_EvalCodeEx (co=0x2aaaadb3a3b0,
globals=0x8d6080, locals=0x7f3c, args=0x6d29e0, argcount=0,
    kws=0x0, kwcount=0, defs=0x0, defcount=0, closure=0x0) at ceval.c:2736
#40 0x000000000047af72 in PyEval_EvalCode (co=0x96c050, globals=0x8d6080,
locals=0x7f3c) at ceval.c:484
#41 0x00000000004a1c72 in PyRun_InteractiveOneFlags (fp=0x2aaaaab132d0,
filename=0x4cbf24 "<stdin>", flags=0x7fffffca155c)
    at pythonrun.c:1265
#42 0x00000000004a1e04 in PyRun_InteractiveLoopFlags (fp=0x2aaaab556b00,
filename=0x4cbf24 "<stdin>", flags=0x7fffffca155c)
    at pythonrun.c:695
#43 0x00000000004a2350 in PyRun_AnyFileExFlags (fp=0x2aaaab556b00,
filename=0x8d6080 "\020\226", closeit=0,
    flags=0x7fffffca155c) at pythonrun.c:658
#44 0x0000000000410788 in Py_Main (argc=0, argv=0x7fffffca28de) at
main.c:484
#45 0x00002aaaab34d5aa in __libc_start_main () from /lib64/tls/libc.so.6
#46 0x000000000040fdfa in _start () at start.S:113
#47 0x00007fffffca1658 in ?? ()
#48 0x00002aaaaabc19c0 in rtld_errno () from /lib64/ld-linux-x86-64.so.2


The only remaining incompatible pointer ones  are

gcc: build/src/build/src/scipy/linalg/flapackmodule.c
build/src/build/src/scipy/linalg/flapackmodule.c: In function
`f2py_rout_flapack_cheev':
build/src/build/src/scipy/linalg/flapackmodule.c:9761: warning: passing
arg 6 of pointer to function from incompatible pointer type
build/src/build/src/scipy/linalg/flapackmodule.c: In function
`f2py_rout_flapack_zheev':
build/src/build/src/scipy/linalg/flapackmodule.c:9945: warning: passing
arg 6 of pointer to function from incompatible pointer type
/scr/python/bin/g77 -shared
build/temp.linux-x86_64-2.4/build/src/build/src/scipy/linalg/flapackmodule.o
build/temp.linux-x86_64-2.4/build/src/fortranobject.o -L/scr/python/lib64
-Lbuild/temp.linux-x86_64-2.4 -llapack -lptf77blas -lptcblas

HTH, Arnd




More information about the Scipy-dev mailing list