This is an archive of the discontinued LLVM Phabricator instance.

[flang][test] Share all driver test dirs between `f18` and `flang-new`
ClosedPublic

Authored by awarzynski on Feb 22 2021, 10:13 AM.

Details

Summary

Originally, when we added the new driver, we created dedicated test
directories for flang-new. This way we separated the tests for the
throwaway and the new driver.

As we are increasing test coverage and starting to share tests between
the two drivers, it makes sense to share all directories and instead
rely on:

! REQUIRES: new-flang-driver

to mark tests as exclusively for the new driver.

Diff Detail

Event Timeline

awarzynski created this revision.Feb 22 2021, 10:13 AM
awarzynski requested review of this revision.Feb 22 2021, 10:13 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 22 2021, 10:13 AM

It looks like there are other tests in Flang-Driver that can be run on f18 as well. That doesn't have to happen in this change if you prefer not to.

flang/test/Frontend/prescanner-diag.f90
5

I think you need to keep the %f18 command so that the test is run on f18 when the new driver is enabled. Unfortunately that means when it is disabled the same test is run on f18 three times, but none of these should take much time.

It looks like there are other tests in Flang-Driver that can be run on f18 as well. That doesn't have to happen in this change if you prefer not to.

Thank you for reviewing Tim!

Yes, I'll port other tests separately. This patch is mostly about enabling https://reviews.llvm.org/D97197.

flang/test/Frontend/prescanner-diag.f90
5

Do we _want_ to test f18 when the new driver is enabled?

I'm fine to keep %f18 here, but so far we've been using %flang and %flang_fc1 for tests that are shared between the drivers. We've already ported quite a few tests this way (e.g. preprocessor tests) and diverging from that approach might be confusing for us later.

tskeith accepted this revision.Feb 23 2021, 9:05 AM
tskeith added inline comments.
flang/test/Frontend/prescanner-diag.f90
5

OK, that makes sense. I guess devs working on the new driver have to do a build with the new driver disabled anyway to be sure the tests still pass with f18. I was thinking that could be avoided, but maybe not.

This revision is now accepted and ready to land.Feb 23 2021, 9:05 AM