mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-30 05:43:53 -06:00
simplebench/bench-backup: add target-cache argument
Allow benchmark with different kinds of target cache. Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by: John Snow <jsnow@redhat.com>
This commit is contained in:
parent
af2ac8514f
commit
684d18efd1
2 changed files with 33 additions and 10 deletions
|
@ -115,9 +115,13 @@ def bench_block_copy(qemu_binary, cmd, cmd_options, source, target):
|
|||
'-blockdev', json.dumps(target)])
|
||||
|
||||
|
||||
def drv_file(filename):
|
||||
return {'driver': 'file', 'filename': filename,
|
||||
'cache': {'direct': True}, 'aio': 'native'}
|
||||
def drv_file(filename, o_direct=True):
|
||||
node = {'driver': 'file', 'filename': filename}
|
||||
if o_direct:
|
||||
node['cache'] = {'direct': True}
|
||||
node['aio'] = 'native'
|
||||
|
||||
return node
|
||||
|
||||
|
||||
def drv_nbd(host, port):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue