xref: /petsc/.gitlab-ci.yml (revision 0962a0d638d9cf58c80cfc49d5e100c1609adcd9)
1stages:
2  - test
3  - test-long
4variables:
5  GIT_STRATEGY: fetch
6  GIT_CLEAN_FLAGS: -ffdxq
7  PETSC_OPTIONS: -check_pointer_intensity 0 -error_output_stdout -nox -nox_warning -malloc_dump
8
9.test:
10  stage: test
11  image: jedbrown/mpich-ccache
12  only:
13    refs:
14      - merge_requests
15  before_script:
16    - echo nproc=$(nproc)
17    - cat /proc/cpuinfo
18    - ccache --zero-stats
19    - echo "${CI_JOB_NAME}"
20    - export CCACHE_COMPILERCHECK=content
21  script:
22    - ${PYTHON} ./configure --with-debugging=0 COPTFLAGS='-O -march=native' CXXOPTFLAGS='-O -march=native' FOPTFLAGS='-O -march=native' ${CONFIG_OPTS}
23    - make -j$(nproc) -l$(nproc) CFLAGS=-Werror
24    - make allgtests-tap search="${TEST_SEARCH}"
25  after_script:
26    - ccache --show-stats
27  artifacts:
28    reports:
29      junit: arch-*/tests/testresults.xml
30  cache:
31    paths:
32      - /ccache/
33    key: "${CI_JOB_NAME}"
34
35mpich-cxx-py3:
36  extends: .test
37  variables:
38    PYTHON: python3
39    CONFIG_OPTS: --with-mpi-dir=/usr/local --with-clanguage=cxx --with-fc=0
40    TEST_SEARCH: snes_tutorials-ex48%
41
42uni-complex-float-int64:
43  extends: .test
44  variables:
45    PYTHON: python3
46    CONFIG_OPTS: <
47      --with-mpi=0
48      --with-scalar-type=complex --with-precision=single --with-64-bit-indices
49    TEST_SEARCH: ts_tutorials-ex11_adv_2d_quad_%
50
51c89-mlib-static-py2:
52  extends: .test
53  image: jedbrown/mpich-ccache:python2
54  variables:
55    PYTHON: python2
56    CONFIG_OPTS: <
57      --with-mpi-dir=/usr/local
58      --with-single-library=0 --with-shared-libraries=0 'CFLAGS=-std=c89 -pedantic -Wno-long-long -Wno-overlength-strings'
59    TEST_SEARCH: snes_tutorials-ex48%
60
61
62.mcs_test:
63  stage: test-long
64  only:
65    refs:
66      - merge_requests
67    variables:
68      - $CI_MERGE_REQUEST_LABELS =~ /fulltest/
69  script:
70    - ./config/examples/${TEST_ARCH}.py
71    - make
72    - make check
73    - make cleantest allgtests-tap TIMEOUT=300
74  artifacts:
75    reports:
76      junit: ${TEST_ARCH}/tests/testresults.xml
77
78.linux_mcs_test:
79  extends: .mcs_test
80  tags:
81    - mcs-linux
82  before_script:
83    - hostname
84    - grep PRETTY_NAME /etc/os-release
85    - echo $(nproc)
86    - ccache --zero-stats
87  after_script:
88    - ccache --show-stats
89
90.freebsd_mcs_test:
91  extends: .mcs_test
92  tags:
93    - mcs-freebsd
94  before_script:
95    - hostname
96    - freebsd-version
97    - echo $(sysctl -n hw.ncpu)
98    - ccache --zero-stats
99  after_script:
100    - ccache --show-stats
101
102.osx_mcs_test:
103  extends: .mcs_test
104  tags:
105    - mcs-osx
106  variables:
107    PETSC_OPTIONS: -check_pointer_intensity 0 -error_output_stdout -nox -nox_warning -malloc_dump -saws_port_auto_select -saws_port_auto_select_silent -vecscatter_mpi1 false -options_left false
108  before_script:
109    - hostname
110    - sw_vers -productVersion
111    - echo $(sysctl -n hw.ncpu)
112    - ccache --zero-stats
113  after_script:
114    - ccache --show-stats
115
116.opensolaris_mcs_test:
117  extends: .mcs_test
118  tags:
119    - mcs-opensolaris
120  before_script:
121    - hostname
122    - uname -a
123    - echo $(nproc)
124
125linux-gcc-complex-opt:
126  extends: .linux_mcs_test
127  variables:
128    TEST_ARCH: arch-ci-linux-gcc-complex-opt
129
130linux-gcc-pkgs-opt:
131  extends: .linux_mcs_test
132  variables:
133    TEST_ARCH: arch-ci-linux-gcc-pkgs-opt
134
135linux-gcc-quad-64idx-dbg:
136  extends: .linux_mcs_test
137  variables:
138    TEST_ARCH: arch-ci-linux-gcc-quad-64idx-dbg
139
140freebsd-c-single-opt:
141  extends: .freebsd_mcs_test
142  variables:
143    TEST_ARCH: arch-ci-freebsd-c-single-opt
144
145freebsd-cxx-cmplx-64idx-dbg:
146  extends: .freebsd_mcs_test
147  variables:
148    TEST_ARCH: arch-ci-freebsd-cxx-cmplx-64idx-dbg
149
150osx-cxx-pkgs-opt:
151  extends: .osx_mcs_test
152  variables:
153    TEST_ARCH: arch-ci-osx-cxx-pkgs-opt
154
155opensolaris-cmplx-pkgs-dbg:
156  extends: .opensolaris_mcs_test
157  variables:
158    TEST_ARCH: arch-ci-opensolaris-cmplx-pkgs-dbg
159
160barry-checksource:
161  stage: test
162  tags:
163    - barry
164  script:
165    - hostname
166    - PETSC_ARCH=arch-basic PETSC_DIR=`pwd` ./configure --with-mpi=0 --with-fc=0
167    - make checkbadSource
168