OSDN Git Service

radeonsi: don't fail in si_shader_io_get_unique_index
authorMarek Olšák <marek.olsak@amd.com>
Thu, 25 Jun 2015 12:58:37 +0000 (14:58 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Thu, 25 Jun 2015 13:05:56 +0000 (15:05 +0200)
Trivial. Picked from my tessellation branch.

src/gallium/drivers/radeonsi/si_shader.c

index 47e5f96..a293ef3 100644 (file)
@@ -133,8 +133,12 @@ unsigned si_shader_io_get_unique_index(unsigned semantic_name, unsigned index)
                return 4 + index;
 
        default:
-               assert(0);
-               return 63;
+               /* Don't fail here. The result of this function is only used
+                * for LS, TCS, TES, and GS, where legacy GL semantics can't
+                * occur, but this function is called for all vertex shaders
+                * before it's known whether LS will be compiled or not.
+                */
+               return 0;
        }
 }