Import WAMR Fast JIT (#1343)
Import WAMR Fast JIT which is a lightweight JIT with quick startup, small footprint, relatively good performance (~40% to ~50% of LLVM JIT) and good portability. Platforms supported: Linux, MacOS and Linux SGX. Arch supported: x86-64.
This commit is contained in:
19
core/iwasm/fast-jit/jit_utils.c
Normal file
19
core/iwasm/fast-jit/jit_utils.c
Normal file
@ -0,0 +1,19 @@
|
||||
/*
|
||||
* Copyright (C) 2021 Intel Corporation. All rights reserved.
|
||||
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||
*/
|
||||
|
||||
#include "jit_utils.h"
|
||||
|
||||
JitBitmap *
|
||||
jit_bitmap_new(uintptr_t begin_index, unsigned bitnum)
|
||||
{
|
||||
JitBitmap *bitmap;
|
||||
|
||||
if ((bitmap = jit_calloc(offsetof(JitBitmap, map) + (bitnum + 7) / 8))) {
|
||||
bitmap->begin_index = begin_index;
|
||||
bitmap->end_index = begin_index + bitnum;
|
||||
}
|
||||
|
||||
return bitmap;
|
||||
}
|
||||
Reference in New Issue
Block a user