[Mesa-dev] [PATCH] i965: Enable disk shader cache by default
Jordan Justen
jordan.l.justen at intel.com
Tue Dec 5 20:42:00 UTC 2017
On 2017-12-05 09:13:11, Mark Janes wrote:
> Jordan Justen <jordan.l.justen at intel.com> writes:
>
> > On 2017-11-08 17:26:47, Timothy Arceri wrote:
> >> Reviewed-by: Timothy Arceri <tarceri at itsqueeze.com>
> >>
> >> Mark may want to consider adding some of the once a day type CI runs for
> >> this. For example running the test suite for two consecutive runs on the
> >> same build so that the second run uses the shader cache and also a
> >> second run the uses MESA_GLSL=cache_fb to force testing of the cache
> >> fallback path.
> >
> > Yeah. We discussed this previously, but I don't think it's been
> > implemented yet. My opinion is that it could perhaps be a weekly test.
>
> This automation is implemented now. It found the issues reported in
> https://bugs.freedesktop.org/show_bug.cgi?id=103988
>
> My opinion is that this test strategy is inadequate.
Meaning you think we cannot enable i965 shader cache for the 18.0
release?
We are already ~1.5 months away from the next stable branch point. If
we want to enable this in 18.0, we should be using this time to see if
enabling the cache by default has some large unexpected side effect in
our graphics stack, or breaks real-world apps.
> Adding a dimension
> to the test matrix has high cost, especially when combined with other
> dimensions of the test matrix (does shader cache need to be tested for
> 32/64 bit builds? For hswgt1/hswgt2/hswgt3e?).
Are you saying this is too high cost to run per check-in? Do you need
to disable it for the health of CI? I think I proposed that daily, or
perhaps even weekly would be adequate.
These tests are already identifying some corner case issues. I'm not
sure these would have impacted real-world apps yet, but I do think it
is a good idea to run these tests regularly.
You say this test strategy is inadequate. Perhaps. I do think it needs
to be part of our test strategy. There is no way we are going to hit
all the corners of the API better than running all of our tests with
the cache enabled. Do you agree?
> Since 103988 is not hardware specific, and is not a regression, it's not
> something that could only have been caught by CI. I'm surprised to find
> it at this point, considering piglit was used to validate the feature.
>
> I'd be happy if there was at least a smoke test where complex programs
> are cached, with the intent of exercising the shader cache mechanism
> directly. It doesn't have to be exhaustive to be effective. Seems like
> a good idea to at least directly test the issue that was fixed in
> 103988 tests.
It could be interesting to define a MESA extension to control or query
the shader cache. Today, the shader cache is a nearly 'invisible'
feature. There are a few env-vars, but I wouldn't call a public
interface.
The downside of defining an extension is that it might constrain
changes to the shader cache implementation. Or, if the interface is
too complex, then it may be tough for some drivers to implement.
But, what if we get around to defining and implementing this extenion,
(and a few piglit tests that makes use of it), by mid-January? It'll
still be pretty difficult to argue we should enable the shader cache
on i965 for 18.0, since we burned all the time to let it be tested on
master against real-world apps.
Also, while you say our current test strategy is inadequate, I do
think it is still far more comprehensive than anything we will
accomplish by defining a new extension and writing a few, or even a
few hundred tests against the new extension.
-Jordan
More information about the mesa-dev
mailing list