Skip to content

Merge upstream main - #156

Merged
plotarmordev merged 495 commits into
mainfrom
feat/249-merge-upstream-main
Nov 24, 2026
Merged

plotarmordev merged 495 commits into
mainfrom
feat/249-merge-upstream-main

Conversation

@plotarmordev

Copy link
Copy Markdown
Owner

ThinkOffApp and others added 30 commits November 24, 2026 03:00
TensorFold takes no mode that changes output tokens, even opt-in, so the
SDOT kernels, eight-row repack and its cache, the fast KDA/MLA attention and
the --fast flag go. The exact path is unchanged: the pool, the GGUF reader,
the forward and the decode tool return to their exact-only forms, and the
affinity-mask test moves to the exact pool tests.
Drop the fast-mode run, its repack cache, the +sha2 note, the fast accuracy
bullet and the fast measured figures. The dot-product build stays as an
optional exact build, since the measured table has both.
…ream-main

# Conflicts:
#	docs/recipes/minimax-h3-image-metal.md
#	zig/build/h3_host.zig
#	zig/build/h3_image_decoder.zig
#	zig/build/h3_image_prompt.zig
#	zig/build/h3_image_server.zig
#	zig/src/families/h3/h3.zig
#	zig/src/families/h3/image.zig
#	zig/src/families/h3/prompt.zig
#	zig/src/server/gpu_turn.zig
#	zig/src/server/speech.zig
#	zig/src/server/speech_voices_test.zig
#	zig/tests/h3_dit.zig
#	zig/tests/h3_image.zig
#	zig/tests/h3_image_decoder.zig
#	zig/tests/h3_image_prompt.zig
#	zig/tests/h3_image_server.zig
…opped

PreflightContext.freeDiskBytes and ModelHubOptions.memory are still used and passed, so the desktop typecheck has been failing on main since 364dd6a. Types only; no runtime change.
…row_best's bits

fn_row_best runs one 1024-thread block per row, so a one-row draft step
fills one SM. fn_row_best_max and fn_row_best_sum do the same two passes
over (row, warp) blocks of 32 threads: each thread reads the same strided
values and each warp does the same shuffles, so the best, its first id
and the log-sum-exp keep their bits. The row's last block (an atomic
ticket) folds the 32 warp sums as warp 0 did.

Head.best takes the split for rows up to round_rows. The kernel contract
registers it as a replacement of fn_row_best (byte equality on every
served shape), with a planted control (the split over V - 1 values) that
goes red at shapes. The gradient-serving pins take the two sources.
The split row best keeps a persistent device buffer of split_bytes
(24,832 bytes at round_rows = 64) for each warp's best and id, each
warp's exponent sum and a counter a row. headBytes adds it, so the
placement estimate covers it, and the exact-accounting test pins it.
…oders, the denoiser and the decoders to a PLY

Each stage is timed and each model freed after it. The starting noise is torch's CPU-seeded randn, reimplemented;
the VAE's posterior noise and the starting noise can be given for parity with the SDK's MPS draws. The recipe's
End to end section has the stage timings, memory and PLY comparison against the SDK's own IdolPipeline run.
…as AIFlowML found

picture() checked only the element count, so `pixels` as float32
[1024, 1024, 3] (HWC) passed and was then read as CHW: a scrambled image
reached both encoders. families/idol/picture.zig now requires `pixels`
to be exactly float32 [3, 1024, 1024] and `image` exactly
[1024, 1024, 3], and its host test plants the HWC `pixels`, a flat
tensor, a bf16 one and a CHW `image`, each refused.
ashhart and others added 28 commits November 24, 2026 11:58
Darwin rejects a single write larger than INT_MAX.
Use bounded writes for Qwen 3.5 output files.
Verify with the chunked writer tests.
Remove multiline comments that fail the project lean check.
The focused writer tests pass.
Review on ashhart#4296 (ashhart): writeChunked made no progress with nonempty
input and a zero cap - every round wrote an empty slice and left the
offset unchanged. Reject the cap before the loop (ZeroWriteCap) and add
the regression: a nonempty buffer at a zero cap refuses with no bytes
written; an empty buffer passes.
core/engine_vision.zig gains gate(), declared() and words(): --vision without a
tower is refused as "--vision given but <model> has no vision tower", and a
tower without --vision stays unread. LFM2 (d1) on CUDA loads its tower only with
--vision; Qwen3.5 on HIP refuses --vision on a text checkpoint instead of serving
text; Flash Next on CUDA names the missing tower before a stream loads. The
header-only text count skips Qwen-VL, Gemma 4, LFM2-VL, LightOn, DeepSeek and GLM
towers too, and a cluster model's non-bool "vision" is refused by name.
… checks stay

refusals.lfm2 refused every --vision before lfm2.open ran the gate, so an LFM2-VL server
could not load its tower at all. It now checks --tp and --rank alone; the test shows
--vision passes and that --tp 2 or --rank 1 with --vision is still refused by name.
Main already holds zig/src/families/qwen3_5/backend/hip/engine/native.zig at 600 lines, so the new VisionWithoutTower refusal line took it to 601 once merged. This drops the blank line after the file's doc comment. No code change.
…nBytes

Main's visionBytes now takes the rank and world (rank 0 of 1 here, as in cuda_dense's tests), so the test's three-argument call stopped compiling once merged. Test only.
glm_copy_u32 and Drama 3's codec c_copy (n values, bounds-checked) and Nemotron's tf_copy_u32 and Flash Next's
pf_copy (one value a thread) had the same bodies. They now come from TF_COPY_U32_N and TF_COPY_U32 in
core/copy_u32.metal. c_copy keeps its 256-thread reservation; names and buffer indices are unchanged, and
pf_copy's arguments are named src and dst like the others. The offline Drama 3 metallib includes the core file;
the embedded codec text has it inlined.
…nput

The codec includes the shared u32 copy macros, but its compile step only listed d3_common.h, so a change to
copy_u32.metal alone reused the cached codec .air with the old copy kernel.
…ream-main

# Conflicts:
#	tools/zig/drama_guidance_check.py
#	tools/zig/test_drama_guidance_check.py
#	zig/build/drama3_host.zig
#	zig/src/core/contract/registry_media.zig
#	zig/src/native/qwen27_served.zig
#	zig/tests/cuda/contract_drama3.zig
… merge 847baad had taken upstream's summary over them

Merge 847baad resolved docs/recipes/minimax-h3-image-metal.md by taking upstream's condensed section (0ffb39e) and dropping the fork's own 'Large resident renders: live signal check, card 64' and 'Repaired live publisher and TOP voice menu, 15 November 2026'. Upstream never held those two, so nothing of its own superseded them. Both are back as main has them, byte for byte, and upstream's section follows them before '## Gates, fixed before any run'.
@plotarmordev
plotarmordev merged commit c577354 into main Nov 24, 2026
@plotarmordev
plotarmordev deleted the feat/249-merge-upstream-main branch November 24, 2026 13:47
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.