[Bug translator/18555] New: ppc64le: can't probe demangled C++ function names

jkenisto at us dot ibm.com sourceware-bugzilla@sourceware.org
Wed Jun 17 19:11:00 GMT 2015


https://sourceware.org/bugzilla/show_bug.cgi?id=18555

            Bug ID: 18555
           Summary: ppc64le: can't probe demangled C++ function names
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: translator
          Assignee: systemtap at sourceware dot org
          Reporter: jkenisto at us dot ibm.com
  Target Milestone: ---

I'm running stap 2.8/0.160 (built from a June 11 git snapshot) on RHEL7.1 in a
ppc64le VM.  In this configuration, stap fails the systemtap.base/cast-scope
tests.

In particular, stap seems able to probe mangled C++ function names (see ok.stp
below), but not demangled names (see bug.stp below).  I've seen this problem
with other C++ programs as well.

BTW, FWIW, a disassembly of a.out shows that the call to length() is NOT
inlined.

I don't see this problem on the same RHEL and stap versions on x86_64.

-bash-4.2# cat bug.cxx
#include <string>

size_t
length(const std::string& str)
{
    int res, r;
    r = str.length() * 2;
    res = r / 2;
    return res;
}

int
main()
{
    std::string hello = "Hello World!";
    return 12 != length(hello);
}
-bash-4.2# g++ -g bug.cxx
-bash-4.2# cat bug.stp
probe process.function("length")
{
        log("length() called")
}
-bash-4.2# stap bug.stp -c ./a.out
semantic error: while resolving probe point: identifier 'process' at
bug.stp:1:7
        source: probe process.function("length")
                      ^

semantic error: no match (similar functions: _init, main, _Z6lengthRKSs, _fini,
_start)

Pass 2: analysis failed.  [man error::pass2]
-bash-4.2# cat ok.stp
probe process.function("_Z6lengthRKSs")
{
        log("length() called")
}
-bash-4.2# stap ok.stp -c ./a.out
length() called
-bash-4.2# stap -V
Systemtap translator/driver (version 2.8/0.160, commit
release-2.7-194-g2be83613ebdc + changes)
Copyright (C) 2005-2015 Red Hat, Inc. and others
This is free software; see the source for copying conditions.
enabled features: TR1_UNORDERED_MAP NLS
-bash-4.2#

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



More information about the Systemtap mailing list