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

Unified Diff: src/hydrogen-instructions.cc

Issue 488073002: Further reduce LookupResult usage (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: More consistency Created 6 years, 4 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/hydrogen-instructions.h ('k') | src/ic.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen-instructions.cc
diff --git a/src/hydrogen-instructions.cc b/src/hydrogen-instructions.cc
index 896efcf65f68c1d75ec5a19c9c6823d1541daf69..87860be6738c0c4d14b895243f95644938275b5a 100644
--- a/src/hydrogen-instructions.cc
+++ b/src/hydrogen-instructions.cc
@@ -4642,24 +4642,9 @@ HObjectAccess HObjectAccess::ForBackingStoreOffset(int offset,
}
-HObjectAccess HObjectAccess::ForField(Handle<Map> map,
- LookupResult* lookup,
+HObjectAccess HObjectAccess::ForField(Handle<Map> map, int index,
+ Representation representation,
Handle<String> name) {
- DCHECK(lookup->IsField() || lookup->IsTransitionToField());
- int index;
- Representation representation;
- if (lookup->IsField()) {
- index = lookup->GetLocalFieldIndexFromMap(*map);
- representation = lookup->representation();
- } else {
- Map* transition = lookup->GetTransitionTarget();
- int descriptor = transition->LastAdded();
- index = transition->instance_descriptors()->GetFieldIndex(descriptor) -
- map->inobject_properties();
- PropertyDetails details =
- transition->instance_descriptors()->GetDetails(descriptor);
- representation = details.representation();
- }
if (index < 0) {
// Negative property indices are in-object properties, indexed
// from the end of the fixed part of the object.
« no previous file with comments | « src/hydrogen-instructions.h ('k') | src/ic.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698