diff options
author | Roman Grundkiewicz <rgrundkiewicz@gmail.com> | 2020-08-21 20:50:07 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-21 20:50:07 +0300 |
commit | a21e48fb4f0beec0f83987112ff61b23a0140080 (patch) | |
tree | 6f4888d6e35e70e953853d327320ef4abe53a5d1 /.github/workflows/windows-cpu.yml | |
parent | c4c4b79f29fc78b2ef65b939677997896ce9624e (diff) |
Add GitHub workflows with CUDA and MKL (#700)
* Add GitHub workflows with CUDA
* Install MKL on Windows
* Upload CPU-only executables from Windows and Ubuntu as artifacts
* Clean up workflows
Diffstat (limited to '.github/workflows/windows-cpu.yml')
-rw-r--r-- | .github/workflows/windows-cpu.yml | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/.github/workflows/windows-cpu.yml b/.github/workflows/windows-cpu.yml new file mode 100644 index 00000000..b6543d0d --- /dev/null +++ b/.github/workflows/windows-cpu.yml @@ -0,0 +1,66 @@ +name: Windows CPU-only + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build-and-upload: + + runs-on: windows-2019 + + steps: + - name: Checkout + uses: actions/checkout@v2 + with: + submodules: recursive + + - name: Download MKL + run: | + Invoke-WebRequest -Uri https://romang.blob.core.windows.net/mariandev/ci/mkl-2020.1-windows-static.zip -TimeoutSec 600 -OutFile mkl.zip + Expand-Archive -Force mkl.zip ${{ github.workspace }}/mkl + # Set MKLROOT environment variables so that CMake can find MKL. + # GITHUB_WORKSPACE is an environment variable available on all GitHub-hosted runners + echo "::set-env name=MKLROOT::$env:GITHUB_WORKSPACE/mkl" + shell: powershell + + - name: Prepare vcpkg + uses: lukka/run-vcpkg@v2 + with: + vcpkgArguments: protobuf + vcpkgGitCommitId: 6185aa76504a5025f36754324abf307cc776f3da + vcpkgDirectory: ${{ github.workspace }}/vcpkg/ + vcpkgTriplet: x64-windows-static + + # Build with a simplified CMake settings JSON file + - name: Run CMake + uses: lukka/run-cmake@v2 + with: + buildDirectory: ${{ github.workspace }}/build/ + cmakeAppendedArgs: -G Ninja + cmakeListsOrSettingsJson: CMakeSettingsJson + # JSON file must be in the same directory as the main CMakeLists.txt + cmakeSettingsJsonPath: ${{ github.workspace }}/_CMakeSettingsCI_CPU.json + useVcpkgToolchainFile: true + + - name: Run unit tests + working-directory: build/Release/ + run: ctest + + #- name: Print versions + #working-directory: build/Release/ + #run: | + #.\marian.exe --version + #.\marian-decoder.exe --version + #.\marian-scorer.exe --version + #.\spm_encode.exe --version + #shell: powershell + + # Marian is built with FBGEMM, so there are some restrictions on what CPUs the executables can be run + - name: Upload archive + uses: actions/upload-artifact@v2 + with: + name: marian-windows-release-static + path: build/Release/marian*.exe |