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 2754 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2765 __ jmp(handler_stubs->at(i), RelocInfo::CODE_TARGET); | 2765 __ jmp(handler_stubs->at(i), RelocInfo::CODE_TARGET); |
2766 __ bind(&next_map); | 2766 __ bind(&next_map); |
2767 } | 2767 } |
2768 } | 2768 } |
2769 | 2769 |
2770 __ bind(&miss); | 2770 __ bind(&miss); |
2771 Handle<Code> ic = isolate()->builtins()->KeyedStoreIC_Miss(); | 2771 Handle<Code> ic = isolate()->builtins()->KeyedStoreIC_Miss(); |
2772 __ jmp(ic, RelocInfo::CODE_TARGET); | 2772 __ jmp(ic, RelocInfo::CODE_TARGET); |
2773 | 2773 |
2774 // Return the generated code. | 2774 // Return the generated code. |
2775 return GetCode(Code::NORMAL, factory()->empty_string(), MEGAMORPHIC); | 2775 return GetCode(Code::NORMAL, factory()->empty_string(), POLYMORPHIC); |
2776 } | 2776 } |
2777 | 2777 |
2778 | 2778 |
2779 Handle<Code> LoadStubCompiler::CompileLoadNonexistent(Handle<String> name, | 2779 Handle<Code> LoadStubCompiler::CompileLoadNonexistent(Handle<String> name, |
2780 Handle<JSObject> object, | 2780 Handle<JSObject> object, |
2781 Handle<JSObject> last) { | 2781 Handle<JSObject> last) { |
2782 // ----------- S t a t e ------------- | 2782 // ----------- S t a t e ------------- |
2783 // -- rax : receiver | 2783 // -- rax : receiver |
2784 // -- rcx : name | 2784 // -- rcx : name |
2785 // -- rsp[0] : return address | 2785 // -- rsp[0] : return address |
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3246 for (int current = 0; current < receiver_count; ++current) { | 3246 for (int current = 0; current < receiver_count; ++current) { |
3247 // Check map and tail call if there's a match | 3247 // Check map and tail call if there's a match |
3248 __ Cmp(map_reg, receiver_maps->at(current)); | 3248 __ Cmp(map_reg, receiver_maps->at(current)); |
3249 __ j(equal, handler_ics->at(current), RelocInfo::CODE_TARGET); | 3249 __ j(equal, handler_ics->at(current), RelocInfo::CODE_TARGET); |
3250 } | 3250 } |
3251 | 3251 |
3252 __ bind(&miss); | 3252 __ bind(&miss); |
3253 GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC); | 3253 GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC); |
3254 | 3254 |
3255 // Return the generated code. | 3255 // Return the generated code. |
3256 return GetCode(Code::NORMAL, factory()->empty_string(), MEGAMORPHIC); | 3256 return GetCode(Code::NORMAL, factory()->empty_string(), POLYMORPHIC); |
3257 } | 3257 } |
3258 | 3258 |
3259 | 3259 |
3260 // Specialized stub for constructing objects from functions which only have only | 3260 // Specialized stub for constructing objects from functions which only have only |
3261 // simple assignments of the form this.x = ...; in their body. | 3261 // simple assignments of the form this.x = ...; in their body. |
3262 Handle<Code> ConstructStubCompiler::CompileConstructStub( | 3262 Handle<Code> ConstructStubCompiler::CompileConstructStub( |
3263 Handle<JSFunction> function) { | 3263 Handle<JSFunction> function) { |
3264 // ----------- S t a t e ------------- | 3264 // ----------- S t a t e ------------- |
3265 // -- rax : argc | 3265 // -- rax : argc |
3266 // -- rdi : constructor | 3266 // -- rdi : constructor |
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3928 __ jmp(ic_slow, RelocInfo::CODE_TARGET); | 3928 __ jmp(ic_slow, RelocInfo::CODE_TARGET); |
3929 } | 3929 } |
3930 } | 3930 } |
3931 | 3931 |
3932 | 3932 |
3933 #undef __ | 3933 #undef __ |
3934 | 3934 |
3935 } } // namespace v8::internal | 3935 } } // namespace v8::internal |
3936 | 3936 |
3937 #endif // V8_TARGET_ARCH_X64 | 3937 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |