diff options
Diffstat (limited to 'compiler/optimizing/code_generator_mips.cc')
-rw-r--r-- | compiler/optimizing/code_generator_mips.cc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/compiler/optimizing/code_generator_mips.cc b/compiler/optimizing/code_generator_mips.cc index 855da2b18f..eb122b7781 100644 --- a/compiler/optimizing/code_generator_mips.cc +++ b/compiler/optimizing/code_generator_mips.cc @@ -1281,7 +1281,9 @@ void CodeGeneratorMIPS::GenerateFrameEntry() { __ Bind(&frame_entry_label_); if (GetCompilerOptions().CountHotnessInCompiledCode()) { - LOG(WARNING) << "Unimplemented hotness update in mips backend"; + __ Lhu(TMP, kMethodRegisterArgument, ArtMethod::HotnessCountOffset().Int32Value()); + __ Addiu(TMP, TMP, 1); + __ Sh(TMP, kMethodRegisterArgument, ArtMethod::HotnessCountOffset().Int32Value()); } bool do_overflow_check = @@ -4027,6 +4029,12 @@ void InstructionCodeGeneratorMIPS::HandleGoto(HInstruction* got, HBasicBlock* su HLoopInformation* info = block->GetLoopInformation(); if (info != nullptr && info->IsBackEdge(*block) && info->HasSuspendCheck()) { + if (codegen_->GetCompilerOptions().CountHotnessInCompiledCode()) { + __ Lw(AT, SP, kCurrentMethodStackOffset); + __ Lhu(TMP, AT, ArtMethod::HotnessCountOffset().Int32Value()); + __ Addiu(TMP, TMP, 1); + __ Sh(TMP, AT, ArtMethod::HotnessCountOffset().Int32Value()); + } GenerateSuspendCheck(info->GetSuspendCheck(), successor); return; } |