LLVM  6.0.0svn
Macros | Functions | Variables
SILoadStoreOptimizer.cpp File Reference
#include "AMDGPU.h"
#include "AMDGPUSubtarget.h"
#include "SIInstrInfo.h"
#include "SIRegisterInfo.h"
#include "Utils/AMDGPUBaseInfo.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Analysis/AliasAnalysis.h"
#include "llvm/CodeGen/MachineBasicBlock.h"
#include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
#include "llvm/CodeGen/MachineInstr.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
#include "llvm/CodeGen/MachineOperand.h"
#include "llvm/CodeGen/MachineRegisterInfo.h"
#include "llvm/IR/DebugLoc.h"
#include "llvm/Pass.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/MathExtras.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
#include <cassert>
#include <cstdlib>
#include <iterator>
#include <utility>
Include dependency graph for SILoadStoreOptimizer.cpp:

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "si-load-store-opt"
 

Functions

 INITIALIZE_PASS_BEGIN (SILoadStoreOptimizer, DEBUG_TYPE, "SI Load / Store Optimizer", false, false) INITIALIZE_PASS_END(SILoadStoreOptimizer
 
static void moveInstsAfter (MachineBasicBlock::iterator I, ArrayRef< MachineInstr *> InstsToMove)
 
static void addDefsToList (const MachineInstr &MI, DenseSet< unsigned > &Defs)
 
static bool memAccessesCanBeReordered (MachineBasicBlock::iterator A, MachineBasicBlock::iterator B, const SIInstrInfo *TII, AliasAnalysis *AA)
 
static bool addToListsIfDependent (MachineInstr &MI, DenseSet< unsigned > &Defs, SmallVectorImpl< MachineInstr *> &Insts)
 
static bool canMoveInstsAcrossMemOp (MachineInstr &MemOp, ArrayRef< MachineInstr *> InstsToMove, const SIInstrInfo *TII, AliasAnalysis *AA)
 

Variables

 DEBUG_TYPE
 
SI Load Store Optimizer
 
SI Load Store false
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "si-load-store-opt"

Definition at line 67 of file SILoadStoreOptimizer.cpp.

Function Documentation

◆ addDefsToList()

static void addDefsToList ( const MachineInstr MI,
DenseSet< unsigned > &  Defs 
)
static

◆ addToListsIfDependent()

static bool addToListsIfDependent ( MachineInstr MI,
DenseSet< unsigned > &  Defs,
SmallVectorImpl< MachineInstr *> &  Insts 
)
static

◆ canMoveInstsAcrossMemOp()

static bool canMoveInstsAcrossMemOp ( MachineInstr MemOp,
ArrayRef< MachineInstr *>  InstsToMove,
const SIInstrInfo TII,
AliasAnalysis AA 
)
static

◆ INITIALIZE_PASS_BEGIN()

INITIALIZE_PASS_BEGIN ( SILoadStoreOptimizer  ,
DEBUG_TYPE  ,
"SI Load / Store Optimizer ,
false  ,
false   
)

◆ memAccessesCanBeReordered()

static bool memAccessesCanBeReordered ( MachineBasicBlock::iterator  A,
MachineBasicBlock::iterator  B,
const SIInstrInfo TII,
AliasAnalysis AA 
)
static

◆ moveInstsAfter()

static void moveInstsAfter ( MachineBasicBlock::iterator  I,
ArrayRef< MachineInstr *>  InstsToMove 
)
static

Definition at line 134 of file SILoadStoreOptimizer.cpp.

References I, llvm::MachineBasicBlock::insert(), and MI.

Referenced by canMoveInstsAcrossMemOp().

Variable Documentation

◆ DEBUG_TYPE

DEBUG_TYPE

Definition at line 123 of file SILoadStoreOptimizer.cpp.

◆ false

SI Load Store false

Definition at line 123 of file SILoadStoreOptimizer.cpp.

◆ Optimizer

SI Load Store Optimizer

Definition at line 123 of file SILoadStoreOptimizer.cpp.