The query that does it is this:
RemovedFileSize = await cmd.ExecuteScalarInt64Async($@"
SELECT SUM(""C"".""Length"")
FROM
""{m_tablename}"" ""A"",
""FileLookup"" ""B"",
""Blockset"" ""C"",
""Metadataset"" ""D""
WHERE
""A"".""FileID"" = ""B"".""ID""
AND (
""B"".""BlocksetID"" = ""C"".""ID""
OR (
""B"".""MetadataID"" = ""D"".""ID""
AND ""D"".""BlocksetID"" = ""C"".""ID""
)
)
", 0, token)
.ConfigureAwait(false);
So what it counts is the size of the files that are removed. It then takes the sum of this number from all filesets and returns it as the “reduction”.
This would be correct if there was no deduplication. But it is quite possible that the same file exists in all versions unmodified, and removing the version does not affect the storage at all.
I have created an issue for tracking this.