Browse Source

Rearranged types a bit

Thomas Johnson 1 year ago
parent
commit
ba0f93f487
1 changed files with 2 additions and 4 deletions
  1. 2
    4
      allocator_internal.h

+ 2
- 4
allocator_internal.h View File

@@ -20,9 +20,9 @@ typedef struct TreeAlloc {
20 20
   struct TreeAlloc *parent;
21 21
   struct TreeAlloc *left;
22 22
   struct TreeAlloc *right;
23
+  uintptr_t size;
23 24
   struct TreeAlloc *before;
24 25
   struct TreeAlloc *after;
25
-  uintptr_t size;
26 26
 } TreeAlloc;
27 27
 
28 28
 typedef struct FreeSpace {
@@ -30,8 +30,6 @@ typedef struct FreeSpace {
30 30
   struct FreeSpace *parent;
31 31
   struct FreeSpace *left;
32 32
   struct FreeSpace *right;
33
-  struct TreeAlloc *before;
34
-  struct TreeAlloc *after;
35 33
   uintptr_t size;
36 34
 } FreeSpace;
37 35
 
@@ -40,9 +38,9 @@ typedef struct WatermarkAlloc {
40 38
   struct TreeAlloc *parent;
41 39
   struct TreeAlloc *left;
42 40
   struct TreeAlloc *right;
41
+  uintptr_t size;
43 42
   struct TreeAlloc *before;
44 43
   struct TreeAlloc *after;
45
-  uintptr_t size;
46 44
   int num_allocs;
47 45
   void *next_alloc;
48 46
 } WatermarkAlloc;

Loading…
Cancel
Save