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

Unified Diff: test/mjsunit/harmony/simd.js

Issue 1294513004: [simd.js] Update to spec version 0.8.2. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase. Created 5 years, 4 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 | « test/cctest/test-simd.cc ('k') | test/simdjs/testcfg.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/harmony/simd.js
diff --git a/test/mjsunit/harmony/simd.js b/test/mjsunit/harmony/simd.js
index 0c52072646c7ede235b46cf6ebe0ed20ae146595..fe4b0358f98b53b3c50e9d6c6afef6f231436b83 100644
--- a/test/mjsunit/harmony/simd.js
+++ b/test/mjsunit/harmony/simd.js
@@ -45,9 +45,9 @@ function isValidSimdString(string, value, type, lanes) {
}
-var simdTypeNames = ['Float32x4', 'Int32x4', 'Bool32x4',
- 'Int16x8', 'Bool16x8',
- 'Int8x16', 'Bool8x16'];
+var simdTypeNames = ['Float32x4', 'Int32x4', 'Uint32x4', 'Bool32x4',
+ 'Int16x8', 'Uint16x8', 'Bool16x8',
+ 'Int8x16', 'Uint8x16', 'Bool8x16'];
var nonSimdValues = [347, 1.275, NaN, "string", null, undefined, {},
function() {}];
@@ -212,6 +212,24 @@ function TestCoercions(type, lanes) {
test(4294967296, 0);
test(4294967297, 1);
break;
+ case 'Uint32x4':
+ test(Infinity, 0);
+ test(-Infinity, 0);
+ test(NaN, 0);
+ test(0, 0);
+ test(-0, 0);
+ test(Number.MIN_VALUE, 0);
+ test(-Number.MIN_VALUE, 0);
+ test(0.1, 0);
+ test(-0.1, 0);
+ test(1, 1);
+ test(1.1, 1);
+ test(-1, 4294967295);
+ test(-1.6, 4294967295);
+ test(4294967295, 4294967295);
+ test(4294967296, 0);
+ test(4294967297, 1);
+ break;
case 'Int16x8':
test(Infinity, 0);
test(-Infinity, 0);
@@ -233,6 +251,24 @@ function TestCoercions(type, lanes) {
test(65536, 0);
test(65537, 1);
break;
+ case 'Uint16x8':
+ test(Infinity, 0);
+ test(-Infinity, 0);
+ test(NaN, 0);
+ test(0, 0);
+ test(-0, 0);
+ test(Number.MIN_VALUE, 0);
+ test(-Number.MIN_VALUE, 0);
+ test(0.1, 0);
+ test(-0.1, 0);
+ test(1, 1);
+ test(1.1, 1);
+ test(-1, 65535);
+ test(-1.6, 65535);
+ test(65535, 65535);
+ test(65536, 0);
+ test(65537, 1);
+ break;
case 'Int8x16':
test(Infinity, 0);
test(-Infinity, 0);
@@ -254,6 +290,24 @@ function TestCoercions(type, lanes) {
test(256, 0);
test(257, 1);
break;
+ case 'Uint8x16':
+ test(Infinity, 0);
+ test(-Infinity, 0);
+ test(NaN, 0);
+ test(0, 0);
+ test(-0, 0);
+ test(Number.MIN_VALUE, 0);
+ test(-Number.MIN_VALUE, 0);
+ test(0.1, 0);
+ test(-0.1, 0);
+ test(1, 1);
+ test(1.1, 1);
+ test(-1, 255);
+ test(-1.6, 255);
+ test(255, 255);
+ test(256, 0);
+ test(257, 1);
+ break;
case 'Bool32x4':
case 'Bool16x8':
case 'Bool8x16':
@@ -330,8 +384,11 @@ function TestEquality(type, lanes) {
test(NaN, NaN);
break;
case 'Int32x4':
+ case 'Uint32x4':
case 'Int16x8':
+ case 'Uint16x8':
case 'Int8x16':
+ case 'Uint8x16':
test(1, 2);
test(1, 1);
test(1, -1);
@@ -381,8 +438,11 @@ function TestSameValue(type, lanes) {
test(NaN, NaN);
break;
case 'Int32x4':
+ case 'Uint32x4':
case 'Int16x8':
+ case 'Uint16x8':
case 'Int8x16':
+ case 'Uint8x16':
test(1, 2);
test(1, 1);
test(1, -1);
« no previous file with comments | « test/cctest/test-simd.cc ('k') | test/simdjs/testcfg.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698