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
  • Merge requests
  • !5854

i#5845: Fix format string type for drcov bb count

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Derek Bruening requested to merge i5845-drcov-x64 into master Feb 05, 2023
  • Overview 3
  • Commits 2
  • Pipelines 0
  • Changes 1

The drcov bb count was being printed as a 32-bit integer but passed a 64-bit value for x64/aarch64 builds. We fix that here to pass a 32-bit value with an overflow check (we do not support >4G blocks in drcov's post-processing today).

Unfortunately there is not a simple way to make a test. I experimented and actually failed to get the original bug to cause any visible problem even with subsequent specifiers in that same format string, with today's va_list accessors. Making a test of millions or billions of blocks is non-trivial: the easiest way is to dynamically generate the code, but that is not a great test for drcov in general where we want source lines to map back to; plus it will take a while to run which is not great in the CI suite.

Fixes #5845 (closed)

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: i5845-drcov-x64