New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 868761 link

Starred by 3 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug



Sign in to add a comment

Long/janky OpenGL calls when using the dGPU on dual-GPU MacBook Pros

Project Member Reported by ccameron@chromium.org, Jul 30

Issue description

To reproduce, take a dual-GPU Macbook Pro, switch to the dGPU, and then open two tabs:
- about:tracing
- poster circle
In the trace, record the "gpu" category, and tab-switch between the two tabs.

Note that many GL calls will be extremely slow. In particular, glTexSubImage2D calls (of tiny sizes, like 32x32), can often be ~20-30 msec. See the attached picture of a trace. This has the effect of making Chrome seem laggy (especially at tab-switch)

Some data points:
- This usually happens after allocating or freeing several IOSurfaces.
- This does not occur when using the iGPU
- This does not happen when disabling IOSurface use via the command line flag
    --disable-gpu-memory-buffer-compositor-resources
- This happens both when using SW and GPU raster
- This affects a 2013 Macbook Pro with 
    GPU0 VENDOR = 0x10de, DEVICE= 0x0fd5
    GPU1 VENDOR = 0x8086, DEVICE= 0x0166
- Other machines have not yet been tested

 
slow-texsubimage-3.png
219 KB View Download
Cc: senorblanco@chromium.org mar...@chromium.org
 Issue 867014  has been merged into this issue.
I tested this on a more recent MacBook Pro (2016 with AMD dual-GPU 0x1002/0x67ef and 0x8086/0x191b), and this bug is not present.

So I'd chalk this up to bitrot/neglect of older models. Good to know that it's just affecting my machine and isn't general.
I haven't tried a >2 months old Chrome build yet, but I wouldn't rule out a kernel regression on macOS since Apple likely don't test this configuration much either, especially since it's OpenGL (vs Metal) and performance-only (not correctness).
Restarting Chrome generally makes it behave properly. Interestingly it was fairly snappy since I restarted it yesterday, then I watched two videos from 
http://11foot8.com/ (we love car crashes, right?) and then Chrome immediately became sluggish again, event after the tab was closed and CPU usage was low again.
Irony: I exchanged my MBP (Intel 4000 + nvidia GT650M) for a MacPro (dual AMD D300). Still with the same 3 monitors.

The GPU hangs once per day but rest of the system still clearly works, i.e. I can ssh into the MacPro for my laptop and reboot it. Last hang was right after I opened a tab.

I wonder if it's an macOS Dual-GPU >2 monitors specific regression. :/

Sign in to add a comment