Uploaded image for project: 'ROOT'
  1. ROOT
  2. ROOT-5236

Memory Leak in RooFit/HistFactory

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 5.34/00
    • Fix Version/s: 6.14/10, 6.16/02
    • Component/s: RooFit/RooStats
    • Labels:
      None
    • Environment:

      tested on several x86_64 slc5 machines (also lxplus5), probably occurs on other machines as well

      Description

      I am trying to run a Cut Optimization study and hence repeatedly execute various methods from RooFit/RooStats/HistFactory in a loop over ~14.000 entries (different cut configurations).
      I noticed that my code was running fast at the beginning, but became slower and slower as time passed by, up to the point that a full run of the study is merely impossible. Looking at the memory usage (using "top"), I saw that the memory usage of my code was huge and ever increasing, hinting towards a memory leak.
      Setting up a minimal example of what I was trying to do and using valgrind to trace the leak, I am by now pretty sure that the memory leak does not originate from my code, but instead from somewhere within RooFit/RooStats/HistFactory. I attached a minimal example source file and a corresponding Makefile, reproducing the leak.
      In the configuration given, the code performs an infinite loop, allowing to observe the memory leak in filling up the system memory as time goes by. If you want to investigate the leak with valgrind or similar utilities, you should first comment line 70.

        Attachments

        1. Makefile
          0.3 kB
        2. memleak.C
          2 kB

          Activity

            People

            Assignee:
            shageboe Stephan Hageboeck
            Reporter:
            cburgard Carsten Daniel Burgard
            Votes:
            1 Vote for this issue
            Watchers:
            6 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Planned Start:
              Planned End:
              Actual End: