Index: src/arm/codegen-arm.cc |
diff --git a/src/arm/codegen-arm.cc b/src/arm/codegen-arm.cc |
index 70ff244649cc313f8110e6cb21341a99099b5628..d7fd9a4902228bbbc04d323597bf73e54b8776e2 100644 |
--- a/src/arm/codegen-arm.cc |
+++ b/src/arm/codegen-arm.cc |
@@ -5496,73 +5496,6 @@ void CodeGenerator::GenerateRegExpConstructResult(ZoneList<Expression*>* args) { |
} |
-void CodeGenerator::GenerateRegExpCloneResult(ZoneList<Expression*>* args) { |
- ASSERT_EQ(1, args->length()); |
- |
- Load(args->at(0)); |
- frame_->PopToR0(); |
- { |
- VirtualFrame::SpilledScope spilled_scope(frame_); |
- |
- Label done; |
- Label call_runtime; |
- __ BranchOnSmi(r0, &done); |
- |
- // Load JSRegExp map into r1. Check that argument object has this map. |
- // Arguments to this function should be results of calling RegExp exec, |
- // which is either an unmodified JSRegExpResult or null. Anything not having |
- // the unmodified JSRegExpResult map is returned unmodified. |
- // This also ensures that elements are fast. |
- |
- __ ldr(r1, ContextOperand(cp, Context::GLOBAL_INDEX)); |
- __ ldr(r1, FieldMemOperand(r1, GlobalObject::kGlobalContextOffset)); |
- __ ldr(r1, ContextOperand(r1, Context::REGEXP_RESULT_MAP_INDEX)); |
- __ ldr(ip, FieldMemOperand(r0, HeapObject::kMapOffset)); |
- __ cmp(r1, Operand(ip)); |
- __ b(ne, &done); |
- |
- if (FLAG_debug_code) { |
- __ LoadRoot(r2, Heap::kEmptyFixedArrayRootIndex); |
- __ ldr(ip, FieldMemOperand(r0, JSObject::kPropertiesOffset)); |
- __ cmp(ip, r2); |
- __ Check(eq, "JSRegExpResult: default map but non-empty properties."); |
- } |
- |
- // All set, copy the contents to a new object. |
- __ AllocateInNewSpace(JSRegExpResult::kSize, |
- r2, |
- r3, |
- r4, |
- &call_runtime, |
- NO_ALLOCATION_FLAGS); |
- // Store RegExpResult map as map of allocated object. |
- ASSERT(JSRegExpResult::kSize == 6 * kPointerSize); |
- // Copy all fields (map is already in r1) from (untagged) r0 to r2. |
- // Change map of elements array (ends up in r4) to be a FixedCOWArray. |
- __ bic(r0, r0, Operand(kHeapObjectTagMask)); |
- __ ldm(ib, r0, r3.bit() | r4.bit() | r5.bit() | r6.bit() | r7.bit()); |
- __ stm(ia, r2, |
- r1.bit() | r3.bit() | r4.bit() | r5.bit() | r6.bit() | r7.bit()); |
- ASSERT(JSRegExp::kElementsOffset == 2 * kPointerSize); |
- // Check whether elements array is empty fixed array, and otherwise make |
- // it copy-on-write (it never should be empty unless someone is messing |
- // with the arguments to the runtime function). |
- __ LoadRoot(ip, Heap::kEmptyFixedArrayRootIndex); |
- __ add(r0, r2, Operand(kHeapObjectTag)); // Tag result and move it to r0. |
- __ cmp(r4, ip); |
- __ b(eq, &done); |
- __ LoadRoot(ip, Heap::kFixedCOWArrayMapRootIndex); |
- __ str(ip, FieldMemOperand(r4, HeapObject::kMapOffset)); |
- __ b(&done); |
- __ bind(&call_runtime); |
- __ push(r0); |
- __ CallRuntime(Runtime::kRegExpCloneResult, 1); |
- __ bind(&done); |
- } |
- frame_->EmitPush(r0); |
-} |
- |
- |
class DeferredSearchCache: public DeferredCode { |
public: |
DeferredSearchCache(Register dst, Register cache, Register key) |