return 0;
}
+static int compression_enabled(struct thread_options *o)
+{
+ return o->compress_percentage || o->compress_chunk;
+}
+
static void init_flags(struct thread_data *td)
{
struct thread_options *o = &td->o;
td->flags |= TD_F_READ_IOLOG;
if (o->refill_buffers)
td->flags |= TD_F_REFILL_BUFFERS;
- if (o->scramble_buffers)
+
+ /*
+ * Don't scramble buffers if we set any of the compression
+ * settings
+ */
+ if (o->scramble_buffers && !compression_enabled(o))
td->flags |= TD_F_SCRAMBLE_BUFFERS;
+
if (o->verify != VERIFY_NONE)
td->flags |= TD_F_VER_NONE;
}
file_alloced = 1;
if (o->nr_files == 1 && exists_and_not_file(jobname))
- add_file(td, jobname, job_add_num);
+ add_file(td, jobname, job_add_num, 0);
else {
for (i = 0; i < o->nr_files; i++)
- add_file(td, make_filename(fname, o, jobname, job_add_num, i), job_add_num);
+ add_file(td, make_filename(fname, o, jobname, job_add_num, i), job_add_num, 0);
}
}
case 'E': {
long long t = 0;
- if (str_to_decimal(optarg, &t, 0, NULL)) {
+ if (str_to_decimal(optarg, &t, 0, NULL, 1)) {
log_err("fio: failed parsing eta time %s\n", optarg);
exit_val = 1;
do_exit++;
case 'L': {
long long val;
- if (check_str_time(optarg, &val)) {
+ if (check_str_time(optarg, &val, 1)) {
log_err("fio: failed parsing time %s\n", optarg);
do_exit++;
exit_val = 1;