OSDN Git Service

Update README
[linuxjm/LDP_man-pages.git] / draft / man3 / profil.3
1 .\" Copyright 1993 Rickard E. Faith (faith@cs.unc.edu)
2 .\"
3 .\" %%%LICENSE_START(VERBATIM)
4 .\" Permission is granted to make and distribute verbatim copies of this
5 .\" manual provided the copyright notice and this permission notice are
6 .\" preserved on all copies.
7 .\"
8 .\" Permission is granted to copy and distribute modified versions of this
9 .\" manual under the conditions for verbatim copying, provided that the
10 .\" entire resulting derived work is distributed under the terms of a
11 .\" permission notice identical to this one.
12 .\"
13 .\" Since the Linux kernel and libraries are constantly changing, this
14 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
15 .\" responsibility for errors or omissions, or for damages resulting from
16 .\" the use of the information contained herein.  The author(s) may not
17 .\" have taken the same level of care in the production of this manual,
18 .\" which is licensed free of charge, as they might when working
19 .\" professionally.
20 .\"
21 .\" Formatted or processed versions of this manual, if unaccompanied by
22 .\" the source, must acknowledge the copyright and authors of this work.
23 .\" %%%LICENSE_END
24 .\"
25 .\" Modified Fri Jun 23 01:35:19 1995 Andries Brouwer <aeb@cwi.nl>
26 .\" (prompted by Bas V. de Bakker <bas@phys.uva.nl>)
27 .\" Corrected (and moved to man3), 980612, aeb
28 .\"*******************************************************************
29 .\"
30 .\" This file was generated with po4a. Translate the source file.
31 .\"
32 .\"*******************************************************************
33 .\"
34 .\" Japanese Version Copyright (c) 1997 HANATAKA Shinya
35 .\"         all rights reserved.
36 .\" Translated San Feb 23 20:40:50 JST 1997
37 .\"         by HANATAKA Shinya <hanataka@abyss.rim.or.jp>
38 .\" Modified Sun Jun 21 17:30:21 JST 1998
39 .\"         by HANATAKA Shinya <hanataka@abyss.rim.or.jp>
40 .\" Updated & Modified Thu Feb 17 00:57:49 JST 2005
41 .\"         by Yuichi SATO <ysato444@yahoo.co.jp>
42 .\"
43 .TH PROFIL 3 2014\-07\-08 Linux "Linux Programmer's Manual"
44 .SH 名前
45 profil \- 実行時間プロファイル (profile)
46 .SH 書式
47 .nf
48 \fB#include <unistd.h>\fP
49 .sp
50 \fBint profil(unsigned short *\fP\fIbuf\fP\fB, size_t \fP\fIbufsiz\fP\fB,\fP
51 \fB           size_t \fP\fIoffset\fP\fB, unsigned int \fP\fIscale\fP\fB);\fP
52 .sp
53 .fi
54 .in -4n
55 glibc 向けの機能検査マクロの要件 (\fBfeature_test_macros\fP(7)  参照):
56 .in
57 .sp
58 \fBprofil\fP(): _BSD_SOURCE || (_XOPEN_SOURCE && _XOPEN_SOURCE\ <\ 500)
59 .SH 説明
60 このルーティンはプログラムのどこの部分で時間を費やしているかを調べる 手段を提供する。引き数 \fIbuf\fP は \fIbufsiz\fP
61 バイトのメモリーを指している。仮想の 10 ミリ秒ごとに、ユーザーの プログラムカウンター (PC) が検査される: \fIoffset\fP
62 が引かれ、その結果が \fIscale\fP 倍され 65536 で割られる。 結果が \fIbufsiz\fP より小さい場合は \fIbuf\fP
63 の対応するエントリーがインクリメントされる。 \fIbuf\fP が NULL ならば、プロファイル (profile) は無効にされる。
64 .SH 返り値
65 常に 0 が返される。
66 .SH 準拠
67 SVr4 のコールに似ている (しかし POSIX.1\-2001 ではない)。
68 .SH バグ
69 \fBprofil\fP()  は \fBITIMER_PROF\fP インターバルタイマーも使用しているプログラムでは使用できない
70 (\fBsetitimer\fP(2)  参照)。
71
72 本当のカーネルプロファイルはより正確な結果を与える。 libc 4.4 にはシステムコール profil を提供するための
73 カーネルパッチが含まれていた。
74 .SH 関連項目
75 \fBgprof\fP(1), \fBsprof\fP(1), \fBsetitimer\fP(2), \fBsigaction\fP(2), \fBsignal\fP(2)
76 .SH この文書について
77 この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.79 の一部である。
78 プロジェクトの説明とバグ報告に関する情報は \%http://www.kernel.org/doc/man\-pages/ に書かれている。