Commit Graph

513 Commits

Author SHA1 Message Date
Huang Qi
b639c3ce61
Use macro instead of enum to define MEM_ALLOCATOR for better compatibility (#399)
Co-authored-by: Huang Qi <huangqi3@xiaomi.com>
2020-09-24 10:48:34 +08:00
Xiaokang Qin
a7e7711f63
Add the support for custom name section (#398)
Add the function name field for internal function struct

Signed-off-by: Zhongmin Wu <vwzm@live.com>
Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>

Co-authored-by: Zhongmin Wu <vwzm@live.com>
2020-09-23 16:12:09 +08:00
Huang Qi
a290aaf93e
Fix wasm loader malloc(0) issue which returns NULL is some platforms (#397)
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>

Co-authored-by: Huang Qi <huangqi3@xiaomi.com>
2020-09-23 15:54:22 +08:00
jmpews(AKA.zz)
d8d367b367
Update some assembler directives for darwin target (#395) 2020-09-23 13:10:26 +08:00
Xu Jun
dc4b8c4822
remove errno in wasm_application_execute_func (#396) 2020-09-23 11:50:37 +08:00
Xu Jun
21850aeb0a
add more build option and samples in CI (#394)
* Update linux.yml

* Create mac.yml
2020-09-20 13:16:13 +08:00
Huang Qi
b9f195ce91
Introduce CI support (#391)
Co-authored-by: Huang Qi <huangqi3@xiaomi.com>
2020-09-20 08:33:08 +08:00
Wenyong Huang
e501a6963b
Fix some coding style issues, fix doc typo and refine some codes (#392) 2020-09-20 08:20:45 +08:00
Xiaokang Qin
7c8ccc7c26
Fix the build warnings on Mac (#388)
Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>
2020-09-18 18:22:26 +08:00
Xiaokang Qin
2d06567cd1
Reimplement the utf8 string check (#389)
Previous implementation doesn't take care of overlong encoding

Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>
2020-09-18 18:06:13 +08:00
Xu Jun
0226dbbb3d
introduce WAMR memory profiling tool (experimental) (#390) 2020-09-18 18:04:56 +08:00
Huang Qi
04a7cc322f
core/shared: Add guard to avoid redefine macro (#386)
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>

Co-authored-by: Huang Qi <huangqi3@xiaomi.com>
2020-09-16 17:53:03 +08:00
Huang Qi
c004b01be3
Introduce support for NuttX RTOS (#377)
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>

Co-authored-by: Huang Qi <huangqi3@xiaomi.com>
2020-09-15 20:56:45 +08:00
Xu Jun
547298d4e7
Add macro to exclude sgx wasi/pthread ocalls if not needed (#384) 2020-09-15 15:49:09 +08:00
Xu Jun
2499e1ec4b
Fix issue and compilation warnings of new function call APIs (#383) 2020-09-14 15:30:42 +08:00
Xiaokang Qin
728890103b
Add the Windows COFF format support for AOT (#382)
Add the Windows COFF format support to wamr-compiler and iwasm can
load and excute it on Windows(X64) platform.

Signed-off-by: Wu Zhongmin <vwzm@live.com>
Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>

Co-authored-by: Wu Zhongmin <vwzm@live.com>
2020-09-11 18:32:58 +08:00
Xiaokang Qin
264e189690
Add Windows support for C-API and Runtime API libraries and examples. (#379)
* Add Windows support for C-API and Runtime API libraries and examples.

Signed-off-by: Wu Zhongmin <vwzm@live.com>
Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>

* Address the review comments

Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>

* Rewrite the the bh_getopt to make it avaliable for more kinds of options

Signed-off-by: Wu Zhongmin <vwzm@live.com>
Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>

* Add the license header

Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>

Co-authored-by: Zhongmin Wu <vwzm@live.com>
2020-09-11 17:36:04 +08:00
Xiaokang Qin
5418e09712
Add two apis for wasm function call (#375)
Add below two apis:

bool wasm_runtime_call_wasm_a(WASMExecEnv *exec_env,
                                                      WASMFunctionInstanceCommon *function,
                                                      uint32 num_results, wasm_val_t results[],
                                                      uint32 num_args, wasm_val_t args[])

bool wasm_runtime_call_wasm_v(WASMExecEnv *exec_env,
                                                      WASMFunctionInstanceCommon *function,
                                                      uint32 num_results, wasm_val_t results[],
                                                      uint32 num_args, ...)

Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>
2020-09-08 13:03:35 +08:00
Xu Jun
2135badc54
fix problem in wasm_module_malloc (#374) 2020-09-07 17:32:00 +08:00
Xu Jun
2e0cef3ef1
fix exec_env not checked issue, export __heap_base and __data_end in sample to decrease memory usage (#371) 2020-09-05 14:48:08 +08:00
Wenyong Huang
c8df3f6eed
Fix app heap migrate issue and aot compilation warning (#368) 2020-09-03 11:16:38 +08:00
Xu Jun
e113298d7f
use llvm release 10.x (#365) 2020-09-01 16:00:15 +08:00
Wenyong Huang
034606b0a9
Change wasm app offset type from int32 to uint32 (#361)
And fix some sign/unsigned conversion compilation warnings.
2020-08-26 18:33:29 +08:00
qinxk-inter
049760b849
Fix the build issues on mac for some samples (#358)
Fix the build issues on mac for basic/multi-module/multi-thread/
simple/spawn-thread/wasm-c-api under samples.
And all these samples could be run as expected.

Signed-off-by: Xiaokang Qin <xiaokang.qxk@antgroup.com>
2020-08-21 15:14:04 +08:00
Wenyong Huang
0103f6429c
Refactor error/exception strings to reduce binary size (#359) 2020-08-21 15:11:31 +08:00
Wenyong Huang
89d2937cde
Refactor app heap and memory boundary check, and fix os_printf compilation error (#356)
Insert app heap before __heap_base, or before new page
Fix os_printf compilation error in some platforms
2020-08-20 12:43:12 +08:00
Xu Jun
6b5f376e79
fix issue in mini-loader (#353) 2020-08-14 19:58:19 +08:00
Xu Jun
1266ebb222
fix coding style for windows build patch (#350) 2020-08-13 16:40:19 +08:00
Karl Fessel
874cc951c6
Optimize get_current_target in AOT loader for more archs (#347) 2020-08-13 15:13:45 +08:00
Xu Jun
21efe12505
add win64 support (#348) 2020-08-13 14:41:20 +08:00
Wenyong Huang
8c820730ba
Add cmake variable to set the max app thread stack size (#346) 2020-08-11 14:47:24 +08:00
sophy228
8ad9c1775f
Add wamrc AoT compiler building support for Windows(MSVC) (#332) 2020-08-11 11:30:51 +08:00
Karl Fessel
3be29c3f46
optimize: get_current_target for AOT thumb loader (#342) 2020-08-11 09:40:18 +08:00
Xu Jun
6aeefbebb2
implement atomics opcodes for interpreter (#344) 2020-08-10 19:43:58 +08:00
Wenyong Huang
1b6ddb37d0
Implement libc-WASI for Linux SGX platform and update documents (#343) 2020-08-10 15:12:26 +08:00
follower
8edf1e152f
Update URL to lvgl repository. (#341)
The `lvgl` project appears to have changed their project name & repository URL.

This commit updates the URLs so the links don't go to a 404 error page.

The project name is now "Light and Versatile Embedded Graphics Library" but I haven't updated the name anywhere.
2020-08-07 22:16:02 +08:00
follower
47450f47dd
Fix typo: "wigdet" -> "widgets" (#340) 2020-08-07 17:25:23 +08:00
Karl Fessel
2022b2584d
remove not needed ${SHARED_DIR}/include/*.h in runtime_lib.cmake (#338) 2020-08-06 17:20:34 +08:00
Wenyong Huang
aa7b0ba6b6
Fix wamrc link error and arm assembly code issue (#335) 2020-08-05 09:07:30 +08:00
Karl Fessel
37aae1bc49
make include headers follow strict protoype rule (#331) 2020-08-04 19:53:34 +08:00
Xu Jun
2db335c6d4
add spawn thread API and sample (#333) 2020-08-04 17:40:45 +08:00
Wenyong Huang
ed8ddb2cea
Disable some components in llvm build script to decrease binary size (#330) 2020-08-03 12:38:22 +08:00
Xu Jun
29e45e1527
implement atomic opcode in AOT/JIT (#329) 2020-08-03 11:30:26 +08:00
dpinthinker
cc05f8fb1c
Use quicksort to sort native_symbols (#324) 2020-07-31 20:54:03 +08:00
Wenyong Huang
93ca9d8c62
Disable memory shrink opt when memory.size opcode is found (#323) 2020-07-30 10:18:55 +08:00
Wenyong Huang
88af12501d
Implement ecall to handle commands from host to call enclave runtime APIs (#320) 2020-07-28 16:18:54 +08:00
Wenyong Huang
056b824ac4
Fix fast interpreter i64 shift issue for non-x86 arch (#319) 2020-07-28 13:46:37 +08:00
lum1n0us
08d01b65c5
Eable post-MVP feature wasm-c-api (#315) 2020-07-23 16:54:13 +08:00
Xu Jun
32b2943369
enable pthread for AoT && update AOT current version to 2 (#311) 2020-07-16 20:35:04 +08:00
yjsungo
ca938f3634
Fix one typo in README.md (#309)
Signed-off-by: yijin.syj <yijin.syj@antgroup.com>

Co-authored-by: yijin.syj <yijin.syj@alibaba-inc.com>
2020-07-13 11:10:46 +08:00