204 lines
10 KiB
HTML
204 lines
10 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<meta name="generator" content="HTML Tidy, see www.w3.org">
|
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
|
<link type="text/css" rel="stylesheet" href="style.css"><!-- Generated by The Open Group's rhtm tool v1.2.1 -->
|
|
<!-- Copyright (c) 2001 The Open Group, All Rights Reserved -->
|
|
<title>posix_trace_eventid_equal</title>
|
|
</head>
|
|
<body bgcolor="white">
|
|
<script type="text/javascript" language="JavaScript" src="../jscript/codes.js">
|
|
</script>
|
|
|
|
<basefont size="3"> <a name="posix_trace_eventid_equal"></a> <a name="tag_03_464"></a><!-- posix_trace_eventid_equal -->
|
|
<!--header start-->
|
|
<center><font size="2">The Open Group Base Specifications Issue 6<br>
|
|
IEEE Std 1003.1-2001<br>
|
|
Copyright © 2001 The IEEE and The Open Group, All Rights reserved.</font></center>
|
|
|
|
<!--header end-->
|
|
<hr size="2" noshade>
|
|
<h4><a name="tag_03_464_01"></a>NAME</h4>
|
|
|
|
<blockquote>posix_trace_eventid_equal, posix_trace_eventid_get_name, posix_trace_trid_eventid_open - manipulate the trace event
|
|
type identifier (<b>TRACING</b>)</blockquote>
|
|
|
|
<h4><a name="tag_03_464_02"></a>SYNOPSIS</h4>
|
|
|
|
<blockquote class="synopsis">
|
|
<div class="box"><code><tt><sup>[<a href="javascript:open_code('TRC')">TRC</a>]</sup> <img src="../images/opt-start.gif" alt=
|
|
"[Option Start]" border="0"> #include <<a href="../basedefs/trace.h.html">trace.h</a>><br>
|
|
<br>
|
|
int posix_trace_eventid_equal(trace_id_t</tt> <i>trid</i><tt>, trace_event_id_t</tt> <i>event1</i><tt>,<br>
|
|
trace_event_id_t</tt> <i>event2</i><tt>);<br>
|
|
int posix_trace_eventid_get_name(trace_id_t</tt> <i>trid</i><tt>,<br>
|
|
trace_event_id_t</tt> <i>event</i><tt>, char *</tt><i>event_name</i><tt>);<br>
|
|
<img src="../images/opt-end.gif" alt="[Option End]" border="0"></tt></code></div>
|
|
|
|
<div class="box"><code><tt><sup>[<a href="javascript:open_code('TRC TEF')">TRC TEF</a>]</sup> <img src="../images/opt-start.gif" alt=
|
|
"[Option Start]" border="0"> int posix_trace_trid_eventid_open(trace_id_t</tt> <i>trid</i><tt>,<br>
|
|
const char *restrict</tt> <i>event_name</i><tt>,<br>
|
|
trace_event_id_t *restrict</tt> <i>event</i><tt>); <img src="../images/opt-end.gif" alt=
|
|
"[Option End]" border="0"></tt></code></div>
|
|
|
|
<tt><br>
|
|
</tt></blockquote>
|
|
|
|
<h4><a name="tag_03_464_03"></a>DESCRIPTION</h4>
|
|
|
|
<blockquote>
|
|
<p>The <i>posix_trace_eventid_equal</i>() function shall compare the trace event type identifiers <i>event1</i> and <i>event2</i>
|
|
from the same trace stream or the same trace log identified by the <i>trid</i> argument. If the trace event type identifiers
|
|
<i>event1</i> and <i>event2</i> are from different trace streams, the return value shall be unspecified.</p>
|
|
|
|
<p>The <i>posix_trace_eventid_get_name</i>() function shall return, in the argument pointed to by <i>event_name</i>, the trace
|
|
event name associated with the trace event type identifier identified by the argument <i>event</i>, for the trace stream or for the
|
|
trace log identified by the <i>trid</i> argument. The name of the trace event shall have a maximum of {TRACE_EVENT_NAME_MAX}
|
|
characters (which has the minimum value {_POSIX_TRACE_EVENT_NAME_MAX}). Successive calls to this function with the same trace event
|
|
type identifier and the same trace stream identifier shall return the same event name.</p>
|
|
|
|
<p><sup>[<a href="javascript:open_code('TEF')">TEF</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">
|
|
The <i>posix_trace_trid_eventid_open</i>() function shall associate a user trace event name with a trace event type identifier for
|
|
a given trace stream. The trace stream is identified by the <i>trid</i> argument, and it shall be an active trace stream. The trace
|
|
event name is the string pointed to by the argument <i>event_name</i>. It shall have a maximum of {TRACE_EVENT_NAME_MAX} characters
|
|
(which has the minimum value {_POSIX_TRACE_EVENT_NAME_MAX}). The number of user trace event type identifiers that can be defined
|
|
for any given process is limited by the maximum value {TRACE_USER_EVENT_MAX}, which has the minimum value
|
|
{_POSIX_TRACE_USER_EVENT_MAX}.</p>
|
|
|
|
<p>If the Trace Inherit option is not supported, the <i>posix_trace_trid_eventid_open</i>() function shall associate the user trace
|
|
event name pointed to by the <i>event_name</i> argument with a trace event type identifier that is unique for the process being
|
|
traced in the trace stream identified by the <i>trid</i> argument, and is returned in the variable pointed to by the <i>event</i>
|
|
argument. If the user trace event name has already been mapped for the traced process, then the previously assigned trace event
|
|
type identifier shall be returned. If the per-process user trace event name limit represented by {TRACE_USER_EVENT_MAX} has been
|
|
reached, the pre-defined POSIX_TRACE_UNNAMED_USEREVENT (see <a href="xsh_chap02_11.html#tagtcjh_7"><i>Trace Option: User Trace
|
|
Event</i></a> ) user trace event shall be returned. <img src="../images/opt-end.gif" alt="[Option End]" border="0"></p>
|
|
|
|
<p><sup>[<a href="javascript:open_code('TEF TRI')">TEF TRI</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]"
|
|
border="0"> If the Trace Inherit option is supported, the <i>posix_trace_trid_eventid_open</i>() function shall associate the user
|
|
trace event name pointed to by the <i>event_name</i> argument with a trace event type identifier that is unique for all the
|
|
processes being traced in the trace stream identified by the <i>trid</i> argument, and is returned in the variable pointed to by
|
|
the <i>event</i> argument. If the user trace event name has already been mapped for the traced processes, then the previously
|
|
assigned trace event type identifier shall be returned. If the per-process user trace event name limit represented by
|
|
{TRACE_USER_EVENT_MAX} has been reached, the pre-defined POSIX_TRACE_UNNAMED_USEREVENT (see <a href=
|
|
"xsh_chap02_11.html#tagtcjh_7"><i>Trace Option: User Trace Event</i></a> ) user trace event shall be returned. <img src=
|
|
"../images/opt-end.gif" alt="[Option End]" border="0"></p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_04"></a>RETURN VALUE</h4>
|
|
|
|
<blockquote>
|
|
<p>Upon successful completion, the <i>posix_trace_eventid_get_name</i>() and <sup>[<a href=
|
|
"javascript:open_code('TEF')">TEF</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">
|
|
<i>posix_trace_trid_eventid_open</i>() <img src="../images/opt-end.gif" alt="[Option End]" border="0"> functions shall return a
|
|
value of zero. Otherwise, they shall return the corresponding error number.</p>
|
|
|
|
<p>The <i>posix_trace_eventid_equal</i>() function shall return a non-zero value if <i>event1</i> and <i>event2</i> are equal;
|
|
otherwise, a value of zero shall be returned. No errors are defined. If either <i>event1</i> or <i>event2</i> are not valid trace
|
|
event type identifiers for the trace stream specified by <i>trid</i> or if the <i>trid</i> is invalid, the behavior shall be
|
|
unspecified.</p>
|
|
|
|
<p>The <i>posix_trace_eventid_get_name</i>() function stores the trace event name value in the object pointed to by
|
|
<i>event_name</i>, if successful.</p>
|
|
|
|
<p><sup>[<a href="javascript:open_code('TEF')">TEF</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">
|
|
The <i>posix_trace_trid_eventid_open</i>() function stores the trace event type identifier value in the object pointed to by
|
|
<i>event</i>, if successful. <img src="../images/opt-end.gif" alt="[Option End]" border="0"></p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_05"></a>ERRORS</h4>
|
|
|
|
<blockquote>
|
|
<p>The <i>posix_trace_eventid_get_name</i>() and <sup>[<a href="javascript:open_code('TEF')">TEF</a>]</sup> <img src=
|
|
"../images/opt-start.gif" alt="[Option Start]" border="0"> <i>posix_trace_trid_eventid_open</i>() <img src="../images/opt-end.gif"
|
|
alt="[Option End]" border="0"> functions shall fail if:</p>
|
|
|
|
<dl compact>
|
|
<dt>[EINVAL]</dt>
|
|
|
|
<dd>The <i>trid</i> argument was not a valid trace stream identifier.</dd>
|
|
</dl>
|
|
|
|
<p><sup>[<a href="javascript:open_code('TEF')">TEF</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">
|
|
The <i>posix_trace_trid_eventid_open</i>() function shall fail if: <img src="../images/opt-end.gif" alt="[Option End]" border=
|
|
"0"></p>
|
|
|
|
<dl compact>
|
|
<dt>[ENAMETOOLONG]</dt>
|
|
|
|
<dd><sup>[<a href="javascript:open_code('TEF')">TEF</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border=
|
|
"0"><br>
|
|
The size of the name pointed to by the <i>event_name</i> argument was longer than the implementation-defined value
|
|
{TRACE_EVENT_NAME_MAX}. <img src="../images/opt-end.gif" alt="[Option End]" border="0"></dd>
|
|
</dl>
|
|
|
|
<p>The <i>posix_trace_eventid_get_name</i>() function shall fail if:</p>
|
|
|
|
<dl compact>
|
|
<dt>[EINVAL]</dt>
|
|
|
|
<dd>The trace event type identifier <i>event</i> was not associated with any name.</dd>
|
|
</dl>
|
|
</blockquote>
|
|
|
|
<hr>
|
|
<div class="box"><em>The following sections are informative.</em></div>
|
|
|
|
<h4><a name="tag_03_464_06"></a>EXAMPLES</h4>
|
|
|
|
<blockquote>
|
|
<p>None.</p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_07"></a>APPLICATION USAGE</h4>
|
|
|
|
<blockquote>
|
|
<p>None.</p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_08"></a>RATIONALE</h4>
|
|
|
|
<blockquote>
|
|
<p>None.</p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_09"></a>FUTURE DIRECTIONS</h4>
|
|
|
|
<blockquote>
|
|
<p>None.</p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_10"></a>SEE ALSO</h4>
|
|
|
|
<blockquote>
|
|
<p><a href="xsh_chap02_11.html#tagtcjh_7"><i>Trace Option: User Trace Event</i></a> , <a href=
|
|
"posix_trace_event.html"><i>posix_trace_event</i>()</a> , <a href=
|
|
"posix_trace_getnext_event.html"><i>posix_trace_getnext_event</i>()</a> , the Base Definitions volume of
|
|
IEEE Std 1003.1-2001, <a href="../basedefs/trace.h.html"><i><trace.h></i></a></p>
|
|
</blockquote>
|
|
|
|
<h4><a name="tag_03_464_11"></a>CHANGE HISTORY</h4>
|
|
|
|
<blockquote>
|
|
<p>First released in Issue 6. Derived from IEEE Std 1003.1q-2000.</p>
|
|
|
|
<p>IEEE PASC Interpretations 1003.1 #123 and #129 are applied.</p>
|
|
</blockquote>
|
|
|
|
<div class="box"><em>End of informative text.</em></div>
|
|
|
|
<hr>
|
|
<hr size="2" noshade>
|
|
<center><font size="2"><!--footer start-->
|
|
UNIX ® is a registered Trademark of The Open Group.<br>
|
|
POSIX ® is a registered Trademark of The IEEE.<br>
|
|
[ <a href="../mindex.html">Main Index</a> | <a href="../basedefs/contents.html">XBD</a> | <a href=
|
|
"../utilities/contents.html">XCU</a> | <a href="../functions/contents.html">XSH</a> | <a href="../xrat/contents.html">XRAT</a>
|
|
]</font></center>
|
|
|
|
<!--footer end-->
|
|
<hr size="2" noshade>
|
|
</body>
|
|
</html>
|
|
|