|Summary:||VkRunner tests assert when run with nir test environment variables|
|Product:||Mesa||Reporter:||Mark Janes <mark.a.janes>|
|Component:||Drivers/DRI/i965||Assignee:||Intel 3D Bugs Mailing List <intel-3d-bugs>|
|Status:||NEW ---||QA Contact:||Intel 3D Bugs Mailing List <intel-3d-bugs>|
|i915 platform:||i915 features:|
Description Mark Janes 2018-12-05 20:49:12 UTC
Mesa i965 CI runs tests in a mode designed to detect problems with our use of NIR. The following environment variables are set: NIR_TEST_CLONE=true NIR_TEST_SERIALIZE=true With the addition of VkRunner tests to piglit, the following tests began to fail in this mode: piglit.vulkan.glsl450.face-forward-double piglit.vulkan.glsl450.frexp-double piglit.vulkan.glsl450.isinf-double piglit.vulkan.glsl450.reflect-double piglit.vulkan.glsl450.refract-double piglit.vulkan.shaders.fs-large-local-array piglit.vulkan.shaders.fs-large-local-array-vec2 piglit.vulkan.shaders.fs-large-local-array-vec3 piglit.vulkan.shaders.fs-large-local-array-vec4 piglit.vulkan.shaders.fs-multiple-large-local-array stderr: /tmp/vkrunner-1E4K6k vkrunner: ../src/intel/vulkan/anv_pipeline.c:193: anv_shader_compile_to_nir: Assertion `exec_list_length(&nir->functions) == 1' failed.
Comment 1 Jason Ekstrand 2018-12-05 20:59:54 UTC
This is entirely due to the way we handle hanging onto the entrypoint we get out of SPIR-V. The spirv_to_nir pass returns a nir_function_impl instead of a nir_shader and we hang on to it while we do a couple of passes such as function inlining. We then go to delete all but the main entrypoint assuming that the nir_function_impl pointer we're hanging on to is still valid. If NIR_TEST_CLONE is set, it won't be valid because it will have been cloned out from under us. This isn't an actual issue in production, but we should probably sort out what to do about it one of these days.
Comment 2 Caio Marcelo de Oliveira Filho 2019-05-19 07:44:54 UTC
There's a MR to attempt to fix this one https://gitlab.freedesktop.org/mesa/mesa/merge_requests/912