Skip to content

Commit 04e7afe

Browse files
authored
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 <[email protected]>
1 parent e4023c8 commit 04e7afe

File tree

4 files changed

+40
-31
lines changed

4 files changed

+40
-31
lines changed

.github/workflows/android.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# This is a basic workflow to help you get started with Actions
22

3-
name: android
3+
name: Android
44

55
# Controls when the action will run.
66
on:
@@ -31,61 +31,61 @@ jobs:
3131
cd product-mini/platforms/android
3232
mkdir build && cd build
3333
cmake ..
34-
make
34+
make -j $(nproc)
3535
cd .. && rm -rf build
3636
- name: Build iwasm [Classic interp]
3737
run: |
3838
cd product-mini/platforms/android
3939
mkdir build && cd build
4040
cmake .. -DWAMR_BUILD_FAST_INTERP=0
41-
make
41+
make -j $(nproc)
4242
cd .. && rm -rf build
4343
- name: Build iwasm [Multi module]
4444
run: |
4545
cd product-mini/platforms/android
4646
mkdir build && cd build
4747
cmake .. -DWAMR_BUILD_MULTI_MODULE=1
48-
make
48+
make -j $(nproc)
4949
cd .. && rm -rf build
5050
- name: Build iwasm [lib-pthread]
5151
run: |
5252
cd product-mini/platforms/android
5353
mkdir build && cd build
5454
cmake .. -DWAMR_BUILD_LIB_PTHREAD=1
55-
make
55+
make -j $(nproc)
5656
cd .. && rm -rf build
5757
- name: Build iwasm [aot only]
5858
run: |
5959
cd product-mini/platforms/android
6060
mkdir build && cd build
6161
cmake .. -DWAMR_BUILD_AOT=1 -DWAMR_BUILD_INTERP=0
62-
make
62+
make -j $(nproc)
6363
cd .. && rm -rf build
6464
- name: Build iwasm [interp only]
6565
run: |
6666
cd product-mini/platforms/android
6767
mkdir build && cd build
6868
cmake .. -DWAMR_BUILD_AOT=0
69-
make
69+
make -j $(nproc)
7070
cd .. && rm -rf build
7171
- name: Build iwasm [memory profiling]
7272
run: |
7373
cd product-mini/platforms/android
7474
mkdir build && cd build
7575
cmake .. -DWAMR_BUILD_MEMORY_PROFILING=1
76-
make
76+
make -j $(nproc)
7777
cd .. && rm -rf build
7878
- name: Build iwasm [tail call]
7979
run: |
8080
cd product-mini/platforms/android
8181
mkdir build && cd build
8282
cmake .. -DWAMR_BUILD_TAIL_CALL=1
83-
make
83+
make -j $(nproc)
8484
cd .. && rm -rf build
8585
- name: Build iwasm [custom name section]
8686
run: |
8787
cd product-mini/platforms/android
8888
mkdir build && cd build
8989
cmake .. -DWAMR_BUILD_CUSTOM_NAME_SECTION=1
90-
make
90+
make -j $(nproc)
9191
cd .. && rm -rf build

