Bug 68348

Summary: [piglit] shaders/glsl-array-bounds-02 (+even nrs) produces TRAP , TRAP_MP - TP0: Unhandled ustatus 0x00000001
Product: xorg Reporter: dirkneukirchen
Component: Driver/nouveauAssignee: Nouveau Project <nouveau>
Status: RESOLVED NOTABUG QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: git   
Hardware: x86 (IA32)   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
dmesg with many instances of problem occuring (while isolating the piglit testcase) none

Description dirkneukirchen 2013-08-20 17:55:23 UTC
Created attachment 84353 [details]
dmesg with many instances of problem occuring (while isolating the piglit testcase)

./piglit-run.py --no-concurrency -t  '^shaders/glsl-array-bounds-02' tests/quick.tests results/quick-shaders-array.tests

and all other even numbered cases 
glsl-array-bounds-04
glsl-array-bounds-06
glsl-array-bounds-08

print out success but get a kernel log entry like 

[ 4653.971680] nouveau E[  PGRAPH][0000:02:00.0] TRAP_MP - TP0: Unhandled ustatus 0x00000001
[ 4653.971688] nouveau E[  PGRAPH][0000:02:00.0]  TRAP
[ 4653.971695] nouveau E[  PGRAPH][0000:02:00.0] ch 5 [0x0007814000 shader_runner[8809]] subc 3 class 0x8397 mthd 0x15e0 data 0x00000000

found with heavy use of exclude -x feature :)


Hardware:
Nvidia 8200 Onboard NVAA/NV50
nouveau  [  DEVICE][0000:02:00.0] Chipset: MCP77/MCP78 (NVAA)
nouveau  [  DEVICE][0000:02:00.0] Family : NV50

Software:
Linux Mint 15 + xorg-edgers + 3.11-rc5
Kernel: 3.11.0-rc5-vanillaice (compiled)
libdrm-nouveau: 2.4.46+git20130702.c6d73cfe-0ubuntu0sarvatt~raring
xserver-xorg-video-nouveau :
1:1.0.9+git20130730.300c5a32-0ubuntu0sarvatt~raring
mesa: 9.2.0~git20130729+9.2.9b8ad643-0ubuntu0sarvatt~raring
Comment 1 Ilia Mirkin 2013-08-20 20:41:19 UTC
The big difference between the even and odd numbered shaders/glsl-array-bounds-* seems to be how the invalid index comes about.

In the odd-numbered ones, it comes directly from shader code, e.g.:

void main() {
  int idx = 20;
  array[idx]
}

In the even-numbered ones, it comes from a uniform that I guess is passed in:

uniform int idx;

void main() {
  array[idx]
}

(And the various tests check fragment/vertex shaders, positive/negative offsets, and the place where the idx comes from, so 8 tests total.)

Although I'm not sure there's actually a problem here... the program is doing something illegal. You get segfault notifications in dmesg too...
Comment 2 Tobias Klausmann 2015-01-17 00:23:31 UTC
Is this still a bug with recent kernels and other software? Please retest with 3.19-rc4 as there were some fixes for these chips in particular.
Comment 3 Tobias Klausmann 2015-01-17 00:54:45 UTC
Noted on IRC by pmoureau:

Tests {2-8} are working fine while {10, 12} are still failing with a similar error on MCP79/7A (the closest we got)
Comment 4 Ilia Mirkin 2015-01-17 01:03:41 UTC
The piglit test got changed in the meanwhile. It's an out-of-bounds access, I think the error in dmesg is legit...ish. Not sure. We could turn off error reporting, which afaik is what the blob does.
Comment 5 Ilia Mirkin 2015-10-22 04:16:18 UTC
We don't disable error reporting, so you'll see stuff like that in dmesg. Expected.

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.