Fully homomorphic encryption (FHE) lets a server compute on data it cannot read: inputs are encrypted, the server adds and multiplies ciphertexts, and only the data owner can decrypt the result. The price is very high. A CIFAR-10 inference that is trivial in plaintext takes about 20 minutes in FHE software, and encrypted training or database queries can run for hours. They also hold gigabytes of intermediate ciphertexts in volatile memory. A host crash, a power cut, or a cloud spot-instance preemption partway through throws all of that work away. Persistent-memory research shows that guarding against such crashes usually costs a lot, through logging, cache flushes, and write amplification. Applied naively to multi-hundred-megabyte ciphertexts, that cost would add a second memory wall on top of the one FHE already has.
Our observation is that FHE programs are an unusually easy case for crash consistency. A homomorphic program is a fixed, branch-free graph of operations, so the compiler knows the whole execution in advance. Each operation writes a new ciphertext instead of overwriting an old one. The large evaluation keys never change during the run. Ciphertext size shrinks predictably as computation consumes its "levels", the budget of multiplications left before a costly refresh step called bootstrapping. Ciphertexts are already encrypted, so persisted state needs no extra protection. We propose a compiler pass that uses these facts to pick, ahead of time, the points in the program where only a small set of live ciphertexts must be saved. Recovery then needs no logs at all: reload the immutable keys and the last saved set, then resume from a single atomically committed program counter.
Core Claim
Crash consistency for FHE workloads can be reduced to choosing where to cut a static dataflow graph. If the compiler places cuts where the set of live ciphertexts is smallest, often just before bootstrapping when ciphertexts carry the fewest residue limbs, the expected cost of persistence plus re-execution should be well below both periodic whole-memory checkpointing and transactional undo/redo logging. Correctness can also be checked exhaustively, because every crash point in a deterministic schedule can be enumerated and the recovered output compared bit-for-bit against an uninterrupted run. A second claim concerns the cost model. A plan tuned on idealized per-operation latencies, which is how every published FHE accelerator is evaluated, may be measurably wrong on real silicon under sustained load. We will quantify that error rather than assume it away.
Why This Gap Is Real
The FHE accelerators in the file all treat state as disposable. F1 builds a wide-vector ASIC with a 64MB scratchpad and a static VLIW schedule, which it can do because FHE has no data-dependent control flow. That determinism is exactly what our planner relies on, but F1 never considers interrupted execution. FHEmem and APACHE move computation into or next to DRAM to cope with working sets of hundreds of megabytes and key-switching traffic near 10,000 GB/s. Both are volatile and both are evaluated only in simulation. MemFHE runs FHE inside resistive RAM, which is non-volatile, yet it defines no commit points or recovery semantics. The SoK on FHE accelerators surveys 14 designs and notes that ASIC results are mostly simulated. None of this work addresses recovery. These papers motivate the gap but do not constrain our design.
The method comes from persistent-memory work. The Parallel Persistent Memory Model shows that splitting computation into "capsules" free of write-after-read conflicts makes re-execution after a crash safe without undo logs. It states this as an asymptotic model and never applies it to cryptographic workloads. We argue that FHE graphs, once the compiler removes in-place buffer reuse within a segment, are capsules by construction. Execution of NVRAM Programs with Persistent Stack commits a stack frame by flipping a single byte within one cache line. We reuse that idea for a one-word commit record holding the schedule index and pointers to the saved live set. SplitFS's relink (SplitFS) shows that swapping pointers instead of copying data avoids most software overhead. That paper measured ext4 DAX at over 8,000 ns for a 4KB append that the hardware completes in about 671 ns, which illustrates how expensive a naive persistence path can be. The constraint we take from all three is that any design copying ciphertexts twice is likely to lose.
Research Program
We will build a planning pass on top of an existing FHE compiler's operation graph. For each candidate cut point $c$ (a position in the static schedule), the pass computes the live set and its size $S(c)$ in bytes. It excludes evaluation keys, which are immutable and are persisted once per job. Given a failure rate $\lambda$, persistence bandwidth $B$, and per-segment runtime $T_k$ between consecutive chosen cuts, the planner selects a cut set $C$ that minimizes expected overhead:
$$ \mathrm{cost}(C) = \sum_{c \in C} \frac{S(c)}{B} + \lambda \sum_{k} \frac{T_k^2}{2}, $$
The second term is the expected re-execution under failures that arrive as a Poisson process, the standard first-order checkpointing approximation. The schedule is linear and $S(c)$ is known everywhere, so the selection is a one-dimensional dynamic program over schedule positions.
The interesting structure comes from the levels. In leveled schemes such as CKKS, a ciphertext just before bootstrapping (Bootstrapping for Approximate Homomorphic Encryption) is many times smaller than one just after. Deep networks need high-degree polynomial activations (SecureNets), and therefore many bootstraps. That supplies a regular series of cheap cut points.
The runtime writes the live set at each chosen cut asynchronously to persistent memory or NVMe, overlapped with the next segment's computation. It then performs a single ordered commit of the schedule index. Within a segment, the compiler forbids writing over any buffer the segment has read, so re-execution from the last commit is idempotent.
We will also test the plan's correctness with a crash-testing harness in the style of Chipmunk and bounded black-box crash testing. Because the schedule is static, the harness can inject crashes at every commit boundary and at sampled points inside segments, including torn writes of the live set.
The simulation-to-silicon direction enters as a measurement discipline, not as a hardware build. Prior work documents that architectural models assume linear event costs and idealized buses, and so miss contention and thermal throttling (empirical CPU power modelling, GuaranTEE). We will plan once with an idealized cost model (operation counts times microbenchmarked per-operation latency) and once with latencies profiled during sustained full-length runs. We will then report how far measured overhead departs from predicted overhead. The real asynchronous checkpoint traffic competes with FHE's own memory traffic, and that interference is the effect an idealized model would miss. Projections onto simulated accelerators such as F1 will be clearly labeled as projections.
Baselines
The naive reference point has two parts. The first is the unmodified FHE runtime with no persistence, which defines zero overhead and also shows how much work is lost when a crash forces a restart from scratch. The second is restart-from-scratch under injected failures, which gives the expected completion time an operator faces today. Every other method must be judged against the second number: any scheme whose overhead exceeds the expected lost work is not worth deploying.
The strongest practical competitor is periodic host checkpointing at a fixed interval. It dumps the accelerator or process memory, keys included, to the same NVMe or persistent-memory device. Each run will use the interval that the same cost formula prescribes, so the baseline is tuned with the same failure-rate knowledge our planner has. This is the approach a systems engineer would deploy tomorrow. To count as beating it, we must lower expected completion time at matched failure rates, with the same hardware, the same storage device, and the same workload binaries.
The ablation that isolates our key ingredient is a level-blind, live-set-aware checkpoint taken at every bootstrapping boundary. It saves only live ciphertexts and excludes keys, but it does not optimize cut placement. Comparing against it separates the gain from "know what is live and immutable" from the gain from "pick cuts where the live set is smallest". If this ablation matches the full planner, the optimizer is unnecessary, and we will report that.
A transactional baseline wraps each ciphertext update in undo/redo logging on persistent memory, mimicking standard persistent-memory libraries. It shows the cost of ignoring FHE's write-once structure. APEX is a reminder that well-engineered logging can still recover quickly, at roughly 42 ms, so we will tune this baseline carefully instead of treating it as a strawman.
On published numbers: there is no reported result found on Lacuna for crash-recovery or checkpoint overhead of any FHE workload or accelerator. The reported workload references are F1's 20 minutes in software versus 241 ms in simulation for CIFAR-10 inference (F1), and APACHE's simulated 4597x speedup on encrypted database queries over CPU (APACHE). These anchor the runtimes we expect, not the overheads.
Why not just…?
Why not just checkpoint from the host to an NVMe drive at epoch boundaries? This is the most serious threat, and we have made it a baseline instead of arguing it away. The file's evidence against it, multi-gigabyte keys and slow storage stacks, is weaker than it looks, because keys never change and need to be saved only once. Some of the case against naive checkpointing is exactly what our design exploits. What remains is the open question of whether choosing where to cut beats choosing when to cut. The level-blind ablation and the tuned periodic baseline settle it. If a well-placed epoch checkpoint comes within noise of our planner, the honest conclusion is that FHE crash consistency is a solved engineering problem once one notices key immutability, and the paper becomes a measurement study.
Why not just make FHE computations short enough that crashes do not matter? For single inferences on a hypothetical accelerator this is largely right: F1 reports 241 ms for CIFAR-10 in simulation, and we would not checkpoint such a job. The regime we target is different. It covers long jobs that exist today on commodity silicon: the 20-minute software inference, encrypted logistic-regression training (HELR), encrypted database scans, and large batched inference in the CryptoNets style (CryptoNets), where amortization deliberately makes jobs long. These jobs often run on preemptible cloud machines, where interruptions are frequent. Shallower circuits trade accuracy for depth (SecureNets). We will report the job length below which our scheme stops paying off, so readers can see where this alternative wins.
Why not just trust a simulator to evaluate the scheme? Our overhead comes from checkpoint writes competing with FHE's own heavy memory traffic. That is the kind of shared-resource contention which instruction-level models are documented to underestimate (GuaranTEE, empirical CPU power modelling). We therefore measure on real CPUs, GPUs, and storage, and report the gap between idealized-model plans and plans built from measured profiles as a result in its own right.
Why not just use standard undo/redo transactions on persistent memory? FHE operations write fresh outputs, so an undo log would copy data that was never going to be overwritten, doubling writes on a medium where writes are the slow, wearing direction. The transactional baseline measures this directly. If it turns out competitive, that would contradict our premise that write-once dataflow removes the need for logging.
Proposed Experiments
The workloads come from the file's shared benchmarks. They are LoLa-MNIST and LoLa-CIFAR inference, ResNet-20 (bootstrapping-heavy), HELR logistic regression training, encrypted database lookups in the HE³DB style, and the Penn Treebank LSTM used by MemFHE. Each runs in CKKS or BFV, as appropriate, on a CPU software library and on a GPU, with NVMe storage and, where available, byte-addressable persistent memory.
We will vary failure rate across values representative of power faults on one end and spot preemption on the other. The metrics are steady-state slowdown with no failures, expected completion time under injected failures, bytes persisted per job, recovery latency, and storage write volume as a proxy for wear.
Three checks are decisive. First, bit-exact recovery: across exhaustive commit-boundary crashes and sampled torn writes, every recovered decryption must match the uninterrupted run exactly. A single mismatch falsifies the idempotence argument. Second, the planner must beat both the tuned periodic baseline and the level-blind ablation on expected completion time for ResNet-20 and HELR, the deep, bootstrapping-heavy workloads where level-aware cuts should matter most. Third, the error between predicted and measured overhead must be reported for idealized-model and profiled plans; if the two plans differ, that measures how much the simulation-to-silicon gap matters for this problem. A null result on the second check, with a pass on the first, would still establish that FHE needs no logging for crash consistency, which no paper in the file has shown.
References
- F1: A Fast and Programmable Accelerator for Fully Homomorphic Encryption (Extended Version)
- FHEmem: A Processing In-Memory Accelerator for Fully Homomorphic Encryption
- APACHE: A Processing-Near-Memory Architecture for Multi-Scheme Fully Homomorphic Encryption
- MemFHE: End-to-end Computing with Fully Homomorphic Encryption in Memory
- SoK: Fully Homomorphic Encryption Accelerators
- The Parallel Persistent Memory Model
- Execution of NVRAM Programs with Persistent Stack
- SplitFS: reducing software overhead in file systems for persistent memory
- Bootstrapping for Approximate Homomorphic Encryption
- SecureNets: Secure Inference of Deep Neural Networks on an Untrusted Cloud
- Chipmunk: Investigating Crash-Consistency in Persistent-Memory File Systems
- Finding Crash-Consistency Bugs with Bounded Black-Box Crash Testing
- Accurate and stable empirical CPU power modelling for multi- and many-core systems
- GuaranTEE: Towards Attestable and Private ML with CCA
- APEX: A High-Performance Learned Index on Persistent Memory
- CryptoNets: Applying Neural Networks to Encrypted Data with High Throughput and Accuracy