| 20 | using namespace llvm; |
| 21 | |
| 22 | static void copyComdat(GlobalObject *Dst, const GlobalObject *Src) { |
| 23 | const Comdat *SC = Src->getComdat(); |
| 24 | if (!SC) |
| 25 | return; |
| 26 | Comdat *DC = Dst->getParent()->getOrInsertComdat(SC->getName()); |
| 27 | DC->setSelectionKind(SC->getSelectionKind()); |
| 28 | Dst->setComdat(DC); |
| 29 | } |
| 30 | |
| 31 | /// This is not as easy as it might seem because we have to worry about making |
| 32 | /// copies of global variables and functions, and making their (initializers and |
no test coverage detected