mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 04:02:41 +01:00
GlobalISel: Remove getIntrinsicID utility function
This is redundant with a method directly on MachineInstr
This commit is contained in:
parent
2398c72d1f
commit
b1584af557
@ -384,9 +384,5 @@ int64_t getICmpTrueVal(const TargetLowering &TLI, bool IsVector, bool IsFP);
|
||||
bool shouldOptForSize(const MachineBasicBlock &MBB, ProfileSummaryInfo *PSI,
|
||||
BlockFrequencyInfo *BFI);
|
||||
|
||||
/// \returns the intrinsic ID for a G_INTRINSIC or G_INTRINSIC_W_SIDE_EFFECTS
|
||||
/// instruction \p MI.
|
||||
unsigned getIntrinsicID(const MachineInstr &MI);
|
||||
|
||||
} // End namespace llvm.
|
||||
#endif
|
||||
|
@ -998,12 +998,3 @@ bool llvm::shouldOptForSize(const MachineBasicBlock &MBB,
|
||||
return F.hasOptSize() || F.hasMinSize() ||
|
||||
llvm::shouldOptimizeForSize(MBB.getBasicBlock(), PSI, BFI);
|
||||
}
|
||||
|
||||
unsigned llvm::getIntrinsicID(const MachineInstr &MI) {
|
||||
#ifndef NDEBUG
|
||||
unsigned Opc = MI.getOpcode();
|
||||
assert(Opc == TargetOpcode::G_INTRINSIC ||
|
||||
Opc == TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS);
|
||||
#endif
|
||||
return MI.getOperand(MI.getNumExplicitDefs()).getIntrinsicID();
|
||||
}
|
||||
|
@ -487,7 +487,7 @@ bool AArch64RegisterBankInfo::hasFPConstraints(const MachineInstr &MI,
|
||||
const TargetRegisterInfo &TRI,
|
||||
unsigned Depth) const {
|
||||
unsigned Op = MI.getOpcode();
|
||||
if (Op == TargetOpcode::G_INTRINSIC && isFPIntrinsic(getIntrinsicID(MI)))
|
||||
if (Op == TargetOpcode::G_INTRINSIC && isFPIntrinsic(MI.getIntrinsicID()))
|
||||
return true;
|
||||
|
||||
// Do we have an explicit floating point instruction?
|
||||
@ -945,7 +945,7 @@ AArch64RegisterBankInfo::getInstrMapping(const MachineInstr &MI) const {
|
||||
case TargetOpcode::G_INTRINSIC: {
|
||||
// Check if we know that the intrinsic has any constraints on its register
|
||||
// banks. If it does, then update the mapping accordingly.
|
||||
unsigned ID = getIntrinsicID(MI);
|
||||
unsigned ID = MI.getIntrinsicID();
|
||||
unsigned Idx = 0;
|
||||
if (!isFPIntrinsic(ID))
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user