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

Side by Side Diff: runtime/vm/raw_object.cc

Issue 12907023: Really remove SIMD types from dart:scalarlist. Fixes build. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Really remove SIMD types from dart:scalarlist. Created 7 years, 8 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/vm/raw_object.h ('k') | runtime/vm/raw_object_snapshot.cc » ('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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 #include "vm/raw_object.h" 5 #include "vm/raw_object.h"
6 6
7 #include "vm/class_table.h" 7 #include "vm/class_table.h"
8 #include "vm/freelist.h" 8 #include "vm/freelist.h"
9 #include "vm/isolate.h" 9 #include "vm/isolate.h"
10 #include "vm/object.h" 10 #include "vm/object.h"
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 instance_size = Int64Array::InstanceSize(byte_array_length); 175 instance_size = Int64Array::InstanceSize(byte_array_length);
176 break; 176 break;
177 } 177 }
178 case kUint64ArrayCid: { 178 case kUint64ArrayCid: {
179 const RawUint64Array* raw_byte_array = 179 const RawUint64Array* raw_byte_array =
180 reinterpret_cast<const RawUint64Array*>(this); 180 reinterpret_cast<const RawUint64Array*>(this);
181 intptr_t byte_array_length = Smi::Value(raw_byte_array->ptr()->length_); 181 intptr_t byte_array_length = Smi::Value(raw_byte_array->ptr()->length_);
182 instance_size = Uint64Array::InstanceSize(byte_array_length); 182 instance_size = Uint64Array::InstanceSize(byte_array_length);
183 break; 183 break;
184 } 184 }
185 case kFloat32x4ArrayCid: {
186 const RawFloat32x4Array* raw_byte_array =
187 reinterpret_cast<const RawFloat32x4Array*>(this);
188 intptr_t byte_array_length = Smi::Value(raw_byte_array->ptr()->length_);
189 instance_size = Float32x4Array::InstanceSize(byte_array_length);
190 break;
191 }
192 case kFloat32ArrayCid: { 185 case kFloat32ArrayCid: {
193 const RawFloat32Array* raw_byte_array = 186 const RawFloat32Array* raw_byte_array =
194 reinterpret_cast<const RawFloat32Array*>(this); 187 reinterpret_cast<const RawFloat32Array*>(this);
195 intptr_t byte_array_length = Smi::Value(raw_byte_array->ptr()->length_); 188 intptr_t byte_array_length = Smi::Value(raw_byte_array->ptr()->length_);
196 instance_size = Float32Array::InstanceSize(byte_array_length); 189 instance_size = Float32Array::InstanceSize(byte_array_length);
197 break; 190 break;
198 } 191 }
199 case kFloat64ArrayCid: { 192 case kFloat64ArrayCid: {
200 const RawFloat64Array* raw_byte_array = 193 const RawFloat64Array* raw_byte_array =
201 reinterpret_cast<const RawFloat64Array*>(this); 194 reinterpret_cast<const RawFloat64Array*>(this);
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after
927 920
928 intptr_t RawUint64Array::VisitUint64ArrayPointers( 921 intptr_t RawUint64Array::VisitUint64ArrayPointers(
929 RawUint64Array *raw_obj, ObjectPointerVisitor* visitor) { 922 RawUint64Array *raw_obj, ObjectPointerVisitor* visitor) {
930 // Make sure that we got here with the tagged pointer as this. 923 // Make sure that we got here with the tagged pointer as this.
931 ASSERT(raw_obj->IsHeapObject()); 924 ASSERT(raw_obj->IsHeapObject());
932 intptr_t length = Smi::Value(raw_obj->ptr()->length_); 925 intptr_t length = Smi::Value(raw_obj->ptr()->length_);
933 visitor->VisitPointers(raw_obj->from(), raw_obj->to()); 926 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
934 return Uint64Array::InstanceSize(length); 927 return Uint64Array::InstanceSize(length);
935 } 928 }
936 929
937
938 intptr_t RawFloat32x4Array::VisitFloat32x4ArrayPointers(
939 RawFloat32x4Array *raw_obj, ObjectPointerVisitor* visitor) {
940 // Make sure that we got here with the tagged pointer as this.
941 ASSERT(raw_obj->IsHeapObject());
942 intptr_t length = Smi::Value(raw_obj->ptr()->length_);
943 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
944 return Float32x4Array::InstanceSize(length);
945 }
946
947 intptr_t RawFloat32Array::VisitFloat32ArrayPointers( 930 intptr_t RawFloat32Array::VisitFloat32ArrayPointers(
948 RawFloat32Array *raw_obj, ObjectPointerVisitor* visitor) { 931 RawFloat32Array *raw_obj, ObjectPointerVisitor* visitor) {
949 // Make sure that we got here with the tagged pointer as this. 932 // Make sure that we got here with the tagged pointer as this.
950 ASSERT(raw_obj->IsHeapObject()); 933 ASSERT(raw_obj->IsHeapObject());
951 intptr_t length = Smi::Value(raw_obj->ptr()->length_); 934 intptr_t length = Smi::Value(raw_obj->ptr()->length_);
952 visitor->VisitPointers(raw_obj->from(), raw_obj->to()); 935 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
953 return Float32Array::InstanceSize(length); 936 return Float32Array::InstanceSize(length);
954 } 937 }
955 938
956 939
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
1038 1021
1039 intptr_t RawExternalUint64Array::VisitExternalUint64ArrayPointers( 1022 intptr_t RawExternalUint64Array::VisitExternalUint64ArrayPointers(
1040 RawExternalUint64Array* raw_obj, ObjectPointerVisitor* visitor) { 1023 RawExternalUint64Array* raw_obj, ObjectPointerVisitor* visitor) {
1041 // Make sure that we got here with the tagged pointer as this. 1024 // Make sure that we got here with the tagged pointer as this.
1042 ASSERT(raw_obj->IsHeapObject()); 1025 ASSERT(raw_obj->IsHeapObject());
1043 visitor->VisitPointers(raw_obj->from(), raw_obj->to()); 1026 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
1044 return ExternalUint64Array::InstanceSize(); 1027 return ExternalUint64Array::InstanceSize();
1045 } 1028 }
1046 1029
1047 1030
1048 intptr_t RawExternalFloat32x4Array::VisitExternalFloat32x4ArrayPointers(
1049 RawExternalFloat32x4Array* raw_obj, ObjectPointerVisitor* visitor) {
1050 // Make sure that we got here with the tagged pointer as this.
1051 ASSERT(raw_obj->IsHeapObject());
1052 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
1053 return ExternalFloat32x4Array::InstanceSize();
1054 }
1055
1056
1057 intptr_t RawExternalFloat32Array::VisitExternalFloat32ArrayPointers( 1031 intptr_t RawExternalFloat32Array::VisitExternalFloat32ArrayPointers(
1058 RawExternalFloat32Array* raw_obj, ObjectPointerVisitor* visitor) { 1032 RawExternalFloat32Array* raw_obj, ObjectPointerVisitor* visitor) {
1059 // Make sure that we got here with the tagged pointer as this. 1033 // Make sure that we got here with the tagged pointer as this.
1060 ASSERT(raw_obj->IsHeapObject()); 1034 ASSERT(raw_obj->IsHeapObject());
1061 visitor->VisitPointers(raw_obj->from(), raw_obj->to()); 1035 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
1062 return ExternalFloat32Array::InstanceSize(); 1036 return ExternalFloat32Array::InstanceSize();
1063 } 1037 }
1064 1038
1065 1039
1066 intptr_t RawExternalFloat64Array::VisitExternalFloat64ArrayPointers( 1040 intptr_t RawExternalFloat64Array::VisitExternalFloat64ArrayPointers(
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
1122 1096
1123 intptr_t RawWeakProperty::VisitWeakPropertyPointers( 1097 intptr_t RawWeakProperty::VisitWeakPropertyPointers(
1124 RawWeakProperty* raw_obj, ObjectPointerVisitor* visitor) { 1098 RawWeakProperty* raw_obj, ObjectPointerVisitor* visitor) {
1125 // Make sure that we got here with the tagged pointer as this. 1099 // Make sure that we got here with the tagged pointer as this.
1126 ASSERT(raw_obj->IsHeapObject()); 1100 ASSERT(raw_obj->IsHeapObject());
1127 visitor->VisitPointers(raw_obj->from(), raw_obj->to()); 1101 visitor->VisitPointers(raw_obj->from(), raw_obj->to());
1128 return WeakProperty::InstanceSize(); 1102 return WeakProperty::InstanceSize();
1129 } 1103 }
1130 1104
1131 } // namespace dart 1105 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/raw_object.h ('k') | runtime/vm/raw_object_snapshot.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698