[Numpy-discussion] SWIG / Numeric core dump

Joe Van Andel vanandel at atd.ucar.edu
Fri Aug 10 17:47:12 EDT 2001

The best way of finding core dumps with a Python extension is to compile
the extension source with '-g', and then follow these steps.
(You may also have to compile the Numeric Extensions with '-g', to trace
into them).

% gdb /usr/bin/python2.1
(gdb) br _PyImport_LoadDynamicModule 
(gdb) cont   # repeat until your extension is loaded

(gdb) finish # to load your extension
(gdb) br wrap_myfunction
(gdb) disable 1   # don't want to break for more modules being loaded
(gdb) continue

Note: you can't set a breakpoint in your code until your module has been

Joe VanAndel  	          
National Center for Atmospheric Research
Internet: vanandel at ucar.edu

More information about the NumPy-Discussion mailing list