1. Use SubtargetFeatures in llc/lli.
[oota-llvm.git] / lib / Target / PowerPC / PPCTargetMachine.h
1 //===-- PPC32TargetMachine.h - Define TargetMachine for PowerPC -*- C++ -*-=//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file was developed by the LLVM research group and is distributed under
6 // the University of Illinois Open Source License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file declares the PowerPC specific subclass of TargetMachine.
11 //
12 //===----------------------------------------------------------------------===//
13
14 #ifndef POWERPC32_TARGETMACHINE_H
15 #define POWERPC32_TARGETMACHINE_H
16
17 #include "PowerPCTargetMachine.h"
18 #include "PPC32JITInfo.h"
19 #include "PPC32InstrInfo.h"
20 #include "llvm/PassManager.h"
21
22 namespace llvm {
23
24 class IntrinsicLowering;
25
26 class PPC32TargetMachine : public PowerPCTargetMachine {
27   PPC32InstrInfo InstrInfo;
28   PPC32JITInfo JITInfo;
29
30 public:
31   PPC32TargetMachine(const Module &M, IntrinsicLowering *IL,
32                      const std::string &FS);
33   virtual const PPC32InstrInfo   *getInstrInfo() const { return &InstrInfo; }
34   virtual const MRegisterInfo *getRegisterInfo() const {
35     return &InstrInfo.getRegisterInfo();
36   }
37
38   virtual TargetJITInfo *getJITInfo() {
39     return &JITInfo;
40   }
41
42   static unsigned getJITMatchQuality();
43
44   static unsigned getModuleMatchQuality(const Module &M);
45
46   bool addPassesToEmitMachineCode(FunctionPassManager &PM,
47                                   MachineCodeEmitter &MCE);
48 };
49
50 } // end namespace llvm
51
52 #endif