diff -rN -u old-jhc/rts/rts/gc_jgc.c new-jhc/rts/rts/gc_jgc.c --- old-jhc/rts/rts/gc_jgc.c 2012-12-07 11:41:31.692778775 +0900 +++ new-jhc/rts/rts/gc_jgc.c 2012-12-07 11:41:32.084780728 +0900 @@ -18,7 +18,7 @@ static void clear_used_bits(struct s_arena *arena) A_UNUSED; static void s_cleanup_blocks(struct s_arena *arena); static struct s_block *get_free_block(gc_t gc, struct s_arena *arena); -static void *aligned_alloc(unsigned size); +static void *jhc_aligned_alloc(unsigned size); typedef struct { sptr_t ptrs[0]; @@ -231,7 +231,7 @@ static heap_t A_STD s_monoblock(struct s_arena *arena, unsigned size, unsigned nptrs, unsigned flags) { - struct s_block *b = aligned_alloc(size * sizeof(uintptr_t)); + struct s_block *b = jhc_aligned_alloc(size * sizeof(uintptr_t)); b->flags = flags | SLAB_MONOLITH; b->color = (sizeof(struct s_block) + BITARRAY_SIZE_IN_BYTES(1) + sizeof(uintptr_t) - 1) / sizeof(uintptr_t); @@ -292,7 +292,7 @@ } static void * -aligned_alloc(unsigned size) { +jhc_aligned_alloc(unsigned size) { void *base; #if defined(__WIN32__) base = _aligned_malloc(MEGABLOCK_SIZE, BLOCK_SIZE); @@ -318,7 +318,7 @@ s_new_megablock(struct s_arena *arena) { struct s_megablock *mb = malloc(sizeof(*mb)); - mb->base = aligned_alloc(MEGABLOCK_SIZE); + mb->base = jhc_aligned_alloc(MEGABLOCK_SIZE); VALGRIND_MAKE_MEM_NOACCESS(mb->base,MEGABLOCK_SIZE); mb->next_free = 0; return mb;