The constant merging pass has no qualms about merging constants with external
linkage, which causes link errors later. It should only merge constants away
that have internal linkage.
This is tested as:
test/Regression/Transforms/ConstantMerge/2003-10-28-MergeExternalConstants.ll
This causes undefined symbols in libstdc++, specifically "std::ios_base::badbit".
Extended Description
The constant merging pass has no qualms about merging constants with external linkage, which causes link errors later. It should only merge constants away that have internal linkage.
This is tested as: test/Regression/Transforms/ConstantMerge/2003-10-28-MergeExternalConstants.ll
This causes undefined symbols in libstdc++, specifically "std::ios_base::badbit".