On Jul 8, 2010, at 2:51 PM, Michael Droettboom wrote: > On 07/08/2010 02:38 PM, John Hunter wrote: >> On Thu, Jul 8, 2010 at 1:25 PM, Tony S Yu<tsy...@gmail.com> wrote: >> >>> On Jul 8, 2010, at 12:27 PM, Michael Droettboom wrote: >>> >>> Can you get a gdb backtrace? >>> >>> Mike >>> >>> Ignore my last email. The crash occurs here: >>> #--- >>> Continuing. >>> Reading symbols for shared libraries . done >>> Reading symbols for shared libraries + done >>> 2010-07-08 14:15:20.218 Python[60899:d13] *** __NSAutoreleaseNoPool(): >>> Object 0x1048a86d0 of class NSCFNumber autoreleased with no pool in place - >>> just leaking >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries ++ done >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries + done >>> Reading symbols for shared libraries + done >>> Program received signal EXC_BAD_ACCESS, Could not access memory. >>> Reason: KERN_INVALID_ADDRESS at address: 0x0000003000000040 >>> agg::pod_bvector<agg::point_base<double>, 6u>::~pod_bvector >>> (this=0x7fff5fbf8130) at agg_array.h:521 >>> 521 pod_allocator<T>::deallocate(*blk, block_size); >>> #--- >>> and the first few lines of the traceback are here: >>> #--- >>> #0 agg::pod_bvector<agg::point_base<double>, 6u>::~pod_bvector >>> (this=0x7fff5fbf8130) at agg_array.h:521 >>> #1 0x0000000101795b65 in ~vertex_sequence [inlined] () at >>> /Users/Tony/python/devel/mpl/agg24/include/agg_vertex_sequence.h:525 >>> #2 0x0000000101795b65 in agg::vcgen_stroke::~vcgen_stroke >>> (this=0x7fff5fbf80c8) at agg_vcgen_stroke.h:32 >>> #3 0x000000011a45ea07 in ~rasterizer_cells_aa [inlined] () at >>> kiva_graphics_context.h:410 >>> #4 0x000000011a45ea07 in ~rasterizer_scanline_aa [inlined] () at >>> /Users/Tony/python/devel/enthought/Enable/enthought/kiva/agg/agg-24/include/agg_rasterizer_cells_aa.h:101 >>> #--- >>> I posted the full traceback on pastebin: http://pastebin.com/ViefksDC >>> Are there conflicting versions of agg? >>> >> Could be -- we both use 2.4 but Maxim was somewhat infamous for doing >> several 2.4 release without changing any version numbers. Can you >> diff the two agg_rasterizer_cells_a.h files? The problems could lie >> in a different file, but this would be a start. You might recursively >> diff the src dirs as well. >> > We also have some custom changes in the matplotlib tree -- because upstream > agg 2.4 is basically closed. > > Mike >
I've attached a diff of the file you suggested, John.There's a pretty significant output when diff-ing recursively. It doesn't sound like there's much to be done about this issue if matplotlib and enthought are using different versions of Agg (assuming this difference is actually the cause of the segfault). In any case, I'll just refactor my code so that I don't run into this conflict. Thanks, -Tony $ diff -b mpl/agg24/include/agg_rasterizer_cells_aa.h enthought/Enable/enthought/kiva/agg/agg-24/include/agg_rasterizer_cells_aa.h32,33d31 < #include "CXX/Exception.hxx" < #include <exception> 38a37 > 40a40 > 52c52 < cell_block_limit = 4096 --- > cell_block_limit = 1024 186,194c186 < if(m_num_blocks >= cell_block_limit) { < static Py::Exception e( < Py::OverflowError( < "Agg rendering complexity exceeded. Consider downsampling or decimating your data.")); < < /* If this exception is thrown too often, one can < increase cell_block_limit */ < throw e; < } --- > if(m_num_blocks >= cell_block_limit) return; 654a647 > 678,679d670 < i = m_num_cells & cell_block_mask; < if (i) { 680a672 > i = m_num_cells & cell_block_mask; 686d677 < } 713,714d703 < i = m_num_cells & cell_block_mask; < if (i) { 715a705 > i = m_num_cells & cell_block_mask; 723d712 < } ------------------------------------------------------------------------------ This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel