Skip to content

Wasmito support #388

Description

@tolauwae

Goal: port wasmito instrumentation to WARDuino main branch (see fork: carllocos/WARDuino)

Overview of the API (hook messages):

Image

Implementation strategy:

  1. program counter: replace op code at program counter with magic constant 0xFF
  2. events: hijack existing ifs
  3. call fidx: copy block for fidx in functions map to the new index N, replace the first instruction of the old function block with the magic constant 0xFF and index 0xN. Replace fidx with N in hook, and add return at end.

0xFF replaces instruction with the hook encoded as an array of bytes, each element of the hook is of type:

  • DBG: 0x01
  • WASM: 0x02

Structure of each building block:

DBG = I8 + I8
WASM = I8 + N x I8

Metadata

Metadata

Labels

No labels
No labels

Fields

No fields configured for Feature.

Projects

Status
No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions