On Tue, Nov 5, 2024 at 11:52 AM ron minnich <rminnich@gmail.com> wrote:
I keep wondering if this assertion of code difference or lack thereof can be tested. Are not all these sources available? Which bits are missing?

Yes. Great question.

https://people.freebsd.org/~imp/pmap/pmap.32v

has the functions as I extracted them for the diff numbers I posted before. The TUHS archive links
are at:

https://www.tuhs.org/cgi-bin/utree.pl?file=V7/usr/sys/sys/subr.c
https://www.tuhs.org/cgi-bin/utree.pl?file=4BSD/usr/src/sys/sys/subr.c
https://www.tuhs.org/cgi-bin/utree.pl?file=4.2BSD/usr/src/sys/sys/ufs_bmap.c
https://github.com/sergev/4.4BSD-Lite2/blob/master/usr/src/sys/ufs/ufs/ufs_bmap.c

in case anybody wants to check my math or characterizations about the differences.

Warner
 
On Tue, Nov 5, 2024 at 9:55 AM Noel Chiappa <jnc@mercury.lcs.mit.edu> wrote:
    > From: Warner Losh

    >> On Mon, Nov 4, 2024 at 8:14PM Larry McVoy wrote:

    >> The bmap implementations I saw were bit for bit identical, same code,
    >> same variables, same style, same indentation. I'm 100% sure they were
    >> not independent.

    > They are different in 4.3BSD. They are different in 4.2BSD (but less
    > different). The underlying filesystems are different on disk, so they
    > routines have to be different.

That last sentence points out something important that people need to remember
in this discussion: in between 4.1 and 4.2 (technically, in 4.1B), BSD
switched to the BSD Fast File System, so I very much doubt that the low-level
(i.e. logical file block to disk block) file system code in anything after
4.1A looks much like the AT+T low-level file system code. (I have no idea how
the BSD code compares to the Linux file system code, but that's between the
Linux people, and Berkeley.)

        Noel