From c3a3c0c99c32c0969e6450d60aae1a2b1798ca17 Mon Sep 17 00:00:00 2001 From: wcohen Date: Tue, 26 Jun 2007 19:36:25 +0000 Subject: 2007-06-26 William Cohen PR 4529 * coveragedb.cxx: New. * coveragedb.h: New. * Makefile.am: Add coveragedb.cxx and sqlite3 to build. * Makefile.in: Regenerated. * configure.ac: Add test for sqlite3 * configure: Regenerated. * systemtap.spec.in: Add dependencies for sqlite3/sqlite3-devel. * elaborate.h, elaborate.cxx (derived_probe::collect_derivation_chain): New. (alias_expansion_builder::build): Correct token location. (semantic_pass_opt[12): Track used and unused variables/functions. * session.h (tapset_compile_coverage, unused_globals, unused_probes, unused_functions): New fields. * staptree.h (unused_locals, probe_point::str): New member. * staptree.cxx: Ditto. * main.cxx: Add "-q" tapset coverage option and SYSTEMTAP_COVERAGE env. --- staptree.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'staptree.h') diff --git a/staptree.h b/staptree.h index 0ba8c657..415d510b 100644 --- a/staptree.h +++ b/staptree.h @@ -411,6 +411,7 @@ struct functiondecl: public symboldecl { std::vector formal_args; std::vector locals; + std::vector unused_locals; statement* body; functiondecl (); void print (std::ostream& o) const; @@ -537,6 +538,7 @@ struct next_statement: public statement struct probe; +struct derived_probe; struct probe_alias; struct embeddedcode; struct stapfile @@ -570,6 +572,7 @@ struct probe_point void print (std::ostream& o) const; probe_point (); probe_point(std::vector const & comps,const token * t); + std::string str(); }; std::ostream& operator << (std::ostream& o, const probe_point& k); @@ -581,9 +584,11 @@ struct probe block* body; const token* tok; std::vector locals; + std::vector unused_locals; probe (); void print (std::ostream& o) const; virtual void printsig (std::ostream &o) const; + virtual void collect_derivation_chain (std::vector &probes_list); virtual probe* basest () { return this; } virtual ~probe() {} bool privileged; -- cgit