Milian Wolff [Thu, 10 Sep 2015 15:05:51 +0000 (17:05 +0200)]
Minor: move newline for readbility
Milian Wolff [Sun, 11 Oct 2015 21:40:08 +0000 (23:40 +0200)]
Increase max chart datapoints to 500.
Milian Wolff [Sun, 11 Oct 2015 16:19:05 +0000 (18:19 +0200)]
Only allocate 100 brushes for the flamegraph.
More colors are probably not discernible anyways. This way,
we can save a couple of megabytes of memory for large input
files.
Milian Wolff [Sun, 11 Oct 2015 16:09:43 +0000 (18:09 +0200)]
Use two-pass over input data to speed up chart building.
This way, we can look at the top N hotspots after the first parse,
and then quickly iterate over the file again, discarding most lines.
Only the lines for (de-)allocations must be looked at, everything
else can be reused from the first parse.
Now, we won't spend minutes/hours to create chart data, as we can
look at the explicit hotspots which we found once before. No more
costly merging or sorting of the allocation data on every timestamp.
Milian Wolff [Sun, 11 Oct 2015 14:01:52 +0000 (16:01 +0200)]
Only create one chart data per second.
This way we can run heaptrack on large data files.
In the future, this will be restructured to make it configurable.
Milian Wolff [Sun, 11 Oct 2015 13:46:58 +0000 (15:46 +0200)]
Make sure the ChartMergeData is nothrow-move-assignable.
Milian Wolff [Sun, 11 Oct 2015 13:46:42 +0000 (15:46 +0200)]
Cache ip addresses.
Milian Wolff [Sun, 11 Oct 2015 13:46:30 +0000 (15:46 +0200)]
Fix wrong assertion
Milian Wolff [Sun, 11 Oct 2015 12:28:15 +0000 (14:28 +0200)]
Disable modeltest.
I'll write a proper test soon and add the ModelTest there.
Milian Wolff [Fri, 25 Sep 2015 05:00:33 +0000 (07:00 +0200)]
Restructure test code layout, import catch and use that.
Milian Wolff [Fri, 25 Sep 2015 04:27:22 +0000 (06:27 +0200)]
Simplify CMakeLists.txt - we always use malloc now.
Milian Wolff [Fri, 25 Sep 2015 04:16:32 +0000 (06:16 +0200)]
Use malloc within libbacktrace for the usecase of heaptrack.
This library is only being used from within the external interpret
process and never from a signal handler. Only there the mmap-approach
makes sense. Using malloc instead is significantly faster and makes
using heaptrack with clang++ and debug symbols usuable.
Milian Wolff [Tue, 22 Sep 2015 07:10:06 +0000 (09:10 +0200)]
Cleanup and rename leaked in gui to consumed.
Milian Wolff [Tue, 22 Sep 2015 06:56:50 +0000 (08:56 +0200)]
Fix chart model by splitting it up by type.
Since the number of columns can be different per type
we need separate models. This finally makes the stacked
charts work properly.
Milian Wolff [Tue, 22 Sep 2015 02:22:08 +0000 (04:22 +0200)]
cleanup
Milian Wolff [Mon, 21 Sep 2015 02:28:10 +0000 (04:28 +0200)]
Deduplicate code
Milian Wolff [Mon, 21 Sep 2015 02:17:48 +0000 (04:17 +0200)]
Format tooltip cost and time.
Milian Wolff [Sat, 19 Sep 2015 06:47:21 +0000 (08:47 +0200)]
Keep the chart data associated with a constant column.
This is neccessary to have the association with a color and
later a legend label make sense.
What's left to be done now is adding some sorting on top to
have the most costly column at the bottom of the model.
Milian Wolff [Sun, 13 Sep 2015 13:46:51 +0000 (15:46 +0200)]
Merge entries for chart data and sort in descending order.
Milian Wolff [Fri, 11 Sep 2015 18:18:51 +0000 (20:18 +0200)]
Fix tooltips and show stacked graph.
Milian Wolff [Thu, 10 Sep 2015 16:02:23 +0000 (18:02 +0200)]
Use correct axis and labels in time charts.
Milian Wolff [Thu, 10 Sep 2015 15:33:39 +0000 (17:33 +0200)]
Add basic tooltip functionality for stacked time charts
Milian Wolff [Wed, 9 Sep 2015 18:41:56 +0000 (20:41 +0200)]
start with stacked time charts
Milian Wolff [Sun, 6 Sep 2015 17:37:40 +0000 (19:37 +0200)]
Use the TopDownData as input to generate the FlameGraph.
Milian Wolff [Sun, 6 Sep 2015 17:26:27 +0000 (19:26 +0200)]
Add Top-Down tree model.
Milian Wolff [Sun, 6 Sep 2015 16:20:56 +0000 (18:20 +0200)]
Also sum up peaks.
The models have no temporal notation thus if two peaks happen
at a different time, you cannot say that this is the real
peak memory consumption of a merged allocation.
But taking the absolute peak of peaks is very confusing as
then the leaked number can be less than the peak.
Milian Wolff [Sun, 6 Sep 2015 16:02:10 +0000 (18:02 +0200)]
Build tooltip ondemand which speeds initial parsing up tremendously.
We save thousands of allocations this way. And the tooltip becomes more
expressive as well. This does remove the number of allocations from the graph
iteself though, but often it's not visible there anyways and the width already
represents the same data.
Milian Wolff [Sun, 6 Sep 2015 15:41:19 +0000 (17:41 +0200)]
Don't forget selection when resizing the flamegraph widget.
Milian Wolff [Sun, 6 Sep 2015 15:37:42 +0000 (17:37 +0200)]
Cleanup the code and add some comments
Milian Wolff [Sun, 6 Sep 2015 15:20:27 +0000 (17:20 +0200)]
Merge branch 'flamegraph'
Milian Wolff [Fri, 4 Sep 2015 16:33:29 +0000 (18:33 +0200)]
Cleanup code
Milian Wolff [Fri, 4 Sep 2015 16:32:10 +0000 (18:32 +0200)]
Implement zooming as done in original FlameGraph SVG.
Maximize parent frames, hide all siblings of these parents and relayout
the children to the available parent width.
This is much better from a usability POV imo and has proven itself in
in the SVG implementation. The previous take of mine was simply too
confusing.
Milian Wolff [Fri, 4 Sep 2015 15:43:17 +0000 (17:43 +0200)]
Use mem color scheme from upstream FlameGraph.
Milian Wolff [Fri, 4 Sep 2015 15:13:38 +0000 (17:13 +0200)]
Add hover effect.
Milian Wolff [Fri, 4 Sep 2015 14:29:39 +0000 (16:29 +0200)]
Paint selected item differently.
Milian Wolff [Fri, 4 Sep 2015 14:17:57 +0000 (16:17 +0200)]
Cleanup the code a bit, use font metrics height for item height.
Milian Wolff [Fri, 4 Sep 2015 14:13:48 +0000 (16:13 +0200)]
Disable QGV BSP item indexing for the FlameGraph scene.
The data changes frequently and this would be slow when we use the BSP.
Milian Wolff [Fri, 4 Sep 2015 14:10:08 +0000 (16:10 +0200)]
Adapt the minRootWidth to the available viewport width
Milian Wolff [Fri, 4 Sep 2015 13:37:14 +0000 (15:37 +0200)]
Cleanup code and build graphics items in the background thread.
This prevents ~1s of GUI freezes on common data files.
Kevin Funk [Thu, 3 Sep 2015 09:59:56 +0000 (11:59 +0200)]
CMake: set_package_properties for KChart
Milian Wolff [Wed, 2 Sep 2015 15:09:36 +0000 (17:09 +0200)]
Bring back mouse wheel zooming.
Works fine when removing the ItemIgnoresTransformations flag,
which apparently isn't required after all.
Milian Wolff [Wed, 2 Sep 2015 15:04:13 +0000 (17:04 +0200)]
Implement click-to-zoom in FlameGraph
Milian Wolff [Wed, 2 Sep 2015 14:06:46 +0000 (16:06 +0200)]
Refactor code and use QGV parent child chain while ignoring transformations.
First steps towards custom zooming operation.
Milian Wolff [Wed, 2 Sep 2015 13:53:49 +0000 (15:53 +0200)]
Set pen externally, add total item
Milian Wolff [Wed, 2 Sep 2015 13:52:27 +0000 (15:52 +0200)]
Exclude stop indices from GUI backtraces.
Milian Wolff [Wed, 2 Sep 2015 09:45:20 +0000 (11:45 +0200)]
Use correct foreground color.
Milian Wolff [Tue, 1 Sep 2015 22:40:13 +0000 (00:40 +0200)]
Keep font size stable.
Milian Wolff [Tue, 1 Sep 2015 22:17:18 +0000 (00:17 +0200)]
Improve layouting and data generation for flame graph.
Don't count non-leaf node's cost multiple times and take the
parent cost into account when calculating the width of frame
graphics items.
Milian Wolff [Tue, 1 Sep 2015 21:39:19 +0000 (23:39 +0200)]
Build a top-down flame graph.
The layouting is still wrong, but this gives us the data at least.
Milian Wolff [Tue, 1 Sep 2015 20:37:09 +0000 (22:37 +0200)]
Merge remote-tracking branch 'origin/master' into flamegraph
Milian Wolff [Mon, 24 Aug 2015 12:52:55 +0000 (14:52 +0200)]
do not mix up peak and allocated columns
Milian Wolff [Mon, 24 Aug 2015 12:52:37 +0000 (14:52 +0200)]
Add QDebug include, for potential printf debugging needs.
Milian Wolff [Fri, 21 Aug 2015 21:49:20 +0000 (23:49 +0200)]
Add initial take on a FlameGraph based on QGraphicsView.
Many issues still, mostly due to bad scaling, i.e. we'd want
constant text size (elided if parent item is too small), and constant
item height based on text height.
Milian Wolff [Fri, 21 Aug 2015 20:59:26 +0000 (22:59 +0200)]
Remove warning about bogus translation.
Milian Wolff [Thu, 20 Aug 2015 21:09:30 +0000 (23:09 +0200)]
Make it possible to create flamegraph compatible stack files.
heaptrack_print gained the following new feature:
-F [ --print-flamegraph ] arg
Path to output file where a flame-graph compatible stack file will
be written to.
To visualize the resulting file, use flamegraph.pl from
https://github.com/brendangregg/FlameGraph:
heaptrack_print heaptrack.someapp.PID.gz -F stacks.txt
# optionally pass --reverse to flamegraph.pl
flamegraph.pl --title "heaptrack: allocations" --colors mem \
--countname allocations < stacks.txt > heaptrack.someapp.PID.svg
[firefox|chromium] heaptrack.someapp.PID.svg
Milian Wolff [Thu, 20 Aug 2015 20:49:20 +0000 (22:49 +0200)]
Increase width of help output
Milian Wolff [Mon, 10 Aug 2015 16:28:54 +0000 (18:28 +0200)]
Save memory by keeping file strings shared.
Before, we detached when we concatenated the string number, leading
to excessive memory consumption in large data files.
Milian Wolff [Mon, 10 Aug 2015 08:51:48 +0000 (10:51 +0200)]
Fix compile of test when unwind.h is in non-standard path.
Milian Wolff [Thu, 23 Jul 2015 14:50:49 +0000 (16:50 +0200)]
Fix serious regression which broke evaluation of back traces.
The data format expects hexadecimal numbers, thus output one.
Regression was introduced when I hacked in the 32bit support.
Milian Wolff [Thu, 23 Jul 2015 14:30:30 +0000 (16:30 +0200)]
Add first test to verify libunwind integration behaves sane.
Turns out that you must not build libunwind with the gold linker,
it completely breaks the stack unwinding functionality for me.
TODO: use a proper testing framework here.
Milian Wolff [Tue, 21 Jul 2015 12:01:00 +0000 (14:01 +0200)]
Don't show an error when heaptrack_gui is not in PATH.
Milian Wolff [Tue, 21 Jul 2015 11:58:21 +0000 (13:58 +0200)]
Make GUI/Chart optional.
Milian Wolff [Wed, 8 Jul 2015 16:14:06 +0000 (18:14 +0200)]
Fix 'obvious' error on 32bit for injection, still doesn't work properly.
Milian Wolff [Wed, 8 Jul 2015 16:13:49 +0000 (18:13 +0200)]
Also fix building of the gui on 32bit
Milian Wolff [Wed, 8 Jul 2015 15:47:07 +0000 (17:47 +0200)]
Always assume 64bit input data in the printer.
Otherwise, we cannot print 64bit records on 32bit machines.
Milian Wolff [Wed, 8 Jul 2015 15:38:44 +0000 (17:38 +0200)]
Fix compile warnings on 32bit
Milian Wolff [Fri, 3 Jul 2015 07:57:35 +0000 (09:57 +0200)]
Use ki18n_wrap_ui
Milian Wolff [Fri, 3 Jul 2015 07:56:38 +0000 (09:56 +0200)]
Set application domain for translations
Milian Wolff [Fri, 3 Jul 2015 07:56:20 +0000 (09:56 +0200)]
Show a window when no files are given.
Milian Wolff [Thu, 2 Jul 2015 21:18:41 +0000 (23:18 +0200)]
Properly link against zlib where required.
Milian Wolff [Thu, 2 Jul 2015 21:17:36 +0000 (23:17 +0200)]
Remove wrong assert.
Yuri Chornoivan [Tue, 23 Jun 2015 16:36:31 +0000 (19:36 +0300)]
Get rid of c-formatting message with %1s
Milian Wolff [Mon, 22 Jun 2015 22:03:25 +0000 (00:03 +0200)]
Add Messages.sh for gettext extraction.
Milian Wolff [Mon, 15 Jun 2015 23:59:11 +0000 (01:59 +0200)]
Properly use max-or-last leaked data value.
Milian Wolff [Mon, 15 Jun 2015 23:41:18 +0000 (01:41 +0200)]
Include 0 as first chart datapoint.
Milian Wolff [Mon, 15 Jun 2015 23:40:22 +0000 (01:40 +0200)]
advertise heaptrack_gui
Milian Wolff [Mon, 15 Jun 2015 23:37:37 +0000 (01:37 +0200)]
Also show total bytes allocated over time.
Milian Wolff [Mon, 15 Jun 2015 23:32:11 +0000 (01:32 +0200)]
Also show total number of allocations over time.
Milian Wolff [Mon, 15 Jun 2015 23:12:20 +0000 (01:12 +0200)]
Show total leaked data in graph.
Milian Wolff [Mon, 15 Jun 2015 22:14:09 +0000 (00:14 +0200)]
Prepare for addition of more visualizations.
Refactors loading of files into its own class and cleans up the
implementation of the (bottom-up) model.
Milian Wolff [Mon, 15 Jun 2015 21:29:31 +0000 (23:29 +0200)]
Add about data, enable loading of multiple files.
Milian Wolff [Mon, 15 Jun 2015 21:03:37 +0000 (23:03 +0200)]
Group disabling of stdio locking code.
Milian Wolff [Mon, 15 Jun 2015 20:58:06 +0000 (22:58 +0200)]
Use binary search in TraceTree.
Milian Wolff [Mon, 15 Jun 2015 20:48:34 +0000 (22:48 +0200)]
Rename function - it's not a dlopen callback, but a dl_iterate_phdr one.
Milian Wolff [Mon, 15 Jun 2015 20:42:41 +0000 (22:42 +0200)]
Two more coments
Milian Wolff [Mon, 15 Jun 2015 20:28:21 +0000 (22:28 +0200)]
Merge branch 'gui'
Milian Wolff [Mon, 15 Jun 2015 20:26:07 +0000 (22:26 +0200)]
Run more stuff in parallel.
Milian Wolff [Mon, 15 Jun 2015 19:46:36 +0000 (21:46 +0200)]
Add tooltip to header
Milian Wolff [Mon, 15 Jun 2015 19:46:28 +0000 (21:46 +0200)]
Merge location columns.
Milian Wolff [Mon, 15 Jun 2015 19:37:07 +0000 (21:37 +0200)]
Make filter case insensitive
Milian Wolff [Mon, 15 Jun 2015 19:27:03 +0000 (21:27 +0200)]
Show debuggee command line in heaptrack_gui
Milian Wolff [Mon, 15 Jun 2015 19:11:55 +0000 (21:11 +0200)]
Make heaptrack more compatible with other debug tools.
Ignore any '--' parameter.
Milian Wolff [Mon, 15 Jun 2015 19:11:06 +0000 (21:11 +0200)]
Skip one more level in backtraces in debug builds.
Otherwise, the malloc function would still be shown in the backtrace
and thereby breaking the aggregation we use elsewhere.
Milian Wolff [Fri, 12 Jun 2015 13:37:38 +0000 (15:37 +0200)]
Translate summary.
Milian Wolff [Fri, 12 Jun 2015 13:27:42 +0000 (15:27 +0200)]
Show full merged backtraces in heaptrack_gui.
Milian Wolff [Sun, 7 Jun 2015 18:50:21 +0000 (20:50 +0200)]
use KFormat for byte formatting in Qt model implementation.
Milian Wolff [Sun, 7 Jun 2015 18:27:09 +0000 (20:27 +0200)]
Copy the massif-visualizer GUI pattern with open/load/result pages.
Also load the data in a background thread with ThreadWeaver.
Milian Wolff [Sun, 7 Jun 2015 18:23:59 +0000 (20:23 +0200)]
Fix style and fix early-return check for Model::data()
Milian Wolff [Sun, 7 Jun 2015 16:59:07 +0000 (18:59 +0200)]
Make it possible to filter by function, module and file info.
Milian Wolff [Sun, 7 Jun 2015 16:47:02 +0000 (18:47 +0200)]
Allow filtering by file/module as well.