Skip to content

Add support for dynamic memrefs in create_nd_tdesc lowering #1

Add support for dynamic memrefs in create_nd_tdesc lowering

Add support for dynamic memrefs in create_nd_tdesc lowering #1

Workflow file for this run

name: CPU Build
on:
pull_request:
branches:
- main
- upstream
- 'dist-ndarray'
workflow_dispatch:
workflow_call:
jobs:
build:
if: github.repository == 'intel-innersource/frameworks.ai.mlir.mlir-extensions'
runs-on: [self-hosted, pvc, glados]
timeout-minutes: 450
env:
BUILD_ROOT: /home/gta/actions-runner/_work/frameworks.ai.mlir.mlir-extensions/frameworks.ai.mlir.mlir-extensions/build_cpu
HOME_DIR: /home/gta/actions-runner/_work/frameworks.ai.mlir.mlir-extensions/frameworks.ai.mlir.mlir-extensions/build_cpu/home
HOME: /github/home
LLVM_SHA_FILE: llvm_version.txt
steps:
- name: Check build root
run: |
export BUILD_ROOT=$(pwd)/build_cpu
echo BUILD_ROOT=${BUILD_ROOT} >> $GITHUB_ENV
export HOME_DIR=${BUILD_ROOT}/home
echo HOME_DIR=${HOME_DIR} >> $GITHUB_ENV
if [ ! -d "$BUILD_ROOT" ]; then mkdir -p $BUILD_ROOT; fi
- name: Clear home dir
run: |
mkdir -p $HOME_DIR
cd $HOME_DIR
rm -rf *
- uses: actions/checkout@v3
with:
repository: intel-innersource/frameworks.ai.mlir.mlir-extensions
token: ${{secrets.WORKFLOW_TOKEN}}
fetch-depth: 0
path: ${{env.HOME_DIR}}/frameworks.ai.mlir.mlir-extensions
- name: Checkout MLIR
run: |
cd $BUILD_ROOT
if [ ! -d "llvm-project" ]; then git clone https://github.com/llvm/llvm-project; fi
cd $BUILD_ROOT/llvm-project
git reset --hard HEAD
export LLVM_SHA=`cat $HOME_DIR/frameworks.ai.mlir.mlir-extensions/build_tools/llvm_version.txt`
git fetch --prune
git checkout $LLVM_SHA || exit 1
if [ -d "$HOME_DIR/frameworks.ai.mlir.mlir-extensions/build_tools/patches" ]; then git apply $HOME_DIR/frameworks.ai.mlir.mlir-extensions/build_tools/patches/*.patch; fi
- name: Setup IMEX and run tests
run: |
cd $HOME_DIR/frameworks.ai.mlir.mlir-extensions || exit 1
cmake -S $BUILD_ROOT/llvm-project/llvm -B build -GNinja -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_PROJECTS=mlir -DLLVM_ENABLE_ASSERTIONS=ON -DLLVM_USE_LINKER=gold -DLLVM_ENABLE_ZSTD=OFF -DLLVM_EXTERNAL_PROJECTS="Imex" -DLLVM_EXTERNAL_IMEX_SOURCE_DIR=. || exit 1
set -o pipefail
cmake --build build --target check-imex | tee build/tests.txt
- name: Upload tests.txt
if: ${{ always() }}
uses: actions/upload-artifact@v3
with:
name: tests_cpu.txt
path: ${{env.HOME_DIR}}/frameworks.ai.mlir.mlir-extensions/build/tests.txt