OLD | NEW |
---|---|
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
787 // Generates the fast case code. On the fallthrough path |result| | 787 // Generates the fast case code. On the fallthrough path |result| |
788 // register contains the result. | 788 // register contains the result. |
789 void GenerateFast(MacroAssembler* masm); | 789 void GenerateFast(MacroAssembler* masm); |
790 | 790 |
791 // Generates the slow case code. Must not be naturally | 791 // Generates the slow case code. Must not be naturally |
792 // reachable. Expected to be put after a ret instruction (e.g., in | 792 // reachable. Expected to be put after a ret instruction (e.g., in |
793 // deferred code). Always jumps back to the fast case. | 793 // deferred code). Always jumps back to the fast case. |
794 void GenerateSlow(MacroAssembler* masm, | 794 void GenerateSlow(MacroAssembler* masm, |
795 const RuntimeCallHelper& call_helper); | 795 const RuntimeCallHelper& call_helper); |
796 | 796 |
797 // Generates the code for handling different string types and loading the | |
798 // result character. We expect |index| to be not smi-tagged. | |
Lasse Reichstein
2011/11/17 13:40:18
"not smi-tagged" -> "untagged".
| |
799 static void GenerateCharLoad(MacroAssembler* masm, | |
800 Factory* factory, | |
801 Register string, | |
802 Register index, | |
803 Register result, | |
804 Label* call_runtime); | |
805 | |
797 private: | 806 private: |
798 Register object_; | 807 Register object_; |
799 Register index_; | 808 Register index_; |
800 Register result_; | 809 Register result_; |
801 | 810 |
802 Label* receiver_not_string_; | 811 Label* receiver_not_string_; |
803 Label* index_not_number_; | 812 Label* index_not_number_; |
804 Label* index_out_of_range_; | 813 Label* index_out_of_range_; |
805 | 814 |
806 StringIndexFlags index_flags_; | 815 StringIndexFlags index_flags_; |
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1062 int MinorKey() { return 0; } | 1071 int MinorKey() { return 0; } |
1063 | 1072 |
1064 void Generate(MacroAssembler* masm); | 1073 void Generate(MacroAssembler* masm); |
1065 | 1074 |
1066 DISALLOW_COPY_AND_ASSIGN(StoreArrayLiteralElementStub); | 1075 DISALLOW_COPY_AND_ASSIGN(StoreArrayLiteralElementStub); |
1067 }; | 1076 }; |
1068 | 1077 |
1069 } } // namespace v8::internal | 1078 } } // namespace v8::internal |
1070 | 1079 |
1071 #endif // V8_CODE_STUBS_H_ | 1080 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |