Commit Graph

11 Commits

Author SHA1 Message Date
13e1ace8dc libsysprof-profile: flush events when disabling 2023-06-09 17:25:57 -07:00
e8293edd54 libsysprof-profile: only create fdlist when necessary 2023-06-09 16:35:04 -07:00
283da1e107 libsysprof-profile: fix flags type
So we can pass it right through.
2023-06-09 16:34:49 -07:00
4f4f3145c1 libsysprof-profile: backoff perf GSource when possible
We have a fairly large buffer for perf events, so we should be able to
process these much less frequently to help reduce the process performing
the profile from showing up in the profiling results.
2023-06-04 13:28:35 -07:00
13b76f7de6 libsysprof-profile: make timeout msec tweakable
We may want to tweak this as we discover we can either backoff or
increase our timing intervals.
2023-06-04 12:35:04 -07:00
a3c235a316 libsysprof-profile: don't use FD to drive perf source
It is not enough to get writability, as that wont trigger on the perf
source. Instead, we need to check the mmap'd header and drive things off
of that.

It might be nice to eventually determine how many of the samples are from
our own process and back-off our timeout based on that.
2023-06-04 10:20:34 -07:00
8138ab49c3 libsysprof-profile: always continue the source 2023-06-04 00:04:52 -07:00
a6ca0eb2d7 libsysprof-profile: setup mmap for perf mapping 2023-06-04 00:02:58 -07:00
5b5916bdcd libsysprof-profiler: convert perf event attr to variant 2023-06-03 23:53:38 -07:00
ece30b52b1 libsysprof-profile: fix GDBusConnection usage 2023-06-03 23:13:12 -07:00
25d629beb4 libsysprof-profile: start on perf event stream
This is a bit different than how we did things previously, but the same
mechanics are involved. Instead of multiple CPU registered together, we'll
just use one-stream-per-cpu.

Partly because I intend to drop support for profiling a single process as
that doesn't really get used much nor does it seem to yield very good
results from perf.
2023-06-03 21:28:22 -07:00