Skip to content

Introducing PR verification x86 CI build #1309

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 10 commits into from
Oct 26, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion .vsts-dotnet-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,15 @@ phases:

- template: /build/ci/phase-template.yml
parameters:
name: Windows_NT
name: Windows_x64
buildScript: build.cmd
queue:
name: Hosted VS2017

- template: /build/ci/phase-template.yml
parameters:
name: Windows_x86
architecture: x86
buildScript: build.cmd
queue:
name: Hosted VS2017
Expand Down
4 changes: 3 additions & 1 deletion build/ci/phase-template.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
parameters:
name: ''
architecture: x64
buildScript: ''
queue: {}

Expand All @@ -8,6 +9,7 @@ phases:
variables:
_buildScript: ${{ parameters.buildScript }}
_phaseName: ${{ parameters.name }}
_arch: ${{ parameters.architecture }}
queue:
parallel: 99
matrix:
Expand All @@ -17,7 +19,7 @@ phases:
_configuration: Release
${{ insert }}: ${{ parameters.queue }}
steps:
- script: $(_buildScript) -$(_configuration)
- script: $(_buildScript) -$(_configuration) -buildArch=$(_arch)
displayName: Build
- ${{ if eq(parameters.name, 'MacOS') }}:
- script: brew install libomp
Expand Down
11 changes: 10 additions & 1 deletion init-tools.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ set BUILD_TOOLS_PATH=%PACKAGES_DIR%\Microsoft.DotNet.BuildTools\%BUILDTOOLS_VERS
set INIT_TOOLS_RESTORE_PROJECT=%~dp0init-tools.msbuild
set BUILD_TOOLS_SEMAPHORE_DIR=%TOOLRUNTIME_DIR%\%BUILDTOOLS_VERSION%
set BUILD_TOOLS_SEMAPHORE=%BUILD_TOOLS_SEMAPHORE_DIR%\init-tools.completed
set ARCH=x64

:: if force option is specified then clean the tool runtime and build tools package directory to force it to get recreated
if [%1]==[force] (
Expand Down Expand Up @@ -47,9 +48,17 @@ echo Running %0 > "%INIT_TOOLS_LOG%"
set /p DOTNET_VERSION=< "%~dp0DotnetCLIVersion.txt"
if exist "%DOTNET_CMD%" goto :afterdotnetrestore

:Arg_Loop
if [%1] == [] goto :ArchSet
if /i [%1] == [x86] ( set ARCH=x86&&goto ArchSet)
shift
goto :Arg_Loop

:ArchSet

echo Installing dotnet cli...
if NOT exist "%DOTNET_PATH%" mkdir "%DOTNET_PATH%"
set DOTNET_ZIP_NAME=dotnet-sdk-%DOTNET_VERSION%-win-x64.zip
set DOTNET_ZIP_NAME=dotnet-sdk-%DOTNET_VERSION%-win-%ARCH%.zip
set DOTNET_REMOTE_PATH=https://dotnetcli.azureedge.net/dotnet/Sdk/%DOTNET_VERSION%/%DOTNET_ZIP_NAME%
set DOTNET_LOCAL_PATH=%DOTNET_PATH%%DOTNET_ZIP_NAME%
echo Installing '%DOTNET_REMOTE_PATH%' to '%DOTNET_LOCAL_PATH%' >> "%INIT_TOOLS_LOG%"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@
<ItemGroup>
<Content Include="..\common\CommonPackage.props" Pack="true" PackagePath="build\netstandard2.0\$(MSBuildProjectName).props" />
<Content Include="$(PackageAssetsPath)$(PackageIdFolderName)\LICENSE.txt" Pack="true" PackagePath=".\" />
<Content Include="$(PackageAssetsPath)$(PackageIdFolderName)\THIRD_PARTY_NOTICES.txt" Pack="true" PackagePath=".\" />
<Content Condition="Exists('$(PackageAssetsPath)$(PackageIdFolderName)\THIRD_PARTY_NOTICES.txt')" Include="$(PackageAssetsPath)$(PackageIdFolderName)\THIRD_PARTY_NOTICES.txt" Pack="true" PackagePath=".\" />
</ItemGroup>
</Project>
2 changes: 1 addition & 1 deletion run.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ set DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
set DOTNET_MULTILEVEL_LOOKUP=0

:: Restore the Tools directory
call "%~dp0init-tools.cmd"
call "%~dp0init-tools.cmd" %*
if NOT [%ERRORLEVEL%]==[0] exit /b 1

set _toolRuntime=%~dp0Tools
Expand Down
4 changes: 4 additions & 0 deletions test/Microsoft.ML.Benchmarks.Tests/BenchmarksTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ public class BenchmarksTest

private ITestOutputHelper Output { get; }

#if DEBUG
[Fact(Skip = SkipTheDebug)]
#else
[ConditionalFact(typeof(Environment), nameof(Environment.Is64BitProcess))]
#endif
public void BenchmarksProjectIsNotBroken()
{
var summary = BenchmarkRunner.Run<BenchmarkTouchingNativeDependency>(new TestConfig().With(new OutputLogger(Output)));
Expand Down
2 changes: 2 additions & 0 deletions test/Microsoft.ML.TestFramework/BaseTestBaseline.cs
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ protected void DoNotEverUseInvertPass()
private static readonly Regex _matchTime = new Regex(@"[0-9]{2}:[0-9]{2}:[0-9]{2}(\.[0-9]+)?", RegexOptions.Compiled);
private static readonly Regex _matchShortTime = new Regex(@"\([0-9]{2}:[0-9]{2}(\.[0-9]+)?\)", RegexOptions.Compiled);
private static readonly Regex _matchMemory = new Regex(@"memory usage\(MB\): [0-9]+", RegexOptions.Compiled);
private static readonly Regex _matchReservedMemory = new Regex(@": [0-9]+ bytes", RegexOptions.Compiled);
private static readonly Regex _matchElapsed = new Regex(@"Time elapsed\(s\): [0-9.]+", RegexOptions.Compiled);
private static readonly Regex _matchTimes = new Regex(@"Instances caching time\(s\): [0-9\.]+", RegexOptions.Compiled);
private static readonly Regex _matchUpdatesPerSec = new Regex(@", ([0-9\.]+|Infinity)M WeightUpdates/sec", RegexOptions.Compiled);
Expand Down Expand Up @@ -281,6 +282,7 @@ protected void Normalize(string path)
line = _matchShortTime.Replace(line, "(%Time%)");
line = _matchElapsed.Replace(line, "Time elapsed(s): %Number%");
line = _matchMemory.Replace(line, "memory usage(MB): %Number%");
line = _matchReservedMemory.Replace(line, ": %Number% bytes");
line = _matchTimes.Replace(line, "Instances caching time(s): %Number%");
line = _matchUpdatesPerSec.Replace(line, ", %Number%M WeightUpdates/sec");
line = _matchParameterT.Replace(line, "=PARAM:/t:%Number%");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ public void TensorFlowTransformCifarSavedModel()
}
}

[Fact]
[ConditionalFact(typeof(Environment), nameof(Environment.Is64BitProcess))]
public void TensorFlowTransformCifarInvalidShape()
{
var model_location = "cifar_model/frozen_model.pb";
Expand Down
2 changes: 1 addition & 1 deletion test/Microsoft.ML.Tests/TensorFlowEstimatorTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ public void TestTensorFlowStatic()
}
}

[Fact]
[ConditionalFact(typeof(Environment), nameof(Environment.Is64BitProcess))]
public void TestTensorFlowStaticWithSchema()
{
var modelLocation = "cifar_model/frozen_model.pb";
Expand Down