it doesn't write the file to disk until the whole file is ready to go, or something, so that if you get a power cut, you don't lose the original file
It's called
soft updates, which is based on concept of
atomic commit.
Basically it does write to disk right away, but it does it in a way that the filesystem logical structure cannot get corrupted even if power is lost. The final single write replaces the previous "snapshot" of the state of the filesystem with a new one. If power is lost before the final write can be made, the filesystem automagically rolls back to previous state.
Simple (and simplified) way to visualise this is think about filesystem metadata as a tree: Trunk is the root directory. Branches are the subdirectories, leaves are the files. When changes occur to this tree, PFS3 updates clone of the tree structure in memory. When PFS3 does the "commit" it writes the file structure to disk in reverse order (from top down) [actually it only writes the changed parts, but it uses free blocks, it doesn't modify the original tree at all]. The final write "plants" the new tree, replacing the old one. If the write was successful, the storage held by the now obsoleted old tree parts are released for future use.
This is different from
filesystem journaling SFS has.