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

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

Issue 2357313003: AOT: Add a separate switchable call state for unlinked calls. (Closed)
Patch Set: . Created 4 years, 2 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/code_generator.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 524 matching lines...) Expand 10 before | Expand all | Expand 10 after
535 static RawClass* context_scope_class() { return context_scope_class_; } 535 static RawClass* context_scope_class() { return context_scope_class_; }
536 static RawClass* api_error_class() { return api_error_class_; } 536 static RawClass* api_error_class() { return api_error_class_; }
537 static RawClass* language_error_class() { return language_error_class_; } 537 static RawClass* language_error_class() { return language_error_class_; }
538 static RawClass* unhandled_exception_class() { 538 static RawClass* unhandled_exception_class() {
539 return unhandled_exception_class_; 539 return unhandled_exception_class_;
540 } 540 }
541 static RawClass* unwind_error_class() { return unwind_error_class_; } 541 static RawClass* unwind_error_class() { return unwind_error_class_; }
542 static RawClass* singletargetcache_class() { 542 static RawClass* singletargetcache_class() {
543 return singletargetcache_class_; 543 return singletargetcache_class_;
544 } 544 }
545 static RawClass* unlinkedcall_class() { return unlinkedcall_class_; }
545 static RawClass* icdata_class() { return icdata_class_; } 546 static RawClass* icdata_class() { return icdata_class_; }
546 static RawClass* megamorphic_cache_class() { 547 static RawClass* megamorphic_cache_class() {
547 return megamorphic_cache_class_; 548 return megamorphic_cache_class_;
548 } 549 }
549 static RawClass* subtypetestcache_class() { return subtypetestcache_class_; } 550 static RawClass* subtypetestcache_class() { return subtypetestcache_class_; }
550 551
551 // Initialize the VM isolate. 552 // Initialize the VM isolate.
552 static void InitNull(Isolate* isolate); 553 static void InitNull(Isolate* isolate);
553 static void InitOnce(Isolate* isolate); 554 static void InitOnce(Isolate* isolate);
554 static void FinalizeVMIsolate(Isolate* isolate); 555 static void FinalizeVMIsolate(Isolate* isolate);
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
787 static RawClass* object_pool_class_; // Class of the ObjectPool vm object. 788 static RawClass* object_pool_class_; // Class of the ObjectPool vm object.
788 static RawClass* pc_descriptors_class_; // Class of PcDescriptors vm object. 789 static RawClass* pc_descriptors_class_; // Class of PcDescriptors vm object.
789 static RawClass* code_source_map_class_; // Class of CodeSourceMap vm object. 790 static RawClass* code_source_map_class_; // Class of CodeSourceMap vm object.
790 static RawClass* stackmap_class_; // Class of Stackmap vm object. 791 static RawClass* stackmap_class_; // Class of Stackmap vm object.
791 static RawClass* var_descriptors_class_; // Class of LocalVarDescriptors. 792 static RawClass* var_descriptors_class_; // Class of LocalVarDescriptors.
792 static RawClass* exception_handlers_class_; // Class of ExceptionHandlers. 793 static RawClass* exception_handlers_class_; // Class of ExceptionHandlers.
793 static RawClass* deopt_info_class_; // Class of DeoptInfo. 794 static RawClass* deopt_info_class_; // Class of DeoptInfo.
794 static RawClass* context_class_; // Class of the Context vm object. 795 static RawClass* context_class_; // Class of the Context vm object.
795 static RawClass* context_scope_class_; // Class of ContextScope vm object. 796 static RawClass* context_scope_class_; // Class of ContextScope vm object.
796 static RawClass* singletargetcache_class_; // Class of SingleTargetCache. 797 static RawClass* singletargetcache_class_; // Class of SingleTargetCache.
798 static RawClass* unlinkedcall_class_; // Class of UnlinkedCall.
797 static RawClass* icdata_class_; // Class of ICData. 799 static RawClass* icdata_class_; // Class of ICData.
798 static RawClass* megamorphic_cache_class_; // Class of MegamorphiCache. 800 static RawClass* megamorphic_cache_class_; // Class of MegamorphiCache.
799 static RawClass* subtypetestcache_class_; // Class of SubtypeTestCache. 801 static RawClass* subtypetestcache_class_; // Class of SubtypeTestCache.
800 static RawClass* api_error_class_; // Class of ApiError. 802 static RawClass* api_error_class_; // Class of ApiError.
801 static RawClass* language_error_class_; // Class of LanguageError. 803 static RawClass* language_error_class_; // Class of LanguageError.
802 static RawClass* unhandled_exception_class_; // Class of UnhandledException. 804 static RawClass* unhandled_exception_class_; // Class of UnhandledException.
803 static RawClass* unwind_error_class_; // Class of UnwindError. 805 static RawClass* unwind_error_class_; // Class of UnwindError.
804 806
805 // The static values below are read-only handle pointers for singleton 807 // The static values below are read-only handle pointers for singleton
806 // objects that are shared between the different isolates. 808 // objects that are shared between the different isolates.
(...skipping 1044 matching lines...) Expand 10 before | Expand all | Expand 10 after
1851 } 1853 }
1852 1854
1853 static RawSingleTargetCache* New(); 1855 static RawSingleTargetCache* New();
1854 1856
1855 private: 1857 private:
1856 FINAL_HEAP_OBJECT_IMPLEMENTATION(SingleTargetCache, Object); 1858 FINAL_HEAP_OBJECT_IMPLEMENTATION(SingleTargetCache, Object);
1857 friend class Class; 1859 friend class Class;
1858 }; 1860 };
1859 1861
1860 1862
1863 class UnlinkedCall : public Object {
1864 public:
1865 RawString* target_name() const { return raw_ptr()->target_name_; }
1866 void set_target_name(const String& target_name) const;
1867 RawArray* args_descriptor() const { return raw_ptr()->args_descriptor_; }
1868 void set_args_descriptor(const Array& args_descriptor) const;
1869
1870 static intptr_t InstanceSize() {
1871 return RoundedAllocationSize(sizeof(RawUnlinkedCall));
1872 }
1873
1874 static RawUnlinkedCall* New();
1875
1876 private:
1877 FINAL_HEAP_OBJECT_IMPLEMENTATION(UnlinkedCall, Object);
1878 friend class Class;
1879 };
1880
1881
1861 // Object holding information about an IC: test classes and their 1882 // Object holding information about an IC: test classes and their
1862 // corresponding targets. The owner of the ICData can be either the function 1883 // corresponding targets. The owner of the ICData can be either the function
1863 // or the original ICData object. In case of background compilation we 1884 // or the original ICData object. In case of background compilation we
1864 // copy the ICData in a child object, thus freezing it during background 1885 // copy the ICData in a child object, thus freezing it during background
1865 // compilation. Code may contain only original ICData objects. 1886 // compilation. Code may contain only original ICData objects.
1866 class ICData : public Object { 1887 class ICData : public Object {
1867 public: 1888 public:
1868 RawFunction* Owner() const; 1889 RawFunction* Owner() const;
1869 1890
1870 RawICData* Original() const; 1891 RawICData* Original() const;
(...skipping 7111 matching lines...) Expand 10 before | Expand all | Expand 10 after
8982 9003
8983 inline void TypeArguments::SetHash(intptr_t value) const { 9004 inline void TypeArguments::SetHash(intptr_t value) const {
8984 // This is only safe because we create a new Smi, which does not cause 9005 // This is only safe because we create a new Smi, which does not cause
8985 // heap allocation. 9006 // heap allocation.
8986 StoreSmi(&raw_ptr()->hash_, Smi::New(value)); 9007 StoreSmi(&raw_ptr()->hash_, Smi::New(value));
8987 } 9008 }
8988 9009
8989 } // namespace dart 9010 } // namespace dart
8990 9011
8991 #endif // VM_OBJECT_H_ 9012 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/code_generator.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698