Commit Graph

41 Commits

Author SHA1 Message Date
5c2f4dc0a9 libsysprof-analyze: remove old series implementations 2023-06-23 22:28:10 -07:00
06767c0a1d libsysprof-analyze: add an XY series strucuture
This is meant to contain information about XY coordinates that we can
store in a normalized form. That allows them to be reused across different
scales without regenerating them.

It also includes a back-pointer to the model index so that we can pull out
the real object when necessary for drawing.
2023-06-16 16:16:44 -07:00
d752e2eec2 libsysprof-analyze: add SysprofTimeSeries
This includes a helper to generate timeseries items such as marks which
have a point in time and optionally a duration.

The TimeSpan has also been beefed up to gain a few operations that are
useful for implementing that.
2023-06-16 13:07:40 -07:00
231535a396 libsysprof-analyze: add SysprofMarkCatalog
This will get used to group marks together by group->name->marks from
the SysprofDocument.
2023-06-14 22:22:34 -07:00
643aa374cb libsysprof-analyze: add GListModel of callgraph symbols
This has an indirect object (SysprofCallgraphSymbol) so that we can provide
plumbing to get the callgraph as well as the augmented data from the
indirection object.

This allows for callgraphs to show overview in the functions list which
contains the same augmentation that the descendants view does.
2023-06-12 11:15:50 -07:00
8348f7fe2c libsysprof-analyze: start on scaffolding for callgraph API 2023-05-24 13:00:47 -07:00
d510dd50da libsysprof-analyze: add support for getting counter values 2023-05-22 16:46:36 -07:00
9d2f7d3767 libsysprof-analyze: add SysprofDocumentCtrset
This represents the SysprofCaptureCtrset and allows fetching the raw values
for a given counter. These are raw because they may not be endian swapped
and that is the responsibility of the consumer.

SysprofDocument will use these eventually to store the values for a given
counter and the time of the value shift.
2023-05-22 16:03:46 -07:00
29cfad06ec libsysprof-analyze: add counter define document frames 2023-05-22 14:12:53 -07:00
57e7377c21 libsysprof-analyze: start indexing counter defines
And add a SysprofDocumentCounter that will represent each counter. Still
to do is implementing the ctrdef type and a way to transform those into
the individual counters.
2023-05-22 13:47:32 -07:00
9e5a241fef libsysprof-analyze: add jitmap symbolizer
This symbolizes using the SysprofCaptureJitmap frames within the capture
document. Currently it only implements the fast path which can avoid a
binary search on the jitmap data.
2023-05-22 13:21:06 -07:00
1e6fc6e668 libsysprof-analyze: sort headers 2023-05-22 12:19:16 -07:00
d28080b9ad libsysprof-analyze: add SysprofDocumentJitmap
This adds a specific frame type for the Jitmap frames in the capture files.
You can iterate them without having to bswap as well, which is why this
does not use the SysprofCaptureJitmapIter (which does require bswap'd
frames).
2023-05-22 12:18:57 -07:00
12e497891f libsysprof-analyze: add SysprofDocumentOverlay
This maps to the SysprofCaptureOverlay data frames. We need them currently
to be able to locate files from various podman/toolbox rootless containers.
2023-05-19 16:51:15 -07:00
140bc1d384 libsysprof-analyze: add scaffolding for elf symbol resolver 2023-05-15 15:03:25 -07:00
00ecc41209 libsysprof-analyze: make SysprofDocumentSymbols private
This instead moves to a public API on the document to symbolize now
that we've gotten much of the necessary bits private in loading the
document. This commit ensures that we only do loading via the loader
now (and removes the incorrect use from the tests so they too go
through the loader).

We check for NoSymbolizer in document symbols so that we can skip any
decoding. That keeps various use cases fast where you don't want to
waste time on symbolizing if you don't need to look at symbols.

There is plenty more we can do to batch decode symbols with some more
API changes, but that will come after we have kernel/userland decoding
integrated from this library.

We may still want to get all symbols into a single symbol cache, but
given that we have address ranges associated with them, that may not
be very useful beyond the hashtable to pid-specific cache we have now.

