Hello community,
here is the log from the commit of package fio for openSUSE:Factory checked in at 2015-04-05 02:04:26
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/fio (Old)
and /work/SRC/openSUSE:Factory/.fio.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "fio"
Changes:
--------
--- /work/SRC/openSUSE:Factory/fio/fio.changes 2015-01-30 11:00:30.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.fio.new/fio.changes 2015-04-05 02:04:34.000000000 +0200
@@ -1,0 +2,12 @@
+Sat Apr 4 12:58:13 UTC 2015 - mpluskal@suse.com
+
+- Update to 2.2.6
+ * make per-thread IOPS more accurate
+ * man page updates
+ * misc bugfixes
+- Cleanup spec file with spec-cleaner
+- Update dependencies
+ * enable numa
+ * enable glusterfs
+
+-------------------------------------------------------------------
Old:
----
fio-2.2.5.tar.bz2
New:
----
fio-2.2.6.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ fio.spec ++++++
--- /var/tmp/diff_new_pack.xfkKfX/_old 2015-04-05 02:04:35.000000000 +0200
+++ /var/tmp/diff_new_pack.xfkKfX/_new 2015-04-05 02:04:35.000000000 +0200
@@ -1,7 +1,7 @@
#
# spec file for package fio
#
-# Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2012 Pascal Bleser
#
# All modifications and additions to the file contributed by third parties
@@ -18,20 +18,23 @@
Name: fio
-Version: 2.2.5
+Version: 2.2.6
Release: 0
Summary: Flexible I/O Tester/benchmarker
License: GPL-2.0
Group: System/Benchmark
-Source: http://brick.kernel.dk/snaps/fio-%{version}.tar.bz2
Url: http://freshmeat.net/projects/fio/
-BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Suggests: gnuplot
-Suggests: gfio
-BuildRequires: gcc
+Source: http://brick.kernel.dk/snaps/fio-%{version}.tar.bz2
BuildRequires: libaio-devel
-BuildRequires: make
BuildRequires: pkg-config
+BuildRequires: zlib-devel
+Suggests: gfio
+Suggests: gnuplot
+BuildRoot: %{_tmppath}/%{name}-%{version}-build
+%if 0%{?suse_version} > 1320
+BuildRequires: glusterfs-devel
+BuildRequires: libnuma-devel
+%endif
%description
fio is an I/O tool meant to be used both for benchmark and stress/hardware
@@ -47,39 +50,34 @@
Summary: Graphical front end for fio
Group: System/Benchmark
BuildRequires: gtk2-devel
-BuildRequires: zlib-devel
%description -n gfio
gfio is a gtk based graphical front-end for fio. It is often installed on the
testers workstation whereas fio would be installed on the server.
-
%prep
%setup -q -n "fio-%{version}"
%build
./configure --enable-gfio
-%__make \
+make \
V=1 \
OPTFLAGS="%{optflags}" \
- CC="%__cc" \
+ CC="gcc" \
prefix="%{_prefix}" \
libdir="%{_libdir}/fio" \
mandir="%{_mandir}"
%install
-%__make \
+make \
V=1 \
- DESTDIR="%{buildroot}" \
+ DESTDIR=%{buildroot} \
prefix="%{_prefix}" \
bindir="%{_bindir}" \
libdir="%{_libdir}/fio" \
mandir="%{_mandir}" \
install
-%clean
-%{?buildroot:%__rm -rf "%{buildroot}"}
-
%files
%defattr(-,root,root)
%doc COPYING README examples
@@ -92,9 +90,9 @@
%{_bindir}/fio-dedupe
%{_bindir}/fio-genzipf
%{_datadir}/fio
-%doc %{_mandir}/man1/fio.1%{ext_man}
-%doc %{_mandir}/man1/fio_generate_plots.1%{ext_man}
-%doc %{_mandir}/man1/fio2gnuplot.1%{ext_man}
+%{_mandir}/man1/fio.1%{ext_man}
+%{_mandir}/man1/fio_generate_plots.1%{ext_man}
+%{_mandir}/man1/fio2gnuplot.1%{ext_man}
%files -n gfio
%defattr(-,root,root)
++++++ fio-2.2.5.tar.bz2 -> fio-2.2.6.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/FIO-VERSION-GEN new/fio-2.2.6/FIO-VERSION-GEN
--- old/fio-2.2.5/FIO-VERSION-GEN 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/FIO-VERSION-GEN 2015-02-27 16:30:04.000000000 +0100
@@ -1,7 +1,7 @@
#!/bin/sh
GVF=FIO-VERSION-FILE
-DEF_VER=fio-2.2.5
+DEF_VER=fio-2.2.6
LF='
'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/HOWTO new/fio-2.2.6/HOWTO
--- old/fio-2.2.5/HOWTO 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/HOWTO 2015-02-27 16:30:04.000000000 +0100
@@ -919,10 +919,10 @@
random IO. If this option is given, fio will just get a
new random offset without looking at past io history. This
means that some blocks may not be read or written, and that
- some blocks may be read/written more than once. This option
- is mutually exclusive with verify= if and only if multiple
- blocksizes (via bsrange=) are used, since fio only tracks
- complete rewrites of blocks.
+ some blocks may be read/written more than once. If this option
+ is used with verify= and multiple blocksizes (via bsrange=),
+ only intact blocks are verified, i.e., partially-overwritten
+ blocks are ignored.
softrandommap=bool See norandommap. If fio runs with the random block map
enabled and it fails to allocate the map, if this option is
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/LICENSE new/fio-2.2.6/LICENSE
--- old/fio-2.2.5/LICENSE 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/LICENSE 1970-01-01 01:00:00.000000000 +0100
@@ -1,17 +0,0 @@
-As specified by the COPYING file, fio is free software published under version
-2 of the GPL license. That covers the copying part of the license. By using fio,
-you are also promising to uphold the following moral obligations:
-
-- If you publish results that are done using fio, it must be clearly stated
- that fio was used. The specific version should also be listed.
-
-- If you develop features or bug fixes for fio, they should be sent upstream
- for inclusion into the main repository. This isn't specific to fio, that
- is a general rule for any open source project. It's just the Right Thing
- to do. Plus it means that you don't have to maintain the feature or change
- internally. In the long run, this is saving you a lot of time.
-
-I would consider the above to fall under "common courtesy", but since
-people tend to have differing opinions of that, it doesn't hurt to spell out
-my expectations clearly.
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/MORAL-LICENSE new/fio-2.2.6/MORAL-LICENSE
--- old/fio-2.2.5/MORAL-LICENSE 1970-01-01 01:00:00.000000000 +0100
+++ new/fio-2.2.6/MORAL-LICENSE 2015-02-27 16:30:04.000000000 +0100
@@ -0,0 +1,17 @@
+As specified by the COPYING file, fio is free software published under version
+2 of the GPL license. That covers the copying part of the license. When using
+fio, you are encouraged to uphold the following moral obligations:
+
+- If you publish results that are done using fio, it should be clearly stated
+ that fio was used. The specific version should also be listed.
+
+- If you develop features or bug fixes for fio, they should be sent upstream
+ for inclusion into the main repository. This isn't specific to fio, that
+ is a general rule for any open source project. It's just the Right Thing
+ to do. Plus it means that you don't have to maintain the feature or change
+ internally. In the long run, this is saving you a lot of time.
+
+I would consider the above to fall under "common courtesy", but since
+people tend to have differing opinions of that, it doesn't hurt to spell out
+my expectations clearly.
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/README new/fio-2.2.6/README
--- old/fio-2.2.5/README 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/README 2015-02-27 16:30:04.000000000 +0100
@@ -311,7 +311,7 @@
fio --client=server --remote-config /path/to/file.fio
-Then the fio serer will open this local (to the server) job file instead
+Then the fio server will open this local (to the server) job file instead
of being passed one from the client.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/arch/arch-arm.h new/fio-2.2.6/arch/arch-arm.h
--- old/fio-2.2.5/arch/arch-arm.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/arch/arch-arm.h 2015-02-27 16:30:04.000000000 +0100
@@ -19,7 +19,8 @@
#endif
#if defined (__ARM_ARCH_4__) || defined (__ARM_ARCH_4T__) \
- || defined (__ARM_ARCH_5__) || defined (__ARM_ARCH_5T__) || defined (__ARM_ARCH_5TE__) || defined (__ARM_ARCH_5TEJ__) \
+ || defined (__ARM_ARCH_5__) || defined (__ARM_ARCH_5T__) || defined (__ARM_ARCH_5E__)\
+ || defined (__ARM_ARCH_5TE__) || defined (__ARM_ARCH_5TEJ__) \
|| defined(__ARM_ARCH_6__) || defined(__ARM_ARCH_6J__) || defined(__ARM_ARCH_6Z__) || defined(__ARM_ARCH_6ZK__)
#define nop __asm__ __volatile__("mov\tr0,r0\t@ nop\n\t")
#define read_barrier() __asm__ __volatile__ ("" : : : "memory")
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/arch/arch-s390.h new/fio-2.2.6/arch/arch-s390.h
--- old/fio-2.2.5/arch/arch-s390.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/arch/arch-s390.h 2015-02-27 16:30:04.000000000 +0100
@@ -40,6 +40,7 @@
#define ARCH_CPU_CLOCK_CYCLES_PER_USEC 1
#define ARCH_HAVE_CPU_CLOCK
+#undef ARCH_CPU_CLOCK_WRAPS
#define ARCH_HAVE_INIT
extern int tsc_reliable;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/arch/arch.h new/fio-2.2.6/arch/arch.h
--- old/fio-2.2.5/arch/arch.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/arch/arch.h 2015-02-27 16:30:04.000000000 +0100
@@ -30,6 +30,8 @@
extern unsigned long arch_flags;
+#define ARCH_CPU_CLOCK_WRAPS
+
#if defined(__i386__)
#include "arch-x86.h"
#elif defined(__x86_64__)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/backend.c new/fio-2.2.6/backend.c
--- old/fio-2.2.5/backend.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/backend.c 2015-02-27 16:30:04.000000000 +0100
@@ -565,6 +565,8 @@
io_u->end_io = verify_io_u;
ddir = io_u->ddir;
+ if (!td->o.disable_slat)
+ fio_gettime(&io_u->start_time, NULL);
ret = td_io_queue(td, io_u);
switch (ret) {
@@ -656,13 +658,13 @@
if (!td->o.number_ios)
return 0;
- number_ios = ddir_rw_sum(td->this_io_blocks);
+ number_ios = ddir_rw_sum(td->io_blocks);
number_ios += td->io_u_queued + td->io_u_in_flight;
- return number_ios >= td->o.number_ios;
+ return number_ios >= (td->o.number_ios * td->loops);
}
-static int io_bytes_exceeded(struct thread_data *td)
+static int io_issue_bytes_exceeded(struct thread_data *td)
{
unsigned long long bytes, limit;
@@ -680,6 +682,29 @@
else
limit = td->o.size;
+ limit *= td->loops;
+ return bytes >= limit || exceeds_number_ios(td);
+}
+
+static int io_complete_bytes_exceeded(struct thread_data *td)
+{
+ unsigned long long bytes, limit;
+
+ if (td_rw(td))
+ bytes = td->this_io_bytes[DDIR_READ] + td->this_io_bytes[DDIR_WRITE];
+ else if (td_write(td))
+ bytes = td->this_io_bytes[DDIR_WRITE];
+ else if (td_read(td))
+ bytes = td->this_io_bytes[DDIR_READ];
+ else
+ bytes = td->this_io_bytes[DDIR_TRIM];
+
+ if (td->o.io_limit)
+ limit = td->o.io_limit;
+ else
+ limit = td->o.size;
+
+ limit *= td->loops;
return bytes >= limit || exceeds_number_ios(td);
}
@@ -703,18 +728,24 @@
lat_target_init(td);
+ total_bytes = td->o.size;
+ /*
+ * Allow random overwrite workloads to write up to io_limit
+ * before starting verification phase as 'size' doesn't apply.
+ */
+ if (td_write(td) && td_random(td) && td->o.norandommap)
+ total_bytes = max(total_bytes, (uint64_t) td->o.io_limit);
/*
* If verify_backlog is enabled, we'll run the verify in this
* handler as well. For that case, we may need up to twice the
* amount of bytes.
*/
- total_bytes = td->o.size;
if (td->o.verify != VERIFY_NONE &&
(td_write(td) && td->o.verify_backlog))
total_bytes += td->o.size;
while ((td->o.read_iolog_file && !flist_empty(&td->io_log_list)) ||
- (!flist_empty(&td->trim_list)) || !io_bytes_exceeded(td) ||
+ (!flist_empty(&td->trim_list)) || !io_issue_bytes_exceeded(td) ||
td->o.time_based) {
struct timeval comp_time;
struct io_u *io_u;
@@ -1231,7 +1262,7 @@
td_set_runstate(td, TD_RUNNING);
while ((td->o.read_iolog_file && !flist_empty(&td->io_log_list)) ||
- (!flist_empty(&td->trim_list)) || !io_bytes_exceeded(td)) {
+ (!flist_empty(&td->trim_list)) || !io_complete_bytes_exceeded(td)) {
struct io_u *io_u;
int ret;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/configure new/fio-2.2.6/configure
--- old/fio-2.2.5/configure 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/configure 2015-02-27 16:30:04.000000000 +0100
@@ -887,7 +887,7 @@
int main(int argc, char **argv)
{
struct bitmask *mask = numa_parse_nodestring(NULL);
- return 0;
+ return mask->size == 0;
}
EOF
if compile_prog "" "" "libnuma api"; then
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/examples/ssd-test.fio new/fio-2.2.6/examples/ssd-test.fio
--- old/fio-2.2.5/examples/ssd-test.fio 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/examples/ssd-test.fio 2015-02-27 16:30:04.000000000 +0100
@@ -14,7 +14,7 @@
bs=4k
ioengine=libaio
iodepth=4
-size=1g
+size=10g
direct=1
runtime=60
directory=/mount-point-of-ssd
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/filelock.c new/fio-2.2.6/filelock.c
--- old/fio-2.2.5/filelock.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/filelock.c 2015-02-27 16:30:04.000000000 +0100
@@ -101,7 +101,7 @@
return;
assert(flist_empty(&fld->list));
- fio_mutex_remove(&fld->lock);
+ __fio_mutex_remove(&fld->lock);
while (!flist_empty(&fld->free_list)) {
struct fio_filelock *ff;
@@ -109,7 +109,7 @@
ff = flist_first_entry(&fld->free_list, struct fio_filelock, list);
flist_del_init(&ff->list);
- fio_mutex_remove(&ff->lock);
+ __fio_mutex_remove(&ff->lock);
}
sfree(fld);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/fio.1 new/fio-2.2.6/fio.1
--- old/fio-2.2.5/fio.1 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/fio.1 2015-02-27 16:30:04.000000000 +0100
@@ -20,6 +20,9 @@
.BI \-\-output \fR=\fPfilename
Write output to \fIfilename\fR.
.TP
+.BI \-\-output-format \fR=\fPformat
+Set the reporting format to \fInormal\fR, \fIterse\fR, or \fIjson\fR.
+.TP
.BI \-\-runtime \fR=\fPruntime
Limit run time to \fIruntime\fR seconds.
.TP
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/fio.h new/fio-2.2.6/fio.h
--- old/fio-2.2.5/fio.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/fio.h 2015-02-27 16:30:04.000000000 +0100
@@ -240,6 +240,7 @@
*/
uint64_t io_issues[DDIR_RWDIR_CNT];
uint64_t io_issue_bytes[DDIR_RWDIR_CNT];
+ uint64_t loops;
/*
* Completions
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/gettime.c new/fio-2.2.6/gettime.c
--- old/fio-2.2.5/gettime.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/gettime.c 2015-02-27 16:30:04.000000000 +0100
@@ -17,6 +17,8 @@
static unsigned long cycles_per_usec;
static unsigned long inv_cycles_per_usec;
static uint64_t max_cycles_for_mult;
+#endif
+#ifdef ARCH_CPU_CLOCK_WRAPS
static unsigned long long cycles_start, cycles_wrap;
#endif
int tsc_reliable = 0;
@@ -171,6 +173,7 @@
#endif
t = get_cpu_clock();
+#ifdef ARCH_CPU_CLOCK_WRAPS
if (t < cycles_start && !cycles_wrap)
cycles_wrap = 1;
else if (cycles_wrap && t >= cycles_start && !tv->warned) {
@@ -179,6 +182,7 @@
}
t -= cycles_start;
+#endif
tv->last_cycles = t;
tv->last_tv_valid = 1;
#ifdef ARCH_CPU_CLOCK_CYCLES_PER_USEC
@@ -311,8 +315,10 @@
inv_cycles_per_usec = 16777216UL / cycles_per_usec;
max_cycles_for_mult = ~0ULL / inv_cycles_per_usec;
dprint(FD_TIME, "inv_cycles_per_usec=%lu\n", inv_cycles_per_usec);
+#ifdef ARCH_CPU_CLOCK_WRAPS
cycles_start = get_cpu_clock();
dprint(FD_TIME, "cycles_start=%llu\n", cycles_start);
+#endif
return 0;
}
#else
@@ -477,12 +483,20 @@
uint32_t last_seq;
int i;
- memset(&cpu_mask, 0, sizeof(cpu_mask));
+ if (fio_cpuset_init(&cpu_mask)) {
+ int __err = errno;
+
+ log_err("clock cpuset init failed: %s\n", strerror(__err));
+ goto err_out;
+ }
+
fio_cpu_set(&cpu_mask, t->cpu);
if (fio_setaffinity(gettid(), cpu_mask) == -1) {
- log_err("clock setaffinity failed\n");
- return (void *) 1;
+ int __err = errno;
+
+ log_err("clock setaffinity failed: %s\n", strerror(__err));
+ goto err;
}
pthread_mutex_lock(&t->lock);
@@ -518,9 +532,14 @@
* indefinitely. Check for that and return failure.
*/
if (!t->entries[i - 1].tsc && !t->entries[0].tsc)
- return (void *) 1;
+ goto err;
+ fio_cpuset_exit(&cpu_mask);
return NULL;
+err:
+ fio_cpuset_exit(&cpu_mask);
+err_out:
+ return (void *) 1;
}
static int clock_cmp(const void *p1, const void *p2)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/gettime.h new/fio-2.2.6/gettime.h
--- old/fio-2.2.5/gettime.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/gettime.h 2015-02-27 16:30:04.000000000 +0100
@@ -24,7 +24,7 @@
static inline int fio_gettime_offload(struct timeval *tv)
{
- size_t last_sec;
+ time_t last_sec;
if (!fio_tv)
return 0;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/idletime.c new/fio-2.2.6/idletime.c
--- old/fio-2.2.5/idletime.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/idletime.c 2015-02-27 16:30:04.000000000 +0100
@@ -43,16 +43,26 @@
return tunit / CALIBRATE_SCALE;
}
+static void free_cpu_affinity(struct idle_prof_thread *ipt)
+{
+#if defined(FIO_HAVE_CPU_AFFINITY)
+ fio_cpuset_exit(&ipt->cpu_mask);
+#endif
+}
+
static int set_cpu_affinity(struct idle_prof_thread *ipt)
{
#if defined(FIO_HAVE_CPU_AFFINITY)
- os_cpu_mask_t cpu_mask;
+ if (fio_cpuset_init(&ipt->cpu_mask)) {
+ log_err("fio: cpuset init failed\n");
+ return -1;
+ }
- memset(&cpu_mask, 0, sizeof(cpu_mask));
- fio_cpu_set(&cpu_mask, ipt->cpu);
+ fio_cpu_set(&ipt->cpu_mask, ipt->cpu);
- if (fio_setaffinity(gettid(), cpu_mask)) {
+ if (fio_setaffinity(gettid(), ipt->cpu_mask)) {
log_err("fio: fio_setaffinity failed\n");
+ fio_cpuset_exit(&ipt->cpu_mask);
return -1;
}
@@ -98,7 +108,7 @@
if (retval == -1) {
ipt->state = TD_EXITED;
pthread_mutex_unlock(&ipt->init_lock);
- return NULL;
+ goto do_exit;
}
ipt->state = TD_INITIALIZED;
@@ -113,13 +123,13 @@
/* exit if other threads failed to initialize */
if (ipc.status == IDLE_PROF_STATUS_ABORT) {
pthread_mutex_unlock(&ipt->start_lock);
- return NULL;
+ goto do_exit;
}
/* exit if we are doing calibration only */
if (ipc.status == IDLE_PROF_STATUS_CALI_STOP) {
pthread_mutex_unlock(&ipt->start_lock);
- return NULL;
+ goto do_exit;
}
fio_gettime(&ipt->tps, NULL);
@@ -143,6 +153,8 @@
ipt->state = TD_EXITED;
pthread_mutex_unlock(&ipt->start_lock);
+do_exit:
+ free_cpu_affinity(ipt);
return NULL;
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/idletime.h new/fio-2.2.6/idletime.h
--- old/fio-2.2.5/idletime.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/idletime.h 2015-02-27 16:30:04.000000000 +0100
@@ -34,6 +34,8 @@
pthread_cond_t cond;
pthread_mutex_t init_lock;
pthread_mutex_t start_lock;
+
+ os_cpu_mask_t cpu_mask;
};
struct idle_prof_common {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/init.c new/fio-2.2.6/init.c
--- old/fio-2.2.5/init.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/init.c 2015-02-27 16:30:04.000000000 +0100
@@ -596,8 +596,7 @@
if (o->norandommap && o->verify != VERIFY_NONE
&& !fixed_block_size(o)) {
log_err("fio: norandommap given for variable block sizes, "
- "verify disabled\n");
- o->verify = VERIFY_NONE;
+ "verify limited\n");
ret = warnings_fatal;
}
if (o->bs_unaligned && (o->odirect || td->io_ops->flags & FIO_RAWIO))
@@ -764,6 +763,10 @@
fio_gtod_offload = 1;
}
+ td->loops = o->loops;
+ if (!td->loops)
+ td->loops = 1;
+
return ret;
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/io_u.c new/fio-2.2.6/io_u.c
--- old/fio-2.2.5/io_u.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/io_u.c 2015-02-27 16:30:04.000000000 +0100
@@ -68,6 +68,9 @@
if (td->o.zone_range)
max_size = td->o.zone_range;
+ if (td->o.min_bs[ddir] > td->o.ba[ddir])
+ max_size -= td->o.min_bs[ddir] - td->o.ba[ddir];
+
max_blocks = max_size / (uint64_t) td->o.ba[ddir];
if (!max_blocks)
return 0;
@@ -1866,7 +1869,7 @@
{
struct thread_options *o = &td->o;
- if (o->compress_percentage) {
+ if (o->compress_percentage || o->dedupe_percentage) {
unsigned int perc = td->o.compress_percentage;
struct frand_state *rs;
unsigned int left = max_bs;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/iolog.c new/fio-2.2.6/iolog.c
--- old/fio-2.2.5/iolog.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/iolog.c 2015-02-27 16:30:04.000000000 +0100
@@ -250,6 +250,7 @@
p = &td->io_hist_tree.rb_node;
parent = NULL;
while (*p) {
+ int overlap = 0;
parent = *p;
__ipo = rb_entry(parent, struct io_piece, rb_node);
@@ -257,11 +258,18 @@
p = &(*p)->rb_left;
else if (ipo->file > __ipo->file)
p = &(*p)->rb_right;
- else if (ipo->offset < __ipo->offset)
+ else if (ipo->offset < __ipo->offset) {
p = &(*p)->rb_left;
- else if (ipo->offset > __ipo->offset)
+ overlap = ipo->offset + ipo->len > __ipo->offset;
+ }
+ else if (ipo->offset > __ipo->offset) {
p = &(*p)->rb_right;
- else {
+ overlap = __ipo->offset + __ipo->len > ipo->offset;
+ }
+ else
+ overlap = 1;
+
+ if (overlap) {
dprint(FD_IO, "iolog: overlap %llu/%lu, %llu/%lu",
__ipo->offset, __ipo->len,
ipo->offset, ipo->len);
@@ -868,10 +876,12 @@
if (ret < 0) {
perror("fread");
fclose(f);
+ free(buf);
return 1;
} else if (ret != 1) {
log_err("fio: short read on reading log\n");
fclose(f);
+ free(buf);
return 1;
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/lib/axmap.c new/fio-2.2.6/lib/axmap.c
--- old/fio-2.2.5/lib/axmap.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/lib/axmap.c 2015-02-27 16:30:04.000000000 +0100
@@ -125,6 +125,7 @@
free(axmap->levels[i].map);
free(axmap->levels);
+ free(axmap);
return NULL;
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/os/os-android.h new/fio-2.2.6/os/os-android.h
--- old/fio-2.2.5/os/os-android.h 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/os/os-android.h 2015-02-27 16:30:04.000000000 +0100
@@ -4,6 +4,7 @@
#define FIO_OS os_android
#include
+#include
#include
#include
#include
@@ -37,10 +38,13 @@
#define OS_MAP_ANON MAP_ANONYMOUS
+#ifndef POSIX_MADV_DONTNEED
#define posix_madvise madvise
#define POSIX_MADV_DONTNEED MADV_DONTNEED
#define POSIX_MADV_SEQUENTIAL MADV_SEQUENTIAL
#define POSIX_MADV_RANDOM MADV_RANDOM
+#endif
+
#ifdef MADV_REMOVE
#define FIO_MADV_FREE MADV_REMOVE
#endif
@@ -261,4 +265,12 @@
return errno;
}
+#ifdef CONFIG_SCHED_IDLE
+static inline int fio_set_sched_idle(void)
+{
+ struct sched_param p = { .sched_priority = 0, };
+ return sched_setscheduler(gettid(), SCHED_IDLE, &p);
+}
+#endif
+
#endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/os/windows/install.wxs new/fio-2.2.6/os/windows/install.wxs
--- old/fio-2.2.5/os/windows/install.wxs 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/os/windows/install.wxs 2015-02-27 16:30:04.000000000 +0100
@@ -10,7 +10,7 @@
+ UpgradeCode="2338A332-5511-43CF-B9BD-5C60496CCFCC" Version="2.2.6">
is_time)
is_time = o->is_time;
+ tmp[sizeof(tmp) - 1] = '\0';
strncpy(tmp, ptr, sizeof(tmp) - 1);
p = strchr(tmp, ',');
if (p)
@@ -705,6 +706,7 @@
char tmp[128];
char *p1, *p2;
+ tmp[sizeof(tmp) - 1] = '\0';
strncpy(tmp, ptr, sizeof(tmp) - 1);
/* Handle bsrange with separate read,write values: */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/fio-2.2.5/stat.c new/fio-2.2.6/stat.c
--- old/fio-2.2.5/stat.c 2015-01-21 21:07:43.000000000 +0100
+++ new/fio-2.2.6/stat.c 2015-02-27 16:30:04.000000000 +0100
@@ -674,9 +674,9 @@
struct group_run_stats *rs, int ddir, struct json_object *parent)
{
unsigned long min, max;
- unsigned long long bw, iops;
+ unsigned long long bw;
unsigned int *ovals = NULL;
- double mean, dev;
+ double mean, dev, iops;
unsigned int len, minv, maxv;
int i;
const char *ddirname[] = {"read", "write", "trim"};
@@ -693,17 +693,18 @@
json_object_add_value_object(parent,
ts->unified_rw_rep ? "mixed" : ddirname[ddir], dir_object);
- iops = bw = 0;
+ bw = 0;
+ iops = 0.0;
if (ts->runtime[ddir]) {
uint64_t runt = ts->runtime[ddir];
bw = ((1000 * ts->io_bytes[ddir]) / runt) / 1024;
- iops = (1000 * (uint64_t) ts->total_io_u[ddir]) / runt;
+ iops = (1000.0 * (uint64_t) ts->total_io_u[ddir]) / runt;
}
json_object_add_value_int(dir_object, "io_bytes", ts->io_bytes[ddir] >> 10);
json_object_add_value_int(dir_object, "bw", bw);
- json_object_add_value_int(dir_object, "iops", iops);
+ json_object_add_value_float(dir_object, "iops", iops);
json_object_add_value_int(dir_object, "runtime", ts->runtime[ddir]);
json_object_add_value_int(dir_object, "total_ios", ts->total_io_u[ddir]);
json_object_add_value_int(dir_object, "short_ios", ts->short_io_u[ddir]);