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

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

Issue 1830733002: Fix stub frame walking: when materializing the frame content during deoptimization, the stack is no… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Remove change to IsStubFrame; pending investigation. Created 4 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
« no previous file with comments | « no previous file | 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 4307 matching lines...) Expand 10 before | Expand all | Expand 10 after
4318 private: 4318 private:
4319 static void UnpackInto(const Array& table, 4319 static void UnpackInto(const Array& table,
4320 const TypedData& packed, 4320 const TypedData& packed,
4321 GrowableArray<DeoptInstr*>* instructions, 4321 GrowableArray<DeoptInstr*>* instructions,
4322 intptr_t length); 4322 intptr_t length);
4323 }; 4323 };
4324 4324
4325 4325
4326 class Code : public Object { 4326 class Code : public Object {
4327 public: 4327 public:
4328 uword active_entry_point() const { return raw_ptr()->entry_point_; } 4328 RawInstructions* active_instructions() const {
4329 return raw_ptr()->active_instructions_;
4330 }
4329 4331
4330 RawInstructions* instructions() const { return raw_ptr()->instructions_; } 4332 RawInstructions* instructions() const { return raw_ptr()->instructions_; }
4331 4333
4332 static intptr_t saved_instructions_offset() { 4334 static intptr_t saved_instructions_offset() {
4333 return OFFSET_OF(RawCode, instructions_); 4335 return OFFSET_OF(RawCode, instructions_);
4334 } 4336 }
4335 4337
4336 static intptr_t entry_point_offset() { 4338 static intptr_t entry_point_offset() {
4337 return OFFSET_OF(RawCode, entry_point_); 4339 return OFFSET_OF(RawCode, entry_point_);
4338 } 4340 }
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after
4600 bool IsStubCode() const; 4602 bool IsStubCode() const;
4601 bool IsFunctionCode() const; 4603 bool IsFunctionCode() const;
4602 4604
4603 void DisableDartCode() const; 4605 void DisableDartCode() const;
4604 4606
4605 void DisableStubCode() const; 4607 void DisableStubCode() const;
4606 4608
4607 void Enable() const { 4609 void Enable() const {
4608 if (!IsDisabled()) return; 4610 if (!IsDisabled()) return;
4609 ASSERT(Thread::Current()->IsMutatorThread()); 4611 ASSERT(Thread::Current()->IsMutatorThread());
4612 ASSERT(instructions() != active_instructions());
4610 SetActiveInstructions(instructions()); 4613 SetActiveInstructions(instructions());
4611 } 4614 }
4612 4615
4613 bool IsDisabled() const { 4616 bool IsDisabled() const {
4614 return active_entry_point() != EntryPoint(); 4617 return instructions() != active_instructions();
4615 } 4618 }
4616 4619
4617 private: 4620 private:
4618 void set_state_bits(intptr_t bits) const; 4621 void set_state_bits(intptr_t bits) const;
4619 4622
4620 void set_object_pool(RawObjectPool* object_pool) const { 4623 void set_object_pool(RawObjectPool* object_pool) const {
4621 StorePointer(&raw_ptr()->object_pool_, object_pool); 4624 StorePointer(&raw_ptr()->object_pool_, object_pool);
4622 } 4625 }
4623 4626
4624 friend class RawObject; // For RawObject::SizeFromClass(). 4627 friend class RawObject; // For RawObject::SizeFromClass().
(...skipping 3792 matching lines...) Expand 10 before | Expand all | Expand 10 after
8417 8420
8418 8421
8419 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, 8422 RawObject* MegamorphicCache::GetTargetFunction(const Array& array,
8420 intptr_t index) { 8423 intptr_t index) {
8421 return array.At((index * kEntryLength) + kTargetFunctionIndex); 8424 return array.At((index * kEntryLength) + kTargetFunctionIndex);
8422 } 8425 }
8423 8426
8424 } // namespace dart 8427 } // namespace dart
8425 8428
8426 #endif // VM_OBJECT_H_ 8429 #endif // VM_OBJECT_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698