tem_debug_module Module

Provide a general debug environment. See tem_load_debug for configuration options.


Uses

  • module~~tem_debug_module~~UsesGraph module~tem_debug_module tem_debug_module module~env_module env_module module~tem_debug_module->module~env_module module~tem_logging_module tem_logging_module module~tem_debug_module->module~tem_logging_module module~flu_binding flu_binding module~tem_debug_module->module~flu_binding module~aot_table_module aot_table_module module~tem_debug_module->module~aot_table_module module~tem_tools_module tem_tools_module module~tem_debug_module->module~tem_tools_module module~env_module->module~flu_binding module~aotus_module aotus_module module~env_module->module~aotus_module iso_fortran_env iso_fortran_env module~env_module->iso_fortran_env mpi mpi module~env_module->mpi module~tem_logging_module->module~env_module module~tem_logging_module->module~aot_table_module module~tem_logging_module->module~aotus_module module~tem_tools_module->module~env_module

Used by

  • module~~tem_debug_module~~UsedByGraph module~tem_debug_module tem_debug_module module~tem_geometry_module tem_geometry_module module~tem_geometry_module->module~tem_debug_module module~tem_restart_module tem_restart_module module~tem_restart_module->module~tem_debug_module module~tem_canonicalnd_module tem_canonicalND_module module~tem_canonicalnd_module->module~tem_debug_module program~elem_memalloc elem_memAlloc program~elem_memalloc->module~tem_debug_module module~tem_bc_prop_module tem_bc_prop_module module~tem_bc_prop_module->module~tem_debug_module module~tem_matrix_module tem_matrix_module module~tem_matrix_module->module~tem_debug_module module~tem_subtree_module tem_subTree_module module~tem_subtree_module->module~tem_debug_module module~tem_tracking_module tem_tracking_module module~tem_tracking_module->module~tem_debug_module program~derivedtype_memalloc derivedType_memAlloc program~derivedtype_memalloc->module~tem_debug_module module~tem_construction_module tem_construction_module module~tem_construction_module->module~tem_debug_module

Contents


Variables

TypeVisibilityAttributesNameInitial
integer, public :: dbgUnit(0:tem_last_lu)
type(tem_debug_type), public :: main_debug
integer, private, parameter:: buffer_length =128

The length of the buffer to create a string representation of arrays.


Interfaces

public interface tem_debug

  • private subroutine tem_debug_for(me, level, msg)

    Write a message to a dedicated debug logger.

    Arguments

    TypeIntentOptionalAttributesName
    type(tem_debug_type), intent(in) :: me

    Debug type including the logger to use.

    integer, intent(in) :: level

    Log-Level of this message.

    character(len=*), intent(in) :: msg

    Message to write.

  • private subroutine tem_debug_main(level, msg)

    Write a message to the main debug logger.

    Arguments

    TypeIntentOptionalAttributesName
    integer, intent(in) :: level

    Log-Level of this message.

    character(len=*), intent(in) :: msg

    Message to write.


Derived Types

type, public :: tem_debug_type

Debug option definitions

Components

TypeVisibilityAttributesNameInitial
logical, private :: active =.false.

debug mode activated?

logical, private :: debugFiles =.false.

open separate file for each process

character(len=PathLen), private :: debugMesh

folder to store the debug mesh

integer, private :: unit =-1

unit to write in

logical, private :: checkEachAlgorithmicStep =.false.

output debug output after each step in compute

logical, private :: dumpLevelwiseState =.false.

write element state information to the debugFiles

logical, private :: dumpHaloState =.false.

write halo state information to the debugFiles

logical, private :: dumpTreeIDlists =.false.

write all the required and generated treeIDs in a level-wise manner to the debug file this includes fluid, ghost and halo elements and can serve as a detailed debug output

logical, private :: dumpPropBits =.false.

write all the property bits to disk for all elements

logical, private :: dumpDependencies =.false.

write all dependencies of ghost elements to disk

logical, private :: debugDependencies =.false.

write all dependencies of ghost elements to disk

logical, private :: checkDependencies =.false.

check if the dependencies are correct by cross checking

logical, private :: dumpAuxLists =.false.

write auxiliary lists to disk such as boundary element lists

logical, private :: unitTests =.false.
logical, private :: dumpSource =.false.

write out source debug statements to debug unit

logical, private :: debugRestart =.false.

write out restart debug info

logical, private :: traceMemory =.false.

trace memory consumption

logical, private :: checkNaNs =.false.

Check the state array for NaNs

logical, private :: dumpBoundaries =.false.

Dump boundary elements information

type(tem_logging_type), private :: logger

A logger to describe the output capabilities of this debug object.


Subroutines

public subroutine tem_load_debug(me, conf, rank)

Read the debug configuration into the debug type 'me' The debug definition is placed in the main level of the musubi.lua file It can look like

Read more…

Arguments

TypeIntentOptionalAttributesName
type(tem_debug_type) :: me

debug type to store information

type(flu_State) :: conf

lua state

integer, intent(in) :: rank

Rank of the calling process

public subroutine tem_debug_load_main(conf, rank)

Load the main debugger object

Arguments

TypeIntentOptionalAttributesName
type(flu_State) :: conf

Lua state, to get the configuration from.

integer, intent(in), optional :: rank

Rank of the calling process.

public subroutine tem_reportStatus(level, text, debug, string)

print an array to the debugunit

Arguments

TypeIntentOptionalAttributesName
integer, intent(in) :: level

level for debug output

character(len=*) :: text

Array title in debug output for easy identification in the file

type(tem_debug_type), intent(in), optional :: debug

optional debug type

character(len=*), optional :: string

optional additional string extending the title

public subroutine tem_print_array(me, nVals, itemLength, title, outUnit)

print an array to the debugunit

Arguments

TypeIntentOptionalAttributesName
integer(kind=long_k), intent(in) :: me(:)

long array to write to debug file

integer, intent(in) :: nVals

number of values in array me

integer, optional :: itemLength

how many characters needs each item of the array to output

character(len=*), optional :: title

Array title in debug output for easy identification in the file

integer, intent(in) :: outUnit

output unit

private subroutine tem_debug_for(me, level, msg)

Write a message to a dedicated debug logger.

Arguments

TypeIntentOptionalAttributesName
type(tem_debug_type), intent(in) :: me

Debug type including the logger to use.

integer, intent(in) :: level

Log-Level of this message.

character(len=*), intent(in) :: msg

Message to write.

private subroutine tem_debug_main(level, msg)

Write a message to the main debug logger.

Arguments

TypeIntentOptionalAttributesName
integer, intent(in) :: level

Log-Level of this message.

character(len=*), intent(in) :: msg

Message to write.