tracy icon indicating copy to clipboard operation
tracy copied to clipboard

Hang when clicking on "Statistics" -> "Location" column

Open mparadinha opened this issue 9 months ago • 2 comments

Clicking on the "Location" column of any entry in the "Statistics" page (on "Sampling" mode, not sure if that has any effect) causes the profiler to hang. This happens both when profiling "live" as well as an captured "off-line" trace. Using a debug build I get a crash instead:

Tracy-debug: ../../../server/TracyTimelineItemPlot.cpp:188: tracy::TimelineItemPlot::Preprocess(const tracy::TimelineContext&, tracy::TaskDispatch&, bool, int)::<lambda()>: Assertion `next > it' failed.

Thread 21 "Render #4" received signal SIGABRT, Aborted.
[Switching to Thread 0x7fffb37fe640 (LWP 165890)]
__pthread_kill_implementation (no_tid=0, signo=6, threadid=140736204891712) at ./nptl/pthread_kill.c:44
44	./nptl/pthread_kill.c: No such file or directory.
(gdb) bt
#0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=140736204891712) at ./nptl/pthread_kill.c:44
#1  __pthread_kill_internal (signo=6, threadid=140736204891712) at ./nptl/pthread_kill.c:78
#2  __GI___pthread_kill (threadid=140736204891712, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
#3  0x00007ffff7042476 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#4  0x00007ffff70287f3 in __GI_abort () at ./stdlib/abort.c:79
#5  0x00007ffff702871b in __assert_fail_base (fmt=0x7ffff71dd150 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x5555569aec20 "next > it", 
    file=0x5555569aea38 "../../../server/TracyTimelineItemPlot.cpp", line=188, function=<optimized out>) at ./assert/assert.c:92
#6  0x00007ffff7039e96 in __GI___assert_fail (assertion=0x5555569aec20 "next > it", file=0x5555569aea38 "../../../server/TracyTimelineItemPlot.cpp", line=188, 
    function=0x5555569aebb0 "tracy::TimelineItemPlot::Preprocess(const tracy::TimelineContext&, tracy::TaskDispatch&, bool, int)::<lambda()>") at ./assert/assert.c:101
#7  0x0000555555b90ba0 in operator() (__closure=0x7fffb37fdc70) at ../../../server/TracyTimelineItemPlot.cpp:188
#8  0x0000555555b94916 in std::__invoke_impl<void, tracy::TimelineItemPlot::Preprocess(const tracy::TimelineContext&, tracy::TaskDispatch&, bool, int)::<lambda()>&>(std::__invoke_other, struct {...} &) (__f=...)
    at /usr/include/c++/11/bits/invoke.h:61
#9  0x0000555555b946e4 in std::__invoke_r<void, tracy::TimelineItemPlot::Preprocess(const tracy::TimelineContext&, tracy::TaskDispatch&, bool, int)::<lambda()>&>(struct {...} &) (__fn=...)
    at /usr/include/c++/11/bits/invoke.h:111
#10 0x0000555555b94159 in std::_Function_handler<void(), tracy::TimelineItemPlot::Preprocess(const tracy::TimelineContext&, tracy::TaskDispatch&, bool, int)::<lambda()> >::_M_invoke(const std::_Any_data &) (
    __functor=...) at /usr/include/c++/11/bits/std_function.h:290
#11 0x0000555555b66058 in std::function<void ()>::operator()() const (this=0x7fffb37fdc70) at /usr/include/c++/11/bits/std_function.h:590
#12 0x0000555555b64d13 in tracy::TaskDispatch::Worker (this=0x555557631038) at ../../../server/TracyTaskDispatch.cpp:73
#13 0x0000555555b64695 in operator() (__closure=0x555557599568) at ../../../server/TracyTaskDispatch.cpp:17
#14 0x0000555555b652a0 in std::__invoke_impl<void, tracy::TaskDispatch::TaskDispatch(size_t, char const*)::<lambda()> >(std::__invoke_other, struct {...} &&) (__f=...) at /usr/include/c++/11/bits/invoke.h:61
#15 0x0000555555b65263 in std::__invoke<tracy::TaskDispatch::TaskDispatch(size_t, char const*)::<lambda()> >(struct {...} &&) (__fn=...) at /usr/include/c++/11/bits/invoke.h:96
#16 0x0000555555b65210 in std::thread::_Invoker<std::tuple<tracy::TaskDispatch::TaskDispatch(size_t, char const*)::<lambda()> > >::_M_invoke<0>(std::_Index_tuple<0>) (this=0x555557599568)
    at /usr/include/c++/11/bits/std_thread.h:259
#17 0x0000555555b651e4 in std::thread::_Invoker<std::tuple<tracy::TaskDispatch::TaskDispatch(size_t, char const*)::<lambda()> > >::operator()(void) (this=0x555557599568)
    at /usr/include/c++/11/bits/std_thread.h:266
#18 0x0000555555b651c8 in std::thread::_State_impl<std::thread::_Invoker<std::tuple<tracy::TaskDispatch::TaskDispatch(size_t, char const*)::<lambda()> > > >::_M_run(void) (this=0x555557599560)
    at /usr/include/c++/11/bits/std_thread.h:211
#19 0x00007ffff74dc253 in ?? () from /lib/x86_64-linux-gnu/libstdc++.so.6
#20 0x00007ffff7094b43 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
#21 0x00007ffff7126a00 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
(gdb) q

Tested on master, which is at da1bc2b60eed1a217af18324e60bc5fbc334ff20 at time of writing. I can send the saved trace file or anything else if more information is needed.

mparadinha avatar Sep 30 '23 23:09 mparadinha