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

Unified Diff: runtime/vm/intermediate_language.cc

Issue 11783006: Intrinsify Uint8ClampedArray's store and load indexed, inline load indexed. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 12 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
Index: runtime/vm/intermediate_language.cc
===================================================================
--- runtime/vm/intermediate_language.cc (revision 16643)
+++ runtime/vm/intermediate_language.cc (working copy)
@@ -1092,6 +1092,7 @@
case kFloat64ArrayCid :
return Type::Double();
case kUint8ArrayCid:
+ case kUint8ClampedArrayCid:
case kExternalUint8ArrayCid:
return Type::IntType();
default:
@@ -1110,6 +1111,7 @@
case kFloat64ArrayCid :
return kDoubleCid;
case kUint8ArrayCid:
+ case kUint8ClampedArrayCid:
case kExternalUint8ArrayCid:
return kSmiCid;
default:
@@ -1124,6 +1126,7 @@
case kArrayCid:
case kImmutableArrayCid:
case kUint8ArrayCid:
+ case kUint8ClampedArrayCid:
case kExternalUint8ArrayCid:
return kTagged;
case kFloat32ArrayCid :
@@ -2460,8 +2463,9 @@
void LoadIndexedInstr::InferRange() {
switch (class_id()) {
+ case kUint8ArrayCid:
+ case kUint8ClampedArrayCid:
case kExternalUint8ArrayCid:
- case kUint8ArrayCid:
range_ = new Range(RangeBoundary::FromConstant(0),
RangeBoundary::FromConstant(255));
break;
@@ -2699,6 +2703,8 @@
return Array::length_offset();
case kUint8ArrayCid:
return Uint8Array::length_offset();
+ case kUint8ClampedArrayCid:
+ return Uint8ClampedArray::length_offset();
case kExternalUint8ArrayCid:
return ByteArray::length_offset();
default:

Powered by Google App Engine
This is Rietveld 408576698