0001 libtraceevent(3)
0002 ================
0003
0004 NAME
0005 ----
0006 tep_get_page_size, tep_set_page_size - Get / set the size of a memory page on
0007 the machine, where the trace is generated
0008
0009 SYNOPSIS
0010 --------
0011 [verse]
0012 --
0013 *#include <event-parse.h>*
0014
0015 int *tep_get_page_size*(struct tep_handle pass:[*]_tep_);
0016 void *tep_set_page_size*(struct tep_handle pass:[*]_tep_, int _page_size_);
0017 --
0018
0019 DESCRIPTION
0020 -----------
0021 The _tep_get_page_size()_ function returns the size of a memory page on
0022 the machine, where the trace is generated. The _tep_ argument is trace
0023 event parser context.
0024
0025 The _tep_set_page_size()_ function stores in the _tep_ context the size of a
0026 memory page on the machine, where the trace is generated.
0027 The _tep_ argument is trace event parser context.
0028 The _page_size_ argument is the size of a memory page, in bytes.
0029
0030 RETURN VALUE
0031 ------------
0032 The _tep_get_page_size()_ function returns size of the memory page, in bytes.
0033
0034 EXAMPLE
0035 -------
0036 [source,c]
0037 --
0038 #include <unistd.h>
0039 #include <event-parse.h>
0040 ...
0041 struct tep_handle *tep = tep_alloc();
0042 ...
0043 int page_size = getpagesize();
0044
0045 tep_set_page_size(tep, page_size);
0046
0047 printf("The page size for this machine is %d\n", tep_get_page_size(tep));
0048
0049 --
0050
0051 FILES
0052 -----
0053 [verse]
0054 --
0055 *event-parse.h*
0056 Header file to include in order to have access to the library APIs.
0057 *-ltraceevent*
0058 Linker switch to add when building a program that uses the library.
0059 --
0060
0061 SEE ALSO
0062 --------
0063 _libtraceevent(3)_, _trace-cmd(1)_
0064
0065 AUTHOR
0066 ------
0067 [verse]
0068 --
0069 *Steven Rostedt* <rostedt@goodmis.org>, author of *libtraceevent*.
0070 *Tzvetomir Stoyanov* <tz.stoyanov@gmail.com>, author of this man page.
0071 --
0072 REPORTING BUGS
0073 --------------
0074 Report bugs to <linux-trace-devel@vger.kernel.org>
0075
0076 LICENSE
0077 -------
0078 libtraceevent is Free Software licensed under the GNU LGPL 2.1
0079
0080 RESOURCES
0081 ---------
0082 https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git