Redo "Make global aliases have symbol size equal to their type"
r242520 was reverted in r244313 as the expected behaviour of the alias attribute in C is that the alias has the same size as the aliasee. However we can re-introduce adding the size on the alias when the aliasee does not, from a source code or object perspective, exist as a discrete entity. This happens when the aliasee is not a symbol, or when that symbol is private. Differential Revision: http://reviews.llvm.org/D11943 llvm-svn: 244752
Showing
- llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp 14 additions, 0 deletionsllvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
- llvm/test/CodeGen/AArch64/global-merge-2.ll 3 additions, 0 deletionsllvm/test/CodeGen/AArch64/global-merge-2.ll
- llvm/test/CodeGen/AArch64/global-merge-3.ll 2 additions, 0 deletionsllvm/test/CodeGen/AArch64/global-merge-3.ll
- llvm/test/CodeGen/ARM/aliases.ll 20 additions, 0 deletionsllvm/test/CodeGen/ARM/aliases.ll
- llvm/test/CodeGen/ARM/global-merge-external.ll 3 additions, 0 deletionsllvm/test/CodeGen/ARM/global-merge-external.ll
Loading
Please register or sign in to comment