1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:27:44 +00:00

LibWasm+Everywhere: Make the instruction count limit configurable

...and enable it for LibWeb and test-wasm.
Note that `wasm` will not be limited by this.
This commit is contained in:
Ali Mohammad Pur 2021-07-15 00:00:45 +04:30
parent 70b94f58b2
commit 65cd5526cb
6 changed files with 25 additions and 3 deletions

View file

@ -505,10 +505,13 @@ public:
auto& store() const { return m_store; }
auto& store() { return m_store; }
void enable_instruction_count_limit() { m_should_limit_instruction_count = true; }
private:
Optional<InstantiationError> allocate_all_initial_phase(Module const&, ModuleInstance&, Vector<ExternValue>&, Vector<Value>& global_values);
Optional<InstantiationError> allocate_all_final_phase(Module const&, ModuleInstance&, Vector<Vector<Reference>>& elements);
Store m_store;
bool m_should_limit_instruction_count { false };
};
class Linker {