[geos-devel] Leaking Prepared Geometries

Paul Ramsey pramsey at cleverelephant.ca
Fri Aug 15 17:50:18 EDT 2008


OK, it took quite a while to set up, but I got an example leaking its
way through valgrind.  This is using geos trunk and postgis trunk,
with PREPARED_GEOM set to 1.  Here's the commandline invocation:

echo "select va.edabbr, count(*) from ed join va on
(st_contains(ed.the_geom, va.the_geom, ed.gid)) where va.edabbr =
'PRO' and va.vaabbr like '02%' group by va.edabbr" | valgrind
--leak-check=yes --log-file=valgrindlog
/usr/local/pgsql/8.3/bin/postgres --single postgis

ed is a table of complex largish polygons and va is a table of
smallish polygons. The where clause limited it to about 15 tests, so
it "only" leaked about 100Mb. At 100 or so tests, it was leaking 500Mb
and creaming the VM on which I'm running this stuff.

The valgrind output is attached.

Paul
-------------- next part --------------
==28178== Memcheck, a memory error detector.
==28178== Copyright (C) 2002-2006, and GNU GPL'd, by Julian Seward et al.
==28178== Using LibVEX rev 1658, a library for dynamic binary translation.
==28178== Copyright (C) 2004-2006, and GNU GPL'd, by OpenWorks LLP.
==28178== Using valgrind-3.2.1, a dynamic binary instrumentation framework.
==28178== Copyright (C) 2000-2006, and GNU GPL'd, by Julian Seward et al.
==28178== For more details, rerun with: -v
==28178== 
==28178== My PID = 28178, parent PID = 6049.  Prog and args are:
==28178==    /usr/local/pgsql/8.3/bin/postgres
==28178==    --single
==28178==    postgis
==28178== 
==28178== Syscall param write(buf) points to uninitialised byte(s)
==28178==    at 0x40D3F53: __write_nocancel (in /lib/libc-2.5.so)
==28178==    by 0x4075544: new_do_write (in /lib/libc-2.5.so)
==28178==    by 0x407582E: _IO_do_write@@GLIBC_2.1 (in /lib/libc-2.5.so)
==28178==    by 0x407611D: _IO_file_overflow@@GLIBC_2.1 (in /lib/libc-2.5.so)
==28178==    by 0x407571B: _IO_file_xsputn@@GLIBC_2.1 (in /lib/libc-2.5.so)
==28178==    by 0x406BCDE: fwrite (in /lib/libc-2.5.so)
==28178==    by 0x8277998: write_item (relcache.c:3832)
==28178==    by 0x8277B86: write_relcache_init_file (relcache.c:3720)
==28178==    by 0x827B740: RelationCacheInitializePhase2 (relcache.c:2663)
==28178==    by 0x828D59F: InitPostgres (postinit.c:536)
==28178==    by 0x81E676B: PostgresMain (postgres.c:3292)
==28178==    by 0x8177A59: main (main.c:186)
==28178==  Address 0x4009466 is not stack'd, malloc'd or (recently) free'd
==28178== 
==28178== Syscall param write(buf) points to uninitialised byte(s)
==28178==    at 0x40D3F53: __write_nocancel (in /lib/libc-2.5.so)
==28178==    by 0x4075544: new_do_write (in /lib/libc-2.5.so)
==28178==    by 0x407582E: _IO_do_write@@GLIBC_2.1 (in /lib/libc-2.5.so)
==28178==    by 0x4076C14: _IO_file_close_it@@GLIBC_2.1 (in /lib/libc-2.5.so)
==28178==    by 0x406A81D: fclose@@GLIBC_2.1 (in /lib/libc-2.5.so)
==28178==    by 0x81D24C4: FreeDesc (fd.c:1322)
==28178==    by 0x81D25E4: FreeFile (fd.c:1359)
==28178==    by 0x8277CD4: write_relcache_init_file (relcache.c:3780)
==28178==    by 0x827B740: RelationCacheInitializePhase2 (relcache.c:2663)
==28178==    by 0x828D59F: InitPostgres (postinit.c:536)
==28178==    by 0x81E676B: PostgresMain (postgres.c:3292)
==28178==    by 0x8177A59: main (main.c:186)
==28178==  Address 0x40091DE is not stack'd, malloc'd or (recently) free'd
==28178== 
==28178== ERROR SUMMARY: 20 errors from 2 contexts (suppressed: 42 from 1)
==28178== malloc/free: in use at exit: 11,284,212 bytes in 227,180 blocks.
==28178== malloc/free: 450,018 allocs, 222,838 frees, 2,521,992,627 bytes allocated.
==28178== For counts of detected errors, rerun with: -v
==28178== searching for pointers to 227,180 not-freed blocks.
==28178== checked 2,272,612 bytes.
==28178== 
==28178== 
==28178== 16 bytes in 1 blocks are possibly lost in loss record 6 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x7028082: geos::index::strtree::STRtree::createNode(int) (STRtree.cpp:222)
==28178==    by 0x702B992: geos::index::strtree::AbstractSTRtree::createParentBoundables(std::vector<geos::index::strtree::Boundable*, std::allocator<geos::index::strtree::Boundable*> >*, int) (AbstractSTRtree.cpp:83)
==28178==    by 0x70287F1: geos::index::strtree::STRtree::createParentBoundablesFromVerticalSlice(std::vector<geos::index::strtree::Boundable*, std::allocator<geos::index::strtree::Boundable*> >*, int) (STRtree.cpp:154)
==28178==    by 0x70288C5: geos::index::strtree::STRtree::createParentBoundablesFromVerticalSlices(std::vector<std::vector<geos::index::strtree::Boundable*, std::allocator<geos::index::strtree::Boundable*> >*, std::allocator<std::vector<geos::index::strtree::Boundable*, std::allocator<geos::index::strtree::Boundable*> >*> >*, int) (STRtree.cpp:139)
==28178==    by 0x7028AE7: geos::index::strtree::STRtree::createParentBoundables(std::vector<geos::index::strtree::Boundable*, std::allocator<geos::index::strtree::Boundable*> >*, int) (STRtree.cpp:117)
==28178==    by 0x702B7F5: geos::index::strtree::AbstractSTRtree::createHigherLevels(std::vector<geos::index::strtree::Boundable*, std::allocator<geos::index::strtree::Boundable*> >*, int) (AbstractSTRtree.cpp:98)
==28178==    by 0x702A9D8: geos::index::strtree::AbstractSTRtree::build() (AbstractSTRtree.cpp:58)
==28178==    by 0x702AA16: geos::index::strtree::AbstractSTRtree::query(void const*, std::vector<void*, std::allocator<void*> >&) (AbstractSTRtree.cpp:123)
==28178==    by 0x7028FB8: geos::index::strtree::STRtree::query(geos::geom::Envelope const*, std::vector<void*, std::allocator<void*> >&) (STRtree.h:129)
==28178==    by 0x703E503: geos::noding::MCIndexSegmentSetMutualIntersector::intersectChains() (MCIndexSegmentSetMutualIntersector.cpp:65)
==28178==    by 0x703EAFE: geos::noding::MCIndexSegmentSetMutualIntersector::process(std::vector<geos::noding::SegmentString const*, std::allocator<geos::noding::SegmentString const*> >*) (MCIndexSegmentSetMutualIntersector.cpp:137)
==28178== 
==28178== 
==28178== 24 bytes in 1 blocks are possibly lost in loss record 11 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x702352C: geos::index::chain::MonotoneChainBuilder::getChains(geos::geom::CoordinateSequence const*, void*, std::vector<geos::index::chain::MonotoneChain*, std::allocator<geos::index::chain::MonotoneChain*> >&) (MonotoneChainBuilder.cpp:65)
==28178==    by 0x702360A: geos::index::chain::MonotoneChainBuilder::getChains(geos::geom::CoordinateSequence const*, void*) (MonotoneChainBuilder.cpp:46)
==28178==    by 0x703E6B3: geos::noding::MCIndexSegmentSetMutualIntersector::addToIndex(geos::noding::SegmentString*) (MCIndexSegmentSetMutualIntersector.cpp:39)
==28178==    by 0x703E760: geos::noding::MCIndexSegmentSetMutualIntersector::setBaseSegments(std::vector<geos::noding::SegmentString const*, std::allocator<geos::noding::SegmentString const*> >*) (MCIndexSegmentSetMutualIntersector.cpp:121)
==28178==    by 0x703BAE1: geos::noding::FastSegmentSetIntersectionFinder::FastSegmentSetIntersectionFinder(std::vector<geos::noding::SegmentString const*, std::allocator<geos::noding::SegmentString const*> >*) (FastSegmentSetIntersectionFinder.cpp:42)
==28178==    by 0x7002D5E: geos::geom::prep::PreparedPolygon::getIntersectionFinder() const (PreparedPolygon.cpp:69)
==28178==    by 0x70023FF: geos::geom::prep::AbstractPreparedPolygonContains::findAndClassifyIntersections(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:86)
==28178==    by 0x700268A: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:141)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178==    by 0x6EFB017: containsPrepared (lwgeom_geos_c.c:3802)
==28178== 
==28178== 
==28178== 38 bytes in 1 blocks are definitely lost in loss record 17 of 106
==28178==    at 0x40053C0: malloc (vg_replace_malloc.c:149)
==28178==    by 0x4081D1F: strdup (in /lib/libc-2.5.so)
==28178==    by 0x82A73C9: set_pglocale_pgservice (exec.c:660)
==28178==    by 0x81775DE: main (main.c:90)
==28178== 
==28178== 
==28178== 1,122 (84 direct, 1,038 indirect) bytes in 1 blocks are definitely lost in loss record 26 of 106
==28178==    at 0x40053C0: malloc (vg_replace_malloc.c:149)
==28178==    by 0x8298776: save_ps_display_args (ps_status.c:162)
==28178==    by 0x81775C9: main (main.c:79)
==28178== 
==28178== 
==28178== 224 bytes in 8 blocks are possibly lost in loss record 37 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x7023902: geos::index::intervalrtree::SortedPackedIntervalRTree::buildLevel(std::vector<geos::index::intervalrtree::IntervalRTreeNode const*, std::allocator<geos::index::intervalrtree::IntervalRTreeNode const*> >*, std::vector<geos::index::intervalrtree::IntervalRTreeNode const*, std::allocator<geos::index::intervalrtree::IntervalRTreeNode const*> >*) (SortedPackedIntervalRTree.cpp:83)
==28178==    by 0x7023B1E: geos::index::intervalrtree::SortedPackedIntervalRTree::buildTree() (SortedPackedIntervalRTree.cpp:51)
==28178==    by 0x7023B9F: geos::index::intervalrtree::SortedPackedIntervalRTree::init() (SortedPackedIntervalRTree.cpp:36)
==28178==    by 0x7023BDB: geos::index::intervalrtree::SortedPackedIntervalRTree::query(double, double, geos::index::ItemVisitor*) (SortedPackedIntervalRTree.cpp:136)
==28178==    by 0x6FE5005: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::query(double, double, geos::index::ItemVisitor*) (IndexedPointInAreaLocator.cpp:136)
==28178==    by 0x6FE559F: geos::algorithm::locate::IndexedPointInAreaLocator::locate(geos::geom::Coordinate const*) (IndexedPointInAreaLocator.cpp:120)
==28178==    by 0x7001A15: geos::geom::prep::PreparedPolygonPredicate::isAllTestComponentsInTargetArea(geos::geom::Geometry const*) (PreparedPolygonPredicate.cpp:44)
==28178==    by 0x70025B5: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:112)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178==    by 0x6EFB017: containsPrepared (lwgeom_geos_c.c:3802)
==28178== 
==28178== 
==28178== 8,910,300 (660 direct, 8,909,640 indirect) bytes in 15 blocks are definitely lost in loss record 53 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x700399C: geos::geom::prep::PreparedGeometryFactory::create(geos::geom::Geometry const*) const (PreparedGeometryFactory.cpp:58)
==28178==    by 0x6F38232: GEOSPrepare (PreparedGeometryFactory.h:61)
==28178==    by 0x6EF7715: get_prepared_geometry_cache_key (lwgeom_geos_c.c:3702)
==28178==    by 0x6EFAF9E: containsPrepared (lwgeom_geos_c.c:3781)
==28178==    by 0x815E007: ExecMakeFunctionResultNoSets (execQual.c:1412)
==28178==    by 0x815E06B: ExecQual (execQual.c:4501)
==28178==    by 0x81693B8: ExecNestLoop (nodeNestloop.c:231)
==28178==    by 0x81592DC: ExecProcNode (execProcnode.c:367)
==28178==    by 0x8163898: ExecAgg (nodeAgg.c:865)
==28178==    by 0x8159339: ExecProcNode (execProcnode.c:394)
==28178==    by 0x8158299: ExecutorRun (execMain.c:1248)
==28178== 
==28178== 
==28178== 936 bytes in 18 blocks are possibly lost in loss record 56 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x6FE50EE: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::addLine(geos::geom::CoordinateSequence*) (IndexedPointInAreaLocator.cpp:72)
==28178==    by 0x6FE53D7: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::init(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:61)
==28178==    by 0x6FE5477: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::IntervalIndexedGeometry(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:42)
==28178==    by 0x6FE54BC: geos::algorithm::locate::IndexedPointInAreaLocator::buildIndex(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:85)
==28178==    by 0x6FE5C9E: geos::algorithm::locate::IndexedPointInAreaLocator::IndexedPointInAreaLocator(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:105)
==28178==    by 0x70028D1: geos::geom::prep::PreparedPolygon::getPointLocator() const (PreparedPolygon.cpp:79)
==28178==    by 0x7001A09: geos::geom::prep::PreparedPolygonPredicate::isAllTestComponentsInTargetArea(geos::geom::Geometry const*) (PreparedPolygonPredicate.cpp:44)
==28178==    by 0x70025B5: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:112)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178==    by 0x6EFB017: containsPrepared (lwgeom_geos_c.c:3802)
==28178== 
==28178== 
==28178== 135,196 (24 direct, 135,172 indirect) bytes in 1 blocks are definitely lost in loss record 65 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x6FF106B: geos::geom::GeometryFactory::createMultiPolygon(std::vector<geos::geom::Geometry*, std::allocator<geos::geom::Geometry*> >*) const (GeometryFactory.cpp:361)
==28178==    by 0x6F393A8: GEOSGeom_createCollection (geos_c.cpp:1282)
==28178==    by 0x6EF75ED: LWGEOM2GEOS (lwgeom_geos_c.c:3156)
==28178==    by 0x6EF768D: POSTGIS2GEOS (lwgeom_geos_c.c:3191)
==28178==    by 0x6EF770D: get_prepared_geometry_cache_key (lwgeom_geos_c.c:3701)
==28178==    by 0x6EFAF9E: containsPrepared (lwgeom_geos_c.c:3781)
==28178==    by 0x815E007: ExecMakeFunctionResultNoSets (execQual.c:1412)
==28178==    by 0x815E06B: ExecQual (execQual.c:4501)
==28178==    by 0x81693B8: ExecNestLoop (nodeNestloop.c:231)
==28178==    by 0x81592DC: ExecProcNode (execProcnode.c:367)
==28178==    by 0x8163898: ExecAgg (nodeAgg.c:865)
==28178== 
==28178== 
==28178== 56 bytes in 7 blocks are definitely lost in loss record 71 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x70015E1: geos::geom::prep::PreparedPolygonPredicate::isAnyTargetComponentInTestArea(geos::geom::Geometry const*, std::vector<geos::geom::Coordinate const*, std::allocator<geos::geom::Coordinate const*> > const*) (PreparedPolygonPredicate.cpp:104)
==28178==    by 0x700265B: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:175)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178==    by 0x6EFB017: containsPrepared (lwgeom_geos_c.c:3802)
==28178==    by 0x815E007: ExecMakeFunctionResultNoSets (execQual.c:1412)
==28178==    by 0x815E06B: ExecQual (execQual.c:4501)
==28178==    by 0x81693B8: ExecNestLoop (nodeNestloop.c:231)
==28178==    by 0x81592DC: ExecProcNode (execProcnode.c:367)
==28178==    by 0x8163964: ExecAgg (nodeAgg.c:921)
==28178==    by 0x8159339: ExecProcNode (execProcnode.c:394)
==28178== 
==28178== 
==28178== 240 bytes in 10 blocks are possibly lost in loss record 82 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x7023F16: geos::index::intervalrtree::SortedPackedIntervalRTree::insert(double, double, void*) (SortedPackedIntervalRTree.cpp:130)
==28178==    by 0x6FE5180: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::addLine(geos::geom::CoordinateSequence*) (IndexedPointInAreaLocator.cpp:77)
==28178==    by 0x6FE53D7: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::init(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:61)
==28178==    by 0x6FE5477: geos::algorithm::locate::IndexedPointInAreaLocator::IntervalIndexedGeometry::IntervalIndexedGeometry(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:42)
==28178==    by 0x6FE54BC: geos::algorithm::locate::IndexedPointInAreaLocator::buildIndex(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:85)
==28178==    by 0x6FE5C9E: geos::algorithm::locate::IndexedPointInAreaLocator::IndexedPointInAreaLocator(geos::geom::Geometry const&) (IndexedPointInAreaLocator.cpp:105)
==28178==    by 0x70028D1: geos::geom::prep::PreparedPolygon::getPointLocator() const (PreparedPolygon.cpp:79)
==28178==    by 0x7001A09: geos::geom::prep::PreparedPolygonPredicate::isAllTestComponentsInTargetArea(geos::geom::Geometry const*) (PreparedPolygonPredicate.cpp:44)
==28178==    by 0x70025B5: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:112)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178== 
==28178== 
==28178== 36,972 (108 direct, 36,864 indirect) bytes in 9 blocks are definitely lost in loss record 88 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x70235D4: geos::index::chain::MonotoneChainBuilder::getChains(geos::geom::CoordinateSequence const*, void*) (MonotoneChainBuilder.cpp:45)
==28178==    by 0x703E6B3: geos::noding::MCIndexSegmentSetMutualIntersector::addToIndex(geos::noding::SegmentString*) (MCIndexSegmentSetMutualIntersector.cpp:39)
==28178==    by 0x703E760: geos::noding::MCIndexSegmentSetMutualIntersector::setBaseSegments(std::vector<geos::noding::SegmentString const*, std::allocator<geos::noding::SegmentString const*> >*) (MCIndexSegmentSetMutualIntersector.cpp:121)
==28178==    by 0x703BAE1: geos::noding::FastSegmentSetIntersectionFinder::FastSegmentSetIntersectionFinder(std::vector<geos::noding::SegmentString const*, std::allocator<geos::noding::SegmentString const*> >*) (FastSegmentSetIntersectionFinder.cpp:42)
==28178==    by 0x7002D5E: geos::geom::prep::PreparedPolygon::getIntersectionFinder() const (PreparedPolygon.cpp:69)
==28178==    by 0x70023FF: geos::geom::prep::AbstractPreparedPolygonContains::findAndClassifyIntersections(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:86)
==28178==    by 0x700268A: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:141)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178==    by 0x6EFB017: containsPrepared (lwgeom_geos_c.c:3802)
==28178==    by 0x815E007: ExecMakeFunctionResultNoSets (execQual.c:1412)
==28178== 
==28178== 
==28178== 360,768 bytes in 4 blocks are possibly lost in loss record 104 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x6FE8395: geos::geom::CoordinateArraySequence::CoordinateArraySequence(geos::geom::CoordinateArraySequence const&) (new_allocator.h:88)
==28178==    by 0x6FE845C: geos::geom::CoordinateArraySequence::clone() const (CoordinateArraySequence.cpp:58)
==28178==    by 0x6FF6D3F: geos::geom::LineString::getCoordinates() const (LineString.cpp:110)
==28178==    by 0x7002B62: geos::geom::prep::PreparedPolygon::getIntersectionFinder() const (SegmentStringUtil.h:56)
==28178==    by 0x70023FF: geos::geom::prep::AbstractPreparedPolygonContains::findAndClassifyIntersections(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:86)
==28178==    by 0x700268A: geos::geom::prep::AbstractPreparedPolygonContains::eval(geos::geom::Geometry const*) (AbstractPreparedPolygonContains.cpp:141)
==28178==    by 0x7002A42: geos::geom::prep::PreparedPolygon::contains(geos::geom::Geometry const*) const (PreparedPolygonContains.h:96)
==28178==    by 0x6F3673C: GEOSPreparedContains (geos_c.cpp:2381)
==28178==    by 0x6EFB017: containsPrepared (lwgeom_geos_c.c:3802)
==28178==    by 0x815E007: ExecMakeFunctionResultNoSets (execQual.c:1412)
==28178==    by 0x815E06B: ExecQual (execQual.c:4501)
==28178== 
==28178== 
==28178== 405,552 bytes in 4 blocks are possibly lost in loss record 105 of 106
==28178==    at 0x4005B65: operator new(unsigned) (vg_replace_malloc.c:163)
==28178==    by 0x6FE8057: geos::geom::CoordinateArraySequence::CoordinateArraySequence(unsigned) (new_allocator.h:88)
==28178==    by 0x6FD6FE0: geos::geom::CoordinateArraySequenceFactory::create(unsigned, unsigned) const (CoordinateArraySequenceFactory.inl:44)
==28178==    by 0x6F37121: GEOSCoordSeq_create (geos_c.cpp:1522)
==28178==    by 0x6EF7376: ptarray_to_GEOSCoordSeq (lwgeom_geos_c.c:3050)
==28178==    by 0x6EF74D1: LWGEOM2GEOS (lwgeom_geos_c.c:3117)
==28178==    by 0x6EF75C6: LWGEOM2GEOS (lwgeom_geos_c.c:3153)
==28178==    by 0x6EF768D: POSTGIS2GEOS (lwgeom_geos_c.c:3191)
==28178==    by 0x6EF770D: get_prepared_geometry_cache_key (lwgeom_geos_c.c:3701)
==28178==    by 0x6EFAF9E: containsPrepared (lwgeom_geos_c.c:3781)
==28178==    by 0x815E007: ExecMakeFunctionResultNoSets (execQual.c:1412)
==28178==    by 0x815E06B: ExecQual (execQual.c:4501)
==28178== 
==28178== LEAK SUMMARY:
==28178==    definitely lost: 970 bytes in 34 blocks.
==28178==    indirectly lost: 9,082,714 bytes in 226,239 blocks.
==28178==      possibly lost: 767,760 bytes in 46 blocks.
==28178==    still reachable: 1,432,768 bytes in 861 blocks.
==28178==         suppressed: 0 bytes in 0 blocks.
==28178== Reachable blocks (those to which a pointer was found) are not shown.
==28178== To see them, rerun with: --show-reachable=yes


More information about the geos-devel mailing list