leetbit
ExperimentstableConducted Jul 8, 2026Updated Jul 12, 20266 min read

FUSE lookup latency under entry caching

Measuring the cost of a path lookup through atlas-fs with and without the kernel's entry cache, to check whether the conservative TTLs from ADR-003 buy what they were supposed to.

Hypothesis
Enabling entry caching with a short TTL removes most of the per-component upcall cost on repeated lookups, without materially raising the risk of a stale hit for read-mostly content.
Outcome
Confirmed. Warm repeated lookups dropped from ~48 µs to ~6 µs per component; cold-path cost was unchanged, as expected. No stale hits were observed over the read-only workload.

The point of this run was not "is caching faster" — of course it is — but whether atlas-fs's conservative caching from ADR-003 is conservative to the point of being useless. If the TTL is so short that nothing is ever warm, the safety is free only because the cache is.

Method#

Both VMs boot from named snapshots so the kernel starts cold. atlas-fs is mounted read-only; the same five-deep path is resolved 10,000 times per condition. The only variable is whether entry caching is enabled.

  condition A                 condition B
  caching OFF                 caching ON (TTL 1s)
      │                            │
  every lookup ──► upcall      first lookup ──► upcall
                               repeat  ──► served from dcache

Latency is the median per-component resolve time, measured in the guest with a bpftrace probe so the harness itself stays out of the number.

Results#

ConditionCold lookupWarm repeatUpcalls / 1k
Caching off47 µs48 µs5000
Caching on (TTL 1 s)49 µs6 µs41
Reading the table
Cold cost is unchanged — the first touch still pays for the upcall either way. The win is entirely on repeats, where the kernel serves from its own dcache and never crosses into userspace.

Discussion#

The short TTL is enough: within a single interactive session the same directories are hit far more than once per second, so the cache stays warm where it matters and expires before staleness becomes a correctness question. This is the behaviour the dentry cache notes predicted, now with numbers from real hardware rather than a hand-wave.

Apparatus

  • vfs-lab and fuse-lab VMs on the Kernel Workbench, booted from clean snapshots
  • atlas-fs built at commit a1b2c3d, mounted read-only
  • bpftrace probe on fuse_dentry_revalidate; time measured with clock_gettime(CLOCK_MONOTONIC)
  • 10,000 lookups per condition, five-deep paths, medians reported

Relations

where else this lives in the system
conducted Jul 8, 2026rev 2last revised Jul 12, 2026