Skip to content

Integration CI: tighten the -O2 inventory and fix timer.c for GCC 14+ (E4) #75

Closed

Description

@fd-shockwave-bot

Task and scope

Epic / milestone: #35, M5 — Establish host interchangeability.
Delivery PR: #76 (ci/integration-green) → claude/eech-campaign-native-spike-tjkj6g.

Rescoped 2026-10-20 (user-approved). The original outcome, integration CI green, was met upstream: 254ded56 (GCC 12 pin, wine) and d2d4792a (eech-map lint, -O2 inventory). All 5 jobs are green at d2d4792a. This Task now delivers two things:

  1. Inventory tightening. d2d4792a skips the global-state "gone" assertion whenever the kernel is optimised. Here only the two evidenced [elidable] globals (old_num_map_z_sectors, update_data) may be absent at EECH_C_OPT ≠ 0. Any other disappearance fails, and at -O0 every listed symbol must exist.
  2. E4, a timer.c:274 source fix. windows_timer_interrupt and the timeSetEvent user data take DWORD_PTR, so GCC 14+ builds the engine on x86-64 without relying on the GCC 12 pin. Runtime behaviour is unchanged on i686 (identical code) and x86-64 (the headless timeSetEvent never calls back).

CI and build hygiene only. It changes no campaign behaviour, golden output, regression baseline, tolerance or accepted claim. No warning is suppressed, and no test is skipped or deleted. The CI GCC 12 pin is kept; removing it is a separate decision.

History of the failures (reproduced from CI logs)

Head Job Failure Resolved by
b4d43ea6 x86_64 ×2 timer.c:274 incompatible pointer type (GCC 15, ubuntu-26.04) 254ded56 (GCC 12 pin); source fix E4 in #76
b4d43ea6 windows-cross the wine launcher was missing ("No such file") 254ded56
254ded56 x86_64 Lints clippy 1.99 chunks_exact_to_as_chunks in eech-map d2d4792a
254ded56 x86_64 EECH_C_OPT=2 inventory: two globals elided at -O2 d2d4792a (skip at -O > 0); tightened to the two [elidable] globals in #76

Acceptance question

Is E4 a correct, behaviour-preserving fix, shown red without it and green with it on a newer GCC? Is the inventory exemption limited to the evidenced symbols? Are all 5 jobs green, and does the retained regression pack pass?

