OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 // Classes that describe assembly patterns as used by inline caches. | 4 // Classes that describe assembly patterns as used by inline caches. |
5 | 5 |
6 #ifndef VM_INSTRUCTIONS_MIPS_H_ | 6 #ifndef VM_INSTRUCTIONS_MIPS_H_ |
7 #define VM_INSTRUCTIONS_MIPS_H_ | 7 #define VM_INSTRUCTIONS_MIPS_H_ |
8 | 8 |
9 #ifndef VM_INSTRUCTIONS_H_ | 9 #ifndef VM_INSTRUCTIONS_H_ |
10 #error Do not include instructions_mips.h directly; use instructions.h instead. | 10 #error Do not include instructions_mips.h directly; use instructions.h instead. |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 Register* reg, | 45 Register* reg, |
46 intptr_t* index); | 46 intptr_t* index); |
47 }; | 47 }; |
48 | 48 |
49 | 49 |
50 class CallPattern : public ValueObject { | 50 class CallPattern : public ValueObject { |
51 public: | 51 public: |
52 CallPattern(uword pc, const Code& code); | 52 CallPattern(uword pc, const Code& code); |
53 | 53 |
54 RawICData* IcData(); | 54 RawICData* IcData(); |
55 RawArray* ClosureArgumentsDescriptor(); | |
56 | 55 |
57 uword TargetAddress() const; | 56 uword TargetAddress() const; |
58 void SetTargetAddress(uword target_address) const; | 57 void SetTargetAddress(uword target_address) const; |
59 | 58 |
60 // This constant length is only valid for inserted call patterns used for | 59 // This constant length is only valid for inserted call patterns used for |
61 // lazy deoptimization. Regular call pattern may vary in length. | 60 // lazy deoptimization. Regular call pattern may vary in length. |
62 static const int kFixedLengthInBytes = 4 * Instr::kInstrSize; | 61 static const int kFixedLengthInBytes = 4 * Instr::kInstrSize; |
63 | 62 |
64 static void InsertAt(uword pc, uword target_address); | 63 static void InsertAt(uword pc, uword target_address); |
65 | 64 |
66 private: | 65 private: |
67 const ObjectPool& object_pool_; | 66 const ObjectPool& object_pool_; |
68 | 67 |
69 uword end_; | 68 uword end_; |
70 uword args_desc_load_end_; | |
71 uword ic_data_load_end_; | 69 uword ic_data_load_end_; |
72 | 70 |
73 intptr_t target_address_pool_index_; | 71 intptr_t target_address_pool_index_; |
74 Array& args_desc_; | |
75 ICData& ic_data_; | 72 ICData& ic_data_; |
76 | 73 |
77 DISALLOW_COPY_AND_ASSIGN(CallPattern); | 74 DISALLOW_COPY_AND_ASSIGN(CallPattern); |
78 }; | 75 }; |
79 | 76 |
80 | 77 |
81 class JumpPattern : public ValueObject { | 78 class JumpPattern : public ValueObject { |
82 public: | 79 public: |
83 JumpPattern(uword pc, const Code& code); | 80 JumpPattern(uword pc, const Code& code); |
84 | 81 |
(...skipping 28 matching lines...) Expand all Loading... |
113 | 110 |
114 bool IsValid() const; | 111 bool IsValid() const; |
115 | 112 |
116 private: | 113 private: |
117 const uword pc_; | 114 const uword pc_; |
118 }; | 115 }; |
119 | 116 |
120 } // namespace dart | 117 } // namespace dart |
121 | 118 |
122 #endif // VM_INSTRUCTIONS_MIPS_H_ | 119 #endif // VM_INSTRUCTIONS_MIPS_H_ |
OLD | NEW |