summaryrefslogtreecommitdiffstats
path: root/tapsets.cxx
diff options
context:
space:
mode:
authorfche <fche>2007-02-25 23:03:49 +0000
committerfche <fche>2007-02-25 23:03:49 +0000
commitaa30ccd31a0163bed25b993ae386efe1cd1feb39 (patch)
treeae223d1620408b9f8f62b4af6faa75ac2451d024 /tapsets.cxx
parent5dbd55d7b4012a10e41c18ebaaddfb534c1b9196 (diff)
downloadsystemtap-steved-aa30ccd31a0163bed25b993ae386efe1cd1feb39.tar.gz
systemtap-steved-aa30ccd31a0163bed25b993ae386efe1cd1feb39.tar.xz
systemtap-steved-aa30ccd31a0163bed25b993ae386efe1cd1feb39.zip
2007-02-25 Frank Ch. Eigler <fche@redhat.com>
* elaborate.h (match_node, derived_probe_builder): Add build_no_more member function. * elaborate.cxx (semantic_pass_symbols): Call it. * tapsets.cxx (dwarf_builder): Implement it by releasing dwflpp instance after pass 2, freeing mucho memory.
Diffstat (limited to 'tapsets.cxx')
-rw-r--r--tapsets.cxx17
1 files changed, 15 insertions, 2 deletions
diff --git a/tapsets.cxx b/tapsets.cxx
index eaa719d4..55e64942 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -1,6 +1,6 @@
// tapset resolution
-// Copyright (C) 2005, 2006 Red Hat Inc.
-// Copyright (C) 2005, 2006 Intel Corporation.
+// Copyright (C) 2005-2007 Red Hat Inc.
+// Copyright (C) 2005-2007 Intel Corporation.
//
// This file is part of systemtap, and is free software. You can
// redistribute it and/or modify it under the terms of the GNU General
@@ -1990,6 +1990,18 @@ struct dwarf_builder: public derived_probe_builder
dwarf_builder()
: kern_dw(NULL), user_dw(NULL)
{}
+
+ void build_no_more (systemtap_session &s)
+ {
+ if (kern_dw)
+ {
+ if (s.verbose > 3)
+ clog << "dwarf_builder releasing dwflpp" << endl;
+ delete kern_dw;
+ kern_dw = 0;
+ }
+ }
+
~dwarf_builder()
{
if (kern_dw)
@@ -1997,6 +2009,7 @@ struct dwarf_builder: public derived_probe_builder
if (user_dw)
delete user_dw;
}
+
virtual void build(systemtap_session & sess,
probe * base,
probe_point * location,