.github/workflows/linux.yml

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -29,63 +29,63 @@ jobs:
2929
cd product-mini/platforms/linux
3030
mkdir build && cd build
3131
cmake ..
32-
make
32+
make -j $(nproc)
3333
cd .. && rm -rf build
3434
- name: Build iwasm [Classic interp]
3535
run: |
3636
cd product-mini/platforms/linux
3737
mkdir build && cd build
3838
cmake .. -DWAMR_BUILD_FAST_INTERP=0
39-
make
39+
make -j $(nproc)
4040
cd .. && rm -rf build
4141
- name: Build iwasm [Multi module]
4242
run: |
4343
cd product-mini/platforms/linux
4444
mkdir build && cd build
4545
cmake .. -DWAMR_BUILD_MULTI_MODULE=1
46-
make
46+
make -j $(nproc)
4747
cd .. && rm -rf build
4848
- name: Build iwasm [lib-pthread]
4949
run: |
5050
cd product-mini/platforms/linux
5151
mkdir build && cd build
5252
cmake .. -DWAMR_BUILD_LIB_PTHREAD=1
53-
make
53+
make -j $(nproc)
5454
cd .. && rm -rf build
5555
- name: Build iwasm [aot only]
5656
run: |
5757
cd product-mini/platforms/linux
5858
mkdir build && cd build
5959
cmake .. -DWAMR_BUILD_AOT=1 -DWAMR_BUILD_INTERP=0
60-
make
60+
make -j $(nproc)
6161
cd .. && rm -rf build
6262
- name: Build iwasm [interp only]
6363
run: |
6464
cd product-mini/platforms/linux
6565
mkdir build && cd build
6666
cmake .. -DWAMR_BUILD_AOT=0
67-
make
67+
make -j $(nproc)
6868
cd .. && rm -rf build
6969
- name: Build iwasm [memory profiling]
7070
run: |
7171
cd product-mini/platforms/linux
7272
mkdir build && cd build
7373
cmake .. -DWAMR_BUILD_MEMORY_PROFILING=1
74-
make
74+
make -j $(nproc)
7575
cd .. && rm -rf build
7676
- name: Build iwasm [tail call]
7777
run: |
7878
cd product-mini/platforms/linux
7979
mkdir build && cd build
8080
cmake .. -DWAMR_BUILD_TAIL_CALL=1
81-
make
81+
make -j $(nproc)
8282
cd .. && rm -rf build
8383
- name: Build iwasm [custom name section]
8484
run: |
8585
cd product-mini/platforms/linux
8686
mkdir build && cd build
8787
cmake .. -DWAMR_BUILD_CUSTOM_NAME_SECTION=1
88-
make
88+
make -j $(nproc)
8989
cd .. && rm -rf build
9090
- name: Cache LLVM libraries
9191
uses: actions/cache@v2
@@ -106,7 +106,7 @@ jobs:
106106
cd wamr-compiler
107107
mkdir build && cd build
108108
cmake ..
109-
make
109+
make -j $(nproc)
110110
cd ..
111111
- name: download and install wasi-sdk
112112
run: |
@@ -127,7 +127,7 @@ jobs:
127127
cd samples/wasm-c-api
128128
mkdir build && cd build
129129
cmake ..
130-
make
130+
make -j $(nproc)
131131
./callback
132132
./callback_chain
133133
./global
@@ -140,7 +140,7 @@ jobs:
140140
cd samples/wasm-c-api
141141
mkdir build && cd build
142142
cmake -DWAMR_BUILD_INTERP=0 -DWAMR_BUILD_JIT=1 -DWAMR_BUILD_AOT=1 ..
143-
make
143+
make -j $(nproc)
144144
./callback
145145
./callback_chain
146146
./global
@@ -153,7 +153,7 @@ jobs:
153153
cd samples/wasm-c-api
154154
mkdir build && cd build
155155
cmake -DWAMR_BUILD_INTERP=0 -DWAMR_BUILD_JIT=0 -DWAMR_BUILD_AOT=1 ..
156-
make
156+
make -j $(nproc)
157157
./callback
158158
./callback_chain
159159
./global
@@ -171,19 +171,19 @@ jobs:
171171
cd samples/multi-thread
172172
mkdir build && cd build
173173
cmake ..
174-
make
174+
make -j $(nproc)
175175
./iwasm wasm-apps/test.wasm
176176
- name: Build Sample [multi-module]
177177
run: |
178178
cd samples/multi-module
179179
mkdir build && cd build
180180
cmake ..
181-
make
181+
make -j $(nproc)
182182
./multi_module
183183
- name: Build Sample [spawn-thread]
184184
run: |
185185
cd samples/spawn-thread
186186
mkdir build && cd build
187187
cmake ..
188-
make
188+
make -j $(nproc)
189189
./spawn_thread

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ The iwasm supports the following architectures:
4848
- AArch64 (Cortex-A57 and Cortex-A53 are tested)
4949
- MIPS
5050
- XTENSA
51-
- RISCV64, RISCV32 (interpreter only)
51+
- RISCV64, RISCV32 (RISC-V LP64 and RISC-V LP64D are tested)
5252

5353
Following platforms are supported. Refer to [WAMR porting guide](./doc/port_wamr.md) for how to port WAMR to a new platform.
5454

doc/build_wasm_app.md

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -236,11 +236,14 @@ wamrc supports a number of compilation options through the command line argument
236236
wamrc --help
237237
Usage: wamrc [options] -o output_file wasm_file
238238
--target=<arch-name> Set the target arch, which has the general format: <arch><sub>
239-
<arch> = x86_64, i386, aarch64, arm, thumb, xtensa, mips.
239+
<arch> = x86_64, i386, aarch64, arm, thumb, xtensa, mips,
240+
riscv64, riscv32.
240241
Default is host arch, e.g. x86_64
241242
<sub> = for ex. on arm or thumb: v5, v6m, v7a, v7m, etc.
242243
Use --target=help to list supported targets
243-
--target-abi=<abi> Set the target ABI, e.g. gnu, eabi, gnueabihf, etc. (default: gnu)
244+
--target-abi=<abi> Set the target ABI, e.g. gnu, eabi, gnueabihf, msvc, etc.
245+
Default is gnu if target isn't riscv64 or riscv32
246+
For target riscv64 and riscv32, default is lp64d and ilp32d
244247
Use --target-abi=help to list all the ABI supported
245248
--cpu=<cpu> Set the target CPU (default: host CPU, e.g. skylake)
246249
Use --cpu=help to list all the CPU supported
@@ -263,10 +266,16 @@ Usage: wamrc [options] -o output_file wasm_file
263266
llvmir-opt Optimized LLVM IR
264267
--enable-bulk-memory Enable the post-MVP bulk memory feature
265268
--enable-multi-thread Enable multi-thread feature, the dependent features bulk-memory and
266-
--enable-tail-call Enable the post-MVP tail call feature
267269
thread-mgr will be enabled automatically
268-
--enable-simd Enable the post-MVP 128-bit SIMD feature
270+
--enable-tail-call Enable the post-MVP tail call feature
271+
--disable-simd Disable the post-MVP 128-bit SIMD feature:
272+
currently 128-bit SIMD is only supported for x86-64 target,
273+
and by default it is enabled in x86-64 target and disabled
274+
in other targets
275+
--enable-ref-types Enable the post-MVP reference types feature
276+
--disable-aux-stack-check Disable auxiliary stack overflow/underflow check
269277
--enable-dump-call-stack Enable stack trace feature
278+
--enable-perf-profiling Enable function performance profiling
270279
-v=n Set log verbose level (0 to 5, default is 2), larger with more log
271280
Examples: wamrc -o test.aot test.wasm
272281
wamrc --target=i386 -o test.aot test.wasm

0 commit comments

Comments
 (0)