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
  • #4399
Closed
Open
Issue created Aug 09, 2020 by John F.X. Galea@johnfxgaleaContributor

Add new ASSERT that only activates in debug builds.

This a feature request to make a version of DR_ASSERT that automatically turns void during release builds.

Currently, DR_ASSERT and DR_ASSERT_MSG cannot be easily turned off for release builds. Unlike for <assert.h>, there is no "NDEBUG" version that turns DR asserts off. Therefore, a lot of code, particularly DR extensions, repeatedly resort to defining a new version of ASSERT to resolve the issue:

#ifdef DEBUG
#    define ASSERT(x, msg) DR_ASSERT_MSG(x, msg)
#else
#    define ASSERT(x, msg)
#endif

Add DR_ASSERT_DEBUG that is controllable with respect to the DEBUG def.

Assignee
Assign to
Time tracking