SwadicalRag / wasm2lua

wasm2lua: converting WASM into Lua
MIT License
190 stars 10 forks source link

Consider using a bitvector for lua memory type tracking. #23

Open MDFL64 opened 5 years ago

MDFL64 commented 5 years ago

Currently memory types are tracked using a (hash)table.

Performing a table lookup for every memory operation is probably not the best idea. Type ids only take up 2 bits of space, so we should be able to store 16 cells (64 bytes) worth of type ids per bitvector cell.