|
LLVM 24.0.0git
|
#include "SystemZ.h"#include "SystemZInstrInfo.h"#include "SystemZSubtarget.h"#include "llvm/ADT/Statistic.h"#include "llvm/CodeGen/LivePhysRegs.h"#include "llvm/CodeGen/MachineFunctionAnalysisManager.h"#include "llvm/CodeGen/MachineFunctionPass.h"#include "llvm/CodeGen/MachineInstr.h"#include "llvm/CodeGen/MachineInstrBuilder.h"#include "llvm/CodeGen/MachinePassManager.h"#include "llvm/CodeGen/TargetInstrInfo.h"#include "llvm/IR/Analysis.h"Go to the source code of this file.
Macros | |
| #define | DEBUG_TYPE "systemz-post-rewrite" |
Functions | |
| STATISTIC (MemFoldCopies, "Number of copies inserted before folded mem ops.") | |
| STATISTIC (LOCRMuxJumps, "Number of LOCRMux jump-sequences (lower is better)") | |
| INITIALIZE_PASS (SystemZPostRewriteLegacy, "systemz-post-rewrite", "SystemZ Post Rewrite pass", false, false) FunctionPass *llvm | |
| Returns an instance of the Post Rewrite pass. | |
| static bool | expandCondMove (MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI, MachineBasicBlock::iterator &NextMBBI, const TargetInstrInfo *TII) |
| static void | selectLOCRMux (MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI, MachineBasicBlock::iterator &NextMBBI, unsigned LowOpcode, unsigned HighOpcode, const TargetInstrInfo *TII) |
| static void | selectSELRMux (MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI, MachineBasicBlock::iterator &NextMBBI, unsigned LowOpcode, unsigned HighOpcode, const TargetInstrInfo *TII) |
| static bool | selectMI (MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI, MachineBasicBlock::iterator &NextMBBI, const TargetInstrInfo *TII) |
| If MBBI references a pseudo instruction that should be selected here, do it and return true. | |
| static bool | selectMBB (MachineBasicBlock &MBB, const TargetInstrInfo *TII) |
| Iterate over the instructions in basic block MBB and select any pseudo instructions. | |
| static bool | runPostRewriteOnMF (MachineFunction &MF) |
| #define DEBUG_TYPE "systemz-post-rewrite" |
Definition at line 30 of file SystemZPostRewrite.cpp.
|
static |
Definition at line 60 of file SystemZPostRewrite.cpp.
References llvm::MachineInstrBuilder::addImm(), llvm::MachineBasicBlock::addLiveIn(), llvm::MachineInstrBuilder::addMBB(), llvm::MachineInstrBuilder::addReg(), llvm::MachineBasicBlock::addSuccessor(), assert(), llvm::MachineBasicBlock::begin(), llvm::BuildMI(), llvm::MachineFunction::CreateMachineBasicBlock(), DL, llvm::MachineBasicBlock::end(), llvm::getRegState(), I, llvm::MachineFunction::insert(), MBB, MBBI, MI, llvm::MachineBasicBlock::splice(), TII, and llvm::MachineBasicBlock::transferSuccessors().
Referenced by selectLOCRMux(), and selectSELRMux().
| INITIALIZE_PASS | ( | SystemZPostRewriteLegacy | , |
| "systemz-post-rewrite" | , | ||
| "SystemZ Post Rewrite pass" | , | ||
| false | , | ||
| false | ) |
Returns an instance of the Post Rewrite pass.
Definition at line 48 of file SystemZPostRewrite.cpp.
References llvm::createSystemZPostRewriteLegacyPass().
|
static |
Definition at line 267 of file SystemZPostRewrite.cpp.
References llvm::MachineFunction::getSubtarget(), MBB, Modified, selectMBB(), and TII.
Referenced by llvm::SystemZPostRewritePass::run().
|
static |
Definition at line 123 of file SystemZPostRewrite.cpp.
References expandCondMove(), llvm::SystemZ::isHighReg(), MBB, MBBI, and TII.
Referenced by selectMI().
|
static |
Iterate over the instructions in basic block MBB and select any pseudo instructions.
Return true if anything was modified.
Definition at line 254 of file SystemZPostRewrite.cpp.
References E(), MBB, MBBI, Modified, selectMI(), and TII.
Referenced by runPostRewriteOnMF().
|
static |
If MBBI references a pseudo instruction that should be selected here, do it and return true.
Otherwise return false.
Definition at line 216 of file SystemZPostRewrite.cpp.
References llvm::MachineInstrBuilder::addReg(), llvm::BuildMI(), llvm::MachineOperand::getReg(), llvm::SystemZ::getTargetMemOpcode(), MBB, MBBI, MI, selectLOCRMux(), selectSELRMux(), llvm::MachineOperand::setReg(), and TII.
Referenced by selectMBB().
|
static |
Definition at line 144 of file SystemZPostRewrite.cpp.
References llvm::MachineInstrBuilder::addReg(), llvm::BuildMI(), expandCondMove(), llvm::MachineOperand::getReg(), llvm::getRegState(), llvm::SystemZ::isHighReg(), MBB, MBBI, llvm::MachineOperand::setReg(), std::swap(), and TII.
Referenced by selectMI().
| STATISTIC | ( | LOCRMuxJumps | , |
| "Number of LOCRMux jump-sequences (lower is better)" | ) |
| STATISTIC | ( | MemFoldCopies | , |
| "Number of copies inserted before folded mem ops." | ) |