Switch the type field in DIVariable and DIGlobalVariable over to DITypeRefs.

This allows us to catch more opportunities for ODR-based type uniquing
during LTO.
Paired commit with CFE which updates some testcases to verify the new
DIBuilder behavior.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204106 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Adrian Prantl
2014-03-18 02:34:58 +00:00
parent 4d82ca7462
commit 5e8144df32
9 changed files with 51 additions and 32 deletions

View File

@ -1604,7 +1604,7 @@ void DwarfCompileUnit::createGlobalVariableDIE(DIGlobalVariable GV) {
assert(GV.isGlobalVariable());
DIScope GVContext = GV.getContext();
DIType GTy = GV.getType();
DIType GTy = DD->resolve(GV.getType());
// If this is a static data member definition, some attributes belong
// to the declaration DIE.