Home | History | Annotate | Download | only in base

Lines Matching defs:memory

21   /* low-level, i.e. memory management, i/o access as well as thread       */
89 APTR memory )
91 ULONG *realmem = (ULONG *)memory - 1;
111 /* MEMORY MANAGEMENT INTERFACE */
130 /* The memory allocation function. */
133 /* memory :: A pointer to the memory object. */
141 ft_alloc( FT_Memory memory,
145 return AllocVecPooled( memory->user, size );
147 return Alloc_VecPooled( memory->user, size );
158 /* The memory reallocation function. */
161 /* memory :: A pointer to the memory object. */
163 /* cur_size :: The current size of the allocated memory block. */
167 /* block :: The current address of the block in memory. */
170 /* The address of the reallocated memory block. */
173 ft_realloc( FT_Memory memory,
181 new_block = AllocVecPooled ( memory->user, new_size );
183 new_block = Alloc_VecPooled ( memory->user, new_size );
190 FreeVecPooled ( memory->user, block );
192 Free_VecPooled ( memory->user, block );
205 /* The memory release function. */
208 /* memory :: A pointer to the memory object. */
210 /* block :: The address of block in memory to be freed. */
213 ft_free( FT_Memory memory,
217 FreeVecPooled( memory->user, block );
219 Free_VecPooled( memory->user, block );
464 ft_mem_debug_init( FT_Memory memory );
467 ft_mem_debug_done( FT_Memory memory );
477 FT_Memory memory;
481 memory = (FT_Memory)AllocVec( sizeof ( *memory ), MEMF_SHARED );
483 memory = (FT_Memory)AllocVec( sizeof ( *memory ), MEMF_PUBLIC );
485 if ( memory )
488 memory->user = CreatePool( MEMF_SHARED, 16384, 16384 );
490 memory->user = CreatePool( MEMF_PUBLIC, 16384, 16384 );
492 if ( memory->user == NULL )
494 FreeVec( memory );
495 memory = NULL;
499 memory->alloc = ft_alloc;
500 memory->realloc = ft_realloc;
501 memory->free = ft_free;
503 ft_mem_debug_init( memory );
508 return memory;
515 FT_Done_Memory( FT_Memory memory )
518 ft_mem_debug_done( memory );
521 DeletePool( memory->user );
522 FreeVec( memory );