Index: runtime/vm/raw_object.h |
diff --git a/runtime/vm/raw_object.h b/runtime/vm/raw_object.h |
index bf37591c8ae8950a7c05d519ecbef375bddb72da..376e2f1342b3e6a557614145d4c6ccec024d21f0 100644 |
--- a/runtime/vm/raw_object.h |
+++ b/runtime/vm/raw_object.h |
@@ -571,6 +571,7 @@ class RawObject { |
friend class MarkingVisitor; |
friend class Object; |
friend class OneByteString; // StoreSmi |
+ friend class RawCode; |
friend class RawExternalTypedData; |
friend class RawInstructions; |
friend class RawInstance; |
@@ -585,6 +586,7 @@ class RawObject { |
friend class TypedDataView; |
friend class WeakProperty; // StorePointer |
friend class Instance; // StorePointer |
+ friend class StackFrame; // GetCodeObject assertion. |
DISALLOW_ALLOCATION(); |
DISALLOW_IMPLICIT_CONSTRUCTORS(RawObject); |
@@ -761,7 +763,7 @@ class RawFunction : public RawObject { |
RawObject** to_no_code() { |
return reinterpret_cast<RawObject**>(&ptr()->ic_data_array_); |
} |
- RawInstructions* instructions_; // Instructions of currently active code. |
+ RawCode* code_; // Currently active code. |
RawCode* unoptimized_code_; // Unoptimized code, keep it after optimization. |
RawObject** to() { |
return reinterpret_cast<RawObject**>(&ptr()->unoptimized_code_); |
@@ -977,6 +979,7 @@ class RawCode : public RawObject { |
return reinterpret_cast<RawObject**>(&ptr()->instructions_); |
} |
RawInstructions* instructions_; |
+ RawObjectPool* object_pool_; |
// If owner_ is Function::null() the owner is a regular stub. |
// If owner_ is a Class the owner is the allocation stub for that class. |
// Else, owner_ is a regular Dart Function. |
@@ -1014,6 +1017,8 @@ class RawCode : public RawObject { |
int32_t* data() { OPEN_ARRAY_START(int32_t, int32_t); } |
const int32_t* data() const { OPEN_ARRAY_START(int32_t, int32_t); } |
+ static bool ContainsPC(RawObject* raw_obj, uword pc); |
+ |
friend class Function; |
friend class MarkingVisitor; |
friend class StackFrame; |
@@ -1044,14 +1049,6 @@ class RawObjectPool : public RawObject { |
class RawInstructions : public RawObject { |
RAW_HEAP_OBJECT_IMPLEMENTATION(Instructions); |
- RawObject** from() { |
- return reinterpret_cast<RawObject**>(&ptr()->code_); |
- } |
- RawCode* code_; |
- RawObjectPool* object_pool_; |
- RawObject** to() { |
- return reinterpret_cast<RawObject**>(&ptr()->object_pool_); |
- } |
int32_t size_; |
// Variable length data follows here. |