LLVM 22.0.0git
HexagonVLIWPacketizer.cpp File Reference

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "packets"

Enumerations

enum  PredicateKind { PK_False , PK_True , PK_Unknown }

Functions

 INITIALIZE_PASS_BEGIN (HexagonPacketizer, "hexagon-packetizer", "Hexagon Packetizer", false, false) INITIALIZE_PASS_END(HexagonPacketizer
static bool hasWriteToReadDep (const MachineInstr &FirstI, const MachineInstr &SecondI, const TargetRegisterInfo *TRI)
static MachineBasicBlock::iterator moveInstrOut (MachineInstr &MI, MachineBasicBlock::iterator BundleIt, bool Before)
static bool isRegDependence (const SDep::Kind DepType)
static bool isDirectJump (const MachineInstr &MI)
static bool isSchedBarrier (const MachineInstr &MI)
static bool isControlFlow (const MachineInstr &MI)
static bool doesModifyCalleeSavedReg (const MachineInstr &MI, const TargetRegisterInfo *TRI)
 Returns true if the instruction modifies a callee-saved register.
static PredicateKind getPredicateSense (const MachineInstr &MI, const HexagonInstrInfo *HII)
 Returns true if an instruction is predicated on p0 and false if it's predicated on !p0.
static const MachineOperandgetPostIncrementOperand (const MachineInstr &MI, const HexagonInstrInfo *HII)
static const MachineOperandgetStoreValueOperand (const MachineInstr &MI)
static bool isLoadAbsSet (const MachineInstr &MI)
static const MachineOperandgetAbsSetOperand (const MachineInstr &MI)
static bool isImplicitDependency (const MachineInstr &I, bool CheckDef, unsigned DepReg)
static unsigned getPredicatedRegister (MachineInstr &MI, const HexagonInstrInfo *QII)
 Gets the predicate register of a predicated instruction.
static bool cannotCoexistAsymm (const MachineInstr &MI, const MachineInstr &MJ, const HexagonInstrInfo &HII)
static bool isSystemInstr (const MachineInstr &MI)

Variables

static cl::opt< boolDisablePacketizer ("disable-packetizer", cl::Hidden, cl::desc("Disable Hexagon packetizer pass"))
static cl::opt< boolSlot1Store ("slot1-store-slot0-load", cl::Hidden, cl::init(true), cl::desc("Allow slot1 store and slot0 load"))
static cl::opt< boolPacketizeVolatiles ("hexagon-packetize-volatiles", cl::Hidden, cl::init(true), cl::desc("Allow non-solo packetization of volatile memory references"))
static cl::opt< boolEnableGenAllInsnClass ("enable-gen-insn", cl::Hidden, cl::desc("Generate all instruction with TC"))
static cl::opt< boolDisableVecDblNVStores ("disable-vecdbl-nv-stores", cl::Hidden, cl::desc("Disable vector double new-value-stores"))
cl::opt< boolScheduleInlineAsm
hexagon packetizer
hexagon Hexagon Packetizer
hexagon Hexagon false

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "packets"

Definition at line 56 of file HexagonVLIWPacketizer.cpp.

Enumeration Type Documentation

◆ PredicateKind

Enumerator
PK_False 
PK_True 
PK_Unknown 

Definition at line 550 of file HexagonVLIWPacketizer.cpp.

Function Documentation

◆ cannotCoexistAsymm()

◆ doesModifyCalleeSavedReg()

bool doesModifyCalleeSavedReg ( const MachineInstr & MI,
const TargetRegisterInfo * TRI )
static

Returns true if the instruction modifies a callee-saved register.

Definition at line 340 of file HexagonVLIWPacketizer.cpp.

References MI, and TRI.

Referenced by llvm::HexagonPacketizerList::hasControlDependence().

◆ getAbsSetOperand()

const MachineOperand & getAbsSetOperand ( const MachineInstr & MI)
static

◆ getPostIncrementOperand()

◆ getPredicatedRegister()

unsigned getPredicatedRegister ( MachineInstr & MI,
const HexagonInstrInfo * QII )
static

Gets the predicate register of a predicated instruction.

We use the following rule: The first predicate register that is a use is the predicate register of a predicated instruction.

Definition at line 940 of file HexagonVLIWPacketizer.cpp.

References assert(), llvm::HexagonInstrInfo::isPredicated(), llvm_unreachable, and MI.

Referenced by llvm::HexagonPacketizerList::arePredicatesComplements().

◆ getPredicateSense()

PredicateKind getPredicateSense ( const MachineInstr & MI,
const HexagonInstrInfo * HII )
static

Returns true if an instruction is predicated on p0 and false if it's predicated on !p0.

Definition at line 558 of file HexagonVLIWPacketizer.cpp.

References llvm::HexagonInstrInfo::isPredicated(), llvm::HexagonInstrInfo::isPredicatedTrue(), MI, PK_False, PK_True, and PK_Unknown.

Referenced by llvm::HexagonPacketizerList::arePredicatesComplements(), and llvm::HexagonPacketizerList::canPromoteToNewValueStore().

◆ getStoreValueOperand()

const MachineOperand & getStoreValueOperand ( const MachineInstr & MI)
static

Definition at line 601 of file HexagonVLIWPacketizer.cpp.

References MI.

Referenced by llvm::HexagonPacketizerList::canPromoteToNewValueStore().

◆ hasWriteToReadDep()

◆ INITIALIZE_PASS_BEGIN()

INITIALIZE_PASS_BEGIN ( HexagonPacketizer ,
"hexagon-packetizer" ,
"Hexagon Packetizer" ,
false ,
false  )

◆ isControlFlow()

bool isControlFlow ( const MachineInstr & MI)
static

Definition at line 335 of file HexagonVLIWPacketizer.cpp.

References MI.

Referenced by llvm::HexagonPacketizerList::hasControlDependence().

◆ isDirectJump()

bool isDirectJump ( const MachineInstr & MI)
static

Definition at line 323 of file HexagonVLIWPacketizer.cpp.

References MI.

Referenced by llvm::HexagonPacketizerList::isLegalToPacketizeTogether().

◆ isImplicitDependency()

bool isImplicitDependency ( const MachineInstr & I,
bool CheckDef,
unsigned DepReg )
static

Definition at line 827 of file HexagonVLIWPacketizer.cpp.

References I.

Referenced by llvm::HexagonPacketizerList::canPromoteToDotNew().

◆ isLoadAbsSet()

bool isLoadAbsSet ( const MachineInstr & MI)
static

Definition at line 606 of file HexagonVLIWPacketizer.cpp.

References MI, and Opc.

Referenced by llvm::HexagonPacketizerList::canPromoteToNewValueStore(), and getAbsSetOperand().

◆ isRegDependence()

bool isRegDependence ( const SDep::Kind DepType)
static

◆ isSchedBarrier()

bool isSchedBarrier ( const MachineInstr & MI)
static

Definition at line 327 of file HexagonVLIWPacketizer.cpp.

References MI.

Referenced by llvm::HexagonPacketizerList::isSoloInstruction().

◆ isSystemInstr()

bool isSystemInstr ( const MachineInstr & MI)
static

Definition at line 1186 of file HexagonVLIWPacketizer.cpp.

References MI, and Opc.

Referenced by llvm::HexagonPacketizerList::hasDualStoreDependence().

◆ moveInstrOut()

Variable Documentation

◆ DisablePacketizer

cl::opt< bool > DisablePacketizer("disable-packetizer", cl::Hidden, cl::desc("Disable Hexagon packetizer pass")) ( "disable-packetizer" ,
cl::Hidden ,
cl::desc("Disable Hexagon packetizer pass")  )
static

◆ DisableVecDblNVStores

cl::opt< bool > DisableVecDblNVStores("disable-vecdbl-nv-stores", cl::Hidden, cl::desc("Disable vector double new-value-stores")) ( "disable-vecdbl-nv-stores" ,
cl::Hidden ,
cl::desc("Disable vector double new-value-stores")  )
static

◆ EnableGenAllInsnClass

cl::opt< bool > EnableGenAllInsnClass("enable-gen-insn", cl::Hidden, cl::desc("Generate all instruction with TC")) ( "enable-gen-insn" ,
cl::Hidden ,
cl::desc("Generate all instruction with TC")  )
static

◆ false

hexagon Hexagon false

Definition at line 124 of file HexagonVLIWPacketizer.cpp.

◆ Packetizer

hexagon Hexagon Packetizer

Definition at line 124 of file HexagonVLIWPacketizer.cpp.

◆ packetizer

hexagon packetizer

Definition at line 123 of file HexagonVLIWPacketizer.cpp.

◆ PacketizeVolatiles

cl::opt< bool > PacketizeVolatiles("hexagon-packetize-volatiles", cl::Hidden, cl::init(true), cl::desc("Allow non-solo packetization of volatile memory references")) ( "hexagon-packetize-volatiles" ,
cl::Hidden ,
cl::init(true) ,
cl::desc("Allow non-solo packetization of volatile memory references")  )
static

◆ ScheduleInlineAsm

cl::opt<bool> ScheduleInlineAsm
extern

◆ Slot1Store

cl::opt< bool > Slot1Store("slot1-store-slot0-load", cl::Hidden, cl::init(true), cl::desc("Allow slot1 store and slot0 load")) ( "slot1-store-slot0-load" ,
cl::Hidden ,
cl::init(true) ,
cl::desc("Allow slot1 store and slot0 load")  )
static