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

Unified Diff: src/ic.h

Issue 429053005: Avoid one repeated property lookup when computing load ICs. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: rebased Created 6 years, 5 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/ic.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic.h
diff --git a/src/ic.h b/src/ic.h
index 4df0c69611cc62d1deab0a40115e48c9e99d3845..3b4b7fd74cffcaab54ab621f1a1ee7d4e71e459c 100644
--- a/src/ic.h
+++ b/src/ic.h
@@ -179,17 +179,29 @@ class IC {
static void PostPatching(Address address, Code* target, Code* old_target);
// Compute the handler either by compiling or by retrieving a cached version.
- Handle<Code> ComputeHandler(LookupResult* lookup,
- Handle<Object> object,
+ Handle<Code> ComputeHandler(LookupIterator* lookup, Handle<Object> object,
Handle<String> name,
Handle<Object> value = Handle<Code>::null());
- virtual Handle<Code> CompileHandler(LookupResult* lookup,
+ virtual Handle<Code> CompileHandler(LookupIterator* lookup,
Handle<Object> object,
Handle<String> name, Handle<Object> value,
CacheHolderFlag cache_holder) {
UNREACHABLE();
return Handle<Code>::null();
}
+ // Temporary copy of the above, but using a LookupResult.
+ // TODO(jkummerow): Migrate callers to LookupIterator and delete these.
+ Handle<Code> ComputeStoreHandler(LookupResult* lookup, Handle<Object> object,
+ Handle<String> name,
+ Handle<Object> value = Handle<Code>::null());
+ virtual Handle<Code> CompileStoreHandler(LookupResult* lookup,
+ Handle<Object> object,
+ Handle<String> name,
+ Handle<Object> value,
+ CacheHolderFlag cache_holder) {
+ UNREACHABLE();
+ return Handle<Code>::null();
+ }
void UpdateMonomorphicIC(Handle<Code> handler, Handle<String> name);
bool UpdatePolymorphicIC(Handle<String> name, Handle<Code> code);
@@ -474,11 +486,10 @@ class LoadIC: public IC {
// Update the inline cache and the global stub cache based on the
// lookup result.
- void UpdateCaches(LookupResult* lookup,
- Handle<Object> object,
+ void UpdateCaches(LookupIterator* lookup, Handle<Object> object,
Handle<String> name);
- virtual Handle<Code> CompileHandler(LookupResult* lookup,
+ virtual Handle<Code> CompileHandler(LookupIterator* lookup,
Handle<Object> object,
Handle<String> name,
Handle<Object> unused,
@@ -638,10 +649,11 @@ class StoreIC: public IC {
Handle<JSObject> receiver,
Handle<String> name,
Handle<Object> value);
- virtual Handle<Code> CompileHandler(LookupResult* lookup,
- Handle<Object> object,
- Handle<String> name, Handle<Object> value,
- CacheHolderFlag cache_holder);
+ virtual Handle<Code> CompileStoreHandler(LookupResult* lookup,
+ Handle<Object> object,
+ Handle<String> name,
+ Handle<Object> value,
+ CacheHolderFlag cache_holder);
private:
void set_target(Code* code) {
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/ic.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698