rr-debugger / rr-debugger/rr

`info proc` doesn't work on replays

Open
#3,328 2 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
10.7k
Forks
662
Avg merge
2d 3h
Merged PRs (30d)
2

Description

info proc mappings works fine, but the other parts of info proc, also requested in #1834, does not.

I've just rechecked: using "plain gdbserver + gdb" this works fine, a way to have this working in rr would be:

  • include in trace and symlink similar to the proc mappings
    • /proc/$pid/cmdline
    • /proc/$pid/cwd
    • /proc/$pid/exe
  • otherwise interrupt the calls from GDB requesting those (the remote GDB shows those from the inferior, so has to ask gdbserver for that)

If for some reason those cannot be intercepted, then a new command rr-info proc could show them.

Originally posted by @GitMensch in https://github.com/rr-debugger/rr/issues/2032#issuecomment-879091625

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the existing handling for /proc/$pid/maps and the info proc entry point, then compare how GDB requests the other proc values during replay. Done means info proc can report mappings, cmdline, cwd, and exe for replays, or a documented rr-info proc alternative is provided.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, linux
Domain
devtools, operating-systems
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.