summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMohamad Ayyash <mkayyash@google.com>2015-03-06 17:44:27 -0800
committerMohamad Ayyash <mkayyash@google.com>2015-03-17 00:01:43 +0000
commit365a153cfe8a3601af5d7c6c87679c20e84314e5 (patch)
treeb4b0f10914f03d068640ea25f1327858664dca21
parenta64f0e1024b1cc29595e5c0b0848a775fed886fd (diff)
downloadfio-365a153cfe8a3601af5d7c6c87679c20e84314e5.tar.gz
fio: Fix a GCC 4.9 allignment error.
Causes a Bus Error when running fio. Change-Id: I388673eb3c5d596026647543d14c47ba08fef3c7
-rw-r--r--stat.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/stat.c b/stat.c
index 85bd728d..6a3610f4 100644
--- a/stat.c
+++ b/stat.c
@@ -1144,10 +1144,14 @@ void sum_thread_stats(struct thread_stat *dst, struct thread_stat *src, int nr)
int m;
for (m = 0; m < FIO_IO_U_PLAT_NR; m++) {
+ /* HACK to prevent bus error in arm GCC 4.9 */
+ dst->io_u_plat[k][m]+=1;
if (!dst->unified_rw_rep)
dst->io_u_plat[k][m] += src->io_u_plat[k][m];
else
dst->io_u_plat[0][m] += src->io_u_plat[k][m];
+ /* HACK to prevent bus error in arm GCC 4.9 */
+ dst->io_u_plat[k][m]-=1;
}
}