| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 183 Object* receiver, | 183 Object* receiver, |
| 184 Object* name) { | 184 Object* name) { |
| 185 InlineCacheHolderFlag cache_holder = | 185 InlineCacheHolderFlag cache_holder = |
| 186 Code::ExtractCacheHolderFromFlags(target->flags()); | 186 Code::ExtractCacheHolderFromFlags(target->flags()); |
| 187 | 187 |
| 188 Isolate* isolate = target->GetIsolate(); | 188 Isolate* isolate = target->GetIsolate(); |
| 189 if (cache_holder == OWN_MAP && !receiver->IsJSObject()) { | 189 if (cache_holder == OWN_MAP && !receiver->IsJSObject()) { |
| 190 // The stub was generated for JSObject but called for non-JSObject. | 190 // The stub was generated for JSObject but called for non-JSObject. |
| 191 // IC::GetCodeCacheHolder is not applicable. | 191 // IC::GetCodeCacheHolder is not applicable. |
| 192 return false; | 192 return false; |
| 193 } else if (cache_holder == DELEGATE_MAP && | 193 } else if (cache_holder == PROTOTYPE_MAP && |
| 194 receiver->GetPrototype(isolate)->IsNull()) { | 194 receiver->GetPrototype(isolate)->IsNull()) { |
| 195 // IC::GetCodeCacheHolder is not applicable. | 195 // IC::GetCodeCacheHolder is not applicable. |
| 196 return false; | 196 return false; |
| 197 } | 197 } |
| 198 Map* map = IC::GetCodeCacheHolder(isolate, receiver, cache_holder)->map(); | 198 Map* map = IC::GetCodeCacheHolder(isolate, receiver, cache_holder)->map(); |
| 199 | 199 |
| 200 // Decide whether the inline cache failed because of changes to the | 200 // Decide whether the inline cache failed because of changes to the |
| 201 // receiver itself or changes to one of its prototypes. | 201 // receiver itself or changes to one of its prototypes. |
| 202 // | 202 // |
| 203 // If there are changes to the receiver itself, the map of the | 203 // If there are changes to the receiver itself, the map of the |
| (...skipping 2572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2776 #undef ADDR | 2776 #undef ADDR |
| 2777 }; | 2777 }; |
| 2778 | 2778 |
| 2779 | 2779 |
| 2780 Address IC::AddressFromUtilityId(IC::UtilityId id) { | 2780 Address IC::AddressFromUtilityId(IC::UtilityId id) { |
| 2781 return IC_utilities[id]; | 2781 return IC_utilities[id]; |
| 2782 } | 2782 } |
| 2783 | 2783 |
| 2784 | 2784 |
| 2785 } } // namespace v8::internal | 2785 } } // namespace v8::internal |
| OLD | NEW |