From 2f3601b7101656899b5e1a39f9d5b31faad51af3 Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Tue, 15 Oct 2024 11:35:46 -0700 Subject: [PATCH 1/6] Switch some mac_unopt tests from intel to arm hosts --- ci/builders/mac_unopt.json | 28 +++++++++------------------- 1 file changed, 9 insertions(+), 19 deletions(-) diff --git a/ci/builders/mac_unopt.json b/ci/builders/mac_unopt.json index 3a95e217f5670..e0e4f8cfe0d0b 100644 --- a/ci/builders/mac_unopt.json +++ b/ci/builders/mac_unopt.json @@ -5,8 +5,7 @@ "drone_dimensions": [ "device_type=none", "os=Mac-13|Mac-14", - "cpu=x86", - "mac_model=Macmini8,1" + "cpu=arm64" ], "gclient_variables": { "download_android_deps": false, @@ -28,7 +27,7 @@ ], "name": "ci/host_debug_tests", - "description": "Produces debug mode x64 macOS host-side tooling and builds host-side unit tests for x64 macOS.", + "description": "Produces debug mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", "ninja": { "config": "ci/host_debug_tests", "targets": [] @@ -58,8 +57,7 @@ "drone_dimensions": [ "device_type=none", "os=Mac-13|Mac-14", - "cpu=x86", - "mac_model=Macmini8,1" + "cpu=arm64" ], "gclient_variables": { "download_android_deps": false, @@ -78,7 +76,7 @@ "--xcode-symlinks" ], "name": "ci/host_profile_tests", - "description": "Produces profile mode x64 macOS host-side tooling and builds host-side unit tests for x64 macOS.", + "description": "Produces profile mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", "ninja": { "config": "ci/host_profile_tests", "targets": [] @@ -108,14 +106,7 @@ "drone_dimensions": [ "device_type=none", "os=Mac-13|Mac-14", - "cpu=x86", - "mac_model=Macmini8,1" - ], - "dependencies": [ - { - "dependency": "goldctl", - "version": "git_revision:720a542f6fe4f92922c3b8f0fdcc4d2ac6bb83cd" - } + "cpu=arm64" ], "gclient_variables": { "download_android_deps": false, @@ -135,7 +126,7 @@ "--xcode-symlinks" ], "name": "ci/host_release_tests", - "description": "Produces release mode x64 macOS host-side tooling and builds host-side unit tests for x64 macOS.", + "description": "Produces release mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", "ninja": { "config": "ci/host_release_tests", "targets": [] @@ -148,7 +139,7 @@ "tests": [ { "language": "python3", - "name": "Impeller-golden, dart and engine tests for host_release", + "name": "Dart and engine tests for host_release", "script": "flutter/testing/run_tests.py", "parameters": [ "--variant", @@ -221,8 +212,7 @@ "drone_dimensions": [ "device_type=none", "os=Mac-13|Mac-14", - "cpu=x86", - "mac_model=Macmini8,1" + "cpu=arm64" ], "gclient_variables": { "download_android_deps": false, @@ -242,7 +232,7 @@ "--xcode-symlinks" ], "name": "ci/host_debug_unopt", - "description": "Builds a debug mode unopt x64 macOS engine and runs host-side tests.", + "description": "Builds a debug mode unopt arm64 macOS engine and runs host-side tests.", "ninja": { "config": "ci/host_debug_unopt", "targets": [] From c3c3190cb574753075161a82586018f780012ca7 Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Tue, 15 Oct 2024 12:48:36 -0700 Subject: [PATCH 2/6] Add --quiet --- ci/builders/mac_unopt.json | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ci/builders/mac_unopt.json b/ci/builders/mac_unopt.json index e0e4f8cfe0d0b..2fcbb91ab6378 100644 --- a/ci/builders/mac_unopt.json +++ b/ci/builders/mac_unopt.json @@ -43,6 +43,7 @@ "name": "Host Tests for host_debug", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/host_debug_tests", "--type", @@ -92,6 +93,7 @@ "name": "Host Tests for host_profile", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/host_profile_tests", "--type", @@ -142,6 +144,7 @@ "name": "Dart and engine tests for host_release", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/host_release_tests", "--type", @@ -199,6 +202,7 @@ "name": "Impeller-golden for host_release", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/mac_release_arm64_tests", "--type", @@ -248,6 +252,7 @@ "name": "Host Tests for host_debug_unopt", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/host_debug_unopt", "--type", @@ -308,6 +313,7 @@ "name": "Tests for ios_debug_unopt_sim", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/ios_debug_unopt_sim", "--type", @@ -371,6 +377,7 @@ "name": "Host Tests for host_debug_unopt_arm64", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/host_debug_unopt_arm64", "--type", @@ -429,6 +436,7 @@ "name": "Tests for ios_debug_unopt_sim_arm64", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/ios_debug_unopt_sim_arm64", "--type", @@ -497,6 +505,7 @@ "name": "Tests for ios_debug_unopt_sim_arm64_extension_safe", "script": "flutter/testing/run_tests.py", "parameters": [ + "--quiet", "--variant", "ci/ios_debug_unopt_sim_arm64_extension_safe", "--type", From 612e8de1de7a48a794fd0c8199b1a4a5271aa871 Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Tue, 15 Oct 2024 13:50:34 -0700 Subject: [PATCH 3/6] Update mac_unopt.json --- ci/builders/mac_unopt.json | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/ci/builders/mac_unopt.json b/ci/builders/mac_unopt.json index 2fcbb91ab6378..46bf21cf4e400 100644 --- a/ci/builders/mac_unopt.json +++ b/ci/builders/mac_unopt.json @@ -17,6 +17,8 @@ "ci/host_debug_tests", "--runtime-mode", "debug", + "--mac-cpu", + "arm64", "--no-lto", "--prebuilt-dart-sdk", "--build-embedder-examples", @@ -24,7 +26,6 @@ "--rbe", "--no-goma", "--xcode-symlinks" - ], "name": "ci/host_debug_tests", "description": "Produces debug mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", @@ -69,6 +70,8 @@ "ci/host_profile_tests", "--runtime-mode", "profile", + "--mac-cpu", + "arm64", "--no-lto", "--prebuilt-dart-sdk", "--build-embedder-examples", @@ -119,6 +122,8 @@ "ci/host_release_tests", "--runtime-mode", "release", + "--mac-cpu", + "arm64", "--no-lto", "--prebuilt-dart-sdk", "--build-embedder-examples", @@ -227,6 +232,8 @@ "ci/host_debug_unopt", "--runtime-mode", "debug", + "--mac-cpu", + "arm64", "--unoptimized", "--no-lto", "--prebuilt-dart-sdk", From 56fc5267101a74a3e876a711394425b57557efa8 Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Tue, 15 Oct 2024 15:06:49 -0700 Subject: [PATCH 4/6] Update mac_unopt.json --- ci/builders/mac_unopt.json | 88 ++++++++------------------------------ 1 file changed, 18 insertions(+), 70 deletions(-) diff --git a/ci/builders/mac_unopt.json b/ci/builders/mac_unopt.json index 46bf21cf4e400..1f9a942362030 100644 --- a/ci/builders/mac_unopt.json +++ b/ci/builders/mac_unopt.json @@ -14,7 +14,7 @@ }, "gn": [ "--target-dir", - "ci/host_debug_tests", + "ci/host_debug_arm64_tests", "--runtime-mode", "debug", "--mac-cpu", @@ -27,10 +27,10 @@ "--no-goma", "--xcode-symlinks" ], - "name": "ci/host_debug_tests", + "name": "ci/host_debug_arm64_tests", "description": "Produces debug mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", "ninja": { - "config": "ci/host_debug_tests", + "config": "ci/host_debug_arm64_tests", "targets": [] }, "properties": { @@ -46,7 +46,7 @@ "parameters": [ "--quiet", "--variant", - "ci/host_debug_tests", + "ci/host_debug_arm64_tests", "--type", "dart,dart-host,engine", "--engine-capture-core-dump" @@ -67,7 +67,7 @@ }, "gn": [ "--target-dir", - "ci/host_profile_tests", + "ci/host_profile_arm64_tests", "--runtime-mode", "profile", "--mac-cpu", @@ -79,10 +79,10 @@ "--no-goma", "--xcode-symlinks" ], - "name": "ci/host_profile_tests", + "name": "ci/host_profile_arm64_tests", "description": "Produces profile mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", "ninja": { - "config": "ci/host_profile_tests", + "config": "ci/host_profile_arm64_tests", "targets": [] }, "properties": { @@ -98,7 +98,7 @@ "parameters": [ "--quiet", "--variant", - "ci/host_profile_tests", + "ci/host_profile_arm64_tests", "--type", "dart,dart-host,engine", "--engine-capture-core-dump" @@ -119,7 +119,7 @@ }, "gn": [ "--target-dir", - "ci/host_release_tests", + "ci/host_release_arm64_tests", "--runtime-mode", "release", "--mac-cpu", @@ -132,10 +132,10 @@ "--no-goma", "--xcode-symlinks" ], - "name": "ci/host_release_tests", + "name": "ci/host_release_arm64_tests", "description": "Produces release mode arm64 macOS host-side tooling and builds host-side unit tests for arm64 macOS.", "ninja": { - "config": "ci/host_release_tests", + "config": "ci/host_release_arm64_tests", "targets": [] }, "properties": { @@ -151,7 +151,7 @@ "parameters": [ "--quiet", "--variant", - "ci/host_release_tests", + "ci/host_release_arm64_tests", "--type", "dart,dart-host,engine" ] @@ -216,64 +216,6 @@ } ] }, - { - "cas_archive": false, - "drone_dimensions": [ - "device_type=none", - "os=Mac-13|Mac-14", - "cpu=arm64" - ], - "gclient_variables": { - "download_android_deps": false, - "use_rbe": true - }, - "gn": [ - "--target-dir", - "ci/host_debug_unopt", - "--runtime-mode", - "debug", - "--mac-cpu", - "arm64", - "--unoptimized", - "--no-lto", - "--prebuilt-dart-sdk", - "--enable-impeller-3d", - "--rbe", - "--no-goma", - "--xcode-symlinks" - ], - "name": "ci/host_debug_unopt", - "description": "Builds a debug mode unopt arm64 macOS engine and runs host-side tests.", - "ninja": { - "config": "ci/host_debug_unopt", - "targets": [] - }, - "properties": { - "$flutter/osx_sdk": { - "sdk_version": "15a240d" - } - }, - "tests": [ - { - "language": "python3", - "name": "Host Tests for host_debug_unopt", - "script": "flutter/testing/run_tests.py", - "parameters": [ - "--quiet", - "--variant", - "ci/host_debug_unopt", - "--type", - "dart,dart-host,engine", - "--engine-capture-core-dump" - ] - }, - { - "name": "Tests of tools/gn", - "language": "python3", - "script": "flutter/tools/gn_test.py" - } - ] - }, { "cas_archive": false, "properties": { @@ -361,6 +303,7 @@ "--prebuilt-dart-sdk", "--mac-cpu", "arm64", + "--enable-impeller-3d", "--rbe", "--no-goma", "--xcode-symlinks", @@ -392,6 +335,11 @@ "--engine-capture-core-dump", "--no-skia-gold" ] + }, + { + "name": "Tests of tools/gn", + "language": "python3", + "script": "flutter/tools/gn_test.py" } ] }, From 0184c1d019df1d59934898ada2ba8f593f00e530 Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Wed, 16 Oct 2024 12:26:00 -0700 Subject: [PATCH 5/6] Disable flutter_desktop_darwin_unittests on arm64 --- testing/run_tests.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/testing/run_tests.py b/testing/run_tests.py index 8ecbb673b3fe9..2d292fd260f95 100755 --- a/testing/run_tests.py +++ b/testing/run_tests.py @@ -505,7 +505,8 @@ def make_test(name, flags=None, extra_env=None): # flutter_desktop_darwin_unittests uses global state that isn't handled # correctly by gtest-parallel. # https://github.com/flutter/flutter/issues/104789 - if not os.path.basename(build_dir).startswith('host_debug'): + variant = os.path.basename(build_dir) + if not variant.startswith('host_debug') and 'arm64' not in variant: # Test is disabled for flaking in debug runs: # https://github.com/flutter/flutter/issues/127441 run_engine_executable( From 43d6d755d2c1ab0bb382f905b36701f2329500ae Mon Sep 17 00:00:00 2001 From: Zachary Anderson Date: Wed, 23 Oct 2024 11:08:08 -0700 Subject: [PATCH 6/6] Update run_tests.py --- testing/run_tests.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/testing/run_tests.py b/testing/run_tests.py index 2d292fd260f95..8ecbb673b3fe9 100755 --- a/testing/run_tests.py +++ b/testing/run_tests.py @@ -505,8 +505,7 @@ def make_test(name, flags=None, extra_env=None): # flutter_desktop_darwin_unittests uses global state that isn't handled # correctly by gtest-parallel. # https://github.com/flutter/flutter/issues/104789 - variant = os.path.basename(build_dir) - if not variant.startswith('host_debug') and 'arm64' not in variant: + if not os.path.basename(build_dir).startswith('host_debug'): # Test is disabled for flaking in debug runs: # https://github.com/flutter/flutter/issues/127441 run_engine_executable(