[SymDB] Defer SymDB startup work#8548
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c129294227
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
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".
Execution-Time Benchmarks Report ⏱️Execution-time results for samples comparing This PR (8548) and master. ✅ No regressions detected - check the details below Full Metrics ComparisonFakeDbCommand
HttpMessageHandler
Comparison explanationExecution-time benchmarks measure the whole time it takes to execute a program, and are intended to measure the one-off costs. Cases where the execution time results for the PR are worse than latest master results are highlighted in **red**. The following thresholds were used for comparing the execution times:
Note that these results are based on a single point-in-time result for each branch. For full results, see the dashboard. Graphs show the p99 interval based on the mean and StdDev of the test run, as well as the mean value of the run (shown as a diamond below the graph). Duration chartsFakeDbCommand (.NET Framework 4.8)gantt
title Execution time (ms) FakeDbCommand (.NET Framework 4.8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (73ms) : 70, 75
master - mean (75ms) : 70, 80
section Bailout
This PR (8548) - mean (80ms) : 75, 84
master - mean (78ms) : 75, 81
section CallTarget+Inlining+NGEN
This PR (8548) - mean (1,098ms) : 1036, 1159
master - mean (1,128ms) : 1084, 1172
FakeDbCommand (.NET Core 3.1)gantt
title Execution time (ms) FakeDbCommand (.NET Core 3.1)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (117ms) : 111, 124
master - mean (115ms) : 108, 121
section Bailout
This PR (8548) - mean (119ms) : 113, 124
master - mean (115ms) : 112, 119
section CallTarget+Inlining+NGEN
This PR (8548) - mean (791ms) : 762, 820
master - mean (813ms) : 780, 846
FakeDbCommand (.NET 6)gantt
title Execution time (ms) FakeDbCommand (.NET 6)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (102ms) : 98, 106
master - mean (101ms) : 97, 104
section Bailout
This PR (8548) - mean (107ms) : crit, 102, 112
master - mean (101ms) : 99, 103
section CallTarget+Inlining+NGEN
This PR (8548) - mean (948ms) : 913, 984
master - mean (946ms) : 903, 990
FakeDbCommand (.NET 8)gantt
title Execution time (ms) FakeDbCommand (.NET 8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (100ms) : 96, 104
master - mean (104ms) : 98, 110
section Bailout
This PR (8548) - mean (103ms) : 98, 109
master - mean (101ms) : 98, 105
section CallTarget+Inlining+NGEN
This PR (8548) - mean (828ms) : 787, 868
master - mean (840ms) : 784, 895
HttpMessageHandler (.NET Framework 4.8)gantt
title Execution time (ms) HttpMessageHandler (.NET Framework 4.8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (212ms) : 197, 226
master - mean (211ms) : 190, 231
section Bailout
This PR (8548) - mean (218ms) : 200, 237
master - mean (214ms) : 194, 234
section CallTarget+Inlining+NGEN
This PR (8548) - mean (1,266ms) : 1189, 1344
master - mean (1,318ms) : 1228, 1407
HttpMessageHandler (.NET Core 3.1)gantt
title Execution time (ms) HttpMessageHandler (.NET Core 3.1)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (309ms) : 280, 337
master - mean (304ms) : 270, 338
section Bailout
This PR (8548) - mean (307ms) : 279, 335
master - mean (301ms) : 277, 325
section CallTarget+Inlining+NGEN
This PR (8548) - mean (999ms) : 972, 1026
master - mean (1,018ms) : 976, 1060
HttpMessageHandler (.NET 6)gantt
title Execution time (ms) HttpMessageHandler (.NET 6)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (297ms) : 271, 322
master - mean (299ms) : 274, 325
section Bailout
This PR (8548) - mean (296ms) : 273, 319
master - mean (301ms) : 275, 326
section CallTarget+Inlining+NGEN
This PR (8548) - mean (1,191ms) : 1128, 1253
master - mean (1,213ms) : 1134, 1293
HttpMessageHandler (.NET 8)gantt
title Execution time (ms) HttpMessageHandler (.NET 8)
dateFormat x
axisFormat %Q
todayMarker off
section Baseline
This PR (8548) - mean (300ms) : 274, 326
master - mean (300ms) : 273, 326
section Bailout
This PR (8548) - mean (305ms) : 271, 338
master - mean (303ms) : 271, 335
section CallTarget+Inlining+NGEN
This PR (8548) - mean (1,110ms) : 998, 1222
master - mean (1,122ms) : 994, 1251
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
BenchmarksBenchmark execution time: 2026-05-11 11:57:40 Comparing candidate commit a674cdf in PR branch Some scenarios are present only in baseline or only in candidate runs. If you didn't create or remove some scenarios in your branch, this maybe a sign of crashed benchmarks 💥💥💥 Scenarios present only in baseline:
Found 2 performance improvements and 2 performance regressions! Performance is the same for 53 metrics, 15 unstable metrics, 88 known flaky benchmarks, 38 flaky benchmarks without significant changes.
|
…8550) ## Summary of changes - Reverts #8510. ## Reason for change - We observed a startup-time performance impact from initializing SymDB independently of Dynamic Instrumentation. We want to investigate that impact before merging this behavior to `master`. ## Implementation details - Reverted the squash commit `01f5157075e90003af48a52c534dd3e6eceac57b`. ## Other details - Follow-up performance improvement PR: #8548 Co-authored-by: Cursor <[email protected]>
jpbempel
left a comment
There was a problem hiding this comment.
LGTM from Debugger POV
non-blocking comments on concurrency stuffs :D
…8565) ## Summary of changes - Reapplies #8510, which was previously reverted by #8550. - Restores the change so `Datadog.Trace` enables SymDB upload independently of Dynamic Instrumentation being enabled. ## Reason for change - We want SymDB to upload symbols even when DI is disabled (DEBUG-5086). - The original PR #8510 was reverted in #8550 because of an observed startup-time impact when SymDB was initialized independently of DI. ## Implementation details - Pure revert of revert commit `587c0655017587728bfd90fbc842bf448491af07` (#8550). - Restores the original logic from #8510 in `Instrumentation.cs`, `DebuggerManager.cs`, `DebuggerSettings.cs`, and the corresponding unit tests in `DebuggerManagerTests`, `DebuggerManagerDynamicTests`, and `DebuggerSettingsTests`. - No additional changes on top of the original #8510. ## Test coverage - No new tests added beyond what was restored from #8510 (those tests are reapplied as-is). - Tests not run locally for this revert-of-revert; relying on CI. ## Other details - The startup-time concern that motivated #8550 is being addressed in the open follow-up #8548 ("[SymDB] Defer SymDB startup work until remote enablement"). This PR should not be merged with #8548 lands (or the perf concern is otherwise resolved), otherwise we will reintroduce the regression that triggered the original revert. <!-- Fixes DEBUG-5086 -->
9970321 to
82207b4
Compare
7a40dcc to
2d4f8ff
Compare
2d4f8ff to
176cfae
Compare
f99b978 to
cf090ae
Compare
bbfda31 to
ce2e19b
Compare
… so debugger integration tests can exercise symbol uploads without parsing multipart data as traces.
- Mark `_symDbRemoteConfig` as `volatile`; drop now-redundant `Volatile.Read`/`Write` call sites. - Replace `Interlocked.Exchange(ref _symDbInitialized, 0)` with `Volatile.Write`; the prior value was discarded.
This is a temporary diagnostic-only change and should be reverted after the investigation.
This reverts commit f99b978.
With SymDB defaulting to on, the debugger lifecycle paths run on every process start. Tighten the "is there anything to do?" gates so the all-off case is genuinely free.
ce2e19b to
a674cdf
Compare
Summary of changes
DD_SYMBOL_DATABASE_UPLOAD_ENABLEDonly opens the debugger path when Remote Configuration is available.LIVE_DEBUGGING_SYMBOL_DBremote config payload enablesupload_symbols=true.Reason for change
Implementation details
Instrumentation.ShouldInitializeDebugger()to keep the top-level debugger gate closed for SymDB when RCM is unavailable.SymDbRemoteConfigto subscribe only toLIVE_DEBUGGING_SYMBOL_DBand parseupload_symbolsupdates without constructingSymbolsUploader.