Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
alexbevi
GitHub Repository: alexbevi/BizHawk
Path: blob/master/waterbox/libc/includes/emulibc.h
2 views
1
#ifndef _EMULIBC_H
2
#define _EMULIBC_H
3
4
#include <stddef.h>
5
6
// mark an entry point or callback pointer
7
#define ECL_ENTRY __attribute__((ms_abi))
8
// mark a visible symbol
9
#define ECL_EXPORT __attribute__((visibility("default")))
10
11
// allocate memory from the "sealed" pool. this memory can never be freed,
12
// and can only be allocated or written to during the init phase. after that, the host
13
// seals the pool, making it read only and all of its contents frozen. good for LUTs and
14
// ROMs
15
void *alloc_sealed(size_t size);
16
17
// allocate memory from the "invisible" pool. this memory can never be freed.
18
// this memory is not savestated! this should only be used for a large buffer whose contents
19
// you are absolutely sure will not harm savestates
20
void *alloc_invisible(size_t size);
21
22
// send a debug string somewhere, bypassing stdio
23
void _debug_puts(const char *);
24
25
#endif
26
27