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

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

Issue 12730013: - Use dart:typedata types in the Dart API calls. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 9 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_snapshot.cc ('k') | runtime/vm/snapshot_test.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/snapshot.h" 5 #include "vm/snapshot.h"
6 6
7 #include "platform/assert.h" 7 #include "platform/assert.h"
8 #include "vm/bigint_operations.h" 8 #include "vm/bigint_operations.h"
9 #include "vm/bootstrap.h" 9 #include "vm/bootstrap.h"
10 #include "vm/class_finalizer.h" 10 #include "vm/class_finalizer.h"
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 case clazz::kClassId: { \ 311 case clazz::kClassId: { \
312 obj_ = clazz::ReadFrom(this, object_id, tags, kind_); \ 312 obj_ = clazz::ReadFrom(this, object_id, tags, kind_); \
313 break; \ 313 break; \
314 } 314 }
315 CLASS_LIST_NO_OBJECT(SNAPSHOT_READ) 315 CLASS_LIST_NO_OBJECT(SNAPSHOT_READ)
316 #undef SNAPSHOT_READ 316 #undef SNAPSHOT_READ
317 #define SNAPSHOT_READ(clazz) \ 317 #define SNAPSHOT_READ(clazz) \
318 case kTypedData##clazz##Cid: { \ 318 case kTypedData##clazz##Cid: { \
319 obj_ = TypedData::ReadFrom(this, object_id, tags, kind_); \ 319 obj_ = TypedData::ReadFrom(this, object_id, tags, kind_); \
320 break; \ 320 break; \
321 } \
322 case kExternalTypedData##clazz##Cid: { \
323 obj_ = ExternalTypedData::ReadFrom(this, object_id, tags, kind_); \
324 break; \
321 } 325 }
322 CLASS_LIST_TYPED_DATA(SNAPSHOT_READ) 326 CLASS_LIST_TYPED_DATA(SNAPSHOT_READ)
323 #undef SNAPSHOT_READ 327 #undef SNAPSHOT_READ
324 default: UNREACHABLE(); break; 328 default: UNREACHABLE(); break;
325 } 329 }
326 if (kind_ == Snapshot::kFull) { 330 if (kind_ == Snapshot::kFull) {
327 obj_.SetCreatedFromSnapshot(); 331 obj_.SetCreatedFromSnapshot();
328 } 332 }
329 return obj_.raw(); 333 return obj_.raw();
330 } 334 }
(...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after
790 case clazz::kClassId: { \ 794 case clazz::kClassId: { \
791 obj_ = clazz::ReadFrom(this, object_id, tags, kind_); \ 795 obj_ = clazz::ReadFrom(this, object_id, tags, kind_); \
792 break; \ 796 break; \
793 } 797 }
794 CLASS_LIST_NO_OBJECT(SNAPSHOT_READ) 798 CLASS_LIST_NO_OBJECT(SNAPSHOT_READ)
795 #undef SNAPSHOT_READ 799 #undef SNAPSHOT_READ
796 #define SNAPSHOT_READ(clazz) \ 800 #define SNAPSHOT_READ(clazz) \
797 case kTypedData##clazz##Cid: { \ 801 case kTypedData##clazz##Cid: { \
798 obj_ = TypedData::ReadFrom(this, object_id, tags, kind_); \ 802 obj_ = TypedData::ReadFrom(this, object_id, tags, kind_); \
799 break; \ 803 break; \
804 } \
805 case kExternalTypedData##clazz##Cid: { \
806 obj_ = ExternalTypedData::ReadFrom(this, object_id, tags, kind_); \
807 break; \
800 } 808 }
801 CLASS_LIST_TYPED_DATA(SNAPSHOT_READ) 809 CLASS_LIST_TYPED_DATA(SNAPSHOT_READ)
802 #undef SNAPSHOT_READ 810 #undef SNAPSHOT_READ
803 default: UNREACHABLE(); break; 811 default: UNREACHABLE(); break;
804 } 812 }
805 if (kind_ == Snapshot::kFull) { 813 if (kind_ == Snapshot::kFull) {
806 obj_.SetCreatedFromSnapshot(); 814 obj_.SetCreatedFromSnapshot();
807 } 815 }
808 return obj_.raw(); 816 return obj_.raw();
809 } 817 }
(...skipping 591 matching lines...) Expand 10 before | Expand all | Expand 10 after
1401 UnmarkAll(); 1409 UnmarkAll();
1402 isolate->set_long_jump_base(base); 1410 isolate->set_long_jump_base(base);
1403 } else { 1411 } else {
1404 isolate->set_long_jump_base(base); 1412 isolate->set_long_jump_base(base);
1405 ThrowException(exception_type(), exception_msg()); 1413 ThrowException(exception_type(), exception_msg());
1406 } 1414 }
1407 } 1415 }
1408 1416
1409 1417
1410 } // namespace dart 1418 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/raw_object_snapshot.cc ('k') | runtime/vm/snapshot_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698