public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug translator/13315] New: @cast() should also accept an object file to extract typedie info
@ 2011-10-18 14:00 fche at redhat dot com
  2011-10-18 14:03 ` [Bug translator/13315] " rrakus at fedoraproject dot org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: fche at redhat dot com @ 2011-10-18 14:00 UTC (permalink / raw)
  To: systemtap

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

             Bug #: 13315
           Summary: @cast() should also accept an object file to extract
                    typedie info
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
        AssignedTo: systemtap@sourceware.org
        ReportedBy: fche@redhat.com
    Classification: Unclassified


The translator supports a couple of syntaxes to generate/find debuginfo
for @cast expressions.  One that's missing is

    @cast(value,"typename","/path/to/object/file")

where said file is to be used directly as a source of elf/dwarf, rather
than interpreted as a header.  For example:

% cat foo.c
#include <stdlib.h>
struct foo { int bar; int zoo; };
void main ()
{ 
  struct foo* bar = malloc(sizeof (struct foo));
}
% gcc -g -c foo.c
% ls -al foo.o
% readelf -w foo.o | less  # to inspect struct foo decl is indeed there
% stap -p4 -e 'probe begin { println(@cast(0,"foo","./foo.o")->bar) }'
semantic error: type definition 'foo' not found: identifier '@cast' at
<input>:1:23
        source: probe begin { println(@cast(0,"foo","./foo.o")->bar) }
                                      ^
oops

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

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

end of thread, other threads:[~2016-05-19 14:50 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-18 14:00 [Bug translator/13315] New: @cast() should also accept an object file to extract typedie info fche at redhat dot com
2011-10-18 14:03 ` [Bug translator/13315] " rrakus at fedoraproject dot org
2011-10-18 18:44 ` jistone at redhat dot com
2011-10-22 13:55 ` rrakus at fedoraproject dot org
2011-10-22 16:37 ` rrakus at fedoraproject dot org
2011-10-22 20:39 ` jistone at redhat dot com
2016-05-16 15:17 ` [Bug core/13315] " gobisha6355 at gmail dot com
2016-05-16 15:21 ` [Bug translator/13315] " fche at redhat dot com
2016-05-19 14:50 ` fche 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).