Actually, the reason that this is expanded out into a separate loop that does less than `git_buf_text_gather_stats` was that performance profiling showed that we were spending close to 30% of diff time in running that routine and by making a smaller version that was tuned just to detecting binary, we were able to dramatically reduce that time. The extra data that `git_buf_text_gather_stats` collects should be irrelevant and this routine should be returning that same answer to "is the file binary" as `git_buf_text_gather_stats`. If you have a file where the answer to the two routines don't match, then that should be considered a bug in this routine.