interplane.Get Omega
Read in your language

CUDApp

CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit.

Brought by drakestapleton

CI: add an x86-64 host-tests job (portable suite + freestanding link)

merged 818f4704e28aa2e1 #199 · opened 2026-10-30 14:58 UTC · closed 2026-10-30 15:28 UTC · merged 2026-10-30 15:28 UTC

Imported from GitHub aien-dev/CUDApp#199, by drakestapleton

Base 522ee0d063cbc93672091a0edd00a0866634b981 · Head 9cb330d7415f0e67fda9ad1ceed06e9b4f4243b0

Merged on GitHub as 86b78f21e234ace384c38d9318e41f61beb13113; reachable from main 21d8de285f713adf09e0d6ba6db2b37139d0674e (observed 2026-11-18T16:38:24Z)

drakestapleton wrote on 2026-10-30 14:58 UTC

Purpose and scope

Adds a GitHub Actions job that runs the portable host suite on an x86-64 runner, with the memory reserve set the way docs/OMEGA_HOST_TESTS.md describes, and builds the x86 freestanding link.

Refs #196. This pull request does not close the issue.

Files:

  • .github/workflows/host-x86.yml (new). Job x86-host-tests on ubuntu-24.04. It does not install nvdisasm, clone Omega, or open a GPU.
  • docs/OMEGA_HOST_TESTS.md: one sentence naming that job.

git diff origin/main -- .github/workflows/ci.yml is empty. The AArch64 host-tests job is unchanged. No edits under src/, om/cubin/, or the files in pull request #170.

Commands the job runs:

make CC=gcc gpu-engine-freestanding
CUDAPP_MEM_RESERVE_MIB=0 make CC=gcc -j4 test

The freestanding step requires the compile of build/gpu_fs/cudapp_binding_portable.o to pass -DCUDAPP_MIGRATION_PENDING_C_ENCODER -DCUDAPP_MIGRATION_PENDING_C_CUBIN (CUDAPP_PORTABLE_DEFS in mk/omega-gpu-engine.mk) and requires the recipe line freestanding GPU link (<n> files): only ... undefined. The suite step requires exit 0 and a last line CUDA++ HOST TESTS PASS (<n> targets). The product default reserve stays 4096. The job sets CUDAPP_MEM_RESERVE_MIB=0 because that is the documented x86-64 command that passes when the host cannot keep 4096 MiB free.

How this sits with #90 and #189

  • #90 (host gates on pull requests) can keep editing .github/workflows/ci.yml and the AArch64 host-tests job. This change does not rewrite that workflow. It adds one file.
  • #189 (make test-runtime-api) already has .github/workflows/runtime-api.yml on main: the manifest check, the negative controls, and the version bump against the base commit, on ubuntu-24.04-arm. This pull request does not edit that file. The portable make test includes test-runtime-api as one of its targets. It does not run test-runtime-api-semver. That comparison stays in runtime-api.yml.

Evidence on the exact commit

Workflow commit 9cb330d7415f0e67fda9ad1ceed06e9b4f4243b0, parent 522ee0d063cbc93672091a0edd00a0866634b981.

GitHub Actions run https://github.com/aien-dev/CUDApp/actions/runs/41076382003, job x86-host-tests on ubuntu-24.04 (arch x86_64). Conclusion: success.

  • Freestanding link step succeeded. Recipe line: freestanding GPU link (15 files): only memcmp memcpy memset strcmp strlen undefined. The same log shows build/gpu_fs/cudapp_binding_portable.o compiled with -DCUDAPP_MIGRATION_PENDING_C_ENCODER -DCUDAPP_MIGRATION_PENDING_C_CUBIN.
  • Portable suite step succeeded with CUDAPP_MEM_RESERVE_MIB=0. Result line: CUDA++ HOST TESTS PASS (57 targets).
  • The job printed GB10: NOT_RUN. It did not run make hello-gpu and did not install a CUDA toolkit.

The same pull request's CI workflow still schedules host-tests on ubuntu-24.04-arm (run https://github.com/aien-dev/CUDApp/actions/runs/41076381664). That job definition is the file on main. This pull request does not change it.

A local run of the same two commands, on the parent sources before this commit (the workflow and the docs sentence are not inputs to make), also exited 0 on Linux x86_64, gcc 13.3.0, 4 cores: the same 57-target line and the same freestanding line. aarch64-linux-gnu-gcc was not installed there either.

  • make test (host-only). GitHub job and the local command both ended CUDA++ HOST TESTS PASS (57 targets).
  • make CC=gcc gpu-engine-freestanding exited 0. Line: freestanding GPU link (15 files): only memcmp memcpy memset strcmp strlen undefined.
  • make test-native-artifact (host-only). Inside the local suite: test_gpu_artifact_export: 47 checks, 0 failed.
  • make zero-cuda-gate exited 0 inside that local suite. ZERO_CUDA SELF-TEST PASS. build/hello_gpu needs libm and libc. build/gpu_matmul_api_test needs libc.
  • build/hello_gpu --sim ran inside that local suite. hello --sim tests: 12 passed, 0 failed.
  • make doctor as its own command. NOT RUN outside the suite. test-doctor is one of the 57 targets and the suite exited 0.
  • GB10 hardware tests. NOT RUN. This job does not open a device and does not run make hello-gpu.

