wasm-micro-runtime/core/shared/mem-alloc/mem_alloc.h
wenyongh b40e79c160
Make heap and linear memory contiguous to refine compilation time and footprint ()
Use FastISel for JIT mode
Use united aot version in aot file and aot runtime
Disable check signature failed warning for wamrc
Fix fast interpreter x86_32 float issue
Remove unused empty lvgl folder
2020-04-13 10:49:40 +08:00

48 lines
907 B
C

/*
* Copyright (C) 2019 Intel Corporation. All rights reserved.
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*/
#ifndef __MEM_ALLOC_H
#define __MEM_ALLOC_H
#include "bh_platform.h"
#ifdef __cplusplus
extern "C" {
#endif
typedef void *mem_allocator_t;
mem_allocator_t
mem_allocator_create(void *mem, uint32_t size);
void
mem_allocator_destroy(mem_allocator_t allocator);
void *
mem_allocator_malloc(mem_allocator_t allocator, uint32_t size);
void *
mem_allocator_realloc(mem_allocator_t allocator, void *ptr, uint32_t size);
void
mem_allocator_free(mem_allocator_t allocator, void *ptr);
int
mem_allocator_migrate(mem_allocator_t allocator,
mem_allocator_t allocator_old);
int
mem_allocator_reinit_lock(mem_allocator_t allocator);
void
mem_allocator_destroy_lock(mem_allocator_t allocator);
#ifdef __cplusplus
}
#endif
#endif /* #ifndef __MEM_ALLOC_H */