This is an archive of the discontinued LLVM Phabricator instance.

[lldb][test] 1 - Don't do test-replication for gmodules debug_info variant
ClosedPublic

Authored by Michael137 on Sep 23 2022, 2:47 AM.

Details

Summary

Currently, by default LLDB runs an API test with 3 variants,
one of which, depending on platform, is gmodules. However,
most tests don't actually make use of any specific gmodules
feature since they compile a single main.cpp file without
imporint types from other modules.

Instead of running all tests an extra time with -gmodules
enabled, we plan to test gmodules features with dedicated
API tests that explicitly opt-into compiling with -gmodules.
One of the main benefits of this will be a reduction in total
API test-suite run-time (by around 1/3).

This patch adds a flag to debug_info_categories that indicates
whether a category is eligible to be replicated by lldbtest.

Keeping gmodules a debug-info category is desirable because
builder.py knows how to inject the appropriate Makefile flags
into the build command for debug-info categories already. Whereas
for non-debug-info categories we'd have to teach it how to. The
category is inferred from the test-name debug-info suffix currently.

Diff Detail

Event Timeline

Michael137 created this revision.Sep 23 2022, 2:47 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 23 2022, 2:47 AM
Michael137 requested review of this revision.Sep 23 2022, 2:47 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 23 2022, 2:47 AM
  • Fixup prototype
labath accepted this revision.Sep 23 2022, 3:21 AM
This revision is now accepted and ready to land.Sep 23 2022, 3:21 AM
  • Reword commit
  • Add docs
Michael137 retitled this revision from [WIP][lldb][test] 1 - Remove gmodules debug_info variant: add decorator for API tests that explicitly test gmodules to [lldb][test] 1 - Don't do test-replication for gmodules debug_info variant.Sep 23 2022, 4:53 PM