未验证 提交 77728dcc 编写于 作者: C Chris Sienkiewicz 提交者: GitHub

Merge pull request #40840 from dotnet/revert-40510-dev/chsienki/central-optprof

Revert "Consume centrally trained optprof data"
......@@ -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)
......
<!-- Copyright (c) Microsoft. All Rights Reserved. Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. -->
<Project>
<PropertyGroup>
<RestoreSources Condition="'$(UsingToolVisualStudioIbcTraining)' == 'true'">
$(RestoreSources);
https://devdiv.pkgs.visualstudio.com/_packaging/Engineering/nuget/v3/index.json;
https://api.nuget.org/v3/index.json;
</RestoreSources>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.DevDiv.Optimization.Data.PowerShell" Version="$(MicrosoftDevDivOptimizationDataPowerShellVersion)" ExcludeAssets="all" Condition="'$(UsingToolVisualStudioIbcTraining)' == 'true'"/>
</ItemGroup>
</Project>
\ No newline at end of file
......@@ -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"
$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
if (!$officialIbcSourceBranchName) {
return $fallback
}
return $branchData.vsBranch
if ($officialIbcSourceBranchName -ne "default") {
return $officialIbcSourceBranchName
}
return $global:_IbcSourceBranchName = calculate
}
function GetIbcDropName() {
if ($officialIbcDrop -and $officialIbcDrop -ne "default"){
return $officialIbcDrop
$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 IbcSourceBranchName build variable." -ForegroundColor Yellow
return $fallback
}
# 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 ""
if (Get-Member -InputObject $branchData -Name "ibcSourceBranch") {
return $branchData.ibcSourceBranch
}
# 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")
return $officialSourceBranchName
}
# 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": {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册