[LLVMdev] DIFactory interface is going away

Devang Patel dpatel at apple.com
Thu Feb 24 13:29:31 PST 2011


Hi All,

DIFactory interface, part of DebugInfo.h, is used to emit LLVM IR constructs to encode debugging information. We are replacing this interface with new simple interface, DIBuilder. 

Here is one example that demonstrates differences between two interfaces. To create debug information entries to encode volatile type one would use following call in a language front end,

	CreateDerivedType(DW_TAG_volatile_type, Context, StringRef(), File, 
                          0 /*line no*/, type_size_in_bits, type_align_in_bits, 
                          0 /* offset */, 0 /* flags */, OriginalType);

using DIFactory interface. Now, DIBuilder allows you to do the same using following call.

	createQualifiedType(DW_TAG_volatile_type, OriginalType);

DIBuilder interface was introduced in Nov/Dec last year. Now, clang has fully adopted this new interface. So we are going to remove DIFactory from llvm sources soon. Our plan is to move DIFactory interface in dragonegg (and llvm-gcc) for now until the front-ends adopt DIBuilder.

If you have any concerns about this plan, please speak up now.
-
Devang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110224/7ef6c76d/attachment.html>


More information about the llvm-dev mailing list