[PATCH] D85437: [DebugInfo] Fix initialization of DwarfCompileUnit::LabelBegin.

David Blaikie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 6 16:32:54 PDT 2020


dblaikie added inline comments.


================
Comment at: llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.h:60
   /// The start of the unit within its section.
-  MCSymbol *LabelBegin;
+  MCSymbol *LabelBegin = nullptr;
 
----------------
Is this used before its initialization - generally nice not to prematurely initiliaze things, because it thwarts checking like msan that might find bugs if this isn't intended to be used until after some other initialization.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85437/new/

https://reviews.llvm.org/D85437



More information about the llvm-commits mailing list