RetroArch
blockheap.h
Go to the documentation of this file.
1 #pragma once
2 #include <wiiu/types.h>
3 #include "memheap.h"
4 
5 #ifdef __cplusplus
6 extern "C" {
7 #endif
8 
11 typedef struct MEMBlockHeap MEMBlockHeap;
12 
13 typedef struct MEMBlockHeapTracking
14 {
20 
21 typedef struct MEMBlockHeapBlock
22 {
23  void *start;
24  void *end;
29 
30 typedef struct MEMBlockHeap
31 {
39 } MEMBlockHeap;
40 
42  void *start,
43  void *end,
44  MEMBlockHeapTracking *blocks,
45  uint32_t size,
46  uint32_t flags);
47 
49 
51  MEMBlockHeapTracking *tracking,
52  uint32_t size);
53 
55  void *addr,
56  uint32_t size);
57 
59  uint32_t size,
60  int32_t align);
61 
63  void *data);
64 
66  int32_t align);
67 
69 
71 
72 #ifdef __cplusplus
73 }
74 #endif
void * MEMAllocFromBlockHeapAt(MEMBlockHeap *heap, void *addr, uint32_t size)
Definition: blockheap.h:30
MEMHeapHeader header
Definition: blockheap.h:32
uint32_t numFreeBlocks
Definition: blockheap.h:38
uint32_t MEMGetAllocatableSizeForBlockHeapEx(MEMBlockHeap *heap, int32_t align)
static int align(int x, int n)
Definition: psp2.c:23
uint32_t MEMGetTotalFreeSizeForBlockHeap(MEMBlockHeap *heap)
GLuint start
Definition: glext.h:6292
Definition: blockheap.h:21
MEMBlockHeapBlock * firstBlock
Definition: blockheap.h:35
MEMBlockHeapBlock * prev
Definition: blockheap.h:26
MEMBlockHeapBlock * blocks
Definition: blockheap.h:17
GLsizeiptr size
Definition: glext.h:6559
void * MEMDestroyBlockHeap(MEMBlockHeap *heap)
Definition: ibxm.h:9
void * end
Definition: blockheap.h:24
void * start
Definition: blockheap.h:23
uint32_t blockCount
Definition: blockheap.h:18
Definition: memheap.h:33
MEMBlockHeap * MEMInitBlockHeap(MEMBlockHeap *heap, void *start, void *end, MEMBlockHeapTracking *blocks, uint32_t size, uint32_t flags)
MEMBlockHeapBlock * next
Definition: blockheap.h:27
GLenum const GLvoid * addr
Definition: glext.h:10528
MEMBlockHeapBlock * lastBlock
Definition: blockheap.h:36
void MEMFreeToBlockHeap(MEMBlockHeap *heap, void *data)
MEMBlockHeapBlock * firstFreeBlock
Definition: blockheap.h:37
signed int int32_t
Definition: stdint.h:123
void * MEMAllocFromBlockHeapEx(MEMBlockHeap *heap, uint32_t size, int32_t align)
uint32_t MEMGetTrackingLeftInBlockHeap(MEMBlockHeap *heap)
unsigned int BOOL
Definition: gctypes.h:51
struct MEMBlockHeap MEMBlockHeap
Definition: blockheap.h:11
uint32_t __unknown1
Definition: blockheap.h:16
struct MEMBlockHeapTracking MEMBlockHeapTracking
Definition: blockheap.h:10
Definition: blockheap.h:13
uint32_t __unknown0
Definition: blockheap.h:15
BOOL isFree
Definition: blockheap.h:25
int MEMAddBlockHeapTracking(MEMBlockHeap *heap, MEMBlockHeapTracking *tracking, uint32_t size)
struct MEMBlockHeapBlock MEMBlockHeapBlock
Definition: blockheap.h:9
GLuint GLuint end
Definition: glext.h:6292
GLbitfield flags
Definition: glext.h:7828
MEMBlockHeapBlock defaultBlock
Definition: blockheap.h:34
unsigned int uint32_t
Definition: stdint.h:126
MEMBlockHeapTracking defaultTrack
Definition: blockheap.h:33