chiark / gitweb /
Rearrange a few fields to reduce holes
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 8 May 2013 01:07:39 +0000 (21:07 -0400)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 9 May 2013 01:34:20 +0000 (21:34 -0400)
src/core/socket.h
src/journal/journal-internal.h
src/journal/mmap-cache.c

index 4826bb331b04844deb674b9f7637b855d4248002..9d48cde0a671e83778caed969ceb5f68379eff4c 100644 (file)
@@ -130,6 +130,10 @@ struct Socket {
         bool broadcast;
         bool pass_cred;
         bool pass_sec;
+
+        /* Only for INET6 sockets: issue IPV6_V6ONLY sockopt */
+        SocketAddressBindIPv6Only bind_ipv6_only;
+
         int priority;
         int mark;
         size_t receive_buffer;
@@ -142,9 +146,6 @@ struct Socket {
         long mq_maxmsg;
         long mq_msgsize;
 
-        /* Only for INET6 sockets: issue IPV6_V6ONLY sockopt */
-        SocketAddressBindIPv6Only bind_ipv6_only;
-
         char *smack;
         char *smack_ip_in;
         char *smack_ip_out;
index eea56e4713b0e7e6b367c8c12422c59c820f2f16..c7e585d810d184fa8585006458f76fde0b03cc18 100644 (file)
@@ -74,19 +74,20 @@ typedef enum LocationType {
 struct Location {
         LocationType type;
 
+        bool seqnum_set;
+        bool realtime_set;
+        bool monotonic_set;
+        bool xor_hash_set;
+
         uint64_t seqnum;
         sd_id128_t seqnum_id;
-        bool seqnum_set;
 
         uint64_t realtime;
-        bool realtime_set;
 
         uint64_t monotonic;
         sd_id128_t boot_id;
-        bool monotonic_set;
 
         uint64_t xor_hash;
-        bool xor_hash_set;
 };
 
 struct Directory {
index 54bf1148e18d572d67db3d980a8609b7325971b7..767f5555265c7e73aee0c94ec83e0b51788a5baa 100644 (file)
@@ -41,9 +41,9 @@ struct Window {
         bool keep_always;
         bool in_unused;
 
+        int prot;
         void *ptr;
         uint64_t offset;
-        int prot;
         size_t size;
 
         FileDescriptor *fd;
@@ -70,12 +70,11 @@ struct FileDescriptor {
 
 struct MMapCache {
         int n_ref;
+        unsigned n_windows;
 
         Hashmap *fds;
         Hashmap *contexts;
 
-        unsigned n_windows;
-
         LIST_HEAD(Window, unused);
         Window *last_unused;
 };