Introducing MEM_CP_{GET_[NON_NULL_]POINTER, SET_[NON_NULL_]POINTER} getters / setters for compressed pointers.

JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
This commit is contained in:
Ruben Ayrapetyan
2015-05-13 20:54:41 +03:00
parent da86a52fe9
commit c4e7f56562
6 changed files with 62 additions and 58 deletions
+2 -2
View File
@@ -109,7 +109,7 @@ mem_compress_pointer (const void *pointer) /**< pointer to compress */
JERRY_ASSERT((int_ptr & ~((1u << MEM_HEAP_OFFSET_LOG) - 1)) == 0);
JERRY_ASSERT(int_ptr != MEM_COMPRESSED_POINTER_NULL);
JERRY_ASSERT (int_ptr != MEM_CP_NULL);
return int_ptr;
} /* mem_compress_pointer */
@@ -120,7 +120,7 @@ mem_compress_pointer (const void *pointer) /**< pointer to compress */
void*
mem_decompress_pointer (uintptr_t compressed_pointer) /**< pointer to decompress */
{
JERRY_ASSERT(compressed_pointer != MEM_COMPRESSED_POINTER_NULL);
JERRY_ASSERT (compressed_pointer != MEM_CP_NULL);
uintptr_t int_ptr = compressed_pointer;