in reply to Re^8: Search hex string in vary large binary file
in thread Search hex string in vary large binary file
So, you're benchmarking a script that finds what the OP is looking for; against a script that doesn't
The fix is to change return !!$tag->{HDVD}; to return $tag->{HDVD} && $tag->{HDVD}==2;. The check was set up like that initially to match the "AtomicParsley" check, which was just meant to be a quick double-check on the results.
on files that don't contain it
Do you think the OP has the flag set in every one of the files? If there's only one file that doesn't have the flag set, scanning will be slower overall. Even if every file were to have the flag set, scanning is only fast if the flag appears near the beginning of every file. The MP4::Info solution appears to be fast regardless of whether the flag is set or not.
using a "ready made solution", that you had to patch
The patch takes a few clicks to find on RT and applies cleanly. What is the problem?
Yeah right!
Considering I'm not even an expert on the file format and the set of input data I happened to have lying around may not be representative, I'd actually appreciate it if someone were to find an actual issue with the MP4::Info solution. At the moment it seems like you're just trying to shout it down without even looking at it.
|
|---|