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

Unified Diff: src/ic.h

Issue 2928: Propagate the information that a monomorphic prototype failure has... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 12 years, 3 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 | « no previous file | src/ic.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic.h
===================================================================
--- src/ic.h (revision 313)
+++ src/ic.h (working copy)
@@ -81,8 +81,12 @@
Code* target() { return GetTargetAtAddress(address()); }
inline Address address();
- // Compute the current IC state based on the target stub and the receiver.
- static State StateFrom(Code* target, Object* receiver);
+ // Compute the state of the current inline cache. If the current
+ // inline cache is monomorphic, this might change the code cache in
+ // the receiver map and it might return a code object from the code
+ // cache in the receiver map that should be used as the new target.
+ static State ComputeCacheState(Code* target, Object* receiver,
+ Object* name, Object** new_target);
// Clear the inline cache to initial state.
static void Clear(Address address);
@@ -161,7 +165,7 @@
public:
CallIC() : IC(EXTRA_CALL_FRAME) { ASSERT(target()->is_call_stub()); }
- Object* LoadFunction(State state, Handle<Object> object, Handle<String> name);
+ Object* LoadFunction(Handle<Object> object, Handle<String> name);
// Code generator routines.
@@ -179,7 +183,6 @@
// Update the inline cache and the global stub cache based on the
// lookup result.
void UpdateCaches(LookupResult* lookup,
- State state,
Handle<Object> object,
Handle<String> name);
@@ -197,7 +200,7 @@
public:
LoadIC() : IC(NO_EXTRA_FRAME) { ASSERT(target()->is_load_stub()); }
- Object* Load(State state, Handle<Object> object, Handle<String> name);
+ Object* Load(Handle<Object> object, Handle<String> name);
// Code generator routines.
static void GenerateInitialize(MacroAssembler* masm);
@@ -219,7 +222,6 @@
// Update the inline cache and the global stub cache based on the
// lookup result.
void UpdateCaches(LookupResult* lookup,
- State state,
Handle<Object> object,
Handle<String> name);
@@ -243,7 +245,7 @@
public:
KeyedLoadIC() : IC(NO_EXTRA_FRAME) { ASSERT(target()->is_keyed_load_stub()); }
- Object* Load(State state, Handle<Object> object, Handle<Object> key);
+ Object* Load(Handle<Object> object, Handle<Object> key);
// Code generator routines.
static void GenerateMiss(MacroAssembler* masm);
@@ -256,7 +258,6 @@
// Update the inline cache.
void UpdateCaches(LookupResult* lookup,
- State state,
Handle<Object> object,
Handle<String> name);
@@ -283,8 +284,7 @@
public:
StoreIC() : IC(NO_EXTRA_FRAME) { ASSERT(target()->is_store_stub()); }
- Object* Store(State state,
- Handle<Object> object,
+ Object* Store(Handle<Object> object,
Handle<String> name,
Handle<Object> value);
@@ -299,7 +299,7 @@
// Update the inline cache and the global stub cache based on the
// lookup result.
void UpdateCaches(LookupResult* lookup,
- State state, Handle<JSObject> receiver,
+ Handle<JSObject> receiver,
Handle<String> name,
Handle<Object> value);
@@ -320,8 +320,7 @@
public:
KeyedStoreIC() : IC(NO_EXTRA_FRAME) { }
- Object* Store(State state,
- Handle<Object> object,
+ Object* Store(Handle<Object> object,
Handle<Object> name,
Handle<Object> value);
@@ -335,7 +334,6 @@
// Update the inline cache.
void UpdateCaches(LookupResult* lookup,
- State state,
Handle<JSObject> receiver,
Handle<String> name,
Handle<Object> value);
« no previous file with comments | « no previous file | src/ic.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698