Skip to content

Commit

Permalink
Add perf pipeline (dotnet/coreclr#26188)
Browse files Browse the repository at this point in the history
* Add performance testing pipeline

* Specify netcoreapp5.0 framework

* Add windows x86

* Address feedback

* Remove stale comment

* Remove unnecessary parameters


Commit migrated from dotnet/coreclr@a337302
  • Loading branch information
michellemcdaniel authored Aug 16, 2019
1 parent 978129c commit 57c81b3
Show file tree
Hide file tree
Showing 2 changed files with 98 additions and 0 deletions.
73 changes: 73 additions & 0 deletions eng/perf-job.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
parameters:
buildConfig: ''
archType: ''
osGroup: ''
osIdentifier: ''
container: ''
framework: netcoreapp5.0 # Specify the appropriate framework when running release branches (ie netcoreapp3.0 for release/3.0)

### Perf job

### Each perf job depends on a corresponding build job with the same
### buildConfig and archType.

jobs:
- template: /eng/common/templates/job/performance.yml
parameters:
# Compute job name from template parameters
jobName: ${{ format('perfbuild_{0}_{1}_{2}', parameters.osIdentifier, parameters.archType, parameters.buildConfig) }}
displayName: ${{ format('Performance {0} {1} {2}', parameters.osIdentifier, parameters.archType, parameters.buildConfig) }}
pool:
# Public Linux Build Pool
${{ if and(eq(parameters.osGroup, 'Linux'), eq(variables['System.TeamProject'], 'public')) }}:
name: NetCorePublic-Pool
queue: BuildPool.Ubuntu.1604.Amd64.Open
# Public Windows Build Pool
${{ if and(eq(parameters.osGroup, 'Windows_NT'), eq(variables['System.TeamProject'], 'public')) }}:
name: NetCorePublic-Pool
queue: BuildPool.Windows.10.Amd64.VS2017.Open

# Test job depends on the corresponding build job
dependsOn: ${{ format('build_{0}_{1}_{2}', parameters.osIdentifier, parameters.archType, parameters.buildConfig) }}

# Run all steps in the container.
${{ if ne(parameters.container, '') }}:
${{ if eq(parameters.container.registry, 'mcr') }}:
container: ${{ format('{0}:{1}', 'mcr.microsoft.com/dotnet-buildtools/prereqs', parameters.container.image) }}
${{ if ne(parameters.container.registry, 'mcr') }}:
container: ${{ format('{0}:{1}', parameters.container.registry, parameters.container.image) }}

${{ if eq(parameters.osGroup, 'Windows_NT') }}:
extraSetupParameters: -CoreRootDirectory $(Build.SourcesDirectory)\bin\tests\${{ parameters.osGroup }}.${{ parameters.archType }}.Release\Tests\Core_Root -Architecture ${{ parameters.archType }} -Framework ${{ parameters.framework }}
${{ if ne(parameters.osGroup, 'Windows_NT') }}:
extraSetupParameters: --corerootdirectory $(Build.SourcesDirectory)/bin/tests/${{ parameters.osGroup }}.${{ parameters.archType }}.Release/Tests/Core_Root --architecture ${{ parameters.archType }} -Framework ${{ parameters.framework }}

steps:
# Extra steps that will be passed to the performance template and run before sending the job to helix (all of which is done in the template)

# Download product binaries directory
- task: DownloadBuildArtifacts@0
displayName: Download product build
inputs:
buildType: current
downloadType: single
artifactName: ${{ format('BinDir_{0}_{1}_{2}', parameters.osIdentifier, parameters.archType, parameters.buildConfig) }}
downloadPath: $(System.ArtifactsDirectory)


# Populate Product directory
- task: CopyFiles@2
displayName: Populate Product directory
inputs:
sourceFolder: $(System.ArtifactsDirectory)/${{ format('BinDir_{0}_{1}_{2}', parameters.osIdentifier, parameters.archType, parameters.buildConfig) }}
contents: '**'
targetFolder: $(Build.SourcesDirectory)/bin/Product/${{ parameters.osGroup }}.${{ parameters.archType }}.Release

# Create Core_Root
- ${{ if ne(parameters.osGroup, 'Windows_NT') }}:
- script: ./build-test.sh ${{ parameters.buildConfig }} ${{ parameters.archType }} generatelayoutonly
displayName: Create Core_Root
- ${{ if eq(parameters.osGroup, 'Windows_NT') }}:
# TODO: add generatelayoutonly to build-test.cmd.
- script: build-test.cmd ${{ parameters.buildConfig }} ${{ parameters.archType }} skipmanaged skipnative
displayName: Create Core_Root
25 changes: 25 additions & 0 deletions eng/pipelines/coreclr/perf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
trigger:
batch: true
branches:
include:
- master

pr: none

- template: /eng/platform-matrix.yml
parameters:
jobTemplate: build-job.yml
buildConfig: release
platforms:
- Linux_x64
- Windows_NT_x64
- Windows_NT_x86

- template: /eng/platform-matrix.yml
parameters:
jobTemplate: perf-job.yml
buildConfig: release
platforms:
- Linux_x64
- Windows_NT_x64
- Windows_NT_x86

0 comments on commit 57c81b3

Please sign in to comment.