Skip to content
Permalink
Browse files

Revert "Consume centrally trained optprof data (#40510)"

This reverts commit 27ecd82.
  • Loading branch information
chsienki committed Jan 9, 2020
1 parent e4d2514 commit cfbd26d732c9e25cc664e438c7d2ff3082f2cbc8
Showing with 40 additions and 52 deletions.
  1. +4 −2 azure-pipelines-official.yml
  2. +0 −16 eng/InternalTools.props
  3. +0 −1 eng/Versions.props
  4. +26 −28 eng/build.ps1
  5. +10 −5 eng/config/PublishData.json
@@ -8,7 +8,8 @@ resources:
# SignType: real
# SkipTests: false
# SkipApplyOptimizationData: false
# IbcDrop: 'default'
# IbcSourceBranchName: 'default'
# IbcDropId: 'default'

# The variables `_DotNetArtifactsCategory` and `_DotNetValidationArtifactsCategory` are required for proper publishing of build artifacts. See https://github.com/dotnet/roslyn/pull/38259
variables:
@@ -75,7 +76,8 @@ stages:
-officialSkipTests $(SkipTests)
-officialSkipApplyOptimizationData $(SkipApplyOptimizationData)
-officialSourceBranchName $(SourceBranchName)
-officialIbcDrop $(IbcDrop)
-officialIbcSourceBranchName $(IbcSourceBranchName)
-officialIbcDropId $(IbcDropId)
-skipAnalyzers
/p:RepositoryName=$(Build.Repository.Name)
/p:VisualStudioDropAccessToken=$(System.AccessToken)

This file was deleted.

