Repository: flutter
Issue: [google_maps_flutter][ios] Unusual micro-stuttering and flickering ('jank') when panning or zooming around in a `GoogleMap`
Labels: platform-ios,c: performance,a: quality,p: maps,package,has reproducible steps,P2,found in release: 2.10,found in release: 2.13,team-ios,triaged-ios

<!-- Thank you for using Flutter!

     If you are looking for support, please check out our documentation
     or consider asking a question on Stack Overflow:
      * https://flutter.dev/
      * https://api.flutter.dev/
      * https://stackoverflow.com/questions/tagged/flutter?sort=frequent

     If you have found a performance problem, then fill out the template below.
     Please read our guide to filing a bug first: https://flutter.dev/docs/resources/bug-reports
-->

## Details

<!--
1.  Please tell us exactly how to reproduce the problem you are running into.

2.  Please attach a small application (ideally just one main.dart file) that
     reproduces the problem. You could use https://gist.github.com/ for this.

3.  Switch flutter to master channel and run this app on a physical device
     using profile mode with Skia tracing enabled, as follows:
       flutter channel master
       flutter run --profile --trace-skia

     The bleeding edge master channel is encouraged here because Flutter is
     constantly fixing bugs and improving its performance. Your problem in an
     older Flutter version may have already been solved in the master channel.

4.  Record a video of the performance issue using another phone so we
     can have an intuitive understanding of what happened. Don’t use
     "adb screenrecord", as that affects the performance of the profile run.

5.  Open Observatory and save a timeline trace of the performance issue
     so we know which functions might be causing it. See "How to Collect
     and Read Timeline Traces" on this blog post:
       https://medium.com/flutter/profiling-flutter-applications-using-the-timeline-a1a434964af3#a499
     Make sure the performance overlay is turned OFF when recording the
     trace as that may affect the performance of the profile run.
     (Pressing ‘P’ on the command line toggles the overlay.)
-->

I am attempting to use the `google_maps_flutter` library in my project, however I'm noticing unusual and inconsistent microstuttering and flickering while moving around and particularly zooming in and out. Here is an attempt to capture some of that lag after running the app using `flutter run --profile --trace-skia`.

https://user-images.githubusercontent.com/10052313/166140440-36f23b97-be39-4f21-b4f9-f42db4238ff0.mp4

(Note: interestingly enough, it seems to perform slghtly better while I'm recording. Not sure what could cause that.)

Here is the code that I'm using to test this:

```dart
import 'package:flutter/material.dart';
import 'package:google_maps_flutter/google_maps_flutter.dart';

void main() async {
  runApp(const TestMap());
}

class TestMap extends StatelessWidget {
  const TestMap({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return const MaterialApp(
      home: Scaffold(
        body: GoogleMap(
          initialCameraPosition: CameraPosition(target: LatLng(0.0, 0.0)),
        ),
      ),
    );
  }
}
```

I've attempted to explore the performance using the Flutter DevTools and [statsfl](https://pub.dev/packages/statsfl), and they both seem to report no issues and a near-constant 60FPS, however the official Google Maps app does not have any similar jankyness, so I suspect I'm not reading the information correctly.

<!--
     Please tell us which target platform(s) the problem occurs (Android / iOS / Web / macOS / Linux / Windows)
     Which target OS version, for Web, browser, is the test system running?
     Does the problem occur on emulator/simulator as well as on physical devices?
-->

**Target Platform:** iOS
**Target OS version/browser:** 15.4.1
**Devices:** iPhone SE (2020)

## Logs

<details>
<summary>Logs</summary>

<!--
     Run `flutter analyze` and attach any output of that command below.
     If there are any analysis errors, try resolving them before filing this issue.
-->

```
% flutter analyze lib/map_test.dart
Analyzing map_test.dart...                                              
No issues found! (ran in 0.9s)
```

<!-- Finally, paste the output of running `flutter doctor -v` here, with your device plugged in. -->

`flutter doctor -v` output:

```
[✓] Flutter (Channel master, 2.13.0-0.0.pre.840, on macOS 12.3.1 21E258 darwin-arm, locale en-US)
    • Flutter version 2.13.0-0.0.pre.840 at /Users/me/Tools/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 43555d0504 (6 hours ago), 2022-04-30 23:34:05 -0400
    • Engine revision 9a1f497f1d
    • Dart version 2.18.0 (build 2.18.0-74.0.dev)
    • DevTools version 2.12.2

[!] Android toolchain - develop for Android devices (Android SDK version 33.0.0-rc2)
    • Android SDK at /Users/me/Library/Android/sdk
    • Platform android-31, build-tools 33.0.0-rc2
    ✗ Android SDK file not found: /Users/me/Library/Android/sdk/build-tools/33.0.0-rc2/aapt.
    • Try re-installing or updating your Android SDK,
      visit https://flutter.dev/docs/get-started/install/macos#android-setup for detailed instructions.

[✓] Xcode - develop for iOS and macOS (Xcode 13.3.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • CocoaPods version 1.11.3

[✗] Chrome - develop for the web (Cannot find Chrome executable at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome)
    ! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.

[✓] Android Studio (version 2021.1)
    • Android Studio at /Users/me/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/211.7628.21.2111.8309675/Android Studio.app/Contents
    • 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.11+0-b60-7772763)

[✓] Android Studio (version 2021.1)
    • Android Studio at /Users/me/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/211.7628.21.2111.8193401/Android Studio.app/Contents
    • 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.11+0-b60-7772763)

[✓] IntelliJ IDEA Community Edition (version 2021.1.3)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • 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

[✓] IntelliJ IDEA Community Edition (version 2021.3.3)
    • IntelliJ at /Users/me/Library/Application Support/JetBrains/Toolbox/apps/IDEA-C/ch-0/213.7172.25/IntelliJ IDEA CE.app
    • 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

[✓] IntelliJ IDEA Community Edition (version 2021.3.1)
    • IntelliJ at /Users/me/Library/Application Support/JetBrains/Toolbox/apps/IDEA-C/ch-0/213.6461.79/IntelliJ IDEA CE.app
    • 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

[✓] VS Code (version 1.66.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension can be installed from:
      🔨 https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[✓] Connected device (1 available)
    • iPhone SE (2nd generation) (mobile) • [redacted] • ios • iOS 15.4.1 19E258
    ! Error: iPad is not connected. Xcode will continue when iPad is connected. (code -13)

[✓] HTTP Host Availability
    • All required HTTP hosts are available
```

</details>