Repository navigation
Commit 3978c31
Link received payload objects into the package cache instead of copying
A rank export receives each cache payload object as a complete companion
wrapper in a synced temporary file, then `store_slice` hashed its payload,
copied it into a new wrapper in cache staging, synced that copy and
verified it again after installation. For a DeepSeek V4.1 Flash TP3 export
on three DGX Spark GB10 hosts that is about 200 GB read twice more and
written and synced once more on rank zero while the streams wait.
`Root::adopt_companion` links the received file itself into staging when
its framing is byte-for-byte the wrapper `store_slice` would write (same
length and the same leading bytes, from `companion_prefix`) and its payload
hashes to the declared identity. Publication is unchanged: the object is
made immutable, linked under its identity and verified once more. Any other
framing, or a file on another file system, returns `None` and the receiver
falls back to `store_slice` as before. An already cached identity returns
the verified cached object, as `store_slice` does.
Validation:
- helios `cargo test --release --features server,runtime-package --lib`:
1181 passed (1179 on main; the only failures are the
7 server::protocol tests that also fail on main); new tests cover the canonical prefix for several
lengths, adoption by link (same inode), a non-canonical framing declined,
a mismatched identity rejected, and a cached identity reused.
- heliopause `cargo test --release`: 166 passed, 0 failed.
- Full TP3 exports on three GB10 hosts, same model, recipe flags and cold
forward cache: "Receive rank export payloads" took 280.6 s with this
change (default streams), against 457.8 s (default streams, parent without
concurrent shared insertion) and 477.2 s (parent, 16 transfer streams)
without it; "Export native packages" took 1473.2 s, against 1677.4 s for
the parent with 16 streams. The exported package served with `flare run`: 262k-token prompt
16/16 retrieval cold (79.9 s) and warm (1.8 s), identical output, decode
in line with earlier packages.
Limitations: one export measured per configuration; the payload is still
hashed by a separate read after receipt instead of while it streams.
Signed-off-by: Javier López <59578422+javieratomic@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Design-Signed-Off-By: Claude Opus 5.5; design-review=1c011 parent a161b17 commit 3978c31
3 files changed
Lines changed: 134 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
735 | 735 | | |
736 | 736 | | |
737 | 737 | | |
738 | | - | |
739 | | - | |
740 | | - | |
| 738 | + | |
| 739 | + | |
| 740 | + | |
| 741 | + | |
741 | 742 | | |
742 | 743 | | |
743 | 744 | | |
| |||
752 | 753 | | |
753 | 754 | | |
754 | 755 | | |
755 | | - | |
| 756 | + | |
| 757 | + | |
| 758 | + | |
| 759 | + | |
756 | 760 | | |
757 | 761 | | |
758 | 762 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| 42 | + | |
42 | 43 | | |
43 | | - | |
44 | | - | |
| 44 | + | |
| 45 | + | |
45 | 46 | | |
46 | 47 | | |
47 | 48 | | |
| |||
1498 | 1499 | | |
1499 | 1500 | | |
1500 | 1501 | | |
1501 | | - | |
1502 | | - | |
1503 | | - | |
1504 | | - | |
1505 | | - | |
| 1502 | + | |
1506 | 1503 | | |
1507 | 1504 | | |
1508 | 1505 | | |
| |||
1524 | 1521 | | |
1525 | 1522 | | |
1526 | 1523 | | |
| 1524 | + | |
| 1525 | + | |
| 1526 | + | |
| 1527 | + | |
| 1528 | + | |
| 1529 | + | |
| 1530 | + | |
| 1531 | + | |
| 1532 | + | |
| 1533 | + | |
| 1534 | + | |
| 1535 | + | |
| 1536 | + | |
| 1537 | + | |
| 1538 | + | |
| 1539 | + | |
| 1540 | + | |
| 1541 | + | |
| 1542 | + | |
| 1543 | + | |
| 1544 | + | |
| 1545 | + | |
| 1546 | + | |
| 1547 | + | |
| 1548 | + | |
| 1549 | + | |
| 1550 | + | |
| 1551 | + | |
| 1552 | + | |
| 1553 | + | |
| 1554 | + | |
| 1555 | + | |
| 1556 | + | |
| 1557 | + | |
| 1558 | + | |
| 1559 | + | |
| 1560 | + | |
| 1561 | + | |
| 1562 | + | |
| 1563 | + | |
| 1564 | + | |
| 1565 | + | |
| 1566 | + | |
| 1567 | + | |
| 1568 | + | |
| 1569 | + | |
| 1570 | + | |
| 1571 | + | |
| 1572 | + | |
| 1573 | + | |
| 1574 | + | |
| 1575 | + | |
| 1576 | + | |
1527 | 1577 | | |
1528 | 1578 | | |
1529 | 1579 | | |
| |||
4756 | 4806 | | |
4757 | 4807 | | |
4758 | 4808 | | |
| 4809 | + | |
| 4810 | + | |
| 4811 | + | |
| 4812 | + | |
| 4813 | + | |
| 4814 | + | |
| 4815 | + | |
| 4816 | + | |
| 4817 | + | |
| 4818 | + | |
| 4819 | + | |
| 4820 | + | |
| 4821 | + | |
| 4822 | + | |
| 4823 | + | |
| 4824 | + | |
| 4825 | + | |
| 4826 | + | |
| 4827 | + | |
| 4828 | + | |
| 4829 | + | |
| 4830 | + | |
| 4831 | + | |
| 4832 | + | |
| 4833 | + | |
| 4834 | + | |
| 4835 | + | |
| 4836 | + | |
| 4837 | + | |
| 4838 | + | |
| 4839 | + | |
| 4840 | + | |
| 4841 | + | |
| 4842 | + | |
| 4843 | + | |
| 4844 | + | |
| 4845 | + | |
| 4846 | + | |
| 4847 | + | |
| 4848 | + | |
| 4849 | + | |
| 4850 | + | |
| 4851 | + | |
| 4852 | + | |
| 4853 | + | |
4759 | 4854 | | |
4760 | 4855 | | |
4761 | 4856 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
537 | 537 | | |
538 | 538 | | |
539 | 539 | | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
540 | 549 | | |
541 | 550 | | |
542 | 551 | | |
| |||
1207 | 1216 | | |
1208 | 1217 | | |
1209 | 1218 | | |
| 1219 | + | |
| 1220 | + | |
| 1221 | + | |
| 1222 | + | |
| 1223 | + | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
| 1230 | + | |
| 1231 | + | |
| 1232 | + | |
| 1233 | + | |
1210 | 1234 | | |
1211 | 1235 | | |
1212 | 1236 | | |
| |||
0 commit comments