LLVM  10.0.0svn
Functions | Variables
PPCTargetMachine.cpp File Reference
#include "PPCTargetMachine.h"
#include "MCTargetDesc/PPCMCTargetDesc.h"
#include "PPC.h"
#include "PPCMachineScheduler.h"
#include "PPCSubtarget.h"
#include "PPCTargetObjectFile.h"
#include "PPCTargetTransformInfo.h"
#include "TargetInfo/PowerPCTargetInfo.h"
#include "llvm/ADT/Optional.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/Triple.h"
#include "llvm/Analysis/TargetTransformInfo.h"
#include "llvm/CodeGen/Passes.h"
#include "llvm/CodeGen/TargetPassConfig.h"
#include "llvm/CodeGen/MachineScheduler.h"
#include "llvm/IR/Attributes.h"
#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Function.h"
#include "llvm/Pass.h"
#include "llvm/Support/CodeGen.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/TargetRegistry.h"
#include "llvm/Target/TargetLoweringObjectFile.h"
#include "llvm/Target/TargetOptions.h"
#include "llvm/Transforms/Scalar.h"
#include <cassert>
#include <memory>
#include <string>
Include dependency graph for PPCTargetMachine.cpp:

Go to the source code of this file.

Functions

void LLVMInitializePowerPCTarget ()
 
static std::string getDataLayoutString (const Triple &T)
 Return the datalayout string of a subtarget. More...
 
static std::string computeFSAdditions (StringRef FS, CodeGenOpt::Level OL, const Triple &TT)
 
static std::unique_ptr< TargetLoweringObjectFilecreateTLOF (const Triple &TT)
 
static PPCTargetMachine::PPCABI computeTargetABI (const Triple &TT, const TargetOptions &Options)
 
static Reloc::Model getEffectiveRelocModel (const Triple &TT, Optional< Reloc::Model > RM)
 
static CodeModel::Model getEffectivePPCCodeModel (const Triple &TT, Optional< CodeModel::Model > CM, bool JIT)
 
static ScheduleDAGInstrscreatePPCMachineScheduler (MachineSchedContext *C)
 
static ScheduleDAGInstrscreatePPCPostMachineScheduler (MachineSchedContext *C)
 

Variables

static cl::opt< boolEnableBranchCoalescing ("enable-ppc-branch-coalesce", cl::Hidden, cl::desc("enable coalescing of duplicate branches for PPC"))
 
static cl::opt< boolDisableCTRLoops ("disable-ppc-ctrloops", cl::Hidden, cl::desc("Disable CTR loops for PPC"))
 
static cl::opt< boolDisablePreIncPrep ("disable-ppc-preinc-prep", cl::Hidden, cl::desc("Disable PPC loop preinc prep"))
 
static cl::opt< boolVSXFMAMutateEarly ("schedule-ppc-vsx-fma-mutation-early", cl::Hidden, cl::desc("Schedule VSX FMA instruction mutation early"))
 
static cl::opt< boolDisableVSXSwapRemoval ("disable-ppc-vsx-swap-removal", cl::Hidden, cl::desc("Disable VSX Swap Removal for PPC"))
 
static cl::opt< boolDisableQPXLoadSplat ("disable-ppc-qpx-load-splat", cl::Hidden, cl::desc("Disable QPX load splat simplification"))
 
static cl::opt< boolDisableMIPeephole ("disable-ppc-peephole", cl::Hidden, cl::desc("Disable machine peepholes for PPC"))
 
static cl::opt< boolEnableGEPOpt ("ppc-gep-opt", cl::Hidden, cl::desc("Enable optimizations on complex GEPs"), cl::init(true))
 
static cl::opt< boolEnablePrefetch ("enable-ppc-prefetching", cl::desc("disable software prefetching on PPC"), cl::init(false), cl::Hidden)
 
static cl::opt< boolEnableExtraTOCRegDeps ("enable-ppc-extra-toc-reg-deps", cl::desc("Add extra TOC register dependencies"), cl::init(true), cl::Hidden)
 
static cl::opt< boolEnableMachineCombinerPass ("ppc-machine-combiner", cl::desc("Enable the machine combiner pass"), cl::init(true), cl::Hidden)
 
static cl::opt< boolReduceCRLogical ("ppc-reduce-cr-logicals", cl::desc("Expand eligible cr-logical binary ops to branches"), cl::init(true), cl::Hidden)
 
static MachineSchedRegistry PPCPreRASchedRegistry ("ppc-prera", "Run PowerPC PreRA specific scheduler", createPPCMachineScheduler)
 