Activity

  1. fd-shockwave-bot commented on Oct 20, 2026

    @fd-shockwave-bot
    Author

    SUPERSEDED by the handover at #75 (comment) (PR #76 rescoped, candidate 303103d2). Kept for history.

    Handover (2026-10-20, fd-shockwave-bot)

    • Branch / commit: ci/integration-green at 2c4cc5ae. Base: claude/eech-campaign-native-spike-tjkj6g at 254ded56. The brief named b4d43ea6, but 254ded56 (GCC 12 pin, wine) landed before this work started, so this Task works forward from it. PR eech-campaign: tighten the -O2 global inventory; E4 timer.c callback fix for GCC 14+ (#75) #76 → integration branch; Task Integration CI: tighten the -O2 inventory and fix timer.c for GCC 14+ (E4) #75 under Epic [Epic][M5] Prove host interchangeability while preserving the reference baseline #35 (M5).
    • Scope / gate: CI and build hygiene only. No campaign, engine C, golden output, baseline, tolerance or pack.json change. This puts M5's refactoring under checks that actually run: the workflow had never passed (0 of 28 runs).
    • Root causes:
      • b4d43ea6, x86_64: timer.c:274. The original passes a DWORD-parameter callback where the compat shim declares LPTIMECALLBACK with DWORD_PTR parameters. GCC 14+ makes that an error. 254ded56 fixed it with GCC 12, not this PR.
      • b4d43ea6, windows-cross: "No such file": the cargo runner wine was not installed (only wine64). Also fixed by 254ded56.
      • 254ded56, x86_64 Lints: clippy 1.99's new chunks_exact_to_as_chunks in eech-map. This PR uses as_chunks::<2>().
      • 254ded56, x86_64 EECH_C_OPT=2: GCC 12 -O2 elides two write-only statics, old_num_map_z_sectors and update_data, and the inventory's "gone" check failed on them. This PR marks exactly those two manifest entries [elidable]. An optimised kernel may omit only them. At -O0 all symbols must exist, and the unclassified check is unchanged.
    • Red / green:
      • Red: reproduced in CI run 39428612290 (not locally: no Linux toolchain, and the Docker daemon is down).
      • Green: CI run 39430643777, 5 of 5 jobs successful (x86_64 incl. Lints, x86_64 OPT=2, i686, i686 original-stack, windows-cross). every_writable_global_is_classified ... ok in each job.
    • Regression: python tools\regression-pack.py --retained-only exits 0, with all 14 retained checks PASS (verdict "INCOMPLETE (retained tier only)", by design). A broader Windows runtime regression was not run and is not warranted: nothing in eech_dc.dll or eech-world.exe changed, and no crate depends on eech-map.
    • Boundaries: none discovered or changed. Baseline differences: none.
    • Limitations:
      • The [elidable] evidence covers GCC 12 -O2 only.
      • The windows-cross inventory may skip silently if nm cannot spawn under Wine (pre-existing).
      • regression-pack.py crashes on relpath when --out is on another drive.
    • Lead decisions requested:
      1. Whether to add a timer.c engine patch (callback parameters to DWORD_PTR; behaviour-neutral on i686; the shim never calls back) so the build no longer depends on the GCC 12 pin.
      2. Whether to enforce or update the declared workspace rust-version = "1.80". It is not inherited, and eech-map needs 1.88 now (1.87 before this PR).
    • Review status: formal review requested from @fd-starscream-bot. Not approved; not merged.
    • Next bounded action: address the lead's review feedback and decisions.
  2. changed the title [-]Integration CI green at b4d43ea6[/-] [+]Integration CI: tighten the -O2 inventory and fix timer.c for GCC 14+ (E4)[/+] on Oct 20, 2026
  3. fd-shockwave-bot commented on Oct 20, 2026

    @fd-shockwave-bot
    Author

    SUPERSEDED by the handover at #75 (comment) (candidate aa110ffa). Kept for history.

    Handover (2026-10-20, fd-shockwave-bot), superseding the earlier handover

    • Branch / commit: ci/integration-green at 303103d2. It is merged with the integration head d2d4792a (94432391), and the integration branch has not moved since. Commits: 2c4cc5ae, 94432391 (merge, inventory tightening), 303103d2 (E4).

    • Scope (rescoped, user-approved):

      1. Inventory tightening: at EECH_C_OPT ≠ 0 only the two [elidable] globals may be absent.
      2. E4: timer.c's timeSetEvent callback and user data take DWORD_PTR.

      CI and build hygiene only; no campaign behaviour change.

    • Characterised: the generated code for timer.c with and without E4, compiled with GCC 12 and the engine's flags. i686 is identical. On x86-64 the only difference is that the pointer is no longer truncated (the headless timeSetEvent never calls back).

    • Red / green for timer.c:

      • Red: GCC 15 in CI run 39426483644 (b4d43ea6). Locally, on 94432391 without E4: GCC 14.2.0 (rust:trixie) and GCC 15.3.0 (gcc:15), both timer.c:274:66: error: … [-Wincompatible-pointer-types].
      • Green: the same two compilers with E4 build OK. The full x86_64 cargo test passes on GCC 14.2.0. The -O2 inventory passes 2 of 2 on GCC 14.2.0 and 15.3.0.
    • CI: run 39440605895 at 303103d2, 5 of 5 green (x86_64 incl. Lints, x86_64 OPT=2, i686, i686 original-stack, windows-cross).

    • Regression: python tools\regression-pack.py --retained-only exits 0, with 15 of 15 retained checks PASS. (The earlier handover said 14; it is 15.)

    • Boundaries: none discovered or changed. Baseline differences: none.

    • Limitations:

      • The GCC 12 CI pin is kept, and an unpinned CI build with E4 was not run.
      • The Windows runtime tier was not run. E4 changes the x86-64 eech_dc.dll, but only in code that is never reached.
      • [elidable] is evidenced for GCC 12, 14 and 15 only.
      • Pre-existing: the windows-cross inventory may skip silently, and regression-pack.py fails on relpath across drives.
    • Lead decisions:

      1. Accept E4 as "no behavioural change".
      2. Whether a Windows -Exact regression is wanted.
      3. Whether to drop the GCC 12 pin in a separate, CI-proven change.
    • Review status: review re-requested from @fd-starscream-bot. Not approved; not merged.

    • Next bounded action: address the lead's review.

  4. fd-shockwave-bot commented on Oct 20, 2026

    @fd-shockwave-bot
    Author

    Handover (2026-10-20, fd-shockwave-bot), superseding the handover of 14:43 UTC

    • Branch / commit: ci/integration-green at aa110ffa.

    • Scope: unchanged.

      • The [elidable] inventory rule, as accepted by the lead.
      • E4, the timer.c fix: "no behavioural change" for the headless product only.

      No campaign behaviour change; the GCC 12 pin is kept.

    • Review 5587346957: every point answered in the PR comment above.

    • Evidence retained in the repository:

    • Red / green: red 94432391 fails at timer.c:274:66 on GCC 14 and 15; green 303103d2 builds on both. i686 code is identical (292 lines); the x86_64 changes are classified.

    • Runtime: finished; nothing in progress.

      • The M4 pack at d38b9b2d, 16:30–16:49 UTC, ran on the retail PC with no other EECH process running.
      • Result: PASS. Georgia and Lebanon -Exact are IDENTICAL to windows-retail v1; 17 directly protected and 12 baseline-sensitive claims PASS; nothing NOT RUN.
      • No difference to classify, no baseline change and no change record.
    • Binaries: eech_dc.dll 186857df…, eech-world.exe 56f08086… (accepted eech-build image 0c60c75d). The record is intended to serve Promote the native integration branch to master: M1-M4, #73, #76 (65892de1) #59 item 2 while Promote the native integration branch to master: M1-M4, #73, #76 (65892de1) #59's head builds to these hashes.

    • Checks:

      • CI: 5/5 green at d38b9b2d (run 39457908937) and at aa110ffa (run 39461065299).
      • govcheck.py: 0 failures.
      • The full pack includes the retained tier (15/15).
    • Boundaries: none changed. Baseline differences: none.

    • Limitations:

      • These are M4's residual risks: one seed, 3 h; 8 evidence-only and 8 uncovered claims; no visual Tacview review; local retail data.
      • E4's evidence covers Linux objects only; the Windows object was not disassembled, though it calls the same no-op shim.
      • Pre-existing: the Wine/nm skip, and the pack's cross-drive path crash.
    • Review status: review re-requested from @fd-starscream-bot. Not approved; not merged.

    • Next bounded action: the lead's review of aa110ffa. After eech-campaign: tighten the -O2 global inventory; E4 timer.c callback fix for GCC 14+ (#75) #76 lands, Promote the native integration branch to master: M1-M4, #73, #76 (65892de1) #59's rebuilt head can be checked against the hashes above.

  5. added a commit that references this issue on Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions