Merge pull request 'feat(window): multi-frame-in-flight frame pacing (#40)' (#81) from claude/issue-40 into master

This commit is contained in:
catbot 2026-06-16 17:42:13 +02:00
commit 1451e3aeb2
4 changed files with 272 additions and 31 deletions

View file

@ -264,6 +264,37 @@ extern "C" Configuration CrafterBuildProject(std::span<const std::string_view> a
scrollImpls.emplace_back("tests/MouseScroll/main");
sc.GetInterfacesAndImplementations(ifaces, scrollImpls);
cfg.tests.push_back(std::move(scrollTest));
// Issue #40: multi-frame-in-flight frame pacing (per-image fences
// + per-frame semaphores, no steady-state wait-idle). Drives the
// real frame loop against a live Wayland compositor for many more
// frames than there are in-flight slots and asserts the validation
// layer stays silent — the old singleton-semaphore design only
// avoided being an active race because the wait-idle masked it, so
// a clean multi-frame run is the regression guard. Needs the
// Wayland backend + a real compositor, hence inside the !windows
// block alongside MouseScroll.
Test frameLoopTest;
Configuration& fl = frameLoopTest.config;
fl.path = cfg.path;
fl.name = "FrameLoopSync";
fl.outputName = "FrameLoopSync";
fl.type = ConfigurationType::Executable;
fl.target = cfg.target;
fl.march = cfg.march;
fl.mtune = cfg.mtune;
fl.debug = cfg.debug;
fl.sysroot = cfg.sysroot;
fl.dependencies = cfg.dependencies;
fl.externalDependencies = cfg.externalDependencies;
fl.compileFlags = cfg.compileFlags;
fl.linkFlags = cfg.linkFlags;
fl.defines = cfg.defines;
fl.cFiles = cfg.cFiles;
std::vector<fs::path> frameLoopImpls(impls.begin(), impls.end());
frameLoopImpls.emplace_back("tests/FrameLoopSync/main");
fl.GetInterfacesAndImplementations(ifaces, frameLoopImpls);
cfg.tests.push_back(std::move(frameLoopTest));
}
// Issue #36: BLAS build options. Drives the real hardware AS-build