Commit Graph

55 Commits

Author SHA1 Message Date
Wenyong Huang
27e7e160af
Upgrade toolkits (#1878)
Upgrade the version of related toolkits:
- upgrade llvm to 15.0
- upgrade wasi-sdk to 19.0
- upgrade emsdk to 3.1.28
- upgrade wabt to 1.0.31
- upgrade binaryen to 111

And upgrade the CI scripts, sample workload build scripts, Dockerfiles, and documents.
2023-02-02 09:42:25 +08:00
Huang Qi
58316635d4
ci: Enable libc-wasi compilation test on NuttX (#1918) 2023-01-28 12:39:14 +08:00
Fadumina
df4b135086
Add WAMR-IDE vscode extension to the Visual Studio Marketplace (#1868)
Publish an extension to the visual studio marketplace using a secret token.
This allows for automation to take place because downloading and installing
the extension is a manual process so it'd be simpler if the extension was
published automatically through the visual studio marketplace.
2023-01-09 18:23:37 +08:00
Wenyong Huang
1f4580fbd8
Enable CI wasi test suite for x86-32 classic/fast interpreter (#1866)
The original CI didn't actually run wasi test suite for x86-32 since the `TEST_ON_X86_32=true`
isn't written into $GITHUB_ENV.

And refine the error output when failed to link import global.
2023-01-06 17:31:39 +08:00
Enrico Loparco
c5b7b9d8df
feat: Integrate wasi test suite to wamr-test-suites and CI (#1832)
Add [wasi-testsuite](https://github.com/WebAssembly/wasi-testsuite) to set of tests executed from `test_wamr.sh`. 
Additional description here: #1761
2023-01-05 17:16:44 +08:00
Huang Qi
5d006ad263
Reuse build llvm libraries for spec test on nuttx (#1838)
Fix daily CI break on NuttX.
2022-12-26 14:22:15 +08:00
TianlongLiang
6fd8001eb6
Update CIs and documents to make naming of generated binaries consistent (#1823) 2022-12-24 09:17:39 +08:00
Wenyong Huang
fb8727ba68
Update release notes and fix issues reported by Coverity (#1813) 2022-12-16 14:16:58 +08:00
Wenyong Huang
97d2b5a060
Publish the docker image with tar/zip files (#1808)
And fix issue found in fast jit call indirect.
2022-12-14 09:42:03 +08:00
Huang Qi
d827315122
Enable XIP in CI daily test (#1793) 2022-12-13 11:32:35 +08:00
Huang Qi
a29344ae6c
Enable spec test on nuttx and daily run it (#1763)
- Spec test needs about 15 min
- Skip some test cases that cannot pass now, most of which are FP relative
  (due to potential bugs in NuttX's libc)
2022-12-02 12:39:46 +08:00
liang.he
216b2cb540
Fix a typo in workflow (#1760) 2022-11-30 14:00:30 +08:00
Huang Qi
93d3d09aa1
Clear some warnings and enable -Werror for NuttX (#1756) 2022-11-28 09:44:33 +08:00
Huang Qi
0456043d8d
Fix missing intrinsics for risc-v which were reported by spec test (#1750) 2022-11-25 09:20:38 +08:00
liang.he
021130f4a3
Add more compilation groups of fast jit into CI (#1717) 2022-11-17 16:46:25 +08:00
liang.he
c718e76dea
Use wabt binary instead of building from source in spec test (#1700)
Directly download wabt binary and use it in spec test instead of
building it from source to fasten the spec test.
2022-11-14 15:16:22 +08:00
Wenyong Huang
84161fe084
Add CIs to release new version and publish binary files (#1648)
Add CIs to enable the release process of a new version of WAMR,
and build and publish the binary files when a version is released,
including iwasm, wamrc, lldb, vscode-extension and wamr-ide for
Ubuntu-20.04, Ubuntu-22.04 and MacOS.

And refine the CIs to test spec cases.
2022-10-28 13:55:41 +08:00
Wenyong Huang
e87a554616
Refactor LLVM JIT (#1613)
Refactor LLVM JIT for some purposes:
- To simplify the source code of JIT compilation
- To simplify the JIT modes
- To align with LLVM latest changes
- To prepare for the Multi-tier JIT compilation, refer to #1302

The changes mainly include:
- Remove the MCJIT mode, replace it with ORC JIT eager mode
- Remove the LLVM legacy pass manager (only keep the LLVM new pass manager)
- Change the lazy mode's LLVM module/function binding:
  change each function in an individual LLVM module into all functions in a single LLVM module
- Upgraded ORC JIT to ORCv2 JIT to enable lazy compilation

Refer to #1468
2022-10-18 20:17:34 +08:00
Huang Qi
d7c2e9a6ea
Fix NuttX CI break by install missing dependencies (#1532) 2022-09-29 12:31:56 +08:00
Jämes Ménétrey
dfd16f8e4f
linux-sgx: Implement SGX IPFS as POSIX backend for file interaction (#1489)
This PR integrates an Intel SGX feature called Intel Protection File System Library (IPFS)
into the runtime to create, operate and delete files inside the enclave, while guaranteeing
the confidentiality and integrity of the data persisted. IPFS can be referred to here:
https://www.intel.com/content/www/us/en/developer/articles/technical/overview-of-intel-protected-file-system-library-using-software-guard-extensions.html

Introduce a cmake variable `WAMR_BUILD_SGX_IPFS`, when enabled, the files interaction
API of WASI will leverage IPFS, instead of the regular POSIX OCALLs. The implementation
has been written with light changes to sgx platform layer, so all the security aspects
WAMR relies on are conserved.

In addition to this integration, the following changes have been made:
 - The CI workflow has been adapted to test the compilation of the runtime and sample
    with the flag `WAMR_BUILD_SGX_IPFS` set to true
 - Introduction of a new sample that demonstrates the interaction of the files (called `file`),
 - Documentation of this new feature
2022-09-28 13:09:58 +08:00
Huang Qi
8fcc556e50
ci: Cover more configurations & targets on NuttX (#1448)
Enable building iwasm on Nuttx for target:
* x86
* cortex-m0
* cortex-m4
* cortex-m7
* rv32imac
* rv64imac
* rv64gc
2022-09-05 12:12:32 +08:00
Huang Qi
c56fd8bd5b
Introduce basic CI for nuttx (#1444) 2022-09-02 11:07:59 +08:00
liang.he
aa7d447ee5
Update Ubuntu CI platforms to 20.04 and 22.04 (#1385)
From Gtihub:
The ubuntu-18.04 environment is deprecated, consider switching to
ubuntu-20.04 (ubuntu-latest), or ubuntu-22.04 instead.
https://github.com/actions/runner-images/issues/6002
2022-08-16 10:02:02 +08:00
Wenyong Huang
bf28030993
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.
2022-08-02 16:03:50 +08:00
liang.he
f975a987bf
Separate MacOS workflows from the big one (#1236)
Separate MacOS workflows from the big one so as to avoid too much tasks
And optimize the total duration by reducing getting LLVM libraries times
2022-06-17 17:44:20 +08:00
Xu Jun
77595c9560
Support emit specified custom sections into AoT file (#1207)
And add API to get the content of custom section with
section name for both wasm file and aot file.
2022-06-10 21:51:13 +08:00
Wenyong Huang
60595d72e1
Update CI files (#1030)
Update CI files:
- add another apt repository for spec test on x86-32 as some packages
  cannot be downloaded with the Github default repository
- trigger the CI file when it is modified
2022-03-08 11:52:32 +08:00
Wenyong Huang
7636d86a76
Refactor Orc JIT to enable lazy compilation (#974)
Refactor LLVM Orc JIT to actually enable the lazy compilation and speedup
the launching process:
  https://llvm.org/docs/ORCv2.html#laziness

Main modifications:
- Create LLVM module for each wasm function, wrap it with thread safe module
  so that the modules can be compiled parallelly
- Lookup function from aot module instance's func_ptrs but not directly call the
  function to decouple the module relationship
- Compile the function when it is first called and hasn't been compiled
- Create threads to pre-compile the WASM functions parallelly when loading
- Set Lazy JIT as default, update document and build/test scripts
2022-01-20 18:40:13 +08:00
Xu Jun
ac3f7dcc0e
Enable source debugger CI on windows and darwin (#912) 2021-12-24 16:57:23 +08:00
liang.he
69c004efb4
Enable SGX spec test for AOT mode and add SIMD option (#821) 2021-11-08 17:53:17 +08:00
liang.he
487072a78e
Speed up the spec case test by parallelism (#819)
Port spec-test-script/all.sh to spec-test-script/all.py and enable to run
spec cases with multiple threads parallelly:
- It reduces spec_test.yml from ~14min to ~9min and reduces
  compilation_on_sgx.yml from ~18min to ~12min
- run `./test_wamr.sh` will keep the same experience likes before by default
- run `./test_wamr.sh -P` will enable parallelism mode
- in parallelism mode, all.py will be in a less-output mode. It only outputs
  the last words of failed cases and will not output logs for those passed
2021-11-08 12:39:02 +08:00
liang.he
c591610111
Add CI tasks on SGX platform (#817)
Add CI tasks on SGX platform:
  build iwasm with some feature combinations
  build and run some samples
  test spec cases with interpreter mode and AOT mode
2021-11-05 19:07:54 +08:00
Wenyong Huang
5face80e0c
Fix spec test workflow issue and CI Dockerfile issue (#810)
Fix llvm binaries cache missed issue in spec test workflow,
fix CI Dockerfile issue and refine code format for libc_builtin_wrapper.c.
2021-10-30 09:24:03 +08:00
liang.he
3d5a0bff0f
Enhance workflows by caching llvm directories directly (#805)
Enhance workflows by caching llvm directories directly instead of
caching the llvm-xxx.tar.gz packages, so as to reduce the time
consumption of unpacking the cached LLVM packages.
2021-10-27 17:26:17 +08:00
Wenyong Huang
32242988ed
Apply clang-format for more source files (#795)
Apply clang-format for C source files in folder core/app-mgr,
core/app-framework, and test-tools.
And rename folder component_test to component-test, update
zephyr build document.

Signed-off-by: Wenyong Huang <wenyong.huang@intel.com>
2021-10-21 13:58:34 +08:00
liang.he
225f5d0a64
Enable to trigger code guideline checks when PR is created (#790)
Enable to trigger code guideline checks for C/C++ source codes when PR is created
2021-10-19 17:42:54 +08:00
liang.he
b46b663c16
Enhance spec test workflow to support x86_32 target (#787)
Enable test spec cases on x86_32 target when PR is created.
And Format shell script with [shellfmt](https://marketplace.visualstudio.com/items?itemName=foxundermoon.shell-format).
2021-10-15 17:05:07 +08:00
liang.he
250aba6874
Sync up with wabt latest modification (#296) (#786)
- Remove "--enable-reference-types" and "--enable-bulk-memory" for wat2wasm
to support finished proposals.

- Ignore invalid module in the thread spec repo:
``` wast
;; my_elem.wast
(module
  (table $t 10 funcref)
  (func $f)
  (elem $t (i32.const 0) 0)
  (elem $t (i32.const 0) $f $f)
  (elem $t (offset (i32.const 0)) $f $f)
)
```

run with reference interpreter under spec/interpreter:
``` shell
$ ./wasm ../../../my_elem.wast
../../../my_elem.wast:5.9-5.11: syntax error: duplicate elem segment $t
```

- use a specific commit instead of the latest commit on the thread spec repo
2021-10-14 15:48:45 +08:00
Wenyong Huang
fb4afc7ca4
Apply clang-format for core/iwasm compilation and libraries (#784)
Apply clang-format for core/iwasm/compilation and core/iwasm/libraries files.
Add wasm-c-api empty_imports sample to workflow test.
And enable triggering workflow when core/config.h changes.
2021-10-13 15:13:00 +08:00
Wenyong Huang
8edca21df2
Enable triggering workflows on push events (#783)
And enable cmake build in workflows with multiple cpu cores.
2021-10-12 14:52:16 +08:00
Wenyong Huang
ee1ae4dc2c
Fix CI issues (#781)
Fix spec_test.yml llvm-library cache key name invalid issue.
Trigger CI when core/shared, product-mini and wamr-compiler change.
2021-10-12 11:30:58 +08:00
Wenyong Huang
03494f9487
Refactor CI rules: merge ubuntu/macos/android, enable spec test (#777)
Refactor CI rules:
- merge ubuntu/macos/android into one job file
- add job file to test spec cases
- add compilation for lazy jit, debug interpreter and debug aot
- add compilation for performance profile, dump call stack and mini-loader
- re-org llvm build script to build lldb

Signed-off-by: Wenyong Huang <wenyong.huang@intel.com>
2021-10-11 20:32:29 +08:00
Wenyong Huang
7be0d385a6
Implement SIMD latest opcodes and update LLVM to 13.0 (#758)
Implement the latest SIMD opcodes and update LLVM 13.0,
update the llvm build scripts, update the sample workloads‘ build scripts,
and build customized wasi-sdk to build some workloads.
Also refine the CI rules.

Signed-off-by: Wenyong Huang <wenyong.huang@intel.com>
2021-09-17 19:12:57 +08:00
Wenyong Huang
4e4d48e72b
Fix several coding style and return value unchecked issues (#722)
And enable building Windows CI with multi cores
2021-09-04 10:08:34 +08:00
Wenyong Huang
edb184f709
Implement most missing wasm-c-api APIs (#303) (#676)
Remove unnecessary functions and implement more APIs:
- wasm_##name##same
- wasm##name##as_ref
- wasm_ref_as##name##
- wasm_ref_delete
- wasm_module_validate
- wasm_table_get/set/size
- wasm_memory_size
- wasm_config_new
- wasm_foreign_new

And add more wasm-c-api samples, update the related documen, add more CI rules.

Signed-off-by: Wenyong Huang <wenyong.huang@intel.com>
2021-07-28 21:53:37 +08:00
Huang Qi
04e7afe55d
Update documents (#669)
Update CI rules to improve CI build speed, update document about arch support and update document of wamrc help.

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2021-07-22 13:52:48 +08:00
Wenyong Huang
0f1ce9ef3d
Implement wasm-c-api frame/trap APIs for AOT mode (#663)
And update CI workflow to build/cache llvm and run wasm-c-api samples.
2021-07-13 09:01:03 +08:00
Xu Jun
621231a48b
Create CI script for android platform (#591) 2021-03-24 18:05:23 +08:00
Xu Jun
fc50404115
add uvwasi implementation to support wasi on windows [experimental] (#534)
add uvwasi implementation to support wasi on windows [experimental] and update windows.yml

Co-authored-by: Wenyong Huang <wenyong.huang@intel.com>
2021-02-22 14:17:46 +08:00
lum1n0us
4787b150b8
Enable multi-module support for wasm-c-api (#426)
it is allowed that all imported functions and globals can be
linked by multi-module feature automatically or by wasm-c-api manually
2020-10-16 17:43:57 +08:00