Bug 89372 - [softpipe] piglit glsl-1.50 generate-zero-primitives regression
Summary: [softpipe] piglit glsl-1.50 generate-zero-primitives regression
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: mesa-dev
QA Contact: mesa-dev
URL:
Whiteboard:
Keywords: bisected, regression
Depends on:
Blocks:
 
Reported: 2015-02-28 22:05 UTC by Vinson Lee
Modified: 2015-03-02 11:49 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vinson Lee 2015-02-28 22:05:28 UTC
mesa: d528907fd2950c7bb968fff66dd79863cd128890 (master 10.6.0-devel)

$ ./bin/shader_runner tests/spec/glsl-1.50/execution/geometry/generate-zero-primitives.shader_test -auto 
Floating point exception (core dumped)

Core was generated by `./bin/shader_runner tests/spec/glsl-1.50/execution/geometry/generate-zero-primi'.
Program terminated with signal SIGFPE, Arithmetic exception.
#0  0x00007fe007e6b16f in draw_pt_emit_prepare (emit=0x1d48600, 
    prim=prim@entry=0, max_vertices=max_vertices@entry=0x1dfdf88)
    at draw/draw_pt_emit.c:116
116	   *max_vertices = (draw->render->max_vertex_buffer_bytes /
(gdb) l
111	       translate_key_compare(&emit->translate->key, &hw_key) != 0) {
112	      translate_key_sanitize(&hw_key);
113	      emit->translate = translate_cache_find(emit->cache, &hw_key);
114	   }
115	
116	   *max_vertices = (draw->render->max_vertex_buffer_bytes /
117	                    (vinfo->size * 4));
118	}
119	
120	
(gdb) print emit->translate->key
$1 = {output_stride = 0, nr_elements = 0, element = {{
      type = TRANSLATE_ELEMENT_NORMAL, input_format = PIPE_FORMAT_NONE, 
      output_format = PIPE_FORMAT_NONE, input_buffer = 0, input_offset = 0, 
      instance_divisor = 0, output_offset = 0} <repeats 33 times>}}
(gdb) print hw_key
$2 = {output_stride = 0, nr_elements = 0, element = {{
      type = TRANSLATE_ELEMENT_NORMAL, input_format = PIPE_FORMAT_NONE, 
      output_format = PIPE_FORMAT_NONE, input_buffer = 0, input_offset = 0, 
      instance_divisor = 0, output_offset = 0} <repeats 33 times>}}
Comment 1 Vinson Lee 2015-02-28 23:23:03 UTC
558f51f1c5491d86c73769065c6df12a2b73dc4d is the first bad commit
commit 558f51f1c5491d86c73769065c6df12a2b73dc4d
Author: Marek Olšák <marek.olsak@amd.com>
Date:   Sun Feb 22 13:22:07 2015 +0100

    st/mesa: cleanup st_translate_geometry_program
    
    Mostly dead code or code that didn't do anything.
    
    Computing gs_num_outputs at the end was also useless. It's already set
    correctly.
    
    Reviewed-by: Dave Airlie <airlied@redhat.com>

:040000 040000 57740001094746c91e2668d8bdfdcb09dc75e7bf ccfee80ddbd7544582285d89c8b21fbfa8bead74 M	src
bisect run success
Comment 2 Marek Olšák 2015-02-28 23:31:55 UTC
The GS before:

GEOM
PROPERTY GS_INPUT_PRIMITIVE TRIANGLES
PROPERTY GS_OUTPUT_PRIMITIVE TRIANGLE_STRIP
PROPERTY GS_MAX_OUTPUT_VERTICES 3
PROPERTY GS_INVOCATIONS 1
DCL OUT[0], GENERIC[0]
  0: END

After:

GEOM
PROPERTY GS_INPUT_PRIMITIVE TRIANGLES
PROPERTY GS_OUTPUT_PRIMITIVE TRIANGLE_STRIP
PROPERTY GS_MAX_OUTPUT_VERTICES 3
PROPERTY GS_INVOCATIONS 1
  0: END

Draw apparently doesn't like geometry shaders without declarations.
Comment 3 Marek Olšák 2015-03-02 11:49:51 UTC
Fixed by 27a34f62baa991eadd040302748c48b31ec21a0c. Closing.


bug/show.html.tmpl processed on Mar 27, 2017 at 02:50:05.
(provided by the Example extension).