Skip to content

Add debug option to specify MALLOC_ARENA_MAX#108

Merged
jbachorik merged 2 commits into
mainfrom
jb/debug_malloc_arena_max
Jun 20, 2024
Merged

Add debug option to specify MALLOC_ARENA_MAX#108
jbachorik merged 2 commits into
mainfrom
jb/debug_malloc_arena_max

Conversation

@jbachorik
Copy link
Copy Markdown
Collaborator

What does this PR do?:
It adds a debug option to specify MALLOC_ARENA_MAX via mallopt

Motivation:
Make it less error prone to diagnose potential malloc fragmentation issues in customer env (eg. no need to set a separate env variable)

Additional Notes:

How to test the change?:

For Datadog employees:

  • If this PR touches code that signs or publishes builds or packages, or handles
    credentials of any kind, I've requested a review from @DataDog/security-design-and-guidance.
  • This PR doesn't touch any of that.

Unsure? Have a question? Request a review!

@jbachorik jbachorik requested a review from richardstartin June 19, 2024 15:58
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 19, 2024

🔧 Report generated by pr-comment-cppcheck

CppCheck Report

Warnings (5)

Style Violations (162)

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 19, 2024

🔧 Report generated by pr-comment-scanbuild

Scan-Build Report

User:runner@fv-az1016-883
Working Directory:/home/runner/work/java-profiler/java-profiler/ddprof-lib/src/test/make
Command Line:make -j4 clean all
Clang Version:Ubuntu clang version 14.0.0-1ubuntu1.1
Date:Thu Jun 20 09:36:47 2024

Bug Summary

Bug TypeQuantityDisplay?
All Bugs6
Logic error
Assigned value is garbage or undefined1
Dereference of null pointer3
Unused code
Dead initialization1
Dead nested assignment1

Reports

Bug Group Bug Type ▾ File Function/Method Line Path Length
Logic errorAssigned value is garbage or undefineddwarf.cppparseInstructions23520
Unused codeDead initializationlivenessTracker.cppcleanup_table451
Unused codeDead nested assignmentvmStructs.cppcheckNativeBinding8271
Logic errorDereference of null pointerflightRecorder.cppflush14058
Logic errorDereference of null pointersafeAccess.hload3518
Logic errorDereference of null pointersymbols_linux.hElfParser12832

@jbachorik jbachorik requested a review from MattAlp June 20, 2024 08:56
@jbachorik jbachorik force-pushed the jb/debug_malloc_arena_max branch from f5a8a6f to f346414 Compare June 20, 2024 09:00
@jbachorik jbachorik merged commit 472281b into main Jun 20, 2024
@jbachorik jbachorik deleted the jb/debug_malloc_arena_max branch June 20, 2024 14:50
@github-actions github-actions Bot added this to the 1.9.0 milestone Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant