Subject: Re: Slowness (caching issues?) in dependency checking

From: Sergey Matveev <[email-masked]>
Date: Fri, 26 Aug 2022 19:09:01 +0300

Greetings!

I tried to reproduce any difference between all.suffix and
all.suffix.suffix2 targets, but completely do not see any.
All my measurements of running those targets takes nearly
the same amount of time. No noticeable overhead for .suffix2.

Various temporary and lock files are created during each redo
invocation, so maybe that is so huge filesystem's overhead? I run those
commands both on tmpfs and ZFS dataset and the latter works slower, but
again with no noticeable difference between those two targets. I looked
at debug output of those both commands and, as expected, the difference
only in additional OOD level check, that virtually has no cost.

I tried playing with REDO_NO_SYNC and sync attribute on filesystem
(actually now I just too lazy to check if any write happens during
redo-ifchange) and it plays no role.

So I really have no ideas, except for overhead of OS overhead, like new
process invocation, however I hardly believe in it, because one
additional statically-linked Go process startup time should be
negligible. There is no caching of OOD information in goredo, except for
temporary file with (already determined) OOD targets, that is not used
during "redo-ifchange all.suffix*" commands.

-- 
Sergey Matveev (http://www.stargrave.org/)
OpenPGP: 12AD 3268 9C66 0D42 6967  FD75 CB82 0563 2107 AD8A