| Index: src/ic.h
|
| diff --git a/src/ic.h b/src/ic.h
|
| index e70cb82c96d59e132ce3994d5f099fc0c183cdad..146b26b28306b8192b3092615c40e2169d2156c8 100644
|
| --- a/src/ic.h
|
| +++ b/src/ic.h
|
| @@ -96,8 +96,14 @@ class IC {
|
|
|
| // Compute the current IC state based on the target stub, receiver and name.
|
| void UpdateState(Handle<Object> receiver, Handle<Object> name);
|
| - void MarkMonomorphicPrototypeFailure() {
|
| - state_ = MONOMORPHIC_PROTOTYPE_FAILURE;
|
| +
|
| + bool IsNameCompatibleWithMonomorphicPrototypeFailure(Handle<Object> name);
|
| + bool TryMarkMonomorphicPrototypeFailure(Handle<Object> name) {
|
| + if (IsNameCompatibleWithMonomorphicPrototypeFailure(name)) {
|
| + state_ = MONOMORPHIC_PROTOTYPE_FAILURE;
|
| + return true;
|
| + }
|
| + return false;
|
| }
|
|
|
| // Clear the inline cache to initial state.
|
|
|