Commit Graph

652 Commits

Author SHA1 Message Date
653ff6ba9e build: add datadir to pkgconfig files
Mutter wants sysprof's exact dbus interface directory during build time
* https://gitlab.gnome.org/GNOME/mutter/blob/master/src/meson.build#L714

On certain platforms mutter's datadir != sysprof's datadir.
This is initial work for a forthcoming PR to do
```
sysprof_dep.get_pkgconfig_variable('datadir')
```
in mutter for compatibility with these platforms.

This patch is on behalf of nixpkgs where we actually have to carry a 
downstream patch [0] for this exact reason. We install everything into 
their own immutable prefix under `/nix/store`.

[0]: a821167046/pkgs/desktops/gnome-3/core/mutter/0001-build-use-get_pkgconfig_variable-for-sysprof-dbusdir.patch
2019-12-04 17:17:58 -05:00
6584fcd286 Fix org.gtk.GDBus.C.UnixFD annotations
The annotation applies to the method as a whole, not to individual
arguments, so the existing annotations don't have any effect.

This was hidden by gdbus-codegen's automatic handling of arguments
of type 'h', but that change was reverted, resulting in a broken
build.
2019-10-31 17:10:48 +01:00
b624ec8809 build: track changes to GLib and gdbus-codegen
GLib is already doing this, which broke a number of auto-generated code.
This tracks those changes and manually sets the annotations so that we
are guaranteed to get this behavior.

We'll need to fix other uses (such as in Mutter), but we have to do that
already because of the change in GLib.

Fixes #17
2019-10-30 14:46:20 -07:00
73dc39329a libsysprof-ui: avoid use of environ for -Werror=shadow
Fixes #18
2019-10-21 11:35:42 -07:00
189505be64 build: only install some files when option is enabled
Fixes #16
2019-10-15 14:49:57 -07:00
1d445c4fad sysprof-ui: add missing filtering of processes
The search implementation here is pretty barebones, but at least it gets
things working again after the fallout from the redesign.

Fixes #15
2019-10-07 12:57:50 -07:00
a2f99c7be5 build: set NO_AT_BRIDGE=1 when running automated tests 2019-09-09 17:58:17 -07:00
753a698563 tools: add --rapl to sysprof-cli command
This allows recording energy statistics using turbostat if supported by
the host system.
2019-08-08 16:12:26 -07:00
0716e23fb4 libsysprof-capture: use GDateTime instead of GTimeVal 2019-08-08 16:08:00 -07:00
201a2f2162 tests: add jitmap symbol resolver 2019-08-03 15:44:57 -07:00
5d26daf009 tests: fix 32-bit build for %lx usage 2019-08-03 15:44:48 -07:00
1c90e3da80 libsysprof: remove symbol-dirs
This is automatically done for the cases we care about, so this can be
removed now (in favor of tuning the elf symbol resolver manually).
2019-08-03 01:03:59 -07:00
3b17e65a39 libsysprof: attach symbol directories to ELF resolver
The goal here is to drop the sysprof-symbol-dirs.[ch] altogether in
favor of modifying the resolver directories on the particular resolver
directly.
2019-08-02 19:41:26 -07:00
3b7a253c57 flatpak: add symbol dirs on host 2019-08-02 19:39:28 -07:00
066b3011bb tests: add helper to test symbol resolving 2019-08-02 19:39:20 -07:00
1ff88caa89 flatpak: peek via host access 2019-08-02 18:56:48 -07:00
aad61d52f3 flatpak: add helpers to locate flatpak installation debug dirs
The goal here is to be able to locate all of the debug directories for
active flatpak runtimes so that we can possibly decode debug libraries
from them (after verifying build-id/CRC).
2019-08-02 18:15:02 -07:00
0c3f2df42b libsysprof: improve decoding a bit from flatpak 2019-08-02 13:22:03 -07:00
ba725d1599 libsysprof: use mountinfo helper for path translations 2019-08-02 13:10:28 -07:00
96dbd07c82 libsysprof: whitespace cleanup 2019-08-02 12:56:57 -07:00
7e7657dd03 libsysprof: add mountinfo helper
The goal of this helper is to simplify the process of parsing information
about mounts and the mountinfo for per-process maps. We should be able
to change sysprof-proc-source to use this and have better support for
getting the libraries within different mount namespaces.
2019-08-02 12:56:54 -07:00
1cb182d1df tools: fix local usage for no_battery 2019-08-02 11:01:13 -07:00
dbfa6c811b libsysprof-ui: track how many counters matched 2019-08-02 10:59:08 -07:00
5fa8c2dd1a rapl: check for > 0 counters 2019-08-01 18:01:39 -07:00
949c75e0f4 libsysprof-ui: soften the shadows a bit 2019-08-01 00:48:25 -07:00
6295b28816 ticks: tweak background style for ticks 2019-08-01 00:30:16 -07:00
2d6906b542 ticks: don't draw final layout if there isn't space
This just helps keep things from geting cut off.
2019-08-01 00:26:02 -07:00
2d69a5ff1c libsysprof-ui: simplify sizing of positioning in visualizers
This simplifies the visualizer sizing by avoiding the expanding sizes
when there is more space available. Doing so allows us to treat all the
sizing uniformly.

