| 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 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 | 461 |
| 462 // Hit on nth entry. | 462 // Hit on nth entry. |
| 463 for (int i = kEntriesPerBucket - 1; i >= 0; i--) { | 463 for (int i = kEntriesPerBucket - 1; i >= 0; i--) { |
| 464 __ bind(&hit_on_nth_entry[i]); | 464 __ bind(&hit_on_nth_entry[i]); |
| 465 if (i != 0) { | 465 if (i != 0) { |
| 466 __ addl(rcx, Immediate(i)); | 466 __ addl(rcx, Immediate(i)); |
| 467 } | 467 } |
| 468 __ LoadAddress(kScratchRegister, cache_field_offsets); | 468 __ LoadAddress(kScratchRegister, cache_field_offsets); |
| 469 __ movl(rdi, Operand(kScratchRegister, rcx, times_4, 0)); | 469 __ movl(rdi, Operand(kScratchRegister, rcx, times_4, 0)); |
| 470 __ movzxbq(rcx, FieldOperand(rbx, Map::kInObjectPropertiesOffset)); | 470 __ movzxbq(rcx, FieldOperand(rbx, Map::kInObjectPropertiesOffset)); |
| 471 __ subq(rdi, rcx); | 471 __ subp(rdi, rcx); |
| 472 __ j(above_equal, &property_array_property); | 472 __ j(above_equal, &property_array_property); |
| 473 if (i != 0) { | 473 if (i != 0) { |
| 474 __ jmp(&load_in_object_property); | 474 __ jmp(&load_in_object_property); |
| 475 } | 475 } |
| 476 } | 476 } |
| 477 | 477 |
| 478 // Load in-object property. | 478 // Load in-object property. |
| 479 __ bind(&load_in_object_property); | 479 __ bind(&load_in_object_property); |
| 480 __ movzxbq(rcx, FieldOperand(rbx, Map::kInstanceSizeOffset)); | 480 __ movzxbq(rcx, FieldOperand(rbx, Map::kInstanceSizeOffset)); |
| 481 __ addq(rcx, rdi); | 481 __ addp(rcx, rdi); |
| 482 __ movp(rax, FieldOperand(rdx, rcx, times_pointer_size, 0)); | 482 __ movp(rax, FieldOperand(rdx, rcx, times_pointer_size, 0)); |
| 483 __ IncrementCounter(counters->keyed_load_generic_lookup_cache(), 1); | 483 __ IncrementCounter(counters->keyed_load_generic_lookup_cache(), 1); |
| 484 __ ret(0); | 484 __ ret(0); |
| 485 | 485 |
| 486 // Load property array property. | 486 // Load property array property. |
| 487 __ bind(&property_array_property); | 487 __ bind(&property_array_property); |
| 488 __ movp(rax, FieldOperand(rdx, JSObject::kPropertiesOffset)); | 488 __ movp(rax, FieldOperand(rdx, JSObject::kPropertiesOffset)); |
| 489 __ movp(rax, FieldOperand(rax, rdi, times_pointer_size, | 489 __ movp(rax, FieldOperand(rax, rdi, times_pointer_size, |
| 490 FixedArray::kHeaderSize)); | 490 FixedArray::kHeaderSize)); |
| 491 __ IncrementCounter(counters->keyed_load_generic_lookup_cache(), 1); | 491 __ IncrementCounter(counters->keyed_load_generic_lookup_cache(), 1); |
| (...skipping 829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1321 Condition cc = (check == ENABLE_INLINED_SMI_CHECK) | 1321 Condition cc = (check == ENABLE_INLINED_SMI_CHECK) |
| 1322 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero) | 1322 ? (*jmp_address == Assembler::kJncShortOpcode ? not_zero : zero) |
| 1323 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry); | 1323 : (*jmp_address == Assembler::kJnzShortOpcode ? not_carry : carry); |
| 1324 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); | 1324 *jmp_address = static_cast<byte>(Assembler::kJccShortPrefix | cc); |
| 1325 } | 1325 } |
| 1326 | 1326 |
| 1327 | 1327 |
| 1328 } } // namespace v8::internal | 1328 } } // namespace v8::internal |
| 1329 | 1329 |
| 1330 #endif // V8_TARGET_ARCH_X64 | 1330 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |