| 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 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 | 91 |
| 92 // Construct the IC structure with the given number of extra | 92 // Construct the IC structure with the given number of extra |
| 93 // JavaScript frames on the stack. | 93 // JavaScript frames on the stack. |
| 94 IC(FrameDepth depth, Isolate* isolate); | 94 IC(FrameDepth depth, Isolate* isolate); |
| 95 virtual ~IC() {} | 95 virtual ~IC() {} |
| 96 | 96 |
| 97 // Get the call-site target; used for determining the state. | 97 // Get the call-site target; used for determining the state. |
| 98 Handle<Code> target() const { return target_; } | 98 Handle<Code> target() const { return target_; } |
| 99 Code* raw_target() const { return GetTargetAtAddress(address()); } | 99 Code* raw_target() const { return GetTargetAtAddress(address()); } |
| 100 | 100 |
| 101 State state() const { return state_; } |
| 101 inline Address address() const; | 102 inline Address address() const; |
| 102 | 103 |
| 103 // Compute the current IC state based on the target stub, receiver and name. | 104 // Compute the current IC state based on the target stub, receiver and name. |
| 104 static State StateFrom(Code* target, Object* receiver, Object* name); | 105 void UpdateState(Object* receiver, Object* name); |
| 106 void MarkMonomorphicPrototypeFailure() { |
| 107 state_ = MONOMORPHIC_PROTOTYPE_FAILURE; |
| 108 } |
| 105 | 109 |
| 106 // Clear the inline cache to initial state. | 110 // Clear the inline cache to initial state. |
| 107 static void Clear(Isolate* isolate, Address address); | 111 static void Clear(Isolate* isolate, Address address); |
| 108 | 112 |
| 109 // Computes the reloc info for this IC. This is a fairly expensive | 113 // Computes the reloc info for this IC. This is a fairly expensive |
| 110 // operation as it has to search through the heap to find the code | 114 // operation as it has to search through the heap to find the code |
| 111 // object that contains this IC site. | 115 // object that contains this IC site. |
| 112 RelocInfo::Mode ComputeMode(); | 116 RelocInfo::Mode ComputeMode(); |
| 113 | 117 |
| 114 // Returns if this IC is for contextual (no explicit receiver) | 118 // Returns if this IC is for contextual (no explicit receiver) |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 #endif | 157 #endif |
| 154 | 158 |
| 155 // Set the call-site target. | 159 // Set the call-site target. |
| 156 void set_target(Code* code) { SetTargetAtAddress(address(), code); } | 160 void set_target(Code* code) { SetTargetAtAddress(address(), code); } |
| 157 | 161 |
| 158 #ifdef DEBUG | 162 #ifdef DEBUG |
| 159 char TransitionMarkFromState(IC::State state); | 163 char TransitionMarkFromState(IC::State state); |
| 160 | 164 |
| 161 void TraceIC(const char* type, | 165 void TraceIC(const char* type, |
| 162 Handle<Object> name, | 166 Handle<Object> name, |
| 163 State old_state, | |
| 164 Code* new_target); | 167 Code* new_target); |
| 165 #endif | 168 #endif |
| 166 | 169 |
| 167 Failure* TypeError(const char* type, | 170 Failure* TypeError(const char* type, |
| 168 Handle<Object> object, | 171 Handle<Object> object, |
| 169 Handle<Object> key); | 172 Handle<Object> key); |
| 170 Failure* ReferenceError(const char* type, Handle<String> name); | 173 Failure* ReferenceError(const char* type, Handle<String> name); |
| 171 | 174 |
| 172 // Access the target code for the given IC address. | 175 // Access the target code for the given IC address. |
| 173 static inline Code* GetTargetAtAddress(Address address); | 176 static inline Code* GetTargetAtAddress(Address address); |
| 174 static inline void SetTargetAtAddress(Address address, Code* target); | 177 static inline void SetTargetAtAddress(Address address, Code* target); |
| 175 static void PostPatching(Address address, Code* target, Code* old_target); | 178 static void PostPatching(Address address, Code* target, Code* old_target); |
| 176 | 179 |
| 177 void UpdateMonomorphicIC(Handle<HeapObject> receiver, | 180 void UpdateMonomorphicIC(Handle<HeapObject> receiver, |
| 178 Handle<Code> handler, | 181 Handle<Code> handler, |
| 179 Handle<String> name); | 182 Handle<String> name); |
| 180 | 183 |
| 181 bool UpdatePolymorphicIC(State state, | 184 bool UpdatePolymorphicIC(Handle<HeapObject> receiver, |
| 182 Handle<HeapObject> receiver, | |
| 183 Handle<String> name, | 185 Handle<String> name, |
| 184 Handle<Code> code); | 186 Handle<Code> code); |
| 185 | 187 |
| 186 void CopyICToMegamorphicCache(Handle<String> name); | 188 void CopyICToMegamorphicCache(Handle<String> name); |
| 187 bool IsTransitionedMapOfMonomorphicTarget(Map* receiver_map); | 189 bool IsTransitionedMapOfMonomorphicTarget(Map* receiver_map); |
| 188 void PatchCache(State state, | 190 void PatchCache(Handle<HeapObject> receiver, |
| 189 Handle<HeapObject> receiver, | |
| 190 Handle<String> name, | 191 Handle<String> name, |
| 191 Handle<Code> code); | 192 Handle<Code> code); |
| 192 virtual void UpdateMegamorphicCache(Map* map, Name* name, Code* code); | 193 virtual void UpdateMegamorphicCache(Map* map, Name* name, Code* code); |
| 193 virtual Handle<Code> megamorphic_stub() { | 194 virtual Handle<Code> megamorphic_stub() { |
| 194 UNREACHABLE(); | 195 UNREACHABLE(); |
| 195 return Handle<Code>::null(); | 196 return Handle<Code>::null(); |
| 196 } | 197 } |
| 197 virtual Handle<Code> generic_stub() const { | 198 virtual Handle<Code> generic_stub() const { |
| 198 UNREACHABLE(); | 199 UNREACHABLE(); |
| 199 return Handle<Code>::null(); | 200 return Handle<Code>::null(); |
| 200 } | 201 } |
| 201 virtual StrictModeFlag strict_mode() const { return kNonStrictMode; } | 202 virtual StrictModeFlag strict_mode() const { return kNonStrictMode; } |
| 202 | 203 |
| 203 private: | 204 private: |
| 204 // Frame pointer for the frame that uses (calls) the IC. | 205 // Frame pointer for the frame that uses (calls) the IC. |
| 205 Address fp_; | 206 Address fp_; |
| 206 | 207 |
| 207 // All access to the program counter of an IC structure is indirect | 208 // All access to the program counter of an IC structure is indirect |
| 208 // to make the code GC safe. This feature is crucial since | 209 // to make the code GC safe. This feature is crucial since |
| 209 // GetProperty and SetProperty are called and they in turn might | 210 // GetProperty and SetProperty are called and they in turn might |
| 210 // invoke the garbage collector. | 211 // invoke the garbage collector. |
| 211 Address* pc_address_; | 212 Address* pc_address_; |
| 212 | 213 |
| 213 Isolate* isolate_; | 214 Isolate* isolate_; |
| 214 | 215 |
| 215 // The original code target that missed. | 216 // The original code target that missed. |
| 216 Handle<Code> target_; | 217 Handle<Code> target_; |
| 218 State state_; |
| 217 | 219 |
| 218 DISALLOW_IMPLICIT_CONSTRUCTORS(IC); | 220 DISALLOW_IMPLICIT_CONSTRUCTORS(IC); |
| 219 }; | 221 }; |
| 220 | 222 |
| 221 | 223 |
| 222 // An IC_Utility encapsulates IC::UtilityId. It exists mainly because you | 224 // An IC_Utility encapsulates IC::UtilityId. It exists mainly because you |
| 223 // cannot make forward declarations to an enum. | 225 // cannot make forward declarations to an enum. |
| 224 class IC_Utility { | 226 class IC_Utility { |
| 225 public: | 227 public: |
| 226 explicit IC_Utility(IC::UtilityId id) | 228 explicit IC_Utility(IC::UtilityId id) |
| 227 : address_(IC::AddressFromUtilityId(id)), id_(id) {} | 229 : address_(IC::AddressFromUtilityId(id)), id_(id) {} |
| 228 | 230 |
| 229 Address address() const { return address_; } | 231 Address address() const { return address_; } |
| 230 | 232 |
| 231 IC::UtilityId id() const { return id_; } | 233 IC::UtilityId id() const { return id_; } |
| 232 private: | 234 private: |
| 233 Address address_; | 235 Address address_; |
| 234 IC::UtilityId id_; | 236 IC::UtilityId id_; |
| 235 }; | 237 }; |
| 236 | 238 |
| 237 | 239 |
| 238 class CallICBase: public IC { | 240 class CallICBase: public IC { |
| 239 public: | 241 public: |
| 240 class Contextual: public BitField<bool, 0, 1> {}; | 242 class Contextual: public BitField<bool, 0, 1> {}; |
| 241 class StringStubState: public BitField<StringStubFeedback, 1, 1> {}; | 243 class StringStubState: public BitField<StringStubFeedback, 1, 1> {}; |
| 242 | 244 |
| 243 // Returns a JSFunction or a Failure. | 245 // Returns a JSFunction or a Failure. |
| 244 MUST_USE_RESULT MaybeObject* LoadFunction(State state, | 246 MUST_USE_RESULT MaybeObject* LoadFunction(Code::ExtraICState extra_ic_state, |
| 245 Code::ExtraICState extra_ic_state, | |
| 246 Handle<Object> object, | 247 Handle<Object> object, |
| 247 Handle<String> name); | 248 Handle<String> name); |
| 248 | 249 |
| 249 protected: | 250 protected: |
| 250 CallICBase(Code::Kind kind, Isolate* isolate) | 251 CallICBase(Code::Kind kind, Isolate* isolate) |
| 251 : IC(EXTRA_CALL_FRAME, isolate), kind_(kind) {} | 252 : IC(EXTRA_CALL_FRAME, isolate), kind_(kind) {} |
| 252 | 253 |
| 253 bool TryUpdateExtraICState(LookupResult* lookup, | 254 bool TryUpdateExtraICState(LookupResult* lookup, |
| 254 Handle<Object> object, | 255 Handle<Object> object, |
| 255 Code::ExtraICState* extra_ic_state); | 256 Code::ExtraICState* extra_ic_state); |
| 256 | 257 |
| 257 // Compute a monomorphic stub if possible, otherwise return a null handle. | 258 // Compute a monomorphic stub if possible, otherwise return a null handle. |
| 258 Handle<Code> ComputeMonomorphicStub(LookupResult* lookup, | 259 Handle<Code> ComputeMonomorphicStub(LookupResult* lookup, |
| 259 State state, | |
| 260 Code::ExtraICState extra_state, | 260 Code::ExtraICState extra_state, |
| 261 Handle<Object> object, | 261 Handle<Object> object, |
| 262 Handle<String> name); | 262 Handle<String> name); |
| 263 | 263 |
| 264 // Update the inline cache and the global stub cache based on the lookup | 264 // Update the inline cache and the global stub cache based on the lookup |
| 265 // result. | 265 // result. |
| 266 void UpdateCaches(LookupResult* lookup, | 266 void UpdateCaches(LookupResult* lookup, |
| 267 State state, | |
| 268 Code::ExtraICState extra_ic_state, | 267 Code::ExtraICState extra_ic_state, |
| 269 Handle<Object> object, | 268 Handle<Object> object, |
| 270 Handle<String> name); | 269 Handle<String> name); |
| 271 | 270 |
| 272 // Returns a JSFunction if the object can be called as a function, and | 271 // Returns a JSFunction if the object can be called as a function, and |
| 273 // patches the stack to be ready for the call. Otherwise, it returns the | 272 // patches the stack to be ready for the call. Otherwise, it returns the |
| 274 // undefined value. | 273 // undefined value. |
| 275 Handle<Object> TryCallAsFunction(Handle<Object> object); | 274 Handle<Object> TryCallAsFunction(Handle<Object> object); |
| 276 | 275 |
| 277 void ReceiverToObjectIfRequired(Handle<Object> callee, Handle<Object> object); | 276 void ReceiverToObjectIfRequired(Handle<Object> callee, Handle<Object> object); |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 328 }; | 327 }; |
| 329 | 328 |
| 330 | 329 |
| 331 class KeyedCallIC: public CallICBase { | 330 class KeyedCallIC: public CallICBase { |
| 332 public: | 331 public: |
| 333 explicit KeyedCallIC(Isolate* isolate) | 332 explicit KeyedCallIC(Isolate* isolate) |
| 334 : CallICBase(Code::KEYED_CALL_IC, isolate) { | 333 : CallICBase(Code::KEYED_CALL_IC, isolate) { |
| 335 ASSERT(target()->is_keyed_call_stub()); | 334 ASSERT(target()->is_keyed_call_stub()); |
| 336 } | 335 } |
| 337 | 336 |
| 338 MUST_USE_RESULT MaybeObject* LoadFunction(State state, | 337 MUST_USE_RESULT MaybeObject* LoadFunction(Handle<Object> object, |
| 339 Handle<Object> object, | |
| 340 Handle<Object> key); | 338 Handle<Object> key); |
| 341 | 339 |
| 342 // Code generator routines. | 340 // Code generator routines. |
| 343 static void GenerateInitialize(MacroAssembler* masm, int argc) { | 341 static void GenerateInitialize(MacroAssembler* masm, int argc) { |
| 344 GenerateMiss(masm, argc); | 342 GenerateMiss(masm, argc); |
| 345 } | 343 } |
| 346 | 344 |
| 347 static void GenerateMiss(MacroAssembler* masm, int argc) { | 345 static void GenerateMiss(MacroAssembler* masm, int argc) { |
| 348 CallICBase::GenerateMiss(masm, argc, IC::kKeyedCallIC_Miss, | 346 CallICBase::GenerateMiss(masm, argc, IC::kKeyedCallIC_Miss, |
| 349 Code::kNoExtraICState); | 347 Code::kNoExtraICState); |
| (...skipping 14 matching lines...) Expand all Loading... |
| 364 // Code generator routines. | 362 // Code generator routines. |
| 365 static void GenerateInitialize(MacroAssembler* masm) { GenerateMiss(masm); } | 363 static void GenerateInitialize(MacroAssembler* masm) { GenerateMiss(masm); } |
| 366 static void GeneratePreMonomorphic(MacroAssembler* masm) { | 364 static void GeneratePreMonomorphic(MacroAssembler* masm) { |
| 367 GenerateMiss(masm); | 365 GenerateMiss(masm); |
| 368 } | 366 } |
| 369 static void GenerateMiss(MacroAssembler* masm); | 367 static void GenerateMiss(MacroAssembler* masm); |
| 370 static void GenerateMegamorphic(MacroAssembler* masm); | 368 static void GenerateMegamorphic(MacroAssembler* masm); |
| 371 static void GenerateNormal(MacroAssembler* masm); | 369 static void GenerateNormal(MacroAssembler* masm); |
| 372 static void GenerateRuntimeGetProperty(MacroAssembler* masm); | 370 static void GenerateRuntimeGetProperty(MacroAssembler* masm); |
| 373 | 371 |
| 374 MUST_USE_RESULT MaybeObject* Load(State state, | 372 MUST_USE_RESULT MaybeObject* Load(Handle<Object> object, |
| 375 Handle<Object> object, | |
| 376 Handle<String> name); | 373 Handle<String> name); |
| 377 | 374 |
| 378 protected: | 375 protected: |
| 379 virtual Code::Kind kind() const { return Code::LOAD_IC; } | 376 virtual Code::Kind kind() const { return Code::LOAD_IC; } |
| 380 | 377 |
| 381 virtual Handle<Code> slow_stub() const { | 378 virtual Handle<Code> slow_stub() const { |
| 382 return isolate()->builtins()->LoadIC_Slow(); | 379 return isolate()->builtins()->LoadIC_Slow(); |
| 383 } | 380 } |
| 384 | 381 |
| 385 virtual Handle<Code> megamorphic_stub() { | 382 virtual Handle<Code> megamorphic_stub() { |
| 386 return isolate()->builtins()->LoadIC_Megamorphic(); | 383 return isolate()->builtins()->LoadIC_Megamorphic(); |
| 387 } | 384 } |
| 388 | 385 |
| 389 // Update the inline cache and the global stub cache based on the | 386 // Update the inline cache and the global stub cache based on the |
| 390 // lookup result. | 387 // lookup result. |
| 391 void UpdateCaches(LookupResult* lookup, | 388 void UpdateCaches(LookupResult* lookup, |
| 392 State state, | |
| 393 Handle<Object> object, | 389 Handle<Object> object, |
| 394 Handle<String> name); | 390 Handle<String> name); |
| 395 | 391 |
| 396 virtual Handle<Code> ComputeLoadHandler(LookupResult* lookup, | 392 virtual Handle<Code> ComputeLoadHandler(LookupResult* lookup, |
| 397 Handle<JSObject> receiver, | 393 Handle<JSObject> receiver, |
| 398 Handle<String> name); | 394 Handle<String> name); |
| 399 | 395 |
| 400 private: | 396 private: |
| 401 // Stub accessors. | 397 // Stub accessors. |
| 402 static Handle<Code> initialize_stub(Isolate* isolate) { | 398 static Handle<Code> initialize_stub(Isolate* isolate) { |
| (...skipping 20 matching lines...) Expand all Loading... |
| 423 }; | 419 }; |
| 424 | 420 |
| 425 | 421 |
| 426 class KeyedLoadIC: public LoadIC { | 422 class KeyedLoadIC: public LoadIC { |
| 427 public: | 423 public: |
| 428 explicit KeyedLoadIC(FrameDepth depth, Isolate* isolate) | 424 explicit KeyedLoadIC(FrameDepth depth, Isolate* isolate) |
| 429 : LoadIC(depth, isolate) { | 425 : LoadIC(depth, isolate) { |
| 430 ASSERT(target()->is_keyed_load_stub()); | 426 ASSERT(target()->is_keyed_load_stub()); |
| 431 } | 427 } |
| 432 | 428 |
| 433 MUST_USE_RESULT MaybeObject* Load(State state, | 429 MUST_USE_RESULT MaybeObject* Load(Handle<Object> object, |
| 434 Handle<Object> object, | |
| 435 Handle<Object> key, | 430 Handle<Object> key, |
| 436 ICMissMode force_generic); | 431 ICMissMode force_generic); |
| 437 | 432 |
| 438 // Code generator routines. | 433 // Code generator routines. |
| 439 static void GenerateMiss(MacroAssembler* masm, ICMissMode force_generic); | 434 static void GenerateMiss(MacroAssembler* masm, ICMissMode force_generic); |
| 440 static void GenerateRuntimeGetProperty(MacroAssembler* masm); | 435 static void GenerateRuntimeGetProperty(MacroAssembler* masm); |
| 441 static void GenerateInitialize(MacroAssembler* masm) { | 436 static void GenerateInitialize(MacroAssembler* masm) { |
| 442 GenerateMiss(masm, MISS); | 437 GenerateMiss(masm, MISS); |
| 443 } | 438 } |
| 444 static void GeneratePreMonomorphic(MacroAssembler* masm) { | 439 static void GeneratePreMonomorphic(MacroAssembler* masm) { |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 521 GenerateMiss(masm); | 516 GenerateMiss(masm); |
| 522 } | 517 } |
| 523 static void GenerateMiss(MacroAssembler* masm); | 518 static void GenerateMiss(MacroAssembler* masm); |
| 524 static void GenerateMegamorphic(MacroAssembler* masm, | 519 static void GenerateMegamorphic(MacroAssembler* masm, |
| 525 StrictModeFlag strict_mode); | 520 StrictModeFlag strict_mode); |
| 526 static void GenerateNormal(MacroAssembler* masm); | 521 static void GenerateNormal(MacroAssembler* masm); |
| 527 static void GenerateRuntimeSetProperty(MacroAssembler* masm, | 522 static void GenerateRuntimeSetProperty(MacroAssembler* masm, |
| 528 StrictModeFlag strict_mode); | 523 StrictModeFlag strict_mode); |
| 529 | 524 |
| 530 MUST_USE_RESULT MaybeObject* Store( | 525 MUST_USE_RESULT MaybeObject* Store( |
| 531 State state, | |
| 532 Handle<Object> object, | 526 Handle<Object> object, |
| 533 Handle<String> name, | 527 Handle<String> name, |
| 534 Handle<Object> value, | 528 Handle<Object> value, |
| 535 JSReceiver::StoreFromKeyed store_mode = | 529 JSReceiver::StoreFromKeyed store_mode = |
| 536 JSReceiver::CERTAINLY_NOT_STORE_FROM_KEYED); | 530 JSReceiver::CERTAINLY_NOT_STORE_FROM_KEYED); |
| 537 | 531 |
| 538 protected: | 532 protected: |
| 539 virtual Code::Kind kind() const { return Code::STORE_IC; } | 533 virtual Code::Kind kind() const { return Code::STORE_IC; } |
| 540 virtual Handle<Code> megamorphic_stub() { | 534 virtual Handle<Code> megamorphic_stub() { |
| 541 if (strict_mode_ == kStrictMode) { | 535 if (strict_mode_ == kStrictMode) { |
| (...skipping 28 matching lines...) Expand all Loading... |
| 570 if (strict_mode_ == kStrictMode) { | 564 if (strict_mode_ == kStrictMode) { |
| 571 return isolate()->builtins()->StoreIC_GlobalProxy_Strict(); | 565 return isolate()->builtins()->StoreIC_GlobalProxy_Strict(); |
| 572 } else { | 566 } else { |
| 573 return isolate()->builtins()->StoreIC_GlobalProxy(); | 567 return isolate()->builtins()->StoreIC_GlobalProxy(); |
| 574 } | 568 } |
| 575 } | 569 } |
| 576 | 570 |
| 577 // Update the inline cache and the global stub cache based on the | 571 // Update the inline cache and the global stub cache based on the |
| 578 // lookup result. | 572 // lookup result. |
| 579 void UpdateCaches(LookupResult* lookup, | 573 void UpdateCaches(LookupResult* lookup, |
| 580 State state, | |
| 581 Handle<JSObject> receiver, | 574 Handle<JSObject> receiver, |
| 582 Handle<String> name, | 575 Handle<String> name, |
| 583 Handle<Object> value); | 576 Handle<Object> value); |
| 584 // Compute the code stub for this store; used for rewriting to | 577 // Compute the code stub for this store; used for rewriting to |
| 585 // monomorphic state and making sure that the code stub is in the | 578 // monomorphic state and making sure that the code stub is in the |
| 586 // stub cache. | 579 // stub cache. |
| 587 virtual Handle<Code> ComputeStoreMonomorphic(LookupResult* lookup, | 580 virtual Handle<Code> ComputeStoreMonomorphic(LookupResult* lookup, |
| 588 Handle<JSObject> receiver, | 581 Handle<JSObject> receiver, |
| 589 Handle<String> name, | 582 Handle<String> name, |
| 590 Handle<Object> value); | 583 Handle<Object> value); |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 626 }; | 619 }; |
| 627 | 620 |
| 628 | 621 |
| 629 class KeyedStoreIC: public StoreIC { | 622 class KeyedStoreIC: public StoreIC { |
| 630 public: | 623 public: |
| 631 KeyedStoreIC(FrameDepth depth, Isolate* isolate) | 624 KeyedStoreIC(FrameDepth depth, Isolate* isolate) |
| 632 : StoreIC(depth, isolate) { | 625 : StoreIC(depth, isolate) { |
| 633 ASSERT(target()->is_keyed_store_stub()); | 626 ASSERT(target()->is_keyed_store_stub()); |
| 634 } | 627 } |
| 635 | 628 |
| 636 MUST_USE_RESULT MaybeObject* Store(State state, | 629 MUST_USE_RESULT MaybeObject* Store(Handle<Object> object, |
| 637 Handle<Object> object, | |
| 638 Handle<Object> name, | 630 Handle<Object> name, |
| 639 Handle<Object> value, | 631 Handle<Object> value, |
| 640 ICMissMode force_generic); | 632 ICMissMode force_generic); |
| 641 | 633 |
| 642 // Code generators for stub routines. Only called once at startup. | 634 // Code generators for stub routines. Only called once at startup. |
| 643 static void GenerateInitialize(MacroAssembler* masm) { | 635 static void GenerateInitialize(MacroAssembler* masm) { |
| 644 GenerateMiss(masm, MISS); | 636 GenerateMiss(masm, MISS); |
| 645 } | 637 } |
| 646 static void GeneratePreMonomorphic(MacroAssembler* masm) { | 638 static void GeneratePreMonomorphic(MacroAssembler* masm) { |
| 647 GenerateMiss(masm, MISS); | 639 GenerateMiss(masm, MISS); |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 861 DECLARE_RUNTIME_FUNCTION(MaybeObject*, UnaryOpIC_Miss); | 853 DECLARE_RUNTIME_FUNCTION(MaybeObject*, UnaryOpIC_Miss); |
| 862 DECLARE_RUNTIME_FUNCTION(MaybeObject*, StoreIC_MissFromStubFailure); | 854 DECLARE_RUNTIME_FUNCTION(MaybeObject*, StoreIC_MissFromStubFailure); |
| 863 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ElementsTransitionAndStoreIC_Miss); | 855 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ElementsTransitionAndStoreIC_Miss); |
| 864 DECLARE_RUNTIME_FUNCTION(MaybeObject*, CompareNilIC_Miss); | 856 DECLARE_RUNTIME_FUNCTION(MaybeObject*, CompareNilIC_Miss); |
| 865 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ToBooleanIC_Miss); | 857 DECLARE_RUNTIME_FUNCTION(MaybeObject*, ToBooleanIC_Miss); |
| 866 | 858 |
| 867 | 859 |
| 868 } } // namespace v8::internal | 860 } } // namespace v8::internal |
| 869 | 861 |
| 870 #endif // V8_IC_H_ | 862 #endif // V8_IC_H_ |
| OLD | NEW |