* [Bug translator/17966] New: @defined always returns true in return probes
@ 2015-02-12 21:32 aram.h at mgk dot ro
2015-02-12 21:33 ` [Bug translator/17966] " aram.h at mgk dot ro
2015-02-12 22:08 ` jistone at redhat dot com
0 siblings, 2 replies; 3+ messages in thread
From: aram.h at mgk dot ro @ 2015-02-12 21:32 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=17966
Bug ID: 17966
Summary: @defined always returns true in return probes
Product: systemtap
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: translator
Assignee: systemtap at sourceware dot org
Reporter: aram.h at mgk dot ro
CC: jistone at redhat dot com
@defined can't be used in return probes because it always returns 1.
stap -e 'probe process("bash").function("*").return {r0 = @defined($_r0) ? $_r0
: 0; printf ("r0: %d\n", r0); exit ()}'
WARNING: function _start return probe is blacklisted: keyword at <input>:1:1
source: probe process("bash").function("*").return {r0 = @defined($_r0) ? $_r0
: 0; printf ("r0: %d\n", r0); exit ()}
^
semantic error: unresolved target-symbol expression: identifier '$_r0' at :1:67
source: probe process("bash").function("*").return {r0 = @defined($_r0)
? $_r0 : 0; printf ("r0: %d\n", r0); exit ()}
^
Pass 2: analysis failed. [man error::pass2]
: xgene:tmp;
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug translator/17966] @defined always returns true in return probes
2015-02-12 21:32 [Bug translator/17966] New: @defined always returns true in return probes aram.h at mgk dot ro
@ 2015-02-12 21:33 ` aram.h at mgk dot ro
2015-02-12 22:08 ` jistone at redhat dot com
1 sibling, 0 replies; 3+ messages in thread
From: aram.h at mgk dot ro @ 2015-02-12 21:33 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=17966
Aram Hăvărneanu <aram.h at mgk dot ro> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |aram.h at mgk dot ro
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug translator/17966] @defined always returns true in return probes
2015-02-12 21:32 [Bug translator/17966] New: @defined always returns true in return probes aram.h at mgk dot ro
2015-02-12 21:33 ` [Bug translator/17966] " aram.h at mgk dot ro
@ 2015-02-12 22:08 ` jistone at redhat dot com
1 sibling, 0 replies; 3+ messages in thread
From: jistone at redhat dot com @ 2015-02-12 22:08 UTC (permalink / raw)
To: systemtap
https://sourceware.org/bugzilla/show_bug.cgi?id=17966
Josh Stone <jistone at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|systemtap at sourceware dot org |jistone at redhat dot com
--- Comment #1 from Josh Stone <jistone at redhat dot com> ---
I did suggest that's what going on, but it appears more subtle when I look
closer.
If I try process("bash").function("main").return, it gets this error. I don't
have debuginfo installed for bash.
If I try process("stap").function("main").return, it works as expected. I do
have debuginfo for my local stap.
In dwarf_var_expanding_visitor::visit_target_symbol, we have:
// Everything else (pretty-printed vars, and context vars) require a
// scope_die in which to search for them. If we don't have that, just
// leave it unresolved; we'll produce an error later on.
if (null_die(scope_die))
{
provide(e);
return;
}
The case without debuginfo will hit this and return without error, leaving
@defined undecided for the moment. The case with debuginfo will get past this,
set an error on e directly, and cause @defined to be 0 right away, as desired.
So I need to figure out why the delayed case doesn't fix @defined later...
--
You are receiving this mail because:
You are the assignee for the bug.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-02-12 22:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-12 21:32 [Bug translator/17966] New: @defined always returns true in return probes aram.h at mgk dot ro
2015-02-12 21:33 ` [Bug translator/17966] " aram.h at mgk dot ro
2015-02-12 22:08 ` jistone at redhat dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).