[PATCH] Emit Clang version information into .comment section (LLVM's part of implementation) [PART 2]

Rafael Ávila de Espíndola rafael.espindola at gmail.com
Mon Sep 30 14:34:36 PDT 2013



================
Comment at: include/llvm/CodeGen/AsmPrinter.h:490
@@ -489,1 +489,3 @@
     void EmitLLVMUsedList(const ConstantArray *InitList);
+    /// EmitModuleIdents - Emit llvm.ident metadata in an '.ident' directive.
+    void EmitModuleIdents(Module &M);
----------------
Please don't repeat the function name in the comment.

================
Comment at: include/llvm/CodeGen/AsmPrinter.h:491
@@ -490,1 +490,3 @@
+    /// EmitModuleIdents - Emit llvm.ident metadata in an '.ident' directive.
+    void EmitModuleIdents(Module &M);
     void EmitXXStructorList(const Constant *List, bool isCtor);
----------------
emitModuleIdents would be the correct name according the the style guide. EmitModuleIdents is OK for now if you want.

================
Comment at: test/CodeGen/X86/ident-metadata.ll:18
@@ +17,3 @@
+!0 = metadata !{metadata !"clang version x.x"}
+!1 = metadata !{metadata !"something else", metadata !"plus another"}
+!2 = metadata !{i32 1}
----------------
Why do we need to support both ways of having multiple .ident? It would be better to say (and check in the verifier) that a each metadata node in a llvm.ident consists of just one string.



http://llvm-reviews.chandlerc.com/D1729



More information about the llvm-commits mailing list