mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-19 02:52:53 +02:00
Set the unnamed_addr only when we're creating a new GV in the dest module.
llvm-svn: 128507
This commit is contained in:
parent
48a0bb7712
commit
83903bc85f
@ -505,6 +505,7 @@ static bool LinkGlobals(Module *Dest, const Module *Src,
|
|||||||
SGV->getType()->getAddressSpace());
|
SGV->getType()->getAddressSpace());
|
||||||
// Propagate alignment, visibility and section info.
|
// Propagate alignment, visibility and section info.
|
||||||
CopyGVAttributes(NewDGV, SGV);
|
CopyGVAttributes(NewDGV, SGV);
|
||||||
|
NewDGV->setUnnamedAddr(SGV->hasUnnamedAddr());
|
||||||
|
|
||||||
// If the LLVM runtime renamed the global, but it is an externally visible
|
// If the LLVM runtime renamed the global, but it is an externally visible
|
||||||
// symbol, DGV must be an existing global with internal linkage. Rename
|
// symbol, DGV must be an existing global with internal linkage. Rename
|
||||||
|
Loading…
Reference in New Issue
Block a user