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

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

Issue 1343383003: VM: Store edge counters in one per-function array. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 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/isolate.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 2586 matching lines...) Expand 10 before | Expand all | Expand 10 after
2597 2597
2598 // Slow function, use in asserts to track changes in important library 2598 // Slow function, use in asserts to track changes in important library
2599 // functions. 2599 // functions.
2600 int32_t SourceFingerprint() const; 2600 int32_t SourceFingerprint() const;
2601 2601
2602 // Return false and report an error if the fingerprint does not match. 2602 // Return false and report an error if the fingerprint does not match.
2603 bool CheckSourceFingerprint(const char* prefix, int32_t fp) const; 2603 bool CheckSourceFingerprint(const char* prefix, int32_t fp) const;
2604 2604
2605 // Works with map [deopt-id] -> ICData. 2605 // Works with map [deopt-id] -> ICData.
2606 void SaveICDataMap( 2606 void SaveICDataMap(
2607 const ZoneGrowableArray<const ICData*>& deopt_id_to_ic_data) const; 2607 const ZoneGrowableArray<const ICData*>& deopt_id_to_ic_data,
2608 const Array& edge_counters_array) const;
2608 void RestoreICDataMap( 2609 void RestoreICDataMap(
2609 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data) const; 2610 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data) const;
2610 2611
2611 RawArray* ic_data_array() const; 2612 RawArray* ic_data_array() const;
2612 void ClearICDataArray() const; 2613 void ClearICDataArray() const;
2613 2614
2614 // Sets deopt reason in all ICData-s with given deopt_id. 2615 // Sets deopt reason in all ICData-s with given deopt_id.
2615 void SetDeoptReasonForAll(intptr_t deopt_id, ICData::DeoptReasonId reason); 2616 void SetDeoptReasonForAll(intptr_t deopt_id, ICData::DeoptReasonId reason);
2616 2617
2617 static const int kCtorPhaseInit = 1 << 0; 2618 static const int kCtorPhaseInit = 1 << 0;
(...skipping 5504 matching lines...) Expand 10 before | Expand all | Expand 10 after
8122 8123
8123 8124
8124 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, 8125 RawObject* MegamorphicCache::GetTargetFunction(const Array& array,
8125 intptr_t index) { 8126 intptr_t index) {
8126 return array.At((index * kEntryLength) + kTargetFunctionIndex); 8127 return array.At((index * kEntryLength) + kTargetFunctionIndex);
8127 } 8128 }
8128 8129
8129 } // namespace dart 8130 } // namespace dart
8130 8131
8131 #endif // VM_OBJECT_H_ 8132 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « runtime/vm/isolate.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698