| Index: src/objects-inl.h
|
| ===================================================================
|
| --- src/objects-inl.h (revision 5007)
|
| +++ src/objects-inl.h (working copy)
|
| @@ -2263,13 +2263,15 @@
|
| InLoopFlag in_loop,
|
| InlineCacheState ic_state,
|
| PropertyType type,
|
| - int argc) {
|
| + int argc,
|
| + InlineCacheHolderFlag holder) {
|
| // Compute the bit mask.
|
| int bits = kind << kFlagsKindShift;
|
| if (in_loop) bits |= kFlagsICInLoopMask;
|
| bits |= ic_state << kFlagsICStateShift;
|
| bits |= type << kFlagsTypeShift;
|
| bits |= argc << kFlagsArgumentsCountShift;
|
| + if (holder == PROTOTYPE_MAP) bits |= kFlagsCacheInPrototypeMapMask;
|
| // Cast to flags and validate result before returning it.
|
| Flags result = static_cast<Flags>(bits);
|
| ASSERT(ExtractKindFromFlags(result) == kind);
|
| @@ -2283,9 +2285,10 @@
|
|
|
| Code::Flags Code::ComputeMonomorphicFlags(Kind kind,
|
| PropertyType type,
|
| + InlineCacheHolderFlag holder,
|
| InLoopFlag in_loop,
|
| int argc) {
|
| - return ComputeFlags(kind, in_loop, MONOMORPHIC, type, argc);
|
| + return ComputeFlags(kind, in_loop, MONOMORPHIC, type, argc, holder);
|
| }
|
|
|
|
|
| @@ -2318,6 +2321,12 @@
|
| }
|
|
|
|
|
| +InlineCacheHolderFlag Code::ExtractCacheHolderFromFlags(Flags flags) {
|
| + int bits = (flags & kFlagsCacheInPrototypeMapMask);
|
| + return bits != 0 ? PROTOTYPE_MAP : OWN_MAP;
|
| +}
|
| +
|
| +
|
| Code::Flags Code::RemoveTypeFromFlags(Flags flags) {
|
| int bits = flags & ~kFlagsTypeMask;
|
| return static_cast<Flags>(bits);
|
|
|