Re: [Qemu-devel] [PATCH v4 15/23] qemu-img: Add find_nonzero()

2017-09-27 Thread John Snow
On 09/13/2017 12:03 PM, Eric Blake wrote: > During 'qemu-img compare', when we are checking that an allocated > portion of one file is all zeros, we don't need to waste time > computing how many additional sectors after the first non-zero > byte are also non-zero. Create a new helper find_nonzer

[Qemu-devel] [PATCH v4 15/23] qemu-img: Add find_nonzero()

2017-09-13 Thread Eric Blake
During 'qemu-img compare', when we are checking that an allocated portion of one file is all zeros, we don't need to waste time computing how many additional sectors after the first non-zero byte are also non-zero. Create a new helper find_nonzero() to do the check for a first non-zero sector, and