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

Side by Side Diff: runtime/lib/typed_data.dart

Issue 23018009: Add add and subtract operations to Uint32x4 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/lib/simd128.cc ('k') | runtime/vm/bootstrap_natives.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // patch classes for Int8List ..... Float64List and ByteData implementations. 5 // patch classes for Int8List ..... Float64List and ByteData implementations.
6 6
7 patch class Int8List { 7 patch class Int8List {
8 /* patch */ factory Int8List(int length) { 8 /* patch */ factory Int8List(int length) {
9 return new _Int8Array(length); 9 return new _Int8Array(length);
10 } 10 }
(...skipping 2063 matching lines...) Expand 10 before | Expand all | Expand 10 after
2074 } 2074 }
2075 Uint32x4 _or(Uint32x4 other) native "Uint32x4_or"; 2075 Uint32x4 _or(Uint32x4 other) native "Uint32x4_or";
2076 Uint32x4 operator &(Uint32x4 other) { 2076 Uint32x4 operator &(Uint32x4 other) {
2077 return _and(other); 2077 return _and(other);
2078 } 2078 }
2079 Uint32x4 _and(Uint32x4 other) native "Uint32x4_and"; 2079 Uint32x4 _and(Uint32x4 other) native "Uint32x4_and";
2080 Uint32x4 operator ^(Uint32x4 other) { 2080 Uint32x4 operator ^(Uint32x4 other) {
2081 return _xor(other); 2081 return _xor(other);
2082 } 2082 }
2083 Uint32x4 _xor(Uint32x4 other) native "Uint32x4_xor"; 2083 Uint32x4 _xor(Uint32x4 other) native "Uint32x4_xor";
2084 Uint32x4 operator +(Uint32x4 other) {
2085 return _add(other);
2086 }
2087 Uint32x4 _add(Uint32x4 other) native "Uint32x4_add";
2088 Uint32x4 operator -(Uint32x4 other) {
2089 return _sub(other);
2090 }
2091 Uint32x4 _sub(Uint32x4 other) native "Uint32x4_sub";
2084 int get x native "Uint32x4_getX"; 2092 int get x native "Uint32x4_getX";
2085 int get y native "Uint32x4_getY"; 2093 int get y native "Uint32x4_getY";
2086 int get z native "Uint32x4_getZ"; 2094 int get z native "Uint32x4_getZ";
2087 int get w native "Uint32x4_getW"; 2095 int get w native "Uint32x4_getW";
2088 Uint32x4 withX(int x) native "Uint32x4_setX"; 2096 Uint32x4 withX(int x) native "Uint32x4_setX";
2089 Uint32x4 withY(int y) native "Uint32x4_setY"; 2097 Uint32x4 withY(int y) native "Uint32x4_setY";
2090 Uint32x4 withZ(int z) native "Uint32x4_setZ"; 2098 Uint32x4 withZ(int z) native "Uint32x4_setZ";
2091 Uint32x4 withW(int w) native "Uint32x4_setW"; 2099 Uint32x4 withW(int w) native "Uint32x4_setW";
2092 bool get flagX native "Uint32x4_getFlagX"; 2100 bool get flagX native "Uint32x4_getFlagX";
2093 bool get flagY native "Uint32x4_getFlagY"; 2101 bool get flagY native "Uint32x4_getFlagY";
(...skipping 1036 matching lines...) Expand 10 before | Expand all | Expand 10 after
3130 return value; 3138 return value;
3131 } 3139 }
3132 return object; 3140 return object;
3133 } 3141 }
3134 3142
3135 3143
3136 void _throwRangeError(int index, int length) { 3144 void _throwRangeError(int index, int length) {
3137 String message = "$index must be in the range [0..$length)"; 3145 String message = "$index must be in the range [0..$length)";
3138 throw new RangeError(message); 3146 throw new RangeError(message);
3139 } 3147 }
OLDNEW
« no previous file with comments | « runtime/lib/simd128.cc ('k') | runtime/vm/bootstrap_natives.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698