Recent changes (master)
The following changes since commit 0313e938c9c8bb37d71dade239f1f5326677b079:
Fio 3.27 (2021-05-26 10:10:32 -0600)
are available in the Git repository at:
git://git.kernel.dk/fio.git master
for you to fetch changes up to 575686bb85fa36f326524c505e83c54abc0d2f2b:
zbd: add a new --ignore_zone_limits option (2021-05-27 16:04:58 -0600)
----------------------------------------------------------------
Jens Axboe (1):
Merge branch 'fix-libpmem' of https://github.com/lukaszstolarczuk/fio
Niklas Cassel (2):
zbd: add missing client/server support for option max_open_zones
zbd: add a new --ignore_zone_limits option
��ukasz Stolarczuk (3):
engines/libpmem: set file open/create mode always to RW engines/libpmem: cleanup a little code, comments and example engines/libpmem: do not call drain on close
cconv.c | 4 ++++ engines/libpmem.c | 64 +++++++++++++++++----------------------------------- examples/libpmem.fio | 35 ++++++++++++++-------------- fio.1 | 5 ++++ options.c | 10 ++++++++ server.h | 2 +- thread_options.h | 3 +++ zbd.c | 2 +- 8 files changed, 63 insertions(+), 62 deletions(-)
---
Diff of recent changes:
cconv.c +4 -0
@@ -231,6 +231,8 @@ void convert_thread_options_to_cpu(struct thread_options *o, o->zone_capacity =le64_to_cpu (top->zone_capacity); o->zone_skip =le64_to_cpu (top->zone_skip); o->zone_mode =le32_to_cpu (top->zone_mode); + o->max_open_zones =__le32_to_cpu (top->max_open_zones); + o->ignore_zone_limits =le32_to_cpu (top->ignore_zone_limits); o->lockmem =le64_to_cpu (top->lockmem); o->offset_increment_percent =le32_to_cpu (top->offset_increment_percent); o->offset_increment =le64_to_cpu (top->offset_increment);
@@ -573,6 +575,8 @@ void convert_thread_options_to_net(struct thread_options_pack *top, top->zone_capacity =__cpu_to_le64 (o->zone_capacity); top->zone_skip =__cpu_to_le64 (o->zone_skip); top->zone_mode =__cpu_to_le32 (o->zone_mode); + top->max_open_zones =__cpu_to_le32 (o->max_open_zones); + top->ignore_zone_limits =cpu_to_le32 (o->ignore_zone_limits); top->lockmem =__cpu_to_le64 (o->lockmem); top->ddir_seq_add =__cpu_to_le64 (o->ddir_seq_add); top->file_size_low =__cpu_to_le64 (o->file_size_low);
engines/libpmem.c +21 -43
138 lines not on this page · raw message
examples/libpmem.fio +18 -17
@@ -1,6 +1,6 @@ [global] bs=4k -size=8g +size=10g ioengine=libpmem norandommap time_based
@@ -17,16 +17,6 @@ thread numjobs=1 runtime=300 -# -# In case of 'scramble_buffers=1', the source buffer -# is rewritten with a random value every write operations. -# -# But when 'scramble_buffers=0' is set, the source buffer isn't -# rewritten. So it will be likely that the source buffer is in CPU -# cache and it seems to be high performance. -# -scramble_buffers=0 - # # depends on direct option, flags are set for pmem_memcpy() call: # direct=1 - PMEM_F_MEM_NONTEMPORAL,
@@ -39,9 +29,19 @@ direct=1 # sync=1 +# +# In case of 'scramble_buffers=1', the source buffer +# is rewritten with a random value every write operation. +# +# But when 'scramble_buffers=0' is set, the source buffer isn't +# rewritten. So it will be likely that the source buffer is in CPU +# cache and it seems to be high write performance. +# +scramble_buffers=1 # -# Setting for fio process's CPU Node and Memory Node +# Setting for fio process's CPU Node and Memory Node. +# Set proper node below or use `numactl` command along with FIO. # numa_cpu_nodes=0 numa_mem_policy=bind:0
@@ -53,21 +53,22 @@ cpus_allowed_policy=split # # The libpmem engine does IO to files in a DAX-mounted filesystem. -# The filesystem should be created on an NVDIMM (e.g /dev/pmem0) +# The filesystem should be created on a Non-Volatile DIMM (e.g /dev/pmem0) # and then mounted with the '-o dax' option. Note that the engine # accesses the underlying NVDIMM directly, bypassing the kernel block # layer, so the usual filesystem/disk performance monitoring tools such # as iostat will not provide useful data. # -directory=/mnt/pmem0 +#filename=/mnt/pmem/somefile +directory=/mnt/pmem [libpmem-seqwrite] rw=write stonewall -#[libpmem-seqread] -#rw=read -#stonewall +[libpmem-seqread] +rw=read +stonewall #[libpmem-randwrite] #rw=randwrite
fio.1 +5 -0
@@ -835,6 +835,11 @@ threads/processes. .BI job_max_open_zones \fR=\fPint Limit on the number of simultaneously opened zones per single thread/process. .TP +.BI ignore_zone_limits \fR=\fPbool +If this isn't set, fio will query the max open zones limit from the zoned block +device, and exit if the specified \fBmax_open_zones\fR value is larger than the +limit reported by the device. Default: false. +.TP .BI zone_reset_threshold \fR=\fPfloat A number between zero and one that indicates the ratio of logical blocks with data to the total number of logical blocks in the test above which zones
options.c +10 -0
@@ -3492,6 +3492,16 @@ struct fio_option fio_options[FIO_MAX_OPTS] = { .category = FIO_OPT_C_IO, .group = FIO_OPT_G_INVALID, }, + { + .name = "ignore_zone_limits", + .lname = "Ignore zone resource limits", + .type = FIO_OPT_BOOL, + .off1 = offsetof(struct thread_options, ignore_zone_limits), + .def = "0", + .help = "Ignore the zone resource limits (max open/active zones) reported by the device", + .category = FIO_OPT_C_IO, + .group = FIO_OPT_G_INVALID, + }, { .name = "zone_reset_threshold", .lname = "Zone reset threshold",
server.h +1 -1
@@ -48,7 +48,7 @@ struct fio_net_cmd_reply { };enum { -FIO_SERVER_VER =89 , +FIO_SERVER_VER =91 ,FIO_SERVER_MAX_FRAGMENT_PDU =1024 ,FIO_SERVER_MAX_CMD_MB =2048 ,
thread_options.h +3 -0
@@ -355,6 +355,7 @@ struct thread_options {unsigned int read_beyond_wp;int max_open_zones;unsigned int job_max_open_zones; +unsigned int ignore_zone_limits;fio_fp64_t zrt;fio_fp64_t zrf; };
@@ -656,6 +657,8 @@ struct thread_options_pack {uint32_t allow_mounted_write;uint32_t zone_mode; +int32_t max_open_zones; +uint32_t ignore_zone_limits; } __attribute__((packed));extern void convert_thread_options_to_cpu (struct thread_options *o,struct thread_options_pack *top);
zbd.c +1 -1
@@ -588,7 +588,7 @@ static int zbd_set_max_open_zones(struct thread_data *td, struct fio_file *f)unsigned int max_open_zones;int ret; -if (zbd->model !=ZBD_HOST_MANAGED ) { +if (zbd->model !=ZBD_HOST_MANAGED || td->o.ignore_zone_limits) {/* Only host-managed devices have a max open limit */ zbd->max_open_zones = td->o.max_open_zones; goto out;