If symbols were shared between processes, that'd make more sense, but
we aren't doing that (albeit strings are shared between symbol
instances to reduce that overhead).
2023-05-15 10:56:09 -07:00
0e95fd3841 libsysprof-analyze: add SysprofNoSymbolizer
A symbolizer that will never symbolize. We can use this later internally
to short-circuit various symoblization steps during loading.
2023-05-15 10:56:09 -07:00
a27f700c06 libsysprof-analyze: add scaffolding for kallsyms parsing
We will want to start embedding this content in the capture file (but
after gzipping it as it's otherwise quite large). This will get things in
place so that we can parse that .gz file into the address ranges and
decode symbols found within the capture file.
2023-05-14 18:45:03 -07:00
3350ad61eb libsysprof-analyze: introduce SysprofDocumentLoader
and thereby make a bunch of the exposed API on SysprofDocument private.
Instead we'll push some of that to the loader but for now the tests can
keep doing what their doing using the private API.

The goal here is to not expose a SysprofDocument pointer until the document
has been loaded and symbolized via the loader API. Then we can lookup
symbols directly from the document w/o intermediary objects.
2023-05-12 15:41:48 -07:00
7c37120edf libsysprof-analyze: make SysprofMount public API
And expose it via sysprof_document_process_list_mounts() so that when
inspecting processes we can see what binaries were mapped as well as what
the filesystem looked like to locate those mapped paths.
2023-05-11 14:37:02 -07:00
f914580675 libsysprof-analyze: remove process list
This is done with a GtkBitset index and so we can drop this unused list
model wrapper.
2023-05-11 13:15:28 -07:00
9fe0ae5306 libsysprof-analyze: add type to represent an embedded file
We have "chunks" within the capture file, this object will represent the
collection of those chunks which is easier for applications to deal with
if they want to view the contents.
2023-05-09 12:33:12 -07:00
235dd98621 libsysprof-analyze: add SysprofDocumentFileChunk
This object will represent frames in the list model which are file chunks.
2023-05-05 13:34:53 -07:00
354eb39676 libsysprof-analyze: add API for bundled symbolizer
This, once completed, will use __symbols__ embedded within a capture file
to decode symbols rather than querying ELF files directly.
2023-05-03 17:08:50 -07:00
976fb93a83 libsysprof-analyze: start on symbols API via document 2023-05-03 14:21:17 -07:00
f7374f3252 libsysprof-analyze: add minimal symbolizer API
This exposes the types and hierarchy but won't expose the API details that
we need internally. The idea here is that we can keep that private so we
can adjust how it is used should we need to since the public interface
would be the SysprofDocumentSymbols, not the SysprofSymbolizer which does
decoding directly via address/context state.
2023-05-03 14:16:31 -07:00
793740b20f libsysprof-analyze: add SysprofSymbol
The goal here is to get an object to represent a symbol so that we can
more easily extend things in the future. We'll still use those pointers
as unique in the stackstash in the future.
2023-05-02 13:31:22 -07:00
7a3f90e8f5 libsysprof-analyze: add process list model
This is not yet functional, but gets the scaffolding in place that we'll
use to filter out processes and turn them into something more useful such
as their execution lifetime.
2023-04-28 16:49:52 -07:00
fe4b6ee812 libsysprof-analyze: add interface for stracetrace types
Currently, this would need to be implemented by SysprofDocumentSample and
SysprofDocumentAllocation. But we could potentially start allowing many
types to attach a trace if we modifier the capture format to allow it.
2023-04-28 12:14:17 -07:00
86561c0c4f libyssprof-analyze: add document type for allocations 2023-04-28 11:44:30 -07:00
6b762ef64a libsysprof-analyze: add document type for fork 2023-04-28 10:36:17 -07:00
72c0ba731c libsysprof-analyze: add document type for metadata 2023-04-27 17:58:23 -07:00
d878fbf372 libsysprof-analyze: add document type for task exit
We don't have any extra data here currently, but it can be nice to be able
to check a gtype when consuming frames.
2023-04-27 17:50:28 -07:00
24d0d4af52 libsysprof-analyze: add document type for processes
Generally this is all the processes at startup, but can also be a process
that is executed while the capture is running. Useful to pair with an
Exit frame for pid/tid duration.
2023-04-27 17:45:04 -07:00
6031233cc3 libsysprof-analyze: add document type for marks 2023-04-27 17:22:44 -07:00
92950f4b6b libsysprof-analyze: add document type for log messages 2023-04-27 17:15:35 -07:00
c1d00db0fb libsysprof-analyze: add document type for memory maps 2023-04-27 17:00:18 -07:00
ca83cd6b40 libsysprof-analyze: add document type for samples 2023-04-25 17:10:12 -07:00
31003c519c libsysprof-analyze: rename to SysprofDocumentFrame
We will eventually be adding sub-types for the various frame types, and
use this as a common ancestor for item inflation.
2023-04-25 15:32:55 -07:00
ed01673a5e libsysprof-analyzer: rename model to SysprofDocument
This will provide better namespacing for the objects inflated from the
document for various frame types. By creating real objects with real
properties we give ourselves quite a bit of flexibility in the data
filtering language coming forth.
2023-04-25 15:26:06 -07:00
efab045006 libsysprof-analyze: start on sysprof-analyze library
The goal here is to break up libsysprof into a library for recording
profiles (using libsysprof-capture) and a library for analyzing profiles
(both used by the sysprof UI).
2023-04-25 11:57:26 -07:00