Skip to content

Commit

Permalink
Update Maui/Mobile pre.py's and disable android due to AOT Issue (dot…
Browse files Browse the repository at this point in the history
…net#65231)

* Setup testing jobs, change repo to test perf repo, and added apk-name parameter to pre.py for mobile scenarios.

* Update dotnet install type to be daily. This matches the link for installing net 6.0 in the maui contributing dev requirements list.

* Try lowercase package name.

* List post build folder stuff.

* Add android output format as apk.

* Disable package replacement to see if that is the issue location.

* Revert "Disable package replacement to see if that is the issue location."

This reverts commit 31cffe7.

* Always try to publish the binlog files.

* Comment out the props file to see if that fixes the AOT error.

* Readd props references.

* Try building without AOT.

* Disable Maui Android Scenarios so that at least iOS on main are being build and measured for SOD.

* Forgot to remove the uploading of the Android APP.

* Disable download attempt of the MauiAndroidApp.

* Reenable full perf run.

* Set the setup branch back to main.

* Undisable MauiScenario.targets file. It semi-causes the AOT issue but should still be enabled for other working builds.

* Add reason for the commented out sections.
  • Loading branch information
LoopedBard3 authored Feb 12, 2022
1 parent f3b925d commit a1f0147
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 43 deletions.
49 changes: 28 additions & 21 deletions eng/pipelines/coreclr/templates/build-perf-maui-apps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ steps:
- script: |
curl -o dotnet-install.sh 'https://dotnet.microsoft.com/download/dotnet/scripts/v1/dotnet-install.sh'
chmod -R a+rx .
./dotnet-install.sh --channel 6.0.2xx --quality signed --install-dir .
./dotnet-install.sh --channel 6.0.2xx --quality daily --install-dir .
./dotnet --info
./dotnet workload install maui --from-rollback-file https://aka.ms/dotnet/maui/main.json --source https://aka.ms/dotnet6/nuget/index.json --source https://api.nuget.org/v3/index.json
displayName: Install MAUI workload
Expand All @@ -126,12 +126,14 @@ steps:
displayName: Setup MAUI Project
workingDirectory: $(Build.SourcesDirectory)
- script: |
chmod -R a+r .
../dotnet publish -bl:MauiAndroid.binlog -f net6.0-android -c Release
mv ./bin/Release/net6.0-android/com.companyname.MauiTesting-Signed.apk ./MauiAndroidDefault.apk
displayName: Build MAUI Android
workingDirectory: $(Build.SourcesDirectory)/MauiTesting
#### Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main
#- script: |
# chmod -R a+r .
# ../dotnet publish -bl:MauiAndroid.binlog -f net6.0-android -c Release -p:RunAOTCompilation=false -p:AndroidEnableProfiledAot=false
# ls -l -R
# mv ./bin/Release/net6.0-android/com.companyname.mauitesting-Signed.apk ./MauiAndroidDefault.apk
# displayName: Build MAUI Android
# workingDirectory: $(Build.SourcesDirectory)/MauiTesting

- script: |
chmod -R a+r .
Expand All @@ -147,33 +149,38 @@ steps:
displayName: Build MAUI MacCatalyst
workingDirectory: $(Build.SourcesDirectory)/MauiTesting
- task: PublishBuildArtifacts@1
displayName: 'Publish MauiAndroid binlog'
inputs:
pathtoPublish: $(Build.SourcesDirectory)/MauiTesting/MauiAndroid.binlog
artifactName: ${{ parameters.artifactName }}
#### Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main
#- task: PublishBuildArtifacts@1
# displayName: 'Publish MauiAndroid binlog'
# condition: always()
# inputs:
# pathtoPublish: $(Build.SourcesDirectory)/MauiTesting/MauiAndroid.binlog
# artifactName: ${{ parameters.artifactName }}

- task: PublishBuildArtifacts@1
displayName: 'Publish MauiiOS binlog'
condition: always()
inputs:
pathtoPublish: $(Build.SourcesDirectory)/MauiTesting/MauiiOS.binlog
artifactName: ${{ parameters.artifactName }}

- task: PublishBuildArtifacts@1
displayName: 'Publish MauiMacCatalyst binlog'
condition: always()
inputs:
pathtoPublish: $(Build.SourcesDirectory)/MauiTesting/MauiMacCatalyst.binlog
artifactName: ${{ parameters.artifactName }}

- template: /eng/pipelines/common/upload-artifact-step.yml
parameters:
rootFolder: $(Build.SourcesDirectory)/MauiTesting/MauiAndroidDefault.apk
includeRootFolder: true
displayName: Maui Android App
artifactName: MauiAndroidApp
archiveExtension: '.tar.gz'
archiveType: tar
tarCompression: gz
#### Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main
#- template: /eng/pipelines/common/upload-artifact-step.yml
# parameters:
# rootFolder: $(Build.SourcesDirectory)/MauiTesting/MauiAndroidDefault.apk
# includeRootFolder: true
# displayName: Maui Android App
# artifactName: MauiAndroidApp
# archiveExtension: '.tar.gz'
# archiveType: tar
# tarCompression: gz

- template: /eng/pipelines/common/upload-artifact-step.yml
parameters:
Expand Down
15 changes: 8 additions & 7 deletions eng/pipelines/coreclr/templates/perf-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,13 +159,14 @@ jobs:
artifactFileName: 'AndroidMonoarm64.tar.gz'
artifactName: 'AndroidMonoarm64'
displayName: 'Mono Android HelloWorld'
- template: /eng/pipelines/common/download-artifact-step.yml
parameters:
unpackFolder: $(Build.SourcesDirectory)
cleanUnpackFolder: false
artifactFileName: 'MauiAndroidApp.tar.gz'
artifactName: 'MauiAndroidApp'
displayName: 'Maui Android App'
#### Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main
#- template: /eng/pipelines/common/download-artifact-step.yml
# parameters:
# unpackFolder: $(Build.SourcesDirectory)
# cleanUnpackFolder: false
# artifactFileName: 'MauiAndroidApp.tar.gz'
# artifactName: 'MauiAndroidApp'
# displayName: 'Maui Android App'

# Download iOSMono tests and MauiiOS/MacCatalyst
- ${{ if eq(parameters.runtimeType, 'iOSMono') }}:
Expand Down
28 changes: 15 additions & 13 deletions eng/testing/performance/android_scenarios.proj
Original file line number Diff line number Diff line change
Expand Up @@ -25,39 +25,41 @@
<ItemGroup>
<HelixWorkItem Include="SOD - Android HelloWorld APK Size">
<PayloadDirectory>$(WorkItemDirectory)</PayloadDirectory>
<PreCommands>cd $(ScenarioDirectory)helloandroid;copy %HELIX_CORRELATION_PAYLOAD%\HelloAndroid.apk .;$(Python) pre.py</PreCommands>
<PreCommands>cd $(ScenarioDirectory)helloandroid;copy %HELIX_CORRELATION_PAYLOAD%\HelloAndroid.apk .;$(Python) pre.py --apk-name HelloAndroid.apk</PreCommands>
<Command>$(Python) test.py sod --scenario-name &quot;%(Identity)&quot;</Command>
<PostCommands>$(Python) post.py</PostCommands>
</HelixWorkItem>
<HelixWorkItem Include="SOD - Android HelloWorld Extracted Size">
<PayloadDirectory>$(WorkItemDirectory)</PayloadDirectory>
<PreCommands>cd $(ScenarioDirectory)helloandroid;copy %HELIX_CORRELATION_PAYLOAD%\HelloAndroid.apk .;$(Python) pre.py --unzip</PreCommands>
<PreCommands>cd $(ScenarioDirectory)helloandroid;copy %HELIX_CORRELATION_PAYLOAD%\HelloAndroid.apk .;$(Python) pre.py --unzip --apk-name HelloAndroid.apk</PreCommands>
<Command>$(Python) test.py sod --scenario-name &quot;%(Identity)&quot;</Command>
<PostCommands>$(Python) post.py</PostCommands>
</HelixWorkItem>
<HelixWorkItem Include="SOD - Maui Android APK Size">
<!--Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main-->
<!--<HelixWorkItem Include="SOD - Maui Android APK Size">
<PayloadDirectory>$(WorkItemDirectory)</PayloadDirectory>
<PreCommands>cd $(ScenarioDirectory)mauiandroid;copy %HELIX_CORRELATION_PAYLOAD%\MauiAndroidDefault.apk .; $(Python) pre.py</PreCommands>
<Command>$(Python) test.py sod --scenario-name &quot;%(Identity)&quot;</Command>
<PreCommands>cd $(ScenarioDirectory)mauiandroid;copy %HELIX_CORRELATION_PAYLOAD%\MauiAndroidDefault.apk .; $(Python) pre.py -1-apk-name MauiAndroidDefault.apk</PreCommands>
<Command>$(Python) test.py sod -1-scenario-name &quot;%(Identity)&quot;</Command>
<PostCommands>$(Python) post.py</PostCommands>
</HelixWorkItem>
<HelixWorkItem Include="SOD - Maui Android Extracted Size">
<PayloadDirectory>$(WorkItemDirectory)</PayloadDirectory>
<PreCommands>cd $(ScenarioDirectory)mauiandroid;copy %HELIX_CORRELATION_PAYLOAD%\MauiAndroidDefault.apk .; $(Python) pre.py --unzip</PreCommands>
<Command>$(Python) test.py sod --scenario-name &quot;%(Identity)&quot;</Command>
<PreCommands>cd $(ScenarioDirectory)mauiandroid;copy %HELIX_CORRELATION_PAYLOAD%\MauiAndroidDefault.apk .; $(Python) pre.py -1-unzip -1-apk-name MauiAndroidDefault.apk</PreCommands>
<Command>$(Python) test.py sod -1-scenario-name &quot;%(Identity)&quot;</Command>
<PostCommands>$(Python) post.py</PostCommands>
</HelixWorkItem>
</HelixWorkItem>-->
<HelixWorkItem Include="Startup - Android HelloWorld">
<PayloadDirectory>$(WorkItemDirectory)</PayloadDirectory>
<PreCommands>echo on;set XHARNESSPATH=$(XharnessPath);cd $(ScenarioDirectory)helloandroid;copy %HELIX_CORRELATION_PAYLOAD%\HelloAndroid.apk .;$(Python) pre.py</PreCommands>
<PreCommands>echo on;set XHARNESSPATH=$(XharnessPath);cd $(ScenarioDirectory)helloandroid;copy %HELIX_CORRELATION_PAYLOAD%\HelloAndroid.apk .;$(Python) pre.py --apk-name HelloAndroid.apk</PreCommands>
<Command>$(Python) test.py devicestartup --device-type android --package-path pub\HelloAndroid.apk --package-name net.dot.HelloAndroid --scenario-name &quot;%(Identity)&quot;</Command>
<PostCommands>$(Python) post.py</PostCommands>
</HelixWorkItem>
<HelixWorkItem Include="Startup - Android Maui">
<!--Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main-->
<!--<HelixWorkItem Include="Startup - Android Maui">
<PayloadDirectory>$(WorkItemDirectory)</PayloadDirectory>
<PreCommands>echo on;set XHARNESSPATH=$(XharnessPath);cd $(ScenarioDirectory)mauiandroid;copy %HELIX_CORRELATION_PAYLOAD%\MauiAndroidDefault.apk .;$(Python) pre.py</PreCommands>
<Command>$(Python) test.py devicestartup --device-type android --package-path pub\MauiAndroidDefault.apk --package-name com.companyname.mauitesting --scenario-name &quot;%(Identity)&quot;</Command>
<PreCommands>echo on;set XHARNESSPATH=$(XharnessPath);cd $(ScenarioDirectory)mauiandroid;copy %HELIX_CORRELATION_PAYLOAD%\MauiAndroidDefault.apk .;$(Python) pre.py -1-apk-name MauiAndroidDefault.apk</PreCommands>
<Command>$(Python) test.py devicestartup -1-device-type android -1-package-path pub\MauiAndroidDefault.apk -1-package-name com.companyname.mauitesting -1-scenario-name &quot;%(Identity)&quot;</Command>
<PostCommands>$(Python) post.py</PostCommands>
</HelixWorkItem>
</HelixWorkItem>-->
</ItemGroup>
</Project>
5 changes: 3 additions & 2 deletions eng/testing/performance/performance-setup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,9 @@ if ($AndroidMono) {
mkdir $WorkItemDirectory
}

Copy-Item -path "$SourceDirectory\androidHelloWorld\HelloAndroid.apk" $PayloadDirectory -Verbose
Copy-Item -path "$SourceDirectory\MauiAndroidDefault.apk" $PayloadDirectory -Verbose
Copy-Item -path "$SourceDirectory\androidHelloWorld\HelloAndroid.apk" $PayloadDirectory -Verbose
#### Commented out to mitigate https://github.com/dotnet/performance/issues/2254 on main
#Copy-Item -path "$SourceDirectory\MauiAndroidDefault.apk" $PayloadDirectory -Verbose
$SetupArguments = $SetupArguments -replace $Architecture, 'arm64'
}

Expand Down

0 comments on commit a1f0147

Please sign in to comment.