| 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 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 1923 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1934 friend class Code; | 1934 friend class Code; |
| 1935 friend class Class; | 1935 friend class Class; |
| 1936 }; | 1936 }; |
| 1937 | 1937 |
| 1938 | 1938 |
| 1939 class LocalVarDescriptors : public Object { | 1939 class LocalVarDescriptors : public Object { |
| 1940 public: | 1940 public: |
| 1941 intptr_t Length() const; | 1941 intptr_t Length() const; |
| 1942 | 1942 |
| 1943 RawString* GetName(intptr_t var_index) const; | 1943 RawString* GetName(intptr_t var_index) const; |
| 1944 void GetScopeInfo(intptr_t var_index, | |
| 1945 intptr_t* scope_id, | |
| 1946 intptr_t* begin_token_pos, | |
| 1947 intptr_t* end_token_pos) const; | |
| 1948 intptr_t GetSlotIndex(intptr_t var_index) const; | |
| 1949 | 1944 |
| 1950 void SetVar(intptr_t var_index, | 1945 void SetVar(intptr_t var_index, |
| 1951 const String& name, | 1946 const String& name, |
| 1952 intptr_t stack_slot, | 1947 RawLocalVarDescriptors::VarInfo* info) const; |
| 1953 intptr_t scope_id, | 1948 |
| 1954 intptr_t begin_pos, | 1949 void GetInfo(intptr_t var_index, RawLocalVarDescriptors::VarInfo* info) const; |
| 1955 intptr_t end_pos) const; | |
| 1956 | 1950 |
| 1957 static intptr_t InstanceSize() { | 1951 static intptr_t InstanceSize() { |
| 1958 ASSERT(sizeof(RawLocalVarDescriptors) == | 1952 ASSERT(sizeof(RawLocalVarDescriptors) == |
| 1959 OFFSET_OF(RawLocalVarDescriptors, data_)); | 1953 OFFSET_OF(RawLocalVarDescriptors, data_)); |
| 1960 return 0; | 1954 return 0; |
| 1961 } | 1955 } |
| 1962 static intptr_t InstanceSize(intptr_t len) { | 1956 static intptr_t InstanceSize(intptr_t len) { |
| 1963 return RoundedAllocationSize( | 1957 return RoundedAllocationSize( |
| 1964 sizeof(RawLocalVarDescriptors) + | 1958 sizeof(RawLocalVarDescriptors) + |
| 1965 (len * sizeof(RawLocalVarDescriptors::VarInfo))); | 1959 (len * sizeof(RawLocalVarDescriptors::VarInfo))); |
| (...skipping 3012 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4978 } | 4972 } |
| 4979 | 4973 |
| 4980 | 4974 |
| 4981 intptr_t Stackmap::SizeInBits() const { | 4975 intptr_t Stackmap::SizeInBits() const { |
| 4982 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); | 4976 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); |
| 4983 } | 4977 } |
| 4984 | 4978 |
| 4985 } // namespace dart | 4979 } // namespace dart |
| 4986 | 4980 |
| 4987 #endif // VM_OBJECT_H_ | 4981 #endif // VM_OBJECT_H_ |
| OLD | NEW |