| 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 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 Code::ExtraICState extra_state = Code::kNoExtraICState, | 86 Code::ExtraICState extra_state = Code::kNoExtraICState, |
| 87 InlineCacheHolderFlag cache_holder = OWN_MAP); | 87 InlineCacheHolderFlag cache_holder = OWN_MAP); |
| 88 | 88 |
| 89 Handle<Code> FindHandler(Handle<Name> name, | 89 Handle<Code> FindHandler(Handle<Name> name, |
| 90 Handle<HeapObject> stub_holder, | 90 Handle<HeapObject> stub_holder, |
| 91 Code::Kind kind, | 91 Code::Kind kind, |
| 92 InlineCacheHolderFlag cache_holder = OWN_MAP, | 92 InlineCacheHolderFlag cache_holder = OWN_MAP, |
| 93 StrictModeFlag strict_mode = kNonStrictMode); | 93 StrictModeFlag strict_mode = kNonStrictMode); |
| 94 | 94 |
| 95 Handle<Code> ComputeMonomorphicIC(Handle<Name> name, | 95 Handle<Code> ComputeMonomorphicIC(Handle<Name> name, |
| 96 Handle<Object> receiver, | 96 Handle<Type> type, |
| 97 Handle<Code> handler, | 97 Handle<Code> handler, |
| 98 StrictModeFlag strict_mode); | 98 StrictModeFlag strict_mode); |
| 99 | 99 |
| 100 Handle<Code> ComputeLoadNonexistent(Handle<Name> name, Handle<Object> object); | 100 Handle<Code> ComputeLoadNonexistent(Handle<Name> name, Handle<Object> object); |
| 101 | 101 |
| 102 Handle<Code> ComputeKeyedLoadElement(Handle<Map> receiver_map); | 102 Handle<Code> ComputeKeyedLoadElement(Handle<Map> receiver_map); |
| 103 | 103 |
| 104 Handle<Code> ComputeKeyedStoreElement(Handle<Map> receiver_map, | 104 Handle<Code> ComputeKeyedStoreElement(Handle<Map> receiver_map, |
| 105 StrictModeFlag strict_mode, | 105 StrictModeFlag strict_mode, |
| 106 KeyedAccessStoreMode store_mode); | 106 KeyedAccessStoreMode store_mode); |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 Handle<Code> ComputeCompareNil(Handle<Map> receiver_map, | 166 Handle<Code> ComputeCompareNil(Handle<Map> receiver_map, |
| 167 CompareNilICStub& stub); | 167 CompareNilICStub& stub); |
| 168 | 168 |
| 169 // --- | 169 // --- |
| 170 | 170 |
| 171 Handle<Code> ComputeLoadElementPolymorphic(MapHandleList* receiver_maps); | 171 Handle<Code> ComputeLoadElementPolymorphic(MapHandleList* receiver_maps); |
| 172 Handle<Code> ComputeStoreElementPolymorphic(MapHandleList* receiver_maps, | 172 Handle<Code> ComputeStoreElementPolymorphic(MapHandleList* receiver_maps, |
| 173 KeyedAccessStoreMode store_mode, | 173 KeyedAccessStoreMode store_mode, |
| 174 StrictModeFlag strict_mode); | 174 StrictModeFlag strict_mode); |
| 175 | 175 |
| 176 Handle<Code> ComputePolymorphicIC(MapHandleList* receiver_maps, | 176 Handle<Code> ComputePolymorphicIC(TypeHandleList* types, |
| 177 CodeHandleList* handlers, | 177 CodeHandleList* handlers, |
| 178 int number_of_valid_maps, | 178 int number_of_valid_maps, |
| 179 Handle<Name> name, | 179 Handle<Name> name, |
| 180 StrictModeFlag strict_mode); | 180 StrictModeFlag strict_mode); |
| 181 | 181 |
| 182 // Finds the Code object stored in the Heap::non_monomorphic_cache(). | 182 // Finds the Code object stored in the Heap::non_monomorphic_cache(). |
| 183 Code* FindCallInitialize(int argc, RelocInfo::Mode mode, Code::Kind kind); | 183 Code* FindCallInitialize(int argc, RelocInfo::Mode mode, Code::Kind kind); |
| 184 | 184 |
| 185 #ifdef ENABLE_DEBUGGER_SUPPORT | 185 #ifdef ENABLE_DEBUGGER_SUPPORT |
| 186 Handle<Code> ComputeCallDebugBreak(int argc, Code::Kind kind); | 186 Handle<Code> ComputeCallDebugBreak(int argc, Code::Kind kind); |
| (...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 525 class BaseLoadStoreStubCompiler: public StubCompiler { | 525 class BaseLoadStoreStubCompiler: public StubCompiler { |
| 526 public: | 526 public: |
| 527 BaseLoadStoreStubCompiler(Isolate* isolate, | 527 BaseLoadStoreStubCompiler(Isolate* isolate, |
| 528 Code::Kind kind, | 528 Code::Kind kind, |
| 529 InlineCacheHolderFlag cache_holder = OWN_MAP) | 529 InlineCacheHolderFlag cache_holder = OWN_MAP) |
| 530 : StubCompiler(isolate), kind_(kind), cache_holder_(cache_holder) { | 530 : StubCompiler(isolate), kind_(kind), cache_holder_(cache_holder) { |
| 531 InitializeRegisters(); | 531 InitializeRegisters(); |
| 532 } | 532 } |
| 533 virtual ~BaseLoadStoreStubCompiler() { } | 533 virtual ~BaseLoadStoreStubCompiler() { } |
| 534 | 534 |
| 535 Handle<Code> CompileMonomorphicIC(Handle<Map> receiver_map, | 535 Handle<Code> CompileMonomorphicIC(Handle<Type> type, |
| 536 Handle<Code> handler, | 536 Handle<Code> handler, |
| 537 Handle<Name> name); | 537 Handle<Name> name); |
| 538 | 538 |
| 539 Handle<Code> CompilePolymorphicIC(MapHandleList* receiver_maps, | 539 Handle<Code> CompilePolymorphicIC(TypeHandleList* types, |
| 540 CodeHandleList* handlers, | 540 CodeHandleList* handlers, |
| 541 Handle<Name> name, | 541 Handle<Name> name, |
| 542 Code::StubType type, | 542 Code::StubType type, |
| 543 IcCheckType check); | 543 IcCheckType check); |
| 544 | 544 |
| 545 virtual void GenerateNameCheck(Handle<Name> name, | 545 virtual void GenerateNameCheck(Handle<Name> name, |
| 546 Register name_reg, | 546 Register name_reg, |
| 547 Label* miss) { } | 547 Label* miss) { } |
| 548 | 548 |
| 549 static Builtins::Name MissBuiltin(Code::Kind kind) { | 549 static Builtins::Name MissBuiltin(Code::Kind kind) { |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 601 | 601 |
| 602 virtual Code::ExtraICState extra_state() { return Code::kNoExtraICState; } | 602 virtual Code::ExtraICState extra_state() { return Code::kNoExtraICState; } |
| 603 virtual Register receiver() = 0; | 603 virtual Register receiver() = 0; |
| 604 virtual Register name() = 0; | 604 virtual Register name() = 0; |
| 605 virtual Register scratch1() = 0; | 605 virtual Register scratch1() = 0; |
| 606 virtual Register scratch2() = 0; | 606 virtual Register scratch2() = 0; |
| 607 virtual Register scratch3() = 0; | 607 virtual Register scratch3() = 0; |
| 608 | 608 |
| 609 void InitializeRegisters(); | 609 void InitializeRegisters(); |
| 610 | 610 |
| 611 bool HasHeapNumberMap(MapHandleList* receiver_maps); | 611 bool IncludesNumberType(TypeHandleList* types); |
| 612 | 612 |
| 613 Code::Kind kind_; | 613 Code::Kind kind_; |
| 614 InlineCacheHolderFlag cache_holder_; | 614 InlineCacheHolderFlag cache_holder_; |
| 615 Register* registers_; | 615 Register* registers_; |
| 616 }; | 616 }; |
| 617 | 617 |
| 618 | 618 |
| 619 class LoadStubCompiler: public BaseLoadStoreStubCompiler { | 619 class LoadStubCompiler: public BaseLoadStoreStubCompiler { |
| 620 public: | 620 public: |
| 621 LoadStubCompiler(Isolate* isolate, | 621 LoadStubCompiler(Isolate* isolate, |
| (...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1050 Handle<JSFunction> constant_function_; | 1050 Handle<JSFunction> constant_function_; |
| 1051 bool is_simple_api_call_; | 1051 bool is_simple_api_call_; |
| 1052 Handle<FunctionTemplateInfo> expected_receiver_type_; | 1052 Handle<FunctionTemplateInfo> expected_receiver_type_; |
| 1053 Handle<CallHandlerInfo> api_call_info_; | 1053 Handle<CallHandlerInfo> api_call_info_; |
| 1054 }; | 1054 }; |
| 1055 | 1055 |
| 1056 | 1056 |
| 1057 } } // namespace v8::internal | 1057 } } // namespace v8::internal |
| 1058 | 1058 |
| 1059 #endif // V8_STUB_CACHE_H_ | 1059 #endif // V8_STUB_CACHE_H_ |
| OLD | NEW |