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

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

Issue 1672873003: Bailout if field state changed during background compilation. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Comment Created 4 years, 10 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
« no previous file with comments | « runtime/vm/intermediate_language_x64.cc ('k') | runtime/vm/object.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 #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 475 matching lines...) Expand 10 before | Expand all | Expand 10 after
486 static const LanguageError& branch_offset_error() { 486 static const LanguageError& branch_offset_error() {
487 ASSERT(branch_offset_error_ != NULL); 487 ASSERT(branch_offset_error_ != NULL);
488 return *branch_offset_error_; 488 return *branch_offset_error_;
489 } 489 }
490 490
491 static const LanguageError& speculative_inlining_error() { 491 static const LanguageError& speculative_inlining_error() {
492 ASSERT(speculative_inlining_error_ != NULL); 492 ASSERT(speculative_inlining_error_ != NULL);
493 return *speculative_inlining_error_; 493 return *speculative_inlining_error_;
494 } 494 }
495 495
496 static const LanguageError& background_compilation_error() {
497 ASSERT(background_compilation_error_ != NULL);
498 return *background_compilation_error_;
499 }
500
496 static const Array& vm_isolate_snapshot_object_table() { 501 static const Array& vm_isolate_snapshot_object_table() {
497 ASSERT(vm_isolate_snapshot_object_table_ != NULL); 502 ASSERT(vm_isolate_snapshot_object_table_ != NULL);
498 return *vm_isolate_snapshot_object_table_; 503 return *vm_isolate_snapshot_object_table_;
499 } 504 }
500 static const Type& dynamic_type() { 505 static const Type& dynamic_type() {
501 ASSERT(dynamic_type_ != NULL); 506 ASSERT(dynamic_type_ != NULL);
502 return *dynamic_type_; 507 return *dynamic_type_;
503 } 508 }
504 static const Type& void_type() { 509 static const Type& void_type() {
505 ASSERT(void_type_ != NULL); 510 ASSERT(void_type_ != NULL);
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
821 static Instance* sentinel_; 826 static Instance* sentinel_;
822 static Instance* transition_sentinel_; 827 static Instance* transition_sentinel_;
823 static Instance* unknown_constant_; 828 static Instance* unknown_constant_;
824 static Instance* non_constant_; 829 static Instance* non_constant_;
825 static Bool* bool_true_; 830 static Bool* bool_true_;
826 static Bool* bool_false_; 831 static Bool* bool_false_;
827 static Smi* smi_illegal_cid_; 832 static Smi* smi_illegal_cid_;
828 static LanguageError* snapshot_writer_error_; 833 static LanguageError* snapshot_writer_error_;
829 static LanguageError* branch_offset_error_; 834 static LanguageError* branch_offset_error_;
830 static LanguageError* speculative_inlining_error_; 835 static LanguageError* speculative_inlining_error_;
836 static LanguageError* background_compilation_error_;
831 static Array* vm_isolate_snapshot_object_table_; 837 static Array* vm_isolate_snapshot_object_table_;
832 static Type* dynamic_type_; 838 static Type* dynamic_type_;
833 static Type* void_type_; 839 static Type* void_type_;
834 840
835 friend void ClassTable::Register(const Class& cls); 841 friend void ClassTable::Register(const Class& cls);
836 friend void RawObject::Validate(Isolate* isolate) const; 842 friend void RawObject::Validate(Isolate* isolate) const;
837 friend class Closure; 843 friend class Closure;
838 friend class SnapshotReader; 844 friend class SnapshotReader;
839 friend class OneByteString; 845 friend class OneByteString;
840 friend class TwoByteString; 846 friend class TwoByteString;
(...skipping 1822 matching lines...) Expand 10 before | Expand all | Expand 10 after
2663 // functions. 2669 // functions.
2664 int32_t SourceFingerprint() const; 2670 int32_t SourceFingerprint() const;
2665 2671
2666 // Return false and report an error if the fingerprint does not match. 2672 // Return false and report an error if the fingerprint does not match.
2667 bool CheckSourceFingerprint(const char* prefix, int32_t fp) const; 2673 bool CheckSourceFingerprint(const char* prefix, int32_t fp) const;
2668 2674
2669 // Works with map [deopt-id] -> ICData. 2675 // Works with map [deopt-id] -> ICData.
2670 void SaveICDataMap( 2676 void SaveICDataMap(
2671 const ZoneGrowableArray<const ICData*>& deopt_id_to_ic_data, 2677 const ZoneGrowableArray<const ICData*>& deopt_id_to_ic_data,
2672 const Array& edge_counters_array) const; 2678 const Array& edge_counters_array) const;
2673 // Uses saved ICData to populate the table 'deopt_id_to_ic_data'. Clone 2679 // Uses 'ic_data_array' to populate the table 'deopt_id_to_ic_data'. Clone
2674 // descriptors if 'clone_descriptors' true. 2680 // descriptors if 'clone_descriptors' true.
2675 void RestoreICDataMap( 2681 void RestoreICDataMap(ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data,
2676 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data, 2682 bool clone_descriptors) const;
2677 bool clone_descriptors) const;
2678 2683
2679 RawArray* ic_data_array() const; 2684 RawArray* ic_data_array() const;
2680 void ClearICDataArray() const; 2685 void ClearICDataArray() const;
2681 2686
2682 // Sets deopt reason in all ICData-s with given deopt_id. 2687 // Sets deopt reason in all ICData-s with given deopt_id.
2683 void SetDeoptReasonForAll(intptr_t deopt_id, ICData::DeoptReasonId reason); 2688 void SetDeoptReasonForAll(intptr_t deopt_id, ICData::DeoptReasonId reason);
2684 2689
2685 void set_modifier(RawFunction::AsyncModifier value) const; 2690 void set_modifier(RawFunction::AsyncModifier value) const;
2686 2691
2687 // static: Considered during class-side or top-level resolution rather than 2692 // static: Considered during class-side or top-level resolution rather than
(...skipping 5729 matching lines...) Expand 10 before | Expand all | Expand 10 after
8417 8422
8418 8423
8419 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, 8424 RawObject* MegamorphicCache::GetTargetFunction(const Array& array,
8420 intptr_t index) { 8425 intptr_t index) {
8421 return array.At((index * kEntryLength) + kTargetFunctionIndex); 8426 return array.At((index * kEntryLength) + kTargetFunctionIndex);
8422 } 8427 }
8423 8428
8424 } // namespace dart 8429 } // namespace dart
8425 8430
8426 #endif // VM_OBJECT_H_ 8431 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_x64.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698