|
1 | 1 | language: cpp |
2 | | -dist: bionic |
| 2 | +dist: focal |
3 | 3 | os: linux |
4 | 4 | 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 |
15 | 5 |
|
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 |
36 | 29 |
|
37 | | -# stages ordering |
38 | 30 | stages: |
| 31 | + - setup |
39 | 32 | - test |
40 | 33 |
|
41 | 34 | jobs: |
42 | 35 | 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 |
44 | 43 | 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 |
47 | 46 | 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 |
50 | 49 | 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 |
53 | 52 | 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 |
56 | 55 | 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 |
59 | 58 | 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 |
62 | 61 | 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 |
65 | 64 | 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 |
67 | 66 | - stage: test |
68 | 67 | 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 |
71 | 70 | 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 |
74 | 73 | 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 |
77 | 76 | 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 |
80 | 79 | 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 |
85 | 81 |
|
86 | 82 | after_success: |
87 | 83 | # Gather code coverage |
|
0 commit comments