oracle / oracle/dtrace

Optimize arg retrieval from stack

Open
#121 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
C
Stars
189
Forks
23
PR merge metrics
No merged PRs in 30d

Description

Right now we have a loop over the argN values that need to be retrieved from the stack, and retrieve them one by one, using the bpf_probe_read_kernel helper. But, since the values will be in consecutive stack slots and we are going to store them in consecutive slots in the mstate, we can simply do a larger read using a single helper call.

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

Locate the C code that loops over argN values and calls bpf_probe_read_kernel, then inspect how consecutive stack slots map to consecutive mstate slots. The work is done when the retrieval uses one larger helper read while preserving the expected argument values; no specific file or test is named in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux
Domain
operating-systems, performance
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.