-
Notifications
You must be signed in to change notification settings - Fork 15
131 lines (103 loc) · 3.79 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
name: build
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
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: ubuntu-20.04
strategy:
fail-fast: false
matrix:
python-version: ["3.7.13"]
steps:
- uses: actions/checkout@v3
# Update references
- name: Git Sumbodule Update
run: |
git submodule update --init
- name: Install LLVM and Clang for CGRA-Mapper
uses: egor-tensin/setup-clang@v1
with:
version: 12
platform: x64
- name: Configure CMake for CGRA-Mapper
run: cd CGRA-Mapper && mkdir build && cd build && cmake ..
- name: Build for CGRA-Mapper
working-directory: ${{github.workspace}}/CGRA-Mapper/build
run: make
- name: Test for CGRA-Mapper
working-directory: ${{github.workspace}}/CGRA-Mapper/test
run: sudo ln -sf /usr/bin/opt-12 /usr/bin/opt && source compile.sh
- name: Set up Python ${{ matrix.python-version }} for VectorCGRA
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install Verilator for VectorCGRA
run: |
wget https://github.com/tancheng/pymtl-verilator/raw/master/verilator-travis-4.036.tar.gz
tar -C ${HOME} -xzf verilator-travis-4.036.tar.gz
echo "VERILATOR_ROOT=${HOME}/verilator" >> $GITHUB_ENV
echo "PYMTL_VERILATOR_INCLUDE_DIR=${HOME}/verilator/share/verilator/include" >> $GITHUB_ENV
echo "${HOME}/verilator/bin" >> $GITHUB_PATH
- name: Check Verilator for VectorCGRA
run: |
echo ${VERILATOR_ROOT}
echo ${PYMTL_VERILATOR_INCLUDE_DIR}
verilator --version
- name: Install dependencies for VectorCGRA
run: |
sudo apt-get install -y graphviz
sudo apt-get install git libffi-dev
python3 -m venv ${HOME}/venv
source ${HOME}/venv/bin/activate
pip install py==1.11.0
pip install wheel
pip install git+https://github.com/tancheng/pymtl3.git
pip install hypothesis
pip install pytest
pip list
- name: Test with pytest for VectorCGRA
run: |
cd VectorCGRA
mkdir -p build && cd build
source ${HOME}/venv/bin/activate
pytest ../cgra/ -v --tb=short
- name: Install dependencies for mflowgen
run: |
sudo apt-get install -y yosys
- name: Build for mflowgen
working-directory: ${{github.workspace}}/tools/mflowgen
run: |
pip install -e .
- name: Test for mflowgen
working-directory: ${{github.workspace}}/tools/mflowgen
run: |
mkdir build && cd build
mflowgen run --design ../designs/GcdUnit
make 3
- name: Build for cacti
working-directory: ${{github.workspace}}/tools/cacti
run: make
- name: Install dependencies for sv2v
run: stack upgrade
- name: Build for sv2v
working-directory: ${{github.workspace}}/tools/sv2v
run: make
- name: Install dependencies for tkinter
run: |
sudo apt-get install python3-tk
source ${HOME}/venv/bin/activate
pip install pillow
- name: Test for tkinter
working-directory: ${{github.workspace}}/
run: |
mkdir build && cd build
source ${HOME}/venv/bin/activate