Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(487)

Unified Diff: test/mjsunit/regress/wasm/regression-699485.js

Issue 2772973002: [wasm] Detach memory buffer only when GrowMemory is called from the JS API (Closed)
Patch Set: Add comment Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/wasm/wasm-module.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/regress/wasm/regression-699485.js
diff --git a/test/mjsunit/regress/wasm/regression-699485.js b/test/mjsunit/regress/wasm/regression-699485.js
new file mode 100644
index 0000000000000000000000000000000000000000..12477c5d37cbc36621ec524c77714b3a97407902
--- /dev/null
+++ b/test/mjsunit/regress/wasm/regression-699485.js
@@ -0,0 +1,22 @@
+// Copyright 2016 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --expose-wasm
+
+load("test/mjsunit/wasm/wasm-constants.js");
+load("test/mjsunit/wasm/wasm-module-builder.js");
+
+(function() {
+"use asm";
+var builder = new WasmModuleBuilder();
+builder.addMemory(0, 5, false);
+builder.addFunction("regression_699485", kSig_i_v)
+ .addBody([
+ kExprI32Const, 0x04,
+ kExprNop,
+ kExprGrowMemory, 0x00,
+ ]).exportFunc();
+let module = builder.instantiate();
+assertEquals(0, module.exports.regression_699485());
+})();
« no previous file with comments | « src/wasm/wasm-module.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698