Skip to content

mount: stop running the page-cache punch on Windows, where it is a no-op - #120

Merged
zcsizmadia merged 1 commit into
mainfrom
fix/winfsp-inert-punch
Sep 13, 2026
Merged

zcsizmadia merged 1 commit into
mainfrom
fix/winfsp-inert-punch

Conversation

@zcsizmadia

Copy link
Copy Markdown
Collaborator

Refs #88. Not a fix for the flake, and none is claimed — see the issue for why the one remaining
candidate is not worth changing while the flake is dormant.

WinFsp-FUSE's fuse_invalidate_path is a stub. inc/fuse3/fuse.h, unchanged from v2.0 through
master (CI pins 2.1.25156):

FSP_FUSE_SYM(
int fuse3_invalidate_path(struct fuse3 *f, const char *path),
{
    (void)f;
    (void)path;
    return -ENOENT;
})

winfsp_fuse.h maps that spelling onto the standard one, and FSP_FUSE_SYM expands to
static inline, so the call never leaves the translation unit, never reaches the DLL, and
invalidates nothing.

Direction A has therefore been running a thread and a queue whose only purpose is to call a no-op a
few thousand times per invalidation burst. This skips both there.

Nothing is lost. The change-notification bridge that reads the same hook is Linux-only, and the punch
was already doing nothing.

Why the comment mattered more than the thread

The comment this replaces said WinFsp "showed no difference from the page-cache change either way, so
this costs nothing measurable there". The measurement was right and the explanation was wrong: it is
free because it does nothing. Left unsaid, it implies Direction A has a cache-coherence mechanism it
does not have — which is precisely the assumption behind two of the three fixes #88 has tried and
refuted, including #111's parent-directory punch, whose 3 pass / 2 fail sample was measuring an
inert call.

Testing

Linux, locally: 146/146 unit tests, 31/31 filesystem conformance, 12/12 change notification. The
Windows path is compile-checked and battery-checked by CI, which is the only place a WinFsp mount
runs.

🤖 Generated with Claude Code

WinFsp-FUSE's fuse_invalidate_path is a stub. inc/fuse3/fuse.h, unchanged
from v2.0 through master:

    FSP_FUSE_SYM(
    int fuse3_invalidate_path(struct fuse3 *f, const char *path),
    {
        (void)f;
        (void)path;
        return -ENOENT;
    })

winfsp_fuse.h maps that spelling onto the standard one and FSP_FUSE_SYM
expands to `static inline`, so the call never leaves the translation
unit, never reaches the DLL, and invalidates nothing.

So Direction A has been running a thread and a queue whose only purpose
is to call a no-op a few thousand times per invalidation burst. Skip
both there. Nothing is lost: the change-notification bridge that also
reads the hook is Linux-only, and the punch was already doing nothing.

The comment this replaces recorded that WinFsp "showed no difference
from the page-cache change either way" and concluded it was free there.
The measurement was right; the explanation was not. It is free because
it does nothing, and leaving that unsaid implies Direction A has a cache
coherence mechanism it does not have - which is the assumption behind
two of the three fixes #88 has already tried and refuted.

No fix for #88 here, and none is claimed. What WinFsp does offer is a
mount option, -o FileInfoTimeout / -o DirInfoTimeout, which nothing has
tried yet; the issue records why that is not worth changing while the
flake is dormant and unmeasurable.

Verified on Linux: 146/146 unit tests, 31/31 filesystem conformance,
12/12 change notification. The Windows path is compile-and-battery
checked by CI.

Refs #88

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@zcsizmadia
zcsizmadia merged commit feb7970 into main Sep 13, 2026
6 checks passed
@zcsizmadia
zcsizmadia deleted the fix/winfsp-inert-punch branch September 13, 2026 23:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ci: mounted conformance batteries fail intermittently on the git checks

1 participant