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

Unified Diff: runtime/vm/object.cc

Issue 1961393002: VM: Optimized code for all of [External]{One|Two}ByteString::codeUnitAt. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: addressed comment Created 4 years, 7 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 | « runtime/vm/method_recognizer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index 29c473933d8d086dfeba67be46614f7850eae603..266b35a893fad456cbb4aebd8e43295f2ae51c9d 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -15531,7 +15531,8 @@ intptr_t Instance::ElementSizeFor(intptr_t cid) {
intptr_t Instance::DataOffsetFor(intptr_t cid) {
- if (RawObject::IsExternalTypedDataClassId(cid)) {
+ if (RawObject::IsExternalTypedDataClassId(cid) ||
+ RawObject::IsExternalStringClassId(cid)) {
// Elements start at offset 0 of the external data.
return 0;
}
« no previous file with comments | « runtime/vm/method_recognizer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698