Remove memory management-related dead code

JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu
This commit is contained in:
Akos Kiss 2016-03-07 10:59:18 +01:00
parent c0f3a9f7fb
commit 212aa34331
5 changed files with 0 additions and 35 deletions

View File

@ -34,11 +34,6 @@
*/
#define CONFIG_MEM_POOL_CHUNK_SIZE (8)
/**
* Size of heap chunk
*/
#define CONFIG_MEM_HEAP_CHUNK_SIZE (64)
/**
* Size of heap
*/

View File

@ -199,13 +199,6 @@ extern void __noreturn jerry_fatal (jerry_fatal_code_t);
* Alignment
*/
/**
* Aligns @a value to @a alignment.
*
* Returns maximum positive value, that divides @a alignment and is less than or equal to @a value
*/
#define JERRY_ALIGNDOWN(value, alignment) ((alignment) * ((value) / (alignment)))
/**
* Aligns @a value to @a alignment.
*

View File

@ -28,11 +28,6 @@
*/
#define MEM_HEAP_SIZE ((size_t) (CONFIG_MEM_HEAP_AREA_SIZE))
/**
* Size of heap chunk
*/
#define MEM_HEAP_CHUNK_SIZE ((size_t) (CONFIG_MEM_HEAP_CHUNK_SIZE))
/**
* Size of pool chunk
*/

View File

@ -90,12 +90,6 @@ void mem_heap_valgrind_freya_mempool_request (void)
# define VALGRIND_FREYA_FREELIKE_SPACE(p)
#endif /* JERRY_VALGRIND_FREYA */
/**
* Chunk size should satisfy the required alignment value
*/
JERRY_STATIC_ASSERT (MEM_HEAP_CHUNK_SIZE % MEM_ALIGNMENT == 0,
MEM_HEAP_CHUNK_SIZE_must_be_multiple_of_MEM_ALIGNMENT);
/* Calculate heap area size, leaving space for a pointer to the free list */
#define MEM_HEAP_AREA_SIZE (MEM_HEAP_SIZE - MEM_ALIGNMENT)
#define MEM_HEAP_END_OF_LIST ((mem_heap_free_t *const) ~((uint32_t) 0x0))
@ -551,17 +545,6 @@ mem_heap_free_block_size_stored (void *ptr) /**< pointer to the memory block */
mem_heap_free_block (original_p, original_p->size);
} /* mem_heap_free_block_size_stored */
/**
* Recommend allocation size based on chunk size.
*
* @return recommended allocation size
*/
size_t __attr_pure___
mem_heap_recommend_allocation_size (size_t minimum_allocation_size) /**< minimum allocation size */
{
return JERRY_ALIGNUP (minimum_allocation_size, MEM_HEAP_CHUNK_SIZE);
} /* mem_heap_recommend_allocation_size */
/**
* Compress pointer
*

View File

@ -39,7 +39,6 @@ extern void mem_heap_free_block_size_stored (void *);
extern uintptr_t mem_heap_compress_pointer (const void *);
extern void *mem_heap_decompress_pointer (uintptr_t);
extern bool mem_is_heap_pointer (const void *);
extern size_t __attr_pure___ mem_heap_recommend_allocation_size (size_t);
extern void mem_heap_print ();
#ifdef MEM_STATS