Summary: | [GM965 GLSL] noise*() cause GPU lockup | ||
---|---|---|---|
Product: | DRI | Reporter: | David L. <equinox-freedesktopbugs> |
Component: | DRM/Intel | Assignee: | Ian Romanick <idr> |
Status: | CLOSED FIXED | QA Contact: | |
Severity: | critical | ||
Priority: | medium | CC: | brian.paul, jiewen.lin, xunx.fang |
Version: | XOrg git | Keywords: | patch |
Hardware: | x86-64 (AMD64) | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Bug Depends on: | |||
Bug Blocks: | 29044 | ||
Attachments: |
Created attachment 27392 [details]
intel_gpu_dump (bz2) after progs/glsl/noise lockup
Created attachment 27393 [details]
intel_gpu_dump (bz2) after progs/glsl/noise2 lockup
Created attachment 27394 [details]
intel_gpu_dump (bz2) after progs/glsl/multinoise lockup
*** Bug 19546 has been marked as a duplicate of this bug. *** when i change the shader in noise.c like this: @@ -27,17 +27,17 @@ "uniform float Slice;\n" "void main()\n" "{\n" " vec4 scale = vec4(5.0);\n" " vec4 p;\n" " p.xy = gl_TexCoord[0].xy;\n" " p.z = Slice;\n" " p.w = 0;\n" - " vec4 n = noise4(p * scale);\n" + " vec4 n = p * scale;\n" " gl_FragColor = n * Scale + Bias;\n" "}\n"; the hang goes away, so it definitively is an issue with the noise4 function. noise1 trips the lockup as well. can't test noise2/noise3 since i have no clue about writing glsl code... adjusting summary and bumping priority for hang. Created attachment 27485 [details] [review] Replacse noise opcodes with GLSL implementation confirmed the patch fixes the hangs with the noise samples, thank you very much! EVE still freezes, removing bug #22613 from blocks :( (In reply to comment #7) > Created an attachment (id=27485) [details] > Replacse noise opcodes with GLSL implementation > Ian, is this patch committed? (In reply to comment #9) > Ian, is this patch committed? It is not. When this code is used, the GLSL compiler inlines *everything*, and programs quickly become too large (or use too many registers) to run in hardware. We're going to have to do some work on the GLSL compiler before we can properly implement this. I don't have a good solution for right now. (In reply to comment #10) > We're going to have to do some work on the GLSL compiler before we > can properly implement this. Ian, can you tell me what are the bugs filed against GLSL that are linked to this issue? Are you still experiencing this problem? I just ran noise and noise2 on my GM45 successfully. Eric Anholt: yes, it seems to persist: # ./checkinst drm.32/c1c8bbf80b1f734e23996bf805dc78f32ebaf56f drm.64/c1c8bbf80b1f734e23996bf805dc78f32ebaf56f mesa.32/05c03c6a1bcfb8ad77d3025f166f02ddaa741aa2 mesa.64/05c03c6a1bcfb8ad77d3025f166f02ddaa741aa2 xf86-video-intel/3d4b3f257fbbb69c6f236d9803abe54a90d7d434 # mesa/progs/glsl/noise Uniforms: 0: Scale size=1 type=0x8b52 loc=0 value=0.5, 0.4, 0, 0 1: Bias size=1 type=0x8b52 loc=1 value=0.5, 0.3, 0, 0 2: Slice size=1 type=0x1406 loc=2 value=0.5, 0, 0, 0 GL_RENDERER = Mesa DRI Intel(R) 965GM GEM 20091221 DEVELOPMENT intel_bufmgr_gem.c:1234: Error setting memory domains 1 (00000040 00000000): Input/output error . ^C # dmesg | tail -n 3 [30715.868133] [drm:i915_hangcheck_elapsed] *ERROR* Hangcheck timer elapsed... GPU hung [30715.868148] render error detected, EIR: 0x00000000 [30715.868190] [drm:i915_do_wait_request] *ERROR* i915_do_wait_request returns -5 (awaiting 2664539 at 2664538) ... but at least it doesn't hard-lockup my box anymore. Though I'm not sure the noise stuff is causing the GPU hangs, I'm experiencing these quite frequently with wine. With Ian's patch, noise works. btw, bug #19546 comment 2 says "Q965 and g45 is fine, this bug may be gm965 one only." right, this only happens on GM965 in our test machines. But in our case, X can be killed and returns to working console. [root@x-gm965 glsl]#./noise libGL: OpenDriver: trying /opt/X11R7/lib/dri/i965_dri.so Uniforms: 0: Scale size=1 type=0x8b52 loc=0 value=0.5, 0.4, 0, 0 1: Bias size=1 type=0x8b52 loc=1 value=0.5, 0.3, 0, 0 2: Slice size=1 type=0x1406 loc=2 value=0.5, 0, 0, 0 GL_RENDERER = Mesa DRI Intel(R) 965GM GEM 20091221 DEVELOPMENT intel_bufmgr_gem.c:1247: Error setting memory domains 1 (00000040 00000000): Inp [root@x-gm965 glsl]# dmesg | tail -n 3 [drm:i915_hangcheck_elapsed] *ERROR* Hangcheck timer elapsed... GPU hung render error detected, EIR: 0x00000000 [drm:i915_do_wait_request] *ERROR* i915_do_wait_request returns -5 (awaiting 1601 at 1600) The following patches effectively disable noise in i965 GLSL. Once real function calls are implemented in i965 drivers a variation of the GLSL code (attachment #27485 [details] [review]) will be used. commit 1f3c7d968c4313dbb71bc93306556cc9292d06ef Author: Ian Romanick <ian.d.romanick@intel.com> Date: Wed Sep 1 21:23:52 2010 -0700 glsl2: Implement noise[1234] built-in functions using ir_unop_noise commit 2b70dbfe091af5ae7c788e16275e1af2cb1c284c Author: Ian Romanick <ian.d.romanick@intel.com> Date: Thu Sep 9 15:25:32 2010 -0700 glsl2: Add EmitNoNoise flag, use it to remove noise opcodes commit 547131ac8750acabd030972fc768705c13d19ef7 Author: Ian Romanick <ian.d.romanick@intel.com> Date: Thu Sep 9 15:20:09 2010 -0700 glsl2: Add lowering pass to remove noise opcodes commit 3a5ce85cfa4914711e56c8cf831699242618928e Author: Ian Romanick <ian.d.romanick@intel.com> Date: Wed Sep 1 21:12:10 2010 -0700 glsl2: Add ir_unop_noise |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.
Created attachment 27391 [details] Xorg.log all "noise" samples from Mesa progs/glsl cause immediate GPU lockup on start. installed versions: kernel b44866e34ce96cdec2e848ab57808381df871ac8 (== 2.6.30.1) libdrm 72a29340ea3225550db6b009f4e50c77c7b1f394 (2009-07-03 15:03:03+0200) mesa 862488075c5537b0613753b0d14c267527fc6199 (2009-07-03 18:53:58+0200) xf86-video-intel 74227141923a2f5049592219ab80e8733062a5d9 (2009-06-23 14:14:50+0100) xorg-server d6b8205e699c0c62af76c4a9cbff1402337927b3 (2009-07-03 19:25:33-0700) hardware: 00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller [8086:2a02] (rev 03) 00:02.1 Display controller [0380]: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller [8086:2a03] (rev 03) MSI disabled. killing the program or X does not return me to a working console, only way out is reboot. no other sample from progs/glsl causes a lockup.