LLVM 22.0.0git
AMDGPUCombinerHelper.cpp File Reference

Go to the source code of this file.

Functions

static LLVM_READNONE bool fnegFoldsIntoMI (const MachineInstr &MI)
static LLVM_READONLY bool opMustUseVOP3Encoding (const MachineInstr &MI, const MachineRegisterInfo &MRI)
 returns true if the operation will definitely need to use a 64-bit encoding, and thus will use a VOP3 encoding regardless of the source modifiers.
static LLVM_READONLY bool hasSourceMods (const MachineInstr &MI)
static bool allUsesHaveSourceMods (MachineInstr &MI, MachineRegisterInfo &MRI, unsigned CostThreshold=4)
static bool mayIgnoreSignedZero (MachineInstr &MI)
static bool isInv2Pi (const APFloat &APF)
static bool isConstantCostlierToNegate (MachineInstr &MI, Register Reg, MachineRegisterInfo &MRI)
static unsigned inverseMinMax (unsigned Opc)
static bool isFPExtFromF16OrConst (const MachineRegisterInfo &MRI, Register Reg)

Function Documentation

◆ allUsesHaveSourceMods()

bool allUsesHaveSourceMods ( MachineInstr & MI,
MachineRegisterInfo & MRI,
unsigned CostThreshold = 4 )
static

◆ fnegFoldsIntoMI()

LLVM_READNONE bool fnegFoldsIntoMI ( const MachineInstr & MI)
static

Definition at line 28 of file AMDGPUCombinerHelper.cpp.

References llvm::cast(), and MI.

Referenced by llvm::AMDGPUCombinerHelper::matchFoldableFneg().

◆ hasSourceMods()

LLVM_READONLY bool hasSourceMods ( const MachineInstr & MI)
static

◆ inverseMinMax()

◆ isConstantCostlierToNegate()

◆ isFPExtFromF16OrConst()

◆ isInv2Pi()

◆ mayIgnoreSignedZero()

bool mayIgnoreSignedZero ( MachineInstr & MI)
static

◆ opMustUseVOP3Encoding()

LLVM_READONLY bool opMustUseVOP3Encoding ( const MachineInstr & MI,
const MachineRegisterInfo & MRI )
static

returns true if the operation will definitely need to use a 64-bit encoding, and thus will use a VOP3 encoding regardless of the source modifiers.

Definition at line 77 of file AMDGPUCombinerHelper.cpp.

References llvm::isa(), MI, and MRI.

Referenced by allUsesHaveSourceMods(), and llvm::AMDGPUTargetLowering::allUsesHaveSourceMods().