.. _file_include_cmb_logger.h: File cmb_logger.h ================= |exhale_lsh| :ref:`Parent directory ` (``include``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS Centralized logging functions with simulation timestamps. .. contents:: Contents :local: :backlinks: none Definition (``include/cmb_logger.h``) ------------------------------------- .. toctree:: :maxdepth: 1 program_listing_file_include_cmb_logger.h.rst Detailed Description -------------------- Each call to the logger tags the message with a logging flag value. The flag value is matched against the simulation logging mask. If a bitwise ``and`` (``&``) of the current mask and the provided flags is non-zero, the message gets printed. This allows more combinations of system and user logging levels than a simple linear logging verbosity level. A single logging message can be flagged by a bitmask with several bits set, matching any of those bits in the current mask. A 32-bit unsigned integer is used for the flags, with the top four bits reserved for Cimba use, leaving 28 bits for user application. Will print the trial number as the first field if part of a multi-trial experiment. Will print the random number seed for message levels warning and above to enable reproducing the suspect condition in a debugger or with additional logging turned on. Format of a logging line: ``[trial_index] [seed] time process_name function (line) : [label] formatted_message`` The initial logging bitmask is ``0xFFFFFFFF``, printing everything. Includes -------- - ``cmi_config.h`` - ``stdint.h`` - ``stdio.h`` Included By ----------- - :ref:`file_include_cimba.h` Functions --------- - :ref:`exhale_function_cmb__logger_8h_1ae4f14575ccc67258cf1fe49d9b8e321e` - :ref:`exhale_function_cmb__logger_8h_1a18c658864cc7bc0f42b7b830081ea6d8` - :ref:`exhale_function_cmb__logger_8h_1ac2a8a7e8c80205c3076142e85322cc76` - :ref:`exhale_function_cmb__logger_8h_1af263325310e97148f5da74b5ea2ba603` Defines ------- - :ref:`exhale_define_cmb__logger_8h_1ad63d40c636054e829cb7c4ec2ee91874` - :ref:`exhale_define_cmb__logger_8h_1a3f0af1c30d074df3e417a694975908ef` - :ref:`exhale_define_cmb__logger_8h_1a2ae18ab8d8c9d91db5c33541ee9e50b7` - :ref:`exhale_define_cmb__logger_8h_1a98726f88d2261013a6641b4634a827c5` - :ref:`exhale_define_cmb__logger_8h_1ac0fca61f16145341387188406a412830` - :ref:`exhale_define_cmb__logger_8h_1ae6f16b766fce54fc5cf8408df145469b` - :ref:`exhale_define_cmb__logger_8h_1af90ac23227f56c1c7a7f94c83994839e` - :ref:`exhale_define_cmb__logger_8h_1a432ccf87b853bb63d39b792550238f44` - :ref:`exhale_define_cmb__logger_8h_1a61fa948317e6517feff4466c47d62a59` Typedefs -------- - :ref:`exhale_typedef_cmb__logger_8h_1aa7638bc4920d3c40a4c2c34a4ebfeeb3`