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

Unified Diff: src/stub-cache.cc

Issue 14847004: Turn the load field code stub into a hydrogen code stub. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed comments Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/stub-cache.cc
diff --git a/src/stub-cache.cc b/src/stub-cache.cc
index 63748779b11c59a75f08aa77eb778ecc3f367277..411abbab0f062c15e1ec28a19e02eff61c08e69e 100644
--- a/src/stub-cache.cc
+++ b/src/stub-cache.cc
@@ -223,8 +223,7 @@ Handle<Code> StubCache::ComputeLoadField(Handle<Name> name,
Handle<JSObject> holder,
PropertyIndex field) {
if (receiver.is_identical_to(holder)) {
- LoadFieldStub stub(LoadStubCompiler::receiver(),
- field.is_inobject(holder),
+ LoadFieldStub stub(field.is_inobject(holder),
field.translate(holder));
return stub.GetCode(isolate());
}
@@ -339,9 +338,8 @@ Handle<Code> StubCache::ComputeKeyedLoadField(Handle<Name> name,
Handle<JSObject> holder,
PropertyIndex field) {
if (receiver.is_identical_to(holder)) {
- LoadFieldStub stub(KeyedLoadStubCompiler::receiver(),
- field.is_inobject(holder),
- field.translate(holder));
+ KeyedLoadFieldStub stub(field.is_inobject(holder),
+ field.translate(holder));
return stub.GetCode(isolate());
}
@@ -1525,8 +1523,7 @@ Handle<Code> BaseLoadStubCompiler::CompileLoadField(Handle<JSObject> object,
Register reg = HandlerFrontendHeader(object, receiver(), holder, name, &miss);
- LoadFieldStub stub(reg, field.is_inobject(holder), field.translate(holder));
- GenerateTailCall(masm(), stub.GetCode(isolate()));
+ GenerateLoadField(reg, holder, field);
__ bind(&miss);
TailCallBuiltin(masm(), MissBuiltin(kind()));
@@ -1611,10 +1608,7 @@ void BaseLoadStubCompiler::GenerateLoadPostInterceptor(
if (lookup->IsField()) {
PropertyIndex field = lookup->GetFieldIndex();
if (interceptor_holder.is_identical_to(holder)) {
- LoadFieldStub stub(interceptor_reg,
- field.is_inobject(holder),
- field.translate(holder));
- GenerateTailCall(masm(), stub.GetCode(isolate()));
+ GenerateLoadField(interceptor_reg, holder, field);
} else {
// We found FIELD property in prototype chain of interceptor's holder.
// Retrieve a field from field's holder.
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698