| 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 671 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 682 LoadIC::GeneratePreMonomorphic(masm()); | 682 LoadIC::GeneratePreMonomorphic(masm()); |
| 683 Handle<Code> code = GetCodeWithFlags(flags, "CompileLoadPreMonomorphic"); | 683 Handle<Code> code = GetCodeWithFlags(flags, "CompileLoadPreMonomorphic"); |
| 684 PROFILE(isolate(), | 684 PROFILE(isolate(), |
| 685 CodeCreateEvent(Logger::LOAD_PREMONOMORPHIC_TAG, *code, 0)); | 685 CodeCreateEvent(Logger::LOAD_PREMONOMORPHIC_TAG, *code, 0)); |
| 686 GDBJIT(AddCode(GDBJITInterface::LOAD_IC, *code)); | 686 GDBJIT(AddCode(GDBJITInterface::LOAD_IC, *code)); |
| 687 return code; | 687 return code; |
| 688 } | 688 } |
| 689 | 689 |
| 690 | 690 |
| 691 Handle<Code> StubCompiler::CompileLoadMegamorphic(Code::Flags flags) { | 691 Handle<Code> StubCompiler::CompileLoadMegamorphic(Code::Flags flags) { |
| 692 ExtraICState extra_state = Code::ExtractExtraICStateFromFlags(flags); | 692 LoadIC::GenerateMegamorphic(masm()); |
| 693 ContextualMode mode = LoadIC::GetContextualMode(extra_state); | |
| 694 LoadIC::GenerateMegamorphic(masm(), mode); | |
| 695 Handle<Code> code = GetCodeWithFlags(flags, "CompileLoadMegamorphic"); | 693 Handle<Code> code = GetCodeWithFlags(flags, "CompileLoadMegamorphic"); |
| 696 PROFILE(isolate(), | 694 PROFILE(isolate(), |
| 697 CodeCreateEvent(Logger::LOAD_MEGAMORPHIC_TAG, *code, 0)); | 695 CodeCreateEvent(Logger::LOAD_MEGAMORPHIC_TAG, *code, 0)); |
| 698 GDBJIT(AddCode(GDBJITInterface::LOAD_IC, *code)); | 696 GDBJIT(AddCode(GDBJITInterface::LOAD_IC, *code)); |
| 699 return code; | 697 return code; |
| 700 } | 698 } |
| 701 | 699 |
| 702 | 700 |
| 703 Handle<Code> StubCompiler::CompileStoreInitialize(Code::Flags flags) { | 701 Handle<Code> StubCompiler::CompileStoreInitialize(Code::Flags flags) { |
| 704 StoreIC::GenerateInitialize(masm()); | 702 StoreIC::GenerateInitialize(masm()); |
| (...skipping 21 matching lines...) Expand all Loading... |
| 726 StoreIC::GenerateRuntimeSetProperty(masm(), strict_mode); | 724 StoreIC::GenerateRuntimeSetProperty(masm(), strict_mode); |
| 727 Handle<Code> code = GetCodeWithFlags(flags, "CompileStoreGeneric"); | 725 Handle<Code> code = GetCodeWithFlags(flags, "CompileStoreGeneric"); |
| 728 PROFILE(isolate(), | 726 PROFILE(isolate(), |
| 729 CodeCreateEvent(Logger::STORE_GENERIC_TAG, *code, 0)); | 727 CodeCreateEvent(Logger::STORE_GENERIC_TAG, *code, 0)); |
| 730 GDBJIT(AddCode(GDBJITInterface::STORE_IC, *code)); | 728 GDBJIT(AddCode(GDBJITInterface::STORE_IC, *code)); |
| 731 return code; | 729 return code; |
| 732 } | 730 } |
| 733 | 731 |
| 734 | 732 |
| 735 Handle<Code> StubCompiler::CompileStoreMegamorphic(Code::Flags flags) { | 733 Handle<Code> StubCompiler::CompileStoreMegamorphic(Code::Flags flags) { |
| 736 ExtraICState extra_state = Code::ExtractExtraICStateFromFlags(flags); | 734 StoreIC::GenerateMegamorphic(masm()); |
| 737 StoreIC::GenerateMegamorphic(masm(), extra_state); | |
| 738 Handle<Code> code = GetCodeWithFlags(flags, "CompileStoreMegamorphic"); | 735 Handle<Code> code = GetCodeWithFlags(flags, "CompileStoreMegamorphic"); |
| 739 PROFILE(isolate(), | 736 PROFILE(isolate(), |
| 740 CodeCreateEvent(Logger::STORE_MEGAMORPHIC_TAG, *code, 0)); | 737 CodeCreateEvent(Logger::STORE_MEGAMORPHIC_TAG, *code, 0)); |
| 741 GDBJIT(AddCode(GDBJITInterface::STORE_IC, *code)); | 738 GDBJIT(AddCode(GDBJITInterface::STORE_IC, *code)); |
| 742 return code; | 739 return code; |
| 743 } | 740 } |
| 744 | 741 |
| 745 | 742 |
| 746 #undef CALL_LOGGER_TAG | 743 #undef CALL_LOGGER_TAG |
| 747 | 744 |
| (...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1228 Handle<Code> code = GetCodeWithFlags(flags, name); | 1225 Handle<Code> code = GetCodeWithFlags(flags, name); |
| 1229 PROFILE(isolate(), CodeCreateEvent(log_kind(code), *code, *name)); | 1226 PROFILE(isolate(), CodeCreateEvent(log_kind(code), *code, *name)); |
| 1230 JitEvent(name, code); | 1227 JitEvent(name, code); |
| 1231 return code; | 1228 return code; |
| 1232 } | 1229 } |
| 1233 | 1230 |
| 1234 | 1231 |
| 1235 Handle<Code> BaseLoadStoreStubCompiler::GetCode(Code::Kind kind, | 1232 Handle<Code> BaseLoadStoreStubCompiler::GetCode(Code::Kind kind, |
| 1236 Code::StubType type, | 1233 Code::StubType type, |
| 1237 Handle<Name> name) { | 1234 Handle<Name> name) { |
| 1238 Code::Flags flags = Code::ComputeHandlerFlags( | 1235 ASSERT_EQ(kNoExtraICState, extra_state()); |
| 1239 kind, extra_state(), type, cache_holder_); | 1236 Code::Flags flags = Code::ComputeHandlerFlags(kind, type, cache_holder_); |
| 1240 Handle<Code> code = GetCodeWithFlags(flags, name); | 1237 Handle<Code> code = GetCodeWithFlags(flags, name); |
| 1241 PROFILE(isolate(), CodeCreateEvent(log_kind(code), *code, *name)); | 1238 PROFILE(isolate(), CodeCreateEvent(log_kind(code), *code, *name)); |
| 1242 JitEvent(name, code); | 1239 JitEvent(name, code); |
| 1243 return code; | 1240 return code; |
| 1244 } | 1241 } |
| 1245 | 1242 |
| 1246 | 1243 |
| 1247 void KeyedLoadStubCompiler::CompileElementHandlers(MapHandleList* receiver_maps, | 1244 void KeyedLoadStubCompiler::CompileElementHandlers(MapHandleList* receiver_maps, |
| 1248 CodeHandleList* handlers) { | 1245 CodeHandleList* handlers) { |
| 1249 for (int i = 0; i < receiver_maps->length(); ++i) { | 1246 for (int i = 0; i < receiver_maps->length(); ++i) { |
| (...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1445 Handle<FunctionTemplateInfo>( | 1442 Handle<FunctionTemplateInfo>( |
| 1446 FunctionTemplateInfo::cast(signature->receiver())); | 1443 FunctionTemplateInfo::cast(signature->receiver())); |
| 1447 } | 1444 } |
| 1448 } | 1445 } |
| 1449 | 1446 |
| 1450 is_simple_api_call_ = true; | 1447 is_simple_api_call_ = true; |
| 1451 } | 1448 } |
| 1452 | 1449 |
| 1453 | 1450 |
| 1454 } } // namespace v8::internal | 1451 } } // namespace v8::internal |
| OLD | NEW |