[PATCH] D21255: Fix cloning GlobalValues with comdats across Modules.
Reid Kleckner via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 15 08:38:53 PDT 2016
rnk added a comment.
I think most users of copyAttributesFrom are not copying globals across modules, they are trying to RAUW in the current module. The one user that I know of (the IR linker) goes out of its way to copy the comdat separately. Anything wrong with forcing the cross-module use case to be a little more complicated? Such users already have to rewrite the initializer to avoid cross-module references, so rewriting the comdat as well isn't that crazy.
More information about the llvm-commits