Skip to content

Remove the synthetic compatibility JFR output - #27

Merged
lhotari merged 1 commit into
mainfrom
remove-synthetic-jfr
Sep 24, 2026
Merged

lhotari merged 1 commit into
mainfrom
remove-synthetic-jfr

Conversation

@lhotari

@lhotari lhotari commented Sep 24, 2026

Copy link
Copy Markdown
Collaborator

Summary

The correlator wrote jonoffcpu-offcpu-synthetic.jfr beside the collapsed stacks and the stack profile: duration-quantized jdk.ExecutionSample events for JFR viewers. It carried nothing the other outputs don't. It also needed:

  • a patched copy of the JMC flightrecorder writer
  • a patch step that no build cache could reuse
  • async-profiler's make-built jfrconv to test it, which records the build date and so reruns the correlator's integration tests on every fresh CI checkout

This PR removes the feature and everything that existed only for it.

Correlator

  • Deleted: CompatibilityJfrWriter, SyntheticJfrSource and QuantumPlanner, plus Thinning.scaleQuantum and AnalysisOutput.synthetic().
  • Sample event time: the samples' event-time column (SampleColumns.startEpochNanos) was read only by the writer, so it's removed. A sample slot now retains 30 bytes instead of 38, and RetentionEstimate is updated to match. A sample with an out-of-range start time is no longer rejected, since the value isn't used.
  • Collapsed output: always written for a complete analysis.

CLI

  • --quantum-ns and --max-synthetic-events are removed.
  • --format takes only collapsed for a complete analysis, and that stays the default. With --partial true it takes diagnostics or collapsed as before. both and jfr are now usage errors (exit 64).

Report schema (jonoffcpu-report.proto)

  • The syntheticJfr block (Report field 24) and the coarsenSyntheticQuantum and omitSyntheticJfr degradation steps (5, 6) are removed. Their numbers and names are reserved.
  • The degradation ladder now starts by dropping the audit outputs.

Build

  • Removed: the JMC writer dependency with its patch and retained licenses, and the extractJmcWriterSources, applyJmcWriterPatch and compileJmcWriterPatch tasks.
  • Removed: the org.openjdk.jmc relocation, and the buildAsyncProfilerConverter task with the jfrconv input of integrationTest.
  • Unchanged: the published jfr-converter.jar.

Proof tools and docs

  • agent-smoke-musl-container.sh and run-agent-signal-pressure.py no longer convert the synthetic JFR.
  • Updated to match: README, OFFLINE.md, AGENTS.md, jonoffcpu-native/README.md, the correlator help snapshots, and the architecture diagram, which is rendered again.

Compatibility

  • Callers: external callers passing --quantum-ns, --max-synthetic-events or --format both|jfr now get a usage error.
  • Report readers: consumers reading syntheticJfr from the report no longer find it.

Verification

  • ./gradlew spotlessCheck :jonoffcpu-agent:check :jonoffcpu-correlator:check :jonoffcpu-jfr-converter:check passes on an arm64 Mac: 302 tests, 0 failures, 11 skipped. That includes the musl aarch64 container integration tests.
  • The second run reuses the configuration cache.

The correlator wrote, beside the collapsed stacks and the stack profile,
a synthetic JFR of duration-quantized jdk.ExecutionSample events for JFR
viewers. It carried nothing the other outputs do not, and it needed a
patched copy of the JMC flightrecorder writer, a patch step that no
build cache could reuse, and async-profiler's make-built jfrconv to test
it. Remove the feature and everything that existed only for it:

- CompatibilityJfrWriter, SyntheticJfrSource and QuantumPlanner, the
  quantum scaling in Thinning, and the samples' event-time column that
  only the writer read (a sample slot retains 30 bytes instead of 38).
- The --quantum-ns and --max-synthetic-events options. --format takes
  only collapsed for a complete analysis (still its default), and
  diagnostics or collapsed with --partial true; both and jfr are usage
  errors.
- The report's syntheticJfr block and the coarsenSyntheticQuantum and
  omitSyntheticJfr degradation steps; their field numbers and names are
  reserved. The degradation ladder now starts by dropping the audit
  outputs.
- The JMC writer dependency, its patch and retained licenses, the
  extract, patch and compile tasks, and the jfrconv build and test
  input.
- The synthetic JFR checks of the proof tools, and the output from the
  documentation, the help snapshots and the architecture diagram.
@lhotari lhotari added the maintenance Build, CI, dependency and other maintenance changes label Sep 24, 2026
@lhotari
lhotari merged commit 2ac2b53 into main Sep 24, 2026
7 checks passed
@lhotari
lhotari deleted the remove-synthetic-jfr branch September 24, 2026 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Build, CI, dependency and other maintenance changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant