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 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
671 __ subsd(result, double_scratch); | 671 __ subsd(result, double_scratch); |
672 __ addsd(result, Operand(kScratchRegister, 8 * kDoubleSize)); | 672 __ addsd(result, Operand(kScratchRegister, 8 * kDoubleSize)); |
673 __ mulsd(result, input); | 673 __ mulsd(result, input); |
674 | 674 |
675 __ bind(&done); | 675 __ bind(&done); |
676 } | 676 } |
677 | 677 |
678 #undef __ | 678 #undef __ |
679 | 679 |
680 | 680 |
681 static const int kNoCodeAgeSequenceLength = 6; | |
682 | |
683 static byte* GetNoCodeAgeSequence(uint32_t* length) { | 681 static byte* GetNoCodeAgeSequence(uint32_t* length) { |
684 static bool initialized = false; | 682 static bool initialized = false; |
685 static byte sequence[kNoCodeAgeSequenceLength]; | 683 static byte sequence[kNoCodeAgeSequenceLength]; |
686 *length = kNoCodeAgeSequenceLength; | 684 *length = kNoCodeAgeSequenceLength; |
687 if (!initialized) { | 685 if (!initialized) { |
688 // The sequence of instructions that is patched out for aging code is the | 686 // The sequence of instructions that is patched out for aging code is the |
689 // following boilerplate stack-building prologue that is found both in | 687 // following boilerplate stack-building prologue that is found both in |
690 // FUNCTION and OPTIMIZED_FUNCTION code: | 688 // FUNCTION and OPTIMIZED_FUNCTION code: |
691 CodePatcher patcher(sequence, kNoCodeAgeSequenceLength); | 689 CodePatcher patcher(sequence, kNoCodeAgeSequenceLength); |
692 patcher.masm()->push(rbp); | 690 patcher.masm()->push(rbp); |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
763 // argument_count_reg_ * times_pointer_size + (receiver - 1) * kPointerSize. | 761 // argument_count_reg_ * times_pointer_size + (receiver - 1) * kPointerSize. |
764 return Operand(base_reg_, argument_count_reg_, times_pointer_size, | 762 return Operand(base_reg_, argument_count_reg_, times_pointer_size, |
765 displacement_to_last_argument + (receiver - 1 - index) * kPointerSize); | 763 displacement_to_last_argument + (receiver - 1 - index) * kPointerSize); |
766 } | 764 } |
767 } | 765 } |
768 | 766 |
769 | 767 |
770 } } // namespace v8::internal | 768 } } // namespace v8::internal |
771 | 769 |
772 #endif // V8_TARGET_ARCH_X64 | 770 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |