Skip to content

0.25.2: the suite keeps the surface under a discarding link; the tests in mtest's layout (unit, e2e, cts, bench) - #67

Merged
Sunrisepeak merged 7 commits into
mainfrom
fix/0.25.2-names-kept
Nov 14, 2026
Merged

Sunrisepeak merged 7 commits into
mainfrom
fix/0.25.2-names-kept

Conversation

@Sunrisepeak

@Sunrisepeak Sunrisepeak commented Nov 14, 2026 •

Copy link
Copy Markdown
Member

The surface the suite links (SPEC clause 11, entry 63)

A link that discards definitions nothing reaches kept of an implementation only what the conformance suite calls, so clause 9's comparison of the exported names with the manifest reported an interface absent whose definitions the implementation holds (measured: openkal.process on an i386 Linux row linked with --gc-sections). The suite reaches every surface name without requiring it (tests/cts/src/declarations.c, generated by tools/check-declarations.sh --write): a defined name is kept, an absent one is null, so the suite still links against an implementation of some interfaces. The mechanism is a weak reference, used where the object format's static link accepts one to a name defined nowhere (ELF). No clause or declaration changes.

The tests in mtest's layout

Directory Kind Content
tests/unit/version.cpp UTest KAL_VERSION_*, read by the compiler, equal the manifest's version
tests/e2e/headers.cpp E2E the macros' module spellings, the C form under -nostdinc (cc, clang), no backend type, and that check failing on a copy given unsigned long
tests/e2e/abi.cpp E2E the frozen layout compiled for riscv32 and riscv64 (tests/e2e/data/abi)
tests/e2e/substitution.cpp E2E one source over two implementations, the surface checker rejecting an addition, the interface list derived from an artefact
tests/cts/ CTS, Bench the suite (moved from conformance/): one cts case per interface, one bench case <interface>.cost per measured cost
kit/tests/ UTest openkal-kit's cases
  • The shell checks of tests/checks and the inline steps of the declarations and substitution jobs are C++ cases of the mtest library. Each case works on copies in its temporary directory, so none writes the checkout and none needs serializing; a compiler a row lacks is a capability, and the case is skipped with the reason.
  • mcpp.toml states [dev-dependencies] mcpplibs.mtest (not resolved for a consumer) and [test] discover = ["tests/*/*.cpp"]; mtest.toml states the host (mcpp).
  • CI: the tests job runs mtest run --set full on Linux (gcc 16.1.0, llvm 22.1.8) and macOS (llvm 22.1.8): 16 passed, 0 skipped on each. Their subjects are the text, the headers through the tools and substitution, none of which depends on a consumer's toolchain; the declarations job builds the module form on its five rows. The mtest 0.8.5 library does not compile under LLVM 20's libc++ import std (directory_iterator comparison, lib/src/mtest.cpp:1290), so the macOS row of tests uses LLVM 22.
  • The suite stays without the C++ library, because it runs where an implementation has no C library; it speaks the protocol itself. tools/run-conformance.sh keeps its arguments, so an implementation's invocation is unchanged; its store is tests/cts/.mtest.
  • tools/gen-macros.sh [<output>] writes elsewhere when asked, which is how the case compares without regenerating in place.
  • Every job uploads its store (mtest-tests-*, mtest-kit-*, mtest-cts-*); the report job writes mtest ci report for the run's group.
  • cts and bench. The suite (0.10.0) reports each interface's measured cost as a bench case listed where the interface measures and cost is selected; a selection of an interface's cost reports only the cost.
  • kit. The implementation is beside the host's C library (the standalone arrangement supplied a second _start once the tests link the C library).

Pins: mcpp 2026.11.14.1, mtest 0.8.5 (bundle sha256 4b890455…).

Measured locally (mcpp 2026.11.14.1 candidate, mtest 0.8.5, openkal-linux 0.26.3): mtest run --set full 13 passed, 3 skipped (this machine's clang does not run; with an LLVM clang on PATH the headers program passes 5 of 5); the suite full 287 passed, 0 failed; a wrong layout in the ABI probe fails both targets.

… set, the kit with the mtest library, each interface's cost a bench case; one report of the run
@Sunrisepeak Sunrisepeak changed the title 0.25.2: the conformance suite keeps the surface under a discarding link 0.25.2: the suite keeps the surface under a discarding link; every test through mtest 0.8.5 (checks, kit, cts, bench) Nov 14, 2026
…++ cases of tests/unit and tests/e2e, and CI runs them as sets
@Sunrisepeak Sunrisepeak changed the title 0.25.2: the suite keeps the surface under a discarding link; every test through mtest 0.8.5 (checks, kit, cts, bench) 0.25.2: the suite keeps the surface under a discarding link; the tests in mtest's layout (unit, e2e, cts, bench) Nov 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant