Wednesday, 24 October 2018

Solve SlowRendering issue with OpenGL

We have been seeing reports of slow rendering of frames in google play vitals. When trying to debug better, it was recommended to use adb shell dumpsys gfxinfo to get more information.

Our game uses OpenGL and only 1 frame is listed when using the above command to solve the issue.

  1. Any suggestions on how we can debug OpenGL applications for slow rendering.
  2. Also want to understand how would google's method of slow rendering be when the game has only 1 frame.

Attaching output of adb shell dumpsys gfxinfo

Applications Graphics Acceleration Info:
Uptime: 54549948 Realtime: 253718955
** Graphics info for pid 22290 [com.hashcube.sqmtest] **
Stats since: 54484683697130ns
Total frames rendered: 2
Janky frames: 2 (100.00%)
50th percentile: 105ms
90th percentile: 105ms
95th percentile: 105ms
99th percentile: 105ms
Number Missed Vsync: 2
Number High input latency: 0
Number Slow UI thread: 2
Number Slow bitmap uploads: 0
Number Slow issue draw commands: 0
HISTOGRAM: 5ms=0 6ms=0 7ms=0 8ms=0 9ms=0 10ms=0 11ms=0 12ms=0 13ms=0 14ms=0 15ms=0 16ms=0 17ms=0 18ms=0 19ms=0 20ms=0 21ms=0 22ms=0 23ms=0 24ms=0 25ms=0 26ms=0 27ms=0 28ms=0 29ms=0 30ms=0 31ms=0 32ms=0 34ms=0 36ms=0 38ms=0 40ms=0 42ms=0 44ms=0 46ms=0 48ms=0 53ms=0 57ms=0 61ms=1 65ms=0 69ms=0 73ms=0 77ms=0 81ms=0 85ms=0 89ms=0 93ms=0 97ms=0 101ms=0 105ms=1 109ms=0 113ms=0 117ms=0 121ms=0 125ms=0 129ms=0 133ms=0 150ms=0 200ms=0 250ms=0 300ms=0 350ms=0 400ms=0 450ms=0 500ms=0 550ms=0 600ms=0 650ms=0 700ms=0 750ms=0 800ms=0 850ms=0 900ms=0 950ms=0 1000ms=0 1050ms=0 1100ms=0 1150ms=0 1200ms=0 1250ms=0 1300ms=0 1350ms=0 1400ms=0 1450ms=0 1500ms=0 1550ms=0 1600ms=0 1650ms=0 1700ms=0 1750ms=0 1800ms=0 1850ms=0 1900ms=0 1950ms=0 2000ms=0 2050ms=0 2100ms=0 2150ms=0 2200ms=0 2250ms=0 2300ms=0 2350ms=0 2400ms=0 2450ms=0 2500ms=0 2550ms=0 2600ms=0 2650ms=0 2700ms=0 2750ms=0 2800ms=0 2850ms=0 2900ms=0 2950ms=0 3000ms=0 3050ms=0 3100ms=0 3150ms=0 3200ms=0 3250ms=0 3300ms=0 3350ms=0 3400ms=0 3450ms=0 3500ms=0 3550ms=0 3600ms=0 3650ms=0 3700ms=0 3750ms=0 3800ms=0 3850ms=0 3900ms=0 3950ms=0 4000ms=0 4050ms=0 4100ms=0 4150ms=0 4200ms=0 4250ms=0 4300ms=0 4350ms=0 4400ms=0 4450ms=0 4500ms=0 4550ms=0 4600ms=0 4650ms=0 4700ms=0 4750ms=0 4800ms=0 4850ms=0 4900ms=0 4950ms=0
Caches:
Current memory usage / total memory usage (bytes) / hit ratio (%) / biggest memory usage (bytes):
  TextureCache                0 / 25165824    0.0000         0
  LayerCache                  0 / 16777216    0.0000         0 (numLayers = 0)
  Layers total          0 (numLayers = 0)
  RenderBufferCache           0 /  2097152    0.0000         0
  GradientCache               0 /   524288    0.0000         0
  PathCache                   0 /  4194304    0.0000         0
  TessellationCache           0 /  1048576    0.0000
  TextDropShadowCache         0 /  2097152    0.0000         0
  PatchCache                  0 /   131072    0.0000         0
FontRenderer doesn't exist.
Other:
  FboCache                    0 /        0    0.0000
Total memory usage:
  0 bytes, 0.00 MB
All Textures in TexctureCache 
# No./ memory usage (bytes)/ size (width X height) / image type / hit count:
Pipeline=FrameBuilder
Profile data in ms:
    com.hashcube.sqmtest/com.hashcube.sqmtest.sqmtestActivity/android.view.ViewRootImpl@54ed8ea (visibility=0)
    Draw    Prepare Process Execute
---PROFILEDATA---
Flags,IntendedVsync,Vsync,OldestInputEvent,NewestInputEvent,HandleInputStart,AnimationStart,PerformTraversalsStart,DrawStart,SyncQueued,SyncStart,IssueDrawCommandsStart,SwapBuffers,FrameCompleted,DequeueBufferDuration,QueueBufferDuration,
1,54494739082491,54494822415821,9223372036854775807,0,54494830560616,54494830733793,54494830737803,54494840259158,54494840282647,54494840441501,54494840561397,54494841406033,54494844766814,1601000,347000,
1,54522949388595,54522982721927,9223372036854775807,0,54522992186751,54522992208730,54522992211386,54523005016438,54523005788209,54523006430397,54523006538938,54523007971438,54523011149303,1596000,214000,
---PROFILEDATA---
View hierarchy:
  com.hashcube.sqmtest/com.hashcube.sqmtest.sqmtestActivity/android.view.ViewRootImpl@54ed8ea
  17 views, 14.75 kB of display lists
Total ViewRootImpl: 1
Total Views:        17
Total DisplayList:  14.75 kB
threadConfig: {0 1.0 showBtnBg = 0 ?mcc?mnc [en_GB] ldltr sw360dp w360dp h616dp 240dpi nrml long port finger -keyb/v/h -nav/h s.4}



from Solve SlowRendering issue with OpenGL

No comments:

Post a Comment