Upgrade V8 to version 4.9.385.28
https://chromium.googlesource.com/v8/v8/+/4.9.385.28
FPIIM-449
Change-Id: I4b2e74289d4bf3667f2f3dc8aa2e541f63e26eb4
diff --git a/test/mjsunit/wasm/verify-function-simple.js b/test/mjsunit/wasm/verify-function-simple.js
new file mode 100644
index 0000000..c4d51c7
--- /dev/null
+++ b/test/mjsunit/wasm/verify-function-simple.js
@@ -0,0 +1,44 @@
+// Copyright 2015 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");
+
+try {
+ var data = bytes(
+ 0, kAstStmt, // signature
+ 3, 0, // local int32 count
+ 4, 0, // local int64 count
+ 5, 0, // local float32 count
+ 6, 0, // local float64 count
+ kExprNop // body
+ );
+
+ _WASMEXP_.verifyFunction(data);
+ print("ok");
+} catch (e) {
+ assertTrue(false);
+}
+
+
+var threw = false;
+try {
+ var data = bytes(
+ 0, kAstI32, // signature
+ 2, 0, // local int32 count
+ 3, 0, // local int64 count
+ 4, 0, // local float32 count
+ 5, 0, // local float64 count
+ kExprBlock, 2, kExprNop, kExprNop // body
+ );
+
+ _WASMEXP_.verifyFunction(data);
+ print("not ok");
+} catch (e) {
+ print("ok: " + e);
+ threw = true;
+}
+
+assertTrue(threw);