diff options
| author | eunhhu <[email protected]> | 2026-09-25 09:34:34 +0100 |
|---|---|---|
| committer | eunhhu <[email protected]> | 2026-09-25 09:34:34 +0100 |
| commit | 65386f68fb53e5a9a20a284b06afd872172c30eb (patch) | |
| tree | b04133aaa602fbf6a864df1d368ae091ab09b600 /prototypes/connections/README.md | |
| parent | 6a28879bd56354483fe940c0c80d511eccb89983 (diff) | |
| download | pure-65386f68fb53e5a9a20a284b06afd872172c30eb.tar.gz pure-65386f68fb53e5a9a20a284b06afd872172c30eb.zip | |
Let the runtime own working versions as drafts
state.h gives any app a runtime-owned working version of a stored value on
the tree store. A draft shares unchanged extents with the stored version,
edits in memory by path copying, lends ordered extents without copying, and
commits only its new nodes when the key is still at its base revision. A
failed commit changes neither the draft nor the store; a draft whose file was
replaced by compaction copies its stored extents on commit. Unreachable
arena nodes are reclaimed once they outweigh max(reachable, 32 KiB).
Typing into the middle of a 1 MiB document and saving each character peaked
at about 1,660 KiB RSS with a draft against about 4,480 KiB for an app copy
compared with storage on save; saves were only 1-2 ms faster. This corrects
073, which had attributed the TUI's remaining 8 ms to that comparison.
Drafts are not yet charged to the runtime budget or visible to .pure
definitions.
Diffstat (limited to 'prototypes/connections/README.md')
| -rw-r--r-- | prototypes/connections/README.md | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/prototypes/connections/README.md b/prototypes/connections/README.md index f0b041e..94d05f0 100644 --- a/prototypes/connections/README.md +++ b/prototypes/connections/README.md @@ -148,6 +148,8 @@ python3 prototypes/connections/export_flat_store.py \ 트리로 둔다. 편집은 바뀐 leaf와 경로만 기록하고, 읽기는 잠그지 않는다. 기존 런타임·부분 수정· 비동기·실제 PTY 검사와 자체 고장·오라클 검사를 함께 실행한다. 형식이 달라 별도 `--store` 디렉터리를 쓴다. [설계·측정·한계](../../docs/research/073-single-file-persistent-tree.md). +같은 저장소에서 런타임이 앱의 작업 버전을 소유하는 draft API는 [`state.h`](state.h)이며, +설계와 측정은 [074](../../docs/research/074-runtime-owned-drafts.md)에 있다. ```sh make -C prototypes/connections check-tree |
