| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #if V8_TARGET_ARCH_X87 | 5 #if V8_TARGET_ARCH_X87 |
| 6 | 6 |
| 7 #include "src/ic/handler-compiler.h" | 7 #include "src/ic/handler-compiler.h" |
| 8 | 8 |
| 9 #include "src/api-arguments.h" | 9 #include "src/api-arguments.h" |
| 10 #include "src/field-type.h" | 10 #include "src/field-type.h" |
| (...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 475 // checks are allowed in stubs. | 475 // checks are allowed in stubs. |
| 476 DCHECK(current_map->IsJSGlobalProxyMap() || | 476 DCHECK(current_map->IsJSGlobalProxyMap() || |
| 477 !current_map->is_access_check_needed()); | 477 !current_map->is_access_check_needed()); |
| 478 | 478 |
| 479 prototype = handle(JSObject::cast(current_map->prototype())); | 479 prototype = handle(JSObject::cast(current_map->prototype())); |
| 480 if (current_map->IsJSGlobalObjectMap()) { | 480 if (current_map->IsJSGlobalObjectMap()) { |
| 481 GenerateCheckPropertyCell(masm(), Handle<JSGlobalObject>::cast(current), | 481 GenerateCheckPropertyCell(masm(), Handle<JSGlobalObject>::cast(current), |
| 482 name, scratch2, miss); | 482 name, scratch2, miss); |
| 483 } else if (current_map->is_dictionary_map()) { | 483 } else if (current_map->is_dictionary_map()) { |
| 484 DCHECK(!current_map->IsJSGlobalProxyMap()); // Proxy maps are fast. | 484 DCHECK(!current_map->IsJSGlobalProxyMap()); // Proxy maps are fast. |
| 485 if (!name->IsUniqueName()) { | 485 DCHECK(name->IsUniqueName()); |
| 486 DCHECK(name->IsString()); | |
| 487 name = factory()->InternalizeString(Handle<String>::cast(name)); | |
| 488 } | |
| 489 DCHECK(current.is_null() || | 486 DCHECK(current.is_null() || |
| 490 current->property_dictionary()->FindEntry(name) == | 487 current->property_dictionary()->FindEntry(name) == |
| 491 NameDictionary::kNotFound); | 488 NameDictionary::kNotFound); |
| 492 | 489 |
| 493 if (depth > 1) { | 490 if (depth > 1) { |
| 494 Handle<WeakCell> weak_cell = | 491 Handle<WeakCell> weak_cell = |
| 495 Map::GetOrCreatePrototypeWeakCell(current, isolate()); | 492 Map::GetOrCreatePrototypeWeakCell(current, isolate()); |
| 496 __ LoadWeakValue(reg, weak_cell, miss); | 493 __ LoadWeakValue(reg, weak_cell, miss); |
| 497 } | 494 } |
| 498 GenerateDictionaryNegativeLookup(masm(), miss, reg, name, scratch1, | 495 GenerateDictionaryNegativeLookup(masm(), miss, reg, name, scratch1, |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 719 // Return the generated code. | 716 // Return the generated code. |
| 720 return GetCode(kind(), name); | 717 return GetCode(kind(), name); |
| 721 } | 718 } |
| 722 | 719 |
| 723 | 720 |
| 724 #undef __ | 721 #undef __ |
| 725 } // namespace internal | 722 } // namespace internal |
| 726 } // namespace v8 | 723 } // namespace v8 |
| 727 | 724 |
| 728 #endif // V8_TARGET_ARCH_X87 | 725 #endif // V8_TARGET_ARCH_X87 |
| OLD | NEW |