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 1091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1102 void KeyedLoadIC::GenerateString(MacroAssembler* masm) { | 1102 void KeyedLoadIC::GenerateString(MacroAssembler* masm) { |
1103 // ---------- S t a t e -------------- | 1103 // ---------- S t a t e -------------- |
1104 // -- lr : return address | 1104 // -- lr : return address |
1105 // -- r0 : key (index) | 1105 // -- r0 : key (index) |
1106 // -- r1 : receiver | 1106 // -- r1 : receiver |
1107 // ----------------------------------- | 1107 // ----------------------------------- |
1108 Label miss; | 1108 Label miss; |
1109 | 1109 |
1110 Register receiver = r1; | 1110 Register receiver = r1; |
1111 Register index = r0; | 1111 Register index = r0; |
1112 Register scratch1 = r2; | 1112 Register scratch = r3; |
1113 Register scratch2 = r3; | |
1114 Register result = r0; | 1113 Register result = r0; |
1115 | 1114 |
1116 StringCharAtGenerator char_at_generator(receiver, | 1115 StringCharAtGenerator char_at_generator(receiver, |
1117 index, | 1116 index, |
1118 scratch1, | 1117 scratch, |
1119 scratch2, | |
1120 result, | 1118 result, |
1121 &miss, // When not a string. | 1119 &miss, // When not a string. |
1122 &miss, // When not a number. | 1120 &miss, // When not a number. |
1123 &miss, // When index out of range. | 1121 &miss, // When index out of range. |
1124 STRING_INDEX_IS_ARRAY_INDEX); | 1122 STRING_INDEX_IS_ARRAY_INDEX); |
1125 char_at_generator.GenerateFast(masm); | 1123 char_at_generator.GenerateFast(masm); |
1126 __ Ret(); | 1124 __ Ret(); |
1127 | 1125 |
1128 StubRuntimeCallHelper call_helper; | 1126 StubRuntimeCallHelper call_helper; |
1129 char_at_generator.GenerateSlow(masm, call_helper); | 1127 char_at_generator.GenerateSlow(masm, call_helper); |
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1672 Register reg = Assembler::GetRn(instr_at_patch); | 1670 Register reg = Assembler::GetRn(instr_at_patch); |
1673 patcher.masm()->tst(reg, Operand(kSmiTagMask)); | 1671 patcher.masm()->tst(reg, Operand(kSmiTagMask)); |
1674 patcher.EmitCondition(eq); | 1672 patcher.EmitCondition(eq); |
1675 } | 1673 } |
1676 } | 1674 } |
1677 | 1675 |
1678 | 1676 |
1679 } } // namespace v8::internal | 1677 } } // namespace v8::internal |
1680 | 1678 |
1681 #endif // V8_TARGET_ARCH_ARM | 1679 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |