public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug dyninst/21463] New: stap -t --dyninst fails un-cleanly
@ 2017-05-05 21:36 serhei.public at gmail dot com
  2017-05-13 12:25 ` [Bug dyninst/21463] " scox at redhat dot com
  0 siblings, 1 reply; 2+ messages in thread
From: serhei.public at gmail dot com @ 2017-05-05 21:36 UTC (permalink / raw)
  To: systemtap

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

            Bug ID: 21463
           Summary: stap -t --dyninst fails un-cleanly
           Product: systemtap
           Version: unspecified
            Status: UNCONFIRMED
          Severity: minor
          Priority: P2
         Component: dyninst
          Assignee: systemtap at sourceware dot org
          Reporter: serhei.public at gmail dot com
  Target Milestone: ---

Encountered this while trying to get some timing info on behaviour of uprobes
vs dyninst function probes, on both git HEAD and release 3.1 (from RPM).

$ stap -t --dyninst -ve 'global counter = 0; probe process.function("*").call {
counter++ } probe end { printf("%d calls\n", counter) }' -c ls

fails to compile the generated client with the following errors:

Pass 1: parsed user script and 61 library scripts using
214144virt/14336res/7540shr/6776data kb, in 40usr/0sys/51real ms.
Pass 2: analyzed script: 262 probes, 0 functions, 0 embeds, 1 global using
217396virt/18552res/8460shr/10028data kb, in 20usr/0sys/23real ms.
Pass 3: translated to C into
"/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c" using
217396virt/18816res/8708shr/10028data kb, in 20usr/140sys/166real ms.
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c: In function
‘probe_706’:
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c:142:7: error:
unknown field ‘contention’ specified in initializer
       .contention = global_contended(s___global_counter),
       ^
In file included from /usr/share/systemtap/runtime/common_session_state.h:16:0,
                 from
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c:107:
/usr/share/systemtap/runtime/dyninst/common_session_state.h:169:33: error:
initialization from incompatible pointer type
[-Werror=incompatible-pointer-types]
 #define global_contended(name)  (&_global_raw(name ## _lock_contention_count))
                                 ^
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c:142:21: note:
in expansion of macro ‘global_contended’
       .contention = global_contended(s___global_counter),
                     ^~~~~~~~~~~~~~~~
/usr/share/systemtap/runtime/dyninst/common_session_state.h:169:33: note: (near
initialization for ‘locks[0].lock’)
 #define global_contended(name)  (&_global_raw(name ## _lock_contention_count))
                                 ^
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c:142:21: note:
in expansion of macro ‘global_contended’
       .contention = global_contended(s___global_counter),
                     ^~~~~~~~~~~~~~~~
/usr/share/systemtap/runtime/dyninst/common_session_state.h:169:33: error:
initialized field with side-effects overwritten
[-Werror=override-init-side-effects]
 #define global_contended(name)  (&_global_raw(name ## _lock_contention_count))
                                 ^
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c:142:21: note:
in expansion of macro ‘global_contended’
       .contention = global_contended(s___global_counter),
                     ^~~~~~~~~~~~~~~~
/usr/share/systemtap/runtime/dyninst/common_session_state.h:169:33: note: (near
initialization for ‘locks[0].lock’)
 #define global_contended(name)  (&_global_raw(name ## _lock_contention_count))
                                 ^
/tmp/stapQDAbpX/stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002_src.c:142:21: note:
in expansion of macro ‘global_contended’
       .contention = global_contended(s___global_counter),
                     ^~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
WARNING: gcc exited with status: 1
Pass 4: compiled C into "stap_51a8b3ab2742c8ba3d6729c1e3f31320_54002.so" in
110usr/10sys/139real ms.
Pass 4: compilation failed.  [man error::pass4]

For the record:

$ stap --version
Systemtap translator/driver (version 3.1/0.168, rpm 3.1-2.fc25)
Copyright (C) 2005-2017 Red Hat, Inc. and others
This is free software; see the source for copying conditions.
tested kernel versions: 2.6.18 ... 4.10-rc8
enabled features: AVAHI BOOST_STRING_REF DYNINST JAVA PYTHON2 PYTHON3 LIBRPM
LIBSQLITE3 LIBVIRT LIBXML2 NLS NSS READLINE

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

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

* [Bug dyninst/21463] stap -t --dyninst fails un-cleanly
  2017-05-05 21:36 [Bug dyninst/21463] New: stap -t --dyninst fails un-cleanly serhei.public at gmail dot com
@ 2017-05-13 12:25 ` scox at redhat dot com
  0 siblings, 0 replies; 2+ messages in thread
From: scox at redhat dot com @ 2017-05-13 12:25 UTC (permalink / raw)
  To: systemtap

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

Stan Cox <scox at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
                 CC|                            |scox at redhat dot com
         Resolution|---                         |FIXED
           Assignee|systemtap at sourceware dot org    |scox at redhat dot com

--- Comment #1 from Stan Cox <scox at redhat dot com> ---
commit 4296b40
Add the linux probe_lock.h contention change to dyninst

Intereesting comparison, e.g. uprobes vs dyninst:
queue_directory  572min/572avg/572max,  92min/92avg/92max,

(A few of the uprobes do not get set by dyninst; e.g. register_tm_clones.)

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

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

end of thread, other threads:[~2017-05-13 12:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-05 21:36 [Bug dyninst/21463] New: stap -t --dyninst fails un-cleanly serhei.public at gmail dot com
2017-05-13 12:25 ` [Bug dyninst/21463] " scox 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).