diff mbox

[PULL,15/16] qcow2: reorder fields in Qcow2CachedTable to reduce padding

Message ID 1441397447-6516-16-git-send-email-kwolf@redhat.com
State New
Headers show

Commit Message

Kevin Wolf Sept. 4, 2015, 8:10 p.m. UTC
From: Alberto Garcia <berto@igalia.com>

Changing the current ordering saves 8 bytes per cache entry in x86_64.

Signed-off-by: Alberto Garcia <berto@igalia.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Message-id: 0bd55291211df3dfb514d0e7d2031dd5c4f9f807.1438690126.git.berto@igalia.com
Signed-off-by: Max Reitz <mreitz@redhat.com>
---
 block/qcow2-cache.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/block/qcow2-cache.c b/block/qcow2-cache.c
index 8457458..046f5b8 100644
--- a/block/qcow2-cache.c
+++ b/block/qcow2-cache.c
@@ -37,9 +37,9 @@ 
 
 typedef struct Qcow2CachedTable {
     int64_t  offset;
-    bool     dirty;
     uint64_t lru_counter;
     int      ref;
+    bool     dirty;
 } Qcow2CachedTable;
 
 struct Qcow2Cache {