bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gprofng/30194] New: [collect app] Investigate occurrences of <stati


From: ruud.vanderpas at oracle dot com
Subject: [Bug gprofng/30194] New: [collect app] Investigate occurrences of <static>@PC from a shared library
Date: Fri, 03 Mar 2023 11:03:42 +0000

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

            Bug ID: 30194
           Summary: [collect app] Investigate occurrences of <static>@PC
                    from a shared library
           Product: binutils
           Version: 2.40
            Status: NEW
          Severity: normal
          Priority: P2
         Component: gprofng
          Assignee: vladimir.mezentsev at oracle dot com
          Reporter: ruud.vanderpas at oracle dot com
  Target Milestone: ---

While gprofng lists <static>@PC for several functions in shared libraries, perf
seems to be able to resolve the function name.

This was reported by a user who has been using gprofng on Ubuntu. Below are the
function views as shown by gprofng and perf.

For example, __strncmp_sse42 shows up in the perf output, but gprofng reports
this as <static>@0x1711f1 (<libc.so.6>).

It will be good to investigate where this difference comes from and whether
gprofng can be improved to resolve the function name(s).

This is what gprofng display text shows:

Excl. Total   Incl. Total    Name
CPU           CPU
sec.      %   sec.      %
0.690 100.00  0.690 100.00   <Total>
0.140  20.29  0.490  71.01  
ada::parser::parse_url(std::basic_string_view<char, std::char_traits<char> >,
ada::url const*, ada::encoding_type)
0.130  18.84  0.130  18.84   <static>@0x1711f1 (<libc.so.6>)
0.050   7.25  0.510  73.91   ada::parse(std::basic_string_view<char,
std::char_traits<char> >, ada::url const*, ada::encoding_type)
0.050   7.25  0.650  94.20   void BasicBench_AdaURL<false>(benchmark::State&)
0.040   5.80  0.040   5.80   ada::unicode::to_lower_ascii(char*, unsigned long)
[clone .isra.0]
0.040   5.80  0.040   5.80   malloc
0.030   4.35  0.030   4.35   ioctl
0.030   4.35  0.070  10.14   operator new(unsigned long)
0.030   4.35  0.090  13.04   std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >::_M_append(char const*, unsigned
long)
0.030   4.35  0.030   4.35   std::basic_string_view<char,
std::char_traits<char> >::substr(unsigned long, unsigned long) const
0.020   2.90  0.020   2.90   <static>@0x9dcd3 (<libc.so.6>)
0.020   2.90  0.040   5.80   free
0.010   1.45  0.010   1.45   <static>@0x7a30 (<bbc_bench>)
0.010   1.45  0.010   1.45   <static>@0x9e160 (<libstdc++.so.6.0.30>)
0.010   1.45  0.010   1.45  
ada::checkers::has_hex_prefix(std::basic_string_view<char,
std::char_traits<char> >)
0.010   1.45  0.010   1.45   ada::url::~url()
0.010   1.45  0.010   1.45   bool std::all_of<char const*, bool (*)(char)
noexcept>(char const*, char const*, bool (*)(char) noexcept)
...

This is what perf reports (perf record/perf report):

Samples: 28K of event 'cycles:u', Event count (approx.): 23444784147
Overhead  Command    Shared Object         Symbol
  29.08%  bbc_bench  bbc_bench             [.] ada::parser::parse_url
  10.71%  bbc_bench  libc.so.6             [.] __strncmp_sse42
   9.16%  bbc_bench  bbc_bench             [.] BasicBench_AdaURL<false>
   5.69%  bbc_bench  libc.so.6             [.] ____wcstold_l_internal
   5.55%  bbc_bench  libc.so.6             [.] __strncasecmp_l_sse42
   3.66%  bbc_bench  bbc_bench             [.] ada::parse
   3.62%  bbc_bench  libstdc++.so.6.0.30   [.] std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >::push_back
   3.31%  bbc_bench  bbc_bench             [.] std::basic_string_view<char,
std::char_traits<char> >::substr
   3.00%  bbc_bench  libstdc++.so.6.0.30   [.] std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >::_M_mutate
   2.83%  bbc_bench  bbc_bench             [.] ada::unicode::to_lower_ascii
   2.79%  bbc_bench  libc.so.6             [.] ____wcstod_l_internal
   2.64%  bbc_bench  libstdc++.so.6.0.30   [.] std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >::_M_append
   2.59%  bbc_bench  bbc_bench             [.] std::basic_string_view<char,
std::char_traits<char> >::find
   2.31%  bbc_bench  bbc_bench             [.] ada::url::~url
   2.26%  bbc_bench  libstdc++.so.6.0.30   [.] std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >::_M_create
   1.05%  bbc_bench  libstdc++.so.6.0.30   [.] operator new
   0.91%  bbc_bench  bbc_bench             [.] standard_url::~standard_url

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]