Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • D dynamorio
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,467
    • Issues 1,467
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 44
    • Merge requests 44
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • DynamoRIO
  • dynamorio
  • Issues
  • #4451
Closed
Open
Issue created Sep 23, 2020 by Derek Bruening@derekbrueningContributor

drcachesim function tracing argument count can be wrong for duplicate-PC functions

drcachesim's function tracing -record_heap by default includes several operator delete functions which take different numbers of args, such as _ZdaPv with 1, _ZdaPvRKSt9nothrow_t with 2, _ZdaPvSt11align_val_t with 2, and _ZdaPvSt11align_val_tRKSt9nothrow_t with 3. Yet, on some applications these all map to a single PC, often free(), since de-allocation typically doesn't care about alignment or nothrow parameters. The tracer just takes the 1st request, in this case the 1-arg which is listed first, and uses it, recording 1 arg for that PC. But in the recorded list of what functions were traced, it still lists the other variants as having 2 or 3 args. This can cause problems in trace analyzers that expect to then find 2 or 3 args: in fact we hit this in one of our tools.

It seems best for the tracer to emit a warning about varying args for the same PC, and to then modify the arg count in the traced function list. Generally, it's best to take the last one listed to allow overriding, but here we'd prefer the first.

Assignee
Assign to
Time tracking