Fix prefetch is considered as read; avoid going into allocate #21
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
build-llvm-9: | |
runs-on: ubuntu-20.04 | |
outputs: | |
cache-key: llvm-9.0.1-${{ runner.os }} | |
steps: | |
- name: Cache dependencies | |
id: cache | |
uses: actions/cache@v3 | |
with: | |
path: | | |
llvm-install | |
key: llvm-9.0.1-${{ runner.os }} | |
- name: Checkout LLVM | |
if: steps.cache.outputs.cache-hit != 'true' | |
uses: actions/checkout@v3 | |
with: | |
repository: llvm/llvm-project | |
ref: refs/tags/llvmorg-9.0.1 | |
submodules: false | |
fetch-depth: 1 # shallow | |
path: llvm-project | |
- name: Install dependencies | |
if: steps.cache.outputs.cache-hit != 'true' | |
run: sudo apt-get update && sudo apt-get install -y build-essential cmake ninja-build binutils-dev | |
- name: Build LLVM | |
if: steps.cache.outputs.cache-hit != 'true' | |
run: | | |
mkdir build | |
cd build | |
cmake -G Ninja ../llvm-project/llvm -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" -DCMAKE_BUILD_TYPE=Release \ | |
-DLLVM_TARGETS_TO_BUILD="X86" \ | |
-DLLVM_ENABLE_ASSERTIONS=ON \ | |
-DLLVM_ABI_BREAKING_CHECKS=FORCE_OFF \ | |
-DLLVM_BINUTILS_INCDIR=/usr/include \ | |
-DCMAKE_INSTALL_PREFIX=../llvm-install \ | |
-DCMAKE_CXX_STANDARD="17" | |
ninja | |
ninja install | |
build-noelle: | |
needs: build-llvm-9 | |
runs-on: ubuntu-20.04 | |
outputs: | |
cache-key: noelle-${{ runner.os }} | |
steps: | |
- name: Cache dependencies | |
id: cache | |
uses: actions/cache@v3 | |
with: | |
path: | | |
noelle-install | |
key: noelle-${{ runner.os }} | |
- name: Restore cache from LLVM | |
if: steps.cache.outputs.cache-hit != 'true' | |
id: cache-llvm | |
uses: actions/cache@v3 | |
with: | |
path: llvm-install | |
key: ${{ needs.build-llvm-9.outputs.cache-key }} | |
restore-keys: | | |
${{ needs.build-llvm-9.outputs.cache-key }} | |
- name: Checkout Noelle | |
if: steps.cache.outputs.cache-hit != 'true' | |
uses: actions/checkout@v3 | |
with: | |
repository: arcana-lab/noelle | |
path: noelle | |
- name: Build Noelle | |
if: steps.cache.outputs.cache-hit != 'true' | |
run: | | |
LLVM_INSTALL=$(realpath llvm-install) | |
mkdir -p noelle-install | |
NOELLE_INSTALL=$(realpath noelle-install) | |
PATH=${LLVM_INSTALL}/bin/:${PATH} \ | |
LLVM_CMAKE_DIR=${LLVM_INSTALL}/lib/cmake/llvm \ | |
PDG_INSTALL_DIR=${NOELLE_INSTALL} \ | |
make -C noelle all | |
build-prompt: | |
needs: [build-llvm-9] | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
path: PROMPT | |
- name: Restore cache from LLVM | |
id: cache-llvm | |
uses: actions/cache@v3 | |
with: | |
path: llvm-install | |
key: ${{ needs.build-llvm-9.outputs.cache-key }} | |
restore-keys: | | |
${{ needs.build-llvm-9.outputs.cache-key }} | |
- name: Install system dependences | |
run: | | |
sudo apt-get install -y build-essential libboost-all-dev libunwind-dev binutils-dev | |
- name: Set up Python 3.x | |
uses: actions/setup-python@v3 | |
with: | |
python-version: 3.x | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install argparse pyyaml | |
- name: Build | |
run: | | |
llvm_install=$(realpath llvm-install) | |
cd PROMPT | |
cd src/runtime/frontend | |
cd ../../.. | |
export PATH=${llvm_install}/bin:$PATH | |
export CC=clang | |
export CXX=clang++ | |
make build | |
make install | |
- name: Cache PROMPT/install directory | |
uses: actions/cache@v3 | |
with: | |
path: PROMPT/install | |
key: ${{ runner.os }}-prompt-install-${{ github.sha }} |