Use %ull here.
[llvm/stm8.git] / lib / Target / CellSPU / SPUTargetMachine.h
blob75abd5eb3fca8c0994658fba272e4ad01eed0e06
1 //===-- SPUTargetMachine.h - Define TargetMachine for Cell SPU ----*- C++ -*-=//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file declares the CellSPU-specific subclass of TargetMachine.
12 //===----------------------------------------------------------------------===//
14 #ifndef SPU_TARGETMACHINE_H
15 #define SPU_TARGETMACHINE_H
17 #include "SPUSubtarget.h"
18 #include "SPUInstrInfo.h"
19 #include "SPUISelLowering.h"
20 #include "SPUSelectionDAGInfo.h"
21 #include "SPUFrameLowering.h"
22 #include "llvm/Target/TargetMachine.h"
23 #include "llvm/Target/TargetData.h"
25 namespace llvm {
26 class PassManager;
27 class GlobalValue;
28 class TargetFrameLowering;
30 /// SPUTargetMachine
31 ///
32 class SPUTargetMachine : public LLVMTargetMachine {
33 SPUSubtarget Subtarget;
34 const TargetData DataLayout;
35 SPUInstrInfo InstrInfo;
36 SPUFrameLowering FrameLowering;
37 SPUTargetLowering TLInfo;
38 SPUSelectionDAGInfo TSInfo;
39 InstrItineraryData InstrItins;
40 public:
41 SPUTargetMachine(const Target &T, const std::string &TT,
42 const std::string &FS);
44 /// Return the subtarget implementation object
45 virtual const SPUSubtarget *getSubtargetImpl() const {
46 return &Subtarget;
48 virtual const SPUInstrInfo *getInstrInfo() const {
49 return &InstrInfo;
51 virtual const SPUFrameLowering *getFrameLowering() const {
52 return &FrameLowering;
54 /*!
55 \note Cell SPU does not support JIT today. It could support JIT at some
56 point.
58 virtual TargetJITInfo *getJITInfo() {
59 return NULL;
62 virtual const SPUTargetLowering *getTargetLowering() const {
63 return &TLInfo;
66 virtual const SPUSelectionDAGInfo* getSelectionDAGInfo() const {
67 return &TSInfo;
70 virtual const SPURegisterInfo *getRegisterInfo() const {
71 return &InstrInfo.getRegisterInfo();
74 virtual const TargetData *getTargetData() const {
75 return &DataLayout;
78 virtual const InstrItineraryData *getInstrItineraryData() const {
79 return &InstrItins;
82 // Pass Pipeline Configuration
83 virtual bool addInstSelector(PassManagerBase &PM,
84 CodeGenOpt::Level OptLevel);
85 virtual bool addPreEmitPass(PassManagerBase &, CodeGenOpt::Level);
88 } // end namespace llvm
90 #endif