FIXME : Add documentation
subroutine run_diagnostics_to_be_updated
use fields_arrays, only: phinew, bparnew
use gs2_diagnostics, only: do_write_fyx, do_write_f
implicit none
integer :: nwrite_large
nwrite_large = gnostics%nwrite*gnostics%nwrite_mult
if (mod(gnostics%istep,nwrite_large) /= 0) return
! Random stuff that needs to be put in properly or removed
! Note we don't use gnostics%ascii_files%write_to_yxdist here
! because do_write_fyx is collective but gnostics%ascii_files%write_to_yxdist
! is only set on proc0
if (gnostics%write_ascii .and. gnostics%write_gyx) &
call do_write_fyx (gnostics%ascii_files%yxdist, phinew, bparnew)
if (gnostics%write_ascii .and. gnostics%write_g) &
call do_write_f (gnostics%ascii_files%dist)
end subroutine run_diagnostics_to_be_updated