Skip to content

Commit 64dc5e1

Browse files
committed
Merge branch 'develop'
2 parents 6e93787 + c1e168f commit 64dc5e1

File tree

10 files changed

+139
-157
lines changed

10 files changed

+139
-157
lines changed

.travis.yml

Lines changed: 56 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,87 +1,83 @@
11
language: cpp
2-
dist: bionic
2+
dist: focal
33
os: linux
44
compiler: gcc
5-
apt:
6-
sources:
7-
- ubuntu-toolchain-r-test
8-
packages:
9-
- build-essential
10-
- valgrind
11-
- libpng-dev
12-
- libboost-serialization-dev
13-
- libstdc++6
14-
- hwloc
155

16-
install:
17-
# Install toolchain
18-
- export TOOLDIR=$HOME/tools
19-
- mkdir -p $TOOLDIR
20-
- DESTDIR=$TOOLDIR ./ci/toolchain_install.sh --all
21-
# Set environments
22-
- export RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv-gnu-toolchain
23-
- export LLVM_POCL=$TOOLDIR/llvm-pocl
24-
- export LLVM_VORTEX=$TOOLDIR/llvm-vortex
25-
- export VERILATOR_ROOT=$TOOLDIR/verilator
26-
- export PATH=$VERILATOR_ROOT/bin:$PATH
27-
- export SV2V_PATH=$TOOLDIR/sv2v
28-
- export PATH=$SV2V_PATH/bin:$PATH
29-
- export YOSYS_PATH=$TOOLDIR/yosys
30-
- export PATH=$YOSYS_PATH/bin:$PATH
31-
- export POCL_CC_PATH=$TOOLDIR/pocl/compiler
32-
- export POCL_RT_PATH=$TOOLDIR/pocl/runtime
33-
# build project
34-
- cp -r $PWD ../build32 && cd ../build32 && make clean-all && make
35-
- cp -r $PWD ../build64 && cd ../build64 && make clean-all && XLEN=64 RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv64-gnu-toolchain make
6+
addons:
7+
apt:
8+
packages:
9+
- build-essential
10+
- valgrind
11+
- libstdc++6
12+
13+
env:
14+
global:
15+
- TOOLDIR=$HOME/tools
16+
17+
cache:
18+
directories:
19+
- $TOOLDIR
20+
- $HOME/build32
21+
- $HOME/build64
22+
23+
before_install:
24+
- if [ ! -d "$TOOLDIR" ] || [ -z "$(ls -A $TOOLDIR)" ]; then
25+
mkdir -p $TOOLDIR;
26+
OSDIR=ubuntu/focal ./ci/toolchain_install.sh --all;
27+
fi
28+
- source ./ci/toolchain_env.sh
3629

37-
# stages ordering
3830
stages:
31+
- setup
3932
- test
4033

