[llvm-commits] CVS: llvm/lib/Target/IA64/IA64TargetMachine.cpp IA64TargetMachine.h
Chris Lattner
lattner at cs.uiuc.edu
Sat Aug 26 14:33:19 PDT 2006
Changes in directory llvm/lib/Target/IA64:
IA64TargetMachine.cpp updated: 1.17 -> 1.18
IA64TargetMachine.h updated: 1.11 -> 1.12
---
Log message:
Fix target matching weights, so that ppc-darwin modules are codegen with the
ppc target, not the itanium target, when run on an itanium machine.
This should fix the CodeGen/PowerPC regtest failures on itanium.
---
Diffs of the changes: (+7 -13)
IA64TargetMachine.cpp | 19 +++++++------------
IA64TargetMachine.h | 1 -
2 files changed, 7 insertions(+), 13 deletions(-)
Index: llvm/lib/Target/IA64/IA64TargetMachine.cpp
diff -u llvm/lib/Target/IA64/IA64TargetMachine.cpp:1.17 llvm/lib/Target/IA64/IA64TargetMachine.cpp:1.18
--- llvm/lib/Target/IA64/IA64TargetMachine.cpp:1.17 Fri Jun 16 13:22:52 2006
+++ llvm/lib/Target/IA64/IA64TargetMachine.cpp Sat Aug 26 16:33:05 2006
@@ -44,14 +44,6 @@
RegisterTarget<IA64TargetMachine> X("ia64", " IA-64 (Itanium)");
}
-unsigned IA64TargetMachine::compileTimeMatchQuality() {
-#if defined(__ia64__) || defined(__IA64__)
- return 50;
-#else
- return 0;
-#endif
-}
-
unsigned IA64TargetMachine::getModuleMatchQuality(const Module &M) {
// we match [iI][aA]*64
bool seenIA64=false;
@@ -65,12 +57,15 @@
seenIA64=true;
}
- if(seenIA64)
- return 50; // strong match
+ if (seenIA64)
+ return 20; // strong match
}
- return compileTimeMatchQuality()/2;
-
+#if defined(__ia64__) || defined(__IA64__)
+ return 5;
+#else
+ return 0;
+#endif
}
/// IA64TargetMachine ctor - Create an LP64 architecture model
Index: llvm/lib/Target/IA64/IA64TargetMachine.h
diff -u llvm/lib/Target/IA64/IA64TargetMachine.h:1.11 llvm/lib/Target/IA64/IA64TargetMachine.h:1.12
--- llvm/lib/Target/IA64/IA64TargetMachine.h:1.11 Fri May 12 18:26:11 2006
+++ llvm/lib/Target/IA64/IA64TargetMachine.h Sat Aug 26 16:33:05 2006
@@ -46,7 +46,6 @@
CodeGenFileType FileType, bool Fast);
static unsigned getModuleMatchQuality(const Module &M);
- static unsigned compileTimeMatchQuality(void);
};
} // End llvm namespace
More information about the llvm-commits
mailing list