Skip to content

Performance

Wenyong Huang edited this page Oct 8, 2021 · 5 revisions

Performance and memory

Test date: 9/1/2020

X86-64 platform:

CPU:Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz
OS :ubuntu 18.04 64-bit
Compiler:gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04), flag: O3

performance comparison:

workload wamr-aot / wasm3 wasm3 / wamr-interpreter wamr-aot / GCC(O3) wamr interpreters (fast/classic)
matrix 22.02 1.23 0.68 2.47
gimli 9.94 1.07 0.94 2.08
CoreMark 8.79 1.32 0.79 2.52

Note

  • The numbers in the column are the performance ratios of the two runtime engines provided. Workloads matrix and gimli are measured by the execution time, and CoreMark is measured by its reported score. A/B denotes the execution_time_of_B/execution_time_of_A, or the score_of_A/score_of_B. For example, matrix 22.02 means that execution_time_of_wasm3/execution_time_of_wamr-aot is 22.02, CoreMakr 8.79 means score_of_wamr-aot/score_of_wasm3 is 8.79.
  • WAMR provides two interpreters - the fast version for advanced performance and and the classic version for smaller footprint respectively.

ARMV7 Cortex-M7:

Board: nucleo_f767zi (ARMV7 Cortex-M7)
OS : Zephyr
Compiler: arm-zephyr-eabi-gcc (crosstool-NG 1.24.0.37-3f461da-dirty) 9.2.0, Os

performance comparison:

workload wamr-aot/wasm3 wasm3/wamr-interpreter wamr interpreters (fast/classic)
matrix 30.17 1.06 1.65
gimli 19.13 1.11 2.03
seqhash 21.12 1.15 1.34

Memory consumption

workload: CoreMark
measurement tool: valgrind/massif

WASM interpreter Peak memory usage
WAMR classic 365KB
WAMR fast 485KB
wasm3 514KB

WASM application binary size

Compilation option: -Os

Workload GCC compiled native binary (Bytes) Wasm bytecode (Bytes) iwasm-aot module (Bytes)
coremark 23120 10457 17348
base64 8792 1026 1840
gimli 8640 498 1080

Misc.

The page is also a response to the data published by wasm3 at https://github.com/wasm3/wasm3/blob/master/docs/Performance.md.

Some background of the performance comparison between WAMR and wasm3:

https://github.com/bytecodealliance/wasm-micro-runtime/issues/134

Clone this wiki locally