This is an archive of the discontinued LLVM Phabricator instance.

Allow specification of what kinds of class members to dump
ClosedPublic

Authored by zturner on Apr 6 2017, 4:09 PM.

Details

Summary

Now instead of just no-class-definitions, we can get a little more granular. This is now an enum, with 3 possible values: 1) None - Don't display any class definitions. This is equivalent to specifying -no-class-definitions before. 2) Layout - Displays only class members which affect class layout -- e.g. data members. All functions, typedefs, nested classes, etc will be suppressed. 3) Full - Displays everything. This is equivalent to the default behavior before this patch, and is still the default behavior after this patch.

Diff Detail

Event Timeline

zturner created this revision.Apr 6 2017, 4:09 PM
zturner updated this revision to Diff 94458.Apr 6 2017, 4:41 PM

Slightly better logic in layout mode. It was dumping constants and static members before which don't occupy any space in a record.

amccarth accepted this revision.Apr 6 2017, 4:45 PM

LGTM.

Clang-format did some awkward comment wrapping in some of the new code.

When the Native reader catches up, we'll have to update the test config to run the tests on all platforms, which may require the -output-color=false options, but that'll probably be my problem later.

llvm/tools/llvm-pdbdump/PrettyClassDefinitionDumper.cpp
80

Can you fix the wrapping on these comments?

This revision is now accepted and ready to land.Apr 6 2017, 4:45 PM
This revision was automatically updated to reflect the committed changes.