summaryrefslogtreecommitdiff
path: root/fio.h
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2013-07-25 10:20:45 -0600
committerJens Axboe <axboe@kernel.dk>2013-07-25 10:20:45 -0600
commitd94722713ebd7bbdbf8b284b7563f2dd17964e24 (patch)
treee965806f37c09f6abdbe5596a61f74f7ed20e958 /fio.h
parent954cd73a9a93102c24afa869fbe67ac38af6e416 (diff)
downloadfio-d94722713ebd7bbdbf8b284b7563f2dd17964e24.tar.gz
Add support for randomness of any IO direction
sequential_random used to be applied to all of the IO directions, with no possibility of having different settings for reads, writes, and trims. Now it supports setting each of them individually. By default, if you do: sequential_random=50 it will still apply to all three. If you do: sequential_random=10,90,80 you would get reads 10% random, writes 90% random, and trims 80% random. Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'fio.h')
-rw-r--r--fio.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/fio.h b/fio.h
index 8c67fccb..e7d5c27c 100644
--- a/fio.h
+++ b/fio.h
@@ -82,7 +82,9 @@ enum {
FIO_RAND_FILE_SIZE_OFF,
FIO_RAND_TRIM_OFF,
FIO_RAND_BUF_OFF,
- FIO_RAND_SEQ_RAND_OFF,
+ FIO_RAND_SEQ_RAND_READ_OFF,
+ FIO_RAND_SEQ_RAND_WRITE_OFF,
+ FIO_RAND_SEQ_RAND_TRIM_OFF,
FIO_RAND_NR_OFFS,
};
@@ -261,8 +263,8 @@ struct thread_data {
* rand/seq mixed workload state
*/
union {
- os_random_state_t seq_rand_state;
- struct frand_state __seq_rand_state;
+ os_random_state_t seq_rand_state[DDIR_RWDIR_CNT];
+ struct frand_state __seq_rand_state[DDIR_RWDIR_CNT];
};
/*