We can also make the ticks area a visualizer for more code re-use.
2019-08-01 00:20:31 -07:00
21643c71bf marks: tweak ellipsize to avoid resizes 2019-08-01 00:16:11 -07:00
52e587a0cb libsysprof-ui: use nsec constant 2019-07-31 16:09:49 -07:00
130a283abe rapl: use "Watts" for line displays 2019-07-31 15:55:32 -07:00
12866c4e15 libsysprof-ui: add units display for line graphs 2019-07-31 15:55:19 -07:00
98fd2fe35d rapl: add counters for additonal core/cpu pairs 2019-07-31 15:25:41 -07:00
8712067b8e rapl: add new aid for the RAPL profiler 2019-07-31 15:05:10 -07:00
5ff150d365 turbostat: remove prctl
This won't be reliable since our handlers are run on threads.
2019-07-31 13:20:05 -07:00
f9f7e29e54 turbostat: use kill() to force sample by turbostat
This is more reliable than using a PTY and allows us to use a regular
pipe to output data into a GIOChannel. This also changes the design to
use async IO watches for sample delivery.
2019-07-31 13:08:42 -07:00
fc013fe99f libsysprof-capture: reset reader before catting into dest 2019-07-31 13:07:41 -07:00
959261919d libsysprof-ui: add source for energy stats 2019-07-30 15:52:02 -07:00
a3d0ddc231 sysprofd: add RAPL profiler on the org.gnome.Sysprof3 D-Bus peer
This allows consumers to get a RAPL profiler object on the D-Bus at
org.gnome.Sysprof3 with path /org/gnome/Sysprof3/RAPL. This can be used
by the clients to record extra power statistics.

It requires the `turbostat` program to be installed, and is provided in
packages such as `kernel-tools` on Fedora. Distributions may want to
ensure that is available as a dependency of Sysprof, but it is not
strictly required.
2019-07-30 15:29:43 -07:00
41f8565a25 tools: fix type for profiler-ctl 2019-07-30 15:17:47 -07:00
b8898fceea service: remove unnecessary code
This is fixed in glib now.
2019-07-30 15:17:32 -07:00
0378b0727b scrollmap: tweak box generation a bit for safety 2019-07-30 15:17:16 -07:00
8c72bafff8 tools: set cwd when spawning with sysprof-cli 2019-07-28 12:32:49 -07:00
745f4c4168 tools: add --gtk option for GTK_TRACE_FD= envvar 2019-07-20 18:38:24 -07:00
c2728b8ada cleanup: remove duplicated NSEC_PER_SEC macros
This switches everything to using a single 64-bit constant for NSEC_PER_SEC
that ensure we're doing 64-bit math everywhere.
2019-07-18 10:22:46 -07:00
6987888349 sysprof: include locale.h
setlocale and LC_ALL requires this
2019-07-17 14:59:42 +05:30
1c1301c0ba sysprof: setup gettext in main 2019-07-13 15:04:11 -07:00
bb5261bc32 tools: setup translations for sysprof-cli 2019-07-13 15:01:59 -07:00
6a331f44f4 tools: add -- option instead of -c
This adds the common convention for applications that receive command
line arguments to use [-- COMMAND ARGS] instead of "-c" which is rather
limiting for shell expansion.

Fixes #10
2019-07-13 15:01:47 -07:00
ce7b11695f build: fix some 32-bit build issues 2019-07-02 17:00:44 -07:00