diff options
author | John Snow <jsnow@redhat.com> | 2015-05-22 14:13:44 -0400 |
---|---|---|
committer | John Snow <jsnow@redhat.com> | 2015-05-22 15:58:22 -0400 |
commit | 91d0374a7ffbd6a9cd0ba159c9160d9f26220cf5 (patch) | |
tree | 62af69ba1ac03fa870eaa6f669482c72647811c6 /tests/libqos | |
parent | 4d00796364ec4edab86b08abc38fd644d5e3c0ad (diff) | |
download | qemu-91d0374a7ffbd6a9cd0ba159c9160d9f26220cf5.zip qemu-91d0374a7ffbd6a9cd0ba159c9160d9f26220cf5.tar.gz qemu-91d0374a7ffbd6a9cd0ba159c9160d9f26220cf5.tar.bz2 |
libqos/ahci: Swap memread/write with bufread/write
Where it makes sense, use the new faster primitives.
For generally small reads/writes such as for the PRDT
and FIS packets, stick with the more wasteful but
easier to debug memread/memwrite.
For ahci-test (before migration tests):
With this patch:
real 0m3.675s
user 0m2.582s
sys 0m1.718s
Without any qtest protocol improvements:
real 0m14.171s
user 0m12.072s
sys 0m12.527s
Signed-off-by: John Snow <jsnow@redhat.com>
Message-id: 1430864578-22072-6-git-send-email-jsnow@redhat.com
Diffstat (limited to 'tests/libqos')
-rw-r--r-- | tests/libqos/ahci.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/libqos/ahci.c b/tests/libqos/ahci.c index 95bfb3d..7e17bb6 100644 --- a/tests/libqos/ahci.c +++ b/tests/libqos/ahci.c @@ -653,13 +653,13 @@ void ahci_io(AHCIQState *ahci, uint8_t port, uint8_t ide_cmd, qmemset(ptr, 0x00, bufsize); if (props->write) { - memwrite(ptr, buffer, bufsize); + bufwrite(ptr, buffer, bufsize); } ahci_guest_io(ahci, port, ide_cmd, ptr, bufsize, sector); if (props->read) { - memread(ptr, buffer, bufsize); + bufread(ptr, buffer, bufsize); } ahci_free(ahci, ptr); |