-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Spmi replay pipeline #56871
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Spmi replay pipeline #56871
Changes from all commits
Commits
Show all changes
66 commits
Select commit
Hold shift + click to select a range
9c1284e
Add superpmi-replay pipeline file
kunalspathak 60b44b4
Add superpmi-replay-job.yml that downloads collection
kunalspathak 1919da8
Moved superpmi-replay-job to right location
kunalspathak f85e072
make sure to have spmi collection after jit build
kunalspathak 224adcd
annotate displayName with windows/OSX
kunalspathak 33072e3
Make osGroup=windows
kunalspathak 207ce41
Add helixType (if that matters)
kunalspathak 84e3dfe
Add some more variables
kunalspathak 2b232d0
skip restore internal tools
kunalspathak 971d198
Just use build-jit-job directly
kunalspathak bc571f9
Hardcode windows.x64.checked
kunalspathak f7f77ae
Add -download_all -download_raw options to superpmi.py
kunalspathak a7bdc5d
Seperate 2 jobs
kunalspathak fabab8a
Fix Upload artifacts
kunalspathak 9f8a0ba
Fix uploadAsArtifacts
kunalspathak 08650f6
Fix to uploadAsArtifacts
kunalspathak d14111f
comment upload to azure storage temporarily
kunalspathak a3916fe
Set variables inside superpmi-replay-job
kunalspathak fcd9855
Entire pipeline
kunalspathak dd12070
minor fix
kunalspathak b136c9d
Add some logging
kunalspathak 333927e
Fix the path
kunalspathak c8f75f5
fix file names and partition ids
kunalspathak 4ed4cc0
add sample download on helix machine
kunalspathak f0a9ae8
fix helix-correlation-payload
kunalspathak 4da534d
Download specific build
kunalspathak 9cb6da8
Try to fix correlation payload directory
kunalspathak 12287f6
Do not run windows x86 for now
kunalspathak c901a70
Log directory
kunalspathak 8dda3f1
walktree instead of dir
kunalspathak af25275
fix the bug
kunalspathak 2fc1495
Add workitem directory as Payload
kunalspathak 60c86e5
TEMP: Skip downloading collection during setup
kunalspathak 3ec4a84
fix core_root
kunalspathak 966a530
Make download happen on helix
kunalspathak 494e7ab
Add windows x86
kunalspathak e7ab499
Use -target_os and pass 1 item to helix
kunalspathak eea085f
Add some logging, have different work item ID
kunalspathak 283f211
fix the superpmi.log upload
kunalspathak f1e914b
Fix the log location
kunalspathak 92e3d55
one more fix to log_directory
kunalspathak 93edb83
try to fix download results
kunalspathak 20db184
Move the matrix to proj file
kunalspathak bcc6c36
fix superpmi-replay.proj
kunalspathak 8b50c09
Cleanup
kunalspathak e35562e
Go back to download specific
kunalspathak 7033211
WorkTimeout for 5 hours
kunalspathak 4edf41d
Remove timeoutInMinutes
kunalspathak 244693f
fix errors related to logging
kunalspathak 9794f4c
return failed run result
kunalspathak dc5ca48
fix the appending logic
kunalspathak b9ba241
Remove download-all and download-raw and instead add -no-progres
kunalspathak 4d97688
do not show download progress, try fixing download file
kunalspathak 53eb396
TO REVERT: Just try benchmark on windows x64/x86
kunalspathak 0c12c61
Use uploadAsArtifacts in build-jit-job
kunalspathak 4a48c37
Create dummy.txt in workitem directory
kunalspathak 1c14146
create workitem_directory
kunalspathak 8fbcace
Build clrjit
kunalspathak 5a3168d
fix build-jit-job
kunalspathak f796b6a
add dependsOn
kunalspathak deeb625
print params
kunalspathak faa8294
TO REVERT: Just run jitbuild win-x64
kunalspathak 7c73aa6
minor
kunalspathak b06725f
move under jobParameters
kunalspathak a729794
Cleanup
kunalspathak c8dc88a
review feedback
kunalspathak File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,29 @@ | ||
| parameters: | ||
| unpackFolder: '' | ||
| cleanUnpackFolder: true | ||
| artifactFileName: '' | ||
| artifactName: '' | ||
| displayName: '' | ||
|
|
||
| steps: | ||
| # Download artifact | ||
| - task: DownloadBuildArtifacts@0 | ||
| displayName: 'Download specific ${{ parameters.displayName }}' | ||
| inputs: | ||
| buildType: specific | ||
| project: 'internal' # 'internal' or 'public' | ||
| pipeline: 'superpmi-replay' | ||
| buildVersionToDownload: specific | ||
| branchName: 'your/branch/having/artifacts' | ||
| buildId: '1274841' | ||
| downloadType: single | ||
| downloadPath: '$(Build.SourcesDirectory)/__download__' | ||
| artifactName: '${{ parameters.artifactName }}' | ||
|
|
||
| # Unzip artifact | ||
| - task: ExtractFiles@1 | ||
| displayName: 'Unzip specific ${{ parameters.displayName }}' | ||
| inputs: | ||
| archiveFilePatterns: $(Build.SourcesDirectory)/__download__/${{ parameters.artifactName }}/${{ parameters.artifactFileName }} | ||
| destinationFolder: ${{ parameters.unpackFolder }} | ||
| cleanDestinationFolder: ${{ parameters.cleanUnpackFolder }} | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| trigger: | ||
| batch: false | ||
| branches: | ||
| include: | ||
| - main | ||
| paths: | ||
| include: | ||
| - src/coreclr/jit/* | ||
| - src/coreclr/inc/jiteeversionguid.h | ||
|
|
||
| # This pipeline is supposed to be run only on merged changes | ||
| # and should not be triggerable from a PR. | ||
| pr: none | ||
|
|
||
| jobs: | ||
|
|
||
| - template: /eng/pipelines/common/platform-matrix.yml | ||
| parameters: | ||
| jobTemplate: /eng/pipelines/coreclr/templates/build-jit-job.yml | ||
| buildConfig: checked | ||
| platforms: | ||
| - windows_x64 | ||
| - windows_x86 | ||
| jobParameters: | ||
| uploadAs: 'pipelineArtifacts' | ||
|
|
||
| - template: /eng/pipelines/common/platform-matrix.yml | ||
| parameters: | ||
| jobTemplate: /eng/pipelines/coreclr/templates/superpmi-replay-job.yml | ||
| buildConfig: checked | ||
| platforms: | ||
| - windows_x64 | ||
| - windows_x86 | ||
| helixQueueGroup: ci | ||
| helixQueuesTemplate: /eng/pipelines/coreclr/templates/helix-queues-setup.yml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
125 changes: 125 additions & 0 deletions
125
eng/pipelines/coreclr/templates/run-superpmi-replay-job.yml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,125 @@ | ||
| parameters: | ||
| steps: [] # optional -- any additional steps that need to happen before pulling down the jitutils repo and sending the jitutils to helix (ie building your repo) | ||
| variables: [] # optional -- list of additional variables to send to the template | ||
| jobName: '' # required -- job name | ||
| displayName: '' # optional -- display name for the job. Will use jobName if not passed | ||
| pool: '' # required -- name of the Build pool | ||
| container: '' # required -- name of the container | ||
| buildConfig: '' # required -- build configuration | ||
| archType: '' # required -- targeting CPU architecture | ||
| osGroup: '' # required -- operating system for the job | ||
| osSubgroup: '' # optional -- operating system subgroup | ||
| extraSetupParameters: '' # optional -- extra arguments to pass to the setup script | ||
| frameworks: ['netcoreapp3.0'] # optional -- list of frameworks to run against | ||
| continueOnError: 'false' # optional -- determines whether to continue the build if the step errors | ||
| dependsOn: '' # optional -- dependencies of the job | ||
| timeoutInMinutes: 320 # optional -- timeout for the job | ||
| enableTelemetry: false # optional -- enable for telemetry | ||
| liveLibrariesBuildConfig: '' # optional -- live-live libraries configuration to use for the run | ||
| runtimeType: 'coreclr' # optional -- Sets the runtime as coreclr or mono | ||
| codeGenType: 'JIT' # optional -- Decides on the codegen technology if running on mono | ||
| runKind: '' # required -- test category | ||
| collectionType: '' | ||
| collectionName: '' | ||
| dependOnEvaluatePaths: false | ||
|
|
||
| jobs: | ||
| - template: xplat-pipeline-job.yml | ||
| parameters: | ||
| dependsOn: ${{ parameters.dependsOn }} | ||
| buildConfig: ${{ parameters.buildConfig }} | ||
| archType: ${{ parameters.archType }} | ||
| osGroup: ${{ parameters.osGroup }} | ||
| osSubgroup: ${{ parameters.osSubgroup }} | ||
| liveLibrariesBuildConfig: ${{ parameters.liveLibrariesBuildConfig }} | ||
| enableTelemetry: ${{ parameters.enableTelemetry }} | ||
| enablePublishBuildArtifacts: true | ||
| continueOnError: ${{ parameters.continueOnError }} | ||
| collectionType: $ {{ parameters.collectionType }} | ||
| collectionName: ${{ parameters.collectionName }} | ||
| dependOnEvaluatePaths: ${{ parameters.dependOnEvaluatePaths }} | ||
| timeoutInMinutes: ${{ parameters.timeoutInMinutes }} | ||
|
|
||
| ${{ if ne(parameters.displayName, '') }}: | ||
| displayName: '${{ parameters.displayName }}' | ||
| ${{ if eq(parameters.displayName, '') }}: | ||
| displayName: '${{ parameters.jobName }}' | ||
|
|
||
| variables: | ||
| - ${{ each variable in parameters.variables }}: | ||
| - ${{ if ne(variable.name, '') }}: | ||
| - name: ${{ variable.name }} | ||
| value: ${{ variable.value }} | ||
| - ${{ if ne(variable.group, '') }}: | ||
| - group: ${{ variable.group }} | ||
|
|
||
| - name: PythonScript | ||
| value: 'py -3' | ||
| - name: PipScript | ||
| value: 'py -3 -m pip' | ||
| - name: SpmiCollectionLocation | ||
| value: '$(Build.SourcesDirectory)\artifacts\spmi\' | ||
| - name: SpmiLogsLocation | ||
| value: '$(Build.SourcesDirectory)\artifacts\spmi_logs\' | ||
| - name: HelixResultLocation | ||
| value: '$(Build.SourcesDirectory)\artifacts\helixresults\' | ||
|
|
||
| workspace: | ||
| clean: all | ||
| pool: | ||
| ${{ parameters.pool }} | ||
| container: ${{ parameters.container }} | ||
| strategy: | ||
| matrix: | ||
| ${{ each framework in parameters.frameworks }}: | ||
| ${{ framework }}: | ||
| _Framework: ${{ framework }} | ||
| steps: | ||
| - ${{ parameters.steps }} | ||
|
|
||
| - script: | | ||
| mkdir -p $(SpmiCollectionLocation) | ||
| displayName: Create directory for SPMI collection | ||
|
|
||
| - script: $(PythonScript) $(Build.SourcesDirectory)/src/coreclr/scripts/superpmi_replay_setup.py -source_directory $(Build.SourcesDirectory) -product_directory $(buildProductRootFolderPath) -arch $(archType) | ||
| displayName: ${{ format('SuperPMI replay setup ({0} {1})', parameters.osGroup, parameters.archType) }} | ||
|
|
||
| # Run superpmi replay in helix | ||
| - template: /eng/pipelines/coreclr/templates/superpmi-send-to-helix.yml | ||
| parameters: | ||
| HelixSource: '$(HelixSourcePrefix)/$(Build.Repository.Name)/$(Build.SourceBranch)' # sources must start with pr/, official/, prodcon/, or agent/ | ||
| HelixAccessToken: $(HelixApiAccessToken) | ||
| HelixTargetQueues: $(Queue) | ||
| HelixPreCommands: $(HelixPreCommand) | ||
| Creator: $(Creator) | ||
| WorkItemTimeout: 4:00 # 4 hours | ||
| WorkItemDirectory: '$(WorkItemDirectory)' | ||
| CorrelationPayloadDirectory: '$(CorrelationPayloadDirectory)' | ||
| ProjectFile: 'superpmi-replay.proj' | ||
| BuildConfig: ${{ parameters.buildConfig }} | ||
| osGroup: ${{ parameters.osGroup }} | ||
| archType: ${{ parameters.archType }} | ||
| continueOnError: true # Run the future step i.e. upload superpmi logs | ||
|
|
||
| # Always upload the available logs for diagnostics | ||
| - task: CopyFiles@2 | ||
| displayName: Copying superpmi.log of all partitions | ||
| inputs: | ||
| sourceFolder: '$(HelixResultLocation)' | ||
| contents: '**/superpmi_*.log' | ||
| targetFolder: '$(SpmiLogsLocation)' | ||
| condition: always() | ||
|
|
||
| - task: PublishPipelineArtifact@1 | ||
| displayName: Publish Superpmi logs | ||
| inputs: | ||
| targetPath: $(SpmiLogsLocation) | ||
| artifactName: 'SuperPMI_Logs_$(archType)_$(buildConfig)' | ||
| condition: always() | ||
|
|
||
| - task: PublishPipelineArtifact@1 | ||
| displayName: Publish SuperPMI build logs | ||
| inputs: | ||
| targetPath: $(Build.SourcesDirectory)/artifacts/log | ||
| artifactName: 'SuperPMI_BuildLogs__$(archType)_$(buildConfig)' | ||
| condition: always() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| parameters: | ||
| buildConfig: '' # required -- build configuration | ||
| archType: '' # required -- targeting CPU architecture | ||
| osGroup: '' # required -- operating system for the job | ||
| osSubgroup: '' # optional -- operating system subgroup | ||
| pool: '' | ||
| stagedBuild: false | ||
| timeoutInMinutes: 320 # build timeout | ||
| framework: net5.0 # Specify the appropriate framework when running release branches (ie netcoreapp3.0 for release/3.0) | ||
| variables: {} | ||
| dependOnEvaluatePaths: false | ||
| runJobTemplate: '/eng/pipelines/coreclr/templates/run-superpmi-replay-job.yml' | ||
|
|
||
| jobs: | ||
| - template: ${{ parameters.runJobTemplate }} | ||
| parameters: | ||
| jobName: ${{ format('superpmibuild_{0}{1}_{2}_{3}', parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.buildConfig) }} | ||
| displayName: ${{ format('SuperPMI replay {0} {1}', parameters.osGroup, parameters.archType) }} | ||
| pool: ${{ parameters.pool }} | ||
| buildConfig: ${{ parameters.buildConfig }} | ||
| archType: ${{ parameters.archType }} | ||
| osGroup: ${{ parameters.osGroup }} | ||
| osSubgroup: ${{ parameters.osSubgroup }} | ||
| dependOnEvaluatePaths: ${{ parameters.dependOnEvaluatePaths }} | ||
| timeoutInMinutes: ${{ parameters.timeoutInMinutes }} | ||
| additionalSetupParameters: ${{ parameters.additionalSetupParameters }} | ||
| dependsOn: | ||
| - ${{ format('coreclr_jit_build_{0}{1}_{2}_{3}', parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.buildConfig) }} | ||
|
|
||
| variables: ${{ parameters.variables }} | ||
|
|
||
| frameworks: | ||
| - ${{ parameters.framework }} | ||
|
|
||
| steps: | ||
|
|
||
| # Download jit builds | ||
| - template: /eng/pipelines/common/download-artifact-step.yml | ||
| parameters: | ||
| unpackFolder: $(buildProductRootFolderPath) | ||
| artifactFileName: '$(buildProductArtifactName)$(archiveExtension)' | ||
| artifactName: '$(buildProductArtifactName)' | ||
| displayName: 'JIT product build' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.