Lines Matching full:instruction
111 BoundsCheckSlowPathMIPS64(HBoundsCheck* instruction,
114 : instruction_(instruction),
147 explicit DivZeroCheckSlowPathMIPS64(HDivZeroCheck* instruction) : instruction_(instruction) {}
208 // The instruction where this slow path is happening.
223 explicit LoadStringSlowPathMIPS64(HLoadString* instruction) : instruction_(instruction) {}
277 explicit SuspendCheckSlowPathMIPS64(HSuspendCheck* instruction,
279 : instruction_(instruction), successor_(successor) {}
316 TypeCheckSlowPathMIPS64(HInstruction* instruction,
320 : instruction_(instruction),
377 explicit DeoptimizationSlowPathMIPS64(HInstruction* instruction)
378 : instruction_(instruction) {}
745 // TODO: Can MOV.S/MOV.D be used here to save one instruction?
784 void CodeGeneratorMIPS64::Move(HInstruction* instruction,
787 LocationSummary* locations = instruction->GetLocations();
792 Primitive::Type type = instruction->GetType();
795 if (instruction->IsIntConstant()
796 || instruction->IsLongConstant()
797 || instruction->IsNullConstant()) {
801 if (instruction->IsNullConstant() || instruction->IsIntConstant()) {
802 __ LoadConst32(dst, GetInt32ValueOf(instruction->AsConstant()));
804 __ LoadConst64(dst, instruction->AsLongConstant()->GetValue());
810 __ LoadConst32(TMP, GetInt32ValueOf(instruction->AsConstant()));
813 __ LoadConst64(TMP, instruction->AsLongConstant()->GetValue());
817 } else if (instruction->IsTemporary()) {
818 Location temp_location = GetTemporaryLocation(instruction->AsTemporary());
820 } else if (instruction->IsLoadLocal()) {
821 uint32_t stack_slot = GetStackSlot(instruction->AsLoadLocal()->GetLocal());
828 DCHECK((instruction->GetNext() == move_for) || instruction->GetNext()->IsTemporary());
956 HInstruction* instruction,
962 RecordPcInfo(instruction, dex_pc, slow_path);
963 DCHECK(instruction->IsSuspendCheck()
964 || instruction->IsBoundsCheck()
965 || instruction->IsNullCheck()
966 || instruction->IsDivZeroCheck()
983 void InstructionCodeGeneratorMIPS64::GenerateSuspendCheck(HSuspendCheck* instruction,
986 new (GetGraph()->GetArena()) SuspendCheckSlowPathMIPS64(instruction, successor);
1009 void LocationsBuilderMIPS64::HandleBinaryOp(HBinaryOperation* instruction) {
1010 DCHECK_EQ(instruction->InputCount(), 2U);
1011 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
1012 Primitive::Type type = instruction->GetResultType();
1017 HInstruction* right = instruction->InputAt(1);
1021 if (instruction->IsAnd() || instruction->IsOr() || instruction->IsXor()) {
1023 } else if (instruction->IsAdd()) {
1026 DCHECK(instruction->IsSub());
1046 LOG(FATAL) << "Unexpected " << instruction->DebugName() << " type " << type;
1050 void InstructionCodeGeneratorMIPS64::HandleBinaryOp(HBinaryOperation* instruction) {
1051 Primitive::Type type = instruction->GetType();
1052 LocationSummary* locations = instruction->GetLocations();
1070 if (instruction->IsAnd()) {
1075 } else if (instruction->IsOr()) {
1080 } else if (instruction->IsXor()) {
1085 } else if (instruction->IsAdd()) {
1098 DCHECK(instruction->IsSub());
1118 if (instruction->IsAdd()) {
1123 } else if (instruction->IsSub()) {
1236 void LocationsBuilderMIPS64::VisitAdd(HAdd* instruction) {
1237 HandleBinaryOp(instruction);
1240 void InstructionCodeGeneratorMIPS64::VisitAdd(HAdd* instruction) {
1241 HandleBinaryOp(instruction);
1244 void LocationsBuilderMIPS64::VisitAnd(HAnd* instruction) {
1245 HandleBinaryOp(instruction);
1248 void InstructionCodeGeneratorMIPS64::VisitAnd(HAnd* instruction) {
1249 HandleBinaryOp(instruction);
1252 void LocationsBuilderMIPS64::VisitArrayGet(HArrayGet* instruction) {
1254 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kNoCall);
1256 locations->SetInAt(1, Location::RegisterOrConstant(instruction->InputAt(1)));
1257 if (Primitive::IsFloatingPointType(instruction->GetType())) {
1264 void InstructionCodeGeneratorMIPS64::VisitArrayGet(HArrayGet* instruction) {
1265 LocationSummary* locations = instruction->GetLocations();
1268 Primitive::Type type = instruction->GetType();
1393 LOG(FATAL) << "Unreachable type " << instruction->GetType();
1396 codegen_->MaybeRecordImplicitNullCheck(instruction);
1399 void LocationsBuilderMIPS64::VisitArrayLength(HArrayLength* instruction) {
1400 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
1405 void InstructionCodeGeneratorMIPS64::VisitArrayLength(HArrayLength* instruction) {
1406 LocationSummary* locations = instruction->GetLocations();
1411 codegen_->MaybeRecordImplicitNullCheck(instruction);
1414 void LocationsBuilderMIPS64::VisitArraySet(HArraySet* instruction) {
1415 Primitive::Type value_type = instruction->GetComponentType();
1418 instruction,
1427 locations->SetInAt(1, Location::RegisterOrConstant(instruction->InputAt(1)));
1428 if (Primitive::IsFloatingPointType(instruction->InputAt(2)->GetType())) {
1436 void InstructionCodeGeneratorMIPS64::VisitArraySet(HArraySet* instruction) {
1437 LocationSummary* locations = instruction->GetLocations();
1440 Primitive::Type value_type = instruction->GetComponentType();
1443 CodeGenerator::StoreNeedsWriteBarrier(value_type, instruction->GetValue());
1492 codegen_->MaybeRecordImplicitNullCheck(instruction);
1500 instruction,
1501 instruction->GetDexPc(),
1555 LOG(FATAL) << "Unreachable type " << instruction->GetType();
1561 codegen_->MaybeRecordImplicitNullCheck(instruction);
1565 void LocationsBuilderMIPS64::VisitBoundsCheck(HBoundsCheck* instruction) {
1567 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kNoCall);
1570 if (instruction->HasUses()) {
1575 void InstructionCodeGeneratorMIPS64::VisitBoundsCheck(HBoundsCheck* instruction) {
1576 LocationSummary* locations = instruction->GetLocations();
1578 instruction,
1597 void LocationsBuilderMIPS64::VisitCheckCast(HCheckCast* instruction) {
1599 instruction,
1606 void InstructionCodeGeneratorMIPS64::VisitCheckCast(HCheckCast* instruction) {
1607 LocationSummary* locations = instruction->GetLocations();
1613 instruction,
1616 instruction->GetDexPc());
1678 void InstructionCodeGeneratorMIPS64::VisitCompare(HCompare* instruction) {
1679 LocationSummary* locations = instruction->GetLocations();
1680 Primitive::Type in_type = instruction->InputAt(0)->GetType();
1701 entry_point_offset = instruction->IsGtBias() ? QUICK_ENTRY_POINT(pCmpgFloat)
1704 entry_point_offset = instruction->IsGtBias() ? QUICK_ENTRY_POINT(pCmpgDouble)
1707 codegen_->InvokeRuntime(entry_point_offset, instruction, instruction->GetDexPc(), nullptr);
1716 instruction) {
1717 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
1719 locations->SetInAt(1, Location::RegisterOrConstant(instruction->InputAt(1)));
1720 if (instruction->NeedsMaterialization()) {
1725 void InstructionCodeGeneratorMIPS64::VisitCondition(HCondition* instruction) {
1726 if (!instruction->NeedsMaterialization()) {
1730 LocationSummary* locations = instruction->GetLocations();
1745 IfCondition if_cond = instruction->GetCondition();
1779 // only the slt instruction but no sge.
1791 // only the slti instruction but no sgti.
1802 // only the slt instruction but no sle.
1833 void InstructionCodeGeneratorMIPS64::VisitDiv(HDiv* instruction) {
1834 Primitive::Type type = instruction->GetType();
1835 LocationSummary* locations = instruction->GetLocations();
1865 void LocationsBuilderMIPS64::VisitDivZeroCheck(HDivZeroCheck* instruction) {
1867 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kNoCall);
1868 locations->SetInAt(0, Location::RegisterOrConstant(instruction->InputAt(0)));
1869 if (instruction->HasUses()) {
1874 void InstructionCodeGeneratorMIPS64::VisitDivZeroCheck(HDivZeroCheck* instruction) {
1876 new (GetGraph()->GetArena()) DivZeroCheckSlowPathMIPS64(instruction);
1878 Location value = instruction->GetLocations()->InAt(0);
1880 Primitive::Type type = instruction->GetType();
1950 void InstructionCodeGeneratorMIPS64::GenerateTestAndBranch(HInstruction* instruction,
1954 HInstruction* cond = instruction->InputAt(0);
1968 // The condition instruction has been materialized, compare the output to 0.
1969 Location cond_val = instruction->GetLocations()->InAt(0);
1973 // The condition instruction has not been materialized, use its inputs as
2100 void LocationsBuilderMIPS64::HandleFieldGet(HInstruction* instruction,
2103 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kNoCall);
2105 if (Primitive::IsFloatingPointType(instruction->GetType())) {
2112 void InstructionCodeGeneratorMIPS64::HandleFieldGet(HInstruction* instruction,
2115 LocationSummary* locations = instruction->GetLocations();
2156 codegen_->MaybeRecordImplicitNullCheck(instruction);
2160 void LocationsBuilderMIPS64::HandleFieldSet(HInstruction* instruction,
2163 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kNoCall);
2165 if (Primitive::IsFloatingPointType(instruction->InputAt(1)->GetType())) {
2172 void InstructionCodeGeneratorMIPS64::HandleFieldSet(HInstruction* instruction,
2175 LocationSummary* locations = instruction->GetLocations();
2210 codegen_->MaybeRecordImplicitNullCheck(instruction);
2212 if (CodeGenerator::StoreNeedsWriteBarrier(type, instruction->InputAt(1))) {
2219 void LocationsBuilderMIPS64::VisitInstanceFieldGet(HInstanceFieldGet* instruction) {
2220 HandleFieldGet(instruction, instruction->GetFieldInfo());
2223 void InstructionCodeGeneratorMIPS64::VisitInstanceFieldGet(HInstanceFieldGet* instruction) {
2224 HandleFieldGet(instruction, instruction->GetFieldInfo());
2227 void LocationsBuilderMIPS64::VisitInstanceFieldSet(HInstanceFieldSet* instruction) {
2228 HandleFieldSet(instruction, instruction->GetFieldInfo());
2231 void InstructionCodeGeneratorMIPS64::VisitInstanceFieldSet(HInstanceFieldSet* instruction) {
2232 HandleFieldSet(instruction, instruction->GetFieldInfo());
2235 void LocationsBuilderMIPS64::VisitInstanceOf(HInstanceOf* instruction) {
2237 instruction->IsClassFinal() ? LocationSummary::kNoCall : LocationSummary::kCallOnSlowPath;
2238 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction, call_kind);
2245 void InstructionCodeGeneratorMIPS64::VisitInstanceOf(HInstanceOf* instruction) {
2246 LocationSummary* locations = instruction->GetLocations();
2260 if (instruction->IsClassFinal()) {
2268 new (GetGraph()->GetArena()) TypeCheckSlowPathMIPS64(instruction,
2271 instruction->GetDexPc());
2569 void LocationsBuilderMIPS64::VisitMonitorOperation(HMonitorOperation* instruction) {
2571 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kCall);
2576 void InstructionCodeGeneratorMIPS64::VisitMonitorOperation(HMonitorOperation* instruction) {
2577 codegen_->InvokeRuntime(instruction->IsEnter()
2580 instruction,
2581 instruction->GetDexPc(),
2609 void InstructionCodeGeneratorMIPS64::VisitMul(HMul* instruction) {
2610 Primitive::Type type = instruction->GetType();
2611 LocationSummary* locations = instruction->GetLocations();
2662 void InstructionCodeGeneratorMIPS64::VisitNeg(HNeg* instruction) {
2663 Primitive::Type type = instruction->GetType();
2664 LocationSummary* locations = instruction->GetLocations();
2692 void LocationsBuilderMIPS64::VisitNewArray(HNewArray* instruction) {
2694 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kCall);
2702 void InstructionCodeGeneratorMIPS64::VisitNewArray(HNewArray* instruction) {
2706 __ LoadConst32(calling_convention.GetRegisterAt(0), instruction->GetTypeIndex());
2708 GetThreadOffset<kMips64WordSize>(instruction->GetEntrypoint()).Int32Value(),
2709 instruction,
2710 instruction->GetDexPc(),
2715 void LocationsBuilderMIPS64::VisitNewInstance(HNewInstance* instruction) {
2717 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kCall);
2724 void InstructionCodeGeneratorMIPS64::VisitNewInstance(HNewInstance* instruction) {
2728 __ LoadConst32(calling_convention.GetRegisterAt(0), instruction->GetTypeIndex());
2730 GetThreadOffset<kMips64WordSize>(instruction->GetEntrypoint()).Int32Value(),
2731 instruction,
2732 instruction->GetDexPc(),
2737 void LocationsBuilderMIPS64::VisitNot(HNot* instruction) {
2738 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
2743 void InstructionCodeGeneratorMIPS64::VisitNot(HNot* instruction) {
2744 Primitive::Type type = instruction->GetType();
2745 LocationSummary* locations = instruction->GetLocations();
2757 LOG(FATAL) << "Unexpected type for not operation " << instruction->GetResultType();
2761 void LocationsBuilderMIPS64::VisitBooleanNot(HBooleanNot* instruction) {
2762 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
2767 void InstructionCodeGeneratorMIPS64::VisitBooleanNot(HBooleanNot* instruction) {
2768 LocationSummary* locations = instruction->GetLocations();
2774 void LocationsBuilderMIPS64::VisitNullCheck(HNullCheck* instruction) {
2776 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kNoCall);
2778 if (instruction->HasUses()) {
2783 void InstructionCodeGeneratorMIPS64::GenerateImplicitNullCheck(HNullCheck* instruction) {
2784 if (codegen_->CanMoveNullCheckToUser(instruction)) {
2787 Location obj = instruction->GetLocations()->InAt(0);
2790 codegen_->RecordPcInfo(instruction, instruction->GetDexPc());
2793 void InstructionCodeGeneratorMIPS64::GenerateExplicitNullCheck(HNullCheck* instruction) {
2794 SlowPathCodeMIPS64* slow_path = new (GetGraph()->GetArena()) NullCheckSlowPathMIPS64(instruction);
2797 Location obj = instruction->GetLocations()->InAt(0);
2802 void InstructionCodeGeneratorMIPS64::VisitNullCheck(HNullCheck* instruction) {
2804 GenerateImplicitNullCheck(instruction);
2806 GenerateExplicitNullCheck(instruction);
2810 void LocationsBuilderMIPS64::VisitOr(HOr* instruction) {
2811 HandleBinaryOp(instruction);
2814 void InstructionCodeGeneratorMIPS64::VisitOr(HOr* instruction) {
2815 HandleBinaryOp(instruction);
2818 void LocationsBuilderMIPS64::VisitParallelMove(HParallelMove* instruction ATTRIBUTE_UNUSED) {
2822 void InstructionCodeGeneratorMIPS64::VisitParallelMove(HParallelMove* instruction) {
2823 codegen_->GetMoveResolver()->EmitNativeCode(instruction);
2826 void LocationsBuilderMIPS64::VisitParameterValue(HParameterValue* instruction) {
2827 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
2828 Location location = parameter_visitor_.GetNextLocation(instruction->GetType());
2837 void InstructionCodeGeneratorMIPS64::VisitParameterValue(HParameterValue* instruction
2842 void LocationsBuilderMIPS64::VisitPhi(HPhi* instruction) {
2843 LocationSummary* locations = new (GetGraph()->GetArena()) LocationSummary(instruction);
2844 for (size_t i = 0, e = instruction->InputCount(); i < e; ++i) {
2850 void InstructionCodeGeneratorMIPS64::VisitPhi(HPhi* instruction ATTRIBUTE_UNUSED) {
2882 void InstructionCodeGeneratorMIPS64::VisitRem(HRem* instruction) {
2883 Primitive::Type type = instruction->GetType();
2884 LocationSummary* locations = instruction->GetLocations();
2903 codegen_->InvokeRuntime(entry_offset, instruction, instruction->GetDexPc(), nullptr);
2980 void LocationsBuilderMIPS64::VisitSub(HSub* instruction) {
2981 HandleBinaryOp(instruction);
2984 void InstructionCodeGeneratorMIPS64::VisitSub(HSub* instruction) {
2985 HandleBinaryOp(instruction);
2988 void LocationsBuilderMIPS64::VisitStaticFieldGet(HStaticFieldGet* instruction) {
2989 HandleFieldGet(instruction, instruction->GetFieldInfo());
2992 void InstructionCodeGeneratorMIPS64::VisitStaticFieldGet(HStaticFieldGet* instruction) {
2993 HandleFieldGet(instruction, instruction->GetFieldInfo());
2996 void LocationsBuilderMIPS64::VisitStaticFieldSet(HStaticFieldSet* instruction) {
2997 HandleFieldSet(instruction, instruction->GetFieldInfo());
3000 void InstructionCodeGeneratorMIPS64::VisitStaticFieldSet(HStaticFieldSet* instruction) {
3001 HandleFieldSet(instruction, instruction->GetFieldInfo());
3004 void LocationsBuilderMIPS64::VisitSuspendCheck(HSuspendCheck* instruction) {
3005 new (GetGraph()->GetArena()) LocationSummary(instruction, LocationSummary::kCallOnSlowPath);
3008 void InstructionCodeGeneratorMIPS64::VisitSuspendCheck(HSuspendCheck* instruction) {
3009 HBasicBlock* block = instruction->GetBlock();
3011 DCHECK(block->GetLoopInformation()->GetSuspendCheck() == instruction);
3015 if (block->IsEntryBlock() && instruction->GetNext()->IsGoto()) {
3019 GenerateSuspendCheck(instruction, nullptr);
3030 void LocationsBuilderMIPS64::VisitThrow(HThrow* instruction) {
3032 instruction, LocationSummary::kCall);
3037 void InstructionCodeGeneratorMIPS64::VisitThrow(HThrow* instruction) {
3039 instruction,
3040 instruction->GetDexPc(),
3183 void LocationsBuilderMIPS64::VisitXor(HXor* instruction) {
3184 HandleBinaryOp(instruction);
3187 void InstructionCodeGeneratorMIPS64::VisitXor(HXor* instruction) {
3188 HandleBinaryOp(instruction);
3191 void LocationsBuilderMIPS64::VisitBoundType(HBoundType* instruction ATTRIBUTE_UNUSED) {
3196 void InstructionCodeGeneratorMIPS64::VisitBoundType(HBoundType* instruction ATTRIBUTE_UNUSED) {