From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Message-ID: <5547EDD7.9000903@kernel.dk> Date: Mon, 04 May 2015 16:08:23 -0600 From: Jens Axboe MIME-Version: 1.0 Subject: Re: [Bug report] Runtime, IOPS, bandwidth recorded incorrectly if small size with time_based References: <5547D99E.4080103@kernel.dk> <5547EC73.5030001@kernel.dk> In-Reply-To: <5547EC73.5030001@kernel.dk> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit To: Brian Fulton Cc: Akash Verma , fio List-ID: On 05/04/2015 04:02 PM, Jens Axboe wrote: > On 05/04/2015 03:25 PM, Brian Fulton wrote: >> Hi Jens, >> >> I've been actively looking at this bug. It was introduced with change >> e5437a073e658e8154b9e87bab5c7b3b06ed4255 >> (https://github.com/axboe/fio/commit/e5437a073e658e8154b9e87bab5c7b3b06ed4255). >> >> >> In this change, the time granularity was changed from microseconds to >> milliseconds. This change assumes that all loops take at least 1ms to >> complete. This is not always true and tests where the loop gets >> processed, regularly, in sub-millisecond time result in many zeroes >> being summed which, ultimately, causes a completely inaccurate >> runtime. >> >> I have a fix for this, but I want to verify that it doesn't break >> anything as it is changing the way the runtime is being calculated. >> >> We are using fio version 2.2.6, though this issue should still be >> present in the latest version (2.2.7). >> >> >> Below is a patch fix based of the latest version of fio 2.2.7: > > Thanks, that makes more sense. Akash, can you confirm that this fixes it > for you? Committed: http://git.kernel.dk/?p=fio.git;a=commit;h=95603b7470fac1917cb11bc686e60b4339f8a2fc Brian, I changed a few things: - DDIR_RWDIR_CNT exists for array sizing - You need a ',' after that zero to clear the array - Style -- Jens Axboe