Initial revision
[ssr] / StraySrc / Libraries / Sapphire / csapph / h / subAlloc
CommitLineData
2ee739cc 1/*
2 * subAlloc.h
3 *
4 * [Generated from subAlloc, 25 September 1996]
5 */
6
7#if !defined(__CC_NORCROFT) || !defined(__arm)
8 #error You must use the Norcroft ARM Compiler for Sapphire programs
9#endif
10
11#pragma include_only_once
12#pragma force_top_level
13
14#ifndef __subAlloc_h
15#define __subAlloc_h
16
17#ifndef __sapphire_h
18 #include "sapphire.h"
19#endif
20
21/*----- Overview ----------------------------------------------------------*
22 *
23 * Functions provided:
24 *
25 * sub_alloc
26 * sub_free
27 * sub_init
28 */
29
30/* --- sub_alloc --- *
31 *
32 * On entry: R0 == size of block to allocate
33 *
34 * On exit: R0 == pointer to block allocated
35 * May return an error
36 *
37 * Use: Allocates a block of the size specified, typically very
38 * quickly indeed.
39 *
40 * If the size is not one of those supported (currently
41 * supported sizes are 8-40 inclusive in 4 byte increments),
42 * the behaviour is undefined (but very predictable).
43 */
44
45extern routine sub_alloc;
46
47/* --- sub_free --- *
48 *
49 * On entry: R0 == pointer to block
50 * R1 == size of the block
51 *
52 * On exit: --
53 *
54 * Use: Frees a block allocated using sub_alloc.
55 */
56
57extern routine sub_free;
58
59/* --- sub_init --- *
60 *
61 * On entry: --
62 *
63 * On exit: --
64 *
65 * Use: Initialises the suballocation system for use.
66 */
67
68extern routine sub_init;
69
70/*----- That's all, folks -------------------------------------------------*/
71
72#endif