[llvm-commits] [llvm] r77619 - /llvm/trunk/lib/VMCore/Module.cpp
Devang Patel
dpatel at apple.com
Thu Jul 30 11:46:30 PDT 2009
Author: dpatel
Date: Thu Jul 30 13:46:29 2009
New Revision: 77619
URL: http://llvm.org/viewvc/llvm-project?rev=77619&view=rev
Log:
Do not use getNamedValue() to lookup NamedMDNode. NamedMDNode is not a GlobalValue.
Thanks Benjamin Kramer!
Modified:
llvm/trunk/lib/VMCore/Module.cpp
Modified: llvm/trunk/lib/VMCore/Module.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/Module.cpp?rev=77619&r1=77618&r2=77619&view=diff
==============================================================================
--- llvm/trunk/lib/VMCore/Module.cpp (original)
+++ llvm/trunk/lib/VMCore/Module.cpp Thu Jul 30 13:46:29 2009
@@ -293,7 +293,7 @@
/// specified name. This method returns null if a MDNode with the specified
/// name is not found.
NamedMDNode *Module::getNamedMetadata(const StringRef &Name) const {
- return dyn_cast_or_null<NamedMDNode>(getNamedValue(Name));
+ return dyn_cast_or_null<NamedMDNode>(getValueSymbolTable().lookup(Name));
}
//===----------------------------------------------------------------------===//
More information about the llvm-commits
mailing list