[PATCH] D47615: [DebugInfo] Refactoring DIType::setFlags to DIType::cloneWithFlags

Adrian Prantl via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 1 14:39:44 PDT 2018


aprantl accepted this revision.
aprantl added a comment.
This revision is now accepted and ready to land.

Looks good. I have a few nitpicks about the doxygen comments inline, but otherwise this is good to go!



================
Comment at: include/llvm/IR/DIBuilder.h:518
 
-    /// Create a new DIType* with "artificial" flag set.
-    DIType *createArtificialType(DIType *Ty);
+    /// Create a new distinct DISubprogram* with "artificial" flag set.
+    static DISubprogram *createArtificialSubprogram(DISubprogram *SP);
----------------
`Create a distinct clone of SP with DIFlagArtificial set.` ?


================
Comment at: include/llvm/IR/DIBuilder.h:521
 
-    /// Create a new DIType* with the "object pointer"
-    /// flag set.
-    DIType *createObjectPointerType(DIType *Ty);
+    /// Create a new uniqued DIType* with "artificial" flag set.
+    static DIType *createArtificialType(DIType *Ty);
----------------
`Create a uniqued clone of Ty with DIFlagArtificial set.`


================
Comment at: include/llvm/IR/DIBuilder.h:524
+
+    /// Create a new uniqued DIType* with the "object pointer" flag set.
+    static DIType *createObjectPointerType(DIType *Ty);
----------------
etc.


Repository:
  rL LLVM

https://reviews.llvm.org/D47615





More information about the llvm-commits mailing list