OpenASIP 2.2
Loading...
Searching...
No Matches
Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
llvm::TCETTIImpl Class Reference

#include <TCETargetTransformInfo.hh>

Inheritance diagram for llvm::TCETTIImpl:
Inheritance graph
Collaboration diagram for llvm::TCETTIImpl:
Collaboration graph

Public Member Functions

 TCETTIImpl (const TCETargetMachine *TM, const Function &F)
 
bool isHardwareLoopProfitable (Loop *L, ScalarEvolution &SE, AssumptionCache &AC, TargetLibraryInfo *LibInfo, HardwareLoopInfo &HWLoopInfo)
 

Private Types

typedef BasicTTIImplBase< TCETTIImpl > BaseT
 
typedef TargetTransformInfo TTI
 

Private Member Functions

const TCESubtarget * getST () const
 
const TCETargetLowering * getTLI () const
 

Private Attributes

friend BaseT
 
const TCESubtarget * ST
 
const TCETargetLowering * TLI
 

Detailed Description

Definition at line 42 of file TCETargetTransformInfo.hh.

Member Typedef Documentation

◆ BaseT

typedef BasicTTIImplBase<TCETTIImpl> llvm::TCETTIImpl::BaseT
private

Definition at line 43 of file TCETargetTransformInfo.hh.

◆ TTI

typedef TargetTransformInfo llvm::TCETTIImpl::TTI
private

Definition at line 44 of file TCETargetTransformInfo.hh.

Constructor & Destructor Documentation

◆ TCETTIImpl()

llvm::TCETTIImpl::TCETTIImpl ( const TCETargetMachine *  TM,
const Function &  F 
)
inlineexplicit

Definition at line 60 of file TCETargetTransformInfo.hh.

61 : BaseT(TM, F.getParent()->getDataLayout()),
62 ST(TM->getSubtargetImpl()),
63 TLI(static_cast<const TCETargetLowering *>(
64 ST->getTargetLowering())) {}
virtual const TargetLowering * getTargetLowering() const override
const TCESubtarget * ST
BasicTTIImplBase< TCETTIImpl > BaseT
const TCETargetLowering * TLI

Member Function Documentation

◆ getST()

const TCESubtarget * llvm::TCETTIImpl::getST ( ) const
inlineprivate

Definition at line 51 of file TCETargetTransformInfo.hh.

51 {
52 return ST;
53 }

References ST.

◆ getTLI()

const TCETargetLowering * llvm::TCETTIImpl::getTLI ( ) const
inlineprivate

Definition at line 55 of file TCETargetTransformInfo.hh.

55 {
56 return TLI;
57 }

References TLI.

◆ isHardwareLoopProfitable()

bool TCETTIImpl::isHardwareLoopProfitable ( Loop *  L,
ScalarEvolution &  SE,
AssumptionCache &  AC,
TargetLibraryInfo *  LibInfo,
HardwareLoopInfo &  HWLoopInfo 
)

Definition at line 43 of file TCETargetTransformInfo.cc.

45 {
46 // Check TCE flag for hwloop
49 if (options == NULL || options->disableHWLoops()) return false;
50
51 // We should do hwloop only for single BB loop
52 if (L->getNumBlocks() != 1) {
53 LLVM_DEBUG(
54 dbgs() << "HWLoops: Loop has " << L->getNumBlocks()
55 << " BB. Not converting to hwloop: " << L->getName()
56 << "\n");
57 return false;
58 }
59
60 // Set counter type and loop decrement value
61 LLVMContext &C = L->getHeader()->getContext();
62 HWLoopInfo.CountType = Type::getInt32Ty(C);
63 HWLoopInfo.LoopDecrement = ConstantInt::get(HWLoopInfo.CountType, 1);
64 HWLoopInfo.IsNestingLegal = false;
65 return true;
66}
static MachInfoCmdLineOptions options
Definition MachInfo.cc:46
static CmdLineOptions * cmdLineOptions()

References Application::cmdLineOptions(), and options.

Here is the call graph for this function:

Member Data Documentation

◆ BaseT

friend llvm::TCETTIImpl::BaseT
private

Definition at line 45 of file TCETargetTransformInfo.hh.

◆ ST

const TCESubtarget* llvm::TCETTIImpl::ST
private

Definition at line 47 of file TCETargetTransformInfo.hh.

Referenced by getST().

◆ TLI

const TCETargetLowering* llvm::TCETTIImpl::TLI
private

Definition at line 48 of file TCETargetTransformInfo.hh.

Referenced by getTLI().


The documentation for this class was generated from the following files: