Use separate artifacts for arm64 and x64 versions of gen_snapshot on Apple platforms (#164419)
Fixes https://github.com/flutter/flutter/issues/156175
This commit is contained in:
@@ -81,12 +81,12 @@ void main() {
|
||||
|
||||
testWithoutContext('iOS arm64', () async {
|
||||
final String genSnapshotPath = artifacts.getArtifactPath(
|
||||
Artifact.genSnapshot,
|
||||
Artifact.genSnapshotArm64,
|
||||
platform: TargetPlatform.ios,
|
||||
mode: BuildMode.release,
|
||||
);
|
||||
processManager.addCommand(
|
||||
FakeCommand(command: <String>['${genSnapshotPath}_arm64', '--additional_arg']),
|
||||
FakeCommand(command: <String>[genSnapshotPath, '--additional_arg']),
|
||||
);
|
||||
|
||||
final int result = await genSnapshot.run(
|
||||
@@ -197,14 +197,14 @@ void main() {
|
||||
final String assembly = fileSystem.path.join(outputPath, 'snapshot_assembly.S');
|
||||
final String debugPath = fileSystem.path.join('foo', 'app.ios-arm64.symbols');
|
||||
final String genSnapshotPath = artifacts.getArtifactPath(
|
||||
Artifact.genSnapshot,
|
||||
Artifact.genSnapshotArm64,
|
||||
platform: TargetPlatform.ios,
|
||||
mode: BuildMode.profile,
|
||||
);
|
||||
processManager.addCommands(<FakeCommand>[
|
||||
FakeCommand(
|
||||
command: <String>[
|
||||
'${genSnapshotPath}_arm64',
|
||||
genSnapshotPath,
|
||||
'--deterministic',
|
||||
'--snapshot_kind=app-aot-assembly',
|
||||
'--assembly=$assembly',
|
||||
@@ -272,14 +272,14 @@ void main() {
|
||||
final String outputPath = fileSystem.path.join('build', 'foo');
|
||||
final String assembly = fileSystem.path.join(outputPath, 'snapshot_assembly.S');
|
||||
final String genSnapshotPath = artifacts.getArtifactPath(
|
||||
Artifact.genSnapshot,
|
||||
Artifact.genSnapshotArm64,
|
||||
platform: TargetPlatform.ios,
|
||||
mode: BuildMode.profile,
|
||||
);
|
||||
processManager.addCommands(<FakeCommand>[
|
||||
FakeCommand(
|
||||
command: <String>[
|
||||
'${genSnapshotPath}_arm64',
|
||||
genSnapshotPath,
|
||||
'--deterministic',
|
||||
'--snapshot_kind=app-aot-assembly',
|
||||
'--assembly=$assembly',
|
||||
@@ -343,14 +343,14 @@ void main() {
|
||||
testWithoutContext('builds iOS snapshot', () async {
|
||||
final String outputPath = fileSystem.path.join('build', 'foo');
|
||||
final String genSnapshotPath = artifacts.getArtifactPath(
|
||||
Artifact.genSnapshot,
|
||||
Artifact.genSnapshotArm64,
|
||||
platform: TargetPlatform.ios,
|
||||
mode: BuildMode.release,
|
||||
);
|
||||
processManager.addCommands(<FakeCommand>[
|
||||
FakeCommand(
|
||||
command: <String>[
|
||||
'${genSnapshotPath}_arm64',
|
||||
genSnapshotPath,
|
||||
'--deterministic',
|
||||
'--snapshot_kind=app-aot-assembly',
|
||||
'--assembly=${fileSystem.path.join(outputPath, 'snapshot_assembly.S')}',
|
||||
|
||||
@@ -794,7 +794,7 @@ void main() {
|
||||
FakeCommand(
|
||||
command: <String>[
|
||||
// This path is not known by the cache due to the iOS gen_snapshot split.
|
||||
'Artifact.genSnapshot.TargetPlatform.ios.profile_arm64',
|
||||
'Artifact.genSnapshotArm64.TargetPlatform.ios.profile',
|
||||
'--deterministic',
|
||||
'--write-v8-snapshot-profile-to=code_size_1/snapshot.arm64.json',
|
||||
'--trace-precompiler-to=code_size_1/trace.arm64.json',
|
||||
|
||||
@@ -813,7 +813,7 @@ void main() {
|
||||
processManager.addCommands(<FakeCommand>[
|
||||
FakeCommand(
|
||||
command: <String>[
|
||||
'Artifact.genSnapshot.TargetPlatform.darwin.release_arm64',
|
||||
'Artifact.genSnapshotArm64.TargetPlatform.darwin.release',
|
||||
'--deterministic',
|
||||
'--snapshot_kind=app-aot-assembly',
|
||||
'--assembly=${environment.buildDir.childFile('arm64/snapshot_assembly.S').path}',
|
||||
@@ -822,7 +822,7 @@ void main() {
|
||||
),
|
||||
FakeCommand(
|
||||
command: <String>[
|
||||
'Artifact.genSnapshot.TargetPlatform.darwin.release_x64',
|
||||
'Artifact.genSnapshotX64.TargetPlatform.darwin.release',
|
||||
'--deterministic',
|
||||
'--snapshot_kind=app-aot-assembly',
|
||||
'--assembly=${environment.buildDir.childFile('x86_64/snapshot_assembly.S').path}',
|
||||
|
||||
Reference in New Issue
Block a user