http://llvm.org/bugs/show_bug.cgi?id=15873
Bug ID: 15873
Summary: IR Builder: Ability to insert comments
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: Bitcode Writer
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
When writing a program that uses the IR Builder to generate IR code, it would
be extremely helpful to be able to insert comments so that when you look at
module.Dump() you can see some debug information.
For example, something like this:
LLVMBasicBlockRef entry = LLVMAppendBasicBlock(fac, "entry");
LLVMPrependComment(entry, "converted from such and such code");
...
LLVMValueRef If = LLVMBuildICmp(builder, LLVMIntEQ, n,
LLVMConstInt(LLVMInt32Type(), 0, 0), "n == 0");
LLVMPrependComment(If, "blah blah blah");
And when the module is dumped, looks something like this:
; converted from such and such code
entry:
...
; blah blah blah
%0 = icmp eq i32 0, 0
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs