public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug translator/10299] New: mangle local variable names
@ 2009-06-18 20:59 fche at redhat dot com
  2009-06-19  0:03 ` [Bug translator/10299] " jistone at redhat dot com
  2009-06-19  2:03 ` jistone at redhat dot com
  0 siblings, 2 replies; 3+ messages in thread
From: fche at redhat dot com @ 2009-06-18 20:59 UTC (permalink / raw)
  To: systemtap

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1332 bytes --]

% stap -p4 -vv -e 'probe kernel.function("sys_open") {current = 2}' -u

fails:

/var/tmp/stapvN2tok/stap_a7fd41cd8eb3d886b2ce6c104c151d60_840.c:102: error:
function declaration isn’t a prototype
/var/tmp/stapvN2tok/stap_a7fd41cd8eb3d886b2ce6c104c151d60_840.c:102: error:
field ‘get_current’ declared as a function
/var/tmp/stapvN2tok/stap_a7fd41cd8eb3d886b2ce6c104c151d60_840.c: In function
‘probe_1751’:
/var/tmp/stapvN2tok/stap_a7fd41cd8eb3d886b2ce6c104c151d60_840.c:129: error:
lvalue required as left operand of assignment
/var/tmp/stapvN2tok/stap_a7fd41cd8eb3d886b2ce6c104c151d60_840.c:133: error:
lvalue required as left operand of assignment

Local variables in the context should be mangled similarly as we do for
globals - prefixed with l_/s_, to avoid namespace collisions with
common kernel symbols.

-- 
           Summary: mangle local variable names
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: fche at redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=10299

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug translator/10299] mangle local variable names
  2009-06-18 20:59 [Bug translator/10299] New: mangle local variable names fche at redhat dot com
@ 2009-06-19  0:03 ` jistone at redhat dot com
  2009-06-19  2:03 ` jistone at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: jistone at redhat dot com @ 2009-06-19  0:03 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From jistone at redhat dot com  2009-06-19 00:03 -------
For script-level names, we can certainly mangle however we like, but how will
this work with embedded-C functions?

  function inc:long(current:long) %{ THIS->__retvalue = THIS->current + 1; %}

Do we want to mangle that too and break the current syntax of THIS?  Or do we
make a special case that embedded functions aren't mangled?

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=10299

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug translator/10299] mangle local variable names
  2009-06-18 20:59 [Bug translator/10299] New: mangle local variable names fche at redhat dot com
  2009-06-19  0:03 ` [Bug translator/10299] " jistone at redhat dot com
@ 2009-06-19  2:03 ` jistone at redhat dot com
  1 sibling, 0 replies; 3+ messages in thread
From: jistone at redhat dot com @ 2009-06-19  2:03 UTC (permalink / raw)
  To: systemtap


------- Additional Comments From jistone at redhat dot com  2009-06-19 02:03 -------
If we decide to mangle parameters to embedded-C too, then we might want to add
ARG(foo) to PR10300.

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=10299

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-06-19  2:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-18 20:59 [Bug translator/10299] New: mangle local variable names fche at redhat dot com
2009-06-19  0:03 ` [Bug translator/10299] " jistone at redhat dot com
2009-06-19  2:03 ` 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).