| Index: src/stub-cache.h
|
| diff --git a/src/stub-cache.h b/src/stub-cache.h
|
| index f544ec411bf0f0e1d2df415bf13460e8b8153f54..737b069599367a73eb6305ea5657e1d4307cd304 100644
|
| --- a/src/stub-cache.h
|
| +++ b/src/stub-cache.h
|
| @@ -483,6 +483,20 @@ class StubCompiler BASE_EMBEDDED {
|
| Register scratch2,
|
| Handle<Name> name,
|
| Label* miss,
|
| + PrototypeCheckType check = CHECK_ALL_MAPS) {
|
| + return CheckPrototypes(type, object_reg, holder, holder_reg, scratch1,
|
| + scratch2, name, kInvalidProtoDepth, miss, check);
|
| + }
|
| +
|
| + Register CheckPrototypes(Handle<HeapType> type,
|
| + Register object_reg,
|
| + Handle<JSObject> holder,
|
| + Register holder_reg,
|
| + Register scratch1,
|
| + Register scratch2,
|
| + Handle<Name> name,
|
| + int save_at_depth,
|
| + Label* miss,
|
| PrototypeCheckType check = CHECK_ALL_MAPS);
|
|
|
| void GenerateBooleanCheck(Register object, Label* miss);
|
| @@ -1014,19 +1028,10 @@ class CallOptimization BASE_EMBEDDED {
|
| return api_call_info_;
|
| }
|
|
|
| - enum HolderLookup {
|
| - kHolderNotFound,
|
| - kHolderIsReceiver,
|
| - kHolderIsPrototypeOfMap
|
| - };
|
| - // Returns a map whose prototype has the expected type in the
|
| - // prototype chain between the two arguments
|
| - // null will be returned if the first argument has that property
|
| - // lookup will be set accordingly
|
| - Handle<Map> LookupHolderOfExpectedType(Handle<JSObject> receiver,
|
| - Handle<JSObject> object,
|
| - Handle<JSObject> holder,
|
| - HolderLookup* holder_lookup) const;
|
| + // Returns the depth of the object having the expected type in the
|
| + // prototype chain between the two arguments.
|
| + int GetPrototypeDepthOfExpectedType(Handle<JSObject> object,
|
| + Handle<JSObject> holder) const;
|
|
|
| bool IsCompatibleReceiver(Object* receiver) {
|
| ASSERT(is_simple_api_call());
|
|
|