radeonsi: Fall back to dummy pixel shader instead of trying indirect addressing.
authorMichel Dänzer <michel.daenzer@amd.com>
Tue, 22 Jan 2013 16:08:24 +0000 (17:08 +0100)
committerMichel Dänzer <michel@daenzer.net>
Thu, 24 Jan 2013 07:46:48 +0000 (08:46 +0100)
Indirect addressing isn't fully handled yet.

Fixes crashes with piglit tests using indirect addressing.

Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
src/gallium/drivers/radeonsi/radeonsi_shader.c

index 52ecef9b54770caf212824d0ac19ebb28bdacaab..f398e6ca066163d9e40a8ff6b340478108e1e5e4 100644 (file)
@@ -913,6 +913,11 @@ int si_pipe_shader_create(
        bld_base = &si_shader_ctx.radeon_bld.soa.bld_base;
 
        tgsi_scan_shader(sel->tokens, &shader_info);
+       if (shader_info.indirect_files != 0) {
+               fprintf(stderr, "Indirect addressing not fully handled yet\n");
+               return -ENOSYS;
+       }
+
        shader->shader.uses_kill = shader_info.uses_kill;
        bld_base->info = &shader_info;
        bld_base->emit_fetch_funcs[TGSI_FILE_CONSTANT] = fetch_constant;