GenBinaryPatches implementation.