Skip to content
This repository has been archived by the owner on Apr 18, 2024. It is now read-only.

Commit

Permalink
Create directx_build.yml (#2)
Browse files Browse the repository at this point in the history
* Create directx_build.yml
* Create track_tvm_github.yml
* Update README.md
  • Loading branch information
wenxcs authored Mar 4, 2022
1 parent f904e94 commit 84122bd
Show file tree
Hide file tree
Showing 3 changed files with 92 additions and 2 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/directx_build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Build TVM with DirectX support

on:
push:
branches: [ develop ]
pull_request:
branches: [ develop ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
VCPKG_EXE_PATH: F:\tool\vcpkg\vcpkg.exe
VCPKG_CMAKE_PATH: "F:/tool/vcpkg/scripts/buildsystems/vcpkg.cmake"
VSDEVCMD: C:/\"Program Files\"/\"Microsoft Visual Studio\"/2022/Enterprise/Common7/Tools/VsDevCmd.bat

jobs:
build:
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
# You can convert this to a matrix build if you need cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: [self-hosted, Windows, X64]

steps:
- uses: actions/checkout@v2
with:
submodules: 'true'

- name: VCPKG install Gtest
shell: cmd
run: ${{env.VCPKG_EXE_PATH}} install gtest:x64-windows

- name: Configure CMake
shell: cmd
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: >-
${{env.VSDEVCMD}} &&
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DUSE_DIRECTX=ON -DCMAKE_TOOLCHAIN_FILE=${{env.VCPKG_CMAKE_PATH}}
- name: Build
shell: cmd
# Build your program with the given configuration
run: >-
${{env.VSDEVCMD}} &&
cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
- name: Test
shell: cmd
# Build your program with the given configuration
run: >-
${{env.VSDEVCMD}} &&
${{github.workspace}}/build/${{env.BUILD_TYPE}}/dx_test.exe
37 changes: 37 additions & 0 deletions .github/workflows/track_tvm_github.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Track latest TVM commit from Github

on:
push:
branches: [ develop ]
pull_request:
branches: [ develop ]
schedule:
- cron: '36 6 * * *'

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: git-mirror-action
# You may pin to the exact commit or the version.
# uses: mathisve/git-mirror-action@0e26d87bd1420836e3b68767929c997565c7028f
uses: mathisve/git-mirror-action@v1.2
with:
# url of the repository you want to mirror
originalURL: https://github.com/apache/tvm.git
# branch in the original repository you want to mirror. Defaults to `master`
originalBranch: main
# url of the repository you want the mirror to go in
mirrorURL: https://github.com/nnfusion/tvm.git
# branch that will be created or pushed into. Defaults to `mirror`
mirrorBranch: main
# Base64 encoded Personal Access Token
pat: ${{ secrets.NNFUSION_PAT }}
# whether to use the `--force` argument when pushing to the mirror repository. Defaults to false
force: false
# whether or not you want the output to be verbose. Defaults to false
verbose: false
# whether or not you want to transfer tags. Defaults to false
tags: false

5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@
[Community](https://tvm.apache.org/community) |
[Release Notes](NEWS.md)

[![Build Status](https://ci.tlcpack.ai/buildStatus/icon?job=tvm/main)](https://ci.tlcpack.ai/job/tvm/job/main/)
[![WinMacBuild](https://github.com/apache/tvm/workflows/WinMacBuild/badge.svg)](https://github.com/apache/tvm/actions?query=workflow%3AWinMacBuild)
[![Build TVM with DirectX support](https://github.com/nnfusion/tvm/actions/workflows/directx_build.yml/badge.svg)](https://github.com/nnfusion/tvm/actions/workflows/directx_build.yml)
[![Track latest TVM commit from Github](https://github.com/nnfusion/tvm/actions/workflows/track_tvm_github.yml/badge.svg)](https://github.com/nnfusion/tvm/actions/workflows/track_tvm_github.yml)
[![WinMacBuild](https://github.com/nnfusion/tvm/actions/workflows/main.yml/badge.svg?branch=main)](https://github.com/nnfusion/tvm/actions/workflows/main.yml)

Apache TVM is a compiler stack for deep learning systems. It is designed to close the gap between the
productivity-focused deep learning frameworks, and the performance- and efficiency-focused hardware backends.
Expand Down

0 comments on commit 84122bd

Please sign in to comment.