From b93ae1f7eb527964169de27567c254663987f3e1 Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Wed, 17 Jan 2018 14:38:49 -0800 Subject: [PATCH] [WebAssembly] Add TODO --- arch/wasm32/wasm.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/wasm32/wasm.js b/arch/wasm32/wasm.js index 1b15c63e..4f9ed366 100644 --- a/arch/wasm32/wasm.js +++ b/arch/wasm32/wasm.js @@ -43,6 +43,9 @@ if (typeof process === 'object' && typeof require === 'function') { // This is n } function setHeap(m) { + // TODO(sbc): Handle the case where wasm calls grow_memory. Currently we + // call setHeap when we modify the memory from JavaScript, but not when + // the wasm code modifies is. memory = m heap = m.buffer heap_uint8 = new Uint8Array(heap);