@@ -66,7 +66,6 @@
<MicrosoftCodeQualityAnalyzersVersion>$(RoslynDiagnosticsNugetPackageVersion)</MicrosoftCodeQualityAnalyzersVersion>
<SystemCompositionVersion>1.0.31</SystemCompositionVersion>
<MicrosoftCSharpVersion>4.3.0</MicrosoftCSharpVersion>
<MicrosoftDevDivOptimizationDataPowerShellVersion>1.0.210</MicrosoftDevDivOptimizationDataPowerShellVersion>
<MicrosoftDiagnosticsRuntimeVersion>0.8.31-beta</MicrosoftDiagnosticsRuntimeVersion>
<MicrosoftDiagnosticsTracingTraceEventVersion>1.0.35</MicrosoftDiagnosticsTracingTraceEventVersion>
<MicrosoftDiaSymReaderVersion>1.3.0</MicrosoftDiaSymReaderVersion>
@@ -49,7 +49,8 @@ param (
[string]$officialSkipApplyOptimizationData = "",
[string]$officialSkipTests = "",
[string]$officialSourceBranchName = "",
[string]$officialIbcDrop = "",
[string]$officialIbcSourceBranchName = "",
[string]$officialIbcDropId = "",

# Test actions
[switch]$test32,
@@ -107,8 +108,10 @@ function Print-Usage() {
Write-Host " -officialSkipTests <bool> Pass 'true' to not run tests"
Write-Host " -officialSkipApplyOptimizationData <bool> Pass 'true' to not apply optimization data"
Write-Host " -officialSourceBranchName <string> The source branch name"
Write-Host " -officialIbcDrop <string> IBC data drop to use (e.g. 'ProfilingOutputs/DevDiv/VS/..')."
Write-Host " -officialIbcDropId <string> IBC data drop to use (e.g. '20190210.1/935479/1')."
Write-Host " 'default' for the most recent available for the branch."
Write-Host " -officialIbcSourceBranchName <string> IBC source branch (e.g. 'master-vs-deps')"
Write-Host " 'default' to select branch based on eng/config/PublishData.json."
Write-Host ""
Write-Host "Command line arguments starting with '/p:' are passed through to MSBuild."
}
@@ -143,6 +146,8 @@ function Process-Arguments() {
OfficialBuildOnly "officialSkipTests"
OfficialBuildOnly "officialSkipApplyOptimizationData"
OfficialBuildOnly "officialSourceBranchName"
OfficialBuildOnly "officialIbcDropId"
OfficialBuildOnly "officialIbcSourceBranchName"

if ($officialBuildId) {
$script:useGlobalNuGetCache = $false
@@ -215,7 +220,8 @@ function BuildSolution() {

$testTargetFrameworks = if ($testCoreClr) { "netcoreapp3.0%3Bnetcoreapp2.1" } else { "" }

$ibcDropName = GetIbcDropName
$ibcSourceBranchName = GetIbcSourceBranchName
$ibcDropId = if ($officialIbcDropId -ne "default") { $officialIbcDropId } else { "" }

# Do not set this property to true explicitly, since that would override values set in projects.
$suppressExtensionDeployment = if (!$deployExtensions) { "/p:DeployExtension=false" } else { "" }
@@ -251,9 +257,10 @@ function BuildSolution() {
/p:BootstrapBuildPath=$bootstrapDir `
/p:TestTargetFrameworks=$testTargetFrameworks `
/p:TreatWarningsAsErrors=true `
/p:VisualStudioIbcSourceBranchName=$ibcSourceBranchName `
/p:VisualStudioIbcDropId=$ibcDropId `
/p:EnableNgenOptimization=$applyOptimizationData `
/p:IbcOptimizationDataDir=$ibcDir `
/p:VisualStudioIbcDrop=$ibcDropName `
$suppressExtensionDeployment `
$msbuildWarnAsError `
$buildFromSource `
@@ -273,40 +280,31 @@ function GetIbcSourceBranchName() {
}

function calculate {
$fallback = "master"
$fallback = "master-vs-deps"

if (!$officialIbcSourceBranchName) {
return $fallback
}

if ($officialIbcSourceBranchName -ne "default") {
return $officialIbcSourceBranchName
}

$branchData = GetBranchPublishData $officialSourceBranchName
if ($branchData -eq $null) {
Write-Host "Warning: Branch $officialSourceBranchName is not listed in PublishData.json. Using IBC data from '$fallback'." -ForegroundColor Yellow
Write-Host "Override by setting IbcDrop build variable." -ForegroundColor Yellow
Write-Host "Override by setting IbcSourceBranchName build variable." -ForegroundColor Yellow
return $fallback
}

return $branchData.vsBranch
}

return $global:_IbcSourceBranchName = calculate
}

function GetIbcDropName() {

if ($officialIbcDrop -and $officialIbcDrop -ne "default"){
return $officialIbcDrop
if (Get-Member -InputObject $branchData -Name "ibcSourceBranch") {
return $branchData.ibcSourceBranch
}

# Don't try and get the ibc drop if we're not in an official build as it won't be used anyway
if (!$officialBuildId) {
return ""
}
return $officialSourceBranchName
}

# Bring in the ibc tools
$packagePath = Join-Path (Get-PackageDir "Microsoft.DevDiv.Optimization.Data.PowerShell") "lib\net461"
Import-Module (Join-Path $packagePath "Optimization.Data.PowerShell.dll")

# Find the matching drop
$branch = GetIbcSourceBranchName
$drop = Find-OptimizationInputsStoreForBranch -ProjectName "DevDiv" -RepositoryName "VS" -BranchName $branch
return $drop.Name
return $global:_IbcSourceBranchName = calculate
}

# Set VSO variables used by MicroBuildBuildVSBootstrapper pipeline task
@@ -79,7 +79,8 @@
"vsix": [ "https://dotnet.myget.org/F/roslyn-nonnull/vsix/upload" ],
"channels": [ "nonnull" ],
"vsBranch": "lab/d16.1stg",
"vsMajorVersion": 16
"vsMajorVersion": 16,
"ibcSourceBranch": "master-vs-deps"
},
"features/dataflow": {
"nugetKind": "PerBuildPreRelease",
@@ -88,7 +89,8 @@
"vsix": [ "https://dotnet.myget.org/F/roslyn/vsix/upload" ],
"channels": [ "dataflow" ],
"vsBranch": "lab/d16.1stg",
"vsMajorVersion": 16
"vsMajorVersion": 16,
"ibcSourceBranch": "master-vs-deps"
},
"features/razorSupport2": {
"nugetKind": [ "Shipping", "NonShipping" ],
@@ -97,7 +99,8 @@
"vsix": [ "https://dotnet.myget.org/F/roslyn/vsix/upload" ],
"channels": [ "razorSupport2" ],
"vsBranch": "lab/d16.1stg",
"vsMajorVersion": 16
"vsMajorVersion": 16,
"ibcSourceBranch": "master-vs-deps"
},
"features/compilerNext": {
"nugetKind": [ "Shipping", "NonShipping" ],
@@ -106,7 +109,8 @@
"vsix": [ "https://dotnet.myget.org/F/roslyn/vsix/upload" ],
"channels": [ "compilerNext" ],
"vsBranch": "master",
"vsMajorVersion": 16
"vsMajorVersion": 16,
"ibcSourceBranch": "master-vs-deps"
},
"features/dotnetFormat": {
"nugetKind": [ "Shipping", "NonShipping" ],
@@ -115,7 +119,8 @@
"vsix": [ "https://dotnet.myget.org/F/roslyn/vsix/upload" ],
"channels": [ "dotnetFormat" ],
"vsBranch": "master",
"vsMajorVersion": 16
"vsMajorVersion": 16,
"ibcSourceBranch": "master-vs-deps"
}
},
"releases": {

0 comments on commit cfbd26d

Please sign in to comment.
You can’t perform that action at this time.