[PATCH] Move DwarfCompileUnit::getOrCreateGlobalVariableDIE to DwarfUnit.

Frederic Riss friss at apple.com
Fri Oct 24 08:23:10 PDT 2014


Hi dblaikie,

I'm not sure this doesn't break some intended layering, but the end
goal is to call it from constructInportedEntityDIE which is in
DwarfUnit (along with the others getOrCreate* helpers) so I suppose
it's OK to move it there. (Another option is to move everything down
into DwarfCompileUnit, but if you want to create some other types of
Units, you might need this functionality in the base class).

BTW, although I think I can imaging where you are going to with the
code shuffling you are doing around the Dwarf(Compile)Unit, could you
explain a bit what the expected end result hierarchy looks like, and
what the responsabilities of each level will be? And maybe update the
file header comments of these 2 classes to reflect the difference.

Thanks!

http://reviews.llvm.org/D5975

Files:
  lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
  lib/CodeGen/AsmPrinter/DwarfCompileUnit.h
  lib/CodeGen/AsmPrinter/DwarfDebug.cpp
  lib/CodeGen/AsmPrinter/DwarfDebug.h
  lib/CodeGen/AsmPrinter/DwarfUnit.cpp
  lib/CodeGen/AsmPrinter/DwarfUnit.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D5975.15414.patch
Type: text/x-patch
Size: 15440 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141024/4c322936/attachment.bin>


More information about the llvm-commits mailing list