Amiga.org

Amiga computer related discussion => Amiga Software Issues and Discussion => Topic started by: freqmax on April 20, 2011, 02:53:54 AM

Title: Performance difference between PFS3 and UFS2 ?
Post by: freqmax on April 20, 2011, 02:53:54 AM
How is the performance difference between PFS3 (http://www.softhut.com/pfs3.html) (Amiga) and UFS2 (http://en.wikipedia.org/wiki/Unix_File_System) (FreeBSD) ..?

Of course considering factors like CPU speed and architecture, memory speed, disc controller, disc bus, disc drive.
Title: Re: Perforrmance difference between PFS3 and UFS2 ?
Post by: kolla on April 20, 2011, 05:05:24 AM
Port PFS3 to FreeBSD and find out.
Title: Re: Perforrmance difference between PFS3 and UFS2 ?
Post by: olsen on April 20, 2011, 07:15:41 AM
Quote from: kolla;632540
Port PFS3 to FreeBSD and find out.


Good one ;)  But there would be some merit to analyze what PFS3 does, and how well, too. As far as I know, no detailed analysis of PFS3 was ever published which goes into the details of how the storage allocation works, how fragmentation is kept at bay, and how the data structures look like. By comparison, all this is known and documented for the old Unix file system, and even the Amiga's various own OFS/FFS/DCFS flavours.
Title: Re: Perforrmance difference between PFS3 and UFS2 ?
Post by: Thomas on April 20, 2011, 09:11:26 AM
Quote
As far as I know, no detailed analysis of PFS3 was ever published which goes into the details of how the storage allocation works, how fragmentation is kept at bay, and how the data structures look like.


Data structures were delivered with the product in form of a C header file and the documentation contains a bit of information about how fragmentation is kept small. IIRC it always allocates new files in the largest contiguous free area.
Title: Re: Perforrmance difference between PFS3 and UFS2 ?
Post by: olsen on April 20, 2011, 10:06:30 AM
Quote from: Thomas;632553
Data structures were delivered with the product in form of a C header file and the documentation contains a bit of information about how fragmentation is kept small. IIRC it always allocates new files in the largest contiguous free area.


I was hoping for documentation, not data structure declarations ;)  As with data structures, algorithms and the intentions behind them are often hard to fathom in file systems. You wouldn't know how the Amiga FFS, for example, does its job by looking at the source code. You have to read and understand the whole thing, look at what is written to the storage medium. It's better if the designer goes to some lengths to explain what is going on inside the code.

As for managing fragmentation, it's one of the toughest tasks in a file system. Using the largest free fragment by default is not necessarily a winning strategy, as there might be other free fragments which are shorter and might fit the size requirements better without wasting additional space. Also, one has to consider the distance between the end of the file and the place where the new data goes. XFS, for example, keeps track of both proximity of free space and size of free space in two separate b-tree data structures. Through this XFS can both find the smallest free space fragment that fits, and which is closest to the end of the file to be extended.