Repository: flutter
Issue: [webview]Shader compilation error on Android
Labels: platform-android,p: webview,package,a: error message,P2,team-android,triaged-android

This problem has been reported before but it has not been resolved, I have the latest stable version of flutter (2.8.1), open this issue because the others are closed, this problem happens every time I navigate to a screen with Flutter Webview and come back to another screen without Webview , from then on it keeps showing this message in the log all the time, it only stops showing this error if I stop and restart the debugging


https://github.com/flutter/flutter/issues/33019
https://github.com/flutter/flutter/issues/33018


## Steps to Reproduce
just create an App with two screens, one without Webview and one with, once you navigate to screen with Webview and come back the problem appears, this on AVD Android API 30/31  on Windows 10/11 I haven't tested it on Linux or MacOS.

### demo project
https://github.com/insinfo/shader_compilation_demo

![image](https://user-images.githubusercontent.com/12227024/148084846-24ca5354-1082-44c1-904b-ce776278ce88.png)




https://www.youtube.com/watch?v=6QCl588h1-0&ab_channel=IsaqueNeves




## Logs
<details>
<summary>logs</summary>

```console
I/WebViewFactory( 3173): Loading com.google.android.webview version 83.0.4103.106 (code 410410681)
I/cr_LibraryLoader( 3173): Loaded native library version number "83.0.4103.106"
I/cr_CachingUmaRecorder( 3173): Flushed 3 samples from 3 histograms.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
I/TetheringManager( 3173): registerTetheringEventCallback:com.example.shader_compilation_demo
W/chromium( 3173): [WARNING:dns_config_service_posix.cc(341)] Failed to read DnsConfig.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
E/cr_PlatformSer-Internal( 3173): UsageReporting query failed
W/ompilation_dem( 3173): Accessing hidden method Landroid/media/AudioManager;->getOutputLatency(I)I (greylist, reflection, allowed)
E/cr_PlatformSer-Internal( 3173): Unable to determine Safe Browsing user opt-in preference
W/cr_media( 3173): Requires BLUETOOTH permission
D/HostConnection( 3173): HostConnection::get() New Host Connection established 0xe89e77d0, tid 3271
D/HostConnection( 3173): HostComposition ext ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_native_sync_v2 ANDROID_EMU_native_sync_v3 ANDROID_EMU_native_sync_v4 ANDROID_EMU_dma_v1 ANDROID_EMU_direct_mem ANDROID_EMU_host_composition_v1 ANDROID_EMU_host_composition_v2 ANDROID_EMU_vulkan ANDROID_EMU_deferred_vulkan_commands ANDROID_EMU_vulkan_null_optional_strings ANDROID_EMU_vulkan_create_resources_with_requirements ANDROID_EMU_YUV_Cache ANDROID_EMU_vulkan_ignored_handles ANDROID_EMU_has_shared_slots_host_memory_allocator ANDROID_EMU_vulkan_free_memory_sync ANDROID_EMU_vulkan_shader_float16_int8 ANDROID_EMU_vulkan_async_queue_submit ANDROID_EMU_sync_buffer_data ANDROID_EMU_read_color_buffer_dma GL_OES_EGL_image_external_essl3 GL_OES_vertex_array_object GL_KHR_texture_compression_astc_ldr ANDROID_EMU_host_side_tracing ANDROID_EMU_gles_max_version_3_0
D/EGL_emulation( 3173): eglCreateContext: 0xe89e7760: maj 3 min 0 rcv 3
D/EGL_emulation( 3173): eglMakeCurrent: 0xe89e7760: ver 3 0 (tinfo 0xb55b21d0) (first time)
I/VideoCapabilities( 3173): Unsupported profile 4 for video/mp4v-es
W/cr_MediaCodecUtil( 3173): HW encoder for video/avc is not available on this device.
D/EGL_emulation( 3173): eglCreateContext: 0xe89e78b0: maj 3 min 0 rcv 3
D/EGL_emulation( 3173): eglMakeCurrent: 0xe89cfeb0: ver 3 0 (tinfo 0xe8d379d0) (first time)
W/Gralloc4( 3173): allocator 3.x is not supported
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 14144(1096KB) AllocSpace objects, 3(60KB) LOS objects, 49% free, 2342KB/4685KB, paused 16.387ms total 187.636ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 752(48KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2342KB/4684KB, paused 525us total 153.825ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 10302(473KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2460KB/4920KB, paused 578us total 171.439ms
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/EGL_emulation( 3173): eglCreateContext: 0xe89e9670: maj 3 min 0 rcv 3
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
E/chromium( 3173): [ERROR:aw_browser_terminator.cc(125)] Renderer process (3238) crash detected (code -1).
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
E/cr_PlatformSer-Internal( 3173): UsageReporting query failed
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 4177(346KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2437KB/4875KB, paused 534us total 188.667ms
W/System  ( 3173): A resource failed to call release.
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 545(51KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2450KB/4901KB, paused 9.995ms total 49.652ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 734(47KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2448KB/4897KB, paused 832us total 152.385ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 628(50KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2446KB/4892KB, paused 544us total 147.518ms
D/EGL_emulation( 3173): eglCreateContext: 0xe89efcd0: maj 3 min 0 rcv 3
E/chromium( 3173): [ERROR:aw_browser_terminator.cc(125)] Renderer process (3288) crash detected (code -1).
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
E/cr_PlatformSer-Internal( 3173): UsageReporting query failed
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
W/System  ( 3173): A resource failed to call release.
I/ompilation_dem( 3173): Waiting for a blocking GC ProfileSaver
I/ompilation_dem( 3173): WaitForGcToComplete blocked ProfileSaver on HeapTrim for 79.125ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 779(78KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2452KB/4905KB, paused 494us total 108.524ms
D/EGL_emulation( 3173): eglCreateContext: 0xe89f5610: maj 3 min 0 rcv 3
E/chromium( 3173): [ERROR:aw_browser_terminator.cc(125)] Renderer process (3317) crash detected (code -1).
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
E/cr_PlatformSer-Internal( 3173): UsageReporting query failed
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
W/System  ( 3173): A resource failed to call release.
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 568(34KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2450KB/4900KB, paused 4.827ms total 172.439ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 554(48KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2451KB/4902KB, paused 7.118ms total 45.055ms
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 2095(131KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2448KB/4897KB, paused 11.782ms total 105.278ms
D/EGL_emulation( 3173): eglCreateContext: 0xe89f6f00: maj 3 min 0 rcv 3
E/chromium( 3173): [ERROR:aw_browser_terminator.cc(125)] Renderer process (3347) crash detected (code -1).
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
E/cr_PlatformSer-Internal( 3173): UsageReporting query failed
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
I/ompilation_dem( 3173): NativeAlloc concurrent copying GC freed 4240(324KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 2543KB/5086KB, paused 574us total 210.526ms
W/System  ( 3173): A resource failed to call release.
D/EGL_emulation( 3173): eglCreateContext: 0xe89e9670: maj 3 min 0 rcv 3
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
E/chromium( 3173): [ERROR:aw_browser_terminator.cc(125)] Renderer process (3379) crash detected (code -1).
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
W/GooglePlayServicesUtil( 3173): Google Play Store is missing.
E/cr_PlatformSer-Internal( 3173): UsageReporting query failed
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log
D/skia    ( 3173): Shader compilation error
D/skia    ( 3173): ------------------------
D/skia    ( 3173): Errors:
D/skia    ( 3173): link failed but did not provide an info log

```
</details>


```console
flutter doctor -v
[√] Flutter (Channel stable, 2.8.1, on Microsoft Windows [versÃ£o 10.0.22000.376], locale pt-BR)
    • Flutter version 2.8.1 at C:\src\flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 77d935af4d (3 weeks ago), 2021-12-16 08:37:33 -0800
    • Engine revision 890a5fca2e
    • Dart version 2.15.1

[√] Android toolchain - develop for Android devices (Android SDK version 32.0.0)
    • Android SDK at C:\Users\isaque\AppData\Local\Android\sdk
    • Platform android-32, build-tools 32.0.0
    • Java binary at: C:\Program Files\Android\Android Studio1\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.11.3)
    • Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
    • Visual Studio Community 2019 version 16.11.31702.278
    • Windows 10 SDK version 10.0.19041.0

[√] Android Studio (version 2020.3)
    • Android Studio at C:\Program Files\Android\Android Studio1
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[√] VS Code (version 1.63.2)
    • VS Code at C:\Users\isaque\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.29.0

[√] Connected device (4 available)
    • Android SDK built for x86 (mobile) • emulator-5554 • android-x86    • Android 11 (API 30) (emulator)
    • Windows (desktop)                  • windows       • windows-x64    • Microsoft Windows [versÃ£o 10.0.22000.376]
    • Chrome (web)                       • chrome        • web-javascript • Google Chrome 96.0.4664.110
    • Edge (web)                         • edge          • web-javascript • Microsoft Edge 96.0.1054.43

• No issues found!
```