Reviewers: Weiliang, mvstanton,
Message:
WL.
PTAL.
thanks
Description:
X87: Updates to maintain flag --vector-ics
port r24548.
original commit message:
Updates to maintain flag --vector-ics
BUG=
Please review this at https://codereview.chromium.org/642603004/
SVN Base: https://chromium.googlesource.com/external/v8.git@bleeding_edge
Affected files (+25, -11 lines):
M src/x87/builtins-x87.cc
M src/x87/debug-x87.cc
M src/x87/full-codegen-x87.cc
Index: src/x87/builtins-x87.cc
diff --git a/src/x87/builtins-x87.cc b/src/x87/builtins-x87.cc
index
d6311752c719d14d328ac752ba29fb9fb807cdac..861ec7ed020fe680a3a408eb9422c5281474d064
100644
--- a/src/x87/builtins-x87.cc
+++ b/src/x87/builtins-x87.cc
@@ -1002,17 +1002,21 @@ void
Builtins::Generate_FunctionApply(MacroAssembler* masm) {
__ bind(&loop);
__ mov(receiver, Operand(ebp, kArgumentsOffset)); // load arguments
- // Use inline caching to speed up access to arguments.
if (FLAG_vector_ics) {
- __ mov(VectorLoadICDescriptor::SlotRegister(),
- Immediate(Smi::FromInt(0)));
+ // TODO(mvstanton): Vector-based ics need additional infrastructure
to
+ // be embedded here. For now, just call the runtime.
+ __ push(receiver);
+ __ push(key);
+ __ CallRuntime(Runtime::kGetProperty, 2);
+ } else {
+ // Use inline caching to speed up access to arguments.
+ Handle<Code> ic = CodeFactory::KeyedLoadIC(masm->isolate()).code();
+ __ call(ic, RelocInfo::CODE_TARGET);
+ // It is important that we do not have a test instruction after the
+ // call. A test instruction after the call is used to indicate that
+ // we have generated an inline version of the keyed load. In this
+ // case, we know that we are not generating a test instruction next.
}
- Handle<Code> ic = CodeFactory::KeyedLoadIC(masm->isolate()).code();
- __ call(ic, RelocInfo::CODE_TARGET);
- // It is important that we do not have a test instruction after the
- // call. A test instruction after the call is used to indicate that
- // we have generated an inline version of the keyed load. In this
- // case, we know that we are not generating a test instruction next.
// Push the nth argument.
__ push(eax);
Index: src/x87/debug-x87.cc
diff --git a/src/x87/debug-x87.cc b/src/x87/debug-x87.cc
index
92c23abea22123aa69983a4e986aca66d86537c0..cdbcbad966254ee8625889a53280f10616769b1c
100644
--- a/src/x87/debug-x87.cc
+++ b/src/x87/debug-x87.cc
@@ -182,7 +182,11 @@ void
DebugCodegen::GenerateLoadICDebugBreak(MacroAssembler* masm) {
// Register state for IC load call (from ic-x87.cc).
Register receiver = LoadDescriptor::ReceiverRegister();
Register name = LoadDescriptor::NameRegister();
- Generate_DebugBreakCallHelper(masm, receiver.bit() | name.bit(), 0,
false);
+ RegList regs = receiver.bit() | name.bit();
+ if (FLAG_vector_ics) {
+ regs |= VectorLoadICTrampolineDescriptor::SlotRegister().bit();
+ }
+ Generate_DebugBreakCallHelper(masm, regs, 0, false);
}
Index: src/x87/full-codegen-x87.cc
diff --git a/src/x87/full-codegen-x87.cc b/src/x87/full-codegen-x87.cc
index
f95359b60759ff82358ad3e4a1044da54093cc2c..295d087777b0ec3d7b639326729b016f911a4632
100644
--- a/src/x87/full-codegen-x87.cc
+++ b/src/x87/full-codegen-x87.cc
@@ -1276,7 +1276,13 @@ void
FullCodeGenerator::EmitLoadHomeObject(SuperReference* expr) {
Handle<Symbol>
home_object_symbol(isolate()->heap()->home_object_symbol());
__ mov(LoadDescriptor::NameRegister(), home_object_symbol);
- CallLoadIC(NOT_CONTEXTUAL, expr->HomeObjectFeedbackId());
+ if (FLAG_vector_ics) {
+ __ mov(VectorLoadICDescriptor::SlotRegister(),
+ Immediate(Smi::FromInt(expr->HomeObjectFeedbackSlot())));
+ CallLoadIC(NOT_CONTEXTUAL);
+ } else {
+ CallLoadIC(NOT_CONTEXTUAL, expr->HomeObjectFeedbackId());
+ }
__ cmp(eax, isolate()->factory()->undefined_value());
Label done;
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.