GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> MSG / V3-1-2 > msg_st / rhel6-32


Interface   Data Structures   File List   Data Fields   Globals  

MSG_report.c File Reference

Core run time routines for the MSG facility. More...

#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
#include <string.h>
#include <MSG/MSG_msgs.h>
#include <MSG_health.h>
#include <MSG_packet.ih>
#include <MSG_prvdefs.h>

Functions

static void reportCapture (MSG_Packet *pkt, const MSG_MsgList *mdb, unsigned int nprm, va_list list)
 Process a message reporting request (packet and varargs).
unsigned int MSG_reportInternal (unsigned int code, WCT_time hack, const char *rtn, unsigned int nprm, va_list list)
 Process a message reporting request.


Detailed Description

Core run time routines for the MSG facility.

CVS $Id: MSG_report.c,v 1.4 2011/03/25 01:05:53 apw Exp $
Author:
A.P.Waite

Function Documentation

unsigned int MSG_reportInternal ( unsigned int  code,
WCT_time  hack,
const char *  rtn,
unsigned int  nprm,
va_list  list 
)

Process a message reporting request.

Parameters:
code (in) Message code to be reported
hack (in) Wall clock time to be recorded with the meessage
rtn (in) Name of calling routine
nprm (in) Number of parameters that follow
list (in) A variable argument list list (!)
MSG_reportInternal() does most of the real work of reporting a message. This routine allocates a message packet and populates it with a block of standard information (timestamp, CPU, task name, etc.) and the variable information in the variadic arguments following nprm.

The packet is sent to an message task (in the multi-threaded case) where the message is formatted using the formatting string associated with the message code. The message task then calls all output processors in turn to do whatever it is they want to do with the information.

In the single-threaded case, the message processing occurs inline with the MSG_report() call.

References _MSG_Control::acb, _MSG_Control::beg, _MSG_Counts::drop, _MSG_Control::drp, _MSG_Control::fqi, _MSG_Counts::lwm, MSG__packetFill(), MSG_A_GAPBEGIN, MSG_A_UNIXEROR, MSG_A_UNIXGOOD, MSG_alt, MSG_getLevel(), MSG_getTask(), MSG_getTrace(), MSG_K_FMT4BINT, MSG_mcb, MSG_outputScan(), MSG_RW_DECLARE, MSG_RW_LOCK, MSG_RW_UNLOCK, MSG_S_STARTED, _MSG_Control::now, reportCapture(), _MSG_Control::reset, _MSG_Control::rwi, _MSG_Control::start, and _MSG_Control::state.

Referenced by MSG_initialize().

static void reportCapture ( MSG_Packet pkt,
const MSG_MsgList *  mdb,
unsigned int  nprm,
va_list  list 
) [static]

Process a message reporting request (packet and varargs).

Parameters:
pkt (in) Packet in which to form the message
mdb (in) Message data entry corresponding to code
nprm (in) Number of parameters that follow
list (in) A variable argument list list (!)
Capture the binary contents of a message. The buffer constructed by this routine will be sent to the message task (in the multi-threaded case) or be sent directly to the output processors (single-threaded case).

References _MSG_Packet::buf, _MSG_Packet::msg, MSG_K_FMT4BINT, MSG_K_FMT8BINT, MSG_K_FMTBITS, MSG_K_FMTDOUBLE, MSG_K_FMTSTRING, MSG_M_FMTBITS, MSG_mcb, _MSG_Message::nick, _MSG_Control::pkt_len, and _MSG_Message::text.

Referenced by MSG_reportInternal().


Generated on Tue Nov 29 16:54:51 2011 by  doxygen 1.5.8