Skip to content

Commit 7acd2cb

Browse files
committed
Frontier fix ups
1 parent d3c24ba commit 7acd2cb

File tree

5 files changed

+24
-15
lines changed

5 files changed

+24
-15
lines changed

CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,6 @@ elseif (CMAKE_Fortran_COMPILER_ID STREQUAL "Cray")
164164
"SHELL: -h acc_model=no_fast_addr"
165165
"SHELL: -h list=adm"
166166
"SHELL: -munsafe-fp-atomics" # Not unsafe for operations we do
167-
"SHELL: -O3 -hacc"
168167
)
169168

170169
add_link_options("SHELL:-hkeepfiles")

src/common/m_mpi_common.fpp

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1055,6 +1055,8 @@ contains
10551055
!! Remaining number of cells, in a particular coordinate direction,
10561056
!! after the majority is divided up among the available processors
10571057
1058+
integer :: recon_order !< reconstruction order
1059+
10581060
integer :: i, j !< Generic loop iterators
10591061
10601062
if (num_procs == 1 .and. parallel_io) then
@@ -1064,6 +1066,12 @@ contains
10641066
return
10651067
end if
10661068
1069+
if (igr) then
1070+
recon_order = igr_order
1071+
else
1072+
recon_order = weno_order
1073+
end if
1074+
10671075
! 3D Cartesian Processor Topology
10681076
if (n > 0) then
10691077
@@ -1092,7 +1100,7 @@ contains
10921100
10931101
if (mod(num_procs, i) == 0 &
10941102
.and. &
1095-
(m + 1)/i >= num_stcls_min*weno_order) then
1103+
(m + 1)/i >= num_stcls_min*recon_order) then
10961104
10971105
tmp_num_procs_x = i
10981106
tmp_num_procs_y = num_procs/i
@@ -1102,7 +1110,7 @@ contains
11021110
.and. &
11031111
(n + 1)/tmp_num_procs_y &
11041112
>= &
1105-
num_stcls_min*weno_order) then
1113+
num_stcls_min*recon_order) then
11061114
11071115
num_procs_x = i
11081116
num_procs_y = num_procs/i
@@ -1138,13 +1146,13 @@ contains
11381146
11391147
if (mod(num_procs, i) == 0 &
11401148
.and. &
1141-
(m + 1)/i >= num_stcls_min*weno_order) then
1149+
(m + 1)/i >= num_stcls_min*recon_order) then
11421150
11431151
do j = 1, num_procs/i
11441152
11451153
if (mod(num_procs/i, j) == 0 &
11461154
.and. &
1147-
(n + 1)/j >= num_stcls_min*weno_order) then
1155+
(n + 1)/j >= num_stcls_min*recon_order) then
11481156
11491157
tmp_num_procs_x = i
11501158
tmp_num_procs_y = j
@@ -1157,7 +1165,7 @@ contains
11571165
.and. &
11581166
(p + 1)/tmp_num_procs_z &
11591167
>= &
1160-
num_stcls_min*weno_order) &
1168+
num_stcls_min*recon_order) &
11611169
then
11621170
11631171
num_procs_x = i
@@ -1186,7 +1194,7 @@ contains
11861194
if (proc_rank == 0 .and. ierr == -1) then
11871195
call s_mpi_abort('Unsupported combination of values '// &
11881196
'of num_procs, m, n, p and '// &
1189-
'weno_order. Exiting.')
1197+
'weno/igr_order. Exiting.')
11901198
end if
11911199
11921200
! Creating new communicator using the Cartesian topology
@@ -1294,7 +1302,7 @@ contains
12941302
12951303
if (mod(num_procs, i) == 0 &
12961304
.and. &
1297-
(m + 1)/i >= num_stcls_min*weno_order) then
1305+
(m + 1)/i >= num_stcls_min*recon_order) then
12981306
12991307
tmp_num_procs_x = i
13001308
tmp_num_procs_y = num_procs/i
@@ -1304,7 +1312,7 @@ contains
13041312
.and. &
13051313
(n + 1)/tmp_num_procs_y &
13061314
>= &
1307-
num_stcls_min*weno_order) then
1315+
num_stcls_min*recon_order) then
13081316
13091317
num_procs_x = i
13101318
num_procs_y = num_procs/i
@@ -1323,7 +1331,7 @@ contains
13231331
if (proc_rank == 0 .and. ierr == -1) then
13241332
call s_mpi_abort('Unsupported combination of values '// &
13251333
'of num_procs, m, n and '// &
1326-
'weno_order. Exiting.')
1334+
'weno/igr_order. Exiting.')
13271335
end if
13281336
13291337
! Creating new communicator using the Cartesian topology

src/simulation/m_global_parameters.fpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ module m_global_parameters
195195
$:GPU_DECLARE(create='[mpp_lim,model_eqns,mixture_err,alt_soundspeed]')
196196
$:GPU_DECLARE(create='[avg_state,mp_weno,weno_eps,teno_CT,hypoelasticity]')
197197
$:GPU_DECLARE(create='[hyperelasticity,hyper_model,elasticity,low_Mach]')
198-
$:GPU_DECLARE(create='[viscous,shear_stress,bulk_stress,cont_damage]')
198+
$:GPU_DECLARE(create='[shear_stress,bulk_stress,cont_damage]')
199199

200200
logical :: relax !< activate phase change
201201
integer :: relax_model !< Relaxation model

src/simulation/m_igr.fpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ contains
163163
end subroutine s_initialize_igr_module
164164

165165
subroutine s_igr_iterative_solve(q_cons_vf, bc_type, t_step)
166-
166+
!DIR$ OPTIMIZE (-haggress)
167167
type(scalar_field), dimension(sys_size), intent(inout) :: q_cons_vf
168168
type(integer_field), dimension(1:num_dims, -1:1), intent(in) :: bc_type
169169
integer, intent(in) :: t_step
@@ -261,7 +261,7 @@ contains
261261
end subroutine s_igr_iterative_solve
262262

263263
subroutine s_igr_sigma_x(q_cons_vf, rhs_vf)
264-
264+
!DIR$ OPTIMIZE (-haggress)
265265
type(scalar_field), &
266266
dimension(sys_size), &
267267
intent(inout) :: rhs_vf
@@ -328,7 +328,7 @@ contains
328328
end subroutine s_igr_sigma_x
329329

330330
subroutine s_igr_riemann_solver(q_cons_vf, rhs_vf, idir)
331-
331+
!DIR$ OPTIMIZE (-haggress)
332332
type(scalar_field), &
333333
dimension(sys_size), &
334334
intent(inout) :: rhs_vf

src/simulation/m_start_up.fpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1143,7 +1143,9 @@ contains
11431143
io_time_final = maxval(io_proc_time)
11441144
end if
11451145

1146-
grind_time = time_final*1.0e9_wp/(sys_size*maxval((/1,m_glb/))*maxval((/1,n_glb/))*maxval((/1,p_glb/)))
1146+
grind_time = time_final * 1.0e9_wp / &
1147+
(real(sys_size, wp) * real(maxval((/1, m_glb/)), wp) * &
1148+
real(maxval((/1, n_glb/)), wp) * real(maxval((/1, p_glb/)), wp))
11471149

11481150
print *, "Performance:", grind_time, "ns/gp/eq/rhs"
11491151
inquire (FILE='time_data.dat', EXIST=file_exists)

0 commit comments

Comments
 (0)