[Mesa-dev] [RFC] r600g: evergreen/cayman tessellation support

Aaron Watry awatry at gmail.com
Thu Dec 3 09:01:22 PST 2015


Hi Dave (and others),

I cloned your fdo r600g-tess-submit branch and gave it a spin on CEDAR
(Radeon 5400, kernel 4.3.0) with Heaven, and ran into a few issues.

1) Initially, I got an assertion in r600_add_atom stating that the atom ID
was not less than the R600_NUM_ATOMS value (id = 51, R600_NUM_ATOMS=51).
  I bumped R600_NUM_ATOMS to 52 for now, and that got rid of that issue...
although I have no idea if that was a correct fix.

2) Next, I kept getting a segfault in evergreen_adjust_gprs at line 3931.
Turns out that rctx->hw_shader_stages[2].shader was null
(missing/miscompiled GS?).

I naively changed the code to the following, and now Heaven actually runs
with tessellation enabled (and it looks like it's working).

    /* gather required shader gprs */
    for (i = 0; i < EG_NUM_HW_STAGES; i++) {
        if (!rctx->hw_shader_stages[i].shader) {
            num_gprs[i] = def_gprs[i];
            continue;
        }
        num_gprs[i] = rctx->hw_shader_stages[i].shader->shader.bc.ngpr;
    }

Just figured that I'd let you know...

If you don't have CEDAR hardware to test with, feel free to ping me to test
any additional changes.  Note that I didn't run the benchmark to completion
(too slow, had to get other work done), but it didn't hang my GPU in the
time that I did have it running.

--Aaron


On Mon, Nov 30, 2015 at 12:20 AM, Dave Airlie <airlied at gmail.com> wrote:

> Hi,
>
> Patchbomb time, this set of patches is a first pass at add adding
> ARB_tessellation_shader support to the r600g driver. Only Evergreen
> and newer GPUs support tessellation. On any of the GPUs that support
> native FP64, this will enable OpenGL 4.1 on them.
>
> The first bunch of patches are a bit of a driver rework to get
> things in better shape for tessellation, they shouldn't cause
> any regressions.
>
> This runs heaven on cayman and should pass all the piglits
> unless I've done something wrong.
>
> Development hit two HW programming fun times, one with tess and
> dynamic GPR interaction requiring disabling dynamic GPRs, and
> one with programming of some SIMD registers to block TESS shaders
> on one unit. These fixed most of the hangs we saw during development.
>
> This doesn't contain SB support yet, Glenn has started working on it.
>
> Currently tested hw:
> working: CAYMAN, REDWOOD, BARTS, TURKS
> hangs on any tessellation: CAYMAN
> hangs differently at least with heaven: SUMO
>
> This patchset doesn't block it on any GPUs, but when merged it
> probably should.
>
> Also available at:
> http://cgit.freedesktop.org/~airlied/mesa/log/?h=r600g-tess-submit
>
> Thanks to Glenn Kennard for lots of discussion and testing.
>
> Dave.
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20151203/8fe7645c/attachment.html>


More information about the mesa-dev mailing list