| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
CI Test ResultsRun: #32491259439 | Commit: 96c1a29 | Duration: 15m 9s (longest job)
Status Overview
Legend: ✅ passed | ❌ failed | ⚪ skipped | 🚫 cancelled Failed Testsmusl-amd64/debug / 17-librcaJob: View logs No detailed failure information available. Check the job logs. Summary: Total: 32 | Passed: 31 | Failed: 1 Updated: 2026-08-21 14:34:40 UTC |
Sorry, something went wrong.
Benchmark Results (commit fb1c44d)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125547869 Commit: fb1c44de77197780eae60267ff98bd38a907a558 ⚠️ Significant outliers
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
Benchmark Results (commit 1118f62)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125554643 Commit: 1118f62831a4384bdf0283ef01a626c5bdc48af5 ⚠️ Significant outliers
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
Benchmark Results (commit 40dbe8e)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125596529 Commit: 40dbe8e833888192b6026558590bce1cf0ad1c9f ⚠️ Significant outliers
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
There was a problem hiding this comment.
Extends wall-clock “owned-block” signal suppression to unfiltered (explicit filter=) wall recordings when wallprecheck=true, by introducing a thread registry keyed by native TID and integrating it into both ASGCT and JVMTI wall-clock sampling paths.
Changes:
Copilot reviewed 22 out of 22 changed files in this pull request and generated 3 comments.
Show a summary per file| File | Description |
|---|---|
| ddprof-test/src/test/java/com/datadoghq/profiler/wallclock/UnfilteredWallPrecheckTest.java | New integration coverage for suppression behavior in explicit-empty-filter wall recordings. |
| ddprof-test/src/test/java/com/datadoghq/profiler/wallclock/UnfilteredWallPrecheckRestartTest.java | Verifies registry activation does not leak across recording restarts and handles stopped gaps safely. |
| ddprof-test/src/test/java/com/datadoghq/profiler/wallclock/JvmtiBasedUnfilteredWallPrecheckTest.java | Ensures the unfiltered path works when wall sampling delegates stacks via JVMTI. |
| ddprof-test/src/test/java/com/datadoghq/profiler/wallclock/J9WallClockPrecheckCapabilityTest.java | Confirms J9 wall engine capability gating prevents activation of unfiltered tracking. |
| ddprof-test/src/test/java/com/datadoghq/profiler/AbstractProfilerTest.java | Adds beforeProfilerStart() hook to allow test setup before profiler thread callbacks are enabled. |
| ddprof-stresstest/src/jmh/java/com/datadoghq/profiler/WallClockPrecheckBenchmarkHooks.java | Exposes owned-block hooks to benchmarks without widening core API surface. |
| ddprof-stresstest/src/jmh/java/com/datadoghq/profiler/stresstest/scenarios/throughput/WallClockPrecheckOverheadBenchmark.java | Adds throughput benchmark comparing wallprecheck=false/true as owned-block population grows. |
| ddprof-lib/src/test/cpp/wallprecheck_args_ut.cpp | Adds capability tests and verifies explicit-empty vs omitted filter parsing behavior. |
| ddprof-lib/src/test/cpp/wallClockCandidateSelector_ut.cpp | Unit-tests the new bounded candidate selection logic. |
| ddprof-lib/src/test/cpp/threadFilter_ut.cpp | Expands tests for registry/epoch/lifecycle behavior and adjusts TID usage in recovery test. |
| ddprof-lib/src/main/cpp/wallClockCandidateSelector.h | Adds reusable “randomized prefix without replacement” candidate selection with stats. |
| ddprof-lib/src/main/cpp/wallClock.h | Integrates candidate selector and adds bounded-visit backfill path to the wall timer loop. |
| ddprof-lib/src/main/cpp/wallClock.cpp | Updates precheck suppression to validate registry identity + context transitions; supports lazy registry lookups. |
| ddprof-lib/src/main/cpp/threadFilter.h | Introduces registry state (TID index, epochs, lifecycle generation) and APIs for unfiltered tracking. |
| ddprof-lib/src/main/cpp/threadFilter.cpp | Implements lock-free lookups + mutex-serialized writers for TID indexing, epoch refresh, and retirement. |
| ddprof-lib/src/main/cpp/profiler.h | Declares bootstrap of existing Java threads for registry population. |
| ddprof-lib/src/main/cpp/profiler.cpp | Boots existing Java threads into registry when unfiltered tracking is active; deactivates registry on stop/failure. |
| ddprof-lib/src/main/cpp/jvmThread.h | Adds capability check for cross-thread native TID lookup support. |
| ddprof-lib/src/main/cpp/jvmThread.cpp | Implements native TID lookup support predicate. |
| ddprof-lib/src/main/cpp/javaApi.cpp | Ensures TLS slot binding is validated/refreshed before using owned-block and filter APIs. |
| ddprof-lib/src/main/cpp/engine.h | Adds wall-engine capability hook for unfiltered precheck support. |
| ddprof-lib/src/main/cpp/counters.h | Adds counters for registry bootstrap and bounded-lookup/backfill diagnostics. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Sorry, something went wrong.
Benchmark Results (commit d82291f)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125875202 Commit: d82291ff62852b63091350a05ebf26283fa39029 ✅ Within expected boundariesNo significant runtime deltas (all within run-to-run noise) and no internal-counter outliers. Runtime details (per benchmark × JDK)
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
Benchmark Results (commit ec76f58)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125883187 Commit: ec76f5829d243f516dee70833f3dfbe7a2b9eaa3 ⚠️ Significant outliers
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
Benchmark Results (commit 82e05b6)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/128529459 Commit: 82e05b6f02f2f64cd9a39e9a2791b4fb2388587e ⚠️ Significant outliers
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
Benchmark Results (commit f5b81de)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/128545992 Commit: f5b81de3bea33b0718817cf344261bda92848074 ⚠️ Significant outliers
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
Sorry, something went wrong.
Scan-Build Report
Bug Summary
Reports
|
||||||||||||||||||||||||||||||||||||
Sorry, something went wrong.
Stale JMC IItemCollection usage predated the jafar migration on main and caused a compile failure once this branch was rebased onto it.
Sorry, something went wrong.
There was a problem hiding this comment.
Here are some automated review suggestions for this pull request.
Reviewed commit: a68d3f22c6
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Sorry, something went wrong.
There was a problem hiding this comment.
🗿 🤖 🔴
Sphinx Review found 2 critical/high severity finding(s) that must be addressed.
Sorry, something went wrong.
|
|
||
| if (_thread_filter.enabled()) { | ||
| _thread_filter.unregisterThread(slot_id); | ||
| if (slot_id >= 0) { |
There was a problem hiding this comment.
🗿 🤖 🔴
[Sphinx Review — MEDIUM] onThreadEnd() now unconditionally calls _thread_filter.unregisterThread()/unregisterThreadByTid() (both mutex-guarded) for every JVMTI ThreadEnd event whenever any profiling engine is active, instead of being gated behind the thread-filter registry's active/enabled state as before.
Suggestion: Gate the else-branch (and ideally both branches) behind _thread_filter.registryActive() (or a cheaper lock-free check) so thread teardown for profiling sessions that never use the registry does not pay for a mutex acquisition.
Sorry, something went wrong.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
# Conflicts: # ddprof-lib/src/main/cpp/javaApi.cpp
There was a problem hiding this comment.
Could you, please, also take a look if it makes sense to add new adversaries in the chaos tests, or some fuzzing tests?
Sorry, something went wrong.
| profiler.stop(); | ||
| profilerStarted = false; | ||
| } | ||
| profiler.clearTraceContext(); |
There was a problem hiding this comment.
QQ: Any reason this is done unconditionally? Eg. regardless of whether profilerStarted == true?
Sorry, something went wrong.
There was a problem hiding this comment.
It was originally done this way to prevent any garbage coming from another test interferes with this test. But you're right in a sense that no test currently writes context without calling start(). I'd still keep it like that though as it is the most defensive way of doing.
Sorry, something went wrong.
| jint num_frames) { | ||
| // The source and destination commonly refer to the two views of the same | ||
| // CallTraceBuffer union. Read both source fields before either write. | ||
| for (jint i = 0; i < num_frames; ++i) { |
There was a problem hiding this comment.
This might be a premature optimization, but did you consider making the code friendlier to potential vectorization?
Probably not necessary to act upon this immediately, unless the benchmarks would show this function becoming a hotspot.
Sorry, something went wrong.
There was a problem hiding this comment.
Honestly I didn't for now, but it is definitely something to consider.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
What does this PR do?:
Extends wall-clock signal suppression to threads sampled through the existing explicit filter= mode.
When wall profiling runs with both filter= and wallprecheck=true, the profiler now:
The existing context-filtered behavior remains unchanged. This PR does not change the meaning of filter=.
Motivation:
With filter=, wall-clock profiling already samples every thread. However, threads outside an active context did not have the lifecycle metadata required to recognize and suppress repeated samples from the same profiler-owned blocking run.
This change closes that metadata gap. It also provides the thread lifecycle machinery needed by the follow-up TaskBlock work for non-context threads.
Implementation notes:
How to test the change?:
For Datadog employees:
of any kind, I've requested a security review.