Commit dd3c4143 authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Add MSC tracing at PI level

parent de90e19e
......@@ -36,11 +36,9 @@ void @_LOWER:Parent_Function_@_RI_@_Name_@@_REPLACE_ALL(-/_):REPLACE((.*)(\))(\n
// puts("");
@@-- Had to comment the line below, because we miss the destination function (in place of gnc)
@@-- When we have multicast me need to to emit the line several times (and need to add support)
// Log message to @_Remote_Function_Names_@ (corresponding PI: @_Remote_Interface_Names_@)
printf ("INNER: @_LOWER:Parent_Function_@,@_LOWER:Remote_Function_Names_@,@_LOWER:Name_@,%lld\n", msc_time);
printf ("INNER_RI: @_LOWER:Parent_Function_@,@_LOWER:Remote_Function_Names_@,@_LOWER:Remote_Interface_Names_@,%lld\n", msc_time);
......@@ -3,6 +3,19 @@
@@-- If you are using vim, go over the URL and pres gx in to follow the link
@@-- If you have no internet access you can also use (with vim) Ctrl-W-f or gf in vim to open the text doc:
@@-- $HOME/tool-inst/share/kazoo/doc/templates_skeletons_sub_interface.ascii
#ifdef __unix__
// Log MSC data on Linux when environment variable is set
static int innerMsc = -1;
if (-1 == innerMsc)
innerMsc = (NULL != getenv("TASTE_INNER_MSC"))?1:0;
if (1 == innerMsc) {
long long msc_time = getTimeInMilliseconds();
printf ("INNER_PI: @_LOWER:Parent_Function_@,@_LOWER:Name_@,%lld\n", msc_time);
@@SET@@ Static="static " @@-- Parameters of unprotected operations must be on the stack to avoid race conditions
......@@ -18,6 +31,7 @@ void @_LOWER:Parent_Function_@_@_Name_@
@@TABLE@@ @@-- decode input/output parameters into static variables or stack in case of unprotected operations
@@IF@@ @_Param_Encodings_@ /= NATIVE
......@@ -29,7 +43,7 @@ void @_LOWER:Parent_Function_@_@_Name_@
#ifdef __unix__
@@IF@@ @_Param_Directions_@ = "PARAM_IN"
if (0 != Decode_@_Param_Encodings_@_@_REPLACE_ALL(-/_):Param_Types_@ (&IN_@_UPPER:Param_Names_@, (void *)IN_@_LOWER:Param_Names_@, IN_@_LOWER:Param_Names_@_len)) {
#ifdef __unix__
puts("Error decoding @_Param_Types_@ in function @_Parent_Function_@_@_Name_@");
......@@ -108,6 +122,8 @@ void @_LOWER:Parent_Function_@_@_Name_@
@@ELSE@@ @@-- parameterless functions
void @_LOWER:Parent_Function_@_@_Name_@()
// Directly call user code, no parameters to pass
extern void @_LOWER:Parent_Function_@_PI_@_Name_@(void);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment