From 3ea23cff6521561f7b855b54786a369ac9abe128 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 2 Aug 2009 04:41:14 +0000 Subject: [PATCH] PIC16 TAI doesn't need TM llvm-svn: 77867 --- llvm/lib/Target/PIC16/PIC16TargetAsmInfo.cpp | 10 +++++----- llvm/lib/Target/PIC16/PIC16TargetAsmInfo.h | 7 +------ llvm/lib/Target/PIC16/PIC16TargetMachine.cpp | 2 +- 3 files changed, 7 insertions(+), 12 deletions(-) diff --git a/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.cpp b/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.cpp index 7a48a469101f..50fba39112a2 100644 --- a/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.cpp +++ b/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.cpp @@ -12,15 +12,15 @@ //===----------------------------------------------------------------------===// #include "PIC16TargetAsmInfo.h" -#include "PIC16TargetMachine.h" -#include "llvm/GlobalValue.h" -#include "llvm/GlobalVariable.h" -#include "llvm/DerivedTypes.h" +// FIXME: Layering violation to get enums and static function, should be moved +// to separate headers. +#include "PIC16.h" +#include "PIC16ISelLowering.h" using namespace llvm; PIC16TargetAsmInfo:: -PIC16TargetAsmInfo(const PIC16TargetMachine &TM) { +PIC16TargetAsmInfo() { CommentString = ";"; GlobalPrefix = PAN::getTagName(PAN::PREFIX_SYMBOL); GlobalDirective = "\tglobal\t"; diff --git a/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.h b/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.h index 8fb9e0c29eb4..d24aa6bd620d 100644 --- a/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.h +++ b/llvm/lib/Target/PIC16/PIC16TargetAsmInfo.h @@ -17,17 +17,12 @@ #include "llvm/Target/TargetAsmInfo.h" namespace llvm { - - // Forward declaration. - class PIC16TargetMachine; - class PIC16TargetAsmInfo : public TargetAsmInfo { const char *RomData8bitsDirective; const char *RomData16bitsDirective; const char *RomData32bitsDirective; public: - PIC16TargetAsmInfo(const PIC16TargetMachine &TM); - + PIC16TargetAsmInfo(); virtual const char *getDataASDirective(unsigned size, unsigned AS) const; }; diff --git a/llvm/lib/Target/PIC16/PIC16TargetMachine.cpp b/llvm/lib/Target/PIC16/PIC16TargetMachine.cpp index 6a4492c5484b..1c5d3d4f2e57 100644 --- a/llvm/lib/Target/PIC16/PIC16TargetMachine.cpp +++ b/llvm/lib/Target/PIC16/PIC16TargetMachine.cpp @@ -38,7 +38,7 @@ CooperTargetMachine::CooperTargetMachine(const Target &T, const Module &M, const TargetAsmInfo *PIC16TargetMachine::createTargetAsmInfo() const { - return new PIC16TargetAsmInfo(*this); + return new PIC16TargetAsmInfo(); } bool PIC16TargetMachine::addInstSelector(PassManagerBase &PM,