aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2009-11-15 12:14:03 -0800
committerJosé Fonseca <[email protected]>2009-11-24 14:49:21 +0000
commitf3a0615fb0452f11f4db88861b30b2177bdd948a (patch)
tree29154a710ac9950b803421878f296cb1e58c05ae /src
parentd185c2fd1318bd41f303ab4a5f6e0a048b76c11c (diff)
svga: Handle comment tokens when dumping.
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/svga/svgadump/svga_shader.h6
-rw-r--r--src/gallium/drivers/svga/svgadump/svga_shader_dump.c7
2 files changed, 12 insertions, 1 deletions
diff --git a/src/gallium/drivers/svga/svgadump/svga_shader.h b/src/gallium/drivers/svga/svgadump/svga_shader.h
index 2fc1796a904..9217af2dd99 100644
--- a/src/gallium/drivers/svga/svgadump/svga_shader.h
+++ b/src/gallium/drivers/svga/svgadump/svga_shader.h
@@ -211,4 +211,10 @@ struct sh_trinaryop
struct sh_srcreg src2;
};
+struct sh_comment
+{
+ unsigned opcode:16;
+ unsigned size:16;
+};
+
#endif /* ST_SHADER_SVGA_H */
diff --git a/src/gallium/drivers/svga/svgadump/svga_shader_dump.c b/src/gallium/drivers/svga/svgadump/svga_shader_dump.c
index 7718bdf757b..b0e7fdf378a 100644
--- a/src/gallium/drivers/svga/svgadump/svga_shader_dump.c
+++ b/src/gallium/drivers/svga/svgadump/svga_shader_dump.c
@@ -587,7 +587,12 @@ svga_shader_dump(
break;
case SVGA3DOP_COMMENT:
- assert( 0 );
+ {
+ struct sh_comment comment = *(struct sh_comment *)assem;
+
+ /* Ignore comment contents. */
+ assem += sizeof(struct sh_comment) / sizeof(unsigned) + comment.size;
+ }
break;
case SVGA3DOP_RET: