[SciPy-dev] Check reading the nested fields of a nested array

Stefan van der Walt stefan at sun.ac.za
Tue Apr 25 06:49:14 CDT 2006


I've installed numpy from svn on two machines this morning, and on
both installations I see the glibc segfault.

Nils' python snippet does not reproduce the problem, however.

I attach the last output of 

 valgrind -v --error-limit=no --leak-check=full python -c 'import numpy; numpy.test()'

If I do

export GLIBCXX_FORCE_NEW=1

the tests crash simply with "Segmentation fault" instead of with

*** glibc detected *** free(): invalid next size (fast): 0x0830e828 ***
Aborted

I'll try to find a minimal snippet that reproduces the problem.

Regards
Stéfan

On Tue, Apr 25, 2006 at 11:02:37AM +0200, Nils Wagner wrote:
> Travis Oliphant wrote:
> >Nils Wagner wrote:
> >  
> >>Travis Oliphant wrote:
> >>  
> >>    
> >>>Nils Wagner wrote:
> >>>  
> >>>    
> >>>      
> >>>>Travis Oliphant wrote:
> >>>>  
> >>>>    
> >>>>      
> >>>>        
> >>>>>Nils Wagner wrote:
> >>>>>  
> >>>>>    
> >>>>>      
> >>>>>        
> >>>>>          
> >>>>>>Nils Wagner wrote:

etc.
-------------- next part --------------
valgrind: m_mallocfree.c:186 (get_bszB_as_is): Assertion 'bszB_lo == bszB_hi' failed.
valgrind: Heap block lo/hi size mismatch: lo = 4096, hi = 0.
Probably caused by overrunning/underrunning a heap block's bounds.

==20067==    at 0xA010AB3: report_and_quit (m_libcassert.c:122)
==20067==    by 0xA010CDC: vgPlain_assert_fail (m_libcassert.c:185)
==20067==    by 0xA01A5F8: mkFreeBlock (m_mallocfree.c:183)
==20067==    by 0xA01B761: vgPlain_arena_free (m_mallocfree.c:1115)
==20067==    by 0xA034513: vgPlain_cli_free (replacemalloc_core.c:108)
==20067==    by 0xA0015F0: die_and_free_mem (mac_malloc_wrappers.c:120)
==20067==    by 0xA03629C: do_client_request (scheduler.c:987)
==20067==    by 0xA035C0A: vgPlain_scheduler (scheduler.c:721)
==20067==    by 0xA04A133: thread_wrapper (syswrap-linux.c:86)
==20067==    by 0xA04A260: run_a_thread_NORETURN (syswrap-linux.c:119)

sched status:
  running_tid=1

Thread 1: status = VgTs_Runnable
==20067==    at 0x401BFCF: free (vg_replace_malloc.c:235)
==20067==    by 0x8098973: (within /usr/bin/python2.4)
==20067==    by 0x80B20C0: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B6FDA: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80FBF2C: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x80B4A59: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80FBF2C: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x805EFD4: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x80B457A: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80FBF2C: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x805EFD4: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x808B076: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x80B457A: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80FBF2C: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x80B4A59: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80FBF2C: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x805EFD4: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x808B076: (within /usr/bin/python2.4)
==20067==    by 0x805943B: PyObject_Call (in /usr/bin/python2.4)
==20067==    by 0x80B457A: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B6FDA: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80B6F32: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80B6F32: PyEval_EvalFrame (in /usr/bin/python2.4)
==20067==    by 0x80B76BE: PyEval_EvalCodeEx (in /usr/bin/python2.4)
==20067==    by 0x80B7904: PyEval_EvalCode (in /usr/bin/python2.4)
==20067==    by 0x80D9A41: PyRun_SimpleStringFlags (in /usr/bin/python2.4)
==20067==    by 0x8055702: Py_Main (in /usr/bin/python2.4)
==20067==    by 0x4084EA1: __libc_start_main (in /lib/tls/i686/cmov/libc-2.3.6.so)



More information about the Scipy-dev mailing list