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

Side by Side Diff: test/mjsunit/wasm/embenchen/copy.js

Issue 1770383002: [wasm] Rename _WASMEXP_ object to Wasm. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « test/mjsunit/wasm/embenchen/box2d.js ('k') | test/mjsunit/wasm/embenchen/corrections.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Modified embenchen to direct to asm-wasm. 1 // Modified embenchen to direct to asm-wasm.
2 // Flags: --expose-wasm 2 // Flags: --expose-wasm
3 3
4 var EXPECTED_OUTPUT = 'sum:8930\n'; 4 var EXPECTED_OUTPUT = 'sum:8930\n';
5 var Module = { 5 var Module = {
6 arguments: [1], 6 arguments: [1],
7 print: function(x) {Module.printBuffer += x + '\n';}, 7 print: function(x) {Module.printBuffer += x + '\n';},
8 preRun: [function() {Module.printBuffer = ''}], 8 preRun: [function() {Module.printBuffer = ''}],
9 postRun: [function() { 9 postRun: [function() {
10 assertEquals(EXPECTED_OUTPUT, Module.printBuffer); 10 assertEquals(EXPECTED_OUTPUT, Module.printBuffer);
(...skipping 5434 matching lines...) Expand 10 before | Expand all | Expand 10 after
5445 5445
5446 5446
5447 var Math_min = Math.min; 5447 var Math_min = Math.min;
5448 function asmPrintInt(x, y) { 5448 function asmPrintInt(x, y) {
5449 Module.print('int ' + x + ',' + y);// + ' ' + new Error().stack); 5449 Module.print('int ' + x + ',' + y);// + ' ' + new Error().stack);
5450 } 5450 }
5451 function asmPrintFloat(x, y) { 5451 function asmPrintFloat(x, y) {
5452 Module.print('float ' + x + ',' + y);// + ' ' + new Error().stack); 5452 Module.print('float ' + x + ',' + y);// + ' ' + new Error().stack);
5453 } 5453 }
5454 // EMSCRIPTEN_START_ASM 5454 // EMSCRIPTEN_START_ASM
5455 var asm = _WASMEXP_.instantiateModuleFromAsm((function Module(global, env, buffe r) { 5455 var asm = Wasm.instantiateModuleFromAsm((function Module(global, env, buffer) {
5456 'use asm'; 5456 'use asm';
5457 var HEAP8 = new global.Int8Array(buffer); 5457 var HEAP8 = new global.Int8Array(buffer);
5458 var HEAP16 = new global.Int16Array(buffer); 5458 var HEAP16 = new global.Int16Array(buffer);
5459 var HEAP32 = new global.Int32Array(buffer); 5459 var HEAP32 = new global.Int32Array(buffer);
5460 var HEAPU8 = new global.Uint8Array(buffer); 5460 var HEAPU8 = new global.Uint8Array(buffer);
5461 var HEAPU16 = new global.Uint16Array(buffer); 5461 var HEAPU16 = new global.Uint16Array(buffer);
5462 var HEAPU32 = new global.Uint32Array(buffer); 5462 var HEAPU32 = new global.Uint32Array(buffer);
5463 var HEAPF32 = new global.Float32Array(buffer); 5463 var HEAPF32 = new global.Float32Array(buffer);
5464 var HEAPF64 = new global.Float64Array(buffer); 5464 var HEAPF64 = new global.Float64Array(buffer);
5465 5465
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
5970 } 5970 }
5971 5971
5972 // shouldRunNow refers to calling main(), not run(). 5972 // shouldRunNow refers to calling main(), not run().
5973 var shouldRunNow = true; 5973 var shouldRunNow = true;
5974 if (Module['noInitialRun']) { 5974 if (Module['noInitialRun']) {
5975 shouldRunNow = false; 5975 shouldRunNow = false;
5976 } 5976 }
5977 5977
5978 5978
5979 run([].concat(Module["arguments"])); 5979 run([].concat(Module["arguments"]));
OLDNEW
« no previous file with comments | « test/mjsunit/wasm/embenchen/box2d.js ('k') | test/mjsunit/wasm/embenchen/corrections.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698