Index: src/arm/code-stubs-arm.cc |
diff --git a/src/arm/code-stubs-arm.cc b/src/arm/code-stubs-arm.cc |
index 45c0c5f352fcf3a815deb9c3dc97efc6e66c74f7..a5a34a4b9771b643d2d4b46e0faa72cf57356444 100644 |
--- a/src/arm/code-stubs-arm.cc |
+++ b/src/arm/code-stubs-arm.cc |
@@ -2740,6 +2740,17 @@ void CallICStub::Generate(MacroAssembler* masm) { |
__ add(r4, r2, Operand::PointerOffsetFromSmiKey(r3)); |
__ LoadRoot(ip, Heap::kmegamorphic_symbolRootIndex); |
__ str(ip, FieldMemOperand(r4, FixedArray::kHeaderSize)); |
+ // We have to update statistics for runtime profiling. |
+ const int with_types_offset = |
+ FixedArray::OffsetOfElementAt(TypeFeedbackVector::kWithTypesIndex); |
+ __ ldr(r4, FieldMemOperand(r2, with_types_offset)); |
+ __ sub(r4, r4, Operand(Smi::FromInt(1))); |
+ __ str(r4, FieldMemOperand(r2, with_types_offset)); |
+ const int generic_offset = |
+ FixedArray::OffsetOfElementAt(TypeFeedbackVector::kGenericCountIndex); |
+ __ ldr(r4, FieldMemOperand(r2, generic_offset)); |
+ __ add(r4, r4, Operand(Smi::FromInt(1))); |
+ __ str(r4, FieldMemOperand(r2, generic_offset)); |
__ jmp(&slow_start); |
} |