OSDN Git Service

If a metadata operand is seeded in value map and the metadata should also be seeded...
authorDevang Patel <dpatel@apple.com>
Tue, 22 Jun 2010 22:53:21 +0000 (22:53 +0000)
committerDevang Patel <dpatel@apple.com>
Tue, 22 Jun 2010 22:53:21 +0000 (22:53 +0000)
commit186b3d260643de5db63c4bab15beceb9edaee396
tree20ba5462d067bbef2aa2537eabdc8cd7b3a2d4c6
parent3bf329f49512e633df430c097bfd5bdaa122ba55
If a metadata operand is seeded in value map and the metadata should also be seeded in value map. This is not limited to function local metadata.

Failure to seed metdata in such cases causes troubles when in a cloned module, metadata from a new module refers to values in old module. Usually this results in mysterious bugpoint crashes. For example,

 Checking to see if we can delete global inits: Unknown constant!
 UNREACHABLE executed at /d/g/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp:904!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106592 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Utils/ValueMapper.cpp