← Lab /Software

WebAssembly enables unaltered AI models in TrustZone with 22% overhead

The authors claim their WebAssembly-based solution runs unmodified AI models in OP-TEE with 22% overhead versus manual porting and 6% extra inference latency

Software arXiv 8 Oct 2026 Method Prototype evidence Threat model

Published as “Protecting CPU AI On Edge TEEs: WebAssembly's Promise and Practical Challenges”

Why it matters

Enables protection of AI model IP on edge devices without costly source-code porting, but performance and compatibility constraints limit its immediate applicability to larger or GPU-accelerated models.

Summary

The authors show that running unmodified AI models compiled to WebAssembly inside OP-TEE adds a 22% overhead compared to a manually ported native Trusted Application, and incurs a 6% slower inference latency. Their evaluation on an NVIDIA Jetson AGX Orin measures a 5.61% (21.7 μs) slowdown when moving from REE-WAMR to TEE-WAMR, and a 23.6% slowdown due to the WAMR runtime itself. However, they could not measure native execution inside the TEE for the MobileNetV2 model because the TA was too large to load, limiting the completeness of the performance claim.

What they found 5

  1. Overall overhead of 22% compared to a manually ported native OP-TEE application

    “incurs an additional overhead of 22% in comparison to an application manually ported to OP-TEE”

  2. Inference latency increase of 6% for AI models running in OP-TEE

    “with an additional inference latency of 6% without significant porting effort”

  3. Switching from REE WAMR to TEE WAMR adds 5.61% (21.7 μs) slowdown

    “switching from the REE WamR environment to TEE WamR results in a mean slowdown of 21.7μs (+5.61%)”

  4. The dominant performance cost is the WAMR runtime itself (+23.6% overhead)

    “the greatest overhead does not originate from switching from the REE to the TEE (+2.62%), but from making use of WamR (+23.6%)”

  5. Native execution inside the TEE could not be measured for MobileNetV2 because the TA was too large

    “The OP-TEE native environment is missing due to the size of the MobileNetV2 ONNX model (13.59 MiB) and the then generated C code (14.2 MiB) by onnx2c, which makes the resulting TA too large (14.9 MiB) for OP-TEE to load into the translation tables”

Caveats 5

  • The authors could not evaluate native execution inside OP-TEE for the MobileNetV2 model, so the reported 6% inference slowdown is based only on comparison with REE-WAMR, not with a true native TEE baseline.
  • Only the no multithreading and the memory limits remain a limitation.
  • we are gravely restricted by the limited support for current workloads, especially AI, in the WASI ecosystem.
  • it is impossible to know the maximum available amount of memory without also knowing on which device it runs.
  • our solution lacks GPU acceleration

What’s new here 4

  • Runs unaltered AI models compiled to WebAssembly inside Arm TrustZone OP-TEE without source code changes.
  • Provides an offline model distribution mechanism that encrypts the Wasm binary and stores the decryption key in device fuses.
  • Integrates the latest WebAssembly Micro Runtime (WAMR) version with AOT support for TEEs.
  • Evaluates both startup and inference latency on a real edge device (Jetson AGX Orin).

Threat model stated by the source

Adversaryan entity that fully controls the device's Rich Execution Environment (REE) and all interfaces between REE, TEE, and the outside world, aiming to steal AI model IP
Capabilityread/write access to REE memory, intercept communication, and launch software attacks within the REE; cannot compromise the model distributor or break secure boot
AssumesSecure confidential computing environment correctly enforces memory confidentiality; Secure boot prevents unauthorized code in the TEE; All TEE software (except the Wasm modules) is trusted