static MachineSchedRegistry PPCPostRASchedRegistry ("ppc-postra", "Run PowerPC PostRA specific scheduler", createPPCPostMachineScheduler)
 

Function Documentation

◆ computeFSAdditions()

static std::string computeFSAdditions ( StringRef  FS,
CodeGenOpt::Level  OL,
const Triple TT 
)
static

◆ computeTargetABI()

static PPCTargetMachine::PPCABI computeTargetABI ( const Triple TT,
const TargetOptions Options 
)
static

◆ createPPCMachineScheduler()

static ScheduleDAGInstrs* createPPCMachineScheduler ( MachineSchedContext C)
static

◆ createPPCPostMachineScheduler()

static ScheduleDAGInstrs* createPPCPostMachineScheduler ( MachineSchedContext C)
static

◆ createTLOF()

static std::unique_ptr<TargetLoweringObjectFile> createTLOF ( const Triple TT)
static

Definition at line 187 of file PPCTargetMachine.cpp.

References llvm::Triple::isOSAIX(), and llvm::Triple::isOSDarwin().

◆ getDataLayoutString()

static std::string getDataLayoutString ( const Triple T)
static

◆ getEffectivePPCCodeModel()

static CodeModel::Model getEffectivePPCCodeModel ( const Triple TT,
Optional< CodeModel::Model CM,
bool  JIT 
)
static

◆ getEffectiveRelocModel()

static Reloc::Model getEffectiveRelocModel ( const Triple TT,
Optional< Reloc::Model RM 
)
static

◆ LLVMInitializePowerPCTarget()

void LLVMInitializePowerPCTarget ( )

Variable Documentation

◆ DisableCTRLoops

cl:: opt<bool> DisableCTRLoops("disable-ppc-ctrloops", cl::Hidden, cl::desc("Disable CTR loops for PPC"))
static

◆ DisableMIPeephole

cl:: opt<bool> DisableMIPeephole("disable-ppc-peephole", cl::Hidden, cl::desc("Disable machine peepholes for PPC"))
static

◆ DisablePreIncPrep

cl:: opt<bool> DisablePreIncPrep("disable-ppc-preinc-prep", cl::Hidden, cl::desc("Disable PPC loop preinc prep"))
static

◆ DisableQPXLoadSplat

cl:: opt<bool> DisableQPXLoadSplat("disable-ppc-qpx-load-splat", cl::Hidden, cl::desc("Disable QPX load splat simplification"))
static

◆ DisableVSXSwapRemoval

cl:: opt<bool> DisableVSXSwapRemoval("disable-ppc-vsx-swap-removal", cl::Hidden, cl::desc("Disable VSX Swap Removal for PPC"))
static

◆ EnableBranchCoalescing

cl::opt<bool> EnableBranchCoalescing("enable-ppc-branch-coalesce", cl::Hidden, cl::desc("enable coalescing of duplicate branches for PPC"))
static

◆ EnableExtraTOCRegDeps

cl::opt<bool> EnableExtraTOCRegDeps("enable-ppc-extra-toc-reg-deps", cl::desc("Add extra TOC register dependencies"), cl::init(true), cl::Hidden)
static

◆ EnableGEPOpt

cl::opt<bool> EnableGEPOpt("ppc-gep-opt", cl::Hidden, cl::desc("Enable optimizations on complex GEPs"), cl::init(true))
static

◆ EnableMachineCombinerPass

cl::opt<bool> EnableMachineCombinerPass("ppc-machine-combiner", cl::desc("Enable the machine combiner pass"), cl::init(true), cl::Hidden)
static

◆ EnablePrefetch

cl::opt<bool> EnablePrefetch("enable-ppc-prefetching", cl::desc("disable software prefetching on PPC"), cl::init(false), cl::Hidden)
static

◆ PPCPostRASchedRegistry

MachineSchedRegistry PPCPostRASchedRegistry("ppc-postra", "Run PowerPC PostRA specific scheduler", createPPCPostMachineScheduler)
static

◆ PPCPreRASchedRegistry

MachineSchedRegistry PPCPreRASchedRegistry("ppc-prera", "Run PowerPC PreRA specific scheduler", createPPCMachineScheduler)
static

◆ ReduceCRLogical

cl::opt<bool> ReduceCRLogical("ppc-reduce-cr-logicals", cl::desc("Expand eligible cr-logical binary ops to branches"), cl::init(true), cl::Hidden)
static

◆ VSXFMAMutateEarly

cl::opt<bool> VSXFMAMutateEarly("schedule-ppc-vsx-fma-mutation-early", cl::Hidden, cl::desc("Schedule VSX FMA instruction mutation early"))
static