Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(13)

Side by Side Diff: src/arm/full-codegen-arm.cc

Issue 137083002: Get rid of ContextualMode for call ICs. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Restore HCallGlobal until a follow-up CL Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 2579 matching lines...) Expand 10 before | Expand all | Expand 10 after
2590 int arg_count = args->length(); 2590 int arg_count = args->length();
2591 { PreservePositionScope scope(masm()->positions_recorder()); 2591 { PreservePositionScope scope(masm()->positions_recorder());
2592 for (int i = 0; i < arg_count; i++) { 2592 for (int i = 0; i < arg_count; i++) {
2593 VisitForStackValue(args->at(i)); 2593 VisitForStackValue(args->at(i));
2594 } 2594 }
2595 __ mov(r2, Operand(name)); 2595 __ mov(r2, Operand(name));
2596 } 2596 }
2597 // Record source position for debugger. 2597 // Record source position for debugger.
2598 SetSourcePosition(expr->position()); 2598 SetSourcePosition(expr->position());
2599 // Call the IC initialization code. 2599 // Call the IC initialization code.
2600 Handle<Code> ic = 2600 Handle<Code> ic = isolate()->stub_cache()->ComputeCallInitialize(arg_count);
2601 isolate()->stub_cache()->ComputeCallInitialize(arg_count, mode);
2602 TypeFeedbackId ast_id = mode == CONTEXTUAL 2601 TypeFeedbackId ast_id = mode == CONTEXTUAL
2603 ? TypeFeedbackId::None() 2602 ? TypeFeedbackId::None()
2604 : expr->CallFeedbackId(); 2603 : expr->CallFeedbackId();
2605 CallIC(ic, mode, ast_id); 2604 CallIC(ic, mode, ast_id);
2606 RecordJSReturnSite(expr); 2605 RecordJSReturnSite(expr);
2607 // Restore context register. 2606 // Restore context register.
2608 __ ldr(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); 2607 __ ldr(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
2609 context()->Plug(r0); 2608 context()->Plug(r0);
2610 } 2609 }
2611 2610
(...skipping 1519 matching lines...) Expand 10 before | Expand all | Expand 10 after
4131 4130
4132 // Push the arguments ("left-to-right"). 4131 // Push the arguments ("left-to-right").
4133 int arg_count = args->length(); 4132 int arg_count = args->length();
4134 for (int i = 0; i < arg_count; i++) { 4133 for (int i = 0; i < arg_count; i++) {
4135 VisitForStackValue(args->at(i)); 4134 VisitForStackValue(args->at(i));
4136 } 4135 }
4137 4136
4138 if (expr->is_jsruntime()) { 4137 if (expr->is_jsruntime()) {
4139 // Call the JS runtime function. 4138 // Call the JS runtime function.
4140 __ mov(r2, Operand(expr->name())); 4139 __ mov(r2, Operand(expr->name()));
4141 ContextualMode mode = NOT_CONTEXTUAL; 4140 Handle<Code> ic = isolate()->stub_cache()->ComputeCallInitialize(arg_count);
4142 Handle<Code> ic = 4141 CallIC(ic, NOT_CONTEXTUAL, expr->CallRuntimeFeedbackId());
4143 isolate()->stub_cache()->ComputeCallInitialize(arg_count, mode);
4144 CallIC(ic, mode, expr->CallRuntimeFeedbackId());
4145 // Restore context register. 4142 // Restore context register.
4146 __ ldr(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); 4143 __ ldr(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
4147 } else { 4144 } else {
4148 // Call the C runtime function. 4145 // Call the C runtime function.
4149 __ CallRuntime(expr->function(), arg_count); 4146 __ CallRuntime(expr->function(), arg_count);
4150 } 4147 }
4151 context()->Plug(r0); 4148 context()->Plug(r0);
4152 } 4149 }
4153 4150
4154 4151
(...skipping 741 matching lines...) Expand 10 before | Expand all | Expand 10 after
4896 ASSERT(Memory::uint32_at(interrupt_address_pointer) == 4893 ASSERT(Memory::uint32_at(interrupt_address_pointer) ==
4897 reinterpret_cast<uint32_t>( 4894 reinterpret_cast<uint32_t>(
4898 isolate->builtins()->OsrAfterStackCheck()->entry())); 4895 isolate->builtins()->OsrAfterStackCheck()->entry()));
4899 return OSR_AFTER_STACK_CHECK; 4896 return OSR_AFTER_STACK_CHECK;
4900 } 4897 }
4901 4898
4902 4899
4903 } } // namespace v8::internal 4900 } } // namespace v8::internal
4904 4901
4905 #endif // V8_TARGET_ARCH_ARM 4902 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « no previous file | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698