[llvm-commits] CVS: llvm/lib/Target/X86/X86TargetMachine.cpp X86TargetMachine.h
Jim Laskey
jlaskey at apple.com
Thu Sep 7 16:39:52 PDT 2006
Changes in directory llvm/lib/Target/X86:
X86TargetMachine.cpp updated: 1.125 -> 1.126
X86TargetMachine.h updated: 1.39 -> 1.40
---
Log message:
1. Remove condition on delete.
2. Protect and outline createTargetAsmInfo.
3. Misc. kruft.
---
Diffs of the changes: (+9 -5)
X86TargetMachine.cpp | 5 +++++
X86TargetMachine.h | 9 ++++-----
2 files changed, 9 insertions(+), 5 deletions(-)
Index: llvm/lib/Target/X86/X86TargetMachine.cpp
diff -u llvm/lib/Target/X86/X86TargetMachine.cpp:1.125 llvm/lib/Target/X86/X86TargetMachine.cpp:1.126
--- llvm/lib/Target/X86/X86TargetMachine.cpp:1.125 Mon Sep 4 13:48:41 2006
+++ llvm/lib/Target/X86/X86TargetMachine.cpp Thu Sep 7 18:39:26 2006
@@ -11,6 +11,7 @@
//
//===----------------------------------------------------------------------===//
+#include "X86TargetAsmInfo.h"
#include "X86TargetMachine.h"
#include "X86.h"
#include "llvm/Module.h"
@@ -35,6 +36,10 @@
RegisterTarget<X86TargetMachine> X("x86", " IA-32 (Pentium and above)");
}
+const TargetAsmInfo *X86TargetMachine::createTargetAsmInfo() const {
+ return new X86TargetAsmInfo(*this);
+}
+
unsigned X86TargetMachine::getJITMatchQuality() {
#if defined(i386) || defined(__i386__) || defined(__x86__) || defined(_M_IX86)
return 10;
Index: llvm/lib/Target/X86/X86TargetMachine.h
diff -u llvm/lib/Target/X86/X86TargetMachine.h:1.39 llvm/lib/Target/X86/X86TargetMachine.h:1.40
--- llvm/lib/Target/X86/X86TargetMachine.h:1.39 Thu Sep 7 17:06:40 2006
+++ llvm/lib/Target/X86/X86TargetMachine.h Thu Sep 7 18:39:26 2006
@@ -21,7 +21,6 @@
#include "X86InstrInfo.h"
#include "X86JITInfo.h"
#include "X86Subtarget.h"
-#include "X86TargetAsmInfo.h"
#include "X86ISelLowering.h"
namespace llvm {
@@ -33,6 +32,10 @@
X86InstrInfo InstrInfo;
X86JITInfo JITInfo;
X86TargetLowering TLInfo;
+
+protected:
+ virtual const TargetAsmInfo *createTargetAsmInfo() const;
+
public:
X86TargetMachine(const Module &M, const std::string &FS);
@@ -51,10 +54,6 @@
static unsigned getModuleMatchQuality(const Module &M);
static unsigned getJITMatchQuality();
- virtual const TargetAsmInfo *createTargetAsmInfo() const {
- return static_cast<const TargetAsmInfo *>(new X86TargetAsmInfo(*this));
- }
-
// Set up the pass pipeline.
virtual bool addInstSelector(FunctionPassManager &PM, bool Fast);
virtual bool addPostRegAlloc(FunctionPassManager &PM, bool Fast);
More information about the llvm-commits
mailing list