DynamoRIO / DynamoRIO/dynamorio

Empty clean call leads to memory leak

Open
#4,999 1 comment 0 reactions 0 assignees View on GitHub
Bug-ResourceLeak OpSys-x86
Dominant language
C
Stars
3.2k
Forks
629
Avg merge
2d 18h
Merged PRs (30d)
30

Description

Instrumenting an empty clean call (without any instrs) using
```
dr_insert_clean_call(drcontext, bb, inst, (void *)empty_clean_call, false, 0);
```
leads to a memory leak on x86.

Discovered this while working on a PR, will add a link when I push it.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the leak on x86 with the empty dr_insert_clean_call invocation shown in the issue, using empty_clean_call as the callback. Trace the clean-call insertion and cleanup paths to identify the allocation that remains live; done means the empty call no longer leaks memory.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
devtools, performance
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.