All of lore.kernel.org
 help / color / mirror / Atom feed
* [Bug 99532] New: Compute shader doesn't give right result under some circumstances
@ 2017-01-25 11:35 bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
  0 siblings, 1 reply; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 11:35 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 2132 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

            Bug ID: 99532
           Summary: Compute shader doesn't give right result under some
                    circumstances
           Product: Mesa
           Version: unspecified
          Hardware: Other
                OS: All
            Status: NEW
          Severity: normal
          Priority: medium
         Component: Drivers/DRI/nouveau
          Assignee: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
          Reporter: stu_dby-KN7UnAbNpbg@public.gmane.org
        QA Contact: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org

Created attachment 129135
  --> https://bugs.freedesktop.org/attachment.cgi?id=129135&action=edit
apitrace of my program

When I'm doing a course project in my compute graphics class, I found my
program didn't fully work on nouveau while it was working fine on intel and
nvidia proprietary drivers. It is a program using deferred shading with some
shadow map techniques, and it has an option to draw a "histogram" of depth
distribution sampled by a compute shader. I found histogram was showing wrong
results (totally blank) on nouveau.

After looking into the problem for a while, I happened to find that if I didn't
render the histogram (i.e. didn't use compute shader to sample) on the first
frame, the histogram would go wrong, otherwise, it would be okay.

This problem can be reproduced with the attached apitrace file, recorded with
simplified program and trimmed to contain only 4 frames. The first 2 frames are
mainly initialization and the third frame renders the scene from one angle
without generating histogram. The last frame renders the scene from another
angle and generates a histogram at bottom-right edge, which is completely blank
on nouveau. However, if the trace is further trimmed to contain frame 0,1,3,
the histogram will render correctly. (Results of the two will be attached
below)

I'm willing provide assistance if needed.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 3589 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
@ 2017-01-25 11:36   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 11:36   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (17 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 11:36 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 379 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #1 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129136
  --> https://bugs.freedesktop.org/attachment.cgi?id=129136&action=edit
Wrong rendering (histogram blank)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1342 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
  2017-01-25 11:36   ` [Bug 99532] " bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 11:36   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:18   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (16 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 11:36 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 381 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #2 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129137
  --> https://bugs.freedesktop.org/attachment.cgi?id=129137&action=edit
Correct rendering of the last frame

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1348 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
  2017-01-25 11:36   ` [Bug 99532] " bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 11:36   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:18   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (15 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:18 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 468 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #3 from Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org> ---
On GM107 it actually appears to work correctly. However on GK208 I got a blank
histogram on the first run, and then a semi-random one on subsequent runs. (And
now it's blank again.)

What GPU are you using?

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1273 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (2 preceding siblings ...)
  2017-01-25 13:18   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:38   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (14 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:24 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 538 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #4 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
(In reply to Ilia Mirkin from comment #3)
> On GM107 it actually appears to work correctly. However on GK208 I got a
> blank histogram on the first run, and then a semi-random one on subsequent
> runs. (And now it's blank again.)
> 
> What GPU are you using?

Mine is a GT740M (GK208).

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1425 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (3 preceding siblings ...)
  2017-01-25 13:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:38   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:41   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (13 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:38 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 531 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #5 from Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org> ---
Can you figure out which compute invocation messes up? Looks like you have 2
compute shaders in there, although my bet is on the one that does all the
atomic ops on shared memory - that stuff changed between Kepler and Maxwell,
which could explain why it works on GM107.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1336 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (4 preceding siblings ...)
  2017-01-25 13:38   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:41   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:44   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (12 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:41 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 553 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #6 from Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org> ---
Oh wait - while there are 2 compute shaders, you only use one of them (the one
with all the shared atomics). Also need to double-check that it's not an
earlier draw messing things up (e.g. that the compute shader is getting the
proper inputs). But my bet is on an issue in the compute shader.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1358 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (5 preceding siblings ...)
  2017-01-25 13:41   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:44   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:47   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (11 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:44 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 756 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #7 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
(In reply to Ilia Mirkin from comment #6)
> Oh wait - while there are 2 compute shaders, you only use one of them (the
> one with all the shared atomics). Also need to double-check that it's not an
> earlier draw messing things up (e.g. that the compute shader is getting the
> proper inputs). But my bet is on an issue in the compute shader.

I agree with you, since the same compute shader input was also used in
subsequent rendering. If that were wrong, the following render would also be
incorrect.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1640 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (6 preceding siblings ...)
  2017-01-25 13:44   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:47   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 13:51   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (10 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:47 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 518 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #8 from Samuel Pitoiset <samuel.pitoiset-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> ---
A missing OP_CCTL maybe? I have something which could help (but it's definitely
not the right thing to do).

The possible fix is here:
https://cgit.freedesktop.org/~hakzsam/mesa/commit/?h=atomic_fixes&id=d3a1158acde83d9d7a2a58e431623dd89e59ca65

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1461 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (7 preceding siblings ...)
  2017-01-25 13:47   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 13:51   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-25 14:07   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (9 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 13:51 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 369 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #9 from Samuel Pitoiset <samuel.pitoiset-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> ---
That might explain the failure on kepler (and presumably fermi) because maxwell
doesn't need that.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1180 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (8 preceding siblings ...)
  2017-01-25 13:51   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-25 14:07   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-26  6:09   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (8 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-25 14:07 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 692 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #10 from Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org> ---
(In reply to Samuel Pitoiset from comment #8)
> A missing OP_CCTL maybe? I have something which could help (but it's
> definitely not the right thing to do).
> 
> The possible fix is here:
> https://cgit.freedesktop.org/~hakzsam/mesa/commit/
> ?h=atomic_fixes&id=d3a1158acde83d9d7a2a58e431623dd89e59ca65

Nope. It does change the rendering very slightly - there's now one bar
consistently in the histogram - still incorrect.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1652 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (9 preceding siblings ...)
  2017-01-25 14:07   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-26  6:09   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-01-26  6:10   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (7 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-26  6:09 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 772 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #11 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129157
  --> https://bugs.freedesktop.org/attachment.cgi?id=129157&action=edit
The compute shader binary and assembly compiled with nouveau

I took some time today to capture the compiled shader binaries under nouveau
and proprietary driver. It seems there are differences when handling atomic
operations. The code generated by nvidia driver (will be attached below) is
rather huge, but seems mostly repetitions of several small sections of code.

I don't know about nvidia isa, but hope it helps.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1790 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (10 preceding siblings ...)
  2017-01-26  6:09   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-01-26  6:10   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-06 12:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (6 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-01-26  6:10 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 418 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #12 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129158
  --> https://bugs.freedesktop.org/attachment.cgi?id=129158&action=edit
The compute shader binary and assembly compiled with proprietary driver

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1458 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (11 preceding siblings ...)
  2017-01-26  6:10   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-06 12:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-07 12:01   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (5 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-06 12:24 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 771 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #13 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Now I doubt if the problem really lies in the atomic operations, even in
compiler at all. I changed the compute shader a little bit, only letting thread
(0, 0) to accumulate its result to the ssbo (the dividing factor in histogram
fragment shader changed from 20000 to 20). This bypasses atomic operation and
shared memory, but the same problem persists.

I suspect that the input state of compute shader is somehow invalid, and that
explains why removing one frame of the trace will magically eliminate the
problem.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1577 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (12 preceding siblings ...)
  2017-02-06 12:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-07 12:01   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-07 12:02   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (4 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-07 12:01 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 843 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #14 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129380
  --> https://bugs.freedesktop.org/attachment.cgi?id=129380&action=edit
A minimal reproducer

I wrote another much simpler program today to find the real cause of this bug.
Turns out that compute shader is unable to sample from depth texture.

The attached program first renders a shape to a FBO. Then a compute shader is
used to copy the color and depth textures attached to the former FBO to a
shader image, which is drawn to the screen. The depth part is different between
nouveau and other drivers.

Compile the program with gcc test.c -lglfw -lGLEW -lGL

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1781 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (13 preceding siblings ...)
  2017-02-07 12:01   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-07 12:02   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-07 12:03   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (3 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-07 12:02 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 374 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #15 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129381
  --> https://bugs.freedesktop.org/attachment.cgi?id=129381&action=edit
Correct shader image (i965)

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1326 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (14 preceding siblings ...)
  2017-02-07 12:02   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-07 12:03   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-12 18:35   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
                     ` (2 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-07 12:03 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 379 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #16 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
Created attachment 129382
  --> https://bugs.freedesktop.org/attachment.cgi?id=129382&action=edit
Incorrect shader image (nouveau)

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1341 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (15 preceding siblings ...)
  2017-02-07 12:03   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-12 18:35   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-13  1:31   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-14  2:14   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-12 18:35 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 838 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #17 from Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org> ---
A few observations:

- Pretty sure you want GL_TEXTURE_FETCH_BARRIER_BIT. Not that this matters for
nvc0.
- In addition to this always working on GM107, it *sometimes* works on my
GK208. Something about card state? Or something in compute insufficiently
initialized?
- I tried setting the DEPTH_TEXTURE bit in the TIC with no effect.
- The GM107 works just as effectively with both old- and new-style TIC formats.
- Throwing glFlush or glTextureBarrier into the mix made no difference, so it's
not a cache issue.
- Switching to DEPTH24 and DEPTH32F made no difference.

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 1644 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (16 preceding siblings ...)
  2017-02-12 18:35   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-13  1:31   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  2017-02-14  2:14   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-13  1:31 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 1810 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

--- Comment #18 from Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org> ---
Also likely relevant is the fact that all these fail, even on GM107. But the
ones for other shader stages do pass. We're clearly missing some setting of
some kind.

dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_literal.compute.sampler2dshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_literal.compute.samplercubeshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_literal.compute.sampler2darrayshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_literal.compute.isampler2d,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_expression.compute.sampler2dshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_expression.compute.samplercubeshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.const_expression.compute.sampler2darrayshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.uniform.compute.sampler2dshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.uniform.compute.samplercubeshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.uniform.compute.sampler2darrayshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.dynamically_uniform.compute.sampler2dshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.dynamically_uniform.compute.samplercubeshadow,Fail
dEQP-GLES31.functional.shaders.opaque_type_indexing.sampler.dynamically_uniform.compute.sampler2darrayshadow,Fail

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 2616 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

* [Bug 99532] Compute shader doesn't give right result under some circumstances
       [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
                     ` (17 preceding siblings ...)
  2017-02-13  1:31   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
@ 2017-02-14  2:14   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
  18 siblings, 0 replies; 20+ messages in thread
From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ @ 2017-02-14  2:14 UTC (permalink / raw)
  To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 1239 bytes --]

https://bugs.freedesktop.org/show_bug.cgi?id=99532

Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #19 from Boyan Ding <stu_dby-KN7UnAbNpbg@public.gmane.org> ---
commit 956556b3c30ce3d38d0af795f9383df3bc2cf8a2
Author: Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org>
Date:   Mon Feb 13 11:14:51 2017 -0500

    nvc0: disable linked tsc mode in compute launch descriptor

    Empirically, this makes things work. Presumably this was originally
    copied from the blob, which does make use of linked tsc mode.

    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=99532
    Signed-off-by: Ilia Mirkin <imirkin-FrUbXkNCsVf2fBVCVOL8/A@public.gmane.org>
    Reviewed-by: Samuel Pitoiset <samuel.pitoiset-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
    Cc: mesa-stable-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.

[-- Attachment #1.2: Type: text/html, Size: 3070 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2017-02-14  2:14 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-25 11:35 [Bug 99532] New: Compute shader doesn't give right result under some circumstances bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
     [not found] ` <bug-99532-8800-V0hAGp6uBxMKqLRl/0Ahz6D7qz1kEfGD2LY78lusg7I@public.gmane.org/>
2017-01-25 11:36   ` [Bug 99532] " bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 11:36   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:18   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:38   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:41   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:44   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:47   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 13:51   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-25 14:07   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-26  6:09   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-01-26  6:10   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-06 12:24   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-07 12:01   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-07 12:02   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-07 12:03   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-12 18:35   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-13  1:31   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ
2017-02-14  2:14   ` bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.