Skip to content

Add LockSupport TaskBlock profiling instrumentation#11545

Draft
kaahos wants to merge 2 commits into
masterfrom
paul.fournillon/wallclock-locksupport-taskblock
Draft

Add LockSupport TaskBlock profiling instrumentation#11545
kaahos wants to merge 2 commits into
masterfrom
paul.fournillon/wallclock-locksupport-taskblock

Conversation

@kaahos

@kaahos kaahos commented Jun 3, 2026

Copy link
Copy Markdown

What Does This Do

Add TaskBlock profiling instrumentation for LockSupport.park/unpark, including blocker and unblocking span attribution where available.

Motivation

LockSupport.park is widely used by executors, queues, schedulers, and virtual-thread internals. Capturing these park intervals as TaskBlock events makes parked time attributable to spans and easier to separate from active execution in wall-clock profiles.

Additional Notes

Contributor Checklist

  • Format the title according to the contribution guidelines
  • Assign the type: and (comp: or inst:) labels in addition to any other useful labels
  • Avoid using close, fix, or any linking keywords when referencing an issue
    Use solves instead, and assign the PR milestone to the issue
  • Update the CODEOWNERS file on source file addition, migration, or deletion
  • Update public documentation with any new configuration flags or behaviors
  • Add your completed PR to the merge queue by commenting /merge. You can also:
    • Customize the commit message associated with the merge with /merge --commit-message "..."
    • Remove your PR from the merge queue with /merge -c
    • Skip all merge queue checks with /merge -f --reason "reason"; please use this judiciously, as some checks do not run at the PR-level
    • Get more information in this doc

Jira ticket: [PROJ-IDENT]

@datadog-official

This comment has been minimized.

@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch 4 times, most recently from b5ead17 to 235547a Compare June 5, 2026 13:18
Comment thread dd-trace-api/src/main/java/datadog/trace/api/config/ProfilingConfig.java Outdated
Comment thread metadata/supported-configurations.json Outdated
@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch from 235547a to 84fded4 Compare June 12, 2026 13:25
@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch from a20d06d to 71c8070 Compare July 6, 2026 09:54
@dd-octo-sts

dd-octo-sts Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

🔴 Java Benchmark SLOs — Performance SLO breach detected

Suite Status
Startup 🔴 breach

SLO thresholds are defined here based on automatically generated metrics. A warning is raised when results are within 5% of the threshold.

PR vs. master results
Scenario Candidate master Δ (95% CI of mean)
startup:insecure-bank:iast:Agent 13.99 s 13.94 s [-0.3%; +1.0%] (no difference)
startup:insecure-bank:tracing:Agent 12.91 s 13.00 s [-1.6%; +0.3%] (no difference)
startup:petclinic:appsec:Agent 16.88 s 16.73 s [-0.1%; +1.9%] (no difference)
startup:petclinic:iast:Agent 16.88 s 16.90 s [-0.9%; +0.7%] (no difference)
startup:petclinic:profiling:Agent 16.64 s 16.82 s [-2.1%; -0.0%] (maybe better)
startup:petclinic:sca:Agent 16.76 s 16.13 s [-0.4%; +8.3%] (no difference)
startup:petclinic:tracing:Agent 16.11 s 16.10 s [-1.0%; +1.1%] (no difference)

Commit: 82ca3c9b · CI Pipeline · Benchmarking Platform UI


Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion.

@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch 12 times, most recently from 53336b8 to 82ca3c9 Compare July 9, 2026 20:56
@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch from 82ca3c9 to 15c54ef Compare July 16, 2026 14:47
@dd-octo-sts

dd-octo-sts Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

❌ New Groovy Files Detected

Please avoid introducing new .groovy files to this repository.

  • dd-java-agent/instrumentation/datadog/profiling/lock-support/src/test/groovy/LockSupportProfilingDisabledForkedTest.groovy
  • dd-java-agent/instrumentation/datadog/profiling/lock-support/src/test/groovy/LockSupportProfilingInstrumentationForkedTest.groovy

Instead, rewrite the new file(s) in Java / JUnit. See the How to Test With JUnit Guide for more details.

If this PR needs an exception, add the tag: override groovy enforcement label to bypass this workflow.

@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch from 15c54ef to b557c8b Compare July 16, 2026 14:48
@kaahos
kaahos force-pushed the paul.fournillon/wallclock-locksupport-taskblock branch from b557c8b to a1815d5 Compare July 17, 2026 14:23
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.

2 participants