|
LLVM 24.0.0git
|
#include "SILowerI1Copies.h"#include "AMDGPU.h"#include "llvm/CodeGen/MachineIDFSSAUpdater.h"#include "llvm/InitializePasses.h"Go to the source code of this file.
Classes | |
| class | llvm::AMDGPU::PhiIncomingAnalysis |
| Helper class that determines the relationship between incoming values of a phi in the control flow graph to determine where an incoming value can simply be taken as a scalar lane mask as-is, and where it needs to be merged with another, previously defined lane mask. More... | |
| class | llvm::AMDGPU::LoopFinder |
| Helper class that detects loops which require us to lower an i1 COPY into bitwise manipulation. More... | |
| class | SILowerI1CopiesLegacy |
Namespaces | |
| namespace | llvm |
| This is an optimization pass for GlobalISel generic memory operations. | |
| namespace | llvm::AMDGPU |
Macros | |
| #define | DEBUG_TYPE "si-i1-copies" |
Functions | |
| static Register | insertUndefLaneMask (MachineBasicBlock *MBB, MachineRegisterInfo *MRI, MachineRegisterInfo::VRegAttrs LaneMaskRegAttrs) |
| static bool | isExecInvariantBackEdge (const MachineBasicBlock &Latch, const MachineBasicBlock &Header, const MachineDominatorTree &DT, const SIInstrInfo &TII) |
Return true if Latch -> Header is the only back-edge of a loop that is left as a whole, so that EXEC is the same on every iteration at the header and at the end of the latch. | |
| static bool | isVRegCompatibleReg (const SIRegisterInfo &TRI, const MachineRegisterInfo &MRI, Register Reg) |
| static void | instrDefsUsesSCC (const MachineInstr &MI, bool &Def, bool &Use) |
| static bool | runFixI1Copies (MachineFunction &MF, MachineDominatorTree &MDT, MachinePostDominatorTree &MPDT) |
| Lower all instructions that def or use vreg_1 registers. | |
| INITIALIZE_PASS_BEGIN (SILowerI1CopiesLegacy, DEBUG_TYPE, "SI Lower i1 Copies", false, false) INITIALIZE_PASS_END(SILowerI1CopiesLegacy | |
Variables | |
| DEBUG_TYPE | |
| SI Lower i1 | Copies |
| SI Lower i1 | false |
| #define DEBUG_TYPE "si-i1-copies" |
Definition at line 29 of file SILowerI1Copies.cpp.
| INITIALIZE_PASS_BEGIN | ( | SILowerI1CopiesLegacy | , |
| DEBUG_TYPE | , | ||
| "SI Lower i1 Copies" | , | ||
| false | , | ||
| false | ) |
References DEBUG_TYPE, and INITIALIZE_PASS_DEPENDENCY.
|
static |
Definition at line 436 of file SILowerI1Copies.cpp.
References llvm::BuildMI(), llvm::AMDGPU::createLaneMaskReg(), llvm::MachineFunction::getSubtarget(), MBB, MRI, and TII.
Referenced by llvm::AMDGPU::PhiLoweringHelper::mergeIncomingLaneMasks().
|
static |
Definition at line 746 of file SILowerI1Copies.cpp.
References llvm::AMDGPU::Def, and MI.
Referenced by llvm::AMDGPU::PhiLoweringHelper::getSaluInsertionAtEnd().
|
static |
Return true if Latch -> Header is the only back-edge of a loop that is left as a whole, so that EXEC is the same on every iteration at the header and at the end of the latch.
This relies on the control flow being structurized: lanes can only leave a loop at different times through SI_IF_BREAK/SI_LOOP on a back-edge, and a divergent SI_IF/SI_ELSE region is closed by its SI_END_CF before any edge leaves it. So if the only back-edge ends in a uniform branch, every exit, including a uniform early exit, is taken by the whole wave, and EXEC at the end of the latch is EXEC at the header.
Definition at line 96 of file SILowerI1Copies.cpp.
References llvm::all_of(), assert(), llvm::MachineDominatorTree::dominates(), llvm::MachineBasicBlock::isSuccessor(), Pred, and TII.
|
static |
Definition at line 448 of file SILowerI1Copies.cpp.
References MRI, Reg, llvm::Size, and TRI.
|
static |
Lower all instructions that def or use vreg_1 registers.
In a first pass, we lower COPYs from vreg_1 to vector registers, as can occur around inline assembly. We do this first, before vreg_1 registers are changed to scalar mask registers.
Then we lower all defs of vreg_1 registers. Phi nodes are lowered before all others, because phi lowering looks through copies and can therefore often make copy lowering unnecessary.
Definition at line 912 of file SILowerI1Copies.cpp.
References Changed, and llvm::MachineFunction::getProperties().
Referenced by llvm::SILowerI1CopiesPass::run(), and SILowerI1CopiesLegacy::runOnMachineFunction().
Definition at line 970 of file SILowerI1Copies.cpp.
Referenced by llvm::AArch64RegisterInfo::getRegAllocationHints(), propagateLocalCopies(), and llvm::TailDuplicator::tailDuplicateAndUpdate().
| DEBUG_TYPE |
Definition at line 970 of file SILowerI1Copies.cpp.
Definition at line 971 of file SILowerI1Copies.cpp.