summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rw-r--r--tapsets.cxx12
2 files changed, 18 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index b641d3b7..5f8e6ff3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
2009-02-11 Josh Stone <jistone@redhat.com>
+ * tapsets.cxx (dwarf_var_expanding_visitor::visit_cast_op): While
+ expanding dwarf probes, provide the current module as a default to
+ @casts without a module name.
+
+2009-02-11 Josh Stone <jistone@redhat.com>
+
* staptree.h (struct cast_op, visitor::visit_cast_op): New.
* staptree.cxx (cast_op::print/visit, various visitor::visit_cast_op's):
Incorporate cast_op into the basic tree operations.
diff --git a/tapsets.cxx b/tapsets.cxx
index d479efda..e5fbcc30 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -4228,6 +4228,7 @@ struct dwarf_var_expanding_visitor: public var_expanding_visitor
dwarf_var_expanding_visitor(dwarf_query & q, Dwarf_Die *sd, Dwarf_Addr a):
q(q), scope_die(sd), addr(a), add_block(NULL), add_probe(NULL), visited(false) {}
void visit_target_symbol (target_symbol* e);
+ void visit_cast_op (cast_op* e);
};
@@ -4787,6 +4788,17 @@ dwarf_var_expanding_visitor::visit_target_symbol (target_symbol *e)
void
+dwarf_var_expanding_visitor::visit_cast_op (cast_op *e)
+{
+ // Fill in our current module context if needed
+ if (e->module.empty())
+ e->module = q.dw.module_name;
+
+ var_expanding_visitor::visit_cast_op(e);
+}
+
+
+void
dwarf_derived_probe::printsig (ostream& o) const
{
// Instead of just printing the plain locations, we add a PC value