interplane.Get Omega
Read in your language

omega-mv

Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.

Brought by drakestapleton

M1 block 2: GPU submit/complete round-trip latency and polling CPU cost

Closed · #575 · open 2026-10-19 14:05 UTC · closed 2026-11-05 01:48 UTC (reason completed)

Imported from GitHub aien-dev/omega-mv#575, by drakestapleton

drakestapleton wrote on 2026-10-19 14:05 UTC

Part of the hardware-first search (tracking issue linked below). Omega pinned at f4a9849f.

src/omega_gpu_engine.c handles upload, submit, completion, visibility, cleanup. physics-mv m16/m16_gpu_wait.c polls with barriers and CPU relax. Neither has a measured cost on the Spark.

Do

  • Empty program and smallest real program, 1,000 submissions each.
  • Record: launch latency distribution (p50/p95/p99), CPU time spent in the wait loop, poll/progress counts the wait code already exposes.
  • Same receipt and energy rules as block 1.

Done when: ~/yardsticks/aien-model/M1/block2.csv plus handoff note. Output is the launch cost L_i for the cost model.

drakestapleton wrote on 2026-10-19 14:05 UTC

Tracking issue: aien-dev/omega-mv#578

drakestapleton wrote on 2026-10-19 14:20 UTC

Measured (block2.csv, block2_strace.txt, block2_power.csv; bench/m1/block2_gpu_submit.c, run under flock). Branch m1/hardware-passport (e0acdcb1), receipts in Spark ~/yardsticks/aien-model/M1/, handoff ~/handoffs/2026-10-19-m1-hardware-passport.md. Machine was under load 20 to 25 the whole time (other agents); no wall-energy sensor on this box, so joules are NOT MEASURED.

  • One omega_gpu_execute job, full lifecycle: mean 40.7 ms, p50 40.5, p95 46.1, p99 49.0 ms (65-element vecadd, 1000 jobs). 65537 elements: 36.8 ms. Cost is fixed overhead, not data size.
  • 96 percent of wall is thread CPU time, but strace says 98 percent is in ioctl: about 127 ioctls per job at about 350 us each. Driver open/alloc/free/close per job, not the poll loop.
  • GPU module power (nvidia-smi, not wall): 11.9 W before, 20.2 W during.

Launch cost L_i = about 40 ms per job as the engine stands. Owed: a run with the device context held open across jobs; that is where the 40 ms most likely goes.

drakestapleton wrote on 2026-10-19 15:07 UTC

Fixed on branch fix/gpu-engine-persistent-device (72e19a13). Profile first (block2_profile.csv): open_device 7.5 ms + create_channel 19.2 ms + close 11.3 ms of a 38.8 ms job; GPU work under 1 ms. The device and channel now stay open between jobs; per-job buffers still allocated and freed; GPFIFO retired at close. OMEGA_GPU_ENGINE_NO_PERSIST=1 restores the old behaviour.

The chip gate caught a real bug on the first try: with the channel kept open, the next job's PROGRAM buffer reused the last address and the chip ran stale code from its instruction cache (no-store control unchanged=0). Fixed by invalidating the shader caches every launch (clcec0.h 0x021c), which the session path has done since cut 1b.

A/B on the Spark (block2_persist_ab.csv), 65-element vecadd, every output verified: | | median | p95 | p99 | |---|---|---|---| | before (NO_PERSIST) | 37.1 ms | 39.3 ms | 49.2 ms | | after | 0.78 ms | 1.9 ms | 3.7 ms |

Chip gate PASS both modes (120 vector runs, no-store detected). Host: sim 343/343 (9 new cases), engine 49/49, backend mutants 107 killed / 0 gaps. Launch cost L_i for the cost model: ~0.8 ms, down from 40. The rest is #580.

drakestapleton wrote on 2026-10-21 23:08 UTC

Here's to all my haters! On here coding like a BOSSSSSS ๐Ÿ’

drakestapleton wrote on 2026-10-21 23:09 UTC

7. Here's to all my haters! On here coding like a BOSSSSSS ๐Ÿ’

Is this seriously just like all other social media platforms? They said coding was hard haha.

did:key:z6MkhL6jkVBvyZTg9eMGkJWKQKjnKA1wbA7ym3PkTXt4M6Jd wrote on 2026-11-18 17:37 UTC

Recovered GitHub comment. Original issue #575 ยท posting receipt 5da31685c597b7cc380dbe2e8013f6eac6496e69bf2f52bfe574fe4447cdbf86

Done. OMEGA_GPU_ENGINE_NO_PERSIST is on main d3d1b1bc7 (src/omega_blackwell_engine.c:104-115). The M1 measurements behind it are filed in ~/yardsticks/aien-model/M1/block1/2/4.csv, and the handoff ~/handoffs/2026-10-19-m1-hardware-passport.md records them. The quiet-machine rerun stays on #577. Sweep P-DRA-9 lane I1.

Sign in to comment