No new evidence/ directory. The Actions log is the receipt. A receipt folder would be a file beyond the workflow and the docs sentence.

Correctness, compatibility and provenance

  • Negative controls stay the ones already in the suite (mutation FAIL lines, the freestanding malloc allowlist, the zero-CUDA self-test). This pull request does not weaken them.
  • Public runtime headers, docs/runtime/omega_runtime_api.manifest, and docs/runtime/API.md are unchanged. The AArch64 library build is unchanged because ci.yml is unchanged.
  • No new source file. The workflow carries the same SPDX header as the other workflows. No NVIDIA binary, cubin, PTX, firmware, or vendor listing was added.
  • No secrets, personal machine paths, or private addresses.
  • Receipts under evidence/ were not edited.

Known limitations

  • GB10 device behavior is NOT RUN.
  • The job has passed on this pull request. It is wired to run on push to main as well. It has not run on main yet, because this pull request is not merged.
  • The six seeded-binding and pinned-omc targets stay outside make test on x86-64 and exit 2 when invoked directly. make test-omega-target-only is the report inside the suite.
  • A host with enough free memory still uses the default 4096 MiB reserve. This job sets 0 so the command matches the documented x86-64 pass, including on a runner that cannot keep 4096 MiB free.
  • Passing this job is a host result. It is not a chip qualification.

— Grokbot

<div><a href="https://cursor.com/agents/bc-b872c9aa-98dd-50ff-aa2f-33452ce43d07?cursor_ref=pr_footer&cursor_cta=open_in_web"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-web-light.png"><img alt="Open in Web" width="114" height="28" src="https://cursor.com/assets/images/open-in-web-dark.png"></picture></a> <a href="https://cursor.com/background-agent?bcId=bc-b872c9aa-98dd-50ff-aa2f-33452ce43d07&cursor_ref=pr_footer&cursor_cta=open_in_cursor"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-cursor-light.png"><img alt="Open in Cursor" width="131" height="28" src="https://cursor.com/assets/images/open-in-cursor-dark.png"></picture></a> </div>

drakestapleton reviewed (COMMENTED) on 2026-10-30 14:59 UTC

Review at 9cb330d7415f0e67fda9ad1ceed06e9b4f4243b0: ready to merge once x86-host-tests is green. At review time all 12 checks were queued, including x86-host-tests (run 41076382003), so there's no run log yet.

Provenance. There's 1 commit, from cloud agent bc-b872c9aa, branched off main 522ee0d. The body says "Refs #196" and doesn't close the issue, which is right.

Scope. It adds one new file, .github/workflows/host-x86.yml (L1-55), with job x86-host-tests on ubuntu-24.04, a 60-minute limit and contents: read. Checkout is pinned to the same SHA as the other workflows. The only other change is docs/OMEGA_HOST_TESTS.md (+4 at L18-21).

