OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 755 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
766 bool ascii); | 766 bool ascii); |
767 | 767 |
768 // Generate code for copying characters using the rep movs instruction. | 768 // Generate code for copying characters using the rep movs instruction. |
769 // Copies rcx characters from rsi to rdi. Copying of overlapping regions is | 769 // Copies rcx characters from rsi to rdi. Copying of overlapping regions is |
770 // not supported. | 770 // not supported. |
771 void GenerateCopyCharactersREP(MacroAssembler* masm, | 771 void GenerateCopyCharactersREP(MacroAssembler* masm, |
772 Register dest, // Must be rdi. | 772 Register dest, // Must be rdi. |
773 Register src, // Must be rsi. | 773 Register src, // Must be rsi. |
774 Register count, // Must be rcx. | 774 Register count, // Must be rcx. |
775 bool ascii); | 775 bool ascii); |
| 776 |
| 777 |
| 778 // Probe the symbol table for a two character string. If the string is |
| 779 // not found by probing a jump to the label not_found is performed. This jump |
| 780 // does not guarantee that the string is not in the symbol table. If the |
| 781 // string is found the code falls through with the string in register rax. |
| 782 void GenerateTwoCharacterSymbolTableProbe(MacroAssembler* masm, |
| 783 Register c1, |
| 784 Register c2, |
| 785 Register scratch1, |
| 786 Register scratch2, |
| 787 Register scratch3, |
| 788 Register scratch4, |
| 789 Label* not_found); |
| 790 |
| 791 // Generate string hash. |
| 792 void GenerateHashInit(MacroAssembler* masm, |
| 793 Register hash, |
| 794 Register character, |
| 795 Register scratch); |
| 796 void GenerateHashAddCharacter(MacroAssembler* masm, |
| 797 Register hash, |
| 798 Register character, |
| 799 Register scratch); |
| 800 void GenerateHashGetHash(MacroAssembler* masm, |
| 801 Register hash, |
| 802 Register scratch); |
776 }; | 803 }; |
777 | 804 |
778 | 805 |
779 // Flag that indicates how to generate code for the stub StringAddStub. | 806 // Flag that indicates how to generate code for the stub StringAddStub. |
780 enum StringAddFlags { | 807 enum StringAddFlags { |
781 NO_STRING_ADD_FLAGS = 0, | 808 NO_STRING_ADD_FLAGS = 0, |
782 NO_STRING_CHECK_IN_STUB = 1 << 0 // Omit string check in stub. | 809 NO_STRING_CHECK_IN_STUB = 1 << 0 // Omit string check in stub. |
783 }; | 810 }; |
784 | 811 |
785 | 812 |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
830 Major MajorKey() { return StringCompare; } | 857 Major MajorKey() { return StringCompare; } |
831 int MinorKey() { return 0; } | 858 int MinorKey() { return 0; } |
832 | 859 |
833 void Generate(MacroAssembler* masm); | 860 void Generate(MacroAssembler* masm); |
834 }; | 861 }; |
835 | 862 |
836 | 863 |
837 } } // namespace v8::internal | 864 } } // namespace v8::internal |
838 | 865 |
839 #endif // V8_X64_CODEGEN_X64_H_ | 866 #endif // V8_X64_CODEGEN_X64_H_ |
OLD | NEW |