| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/ast.h" | 7 #include "src/ast.h" |
| 8 #include "src/ast-numbering.h" | 8 #include "src/ast-numbering.h" |
| 9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
| 10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
| (...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 438 | 438 |
| 439 | 439 |
| 440 void FullCodeGenerator::CallLoadIC(ContextualMode contextual_mode, | 440 void FullCodeGenerator::CallLoadIC(ContextualMode contextual_mode, |
| 441 TypeFeedbackId id) { | 441 TypeFeedbackId id) { |
| 442 Handle<Code> ic = CodeFactory::LoadIC(isolate(), contextual_mode).code(); | 442 Handle<Code> ic = CodeFactory::LoadIC(isolate(), contextual_mode).code(); |
| 443 CallIC(ic, id); | 443 CallIC(ic, id); |
| 444 } | 444 } |
| 445 | 445 |
| 446 | 446 |
| 447 void FullCodeGenerator::CallGlobalLoadIC(Handle<String> name) { | 447 void FullCodeGenerator::CallGlobalLoadIC(Handle<String> name) { |
| 448 if (masm()->serializer_enabled() || FLAG_vector_ics) { | 448 return CallLoadIC(CONTEXTUAL); |
| 449 // Vector-ICs don't work with LoadGlobalIC. | |
| 450 return CallLoadIC(CONTEXTUAL); | |
| 451 } | |
| 452 Handle<Code> ic = CodeFactory::LoadGlobalIC( | |
| 453 isolate(), isolate()->global_object(), name).code(); | |
| 454 CallIC(ic, TypeFeedbackId::None()); | |
| 455 } | 449 } |
| 456 | 450 |
| 457 | 451 |
| 458 void FullCodeGenerator::CallStoreIC(TypeFeedbackId id) { | 452 void FullCodeGenerator::CallStoreIC(TypeFeedbackId id) { |
| 459 Handle<Code> ic = CodeFactory::StoreIC(isolate(), language_mode()).code(); | 453 Handle<Code> ic = CodeFactory::StoreIC(isolate(), language_mode()).code(); |
| 460 CallIC(ic, id); | 454 CallIC(ic, id); |
| 461 } | 455 } |
| 462 | 456 |
| 463 | 457 |
| 464 void FullCodeGenerator::RecordJSReturnSite(Call* call) { | 458 void FullCodeGenerator::RecordJSReturnSite(Call* call) { |
| (...skipping 1177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1642 } | 1636 } |
| 1643 codegen_->PrepareForBailoutForId(exit_id_, NO_REGISTERS); | 1637 codegen_->PrepareForBailoutForId(exit_id_, NO_REGISTERS); |
| 1644 codegen_->scope_ = saved_scope_; | 1638 codegen_->scope_ = saved_scope_; |
| 1645 } | 1639 } |
| 1646 | 1640 |
| 1647 | 1641 |
| 1648 #undef __ | 1642 #undef __ |
| 1649 | 1643 |
| 1650 | 1644 |
| 1651 } } // namespace v8::internal | 1645 } } // namespace v8::internal |
| OLD | NEW |