blob: 587d1552f754ad82c2d9e29b0a8fe12a5c1c9a28 [file] [log] [blame]
Misha Brukmanadde6992004-08-17 04:57:37 +00001//===-- PPC64TargetMachine.h - Define TargetMachine for PowerPC64 -*- C++ -*-=//
Misha Brukmanc0f64202004-08-11 00:10:41 +00002//
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//
Misha Brukmanadde6992004-08-17 04:57:37 +000010// This file declares the PowerPC specific subclass of TargetMachine.
Misha Brukmanc0f64202004-08-11 00:10:41 +000011//
12//===----------------------------------------------------------------------===//
13
Misha Brukmanadde6992004-08-17 04:57:37 +000014#ifndef POWERPC64_TARGETMACHINE_H
15#define POWERPC64_TARGETMACHINE_H
Misha Brukmanc0f64202004-08-11 00:10:41 +000016
17#include "PowerPCTargetMachine.h"
Misha Brukmanadde6992004-08-17 04:57:37 +000018#include "PPC64InstrInfo.h"
19#include "llvm/PassManager.h"
Misha Brukmanc0f64202004-08-11 00:10:41 +000020
21namespace llvm {
22
Misha Brukmanadde6992004-08-17 04:57:37 +000023class IntrinsicLowering;
24
Misha Brukmanc0f64202004-08-11 00:10:41 +000025class PPC64TargetMachine : public PowerPCTargetMachine {
Misha Brukmanadde6992004-08-17 04:57:37 +000026 PPC64InstrInfo InstrInfo;
27
Misha Brukmanc0f64202004-08-11 00:10:41 +000028public:
29 PPC64TargetMachine(const Module &M, IntrinsicLowering *IL);
Misha Brukmanadde6992004-08-17 04:57:37 +000030 virtual const PPC64InstrInfo *getInstrInfo() const { return &InstrInfo; }
31 virtual const MRegisterInfo *getRegisterInfo() const {
32 return &InstrInfo.getRegisterInfo();
33 }
Misha Brukmanc0f64202004-08-11 00:10:41 +000034
Misha Brukmanc0f64202004-08-11 00:10:41 +000035 static unsigned getModuleMatchQuality(const Module &M);
Misha Brukmanadde6992004-08-17 04:57:37 +000036
37 bool addPassesToEmitMachineCode(FunctionPassManager &PM,
38 MachineCodeEmitter &MCE);
Misha Brukmanc0f64202004-08-11 00:10:41 +000039};
40
41} // end namespace llvm
42
43#endif