News for hackers. Stuff that matters.
Re:GDB Debugging Full Example: Ncurses by brendangregg on Tuesday August 09, 2016 @07:04PM (#12258313)
I've been meaning to. I took a quick look now:

  # rr record date
  rr: Saving the execution of `date' to trace directory `/root/.local/share/rr/date-30'.
  [FATAL /build/rr-jR8ti5/rr-4.1.0/src/PerfCounters.cc:195:start_counter() errno: 2 'No such file or directory'] 
   -> Unable to open performance counter with 'perf_event_open'; are perf events enabled? Try 'perf record'.
  Aborted
oh-oh...

  # gdb `which rr`
  [...]
  (gdb) r record date
  Starting program: /usr/bin/rr record date
  [...]
  [FATAL /build/rr-jR8ti5/rr-4.1.0/src/PerfCounters.cc:195:start_counter() errno: 2 'No such file or directory'] 
   -> Unable to open performance counter with 'perf_event_open'; are perf events enabled? Try 'perf record'.
  Thread 1 "rr" received signal SIGABRT, Aborted.
  0x00007ffff6d6b418 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
  54	../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
  (gdb) bt
  #0  0x00007ffff6d6b418 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
  #1  0x00007ffff6d6d01a in __GI_abort () at abort.c:89
  #2  0x00000000005a9133 in FatalOstream::~FatalOstream() ()
  #3  0x00000000006303fc in ?? ()
  #4  0x0000000000630679 in PerfCounters::reset(long) ()
  #5  0x00000000006cbd8f in Task::resume_execution(ResumeRequest, WaitRequest, TicksRequest, int) ()
  #6  0x0000000000638be9 in RecordSession::task_continue(Task*, RecordSession::StepState const&) ()
  #7  0x000000000063d70e in RecordSession::record_step() ()
  #8  0x00000000006354b6 in ?? ()
  #9  0x00000000006356f2 in RecordCommand::run(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&) ()
  #10 0x000000000061f44d in main ()
I did a bit more gdb debugging (one debugger debugging another, although it's a bit hard as rr is stripped and doesn't have a debuginfo package!), and it looks like it's trying to use PMCs.

No PMCs here: EC2 Xen guest. So rr won't work, for me or EC2's 1+ million other customers. Perhaps rr can switch to software events?

There are no comments on this comment yet.