From ffcdd49c69811b9f768c0b32acef6527d5626a6e Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Sun, 23 Jan 2011 12:03:59 +0100 Subject: r300/compiler: remove any code related to relative addressing of temporaries The hw can't do it and the code was useless anyway (it's lowered in the GLSL compiler). --- src/gallium/drivers/r300/r300_fs.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/gallium/drivers/r300/r300_fs.c') diff --git a/src/gallium/drivers/r300/r300_fs.c b/src/gallium/drivers/r300/r300_fs.c index 6d4091dc87d..84773ab386c 100644 --- a/src/gallium/drivers/r300/r300_fs.c +++ b/src/gallium/drivers/r300/r300_fs.c @@ -414,6 +414,13 @@ static void r300_translate_fragment_shader( r300_tgsi_to_rc(&ttr, tokens); + if (ttr.error) { + fprintf(stderr, "r300 FP: Cannot translate a shader. " + "Using a dummy shader instead.\n"); + r300_dummy_fragment_shader(r300, shader); + return; + } + if (!r300->screen->caps.is_r500 || compiler.Base.Program.Constants.Count > 200) { compiler.Base.remove_unused_constants = TRUE; -- cgit v1.2.3