[llvm-commits] [llvm] r58895 - in /llvm/trunk: include/llvm/CodeGen/MachineRelocation.h lib/ExecutionEngine/JIT/JITEmitter.cpp
Evan Cheng
evan.cheng at apple.com
Fri Nov 7 23:37:34 PST 2008
Author: evancheng
Date: Sat Nov 8 01:37:34 2008
New Revision: 58895
URL: http://llvm.org/viewvc/llvm-project?rev=58895&view=rev
Log:
Rename isString -> isExternalSymbol; getString -> getExternalSymbol since these work on externsym machine relocations.
Modified:
llvm/trunk/include/llvm/CodeGen/MachineRelocation.h
llvm/trunk/lib/ExecutionEngine/JIT/JITEmitter.cpp
Modified: llvm/trunk/include/llvm/CodeGen/MachineRelocation.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/MachineRelocation.h?rev=58895&r1=58894&r2=58895&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/MachineRelocation.h (original)
+++ llvm/trunk/include/llvm/CodeGen/MachineRelocation.h Sat Nov 8 01:37:34 2008
@@ -234,9 +234,9 @@
return AddrType == isBB;
}
- /// isString - Return true if this is a constant string.
+ /// isExternalSymbol - Return true if this is a constant string.
///
- bool isString() const {
+ bool isExternalSymbol() const {
return AddrType == isExtSym;
}
@@ -287,8 +287,8 @@
/// getString - If this is a string value, return the string reference.
///
- const char *getString() const {
- assert(isString() && "This is not a string reference!");
+ const char *getExternalSymbol() const {
+ assert(isExternalSymbol() && "This is not an external symbol reference!");
return Target.ExtSym;
}
Modified: llvm/trunk/lib/ExecutionEngine/JIT/JITEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/JIT/JITEmitter.cpp?rev=58895&r1=58894&r2=58895&view=diff
==============================================================================
--- llvm/trunk/lib/ExecutionEngine/JIT/JITEmitter.cpp (original)
+++ llvm/trunk/lib/ExecutionEngine/JIT/JITEmitter.cpp Sat Nov 8 01:37:34 2008
@@ -885,9 +885,9 @@
MachineRelocation &MR = Relocations[i];
void *ResultPtr = 0;
if (!MR.letTargetResolve()) {
- if (MR.isString()) {
- ResultPtr = TheJIT->getPointerToNamedFunction(MR.getString());
- DOUT << "JIT: Map \'" << MR.getString() << "\' to ["
+ if (MR.isExternalSymbol()) {
+ ResultPtr = TheJIT->getPointerToNamedFunction(MR.getExternalSymbol());
+ DOUT << "JIT: Map \'" << MR.getExternalSymbol() << "\' to ["
<< ResultPtr << "]\n";
// If the target REALLY wants a stub for this function, emit it now.
More information about the llvm-commits
mailing list