[HN Gopher] Help the Graphics team track down an interesting Web...
       ___________________________________________________________________
        
       Help the Graphics team track down an interesting WebRender bug
        
       Author : Santosh83
       Score  : 187 points
       Date   : 2020-02-18 19:42 UTC (3 hours ago)
        
 (HTM) web link (mozillagfx.wordpress.com)
 (TXT) w3m dump (mozillagfx.wordpress.com)
        
       | godelski wrote:
       | I used to have this problem __ALL__ the time. So I can give some
       | specs to help anyone, because another comment suggests old
       | hardware.
       | 
       | I __only__ experienced the text tearing. It would basically be a
       | slash through the screen, usually two or three where text would
       | just be displaced. A small scroll would fix it.
       | 
       | This has happened to me in both Manjaro and Ubuntu and on two
       | different computers. The Manjaro is a Inspiron with a 1060Qmax.
       | The Ubuntu has a GTK Titan Black (so old).
       | 
       | I have not experienced these glitches in fairly recent memory. So
       | probably last two versions of FF. These computers are my daily
       | drivers and I keep them fairly up to date.
       | 
       | Usually where these glitches would happen is in long form text
       | articles. I don't recall seeing them on Reddit, but more like
       | NYT. Hope this helps.
        
         | rahuldottech wrote:
         | I've been experiencing this too! On only one of my machines. I
         | did a complete Windows reinstall but the problem persisted.
         | 
         | It doesn't happen too often, but iirc I saw a text glitch
         | sometime in the past few days. Moving my mouse over the
         | glitched area or a small scroll solves it for me too.
        
           | godelski wrote:
           | Yeah I could get rid of it by scrolling or highlighting the
           | text. I remember looking it up and only find like one small
           | bug report a year ago. But I don't see it anymore. Are you on
           | the newest FF? I don't use nightly and I haven't seen this
           | problem in awhile.
        
             | rahuldottech wrote:
             | Just checked, I'm on latest regular FF, non-nightly. I
             | don't recall seeing it in the past couple days so maaaaybe
             | it's resolved now? I'll keep an eye out for it in case I
             | see it again.
        
       | miohtama wrote:
       | But hunting is one of the easy to apply kinds of crowd wisdom.
       | Let's hope Mozilla gets enough data to nail down the root cause.
        
       | dx87 wrote:
       | I was having a weird WebRender issue last year, except it was
       | causing sudden reboots until the computer stayed powered off long
       | enough for the GPU memory to be cleared. I had enabled WebRender
       | in Linux (it's experimental, I know), and the computer would run
       | fine for weeks at a time, then reboot out of nowhere. It would
       | continue to reboot any time I opened firefox, sometimes a few
       | minutes after starting firefox. The reboots would persist even
       | when I would boot into Windows instead of Linux after one of the
       | forced reboots. Once I narrowed it down to firefox causing the
       | reboots, I started it in safe mode and disabled WebRender, and I
       | haven't had any issues since. This was with a 1050TI graphics
       | card.
        
         | [deleted]
        
       | egfx wrote:
       | Looks a lot like older graphics cards over heating. I worked in
       | graphics QA.
        
         | trynumber9 wrote:
         | I get this frequently. Usually when an update fires and I
         | scroll. Have not yet been able to reproduce reliably. I really
         | doubt it's overheating, since it takes a fraction of a second
         | to happen and it couldn't heat up that quickly.
        
           | inetknght wrote:
           | > _it couldn 't heat up that quickly_
           | 
           | It could, actually, especially if it's not well maintained.
        
             | trynumber9 wrote:
             | It's a $1200 GPU, I do make time to clean. I'm not saying
             | it's Firefox specifically, perhaps a strange interaction
             | between Firefox and the latest Nvidia drivers. But you're
             | welcome to come check my machine.
        
         | Lammy wrote:
         | I experience this bug and my GPU is definitely not overheating.
        
         | chrisan wrote:
         | I will get the black box bug in outlook, temps are fine.
         | 
         | I've never seen this in Firefox but makes me wonder if its
         | windows related instead of FF/Outlook specific
        
         | rplnt wrote:
         | My Windows 7 + nvidia does these black boxes. The card also
         | can't handle 2 monitors anymore (crashes the system from time
         | to time).
        
       | thefurman wrote:
       | You should ask the people having the issue to switch graphics
       | cards, PSU and RAM since this >90% smells like a memory/power
       | issue. I think you've just gotten unlucky and collected a few
       | similar reports of people having memory corruptions. I am
       | guessing you cache renderings and that is why the issue sticks
       | around until you re-render.
       | 
       | If you want to reproduce it yourselves then perhaps try pointing
       | a hairdryer from a distance at the various components until they
       | start to create trouble, or alternatively just overclock them
       | towards the breaking points.
        
       | tomlong wrote:
       | Heh, i was talking about this today. I do three days a month for
       | a client where I use their computers and it's the only time I
       | ever use Windows 10 and the only time I see this. I was asking
       | around about it but no one else was using Firefox. Next time I'm
       | in I'll pay more attention.
        
       | j1elo wrote:
       | I'm curious, why does a team working for Mozilla need to host
       | their blog as a free account on wordpress.com? They really don't
       | have a unified blog system to provide a more official feeling to
       | all their different departments?
       | 
       | Or is this just an unofficial blog from people that is unrelated
       | to Mozilla?
        
       | lucideer wrote:
       | Given this is the mozillagfx blog, one would hope the "gfx"
       | displayed on the blog were a little better: I can't make out the
       | graphical glitches described in those tiny low-resolution
       | screenshots.
        
         | VWWHFSfQ wrote:
         | you dont see the glitches in this image
         | https://mozillagfx.files.wordpress.com/2020/02/screen-shot-g...
        
           | ilikehurdles wrote:
           | Is that not how reddit looks?
        
             | speedgoose wrote:
             | There is old.reddit.com for the boomers.
        
             | k1t wrote:
             | Interesting to note that even the address bar appears to be
             | affected. Several characters are missing from the URL in
             | that screenshot.
        
               | capableweb wrote:
               | Yeah, when I had it happen to me, it happens to the
               | entire Firefox instance, settings page, url bar, tab
               | names, context menu (right click menu) and everything in
               | between.
        
               | cpeterso wrote:
               | Much of Firefox's UI is HTML and can be affected by bugs
               | like this. But it is very interesting to see that bug
               | appears to affect both the app UI and web page at the
               | same time.
        
       | rmccue wrote:
       | I am fairly certain I've seen this bug, but on macOS using a
       | MBP's integrated graphics. I opted into WebRender a while ago via
       | about:config, so I had figured it was just a random beta issue.
       | Will have to see if I can capture it next time it happens!
        
         | skept wrote:
         | Me too. I've seen it happen on more than a couple of occasions
         | while visiting Trello.com and YouTube.com. Firefox isn't my
         | primary browser, partly for this reason.
         | 
         | MBP 2013 with integrated graphics, running Mojave and the
         | latest stable public release of Firefox. I haven't messed with
         | about:config.
        
       | MayeulC wrote:
       | > Update: we have created the channel #gfx-wr-glitch on Matrix
       | 
       | Funnily, this alias is incomplete and therefore not enough to
       | join. A room ID might have been enough, but just an alias without
       | a server part is worthless, a bit like someone left an e-mail
       | adress as gfx-wr-glitch@, without specifying the rest.
       | 
       | I've successfully joined trough #gfx-wr-glitch:mozilla.org,
       | (roomid is !qaAtjMWizEgMcVSbNH:mozilla.org, no alias on
       | matrix.org) and told them so.
       | 
       | Edit: they fixed it. I wonder how often that happens with those
       | new to Matrix?
        
       | rvz wrote:
       | This reminds me of the comments section or sometimes a mailing
       | list for a particular bug in a driver or a low-level component
       | and most of all the replies were from 'users' who weren't helping
       | to solving the actual problem in the discussion. Then one day an
       | unknown contributor not only was able to reproduce the bug but
       | also sent an actual fix and ended up gaining commit access to the
       | project after staying there for a while.
       | 
       | Whenever I hear the 'mythical legend of the 10X rockstar
       | developer', I think of them. Mozilla needs more of those
       | developers to reproduce AND send patches to interesting bugs like
       | this. Not the whining copypasta forum-posting 'users' calling
       | themselves 'developers' who take many open-source projects like
       | this for granted and don't appreciate the time spent by the
       | maintainers of the project.
       | 
       | Nowadays they're usually doing this on a developer social network
       | through every maintainers nightmare 'The Issues Tab'.
        
         | paxys wrote:
         | Hah! As an open source maintainer for a mildly popular repo a
         | big chunk of my time is spent weeding out people filing issues
         | and opening PRs for trivial changes (like adding a line to the
         | README file) just so they can claim to be a "contributor".
         | Meanwhile there are a ton of issues that are ready to code with
         | a full explanation and are even marked as such ("good first
         | issue" or whatever else) that stay untouched.
         | 
         | Regardless of community engagement, perceived interest, Github
         | stars or whatever else -- finding a developer willing to spend
         | actual time and effort to make a project better is very, very
         | rare.
        
           | jpxw wrote:
           | Which repo, out of interest?
        
           | sarah180 wrote:
           | Yeah, people who drive-by PRs to unnecessarily fix a
           | minuscule style or dependency-version issue is one of my pet
           | peeves. I don't spend a lot of time on it, but this kind of
           | cynical game playing sucks. These kinds of contributions
           | produce a net loss for OSS, not a net win.
        
       | j0e1 wrote:
       | I have seen this in the past (I use FF-nightly on MacOS) but
       | subsequent updates seemed to have fixed it. Although maybe some
       | other factor affecting the frequency. Will keep an eye out.
        
       | pg_is_a_butt wrote:
       | I thought I was the only one seeing this... they claim it's only
       | windows 10, but I'm also seeing it on a 2012 macbook pro i5 intel
       | graphics 3000. Not very often, but enough to be very annoyed and
       | concerned by it.
       | 
       | My fear is some other program is gaining access to portions of
       | the screen or video memory to scrape for banking information
       | using ocr or something like that. Sometimes the glitches will be
       | filled with upside down and stretched/keystone shifted versions
       | of an area of a rendered page from a different tab. The keystone
       | shift triggers my off-by-1 memory allocation bug sense... But it
       | might be some other driver issue or exploit causing that on
       | purpose somehow (like rowhammer). I fear this is going to take
       | years to track down.
        
       | Const-me wrote:
       | I'm almost sure it's incorrect usage of D3D. I've encountered and
       | fixed similar bugs in my 3D graphics code.
       | 
       | Based on the symptoms and difficulties to reproduce, I think what
       | you see on the screenshots are incomplete renders. The FF code
       | submitted some draw calls to GPU, and copied the render target
       | texture without waiting for draw calls to complete. A good way to
       | fix is use a D3D11_QUERY_EVENT query to wait for completion of
       | rendering.
       | 
       | If all GPU access happens through D3D11 this shouldn't happen
       | i.e. the API guarantees to wait for the completion of previously
       | submitted draw calls. It may happen in practice when mixing
       | multiple GPU APIs, e.g. when using DXGI surface sharing to pass
       | textures between D3D11 and DX9. Also, it may happen when using
       | D3D from multiple threads. Easy way to detect the latter, set
       | D3D11_CREATE_DEVICE_DEBUG flag when creating the device, and read
       | warnings in debug output of the process.
       | 
       | Another possibility is just bugs in rendering code. To
       | troubleshoot them, https://renderdoc.org/ is awesome.
       | Unfortunately, if the FF doesn't use D3D to present, only
       | rendering to textures, some changes to FF's source code is
       | required to capture frames with RD, see this page for details:
       | https://renderdoc.org/docs/in_application_api.html
        
         | ehsankia wrote:
         | Makes sense that a delay sensitive bug is hard to repro too. I
         | have definitely seen similar artifacts throughout the years in
         | Chrome too come and go, seems like it's a common problem in
         | browser D3D implementations.
        
           | Const-me wrote:
           | A few years ago a customer reported a bug in my software
           | which only happened with a specific 3D scene, on specific
           | GPUs (my desktop rendered that scene fine), and was only
           | happening rarely. That's how I have learned about that GPU
           | synchronization issue across graphics APIs which may cause
           | incomplete renders.
        
         | core-questions wrote:
         | I saw the bug on Ubuntu 18 this morning, on FF 72.0.2 on Nvidia
         | 435.21-0ubuntu0.18.04.2. Can't reproduce. Assumed it was
         | because I have 2x 4K screens plus another 1080p one and I often
         | get weird graphics issues with this setup.
        
           | clarry wrote:
           | I don't know if it's the same bug but I've certainly seen a
           | _similar_ bug (weird glitches in display that disappear when
           | you scroll) on Fedora with AMD graphics (open source amdgpu
           | driver, X), running Firefox nightly. One screen only..
        
         | hrgiger wrote:
         | Yep I think you are right and I think I can replicate and I
         | dont think its just windows:)
         | 
         | https://imgur.com/a/fpnWKhm
         | 
         | Another post mentioned 2x4k screens so I thought creating load
         | might delay expected events so I set up gpu to lowest:
         | 
         | "echo low >
         | /sys/class/drm/card0/device/power_dpm_force_performance_level"
         | 
         | Then opened 2 drm and lot of youtube videos with new tabs and
         | keep refreshing reddit, after a minute or two got black boxes
         | 
         | specs here: https://pastebin.com/JXE2HFUu
         | 
         | EDIT: Nope its not it turns out marvel has black theme, sorry
         | misleading comment, move along
        
           | Const-me wrote:
           | > I dont think its just windows
           | 
           | I have no idea how exactly FF uses GPU. However, all 3D APIs,
           | especially modern ones, are just ways to access the
           | functionality of underlying GPU hardware, which doesn't
           | depend on the OS.
           | 
           | If FF uses Vulkan, the direct equivalent of that query is
           | probably VkFence, but unlike D3D11 VK has other ways too,
           | subpasses and VkSubpassDependency, and maybe something else I
           | forgot.
        
             | hrgiger wrote:
             | Yeah sorry my bad , turns out marvel had black theme
        
             | leeoniya wrote:
             | as muizelaar says below,
             | 
             | "WebRender is actually using D3D through OpenGL on top of
             | ANGLE"
             | 
             | maybe an angle bug, then.
        
         | [deleted]
        
         | est31 wrote:
         | This is interesting, as Webrender does not use D3D but OpenGL,
         | so the parts of Firefox that use D3D might interact badly with
         | it.
         | 
         | There is work to port Webrender to gfx-rs which abstracts over
         | Vulkan, Metal and modern DirectX but it seems to only live in
         | the fork of the Hungarian Szeged university for now:
         | https://github.com/szeged/webrender/issues/198
         | 
         | Maybe then Firefox can purely use DirectX?
        
           | muizelaar wrote:
           | WebRender is actually using D3D through OpenGL on top of
           | ANGLE
        
             | leeoniya wrote:
             | i was also wondering about the gfx-rs port. i've been
             | watching that repo for over a year, and it's quite
             | impossible to tell how far along things actually are today.
        
             | est31 wrote:
             | Didn't know that, thanks for the info!
        
       | modeless wrote:
       | The state of debugging for graphics code is deplorable. When you
       | run code on a GPU you almost always have a gigantic closed source
       | binary blob underneath you, the graphics driver. Graphics drivers
       | contain complete compilers that munge your code with a focus on
       | speed over correctness. The graphics driver is often years out of
       | date, and you can't even run it yourself to reproduce issues
       | unless you go out and buy the exact hardware that each user has.
       | 
       | The state of the art in debugging GPU issues is to have a closet
       | full of random hardware purchased used on eBay that hopefully
       | contains something close enough to what you need to reproduce the
       | issue you're working on.
       | 
       | Most fancy debugging tools pretend that GPUs don't exist and GPU-
       | focused debuggers are incredibly buggy and feature-poor, not to
       | mention hardware specific in many cases.
        
         | Const-me wrote:
         | It's not that bad, at least on Windows.
         | 
         | > contain complete compilers that munge your code with a focus
         | on speed over correctness
         | 
         | If you're a developer, the right tools are available. Set
         | D3D11_CREATE_DEVICE_DEBUG when creating the device, also run
         | debug builds of your HLSL shaders. You'll get huge amount of
         | error checking and diagnostics this way, including very
         | detailed and specific messages about incorrect API use.
         | 
         | > GPU-focused debuggers are incredibly buggy and feature-poor
         | 
         | I indeed found and reported bugs in GPUs and their drivers
         | (mostly Intel GPUs), but it only was a few times over my
         | career. The majority of times they were bugs in my code, not in
         | GPU drivers, and renderdoc.org helped a lot fixing them.
         | 
         | I generally agree GPU debugging is harder than CPU debugging,
         | but I don't see how open source driver gonna help. It's an
         | unfortunate combination of execution model (many thousands
         | hardware threads running your code in parallel), external piece
         | of hardware completely separate and asynchronous from the CPU,
         | and very limited ways to interact or even output data (you
         | can't printf messages, nor allocate dynamic memory, from GPU
         | code).
        
           | leeoniya wrote:
           | > The majority of times they were bugs in my code, not in GPU
           | drivers
           | 
           | the Servo/WebRender folks maintain such a list of driver bugs
           | with workarounds, you may find useful:
           | 
           | https://github.com/servo/webrender/wiki/Driver-issues
        
           | MayeulC wrote:
           | > It's not that bad, at least on Windows.
           | 
           | Funny you say that. I've seen many developers praising the
           | open source stack under Linux, as you can step right into the
           | driver and fix it yourself, instead of landing in symbols
           | land.
           | 
           | Feral Interactive mentioned it there, for instance:
           | https://www.gamingonlinux.com/articles/interview-with-
           | feral-...
        
         | brundolf wrote:
         | I've never understood the logic behind closed-source drivers.
         | Nobody pays for a driver, people pay for hardware. If you want
         | your hardware to get better support, and therefore become more
         | popular, aren't you incentivized to open-source the drivers?
        
           | ensiferum wrote:
           | It'd expose trade secrets and give away the details basically
           | giving away any competitive edge.
        
           | mschuster91 wrote:
           | There is a disincentive: patents/IP as one thing (competitors
           | could deduce how your stuff works from oss drivers), and the
           | other thing is exclusivity with games: especially nvidia has
           | deals with game developers to tweak their games in drivers
           | (!) - things like hand optimized shaders or other rendering
           | settings, that provide superior quality for the gamer, so
           | that gamers prefer to buy nvidia cards over AMD.
           | 
           | With open source drivers, AMD or Intel could just walk in and
           | steal whatever optimizations nvidia has made for a game.
        
             | JohnFen wrote:
             | Everything that is patented is already fully disclosed to
             | the public. It's a requirement of getting a patent. Keeping
             | drivers closed-source is more likely to be due to the
             | presence of trade secrets or that the code includes
             | licensed bits that the manufacturer doesn't have the right
             | to disclose the source code to.
        
               | mschuster91 wrote:
               | With patents you're afaik only required to describe the
               | process itself - but not the implementation in code, and
               | especially not optimizations fitted to your architecture.
        
               | sarah180 wrote:
               | From the USPTO:
               | 
               | > The specification must include a written description of
               | the invention and of the manner and process of making and
               | using it, and is required to be in such full, clear,
               | concise, and exact terms as to enable any person skilled
               | in the technological area to which the invention
               | pertains, or with which it is most nearly connected, to
               | make and use the same.
               | 
               | You don't have to provide code, but you have to teach the
               | reader of your patent how to make and use the invention.
        
           | et1337 wrote:
           | One possible factor: graphics drivers are full of app-
           | specific hacks to make benchmarks look good, on the level of
           | "if game == GTAV then run super special fast code instead of
           | whatever the game is telling us to do"
        
             | metalliqaz wrote:
             | they definitely do that, but they don't keep it secret
             | anymore. they even advertise it as "game ready drivers"
             | from nvidia.
        
           | cpeterso wrote:
           | Companies think open-source drivers will reveal "special
           | sauce" implementation details of their graphics hardware to
           | their competitors.
        
             | jjoonathan wrote:
             | No, they think it will prove their use of bog-standard
             | techniques to people who laid patent minefields, instantly
             | fueling a hundred lawsuits.
             | 
             | The USPTO is terrible at performing prior art searches and
             | terrible at rejecting obvious claims, so there are legions
             | of trolls waiting in the wings to jump on them if they go
             | open source.
        
           | modeless wrote:
           | > Nobody pays for a driver
           | 
           | This is not true. Driver quality is a major differentiating
           | factor between GPUs and absolutely influences purchasing
           | decisions.
           | 
           | GPU makers don't want their competitors to be able to take
           | parts of their drivers and benefit from them. They want to
           | protect trade secrets. They want to avoid revealing how many
           | of their competitors' patents they are violating. They don't
           | own the rights to some third party code or trade secrets that
           | are incorporated in their drivers. They want to avoid
           | revealing future product plans.
           | 
           | Of course it's debatable whether closed source drivers
           | actually help with all of the above reasons, or whether they
           | are good reasons to begin with. But those are the reasons.
        
           | 0x00000000 wrote:
           | I can understand that AMD and Nvidia have spent a ton of time
           | and money developing their drivers and that ML/GPGPU
           | performance and features are highly competitive.
           | 
           | But embedded GPUs are so fucking obnoxious. There's about a
           | million of them and they pretty much all have proprietary
           | binary blobs. Pretty worrying for something that could
           | potentially allow any device to be remotely compromised via
           | some malicious webGL or something. Good luck getting the
           | manufacturer to continue supporting it 3 years from now
           | though
        
           | z3t4 wrote:
           | I guess, it makes it harder to copy the hardware design,
           | which is often off the shelf parts. Once you have the
           | finished design it's relative cheap to mass produce.
        
           | heavyset_go wrote:
           | > _aren 't you incentivized to open-source the drivers?_
           | 
           | Opening the source to drivers as they exist now might expose
           | IP that might not be yours to share, IP that you aren't
           | licensed to use or open you up to liability because of how
           | bad your drivers actually are.
           | 
           | That said, I do believe hardware companies should prioritize
           | open-source drivers to benefit themselves and their
           | customers.
        
           | simias wrote:
           | I think the incentive to keep drivers closed is not huge, but
           | the incentive to open source them is effectively nil,
           | especially from the point of view of "management types".
           | 
           | It may on may not end up improving support, but you can't
           | really know that ahead of time. Then you have the risk of
           | people using your code against you, finding vulnerabilities,
           | patent/IP violations or simply reverse-engineering your
           | hardware more easily. You also won't be able to cheat in
           | benchmarks anymore.
           | 
           | There's a cultural aspect to it too. Paying all these
           | engineers to write that code was expensive, and now you want
           | to give it all away _for free_? Most companies never do that
           | for anything, why would they make an exception?
           | 
           | It's dumb, I too would love for these drivers to become open
           | source, but it doesn't look like it will be happening any
           | time soon.
        
             | sarah180 wrote:
             | > Paying all these engineers to write that code was
             | expensive, and now you want to give it all away for free?
             | Most companies never do that for anything, why would they
             | make an exception?
             | 
             | I'm not saying it doesn't exist, but I've been doing
             | professional software development for more than twenty
             | years and have never encountered this. There's plenty of
             | "we should be paid for our work and innovation" but nothing
             | so reflexive as what you describe here.
        
           | gputhrowaway630 wrote:
           | Graphics drivers contain competitive optimizations that make
           | a significant difference in the performance of the hardware.
           | Since these optimizations are both costly (in R&D) and allow
           | for the vendors GPU to perform better than a competitors,
           | they do not share these optimizations (that a competitor may
           | or may not use to improve their own driver). And since people
           | pay ultimately for performance, not hardware, the driver is
           | just as important as the silicon.
           | 
           | Your second point is correct, that open source drivers do get
           | better support. AMD has better support on Linux than NVIDIA
           | because it has an officially supported open source driver
           | (AMDGPU). However, the support they receive from open-
           | sourcing the drivers is not always the R&D required to gain a
           | competitive performance advantage, limiting the
           | competitiveness of an open source driver (at least compared
           | to proprietary).
        
           | ksec wrote:
           | > aren't you incentivized to open-source the drivers?
           | 
           | No, Not at all.
           | 
           | If we go all the way back to 3Dfx era, we have seen dozens of
           | GPU ( or 2D/3D Graphics Accelerator before the term GPU was
           | coined ) trying to compete in the PC space, 3D Labs, Matrox,
           | PowerVR, Intel I740, S3, ATI, Nvidia, Rendition, ( These are
           | on top of my head, sorry if I missed any of your favourite ).
           | None of them had much problem with designing hardware, their
           | maximum triangles, ( If I remember correctly it was one of
           | the unit used to market graphics card before GFLOPS were used
           | ) were all on par with each other. And some even exceed the
           | current dominant players, but in the end they all failed.
           | 
           | Why? Because they cant get the drivers / software to optimise
           | the use of their Hardware. They do not perform any where
           | close to their potential in Tomb Raider or DOOM. There are
           | huge amount of optimisation built up over the years. As
           | Nvidia once said ( That was even before their huge bet on
           | CUDA ), 60% of their engineers are Software.
           | 
           | To point where the I am going to say, the Driver _IS_ the
           | GPU. You are just paying the hardware to use it.
           | 
           | * And now I feel very old just typing this up. :/
        
           | monocasa wrote:
           | They do sketch things, like keep a database of third party
           | shaders that warranted hand optimization by their driver
           | team, and their replacement shaders. I'd be surprised if they
           | could open source such a thing. It's an IP nightmare.
        
             | apetresc wrote:
             | Why would that be sketchy? I'm sure there's lots of bad
             | things in there, but hand-optimizing common third-party
             | code paths doesn't seem like it should be one of them.
             | 
             | Would there be some sort of uproar if people found out that
             | Firefox had special optimizations for common websites, for
             | instance?
        
               | monocasa wrote:
               | Because they use partial verbatim copies of other
               | people's shader code to make that happen.
        
               | heavyset_go wrote:
               | If I found out my competitors made sweetheart deals with
               | hardware manufacturers so that their software worked
               | better on their hardware than my software does, I'd be
               | pissed.
               | 
               | > _Would there be some sort of uproar if people found out
               | that Firefox had special optimizations for common
               | websites, for instance?_
               | 
               | It would ruffle a few feathers if Chrome was optimized
               | for Google properties, but ran their competitors' code
               | with a performance penalty.
               | 
               | One of the issues in _United States v Microsoft_ was that
               | IE used optimized APIs that Microsoft 's competitors,
               | like Netscape, didn't have access to.
        
               | akersten wrote:
               | > Would there be some sort of uproar if people found out
               | that Firefox had special optimizations for common
               | websites, for instance?
               | 
               | There was a comment on this site a few days ago that
               | claimed Google was being anti-competitive by hard-coding
               | a list of their web properties into Chrome for it to send
               | diagnostic info when visiting them, so yes, anything
               | where there's a special path for some 1st/3rd parties but
               | not others could be construed in many ways that look bad
               | for the author.
        
         | kevingadd wrote:
         | On the bright side the situation is at least better on Windows
         | - D3D11 and D3D9 both have well-specified behavior and full
         | software rasterizers that can be used to render a reference
         | version of a given frame and then debug it at a pixel level.
         | Wish I had something like that for OpenGL... console game
         | developers have had toys like this for ages.
         | 
         | It's 2020 and I still sometimes swap my renderer from OpenGL to
         | D3D9 when I need to debug a graphics issue because the D3D9
         | graphics debugging tools are that much better than cutting-edge
         | GL debuggers. (I'd use the D3D11 debugging tools but my 11
         | backend doesn't work right)
        
       | dmead wrote:
       | is this a real request for help, or a marketing-look-at-our-blog
       | thing?
        
         | Lammy wrote:
         | If you can suggest a better way to get word about a tricky bug
         | out to people who don't usually look at Mozilla's bug tracker
         | I'm sure they'd be happy to hear it :)
        
         | jbonisteel wrote:
         | This is a real request for help!
        
         | rafaelvasco wrote:
         | When in doubt assume the best of people, not the worst by
         | default.
        
       | tvelichkov wrote:
       | This very much sound like a similar issue Linux users are facing
       | from more than a year and it's still not resolved?
       | https://askubuntu.com/questions/1088324/firefox-becoming-unr...
        
         | twic wrote:
         | I don't think so - in the Linux bug, Firefox becomes
         | unresponsive, whereas in the bug in the article, Firefox runs
         | as normal, and the blanks can be cleared by scrolling or
         | mousing over.
         | 
         | I see a somewhat similar bug on my Linux box, where windows
         | flicker between black and normal, and the flickering stops if i
         | focus on the window. I don't think it's specific to Firefox,
         | though - i believe i've seen all sorts of apps do it. I do have
         | an nvidia graphics card, FWIW.
        
           | tvelichkov wrote:
           | As someone who experience this very often I can't say that
           | Firefox is becoming unresponsive, you can still scroll
           | up/down, change tabs, etc.. but the all pages are glitched
           | similar (even worse) to the screenshots.
        
       | reuben_scratton wrote:
       | I haven't seen this particular issue but I've seen very similar
       | bugs in my own work where GPU and CPU are not properly sync'd
       | when using glyph or small image cache textures.
       | 
       | E.g. gpu has a frame pending, CPU updates glyph cache, GPU
       | renders pending frame using incorrect cache data.
        
       | electrotype wrote:
       | Why the Nightly version only, I'm curious?
        
         | sleavey wrote:
         | The Firefox developers only patch security vulnerabilities in
         | standard Firefox releases. All minor bug fixes and new features
         | go into Nightly and only after a few months into stock Firefox.
        
         | cpeterso wrote:
         | Presumably there are other graphics bugs that have been fixed
         | in Firefox Nightly but still exist in the Beta or Stable
         | Release channels. Best to debug and reproduce the bug in the
         | code closest to version the Mozilla engineers are using.
        
       | petargyurov wrote:
       | This bug happens to me somewhat often. In fact it happened to me
       | yesterday. It fixes itself after a couple of seconds. No idea how
       | it happens - I haven't noticed a pattern.
       | 
       | I have a GTX 1070.
        
         | godelski wrote:
         | This is interesting. I have a 1060Q and used to get the text
         | tearing all the time. In the last (2 or 3?) FF updates I have
         | yet to see it happen. (Currently v73.0)
        
         | abacadaba wrote:
         | same, gp107. ubuntu, usually after session resume.
         | 
         | the good: it used to crash my pc when the render process would
         | just hang at 100% after resume, doesnt anymore
         | 
         | the bad: sometimes i have to scroll the page and tab bar after
         | resume now
         | 
         | progress
        
         | a_f wrote:
         | I too have seen the same issue, and I also have a GTX 1070. I
         | also sometimes see the characters on a page suddenly not render
         | too, or parts of the page go black like the squares they
         | mention. I will keeping an eye out to see if I can get some
         | repro steps.
        
         | jbonisteel wrote:
         | Could you file a bug for us?
         | https://bugzilla.mozilla.org/enter_bug.cgi?product=Core&comp...
        
           | capableweb wrote:
           | I'm in the same boat with Windows 10 + nvidia 2080ti. Not
           | sure why you want a bug report filled when neither of us have
           | any way of reproducing the issue nor more information about
           | where/when it happens.
        
       ___________________________________________________________________
       (page generated 2020-02-18 23:00 UTC)