[DO NOT MERGE] temporary: time clangd's module BMI rebuild on real projects - #29
Draft
Sunrisepeak wants to merge 2 commits into
Draft
Sunrisepeak wants to merge 2 commits into
Sunrisepeak wants to merge 2 commits into
Conversation
…jects Instruments module preparation (per-module prime duration, the preparation window and clangd's CPU at both ends) in the clangd engine's report, has the conformance runner wait for preparation and record it under MCPPLS_MEASURE_PREPARATION, and adds a linux-x64 workflow timing self-mcpp, real-xlings and self-mcppls cold and warm.
…hots per start Once preparation is idle and MCPPLS_MEASURE_PREPARATION is set, the clangd engine writes its log ring to <cache>/clangd-ring.log; the workflow keeps it, the server logs and a .pcm snapshot after the cold and the warm start, to tell whether the warm start built BMIs again.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Temporary draft, opened only to get numbers from CI; it will be closed without merging.
Question: how much of an mcppls cold start is clangd rebuilding the modules' BMIs (module preparation)? The answer decides whether a consumer-side universal BMI (clangd reading an IFC the GCC build already wrote) is worth doing (mcpp-safe research).
What it changes (measurement only):
src/engine/clangd.cpp: the clangd engine's report carriespreparationTiming: each primed module's time from itsimport M;didOpen to its first diagnostics, the preparation window, and clangd's CPU seconds at both ends and now.src/bin/conformance.cpp: withMCPPLS_MEASURE_PREPARATIONset,--measurewaits for preparation to finish (up to 15 min) and records that report section..github/workflows/tmp-bmi-timing.yml: linux-x64, self-mcpp / real-xlings / self-mcppls, cold then warm; the table goes to the step summary, the JSON to thebmi-timingartifact.Locally, the
timingfixture: cold first navigation 3.4 s with a 2.1 s preparation window (std 1.8 s), clangd 4.9 of 5.1 CPU seconds in preparation; warm 0.8 s with nothing primed.