summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorBrian Gaeke <gaeke@uiuc.edu>2004-06-08 20:08:30 +0000
committerBrian Gaeke <gaeke@uiuc.edu>2004-06-08 20:08:30 +0000
commitc365e7cc99cd7b30b888d070a030fb963b9b2701 (patch)
tree9ab14401cac90b541fed2b12bcff822c330e250f /llvm/lib
parent78d03b523fc275681bec88df11f04eee017ecbc7 (diff)
downloadbcm5719-llvm-c365e7cc99cd7b30b888d070a030fb963b9b2701.tar.gz
bcm5719-llvm-c365e7cc99cd7b30b888d070a030fb963b9b2701.zip
Fix a minor bug in the map - since this pass adds a global symbol, it must be
accounted for in the map (at least, in its current format). llvm-svn: 14075
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/SparcV9/InternalGlobalMapper.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/Target/SparcV9/InternalGlobalMapper.cpp b/llvm/lib/Target/SparcV9/InternalGlobalMapper.cpp
index 8df87fd0006..7d4a40a13be 100644
--- a/llvm/lib/Target/SparcV9/InternalGlobalMapper.cpp
+++ b/llvm/lib/Target/SparcV9/InternalGlobalMapper.cpp
@@ -54,6 +54,10 @@ bool InternalGlobalMapper::run (Module &M) {
// Populate the vector with internal global values and their names.
for (Module::giterator i = M.gbegin (), e = M.gend (); i != e; ++i)
maybeAddInternalValueToVector (gvvector, *i);
+ // Add an extra global for _llvm_internalGlobals itself (null,
+ // because it's not internal)
+ gvvector.push_back (ConstantPointerNull::get
+ (PointerType::get (Type::SByteTy)));
for (Module::iterator i = M.begin (), e = M.end (); i != e; ++i)
maybeAddInternalValueToVector (gvvector, *i);
OpenPOWER on IntegriCloud