@@ -27,9 +27,9 @@ program main
27
27
28
28
! Check for feature flags
29
29
debug_active = index (options_str, ' -g' ) > 0
30
- release_active = index (options_str, ' -O ' ) > 0
30
+ release_active = index (options_str, ' -O3 ' ) > 0
31
31
verbose_active = index (options_str, ' -v' ) > 0 .or. index (options_str, ' -v ' ) > 0
32
- fast_active = index (options_str, ' -Ofast ' ) > 0 .or. index (options_str, ' - fast' ) > 0
32
+ fast_active = index (options_str, ' fast' ) > 0
33
33
strict_active = index (options_str, ' -std=f2018' ) > 0 .or. index (options_str, ' -stand f18' ) > 0
34
34
35
35
! Display active features
@@ -127,13 +127,13 @@ function check_gfortran_flags(options, debug_on, release_on, fast_on, strict_on)
127
127
end if
128
128
129
129
if (release_on) then
130
- ! Check for either -march=native or -mcpu (Apple Silicon uses -mcpu)
131
- if (.not. (index (options, ' -march=native ' ) > 0 .or. index (options, ' -mcpu' ) > 0 )) then
130
+ ! Check for either -march or -mcpu (Apple Silicon uses -mcpu; -match=native may be re-resolved by gcc )
131
+ if (.not. (index (options, ' -march' ) > 0 .or. index (options, ' -mcpu' ) > 0 )) then
132
132
print ' (a)' , ' ✗ Release: neither -march=native nor -mcpu found'
133
133
failed_count = failed_count + 1
134
134
else
135
135
if (index (options, ' -march=native' ) > 0 ) then
136
- print ' (a)' , ' ✓ Release: -march=native found'
136
+ print ' (a)' , ' ✓ Release: -march found'
137
137
else
138
138
print ' (a)' , ' ✓ Release: -mcpu found'
139
139
end if
@@ -142,7 +142,7 @@ function check_gfortran_flags(options, debug_on, release_on, fast_on, strict_on)
142
142
end if
143
143
144
144
if (fast_on) then
145
- if (.not. check_flag(options, ' -Ofast ' , ' Fast' , ' -Ofast ' )) failed_count = failed_count + 1
145
+ if (.not. check_flag(options, ' -ffast ' , ' Fast' , ' -fast ' )) failed_count = failed_count + 1
146
146
if (.not. check_flag(options, ' -ffast-math' , ' Fast' , ' -ffast-math' )) failed_count = failed_count + 1
147
147
end if
148
148
@@ -172,7 +172,7 @@ function check_ifort_flags(options, debug_on, release_on, fast_on, strict_on) re
172
172
end if
173
173
174
174
if (fast_on) then
175
- if (.not. check_flag(options, ' -fast' , ' Fast' , ' -fast ' )) failed_count = failed_count + 1
175
+ if (.not. check_flag(options, ' -fast' , ' Fast' , ' -ffast ' )) failed_count = failed_count + 1
176
176
end if
177
177
178
178
if (strict_on) then
@@ -201,7 +201,7 @@ function check_ifx_flags(options, debug_on, release_on, fast_on, strict_on) resu
201
201
end if
202
202
203
203
if (fast_on) then
204
- if (.not. check_flag(options, ' -fast' , ' Fast' , ' -fast ' )) failed_count = failed_count + 1
204
+ if (.not. check_flag(options, ' -fast' , ' Fast' , ' -ffast ' )) failed_count = failed_count + 1
205
205
end if
206
206
207
207
if (strict_on) then
0 commit comments