Repository: flutter
Issue: App crashes when drawing a number of custom painters
Labels: engine,c: performance,has reproducible steps,P2,c: fatal crash,found in release: 3.3,found in release: 3.6,team-engine,triaged-engine

```
F/libc    (28298): Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0 in tid 28379 (1.ui), pid 28298 (cn.plaso.yxt)
*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
Build fingerprint: 'HUAWEI/SCM-W09/HWSCM:10/HUAWEISCM-W09/10.1.0.165C00:user/release-keys'
Revision: '0'
ABI: 'arm64'
SYSVMTYPE: Maple
APPVMTYPE: Art
Timestamp: 2020-09-21 20:30:37+0800
pid: 28298, tid: 28379, name: 1.ui  >>> cn.plaso.yxt <<<
uid: 10183
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
Cause: null pointer dereference
    x0  0000007a7a25c3b8  x1  0000007b0b722c74  x2  000000007fffffff  x3  0000000000000000
    x4  0000000000000000  x5  0000000000000000  x6  0000000000000000  x7  000000001bb9c06c
    x8  0000007a15de5000  x9  0000000000000000  x10 0000000000000001  x11 0000000000000000
    x12 000001346ac93e0c  x13 0000000000000000  x14 000b12e7acea5f18  x15 0000187dd61feff3
    x16 0000007a15d079f8  x17 0000007b0b723970  x18 0000007a06c8c000  x19 0000007a06f0cc00
    x20 0000000000000000  x21 0000007a15ce96c0  x22 0000007a15ce96e0  x23 00000079d2f4c390
    x24 00000000000b3550  x25 0000007a07042000  x26 0000007a06f0cc00  x27 00000079f4c80040
    x28 0000000000000004  x29 0000007a0711ab38
    sp  0000007a0711a9b0  lr  0000007a15c6c710  pc  0000007a15c6c78c
backtrace:
      #00 pc 0000000000b2878c  /data/app/cn.plaso.yxt-8absxZCmpbVJH8j0c7jYhw==/lib/arm64/libflutter.so (BuildId: 07178ae56c5cc4613b959fc28553308f6701095c)
      #01 pc 000000000012d05c  [anon:libc_malloc]
Lost connection to device.
```

it seems more info from another app

also crashed in release mode ,but works well in debug;

I have test many android machine ,it always crash;



```
09-21 20:08:50.007 17347 19054 F libc    : Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0 in tid 19054 (1.ui), pid 17347 (ClientBetaPLASO)
09-21 20:08:50.263 19705 19705 F DEBUG   : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
09-21 20:08:50.264 19705 19705 F DEBUG   : Build fingerprint: 'HiDPT/Hi3751V811/Hi3751V811:9/PPR1.180610.011/384:eng/dev-keys'
09-21 20:08:50.264 19705 19705 F DEBUG   : Revision: '0'
09-21 20:08:50.264 19705 19705 F DEBUG   : ABI: 'arm'
09-21 20:08:50.264 19705 19705 F DEBUG   : Build Time: Mon Aug 31 10:23:25 CST 2020
09-21 20:08:50.264 19705 19705 F DEBUG   : Boot Time:
09-21 20:08:50.264 19705 19705 F DEBUG   :  3:51
09-21 20:08:50.264 19705 19705 F DEBUG   :
09-21 20:08:50.264 19705 19705 F DEBUG   :
09-21 20:08:50.264 19705 19705 F DEBUG   : Crash time at 2020-09-21 20:08:50 -----
09-21 20:08:50.264 19705 19705 F DEBUG   :
09-21 20:08:50.264 19705 19705 F DEBUG   : pid: 17347, tid: 19054, name: 1.ui  >>> com.plaso.studentClientBetaPLASO <<<
09-21 20:08:50.264 19705 19705 F DEBUG   : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
09-21 20:08:50.264 19705 19705 F DEBUG   : Cause: null pointer dereference
09-21 20:08:50.264 19705 19705 F DEBUG   :     r0  bb8b7acc  r1  00000000  r2  00000000  r3  80000000
09-21 20:08:50.264 19705 19705 F DEBUG   :     r4  bd075a00  r5  00000000  r6  bb7cd4a4  r7  bb7cd4b4
09-21 20:08:50.264 19705 19705 F DEBUG   :     r8  c29fea58  r9  c00df00c  r10 00000000  r11 c29fea9c
09-21 20:08:50.264 19705 19705 F DEBUG   :     ip  bb7da588  sp  c29fea20  lr  bb41255c  pc  bb79fca4
09-21 20:08:50.322 19705 19705 F DEBUG   :
09-21 20:08:50.322 19705 19705 F DEBUG   : backtrace:
09-21 20:08:50.322 19705 19705 F DEBUG   :     #00 pc 004ceca4  /data/app/com.plaso.studentClientBetaPLASO-U9LeVGNw6HQwDumygvDk7A==/lib/arm/libflutter.so (offset 0x133000)
09-21 20:08:50.322 19705 19705 F DEBUG   :     #01 pc 00167bad  /data/app/com.plaso.studentClientBetaPLASO-U9LeVGNw6HQwDumygvDk7A==/lib/arm/libflutter.so (offset 0x133000)
09-21 20:08:50.322 19705 19705 F DEBUG   :     #02 pc 000759fe  [anon:libc_malloc:bd000000]
```


result of flutter doctor -v 

```
[✓] Flutter (Channel stable, 1.20.3, on Mac OS X 10.15.6 19G2021, locale zh-Hans-CN)
    • Flutter version 1.20.3 at /opt/google/flutter
    • Framework revision 216dee60c0 (3 weeks ago), 2020-09-01 12:24:47 -0700
    • Engine revision d1bc06f032
    • Dart version 2.9.2
    • Pub download mirror https://pub.flutter-io.cn
    • Flutter download mirror https://storage.flutter-io.cn

[!] Android toolchain - develop for Android devices (Android SDK version 30.0.0)
    • Android SDK at /opt/google/android/sdk
    • Platform android-30, build-tools 30.0.0
    • ANDROID_HOME = /opt/google/android/sdk
    • ANDROID_SDK_ROOT = /opt/google/android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    ✗ Android license status unknown.
      Try re-installing or updating your Android SDK Manager.
      See https://developer.android.com/studio/#downloads or visit https://flutter.dev/docs/get-started/install/macos#android-setup for detailed instructions.


[✓] Xcode - develop for iOS and macOS (Xcode 12.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.0, Build version 12A7209
    • CocoaPods version 1.8.3

[✓] Android Studio (version 4.0)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 47.1.2
    • Dart plugin version 193.7547
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[!] IntelliJ IDEA Ultimate Edition (version 2018.1)
    • IntelliJ at /Applications/IntelliJ IDEA.app
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    ✗ Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

[✓] Connected device (1 available)
    • SCM W09 (mobile) • GYH9X20514X00279 • android-arm64 • Android 10 (API 29)

! Doctor found issues in 2 categories.
```