From 0a63bf3246528b8420d8435f8523ff53b5996774 Mon Sep 17 00:00:00 2001 From: SVS87 Date: Mon, 15 Jun 2026 01:39:59 -0400 Subject: [PATCH] fix: remove dead *_MOK assignments in file_per_process I/O branches MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In the sequential file_per_process paths (MPI_COMM_SELF), the *_MOK offset variables are computed but never used — no MPI_FILE_SET_VIEW or disp displacement is present in these branches. Also removes the copy-paste typo where n_MOK and p_MOK were both derived from m_glb_read instead of n_glb_read/p_glb_read in m_start_up.fpp. Fixes #1490 --- src/simulation/m_data_output.fpp | 8 -------- src/simulation/m_start_up.fpp | 6 ------ 2 files changed, 14 deletions(-) diff --git a/src/simulation/m_data_output.fpp b/src/simulation/m_data_output.fpp index 255e3a4dd3..44724746f2 100644 --- a/src/simulation/m_data_output.fpp +++ b/src/simulation/m_data_output.fpp @@ -729,14 +729,6 @@ contains p_glb_save = p_glb + 1 end if - m_MOK = int(m_glb_save + 1, MPI_OFFSET_KIND) - n_MOK = int(n_glb_save + 1, MPI_OFFSET_KIND) - p_MOK = int(p_glb_save + 1, MPI_OFFSET_KIND) - WP_MOK = int(storage_size(0._stp)/8, MPI_OFFSET_KIND) - MOK = int(1._wp, MPI_OFFSET_KIND) - str_MOK = int(name_len, MPI_OFFSET_KIND) - NVARS_MOK = int(sys_size, MPI_OFFSET_KIND) - if (bubbles_euler) then do i = 1, sys_size var_MOK = int(i, MPI_OFFSET_KIND) diff --git a/src/simulation/m_start_up.fpp b/src/simulation/m_start_up.fpp index 4651133b83..2b05f32163 100644 --- a/src/simulation/m_start_up.fpp +++ b/src/simulation/m_start_up.fpp @@ -386,12 +386,6 @@ contains p_glb_read = p_glb + 1 end if - m_MOK = int(m_glb_read + 1, MPI_OFFSET_KIND) - n_MOK = int(m_glb_read + 1, MPI_OFFSET_KIND) - p_MOK = int(m_glb_read + 1, MPI_OFFSET_KIND) - WP_MOK = int(storage_size(0._stp)/8, MPI_OFFSET_KIND) - MOK = int(1._wp, MPI_OFFSET_KIND) - if (bubbles_euler .or. elasticity) then do i = 1, sys_size var_MOK = int(i, MPI_OFFSET_KIND)