Commit 67936a7b authored by lrn@chromium.org's avatar lrn@chromium.org

X64: Fix lint problem and add missing stub function.

Review URL: http://codereview.chromium.org/160387


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2588 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 1a39e070
......@@ -737,8 +737,6 @@ Object* KeyedLoadIC::Load(State state,
return TypeError("non_object_property_load", object, name);
}
// TODO(X64): Enable specialized stubs for length and prototype lookup.
#ifndef V8_TARGET_ARCH_X64
if (FLAG_use_ic) {
// Use specialized code for getting the length of strings.
if (object->IsString() && name->Equals(Heap::length_symbol())) {
......@@ -778,7 +776,6 @@ Object* KeyedLoadIC::Load(State state,
return Accessors::FunctionGetPrototype(*object, 0);
}
}
#endif // !V8_TARGET_ARCH_X64
// Check if the name is trivially convertible to an index and get
// the element or char if so.
......
......@@ -5459,7 +5459,8 @@ void Reference::GetValue(TypeofState typeof_state) {
__ bind(deferred->patch_site());
// Use masm-> here instead of the double underscore macro since extra
// coverage code can interfere with the patching.
masm->movq(kScratchRegister, Factory::null_value(), RelocInfo::EMBEDDED_OBJECT);
masm->movq(kScratchRegister, Factory::null_value(),
RelocInfo::EMBEDDED_OBJECT);
masm->cmpq(FieldOperand(receiver.reg(), HeapObject::kMapOffset),
kScratchRegister);
deferred->Branch(not_equal);
......
......@@ -1144,6 +1144,36 @@ Object* LoadStubCompiler::CompileLoadGlobal(JSObject* object,
}
Object* KeyedLoadStubCompiler::CompileLoadCallback(String* name,
JSObject* receiver,
JSObject* holder,
AccessorInfo* callback) {
// ----------- S t a t e -------------
// -- rsp[0] : return address
// -- rsp[8] : name
// -- rsp[16] : receiver
// -----------------------------------
Label miss;
__ movq(rax, Operand(rsp, kPointerSize));
__ movq(rcx, Operand(rsp, 2 * kPointerSize));
__ IncrementCounter(&Counters::keyed_load_callback, 1);
// Check that the name has not changed.
__ Cmp(rax, Handle<String>(name));
__ j(not_equal, &miss);
GenerateLoadCallback(receiver, holder, rcx, rax, rbx, rdx,
callback, name, &miss);
__ bind(&miss);
__ DecrementCounter(&Counters::keyed_load_callback, 1);
GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC);
// Return the generated code.
return GetCode(CALLBACKS, name);
}
Object* KeyedLoadStubCompiler::CompileLoadArrayLength(String* name) {
// ----------- S t a t e -------------
// -- rsp[0] : return address
......@@ -1170,15 +1200,6 @@ Object* KeyedLoadStubCompiler::CompileLoadArrayLength(String* name) {
}
Object* KeyedLoadStubCompiler::CompileLoadCallback(String* name,
JSObject* object,
JSObject* holder,
AccessorInfo* callback) {
UNIMPLEMENTED();
return NULL;
}
Object* KeyedLoadStubCompiler::CompileLoadConstant(String* name,
JSObject* receiver,
JSObject* holder,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment