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 5618 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5629 __ cmp(tmp, Operand(tmp2)); | 5629 __ cmp(tmp, Operand(tmp2)); |
5630 __ b(ne, &done); | 5630 __ b(ne, &done); |
5631 __ ldr(tmp, FieldMemOperand(left, JSRegExp::kDataOffset)); | 5631 __ ldr(tmp, FieldMemOperand(left, JSRegExp::kDataOffset)); |
5632 __ ldr(tmp2, FieldMemOperand(right, JSRegExp::kDataOffset)); | 5632 __ ldr(tmp2, FieldMemOperand(right, JSRegExp::kDataOffset)); |
5633 __ cmp(tmp, tmp2); | 5633 __ cmp(tmp, tmp2); |
5634 __ bind(&done); | 5634 __ bind(&done); |
5635 cc_reg_ = eq; | 5635 cc_reg_ = eq; |
5636 } | 5636 } |
5637 | 5637 |
5638 | 5638 |
| 5639 void CodeGenerator::GenerateHasCachedArrayIndex(ZoneList<Expression*>* args) { |
| 5640 ASSERT(args->length() == 1); |
| 5641 Load(args->at(0)); |
| 5642 Register value = frame_->PopToRegister(); |
| 5643 Register tmp = frame_->scratch0(); |
| 5644 __ ldr(tmp, FieldMemOperand(value, String::kHashFieldOffset)); |
| 5645 __ tst(tmp, Operand(String::kContainsCachedArrayIndexMask)); |
| 5646 cc_reg_ = eq; |
| 5647 } |
| 5648 |
| 5649 |
| 5650 void CodeGenerator::GenerateGetCachedArrayIndex(ZoneList<Expression*>* args) { |
| 5651 ASSERT(args->length() == 1); |
| 5652 Load(args->at(0)); |
| 5653 Register value = frame_->PopToRegister(); |
| 5654 |
| 5655 __ ldr(value, FieldMemOperand(value, String::kHashFieldOffset)); |
| 5656 __ IndexFromHash(value, value); |
| 5657 frame_->EmitPush(value); |
| 5658 } |
| 5659 |
5639 | 5660 |
5640 void CodeGenerator::VisitCallRuntime(CallRuntime* node) { | 5661 void CodeGenerator::VisitCallRuntime(CallRuntime* node) { |
5641 #ifdef DEBUG | 5662 #ifdef DEBUG |
5642 int original_height = frame_->height(); | 5663 int original_height = frame_->height(); |
5643 #endif | 5664 #endif |
5644 if (CheckForInlineRuntimeCall(node)) { | 5665 if (CheckForInlineRuntimeCall(node)) { |
5645 ASSERT((has_cc() && frame_->height() == original_height) || | 5666 ASSERT((has_cc() && frame_->height() == original_height) || |
5646 (!has_cc() && frame_->height() == original_height + 1)); | 5667 (!has_cc() && frame_->height() == original_height + 1)); |
5647 return; | 5668 return; |
5648 } | 5669 } |
(...skipping 1434 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7083 BinaryOpIC::GetName(runtime_operands_type_)); | 7104 BinaryOpIC::GetName(runtime_operands_type_)); |
7084 return name_; | 7105 return name_; |
7085 } | 7106 } |
7086 | 7107 |
7087 | 7108 |
7088 #undef __ | 7109 #undef __ |
7089 | 7110 |
7090 } } // namespace v8::internal | 7111 } } // namespace v8::internal |
7091 | 7112 |
7092 #endif // V8_TARGET_ARCH_ARM | 7113 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |