Add getSymbolAlignment to the ObjectFile interface.
authorRafael Espindola <rafael.espindola@gmail.com>
Mon, 29 Apr 2013 22:24:22 +0000 (22:24 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Mon, 29 Apr 2013 22:24:22 +0000 (22:24 +0000)
commit59a0e79631ed851d98cf9c2ba6fa5f9aafdfdc93
treea910559464f8b9b14301d59fcb7948052071b3bd
parentd8b2da11360419a9f1d569468a9b2a8ca3dace20
Add getSymbolAlignment to the ObjectFile interface.

For regular object files this is only meaningful for common symbols. An object
file format with direct support for atoms should be able to provide alignment
information for all symbols.

This replaces getCommonSymbolAlignment and fixes
test-common-symbols-alignment.ll on darwin. This also includes a fix to
MachOObjectFile::getSymbolFlags. It was marking undefined symbols as common
(already tested by existing mcjit tests now that it is used).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@180736 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Object/ELF.h
include/llvm/Object/MachO.h
include/llvm/Object/ObjectFile.h
lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
lib/Object/MachOObjectFile.cpp
lib/Object/ObjectFile.cpp
test/ExecutionEngine/MCJIT/test-common-symbols-alignment.ll