Against #196's done-when

  • (a) Met, pending the run. L44-55 runs CUDAPP_MEM_RESERVE_MIB=0 make CC=gcc -j4 test, which matches docs/OMEGA_HOST_TESTS.md L15-17 on main. The product default of 4096 is unchanged. A pass on main can only be confirmed after this merges; the PR run is on the PR's merge ref.
  • (b) Met. L32-42 runs make CC=gcc gpu-engine-freestanding and greps for the cudapp_binding_portable.o compile carrying both CUDAPP_PORTABLE_DEFS flags, then for the freestanding GPU link (...) line.
  • (c) Met. ci.yml isn't in the diff, so the AArch64 host-tests job is byte-for-byte unchanged.
  • (d) Met. The workflow is host-x86 and the job and check are x86-host-tests. Neither collides with host-tests, runtime-api, fresh-checkout (#198) or figures (#198).
  • (e) Nothing is faked green.
    • || rc=$? is re-raised at L38 and L50.
    • The default bash -eo pipefail makes a failed grep pipeline at L39 or line=$(grep ...) at L40 fail the step.
    • The last line has to be CUDA++ HOST TESTS PASS (...) (L52-54).
    • L27 enforces x86_64.
    • There's no continue-on-error, no || true and no if: skip.
  • The echo "GB10: NOT_RUN" lines are honest, and the body makes no chip claim.

Fit. No file is shared with #197 (runtime-api.yml) or #198 (host-gates.yml, tools/ci/, AGENTS, CONTRIBUTING, START_HERE). #195 edits AGENTS.md, not this doc. Merge order: #197, then #199, then #198. None needs a textual rebase. After #199 lands, #198 should update its "#196 / x86 make test NOT_RUN" pointers (host-gates.yml L15, host-gates.sh L320, CI_ACCEPTANCE.md L9). One cost to note: x86 make test re-runs test-runtime-api without semver, which is fine since it's documented.

Follow-ups. The body lists none to file.

— Grokbot

Apply it

git checkout -b patch-818f4704e28aa2e1 522ee0d063cbc93672091a0edd00a0866634b981
curl -fsSL https://interplane.io/drakestapleton/CUDApp/patches/818f4704e28aa2e1.patch | git am

Raw patch (mbox) · Diff

Provenance

This proposal is imported from GitHub; it is not signed by its author. Its import statement and source record:

github-import 1
aien-dev/CUDApp
199
9cb330d7415f0e67fda9ad1ceed06e9b4f4243b0
{"kind":"github-import","owner":"aien-dev","repo":"CUDApp","number":199,"url":"https://github.com/aien-dev/CUDApp/pull/199","export_sha256":"0aafd51b77ff5776d6baaf9b88b48c8b36a6e27c8d829ae8ded561b71712b17a","imported_utc":"2026-11-18T16:38:24Z"}

Changes

diff --git a/.github/workflows/host-x86.yml b/.github/workflows/host-x86.yml
new file mode 100644
index 00000000..1222f66c
--- /dev/null
+++ b/.github/workflows/host-x86.yml
@@ -0,0 +1,55 @@
+# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+# x86-64 host CI (issue #196). Runs the portable suite from docs/OMEGA_HOST_TESTS.md
+# and builds the x86 freestanding link (mk/omega-gpu-engine.mk, CUDAPP_PORTABLE_DEFS
+# on cudapp_binding_portable.o). Does not install nvdisasm, clone Omega, or open a GPU.
+# The AArch64 host-tests job stays in ci.yml. make test-runtime-api's version bump
+# stays in runtime-api.yml (#189). Further host gates for #90 belong in their own
+# change, not in this file. GB10 chip tests stay NOT_RUN.
+name: host-x86
+on:
+  pull_request:
+  push:
+    branches: [main]
+permissions:
+  contents: read
+jobs:
+  x86-host-tests:
+    runs-on: ubuntu-24.04
+    timeout-minutes: 60
+    steps:
+      - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
+        with:
+          persist-credentials: false
+      - name: Toolchain record
+        run: |
+          arch=$(uname -m)
+          echo "arch $arch"
+          [ "$arch" = x86_64 ]
+          gcc --version | head -n 1
+          make --version | head -n 1
+          echo "CUDAPP_MEM_RESERVE_MIB=0 for the portable suite (docs/OMEGA_HOST_TESTS.md). The default 4096 is unchanged."
+          echo "GB10: NOT_RUN"
+      - name: x86 freestanding link
+        # The runner's bash uses -e -o pipefail, so make's status is captured with `||`.
+        run: |
+          rc=0
+          make CC=gcc gpu-engine-freestanding > "$RUNNER_TEMP/freestanding.log" 2>&1 || rc=$?
+          cat "$RUNNER_TEMP/freestanding.log"
+          [ "$rc" -eq 0 ] || exit "$rc"
+          grep -F 'cudapp_binding_portable.o' "$RUNNER_TEMP/freestanding.log" | grep -F -- '-DCUDAPP_MIGRATION_PENDING_C_ENCODER' | grep -F -- '-DCUDAPP_MIGRATION_PENDING_C_CUBIN'
+          line=$(grep -E '^freestanding GPU link \([0-9]+ files\): only .*undefined$' "$RUNNER_TEMP/freestanding.log")
+          echo "$line"
+      - name: Portable host suite
+        env:
+          CUDAPP_MEM_RESERVE_MIB: "0"
+        run: |
+          rc=0
+          make CC=gcc -j4 test > "$RUNNER_TEMP/make-test.log" 2>&1 || rc=$?
+          cat "$RUNNER_TEMP/make-test.log"
+          [ "$rc" -eq 0 ] || exit "$rc"
+          last=$(tail -n 1 "$RUNNER_TEMP/make-test.log")
+          case $last in
+            "CUDA++ HOST TESTS PASS ("*" targets)") echo "$last" ;;
+            *) echo "make test exited 0 without the final CUDA++ HOST TESTS PASS line"; exit 1 ;;
+          esac
+          echo "GB10: NOT_RUN"
diff --git a/docs/OMEGA_HOST_TESTS.md b/docs/OMEGA_HOST_TESTS.md
index dd155bae..38fdfd52 100644
--- a/docs/OMEGA_HOST_TESTS.md
+++ b/docs/OMEGA_HOST_TESTS.md
@@ -15,6 +15,10 @@ VM in `evidence/HOST-X86-20261030`, `make CC=gcc -j4 test` exits 2 at that
 default and passes only with `CUDAPP_MEM_RESERVE_MIB=0`. The failing check
 refuses a 741.9 MiB serving upload because 4.6 GiB is free and the runtime
 keeps 4.0 GiB free. A host that cannot keep 4096 MiB free fails the same way.
+GitHub Actions runs `CUDAPP_MEM_RESERVE_MIB=0 make CC=gcc -j4 test` and
+`make CC=gcc gpu-engine-freestanding` on `ubuntu-24.04`
+(`.github/workflows/host-x86.yml`). The AArch64 `host-tests` job is unchanged.
+GB10 stays NOT_RUN.
 
 On x86-64, `make test` does not count checks that execute the seeded AArch64
 binding or the pinned `omc`. Those targets still exist. Invoking one directly