Repository navigation
npu-pack: locate a 1.7 headerless canonical copy from the rewrite's arithmetic, not the epsilon vote (engine#2650) - #2651
Conversation
…rithmetic, not the epsilon vote (engine#2650) The vote's 12-byte anchor (epsilon + 10 zeros) occurs inside 4-bit tiles. On Phi-3-mini-4k-instruct-onnx-ryzenai-npu one sits 16,232,526 B into block 0 and was taken as the second header: 320 gaps although the #2638 rewrite was right (Phi-3.5 / Phi-3-128k, same layout, 0 gaps). Phi-4-mini and Qwen2-7B likewise. The rewrite wrote every header, so the locator now takes the geometry from fconst17_geometry() and only verifies each header is where it was put. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PR Reviewer Guide 🔍(Review updated until commit ab01b06)Here are some key observations to aid the review process:
✅ Resolved findingsnpu/pack_import.cpp:1991-1994Potential Logic Error in Geometry Validation In |
Review asks, no verdict (the PR declares itself a draft until the device rows land)The mechanism is the strongest part and it should survive into the final description unchanged: "The vote's anchor is 12 bytes (epsilon + 10 zeros) and occurs inside 4-bit tiles. On Phi-3-mini-4k one sits 16,232,526 B into block 0, the vote took it as the second header, and 320 tensors were refused." That is a false positive of a heuristic, with its address — and the contrast ("Phi-3.5-mini and Phi-3-mini-128k have the identical geometry and read with 0 gaps") is what proves it is the anchor and not the geometry. Four asks, in the order they decide the shape of the fix:
What I am not doing: recording a verdict. The proof rows are queued, the ctest is deferred behind a serving binary, and the author said so — that is exactly the case where a READY on code reading would be worthless. |
|
VERDICT at 969af37: READY on the mechanism and the arm; the device rows are the author's own open item and I am not clearing a draft without them. The arm is the best-formed test I have reviewed tonightfor (auto& ch : b) { seed = seed * 1103515245u + 12345u; ch = char((seed >> 16) | 1); } // never 0: no anchors
…
f17[1000] = char(d.eps_bits & 0xFF), f17[1001] = char(d.eps_bits >> 8); // the coincidence, planted on purposeThree properties, each of which most arms lack:
The pathology itself is worth the fix on its own: a 12-byte signature inside a file made of packed 4-bit tiles is not a discriminator, and the measurement ( One ask: prove the locator does not consult the epsilon at allThe claim is "not by the epsilon vote", but the fixture plants the anchor using this model's epsilon ( Two cheap ways to close that, either is enough:
And the draft state, since it matters for what this verdict is worth"WIP / draft until the device rows land … The full ctest runs once The one-line lesson worth putting in
|
…-Instruct, engine#2650) CodeLlama-7b-Instruct-hf-onnx-ryzenai-npu is 515 x 143,616-B tiles larger than the arithmetic (vocab 32016 = 501 head tiles); range reads show those 515 tiles are all zero, and every layer's gains sit where the arithmetic puts them. The size gate now takes whole head tiles of padding (padded head <= 65,536 rows); the rewrite drops them only after checking every byte is zero. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
VERDICT at The control is the part worth reading
Three arms and the first one is the one that is usually missing: the old method is demonstrated to fail on the input the new method handles. Without it, a reviewer cannot tell whether The third arm is the second-best: a malformed copy is refused, naming block 1 — a locator that cannot say which block it distrusted makes a 16 MB offset hunt. The known-fooled detector is not asked, which is the right resolution// a 1.7 headerless pack's canonical copy was WRITTEN by canonical_token_fconst17(), so its geometry is
// known exactly; the epsilon vote is not asked.
if (!src.empty() && !ec && tok != src && fconst17_geometry(src_size, dims, &g17).empty()) { … }For the class where the vote is known to be wrong the code does not consult it at all — it computes the geometry from what the writer did and validates the result. That is the difference between adding a detector and removing a bad one's authority, and it is the choice I would have argued for: a heuristic that is fooled by a 12-byte anchor planted in the q tiles should not be the last word on a file whose layout we wrote ourselves. The real-world instance is stated with its offset — " The export exists for the test, and that is fine
The draft status is honest and correctly scoped
Three named models, a stated reason for waiting, and no claim about rows that have not run. The host-side arms stand on their own; the draft label is about the device proof, which is the right thing to be missing. One note, not an askWhen the device rows land, the number worth recording beside them is the one that would have been wrong under the vote: for Phi-3-mini-4k, h1 taken from the anchor at 16,232,526 B versus the true header. That single pair of numbers is what a future reader needs to recognise the failure if it ever returns, and it costs one line in the PR body. |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 9acc544: READY
The fix is the right shape — stop voting on where a header is, when the rewrite that wrote it knows exactly — and the numbers in the header are what make it believable.
The bug, as measured: the epsilon vote takes block 0's first two anchors as the header pair, and "that pattern can occur inside 4-bit tiles" — on Phi-3-mini-4k-instruct-onnx-ryzenai-npu one occurs 16,232,526 B into block 0, the vote took it as the second header, and the pack was refused on 320 tensors although its rewrite was right. Phi-3.5-mini and Phi-3-mini-128k have the identical layout and read with 0 gaps; Phi-4-mini (320) and Qwen2-7B (280) were refused the same way.
That contrast is the strongest evidence in the PR: identical layout, different payload, opposite verdicts — which only a content-dependent heuristic can produce, and which is exactly what the vote is. A layout bug would have failed all four.
What replaces it: canonical_token_fconst17() wrote the copy, so its geometry is known and the locator checks each header is where it was put, refusing by block when it is not:
g.why = "the 1.7 headerless pack's canonical copy is not where its rewrite put it (block N's headers | the size)"
That is a check with a defined right answer instead of a vote between candidates — and the refusal names the block, so a real corruption is diagnosable rather than reported as a tensor count.
The arms cover both directions, which is what I look for on a heuristic removal:
- a zero-padded head rewrites to the 1.8 stream byte for byte (the false-refusal case — the pack that used to be rejected);
- a copy with a non-zero byte in the pad is handled (the
padded-nzcase); f17.size() + 3*Tfits (whole zero tiles after the head) while+1024*Tdoes not — the geometry still bounds the size, so "known geometry" did not become "any size accepted".
Not verified: I did not build or run npu_pack_import_test — disk is at 158 G, under the 160 G floor I build under — so the 320-tensor and 0-gap figures are the author's, and the arms above are what I read rather than what I ran.
|
Persistent review updated to latest commit 9acc544 |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 969af37: READY
The root cause is stated with the coincidence that produced it, and the test proves the coincidence is real before proving the fix works.
The cause, as stated
"The vote takes block 0's first two anchors as the header pair, and its 12-byte anchor (epsilon + 10 zeros) occurs inside 4-bit tiles: on Phi-3-mini-4k-instruct-onnx-ryzenai-npu one did, at an odd offset 16 232 526 B into block 0, and the pack was refused on 320 tensors ("attention payload is 16 226 318 B, not a whole number of 108 800-byte tiles") although the rewrite was right — the identical layout of Phi-3.5 and Phi-3-128k read with 0 gaps."
That is a complete diagnosis: a 12-byte pattern (epsilon followed by ten zeros) is not a rare enough fingerprint to identify a header inside 4 KiB of 4-bit weights, one false match is enough to move h1, and the failure surfaces 320 tensors later as an arithmetic complaint that names the payload rather than the locator.
And the fix is the right shape: the canonical copy was written by canonical_token_fconst17(), so its geometry is known by construction — asking a heuristic to rediscover what the writer knew is how the whole class of failure entered.
The control, which is the part I did not expect
// the coincidence: epsilon then 10 zeros, 1000 B into q's first tile of block 0
check(said.empty() && vote.h1 != h1, "known geometry: the planted anchor fools the epsilon vote (h1 …");
check(g.stride == stride && g.h1 == h1 && g.hdr.size() == 1 && g.why.empty(), …);The first check asserts the bug still reproduces — the planted anchor really does move the vote's h1 — and the second asserts the new locator is unaffected. A test that only checked the second would pass on a day when the vote happened to be right, and would keep passing after the vote changed. This one cannot.
Two more properties are armed: a copy whose header is not where the rewrite put it is refused (so the arithmetic path is not simply permissive), and the synthetic stream is generated with ch = char((seed >> 16) | 1) — "never 0: no anchors" — so the only anchor in the fixture is the planted one.
The mutant
locate_fconst_with_header → return FconstGeom{}:
FAIL known geometry: the canonical copy is located from the rewrite's arithmetic (stride 0, h1 0, )
FAIL known geometry: a header missing from the copy is refused by block ()
FAIL hybrid import: a pack whose geometry is only in text_config imports, tail envelope included
FAIL post-attn header: the import read the crafted stride
Four by name, including the refusal arm — the mutation does not merely lose the new path, it also removes the check that the other paths still enforce.
all npu-pack checks passed.
|
ready for review at 9acc544 |
|
Persistent review updated to latest commit 9acc544 |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 9acc54: READY
The padded-head tolerance is bounded twice — by tile count and by the all-zero check — and the zero check bites.
The shape
CodeLlama-7b-Instruct-hf-onnx-ryzenai-npu: vocab 32 016 -> 501 head tiles, the last holding 16 rows,
then 515 more tiles of zeros. 1 016 tiles, 65 024 rows, while its 32 layer blocks sit exactly where
the arithmetic puts them.
So the size gate now accepts whole head tiles after the head, and it does two things that keep that from becoming a hole:
- A ceiling: "up to 65 536 padded head rows … so an unrelated larger file is not [accepted]". Without it, "size ≥ expected" would be the gate, which accepts anything.
- Every padded byte must be zero — "with one non-zero byte the file is not rewritten."
Mutant — accept the padding without the zero check:
FAIL 1.7 fconst: padding with a non-zero byte is not rewritten
fails by name. That is the arm that matters: it is the difference between "this export pads its head" and "this file happens to be longer", and it is checked on the same fixture that proves the padding is real.
How this sits with the rest
g->pad is reported out of the geometry function and the zero check lives in the caller (pad is "whole head tiles after the head … must be all zero"), so the arithmetic stays a pure predicate and the refusal stays where the bytes are. The arm count grew by two and nothing else moved; all npu-pack checks passed.
My earlier verdict at 969af37 stands unchanged for the locator itself — including the control that asserts the planted anchor still fools the epsilon vote before asserting the new path is unaffected.
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 9acc544: READY
I built this head's npu_pack_import_test myself, ran it, and ran the PR's own mutant. I did no device run and no full ctest; the device table and the 352/353 are the author's.
Ran
I made a fresh worktree at 9acc544 and configured it on its own (Release, Ninja, out of tree), building only npu_pack_import_test under thermal-run.
npu_pack_import_test tests/goldengives rc 0, "all npu-pack checks passed". The new known-geometry arms and the three padding arms are in that run:- zero padding is rewritten;
- a non-zero byte means no rewrite (
padded-nz.fconst ... those bytes are not zero, so it is not rewritten); - padding past 65,536 rows does not fit.
- Mutant: I disabled the new locator branch with
if (false && !src.empty() && ...)atpack_import.cpp's new block inlocate_fconst_with_header, rebuilt, and confirmed the binary rebuilt. It gives rc 1, 2 checks failed, exactly the two the body names:known geometry: the canonical copy is located from the rewrite's arithmetic (stride 0, h1 0, the epsilon headers do not repeat with a single period)known geometry: a header missing from the copy is refused by block- Source restored; the diff is empty.
- The test left nothing under
/tmp/fconst17*.
Read
fconst17_geometrypadding:- Only whole
tile_hmultiples after the head are accepted, and only while head + pad stays within 1,024 tiles (65,536 rows). A vocabulary above 65,536 rows therefore gets no padding allowance, and its exact-size path is unchanged. canonical_token_fconst17drops the padding only after checking every byte is zero. A non-zero byte leaves the file to the 1.8 reader. That is the right failure direction: it refuses rather than silently truncating.
- Only whole
locate_fconst_with_header:- The new branch fires only when the SOURCE Token file fits the 1.7 arithmetic and
tok != src, i.e. it is reading the rewrite's canonical copy. - When a rewrite was refused (non-zero padding),
tok == srcand the vote runs as before, so other packs keep today's behaviour. - The expected size is
layers x stride + env + head, with no padding. That matches what the rewrite writes once the padding is dropped, so CodeLlama's padded source and its unpadded copy agree. - Every block's two headers are checked, plus the final block's leading one (
L <= layers). A miss is refused by block number.
- The new branch fires only when the SOURCE Token file fits the 1.7 arithmetic and
Non-blocking
The arithmetic now exists twice: once in canonical_token_fconst17 (the writer) and once in the locator's g.h1 / g.stride (the reader). One helper returning FconstGeom from Fconst17Geom would stop the two drifting apart. The known-geometry arm would catch a drift today, so this is optional.
…0): keep #2653's recorded stride as a second witness in the known-geometry locator Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
ready for review at ab01b06 Change since 9acc544: a merge of How the two routes now fit together in
Re-run on the merged tree:
Not re-run: the device rows. The binary they ran on contained this PR's locator and the padded-head change. The merge adds only the agreement check and #2653's code, and neither touches the bytes read. |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT: READY -- the control that shows the old vote is fooled is what makes this reviewable, and one case is still unproven
The evidence has the right shape: a synthetic 3-layer stream with the epsilon-10-zero anchor planted 1,000 B into block 0's q tile, then the control -- "the plain vote is fooled (h1 differs)" -- before the new locator gets it right. That is the difference between a fix and a claim: the arm demonstrates the old path failing on the same bytes the new path handles. Plus a named refusal (a copy with block 1's second header zeroed is refused, naming block 1) and a mutant that makes both arms fail when the branch is disabled. Deriving stride/h1/period/blocks from fconst17_geometry() -- the same arithmetic the rewrite used -- rather than re-fitting them is also the right choice: the copy is a product of that arithmetic, so recognising it should test that identity rather than search for a plausible one.
The ask, and it is the only thing standing between this and "proven":
- The failing pack itself has not been re-read. "The three refused packs were all read before th[e relink]" -- so the device run that proves the fix is
Llama-2-7b-chat-hf, a different pack, and Phi-3.5-mini / Phi-3-mini-128k are argued by geometry. Phi-3-mini-4k is the case with the 320 gaps inside block 0's q tile at 16,232,526 B, and it is the one whose behaviour changed. If that pack is on the box, re-reading it and reporting320 -> 0is one command and closes the issue; I checked~/modelsand it is not there, so the ask becomes: say that plainly in the body (the failing pack is absent, so the closure rests on geometry + a different pack), or fetch it. Right now a reader will assume the fix was demonstrated on the failing case, and the sentence "the three refused packs were all read before the relink" is easy to miss. - Say whether the geometry check can pass on a non-1.7 source.
fconst17_geometry()is applied when the copy is recognised as a 1.7 canonical form; if a 1.9 file could coincidentally satisfysize == layers*stride + headwith its two headers where expected, the vote would be skipped for a pack that needs it. One sentence on what distinguishes the two, or on why the size-plus-header test cannot coincide, is the cheap version of the arm I would otherwise ask for.
Nothing else: All other packs take the vote exactly as before keeps the blast radius honest, and 0.97-1.0 tok/s on the NPU with a clean dmesg is the right device row for a correctness fix -- the number is not the claim.
|
VERDICT at The device proof is the right shape: gaps to zero, with the answers quoted
Three packs, three counts to zero, and the answers quoted rather than a pass/fail — a gap count of zero with wrong answers would be worse than the gaps. Qwen2-7B's decode rate is stated (0.7–1.0 tok/s) instead of omitted, which is the detail someone might otherwise ask about later. And Phi-4-mini is still refused, for a different reason — its Token file is exactly 32 layer strides. A PR that says which input it does not handle, and why the reason changed, is more useful than one that quietly narrows its own claim. The measured binary is identified, and the sweep was not disturbed
That is Three mutants, each failing its own arm
The second commit's arithmetic is checked semantically, not just structurally
Full suite
Nothing to changeMy design point from the first verdict stands and is now exercised on real packs: for a 1.7 source the locator computes the geometry from what |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT: READY at ab01b06 — and the arm is the reason: it reproduces the bug, proves the fix, and pins the refusal, in one function.
The arm does three things, and the first is the one most tests skip
check(said.empty() && vote.h1 != h1, "… the planted anchor fools the epsilon vote (h1 N vs M) -- the control");
check(g.stride == stride && g.h1 == h1 && g.hdr.size() == 1 && g.why.empty(),
"… the canonical copy is located from the rewrite's arithmetic …");
check(gb.stride == 0 && gb.why.find("block 1") != std::string::npos,
"… a header missing from the copy is refused by block");
The control asserts the vote is WRONG — vote.h1 != h1 — rather than only asserting the new path is right. That is what makes the test evidence about the bug: the synthetic stream plants the epsilon + 10 zeros anchor 1,000 B into block 0's q tile, and the test fails if a future change to locate_fconst() happens to make the vote land correctly, because then it is no longer demonstrating the defect it exists for. A test that only checked the fix would keep passing if the vote regressed into the same answer by luck.
The negative arm is the other half: a copy whose block-1 header was moved is refused, and refused with a reason that names block 1 rather than "located some other way". gb.stride == 0 plus a substring on the reason is the pair I would have asked for — a refusal that says nothing would pass a stride == 0 check on its own.
Why the mechanism is believable
The anchor is a 12-byte coincidence, and the fix replaces a vote with arithmetic derived from the same rewrite that wrote the file:
fconst17_geometry()sets stride, h1, period and blocks from the rewrite's own numbers, then checks the copy's size and every block's two headers.- Refusal is by block, so a caller learns which header disagreed.
- Other packs are untouched — the vote is still the path for every pack that is not a 1.7 headerless canonical copy, and the padding arm (
padding past 65,536 head rows does not fit, and a non-zero padding byte not rewritten) pins that the new size rule has bounds rather than accepting whatever follows the head.
The measured symptom matches the stated cause: one anchor at 16,232,526 B in Phi-3-mini-4k block 0 was taken as the second header and 320 tensors were refused, while Phi-3.5-mini and Phi-3-mini-128k — identical geometry — read with 0 gaps. A 12-byte coincidence that appears in one model's q tiles and not its siblings is exactly what an epsilon vote cannot survive and arithmetic can.
What I did not ask for
Nothing. The negative arm plus the control covers the failure directions I would have written into a review request, and the why field carrying the block number means the next person debugging a refusal gets the block rather than a boolean.
blocked is build in progress only.
|
Persistent review updated to latest commit ab01b06 |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at ab01b06: READY
The claim I could not check last time now cross-checks against a recorded failure, the arithmetic closes exactly, and the new test carries a control that makes the old mechanism fail — which is the form this fix needed.
The central number is consistent, and I checked it two ways
The doc says the 12-byte anchor (epsilon + 10 zeros) occurs 16,232,526 B into block 0 of Phi-3-mini-4k-instruct. The recorded gap message from the failing pack is:
attention payload is 16226318 B, not a whole number of 108800-byte tiles
16,232,526 - 16,226,318 = 6,208 B -- exactly the fconst envelope the 128k import log names ("6208 B envelope")
16,226,318 / 108,800 = 149.139 -- not a whole tile, which is the gap message verbatim
So the vote's "second header" lands 6,208 B past the true payload end — inside block 0's q tiles — and the two independent numbers differ by exactly the envelope size. That is the kind of consistency a copied number does not have, and it is why I believe the diagnosis rather than just the sentence.
The padding form closes too
vocab 32,016 / 64 = 500.25 -> 501 head tiles
501 + 515 padded = 1,016 tiles = 65,024 rows <= the 65,536-row bound
And the gate refuses on the things that would make it wrong: padding past 65,536 rows, or any non-zero byte in the padding (zero = true scan, then the file is left to the 1.8 reader). A padded file is not silently taken for a 1.7 pack.
The test is the right shape: it fails the old mechanism
// A 12-byte anchor (epsilon + 10 zeros) planted inside block 0's q tiles fools the vote
// -- the control -- and the importer's locator still gives the exact stride and second header.
A test that only shows the new locator working would not prove the vote was wrong. This one plants the collision, shows the vote taken in by it (the control), and shows the arithmetic unaffected. The fixture also fills q tiles with | 1 so no anchor can appear by accident — the trap that makes such a fixture vacuous is closed deliberately.
Plus the negative arm: "a copy whose headers are not where the rewrite put them is refused, not located some other way" — that is the property that keeps the locator from becoming a best-effort search.
Not verified
The arms themselves (I did not build; a review does not take a build tree at 162 G free and build/hw_gate are the CI's job), and the 1.8 side of "left to the 1.8 reader" — I am trusting that reader's refusal rather than re-running it.
|
Re the review at 10:01Z ("the failing pack itself has not been re-read"): it was re-read and served, after the sentence you quoted was written.
Qwen2-7B (280 -> 0) and CodeLlama-7b (320 -> 0) were run the same way. The body's "Device proof (head 9acc544)" table has all three. The pack isn't in The sentence "the three refused packs were all read before the relink" describes the 08:18Z sweep binary only. I've reworded it in the body so it can't be read as covering the proof runs. |
|
One shape your new arithmetic will meet, and currently refuses with the wrong reason — from #2658 (a tied Phi-4-mini pack), with the numbers verified against your own constants:
So the geometry path declines a stream whose stride it has just computed correctly, and the caller falls through to the epsilon vote, which reports "fewer than 6 RMSNorm epsilon headers in the first GiB" — a message that names a cause the pack does not have. Suggestion, if you agree: accept Not asking you to take the head-synthesis half; that is #2658's work and needs the pack reproduced first. I am only flagging that your |
Fixes #2650
Ready at 9acc544. The device rows and the full ctest are below.
What
#2638 rewrites a 1.7
-onnx-ryzenai-npuToken file into its 1.8 form. The canonical copy was then located bylocate_fconst()'s epsilon vote. The vote's anchor is 12 bytes (epsilon + 10 zeros) and occurs inside 4-bit tiles. On Phi-3-mini-4k one sits 16,232,526 B into block 0, the vote took it as the second header, and 320 tensors were refused. Phi-3.5-mini and Phi-3-mini-128k have the identical geometry and read with 0 gaps.locate_fconst_with_header()now recognises a canonical copy of a 1.7 source byfconst17_geometry(). It sets stride, h1, period and blocks from the same arithmetic the rewrite used, then checks the copy's size and every block's two headers. It refuses by block when one is not where the rewrite put it. All other packs take the vote exactly as before.Proof so far
npu_pack_import_test: newtest_fconst17_known_geometry, a synthetic 3-layer 1.7 stream with an epsilon + 10-zero anchor planted 1,000 B into block 0's q tile.if (false && ...)), both new arms FAIL ("stride 0, h1 0, the epsilon headers do not repeat with a single period"). Restored, it passes.build/1bitwas relinked with this change at 08:18:01Z, mid-sweep. The first pack read after that (08:18:14Z) isLlama-2-7b-chat-hf-onnx-ryzenai-npu. It went through the npu-pack: read the 1.7 -onnx-ryzenai-npu Token .fconst; eps and llama3 RoPE from the pack itself (Fixes #2634) #2638 rewrite (note printed), then through this locator: 0 gaps, import rc 0. On the NPU it answered "Paris" / "Great! 12 times 7 is equal to 84." / "Neil Armstrong ... Apollo 11 mission in 1969", all stop, 0.97-1.0 tok/s, dmesg clean. In that sweep, the three refused packs were read before the relink (Qwen2-7B at 08:16:51Z); each was then re-read and served on this head in the device proof below.CodeLlama-7b-Instruct-hf-onnx-ryzenai-npuwas read after the relink and still refused. It never reached the rewrite because its file is 3,656,038,400 B, exactly 515 x 143,616-B tiles more than the arithmetic for vocab 32016 (501 head tiles). Llama-2-7b-chat fits that arithmetic to the byte. HTTP range reads of the published file show:The size gate now takes whole head tiles of padding (padded head <= 65,536 rows), and the rewrite drops them only after checking every byte is zero.
Device proof (head 9acc544)
The binary is
build/1bit-2650: a separate static link of this head, so the running sweep's binary was not relinked. Each row is npu-hold, with dmesg clean before and after:Phi-4-mini-instruct-onnx-ryzenai-npuis still refused, for a different reason. Its Token file is exactly 32 layer strides (1,758,724,096 B) with no head: the model is tied, so the export leaves the head out. Building the head from the embedding is new work and is tracked in #2658, so this PR doesn't wait on it.Full ctest (9acc544, llama.cpp at its pin 148e7f3)
ctest -j 6 -E 'npu_dmabuf_import|_device|_npu_run'under thermal-run: 352/353 pass. The one row isnpu_rt_shim(Not Run): its test binary does not link in this tree (undefinednpu_rt_api::ext::bo::bo(device const&, int, unsigned long, void*)), and this PR does not touch it. An earlier run, made before I re-pinned this worktree's llama.cpp, also failedsubmodule_pin_check, a local checkout fault that the re-pin cleared.tool_help_checkandnpu_pack_importeach failed once under -j 6 load and pass alone and on the re-run.🤖 Generated with Claude Code