[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [HTCondor-users] Memory leak in python bindings?



On 6/14/2016 12:21 PM, Scott Leishman wrote:
> Hi Brian,
> 
> Unfortunately schedd.xquery() exhibits the same behavior, and as it 
> turns out, so does query() on htcondor.Collector().
> 
> -Scott

Hi Scott,

I was able to reproduce the valgrind error of "definitely lost" leak with Schedd().query() (thanks for the bug report!), but when I tried using Schedd.xquery() or Collector.query() valgrind did not report a definite leak.  I was wondering what you are doing differently that is causing a definite leak with Collector.query().  Below you can see what I am trying.  Ps I patched the definite leak w/ Schedd.query() for the next release...

regards
Todd


[tannenba@localhost build_v84]$ valgrind python -c 'import htcondor; htcondor.Schedd().query()'

==26344== Memcheck, a memory error detector
==26344== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
==26344== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
==26344== Command: python -c import\ htcondor;\ htcondor.Schedd().query()
==26344== 
==26344== 
==26344== HEAP SUMMARY:
==26344==     in use at exit: 1,107,223 bytes in 6,756 blocks
==26344==   total heap usage: 26,204 allocs, 19,448 frees, 3,847,805 bytes allocated
==26344== 
==26344== LEAK SUMMARY:
==26344==    definitely lost: 200 bytes in 1 blocks
==26344==    indirectly lost: 96 bytes in 1 blocks
==26344==      possibly lost: 6,152 bytes in 13 blocks
==26344==    still reachable: 1,100,775 bytes in 6,741 blocks
==26344==         suppressed: 0 bytes in 0 blocks
==26344== Rerun with --leak-check=full to see details of leaked memory
==26344== 
==26344== For counts of detected and suppressed errors, rerun with: -v
==26344== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 72 from 9)

[tannenba@localhost build_v84]$ valgrind python -c 'import htcondor; htcondor.Schedd().xquery()'

==26346== Memcheck, a memory error detector
==26346== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
==26346== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
==26346== Command: python -c import\ htcondor;\ htcondor.Schedd().xquery()
==26346== 
==26346== 
==26346== HEAP SUMMARY:
==26346==     in use at exit: 1,106,926 bytes in 6,754 blocks
==26346==   total heap usage: 26,178 allocs, 19,424 frees, 3,825,153 bytes allocated
==26346== 
==26346== LEAK SUMMARY:
==26346==    definitely lost: 0 bytes in 0 blocks
==26346==    indirectly lost: 0 bytes in 0 blocks
==26346==      possibly lost: 6,152 bytes in 13 blocks
==26346==    still reachable: 1,100,774 bytes in 6,741 blocks
==26346==         suppressed: 0 bytes in 0 blocks
==26346== Rerun with --leak-check=full to see details of leaked memory
==26346== 
==26346== For counts of detected and suppressed errors, rerun with: -v
==26346== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 72 from 9)

[tannenba@localhost build_v84]$ valgrind python -c 'import htcondor; htcondor.Collector().query()'

==26350== Memcheck, a memory error detector
==26350== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
==26350== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
==26350== Command: python -c import\ htcondor;\ htcondor.Collector().query()
==26350== 
==26350== 
==26350== HEAP SUMMARY:
==26350==     in use at exit: 1,107,381 bytes in 6,764 blocks
==26350==   total heap usage: 33,774 allocs, 27,010 frees, 4,153,731 bytes allocated
==26350== 
==26350== LEAK SUMMARY:
==26350==    definitely lost: 0 bytes in 0 blocks
==26350==    indirectly lost: 0 bytes in 0 blocks
==26350==      possibly lost: 6,152 bytes in 13 blocks
==26350==    still reachable: 1,101,229 bytes in 6,751 blocks
==26350==         suppressed: 0 bytes in 0 blocks
==26350== Rerun with --leak-check=full to see details of leaked memory
==26350== 
==26350== For counts of detected and suppressed errors, rerun with: -v
==26350== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 72 from 9)

[tannenba@localhost build_v84]$ condor_version
$CondorVersion: 8.4.8 Jun 16 2016 BuildID: ToddT_Development PRE-RELEASE-UWCS $
$CondorPlatform: X86_64-ScientificLinux_6.7 $