| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 148 Address pc() const { return *pc_address_; } | 148 Address pc() const { return *pc_address_; } |
| 149 Isolate* isolate() const { return isolate_; } | 149 Isolate* isolate() const { return isolate_; } |
| 150 | 150 |
| 151 #ifdef ENABLE_DEBUGGER_SUPPORT | 151 #ifdef ENABLE_DEBUGGER_SUPPORT |
| 152 // Computes the address in the original code when the code running is | 152 // Computes the address in the original code when the code running is |
| 153 // containing break points (calls to DebugBreakXXX builtins). | 153 // containing break points (calls to DebugBreakXXX builtins). |
| 154 Address OriginalCodeAddress() const; | 154 Address OriginalCodeAddress() const; |
| 155 #endif | 155 #endif |
| 156 | 156 |
| 157 // Set the call-site target. | 157 // Set the call-site target. |
| 158 void set_target(Code* code) { SetTargetAtAddress(address(), code); } | 158 void set_target(Code* code) { |
| 159 SetTargetAtAddress(address(), code); |
| 160 target_set_ = true; |
| 161 } |
| 162 |
| 163 bool is_target_set() { return target_set_; } |
| 159 | 164 |
| 160 #ifdef DEBUG | 165 #ifdef DEBUG |
| 161 char TransitionMarkFromState(IC::State state); | 166 char TransitionMarkFromState(IC::State state); |
| 162 | 167 |
| 163 void TraceIC(const char* type, Handle<Object> name); | 168 void TraceIC(const char* type, Handle<Object> name); |
| 164 #endif | 169 #endif |
| 165 | 170 |
| 166 Failure* TypeError(const char* type, | 171 Failure* TypeError(const char* type, |
| 167 Handle<Object> object, | 172 Handle<Object> object, |
| 168 Handle<Object> key); | 173 Handle<Object> key); |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 228 // to make the code GC safe. This feature is crucial since | 233 // to make the code GC safe. This feature is crucial since |
| 229 // GetProperty and SetProperty are called and they in turn might | 234 // GetProperty and SetProperty are called and they in turn might |
| 230 // invoke the garbage collector. | 235 // invoke the garbage collector. |
| 231 Address* pc_address_; | 236 Address* pc_address_; |
| 232 | 237 |
| 233 Isolate* isolate_; | 238 Isolate* isolate_; |
| 234 | 239 |
| 235 // The original code target that missed. | 240 // The original code target that missed. |
| 236 Handle<Code> target_; | 241 Handle<Code> target_; |
| 237 State state_; | 242 State state_; |
| 243 bool target_set_; |
| 238 | 244 |
| 239 DISALLOW_IMPLICIT_CONSTRUCTORS(IC); | 245 DISALLOW_IMPLICIT_CONSTRUCTORS(IC); |
| 240 }; | 246 }; |
| 241 | 247 |
| 242 | 248 |
| 243 // An IC_Utility encapsulates IC::UtilityId. It exists mainly because you | 249 // An IC_Utility encapsulates IC::UtilityId. It exists mainly because you |
| 244 // cannot make forward declarations to an enum. | 250 // cannot make forward declarations to an enum. |
| 245 class IC_Utility { | 251 class IC_Utility { |
| 246 public: | 252 public: |
| 247 explicit IC_Utility(IC::UtilityId id) | 253 explicit IC_Utility(IC::UtilityId id) |
| (...skipping 634 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 882 DECLARE_RUNTIME_FUNCTION(MaybeObject*, StoreIC_MissFromStubFailure); | 888 DECLARE_RUNTIME_FUNCTION(MaybeObject*, StoreIC_MissFromStubFailure); |
| 883 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ElementsTransitionAndStoreIC_Miss); | 889 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ElementsTransitionAndStoreIC_Miss); |
| 884 DECLARE_RUNTIME_FUNCTION(MaybeObject*, BinaryOpIC_Miss); | 890 DECLARE_RUNTIME_FUNCTION(MaybeObject*, BinaryOpIC_Miss); |
| 885 DECLARE_RUNTIME_FUNCTION(MaybeObject*, CompareNilIC_Miss); | 891 DECLARE_RUNTIME_FUNCTION(MaybeObject*, CompareNilIC_Miss); |
| 886 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ToBooleanIC_Miss); | 892 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ToBooleanIC_Miss); |
| 887 | 893 |
| 888 | 894 |
| 889 } } // namespace v8::internal | 895 } } // namespace v8::internal |
| 890 | 896 |
| 891 #endif // V8_IC_H_ | 897 #endif // V8_IC_H_ |
| OLD | NEW |