Only request the `classes_by_source` product if it is necessary

Review Request #2939 - Created Oct. 7, 2015 and submitted

Stu Hood
jsirois, mateor, patricklaw

The classes_by_source product is expensive to compute, and was only (really) used to provide source-to-classnames lookups in cases where a sourcefile was specified to the --test option.

Dropping this dependency means that we will not parse zinc analysis files or iterate over classnames for unchanged targets during incremental compiles. I haven't done any benchmarking, but from previous profiling sessions I expect that it's significant.

  • Use the runtime_classpath rather than classes_by_source to compute coverage patterns
  • Extract the intepret_test_spec method for reuse
  • Make requesting classes_by_source optional, and test this

Patrick Lawson
John Sirois
Stu Hood
Review request changed

Status: Closed (submitted)

Change Summary:

Merged as 9a9656c664ac27d85c62347eb03ad021cfd175e9

Benjy Weinberger

Can we consider dropping the ability to specify tests by sourcefile, and instead require specfying them by FQCN? Then we could remove a little bit of complexity entirely.