Hi- I'm doing a project that involves, among other things, measuring the block write overhead that reference counting snapshots imposes in btrfs, and I wanted to run my methodology by the mailing list, to see if there were any holes in it. I'm counting backrefs here as reference counts, since they're used for the same purpose. Essentially, I'm using extent_buffers to track reference count I/O. In the functions __btrfs_inc_extent_ref and __btrfs_free_extent, I check whether the reference count was incremented above one or decremented to a minimum of one, respectively; if so, I mark the extent_buffer as having been used for reference counts. Conversely, if the buffer was employed for allocation or deallocation, I mark that; to this end, I also mark the buffers used in alloc_reserved_tree_block. I also mark extent_buffers written in write_one_cache_group, create_pending_block_groups, and btrfs_remove_block_group as having been accessed for block groups. Finally, in write_one_eb, I count each extent_buffer that has only been marked for reference counting and use the total as an indicator of the overhead incurred. Does this seem accurate? Are there any points at which I might be missing I/O that goes to extent buffers that store reference counts? I'm deliberately ignoring side-effects of reference count modification, like B-Tree splitting, as that I/O isn't related to the algorithm and would be difficult to track in a verifiable fashion. Thanks, Chris Dragga -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html