summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Wielaard <mjw@redhat.com>2009-06-22 16:48:30 +0200
committerMark Wielaard <mjw@redhat.com>2009-06-22 16:48:30 +0200
commit6a35d102ce201e142f1133d9d5f0df6d47e3cd66 (patch)
tree7afc5e6bc8b361b8c83fc639d26cb70e5163a34b
parent98a1242d112575a8e65258f17611dd01c84fc45b (diff)
downloadsystemtap-steved-6a35d102ce201e142f1133d9d5f0df6d47e3cd66.tar.gz
systemtap-steved-6a35d102ce201e142f1133d9d5f0df6d47e3cd66.tar.xz
systemtap-steved-6a35d102ce201e142f1133d9d5f0df6d47e3cd66.zip
PR10307 beginning of statement check should be overridden in guru mode.
* tapsets.cxx (query_cu): When in guru mode just issue an warning (if not suppressed) instead of an error when address isn't at the beginning of a statement.
-rw-r--r--tapsets.cxx6
1 files changed, 5 insertions, 1 deletions
diff --git a/tapsets.cxx b/tapsets.cxx
index 15dbeb81..bc09e168 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -1639,6 +1639,7 @@ query_cu (Dwarf_Die * cudie, void * arg)
// statement. This is a somewhat lame check that the address
// is at the start of an assembly instruction. Mark probes are in the
// middle of a macro and thus not strictly at a statement beginning.
+ // Guru mode may override this check.
if (q->has_statement_num && ! q->has_mark)
{
Dwarf_Addr queryaddr = q->statement_num_val;
@@ -1651,7 +1652,10 @@ query_cu (Dwarf_Die * cudie, void * arg)
stringstream msg;
msg << "address 0x" << hex << queryaddr
<< " does not match the beginning of a statement";
- throw semantic_error(msg.str());
+ if (! q->sess.guru_mode)
+ throw semantic_error(msg.str());
+ else if (! q->sess.suppress_warnings)
+ q->sess.print_warning(msg.str());
}
}
// Pick up [entrypc, name, DIE] tuples for all the functions