| 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 449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 460 // Fix up last fixup on linked list. | 460 // Fix up last fixup on linked list. |
| 461 int last_imm32 = pos - (current + sizeof(int32_t)); | 461 int last_imm32 = pos - (current + sizeof(int32_t)); |
| 462 long_at_put(current, last_imm32); | 462 long_at_put(current, last_imm32); |
| 463 } | 463 } |
| 464 while (L->is_near_linked()) { | 464 while (L->is_near_linked()) { |
| 465 int fixup_pos = L->near_link_pos(); | 465 int fixup_pos = L->near_link_pos(); |
| 466 int offset_to_next = | 466 int offset_to_next = |
| 467 static_cast<int>(*reinterpret_cast<int8_t*>(addr_at(fixup_pos))); | 467 static_cast<int>(*reinterpret_cast<int8_t*>(addr_at(fixup_pos))); |
| 468 ASSERT(offset_to_next <= 0); | 468 ASSERT(offset_to_next <= 0); |
| 469 int disp = pos - (fixup_pos + sizeof(int8_t)); | 469 int disp = pos - (fixup_pos + sizeof(int8_t)); |
| 470 ASSERT(is_int8(disp)); | 470 CHECK(is_int8(disp)); |
| 471 set_byte_at(fixup_pos, disp); | 471 set_byte_at(fixup_pos, disp); |
| 472 if (offset_to_next < 0) { | 472 if (offset_to_next < 0) { |
| 473 L->link_to(fixup_pos + offset_to_next, Label::kNear); | 473 L->link_to(fixup_pos + offset_to_next, Label::kNear); |
| 474 } else { | 474 } else { |
| 475 L->UnuseNear(); | 475 L->UnuseNear(); |
| 476 } | 476 } |
| 477 } | 477 } |
| 478 L->bind_to(pos); | 478 L->bind_to(pos); |
| 479 } | 479 } |
| 480 | 480 |
| (...skipping 2560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3041 bool RelocInfo::IsCodedSpecially() { | 3041 bool RelocInfo::IsCodedSpecially() { |
| 3042 // The deserializer needs to know whether a pointer is specially coded. Being | 3042 // The deserializer needs to know whether a pointer is specially coded. Being |
| 3043 // specially coded on x64 means that it is a relative 32 bit address, as used | 3043 // specially coded on x64 means that it is a relative 32 bit address, as used |
| 3044 // by branch instructions. | 3044 // by branch instructions. |
| 3045 return (1 << rmode_) & kApplyMask; | 3045 return (1 << rmode_) & kApplyMask; |
| 3046 } | 3046 } |
| 3047 | 3047 |
| 3048 } } // namespace v8::internal | 3048 } } // namespace v8::internal |
| 3049 | 3049 |
| 3050 #endif // V8_TARGET_ARCH_X64 | 3050 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |