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

Side by Side Diff: runtime/vm/object.h

Issue 1336763002: Last snapshot bits to get working precompiled hello_world on x64. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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
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 #ifndef VM_OBJECT_H_ 5 #ifndef VM_OBJECT_H_
6 #define VM_OBJECT_H_ 6 #define VM_OBJECT_H_
7 7
8 #include "include/dart_api.h" 8 #include "include/dart_api.h"
9 #include "platform/assert.h" 9 #include "platform/assert.h"
10 #include "platform/utils.h" 10 #include "platform/utils.h"
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 ASSERT(vm_isolate_snapshot_object_table_ != NULL); 487 ASSERT(vm_isolate_snapshot_object_table_ != NULL);
488 return *vm_isolate_snapshot_object_table_; 488 return *vm_isolate_snapshot_object_table_;
489 } 489 }
490 static void InitVmIsolateSnapshotObjectTable(intptr_t len); 490 static void InitVmIsolateSnapshotObjectTable(intptr_t len);
491 static const uint8_t* instructions_snapshot_buffer() { 491 static const uint8_t* instructions_snapshot_buffer() {
492 return instructions_snapshot_buffer_; 492 return instructions_snapshot_buffer_;
493 } 493 }
494 static void set_instructions_snapshot_buffer(const uint8_t* buffer) { 494 static void set_instructions_snapshot_buffer(const uint8_t* buffer) {
495 instructions_snapshot_buffer_ = buffer; 495 instructions_snapshot_buffer_ = buffer;
496 } 496 }
497 static bool IsRunningPrecompiledCode() {
498 return instructions_snapshot_buffer != NULL;
siva 2015/09/15 23:22:01 instructions_snapshot_buffer_
rmacnak 2015/09/16 01:34:44 Done.
499 }
siva 2015/09/15 23:22:01 We should move instructions_snapshot_buffer_ field
497 500
498 static RawClass* class_class() { return class_class_; } 501 static RawClass* class_class() { return class_class_; }
499 static RawClass* dynamic_class() { return dynamic_class_; } 502 static RawClass* dynamic_class() { return dynamic_class_; }
500 static RawClass* void_class() { return void_class_; } 503 static RawClass* void_class() { return void_class_; }
501 static RawType* dynamic_type() { return dynamic_type_; } 504 static RawType* dynamic_type() { return dynamic_type_; }
502 static RawType* void_type() { return void_type_; } 505 static RawType* void_type() { return void_type_; }
503 static RawClass* unresolved_class_class() { return unresolved_class_class_; } 506 static RawClass* unresolved_class_class() { return unresolved_class_class_; }
504 static RawClass* type_arguments_class() { return type_arguments_class_; } 507 static RawClass* type_arguments_class() { return type_arguments_class_; }
505 static RawClass* patch_class_class() { return patch_class_class_; } 508 static RawClass* patch_class_class() { return patch_class_class_; }
506 static RawClass* function_class() { return function_class_; } 509 static RawClass* function_class() { return function_class_; }
(...skipping 3258 matching lines...) Expand 10 before | Expand all | Expand 10 after
3765 3768
3766 // New is a private method as RawInstruction and RawCode objects should 3769 // New is a private method as RawInstruction and RawCode objects should
3767 // only be created using the Code::FinalizeCode method. This method creates 3770 // only be created using the Code::FinalizeCode method. This method creates
3768 // the RawInstruction and RawCode objects, sets up the pointer offsets 3771 // the RawInstruction and RawCode objects, sets up the pointer offsets
3769 // and links the two in a GC safe manner. 3772 // and links the two in a GC safe manner.
3770 static RawInstructions* New(intptr_t size); 3773 static RawInstructions* New(intptr_t size);
3771 3774
3772 FINAL_HEAP_OBJECT_IMPLEMENTATION(Instructions, Object); 3775 FINAL_HEAP_OBJECT_IMPLEMENTATION(Instructions, Object);
3773 friend class Class; 3776 friend class Class;
3774 friend class Code; 3777 friend class Code;
3778 friend class InstructionsWriter;
3775 }; 3779 };
3776 3780
3777 3781
3778 class LocalVarDescriptors : public Object { 3782 class LocalVarDescriptors : public Object {
3779 public: 3783 public:
3780 intptr_t Length() const; 3784 intptr_t Length() const;
3781 3785
3782 RawString* GetName(intptr_t var_index) const; 3786 RawString* GetName(intptr_t var_index) const;
3783 3787
3784 void SetVar(intptr_t var_index, 3788 void SetVar(intptr_t var_index,
(...skipping 4344 matching lines...) Expand 10 before | Expand all | Expand 10 after
8129 8133
8130 8134
8131 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, 8135 RawObject* MegamorphicCache::GetTargetFunction(const Array& array,
8132 intptr_t index) { 8136 intptr_t index) {
8133 return array.At((index * kEntryLength) + kTargetFunctionIndex); 8137 return array.At((index * kEntryLength) + kTargetFunctionIndex);
8134 } 8138 }
8135 8139
8136 } // namespace dart 8140 } // namespace dart
8137 8141
8138 #endif // VM_OBJECT_H_ 8142 #endif // VM_OBJECT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698