LLVM API Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Namespaces | Macros | Enumerations | Functions
XCoreInstrInfo.cpp File Reference
#include "XCoreInstrInfo.h"
#include "XCore.h"
#include "XCoreMachineFunctionInfo.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/CodeGen/MachineFrameInfo.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
#include "llvm/MC/MCContext.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/TargetRegistry.h"
#include "XCoreGenInstrInfo.inc"
Include dependency graph for XCoreInstrInfo.cpp:

Go to the source code of this file.

Namespaces

 llvm
 List of target independent CodeGen pass IDs.
 
 llvm::XCore
 

Macros

#define GET_INSTRINFO_CTOR_DTOR
 

Enumerations

enum  llvm::XCore::CondCode { llvm::XCore::COND_TRUE, llvm::XCore::COND_FALSE, llvm::XCore::COND_INVALID }
 

Functions

static bool isZeroImm (const MachineOperand &op)
 
static bool IsBRU (unsigned BrOpc)
 
static bool IsBRT (unsigned BrOpc)
 
static bool IsBRF (unsigned BrOpc)
 
static bool IsCondBranch (unsigned BrOpc)
 
static bool IsBR_JT (unsigned BrOpc)
 
static XCore::CondCode GetCondFromBranchOpc (unsigned BrOpc)
 
static unsigned GetCondBranchFromCond (XCore::CondCode CC)
 
static XCore::CondCode GetOppositeBranchCondition (XCore::CondCode CC)
 

Macro Definition Documentation

#define GET_INSTRINFO_CTOR_DTOR

Definition at line 25 of file XCoreInstrInfo.cpp.

Function Documentation

static unsigned GetCondBranchFromCond ( XCore::CondCode  CC)
inlinestatic

GetCondBranchFromCond - Return the Branch instruction opcode that matches the cc.

Definition at line 147 of file XCoreInstrInfo.cpp.

References llvm::XCore::COND_FALSE, llvm::XCore::COND_TRUE, and llvm_unreachable.

Referenced by llvm::X86InstrInfo::AnalyzeBranch(), llvm::XCoreInstrInfo::InsertBranch(), llvm::X86InstrInfo::InsertBranch(), and llvm::X86InstrInfo::optimizeCompareInstr().

static XCore::CondCode GetCondFromBranchOpc ( unsigned  BrOpc)
static

GetCondFromBranchOpc - Return the XCore CC that matches the correspondent Branch instruction opcode.

Definition at line 134 of file XCoreInstrInfo.cpp.

References llvm::XCore::COND_FALSE, llvm::XCore::COND_INVALID, llvm::XCore::COND_TRUE, IsBRF(), and IsBRT().

Referenced by llvm::XCoreInstrInfo::AnalyzeBranch().

static XCore::CondCode GetOppositeBranchCondition ( XCore::CondCode  CC)
inlinestatic

GetOppositeBranchCondition - Return the inverse of the specified condition, e.g. turning COND_E to COND_NE.

Definition at line 158 of file XCoreInstrInfo.cpp.

References llvm::XCore::COND_FALSE, llvm::XCore::COND_TRUE, and llvm_unreachable.

Referenced by llvm::XCoreInstrInfo::ReverseBranchCondition().

static bool IsBR_JT ( unsigned  BrOpc)
inlinestatic

Definition at line 127 of file XCoreInstrInfo.cpp.

References llvm::ISD::BR_JT, and llvm::XCoreISD::BR_JT32.

Referenced by llvm::XCoreInstrInfo::AnalyzeBranch().

static bool IsBRF ( unsigned  BrOpc)
inlinestatic

Definition at line 116 of file XCoreInstrInfo.cpp.

Referenced by GetCondFromBranchOpc(), and IsCondBranch().

static bool IsBRT ( unsigned  BrOpc)
inlinestatic

Definition at line 109 of file XCoreInstrInfo.cpp.

Referenced by GetCondFromBranchOpc(), and IsCondBranch().

static bool IsBRU ( unsigned  BrOpc)
inlinestatic
static bool IsCondBranch ( unsigned  BrOpc)
inlinestatic

Definition at line 123 of file XCoreInstrInfo.cpp.

References IsBRF(), and IsBRT().

Referenced by llvm::XCoreInstrInfo::RemoveBranch().

static bool isZeroImm ( const MachineOperand op)
static