Closed Bug 1406015 Opened 8 years ago Closed 8 years ago

Shader local variables aren't zeroed

Categories

(Core :: Graphics: CanvasWebGL, defect, P1)

57 Branch
defect

Tracking

()

RESOLVED FIXED
mozilla58
Tracking Status
firefox-esr52 --- wontfix
firefox56 --- wontfix
firefox57 --- wontfix
firefox58 --- fixed

People

(Reporter: kdmitrenko, Assigned: jgilbert)

References

Details

(Whiteboard: [gfx-noted])

Attachments

(4 files)

Attached file Repro case
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Safari/604.1.38 Steps to reproduce: 1. Open http://output.jsbin.com/gahorow (or attached repro). Actual results: Junky rendered image. Expected results: Image with 3 transparent quarters and one black.
Attached image Screen Shot
OS: Unspecified → Mac OS X
Hardware: Unspecified → x86_64
Attached image Screen shot from linux
Also reproduces on a linux machine.
This can be done by enabling the new flag SH_INITIALIZE_UNINITIALIZED_LOCALS in the ANGLE shader translator. However be aware of some bugs that may creep up (we see them specifically in Nexus 5X and Mac/NVIDIA): https://crbug.com/728271
Component: Untriaged → Canvas: WebGL
Product: Firefox → Core
Jeff, what's the standard say in this case?
Flags: needinfo?(jgilbert)
Priority: -- → P3
Whiteboard: [gfx-noted]
I wish we could just reject shaders that do this. We need to initialize the variables.
Flags: needinfo?(jgilbert)
Assignee: nobody → jgilbert
Status: UNCONFIRMED → ASSIGNED
Depends on: 1371190
Ever confirmed: true
Priority: P3 → P1
OS: Mac OS X → Unspecified
Hardware: x86_64 → Unspecified
Comment on attachment 8918019 [details] Bug 1406015 - Enable SH_INITIALIZE_UNINITIALIZED_LOCALS. - https://reviewboard.mozilla.org/r/188900/#review194274 LGTM
Attachment #8918019 - Flags: review?(cleu) → review+
Pushed by ryanvm@gmail.com: https://hg.mozilla.org/integration/autoland/rev/f5fa4359525c Enable SH_INITIALIZE_UNINITIALIZED_LOCALS. - r=Lenzak
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: