RE: is TTreeSQL dumping the whole table ?

From: Philippe Canal <pcanal_at_fnal.gov>
Date: Tue, 07 Feb 2006 09:07:21 -0600


 Hi,

The memory leak is now resolve. We still need to optimze the runtime speed.

Cheers,
Philippe.

-----Original Message-----
From: Tristan Beau [mailto:beau_at_in2p3.fr] Sent: Friday, February 03, 2006 2:27 AM
To: Philippe Canal
Cc: roottalk_at_pcroot.cern.ch
Subject: Re: [ROOT] is TTreeSQL dumping the whole table ?

Hi,

On 2 Feb 2006, at 15:35, Philippe Canal wrote:

> I'll try to see if I can spot any memory leak. Could you try running > with valgrind?

Well, I don't know valgrind. Anyway, I've installed and tried it. But I am using the interactive mode of ROOT, and the valgrind output is not so interesting...

#########################################################

  $ valgrind --leak-check=full root

==18136== Memcheck, a memory error detector.
==18136== Copyright (C) 2002-2005, and GNU GPL'd, by Julian Seward et
al.
==18136== Using LibVEX rev 1471, a library for dynamic binary
translation.
==18136== Copyright (C) 2004-2005, and GNU GPL'd, by OpenWorks LLP.
==18136== Using valgrind-3.1.0, a dynamic binary instrumentation
framework.
==18136== Copyright (C) 2000-2005, and GNU GPL'd, by Julian Seward et
al.
==18136== For more details, rerun with: -v
==18136==


FreeType Engine v2.1.9 used to render TrueType fonts. Compiled on 1 February 2006 for linux with thread support.

CINT/ROOT C/C++ Interpreter version 5.16.7, January 19, 2006 Type ? for help. Commands must be C++ statements. Enclose multiple statements between { }. root [0] TSQLServer *s = TSQLServer::Connect("mysql://aserver/ adb","user","pwd");
root [1] TTreeSQL *t = new TTreeSQL(s,"adb","atable"); root [2] t->Draw("field1","")
<TCanvas::MakeDefCanvas>: created default TCanvas with name c1 (Long64_t)742562
root [3] t->Draw("field2","")
(Long64_t)742562
root [4] t->Draw("field3","")
Error in <TTreeFormula::Compile>: Bad numerical expression : "T3Rate" (Long64_t)(-1)
root [5] t->Draw("field4:field5","")
(Long64_t)742562
root [6] t->Draw("field6:field7","")
==18136==
==18136== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 22
from 2)
==18136== malloc/free: in use at exit: 175 bytes in 3 blocks.
==18136== malloc/free: 1,056 allocs, 1,053 frees, 736,097 bytes
allocated.
==18136== For counts of detected errors, rerun with: -v
==18136== searching for pointers to 3 not-freed blocks.
==18136== checked 146,644 bytes.
==18136==
==18136== LEAK SUMMARY:
==18136== definitely lost: 0 bytes in 0 blocks.
==18136== possibly lost: 0 bytes in 0 blocks.
==18136== still reachable: 175 bytes in 3 blocks.
==18136== suppressed: 0 bytes in 0 blocks.
==18136== Reachable blocks (those to which a pointer was found) are
not shown.
==18136== To see them, rerun with: --show-reachable=yes

#######################

After the 6th command, the system killed the interactive root due to memory full...

How should I use valgrind to test the memory leak ?

                                Tristan

---
Tristan Beau       http://www.apc.univ-paris7.fr/~beau/
AstroParticules et Cosmologie
11 pl. M. Berthelot, 75231 Paris cedex 05 tel: +33 1 44 27 14 46 , fax: +33 1 43 54 69 89 Received on Tue Feb 07 2006 - 16:17:21 MET

This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:31:57 MET