{
  "slug": "squirrelfs",
  "term": "SquirrelFS",
  "aliases": [],
  "definition": "SquirrelFS is a research persistent-memory filesystem that uses Rust typestate to enforce crash-consistency ordering rules at compile time.",
  "note": "Ordering: Synchronous Soft Updates requires an inode to be initialized and persisted before a directory entry points to it. Separate persistence states (Dirty, InFlight, Clean) and operation states encode these prerequisites; a flush alone does not complete the transition to Clean. [osdi24]\n\nDurability and atomicity: The prototype makes syscall updates durable before return, making fsync a no-op. Metadata operations, including rename, are crash-atomic, but file-data writes are not. A crash during a write can therefore leave a partial update even though a completed write is durable. [osdi24]\n\nTrust boundary: Type checking enforces the encoded order, not the correctness of that order or of each transition's implementation. Variable-sized collections need additional reasoning: page ranges share one typestate, leaving per-page work inside trusted transition functions. The design also uses Alloy model checking and runtime tests; successful compilation is not full filesystem verification. [osdi24]\n\nImplementation: The pinned memcpy_nt helper supplements its non-temporal copy with cache-line flushing at non-8-byte-aligned destination boundaries. It invokes a store fence when its fence argument is true. Choosing a cache-bypassing copy is therefore not enough to explain how the entire byte range becomes persistent. [pm-code]",
  "status": "research",
  "advantages": [],
  "limitations": [],
  "related": [
    "soft-updates",
    "crash-consistency",
    "persistence-ordering"
  ],
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "updated": "2026-11-16",
  "citations": [
    {
      "id": "osdi24",
      "title": "LeBlanc, Taylor, Bornholt and Chidambaram. SquirrelFS: using the Rust compiler to check file-system crash consistency. OSDI 2024, sections 3-5.",
      "url": "https://www.usenix.org/system/files/osdi24-leblanc.pdf",
      "accessed": "2026-11-16"
    },
    {
      "id": "pm-code",
      "title": "SquirrelFS authors. pm.rs: memcpy_nt, flush_edge_cachelines and conditional fencing; revision e49c0125effc7e3ebd3b834d554ac4a498667b83.",
      "url": "https://github.com/utsaslab/squirrelfs/blob/e49c0125effc7e3ebd3b834d554ac4a498667b83/linux/fs/squirrelfs/pm.rs",
      "accessed": "2026-11-16"
    },
    {
      "id": "artifact",
      "title": "SquirrelFS authors. Artifact README: modified Linux 6.3, persistent-memory prerequisites and evaluation instructions.",
      "url": "https://github.com/utsaslab/squirrelfs/blob/e49c0125effc7e3ebd3b834d554ac4a498667b83/README.md",
      "accessed": "2026-11-16"
    },
    {
      "id": "hesela-soft",
      "title": "Hesela. Soft updates and metadata ordering.",
      "url": "https://hesela.com/analyses/soft-updates-metadata-ordering/",
      "accessed": "2026-11-16"
    }
  ],
  "provenance": [
    "Primary-paper and pinned-source review, not a filesystem execution, crash experiment or performance replication.",
    "The 2024 evaluation uses an x86 persistent-memory setup; results are not a guarantee for arbitrary storage or Rust programs. [osdi24]",
    "The inspected repository revision is recorded separately from the historical paper. Its modified-kernel and persistent-memory prerequisites were not installed. [artifact]"
  ]
}
