This is an archive of the discontinued LLVM Phabricator instance.

[LNT] Run configure earlier in runtest test-suite [NFC]
ClosedPublic

Authored by kristof.beyls on Feb 10 2017, 4:52 AM.

Details

Summary

This is in preparation for follow-on work where we'll extract the
compiler used from the CMakeCache rather than from the --cc
command line option. For that to work, however, the configure step
has to be run before the first time self._get_cc_info() gets called.

This also simplifies the need-to-configure logic a bit.

Diff Detail

Repository
rL LLVM

Event Timeline

kristof.beyls created this revision.Feb 10 2017, 4:52 AM
MatzeB accepted this revision.Feb 10 2017, 10:40 AM

LGTM, nitpicks below

lnt/tests/test_suite.py
530–536 ↗(On Diff #87983)

The _get_path() function boils down to to calling mkdir_p(self._base_path) should be easier/more obvious to just inline it instead of creating a function.

533–534 ↗(On Diff #87983)

I consider if not exists: create an anti-pattern, just do mkdir_p() it'll be fine if the directory already exists.

538 ↗(On Diff #87983)

Could this be _configure_if_neede()?

This revision is now accepted and ready to land.Feb 10 2017, 10:40 AM
cmatthews accepted this revision.Feb 10 2017, 12:31 PM
This revision was automatically updated to reflect the committed changes.