-
Notifications
You must be signed in to change notification settings - Fork 0
179 lines (178 loc) · 8.44 KB
/
gamma_f77.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
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
##############################################################################
# Copyright Christopher Kormanyos 2023 - 2024.
# Distributed under the Boost Software License,
# Version 1.0. (See accompanying file LICENSE_1_0.txt
# or copy at http://www.boost.org/LICENSE_1_0.txt)
name: gamma_f77
on:
push:
branches:
- '**'
pull_request:
jobs:
ubuntu-native:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
standard: [ legacy, f2018 ]
compiler: [ g++ ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: ubuntu-native
run: |
${{ matrix.compiler }} -x f77 -std=${{ matrix.standard }} -m64 -fno-exceptions -O2 gamma.f -lgfortran -lquadmath -o gamma.exe
ls -la gamma.exe
./gamma.exe | grep '0.947395504039301942134227647281424E+00'
./gamma.exe | grep '0.110784755653406415338349971053114E+01'
./gamma.exe | grep '0.271139823924390323650711692085896E+01'
./gamma.exe | grep '0.102754040920152050479188001843206E+02'
./gamma.exe | grep '0.531934282525008207389522379291889E+02'
./gamma.exe | grep '0.350998609824200588801455504140098E+03'
./gamma.exe | grep '0.282509453680418713613816084109635E+04'
./gamma.exe | grep '0.269036719467497675679082571845063E+05'
./gamma.exe | grep '0.296439082102472192334520537379648E+06'
./gamma.exe | grep '0.554521067573633755529159865936434E-01'
./gamma.exe | grep '0.265252859812191058636308480000000E+33'
ubuntu-native-asan:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
standard: [ legacy, f2018 ]
compiler: [ g++ ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: ubuntu-native
run: |
${{ matrix.compiler }} -x f77 -std=${{ matrix.standard }} -m64 -fno-exceptions -fsanitize=address -fsanitize=leak -O1 gamma.f -lgfortran -lquadmath -o gamma.exe
ls -la gamma.exe
setarch `uname -m` -R ./gamma.exe | grep '0.947395504039301942134227647281424E+00'
setarch `uname -m` -R ./gamma.exe | grep '0.110784755653406415338349971053114E+01'
setarch `uname -m` -R ./gamma.exe | grep '0.271139823924390323650711692085896E+01'
setarch `uname -m` -R ./gamma.exe | grep '0.102754040920152050479188001843206E+02'
setarch `uname -m` -R ./gamma.exe | grep '0.531934282525008207389522379291889E+02'
setarch `uname -m` -R ./gamma.exe | grep '0.350998609824200588801455504140098E+03'
setarch `uname -m` -R ./gamma.exe | grep '0.282509453680418713613816084109635E+04'
setarch `uname -m` -R ./gamma.exe | grep '0.269036719467497675679082571845063E+05'
setarch `uname -m` -R ./gamma.exe | grep '0.296439082102472192334520537379648E+06'
setarch `uname -m` -R ./gamma.exe | grep '0.554521067573633755529159865936434E-01'
setarch `uname -m` -R ./gamma.exe | grep '0.265252859812191058636308480000000E+33'
ubuntu-native-ubsan:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
standard: [ legacy, f2018 ]
compiler: [ g++ ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: ubuntu-native
run: |
${{ matrix.compiler }} -x f77 -std=${{ matrix.standard }} -m64 -fno-exceptions -fsanitize=shift -fsanitize=shift-exponent -fsanitize=shift-base -fsanitize=integer-divide-by-zero -fsanitize=null -fsanitize=signed-integer-overflow -fsanitize=bounds -fsanitize=alignment -fsanitize=float-divide-by-zero -fsanitize=float-cast-overflow -fsanitize=enum -O1 gamma.f -lgfortran -lquadmath -o gamma.exe
ls -la gamma.exe
./gamma.exe | grep '0.947395504039301942134227647281424E+00'
./gamma.exe | grep '0.110784755653406415338349971053114E+01'
./gamma.exe | grep '0.271139823924390323650711692085896E+01'
./gamma.exe | grep '0.102754040920152050479188001843206E+02'
./gamma.exe | grep '0.531934282525008207389522379291889E+02'
./gamma.exe | grep '0.350998609824200588801455504140098E+03'
./gamma.exe | grep '0.282509453680418713613816084109635E+04'
./gamma.exe | grep '0.269036719467497675679082571845063E+05'
./gamma.exe | grep '0.296439082102472192334520537379648E+06'
./gamma.exe | grep '0.554521067573633755529159865936434E-01'
./gamma.exe | grep '0.265252859812191058636308480000000E+33'
macos-native:
runs-on: macos-latest
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
compiler: [ g++-13 ]
standard: [ legacy, f2018 ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: update-tools
run: brew reinstall gcc@13
- name: brew-installed-gcc-path
run: |
PATH="/usr/local/Cellar/gcc/13.2.0/bin:$PATH"
- name: g++-version
run: |
echo Query the g++ version
${{ matrix.compiler }} -v
- name: macos-native
run: |
${{ matrix.compiler }} -x f77 -std=${{ matrix.standard }} -m64 -fno-exceptions -O2 gamma.f -lgfortran -lquadmath -o gamma.exe
ls -la gamma.exe
./gamma.exe | grep '0.947395504039301942134227647281424E+00'
./gamma.exe | grep '0.110784755653406415338349971053114E+01'
./gamma.exe | grep '0.271139823924390323650711692085896E+01'
./gamma.exe | grep '0.102754040920152050479188001843206E+02'
./gamma.exe | grep '0.531934282525008207389522379291889E+02'
./gamma.exe | grep '0.350998609824200588801455504140098E+03'
./gamma.exe | grep '0.282509453680418713613816084109635E+04'
./gamma.exe | grep '0.269036719467497675679082571845063E+05'
./gamma.exe | grep '0.296439082102472192334520537379648E+06'
./gamma.exe | grep '0.554521067573633755529159865936434E-01'
./gamma.exe | grep '0.265252859812191058636308480000000E+33'
ubuntu-native-valgrind:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
standard: [ legacy, f2018 ]
compiler: [ g++ ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: update-tools
run: |
sudo apt-get update -y
sudo apt-get install -y valgrind
- name: ubuntu-native-valgrind-run
run: |
${{ matrix.compiler }} -x f77 -std=${{ matrix.standard }} -m64 -fno-exceptions -O1 gamma.f -lgfortran -lquadmath -o gamma.exe
ls -la gamma.exe
valgrind --leak-check=yes --log-file=gamma_valgrind_0.txt ./gamma.exe | grep '0.947395504039301942134227647281424E+00'
valgrind --leak-check=yes --log-file=gamma_valgrind_1.txt ./gamma.exe | grep '0.110784755653406415338349971053114E+01'
valgrind --leak-check=yes --log-file=gamma_valgrind_2.txt ./gamma.exe | grep '0.271139823924390323650711692085896E+01'
valgrind --leak-check=yes --log-file=gamma_valgrind_3.txt ./gamma.exe | grep '0.102754040920152050479188001843206E+02'
valgrind --leak-check=yes --log-file=gamma_valgrind_4.txt ./gamma.exe | grep '0.531934282525008207389522379291889E+02'
valgrind --leak-check=yes --log-file=gamma_valgrind_5.txt ./gamma.exe | grep '0.350998609824200588801455504140098E+03'
valgrind --leak-check=yes --log-file=gamma_valgrind_6.txt ./gamma.exe | grep '0.282509453680418713613816084109635E+04'
valgrind --leak-check=yes --log-file=gamma_valgrind_7.txt ./gamma.exe | grep '0.269036719467497675679082571845063E+05'
valgrind --leak-check=yes --log-file=gamma_valgrind_8.txt ./gamma.exe | grep '0.296439082102472192334520537379648E+06'
valgrind --leak-check=yes --log-file=gamma_valgrind_9.txt ./gamma.exe | grep '0.554521067573633755529159865936434E-01'
valgrind --leak-check=yes --log-file=gamma_valgrind_10.txt ./gamma.exe | grep '0.265252859812191058636308480000000E+33'
- name: ubuntu-native-valgrind-check
run: |
#!/bin/bash
for i in {0..10}; do
filename="gamma_valgrind_$i.txt"
grep '0 bytes in 0 blocks' $filename
grep '0 errors from 0 contexts' $filename
done