Commit a2ac13c
committed
fix(executor): back all memory with a uniform page map, not just private input
store_byte used infallible allocation while every other private-input
write path was fallible, and store_private_inputs could write 4 bytes
past MAX_PRIVATE_INPUT_SIZE (the length prefix wasn't accounted for in
the accepted payload size), corrupting the tail of a maximal-size
input on readback.
Rather than patch the private-input-only paged HashMap, drop the
special case entirely: back the whole address space with one
HashMap<page_idx, Box<page>>, so private input is just memory written
at a fixed address like anything else. This removes the page/region
alignment invariant the split design depended on, and every write
(private or not) now goes through the same fallible page allocator.1 parent e17edc9 commit a2ac13c
3 files changed
Lines changed: 192 additions & 263 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | | - | |
| 8 | + | |
| 9 | + | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
189 | 189 | | |
190 | 190 | | |
191 | 191 | | |
192 | | - | |
| 192 | + | |
193 | 193 | | |
194 | 194 | | |
195 | 195 | | |
| |||
0 commit comments