| OLD | NEW |
| 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 RUNTIME_VM_OBJECT_H_ | 5 #ifndef RUNTIME_VM_OBJECT_H_ |
| 6 #define RUNTIME_VM_OBJECT_H_ | 6 #define RUNTIME_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 8435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8446 | 8446 |
| 8447 // Internal stacktrace object used in exceptions for printing stack traces. | 8447 // Internal stacktrace object used in exceptions for printing stack traces. |
| 8448 class StackTrace : public Instance { | 8448 class StackTrace : public Instance { |
| 8449 public: | 8449 public: |
| 8450 static const int kPreallocatedStackdepth = 30; | 8450 static const int kPreallocatedStackdepth = 30; |
| 8451 | 8451 |
| 8452 intptr_t Length() const; | 8452 intptr_t Length() const; |
| 8453 | 8453 |
| 8454 RawFunction* FunctionAtFrame(intptr_t frame_index) const; | 8454 RawFunction* FunctionAtFrame(intptr_t frame_index) const; |
| 8455 | 8455 |
| 8456 RawArray* code_array() const { return raw_ptr()->code_array_; } |
| 8456 RawCode* CodeAtFrame(intptr_t frame_index) const; | 8457 RawCode* CodeAtFrame(intptr_t frame_index) const; |
| 8457 void SetCodeAtFrame(intptr_t frame_index, const Code& code) const; | 8458 void SetCodeAtFrame(intptr_t frame_index, const Code& code) const; |
| 8458 | 8459 |
| 8460 RawArray* pc_offset_array() const { return raw_ptr()->pc_offset_array_; } |
| 8459 RawSmi* PcOffsetAtFrame(intptr_t frame_index) const; | 8461 RawSmi* PcOffsetAtFrame(intptr_t frame_index) const; |
| 8460 void SetPcOffsetAtFrame(intptr_t frame_index, const Smi& pc_offset) const; | 8462 void SetPcOffsetAtFrame(intptr_t frame_index, const Smi& pc_offset) const; |
| 8461 void set_expand_inlined(bool value) const; | 8463 void set_expand_inlined(bool value) const; |
| 8462 | 8464 |
| 8463 static intptr_t InstanceSize() { | 8465 static intptr_t InstanceSize() { |
| 8464 return RoundedAllocationSize(sizeof(RawStackTrace)); | 8466 return RoundedAllocationSize(sizeof(RawStackTrace)); |
| 8465 } | 8467 } |
| 8466 static RawStackTrace* New(const Array& code_array, | 8468 static RawStackTrace* New(const Array& code_array, |
| 8467 const Array& pc_offset_array, | 8469 const Array& pc_offset_array, |
| 8468 Heap::Space space = Heap::kNew); | 8470 Heap::Space space = Heap::kNew); |
| (...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8956 | 8958 |
| 8957 inline void TypeArguments::SetHash(intptr_t value) const { | 8959 inline void TypeArguments::SetHash(intptr_t value) const { |
| 8958 // This is only safe because we create a new Smi, which does not cause | 8960 // This is only safe because we create a new Smi, which does not cause |
| 8959 // heap allocation. | 8961 // heap allocation. |
| 8960 StoreSmi(&raw_ptr()->hash_, Smi::New(value)); | 8962 StoreSmi(&raw_ptr()->hash_, Smi::New(value)); |
| 8961 } | 8963 } |
| 8962 | 8964 |
| 8963 } // namespace dart | 8965 } // namespace dart |
| 8964 | 8966 |
| 8965 #endif // RUNTIME_VM_OBJECT_H_ | 8967 #endif // RUNTIME_VM_OBJECT_H_ |
| OLD | NEW |