http://www.perlmonks.org?node_id=468774


in reply to Re: Comparing duplicate pictures in different directories
in thread Comparing duplicate pictures in different directories

If you compute the hash you can save it and run it again later when more files are added. If you go the diff or eq route, you have to read the entire file for each compare.

He doesn't seem to take advantage of hash-caching here, but it would also speed up subsequent compares of the file against the next potential duplicate.
  • Comment on Re^2: Comparing duplicate pictures in different directories