4134
jobs:
4235
include:
43-
- stage: test
36+
- stage: setup
37+
script:
38+
- rm -rf $HOME/build32 && cp -r $PWD $HOME/build32
39+
- rm -rf $HOME/build64 && cp -r $PWD $HOME/build64
40+
- make -C $HOME/build32
41+
- XLEN=64 RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv64-gnu-toolchain make -C $HOME/build64
42+
- stage: test
4443
name: unittest
45-
script: cp -r ../build32 ../build32_unittest && cd ../build32_unittest && ./ci/travis_run.py ./ci/regression.sh --unittest
46-
- stage: test
44+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --unittest
45+
- stage: test
4746
name: isa
48-
script: cp -r ../build32 ../build32_isa && cd ../build32_isa && ./ci/travis_run.py ./ci/regression.sh --isa
49-
- stage: test
47+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --isa
48+
- stage: test
5049
name: isa64
51-
script: cp -r ../build64 ../build64_isa && cd ../build64_isa && XLEN=64 RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv64-gnu-toolchain ./ci/travis_run.py ./ci/regression.sh --isa
52-
- stage: test
50+
script: cp -r $HOME/build64 build && cd build && XLEN=64 RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv64-gnu-toolchain ./ci/travis_run.py ./ci/regression.sh --isa
51+
- stage: test
5352
name: regression
54-
script: cp -r ../build32 ../build32_regression && cd ../build32_regression && ./ci/travis_run.py ./ci/regression.sh --regression
55-
- stage: test
53+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --regression
54+
- stage: test
5655
name: regression64
57-
script: cp -r ../build64 ../build64_regression && cd ../build64_regression && XLEN=64 RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv64-gnu-toolchain ./ci/travis_run.py ./ci/regression.sh --regression
58-
- stage: test
56+
script: cp -r $HOME/build64 build && cd build && XLEN=64 RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv64-gnu-toolchain ./ci/travis_run.py ./ci/regression.sh --regression
57+
- stage: test
5958
name: opencl
60-
script: cp -r ../build32 ../build32_opencl && cd ../build32_opencl && ./ci/travis_run.py ./ci/regression.sh --opencl
61-
- stage: test
59+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --opencl
60+
- stage: test
6261
name: cluster
63-
script: cp -r ../build32 ../build32_cluster && cd ../build32_cluster && ./ci/travis_run.py ./ci/regression.sh --cluster
64-
- stage: test
62+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --cluster
63+
- stage: test
6564
name: config
66-
script: cp -r ../build32 ../build32_config && cd ../build32_config && ./ci/travis_run.py ./ci/regression.sh --config
65+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --config
6766
- stage: test
6867
name: debug
69-
script: cp -r ../build32 ../build32_debug && cd ../build32_debug && ./ci/travis_run.py ./ci/regression.sh --debug
70-
- stage: test
68+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --debug
69+
- stage: test
7170
name: stress0
72-
script: cp -r ../build32 ../build32_stress0 && cd ../build32_stress0 && ./ci/travis_run.py ./ci/regression.sh --stress0
73-
- stage: test
71+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --stress0
72+
- stage: test
7473
name: stress1
75-
script: cp -r ../build32 ../build32_stress1 && cd ../build32_stress1 && ./ci/travis_run.py ./ci/regression.sh --stress1
76-
- stage: test
74+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --stress1
75+
- stage: test
7776
name: synthesis
78-
script: cp -r ../build32 ../build32_isa && cd ../build32_isa && ./ci/travis_run.py ./ci/regression.sh --synthesis
79-
- stage: test
77+
script: cp -r $HOME/build32 build && cd build && ./ci/travis_run.py ./ci/regression.sh --synthesis
78+
- stage: test
8079
name: synthesis64
81-
script: cp -r ../build64 ../build64_isa && cd ../build64_isa && XLEN=64 ./ci/travis_run.py ./ci/regression.sh --synthesis
82-
- stage: test
83-
name: compiler
84-
script: cp -r ../build32 ../build32_compiler && cd ../build32_compiler && ./ci/travis_run.py ./ci/test_compiler.sh
80+
script: cp -r $HOME/build64 build && cd build && XLEN=64 ./ci/travis_run.py ./ci/regression.sh --synthesis
8581

8682
after_success:
8783
# Gather code coverage

README.md

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -53,18 +53,11 @@ Vortex is a full-stack open-source RISC-V GPGPU.
5353
$ git clone --recursive https://github.com/vortexgpgpu/vortex.git
5454
$ cd Vortex
5555
### Install prebuilt toolchain
56-
$ ./ci/toolchain_install.sh --all
57-
5856
By default, the toolchain will install to /opt folder.
59-
You can install the toolchain to a different directory by overiding DESTDIR.
60-
61-
$ DESTDIR=$TOOLDIR ./ci/toolchain_install.sh --all
62-
$ export VORTEX_HOME=$TOOLDIR/vortex
63-
$ export LLVM_VORTEX=$TOOLDIR/llvm-vortex
64-
$ export LLVM_POCL=$TOOLDIR/llvm-pocl
65-
$ export RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv-gnu-toolchain
66-
$ export VERILATOR_ROOT=$TOOLDIR/verilator
67-
$ export PATH=$VERILATOR_ROOT/bin:$PATH
57+
You can install the toolchain to a different directory by overriding TOOLDIR (e.g. export TOOLDIR=$HOME/tools).
58+
59+
$ ./ci/toolchain_install.sh --all
60+
$ source ./ci/toolchain_env.sh
6861
### Build Vortex sources
6962
$ make -s
7063
### Quick demo running vecadd OpenCL kernel on 2 cores

ci/test_compiler.sh

Lines changed: 0 additions & 31 deletions
This file was deleted.

ci/toolchain_env.sh

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#!/bin/sh
2+
3+
# Copyright 2023 blaise
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
TOOLDIR=${TOOLDIR:=/opt}
18+
19+
export RISCV_TOOLCHAIN_PATH=$TOOLDIR/riscv-gnu-toolchain
20+
export LLVM_POCL=$TOOLDIR/llvm-pocl
21+
export LLVM_VORTEX=$TOOLDIR/llvm-vortex
22+
export VERILATOR_ROOT=$TOOLDIR/verilator
23+
export PATH=$VERILATOR_ROOT/bin:$PATH
24+
export SV2V_PATH=$TOOLDIR/sv2v
25+
export PATH=$SV2V_PATH/bin:$PATH
26+
export YOSYS_PATH=$TOOLDIR/yosys
27+
export PATH=$YOSYS_PATH/bin:$PATH
28+
export POCL_CC_PATH=$TOOLDIR/pocl/compiler
29+
export POCL_RT_PATH=$TOOLDIR/pocl/runtime

0 commit comments

Comments
 (0)