OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Flags: --expose-wasm | 5 // Flags: --validate-asm --allow-natives-syntax |
6 | 6 |
7 // /v8/test/mjsunit/regress/regress-crbug-431602.js | 7 // /v8/test/mjsunit/regress/regress-crbug-431602.js |
8 // /v8/test/mjsunit/lazy-load.js | 8 // /v8/test/mjsunit/lazy-load.js |
9 // /v8/test/mjsunit/wasm/asm-wasm.js | 9 // /v8/test/mjsunit/wasm/asm-wasm.js |
10 // /v8/test/mjsunit/debug-toggle-mirror-cache.js | 10 // /v8/test/mjsunit/debug-toggle-mirror-cache.js |
11 // /v8/test/mjsunit/debug-stack-check-position.js | 11 // /v8/test/mjsunit/debug-stack-check-position.js |
12 | 12 |
13 // Begin stripped down and modified version of mjsunit.js for easy minimization
in CF. | 13 // Begin stripped down and modified version of mjsunit.js for easy minimization
in CF. |
| 14 var Wasm = { |
| 15 instantiateModuleFromAsm: function(text, stdlib, ffi, heap) { |
| 16 var module_decl = eval('(' + text + ')'); |
| 17 if (%IsNotAsmWasmCode(module_decl)) { |
| 18 throw "validate failure"; |
| 19 } |
| 20 var ret = module_decl(stdlib, ffi, heap); |
| 21 if (%IsNotAsmWasmCode(module_decl)) { |
| 22 throw "bad module args"; |
| 23 } |
| 24 return ret; |
| 25 }, |
| 26 }; |
14 function MjsUnitAssertionError(message) {} | 27 function MjsUnitAssertionError(message) {} |
15 MjsUnitAssertionError.prototype.toString = function () { return this.message; }; | 28 MjsUnitAssertionError.prototype.toString = function () { return this.message; }; |
16 var assertSame; | 29 var assertSame; |
17 var assertEquals; | 30 var assertEquals; |
18 var assertEqualsDelta; | 31 var assertEqualsDelta; |
19 var assertArrayEquals; | 32 var assertArrayEquals; |
20 var assertPropertiesEqual; | 33 var assertPropertiesEqual; |
21 var assertToStringEquals; | 34 var assertToStringEquals; |
22 var assertTrue; | 35 var assertTrue; |
23 var assertFalse; | 36 var assertFalse; |
(...skipping 1424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1448 function __f_113() { | 1461 function __f_113() { |
1449 return 1; | 1462 return 1; |
1450 } | 1463 } |
1451 try { | 1464 try { |
1452 Debug.setListener(__f_112); | 1465 Debug.setListener(__f_112); |
1453 nop(); | 1466 nop(); |
1454 __f_113(); | 1467 __f_113(); |
1455 Debug.setListener(null); | 1468 Debug.setListener(null); |
1456 assertNull(__v_112); | 1469 assertNull(__v_112); |
1457 } catch(e) { print("Caught: " + e); } | 1470 } catch(e) { print("Caught: " + e); } |
OLD | NEW |