DynamoRIO / DynamoRIO/dynamorio

Add new instrumentation insertion event(s) for observing original instruction stream, hiding expansions and emulations

Open
#4,947 0 comments 0 reactions 0 assignees View on GitHub
Component-API Type-Feature Usability
Dominant language
C
Stars
3.2k
Forks
629
Avg merge
2d 15h
Merged PRs (30d)
31

Description

With expansions for rep strings and scatter gather, and with emulation of other instructions, we've added an emulation API for a tool to view the original instruction stream rather than the messy expanded to-be-executed instruction list passed to the drmgr insertion event. It would be cleaner to have an instrumentation insertion event that is passed just the original instruction stream, hiding the expansions directly, rather than a tool having to separately query for the original code. That was proposed in #4865 but we balked at implementing it at that time: see https://github.com/DynamoRIO/dynamorio/issues/4865#issuecomment-861030167 for a two-event proposal.

This issue covers revisiting that idea. There are several complexities:
+ Would we try to replace the existing insertion event in all end tools? If not, would we then add new event support to wrappers such as drbbdup which call their own insertion events? If so, would we just have a big compatibility break? And we'd leave the to-be-executed instrlist event only for libraries like drreg?
+ Would we have versions that do not support expanded operands, or would we go with the two-event scheme from https://github.com/DynamoRIO/dynamorio/issues/4865#issuecomment-861030167?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.