OSDN Git Service

(split) LDP: Translate memory related pages
[linuxjm/LDP_man-pages.git] / po4a / memory / po / ja.po
1 # SOME DESCRIPTIVE TITLE
2 # Copyright (C) YEAR Free Software Foundation, Inc.
3 # This file is distributed under the same license as the PACKAGE package.
4 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5 #
6 msgid ""
7 msgstr ""
8 "Project-Id-Version: PACKAGE VERSION\n"
9 "POT-Creation-Date: 2014-04-24 00:51+0900\n"
10 "PO-Revision-Date: 2014-04-27 07:57+0900\n"
11 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
12 "Language-Team: LANGUAGE <LL@li.org>\n"
13 "Language: \n"
14 "MIME-Version: 1.0\n"
15 "Content-Type: text/plain; charset=UTF-8\n"
16 "Content-Transfer-Encoding: 8bit\n"
17
18 #. type: TH
19 #: build/C/man2/alloc_hugepages.2:25
20 #, no-wrap
21 msgid "ALLOC_HUGEPAGES"
22 msgstr "ALLOC_HUGEPAGES"
23
24 #. type: TH
25 #: build/C/man2/alloc_hugepages.2:25
26 #, no-wrap
27 msgid "2007-05-31"
28 msgstr "2007-05-31"
29
30 #. type: TH
31 #: build/C/man2/alloc_hugepages.2:25 build/C/man2/cacheflush.2:25
32 #: build/C/man2/fallocate.2:11 build/C/man2/madvise.2:35
33 #: build/C/man3/mallinfo.3:26 build/C/man3/malloc_stats.3:26
34 #: build/C/man3/malloc_trim.3:26 build/C/man3/mallopt.3:26
35 #: build/C/man2/mlock.2:26 build/C/man2/mmap.2:40 build/C/man2/mmap2.2:29
36 #: build/C/man2/mprotect.2:38 build/C/man2/mremap.2:30 build/C/man2/msync.2:25
37 #: build/C/man2/posix_fadvise.2:28 build/C/man2/readahead.2:28
38 #: build/C/man2/remap_file_pages.2:28 build/C/man3/shm_open.3:26
39 #: build/C/man7/shm_overview.7:27 build/C/man2/shmctl.2:45
40 #: build/C/man2/shmget.2:38 build/C/man2/shmop.2:41
41 #: build/C/man2/subpage_prot.2:30 build/C/man2/sync_file_range.2:30
42 #, no-wrap
43 msgid "Linux"
44 msgstr "Linux"
45
46 #. type: TH
47 #: build/C/man2/alloc_hugepages.2:25 build/C/man3/alloca.3:43
48 #: build/C/man2/cacheflush.2:25 build/C/man2/fallocate.2:11
49 #: build/C/man2/madvise.2:35 build/C/man3/mallinfo.3:26
50 #: build/C/man3/malloc_get_state.3:25 build/C/man3/malloc_hook.3:10
51 #: build/C/man3/malloc_info.3:25 build/C/man3/malloc_stats.3:26
52 #: build/C/man3/malloc_trim.3:26 build/C/man3/malloc_usable_size.3:25
53 #: build/C/man3/mallopt.3:26 build/C/man3/mcheck.3:25 build/C/man2/mlock.2:26
54 #: build/C/man2/mmap.2:40 build/C/man2/mmap2.2:29 build/C/man2/mprotect.2:38
55 #: build/C/man2/mremap.2:30 build/C/man2/msync.2:25 build/C/man3/mtrace.3:25
56 #: build/C/man2/posix_fadvise.2:28 build/C/man3/posix_fallocate.3:25
57 #: build/C/man3/posix_memalign.3:29 build/C/man2/readahead.2:28
58 #: build/C/man2/remap_file_pages.2:28 build/C/man3/shm_open.3:26
59 #: build/C/man7/shm_overview.7:27 build/C/man2/shmctl.2:45
60 #: build/C/man2/shmget.2:38 build/C/man2/shmop.2:41
61 #: build/C/man2/subpage_prot.2:30 build/C/man2/sync_file_range.2:30
62 #, no-wrap
63 msgid "Linux Programmer's Manual"
64 msgstr "Linux Programmer's Manual"
65
66 #. type: SH
67 #: build/C/man2/alloc_hugepages.2:26 build/C/man3/alloca.3:44
68 #: build/C/man2/cacheflush.2:26 build/C/man2/fallocate.2:12
69 #: build/C/man2/madvise.2:36 build/C/man3/mallinfo.3:27
70 #: build/C/man3/malloc_get_state.3:26 build/C/man3/malloc_hook.3:11
71 #: build/C/man3/malloc_info.3:26 build/C/man3/malloc_stats.3:27
72 #: build/C/man3/malloc_trim.3:27 build/C/man3/malloc_usable_size.3:26
73 #: build/C/man3/mallopt.3:27 build/C/man3/mcheck.3:26 build/C/man2/mlock.2:27
74 #: build/C/man2/mmap.2:41 build/C/man2/mmap2.2:30 build/C/man2/mprotect.2:39
75 #: build/C/man2/mremap.2:31 build/C/man2/msync.2:26 build/C/man3/mtrace.3:26
76 #: build/C/man2/posix_fadvise.2:29 build/C/man3/posix_fallocate.3:26
77 #: build/C/man3/posix_memalign.3:30 build/C/man2/readahead.2:29
78 #: build/C/man2/remap_file_pages.2:29 build/C/man3/shm_open.3:27
79 #: build/C/man7/shm_overview.7:28 build/C/man2/shmctl.2:46
80 #: build/C/man2/shmget.2:39 build/C/man2/shmop.2:42
81 #: build/C/man2/subpage_prot.2:31 build/C/man2/sync_file_range.2:31
82 #, no-wrap
83 msgid "NAME"
84 msgstr "名前"
85
86 #. type: Plain text
87 #: build/C/man2/alloc_hugepages.2:28
88 msgid "alloc_hugepages, free_hugepages - allocate or free huge pages"
89 msgstr ""
90 "alloc_hugepages, free_hugepages - 大きなサイズのページの割り当てと解放を行う"
91
92 #. type: SH
93 #: build/C/man2/alloc_hugepages.2:28 build/C/man3/alloca.3:46
94 #: build/C/man2/cacheflush.2:28 build/C/man2/fallocate.2:14
95 #: build/C/man2/madvise.2:38 build/C/man3/mallinfo.3:29
96 #: build/C/man3/malloc_get_state.3:28 build/C/man3/malloc_hook.3:15
97 #: build/C/man3/malloc_info.3:28 build/C/man3/malloc_stats.3:29
98 #: build/C/man3/malloc_trim.3:29 build/C/man3/malloc_usable_size.3:28
99 #: build/C/man3/mallopt.3:29 build/C/man3/mcheck.3:28 build/C/man2/mlock.2:29
100 #: build/C/man2/mmap.2:43 build/C/man2/mmap2.2:32 build/C/man2/mprotect.2:41
101 #: build/C/man2/mremap.2:33 build/C/man2/msync.2:28 build/C/man3/mtrace.3:28
102 #: build/C/man2/posix_fadvise.2:31 build/C/man3/posix_fallocate.3:28
103 #: build/C/man3/posix_memalign.3:32 build/C/man2/readahead.2:31
104 #: build/C/man2/remap_file_pages.2:31 build/C/man3/shm_open.3:29
105 #: build/C/man2/shmctl.2:48 build/C/man2/shmget.2:41 build/C/man2/shmop.2:44
106 #: build/C/man2/subpage_prot.2:33 build/C/man2/sync_file_range.2:33
107 #, no-wrap
108 msgid "SYNOPSIS"
109 msgstr "書式"
110
111 #.  asmlinkage unsigned long sys_alloc_hugepages(int key, unsigned long addr,
112 #.  unsigned long len, int prot, int flag);
113 #. type: Plain text
114 #: build/C/man2/alloc_hugepages.2:34
115 #, no-wrap
116 msgid ""
117 "B<void *alloc_hugepages(int >I<key>B<, void *>I<addr>B<, size_t >I<len>B<,>\n"
118 "B<                      int >I<prot>B<, int >I<flag>B<);>\n"
119 msgstr ""
120 "B<void *alloc_hugepages(int >I<key>B<, void *>I<addr>B<, size_t >I<len>B<,>\n"
121 "B<                      int >I<prot>B<, int >I<flag>B<);>\n"
122
123 #.  asmlinkage int sys_free_hugepages(unsigned long addr);
124 #. type: Plain text
125 #: build/C/man2/alloc_hugepages.2:37
126 #, no-wrap
127 msgid "B<int free_hugepages(void *>I<addr>B<);>\n"
128 msgstr "B<int free_hugepages(void *>I<addr>B<);>\n"
129
130 #. type: SH
131 #: build/C/man2/alloc_hugepages.2:38 build/C/man3/alloca.3:50
132 #: build/C/man2/cacheflush.2:34 build/C/man2/fallocate.2:22
133 #: build/C/man2/madvise.2:50 build/C/man3/mallinfo.3:33
134 #: build/C/man3/malloc_get_state.3:36 build/C/man3/malloc_hook.3:33
135 #: build/C/man3/malloc_info.3:34 build/C/man3/malloc_stats.3:33
136 #: build/C/man3/malloc_trim.3:33 build/C/man3/malloc_usable_size.3:32
137 #: build/C/man3/mallopt.3:33 build/C/man3/mcheck.3:40 build/C/man2/mlock.2:39
138 #: build/C/man2/mmap.2:54 build/C/man2/mmap2.2:39 build/C/man2/mprotect.2:47
139 #: build/C/man2/mremap.2:42 build/C/man2/msync.2:32 build/C/man3/mtrace.3:34
140 #: build/C/man2/posix_fadvise.2:50 build/C/man3/posix_fallocate.3:46
141 #: build/C/man3/posix_memalign.3:84 build/C/man2/readahead.2:38
142 #: build/C/man2/remap_file_pages.2:39 build/C/man3/shm_open.3:41
143 #: build/C/man7/shm_overview.7:30 build/C/man2/shmctl.2:56
144 #: build/C/man2/shmget.2:49 build/C/man2/shmop.2:53
145 #: build/C/man2/subpage_prot.2:41 build/C/man2/sync_file_range.2:41
146 #, no-wrap
147 msgid "DESCRIPTION"
148 msgstr "説明"
149
150 #. type: Plain text
151 #: build/C/man2/alloc_hugepages.2:49
152 msgid ""
153 "The system calls B<alloc_hugepages>()  and B<free_hugepages>()  were "
154 "introduced in Linux 2.5.36 and removed again in 2.5.54.  They existed only "
155 "on i386 and ia64 (when built with B<CONFIG_HUGETLB_PAGE>).  In Linux 2.4.20 "
156 "the syscall numbers exist, but the calls fail with the error B<ENOSYS>."
157 msgstr ""
158 "システムコール B<alloc_hugepages>()  と B<free_hugepages>()  は Linux 2.5.36 "
159 "で導入され、2.5.54 で再び削除された。 これらのシステムコールは i386 と ia64 "
160 "のみで (かつ B<CONFIG_HUGETLB_PAGE> を指定してビルドされた場合に) 存在する。 "
161 "Linux 2.4.20 では syscall 番号が存在するが、 呼び出すとエラー B<ENOSYS> で失"
162 "敗する。"
163
164 #. type: Plain text
165 #: build/C/man2/alloc_hugepages.2:57
166 msgid ""
167 "On i386 the memory management hardware knows about ordinary pages (4 KiB)  "
168 "and huge pages (2 or 4 MiB).  Similarly ia64 knows about huge pages of "
169 "several sizes.  These system calls serve to map huge pages into the "
170 "process's memory or to free them again.  Huge pages are locked into memory, "
171 "and are not swapped."
172 msgstr ""
173 "i386 では、メモリ管理ハードウェアは通常のページ (4 KiB) と 大きなサイズのペー"
174 "ジ (以下、ヒュージページ; 2MiB または 4 MiB) を 扱うことができる。 同様に、"
175 "ia64 もいくつかのサイズのヒュージページを扱うことができる。 これらのシステム"
176 "コールは、ヒュージページをプロセスのメモリにマップしたり、 再び解放したりす"
177 "る。 ヒュージページはメモリ内にロックされ、スワップされない。"
178
179 #. type: Plain text
180 #: build/C/man2/alloc_hugepages.2:66
181 msgid ""
182 "The I<key> argument is an identifier.  When zero the pages are private, and "
183 "not inherited by children.  When positive the pages are shared with other "
184 "applications using the same I<key>, and inherited by child processes."
185 msgstr ""
186 "I<key> 引き数は識別子である。 0 の場合、ページは非公開になり、子プロセスに継"
187 "承されない。 正の場合、ページは同じ I<key> を使う他のアプリケーションと共有さ"
188 "れ、子プロセスに継承される。"
189
190 #. type: Plain text
191 #: build/C/man2/alloc_hugepages.2:81
192 msgid ""
193 "The I<addr> argument of B<free_hugepages>()  tells which page is being "
194 "freed: it was the return value of a call to B<alloc_hugepages>().  (The "
195 "memory is first actually freed when all users have released it.)  The "
196 "I<addr> argument of B<alloc_hugepages>()  is a hint, that the kernel may or "
197 "may not follow.  Addresses must be properly aligned."
198 msgstr ""
199 "B<free_hugepages>()  の I<addr> 引き数は、どのページを解放するかを指定する: "
200 "I<addr> は B<alloc_hugepages>()  の呼び出しの返り値である (全てのユーザがメモ"
201 "リを解放したときに、 そのメモリは初めて実際に解放される)。 B<alloc_hugepages>"
202 "()  の I<addr> 引き数はヒントであり、カーネルはそれに従うかもしれないし、 従"
203 "わないかもしれない。 アドレスは正しく配置されなければならない。"
204
205 #. type: Plain text
206 #: build/C/man2/alloc_hugepages.2:86
207 msgid ""
208 "The I<len> argument is the length of the required segment.  It must be a "
209 "multiple of the huge page size."
210 msgstr ""
211 "I<len> 引き数は要求されたセグメントの長さである。 これはヒュージページのサイ"
212 "ズの倍数にしなければならない。"
213
214 #. type: Plain text
215 #: build/C/man2/alloc_hugepages.2:94
216 msgid ""
217 "The I<prot> argument specifies the memory protection of the segment.  It is "
218 "one of B<PROT_READ>, B<PROT_WRITE>, B<PROT_EXEC>."
219 msgstr ""
220 "I<prot> 引き数はセグメントのメモリ保護を指定する。 これは B<PROT_READ>, "
221 "B<PROT_WRITE>, B<PROT_EXEC> のいずれかである。"
222
223 #. type: Plain text
224 #: build/C/man2/alloc_hugepages.2:109
225 msgid ""
226 "The I<flag> argument is ignored, unless I<key> is positive.  In that case, "
227 "if I<flag> is B<IPC_CREAT>, then a new huge page segment is created when "
228 "none with the given key existed.  If this flag is not set, then B<ENOENT> is "
229 "returned when no segment with the given key exists."
230 msgstr ""
231 "I<key> が正でない限り、 I<flag> 引き数は無視される。 I<key> が正で、かつ "
232 "I<flag> が B<IPC_CREAT> であり、かつ指定された I<key> で (セグメントが) 何も"
233 "存在しない場合、 新しいヒュージページセグメントが作成される。 I<flag> が設定"
234 "されておらず、かつ指定された I<key> のセグメントが存在しない場合、 B<ENOENT> "
235 "が返される。"
236
237 #. type: SH
238 #: build/C/man2/alloc_hugepages.2:109 build/C/man3/alloca.3:60
239 #: build/C/man2/cacheflush.2:53 build/C/man2/fallocate.2:183
240 #: build/C/man2/madvise.2:268 build/C/man3/malloc_get_state.3:61
241 #: build/C/man3/malloc_info.3:48 build/C/man3/malloc_trim.3:51
242 #: build/C/man3/malloc_usable_size.3:40 build/C/man3/mallopt.3:379
243 #: build/C/man3/mcheck.3:129 build/C/man2/mlock.2:116 build/C/man2/mmap.2:375
244 #: build/C/man2/mmap2.2:54 build/C/man2/mprotect.2:78
245 #: build/C/man2/mremap.2:127 build/C/man2/msync.2:68
246 #: build/C/man2/posix_fadvise.2:87 build/C/man3/posix_fallocate.3:66
247 #: build/C/man3/posix_memalign.3:142 build/C/man2/readahead.2:66
248 #: build/C/man2/remap_file_pages.2:124 build/C/man3/shm_open.3:171
249 #: build/C/man2/shmctl.2:283 build/C/man2/shmget.2:180
250 #: build/C/man2/shmop.2:171 build/C/man2/subpage_prot.2:66
251 #: build/C/man2/sync_file_range.2:141
252 #, no-wrap
253 msgid "RETURN VALUE"
254 msgstr "返り値"
255
256 #. type: Plain text
257 #: build/C/man2/alloc_hugepages.2:118
258 msgid ""
259 "On success, B<alloc_hugepages>()  returns the allocated virtual address, and "
260 "B<free_hugepages>()  returns zero.  On error, -1 is returned, and I<errno> "
261 "is set appropriately."
262 msgstr ""
263 "成功した場合、 B<alloc_hugepages>()  は割り当てられた仮想アドレスを返し、 "
264 "B<free_hugepages>()  は 0 を返す。 失敗した場合、-1 を返し、 I<errno> が適切"
265 "に設定される。"
266
267 #. type: SH
268 #: build/C/man2/alloc_hugepages.2:118 build/C/man2/cacheflush.2:59
269 #: build/C/man2/fallocate.2:190 build/C/man2/madvise.2:275
270 #: build/C/man3/malloc_info.3:55 build/C/man3/malloc_trim.3:56
271 #: build/C/man3/mallopt.3:384 build/C/man2/mlock.2:122 build/C/man2/mmap.2:392
272 #: build/C/man2/mmap2.2:61 build/C/man2/mprotect.2:85
273 #: build/C/man2/mremap.2:135 build/C/man2/msync.2:73
274 #: build/C/man2/posix_fadvise.2:90 build/C/man3/posix_fallocate.3:72
275 #: build/C/man3/posix_memalign.3:157 build/C/man2/readahead.2:72
276 #: build/C/man2/remap_file_pages.2:131 build/C/man3/shm_open.3:180
277 #: build/C/man2/shmctl.2:305 build/C/man2/shmget.2:185
278 #: build/C/man2/shmop.2:185 build/C/man2/subpage_prot.2:71
279 #: build/C/man2/sync_file_range.2:147
280 #, no-wrap
281 msgid "ERRORS"
282 msgstr "エラー"
283
284 #. type: TP
285 #: build/C/man2/alloc_hugepages.2:119 build/C/man2/fallocate.2:270
286 #, no-wrap
287 msgid "B<ENOSYS>"
288 msgstr "B<ENOSYS>"
289
290 #. type: Plain text
291 #: build/C/man2/alloc_hugepages.2:122
292 msgid "The system call is not supported on this kernel."
293 msgstr "このシステムコールはカーネルでサポートされていない。"
294
295 #. type: SH
296 #: build/C/man2/alloc_hugepages.2:122
297 #, no-wrap
298 msgid "FILES"
299 msgstr "ファイル"
300
301 #. type: Plain text
302 #: build/C/man2/alloc_hugepages.2:126
303 msgid ""
304 "I</proc/sys/vm/nr_hugepages> Number of configured hugetlb pages.  This can "
305 "be read and written."
306 msgstr ""
307 "I</proc/sys/vm/nr_hugepages> 設定された hugetlb ページの数。 このファイルは読"
308 "み書きできる。"
309
310 #. type: Plain text
311 #: build/C/man2/alloc_hugepages.2:130
312 msgid ""
313 "I</proc/meminfo> Gives info on the number of configured hugetlb pages and on "
314 "their size in the three variables HugePages_Total, HugePages_Free, "
315 "Hugepagesize."
316 msgstr ""
317 "I</proc/meminfo> 設定された hugetlb ページの数と、 3 つの変数 "
318 "HugePages_Total, HugePages_Free, Hugepagesize の サイズについての情報を提供す"
319 "る。"
320
321 #. type: SH
322 #: build/C/man2/alloc_hugepages.2:130 build/C/man3/alloca.3:70
323 #: build/C/man2/cacheflush.2:75 build/C/man2/fallocate.2:321
324 #: build/C/man2/madvise.2:325 build/C/man3/mallinfo.3:110
325 #: build/C/man3/malloc_get_state.3:86 build/C/man3/malloc_hook.3:80
326 #: build/C/man3/malloc_info.3:63 build/C/man3/malloc_stats.3:55
327 #: build/C/man3/malloc_trim.3:60 build/C/man3/malloc_usable_size.3:48
328 #: build/C/man3/mallopt.3:392 build/C/man3/mcheck.3:145
329 #: build/C/man2/mlock.2:186 build/C/man2/mmap.2:495 build/C/man2/mmap2.2:77
330 #: build/C/man2/mprotect.2:113 build/C/man2/mremap.2:185
331 #: build/C/man2/msync.2:96 build/C/man3/mtrace.3:78
332 #: build/C/man2/posix_fadvise.2:112 build/C/man3/posix_fallocate.3:103
333 #: build/C/man3/posix_memalign.3:182 build/C/man2/readahead.2:88
334 #: build/C/man2/remap_file_pages.2:153 build/C/man3/shm_open.3:251
335 #: build/C/man7/shm_overview.7:101 build/C/man2/shmctl.2:377
336 #: build/C/man2/shmget.2:232 build/C/man2/shmop.2:231
337 #: build/C/man2/subpage_prot.2:96 build/C/man2/sync_file_range.2:180
338 #, no-wrap
339 msgid "CONFORMING TO"
340 msgstr "準拠"
341
342 #. type: Plain text
343 #: build/C/man2/alloc_hugepages.2:133
344 msgid ""
345 "These calls are specific to Linux on Intel processors, and should not be "
346 "used in programs intended to be portable."
347 msgstr ""
348 "このシステムコールは Intel プロセッサ上の Linux に固有のものであり、 移植性が"
349 "必要なプログラムで使うべきでない。"
350
351 #. type: SH
352 #: build/C/man2/alloc_hugepages.2:133 build/C/man3/alloca.3:78
353 #: build/C/man2/madvise.2:347 build/C/man3/malloc_get_state.3:88
354 #: build/C/man3/malloc_hook.3:82 build/C/man3/malloc_info.3:65
355 #: build/C/man3/malloc_stats.3:57 build/C/man3/malloc_trim.3:62
356 #: build/C/man3/malloc_usable_size.3:50 build/C/man3/mcheck.3:147
357 #: build/C/man2/mlock.2:213 build/C/man2/mmap.2:513 build/C/man2/mmap2.2:79
358 #: build/C/man2/mprotect.2:122 build/C/man2/mremap.2:191
359 #: build/C/man2/msync.2:120 build/C/man3/mtrace.3:80
360 #: build/C/man2/posix_fadvise.2:121 build/C/man3/posix_memalign.3:221
361 #: build/C/man2/readahead.2:93 build/C/man3/shm_open.3:257
362 #: build/C/man7/shm_overview.7:103 build/C/man2/shmctl.2:382
363 #: build/C/man2/shmget.2:238 build/C/man2/shmop.2:250
364 #: build/C/man2/subpage_prot.2:98 build/C/man2/sync_file_range.2:183
365 #, no-wrap
366 msgid "NOTES"
367 msgstr "注意"
368
369 #. type: Plain text
370 #: build/C/man2/alloc_hugepages.2:141
371 msgid ""
372 "These system calls are gone; they existed only in Linux 2.5.36 through to "
373 "2.5.54.  Now the hugetlbfs filesystem can be used instead.  Memory backed by "
374 "huge pages (if the CPU supports them) is obtained by using B<mmap>(2)  to "
375 "map files in this virtual filesystem."
376 msgstr ""
377 "これらのシステムコールはなくなった。 これらは Linux 2.5.36 から 2.5.54 にのみ"
378 "存在する。 代わりに今は hugetlbfs ファイルシステムを使うことができる。 (CPU "
379 "がサポートしている場合) ヒュージページを持つメモリは、 B<mmap>(2)  を使ってこ"
380 "の仮想ファイルシステムでファイルをマップすることで取得できる。"
381
382 #. type: Plain text
383 #: build/C/man2/alloc_hugepages.2:145
384 msgid ""
385 "The maximal number of huge pages can be specified using the B<hugepages=> "
386 "boot parameter."
387 msgstr ""
388 "ヒュージページの最大数は、 B<hugepages=> 起動パラメータを使って指定できる。"
389
390 #. type: SH
391 #: build/C/man2/alloc_hugepages.2:150 build/C/man3/alloca.3:162
392 #: build/C/man2/cacheflush.2:89 build/C/man2/fallocate.2:329
393 #: build/C/man2/madvise.2:381 build/C/man3/mallinfo.3:279
394 #: build/C/man3/malloc_get_state.3:114 build/C/man3/malloc_hook.3:142
395 #: build/C/man3/malloc_info.3:262 build/C/man3/malloc_stats.3:67
396 #: build/C/man3/malloc_trim.3:82 build/C/man3/malloc_usable_size.3:64
397 #: build/C/man3/mallopt.3:580 build/C/man3/mcheck.3:208
398 #: build/C/man2/mlock.2:343 build/C/man2/mmap.2:735 build/C/man2/mmap2.2:101
399 #: build/C/man2/mprotect.2:229 build/C/man2/mremap.2:214
400 #: build/C/man2/msync.2:151 build/C/man3/mtrace.3:172
401 #: build/C/man2/posix_fadvise.2:197 build/C/man3/posix_fallocate.3:133
402 #: build/C/man3/posix_memalign.3:277 build/C/man2/readahead.2:113
403 #: build/C/man2/remap_file_pages.2:164 build/C/man3/shm_open.3:282
404 #: build/C/man7/shm_overview.7:127 build/C/man2/shmctl.2:435
405 #: build/C/man2/shmget.2:325 build/C/man2/shmop.2:295
406 #: build/C/man2/subpage_prot.2:134 build/C/man2/sync_file_range.2:226
407 #, no-wrap
408 msgid "COLOPHON"
409 msgstr "この文書について"
410
411 #. type: Plain text
412 #: build/C/man2/alloc_hugepages.2:157 build/C/man3/alloca.3:169
413 #: build/C/man2/cacheflush.2:96 build/C/man2/fallocate.2:336
414 #: build/C/man2/madvise.2:388 build/C/man3/mallinfo.3:286
415 #: build/C/man3/malloc_get_state.3:121 build/C/man3/malloc_hook.3:149
416 #: build/C/man3/malloc_info.3:269 build/C/man3/malloc_stats.3:74
417 #: build/C/man3/malloc_trim.3:89 build/C/man3/malloc_usable_size.3:71
418 #: build/C/man3/mallopt.3:587 build/C/man3/mcheck.3:215
419 #: build/C/man2/mlock.2:350 build/C/man2/mmap.2:742 build/C/man2/mmap2.2:108
420 #: build/C/man2/mprotect.2:236 build/C/man2/mremap.2:221
421 #: build/C/man2/msync.2:158 build/C/man3/mtrace.3:179
422 #: build/C/man2/posix_fadvise.2:204 build/C/man3/posix_fallocate.3:140
423 #: build/C/man3/posix_memalign.3:284 build/C/man2/readahead.2:120
424 #: build/C/man2/remap_file_pages.2:171 build/C/man3/shm_open.3:289
425 #: build/C/man7/shm_overview.7:134 build/C/man2/shmctl.2:442
426 #: build/C/man2/shmget.2:332 build/C/man2/shmop.2:302
427 #: build/C/man2/subpage_prot.2:141 build/C/man2/sync_file_range.2:233
428 msgid ""
429 "This page is part of release 3.65 of the Linux I<man-pages> project.  A "
430 "description of the project, and information about reporting bugs, can be "
431 "found at \\%http://www.kernel.org/doc/man-pages/."
432 msgstr ""
433 "この man ページは Linux I<man-pages> プロジェクトのリリース 3.65 の一部\n"
434 "である。プロジェクトの説明とバグ報告に関する情報は\n"
435 "http://www.kernel.org/doc/man-pages/ に書かれている。"
436
437 #. type: TH
438 #: build/C/man3/alloca.3:43
439 #, no-wrap
440 msgid "ALLOCA"
441 msgstr "ALLOCA"
442
443 #. type: TH
444 #: build/C/man3/alloca.3:43
445 #, no-wrap
446 msgid "2013-10-07"
447 msgstr "2013-10-07"
448
449 #. type: TH
450 #: build/C/man3/alloca.3:43 build/C/man3/malloc_get_state.3:25
451 #: build/C/man3/malloc_hook.3:10 build/C/man3/malloc_info.3:25
452 #: build/C/man3/malloc_usable_size.3:25 build/C/man3/mcheck.3:25
453 #: build/C/man3/mtrace.3:25 build/C/man3/posix_fallocate.3:25
454 #: build/C/man3/posix_memalign.3:29
455 #, no-wrap
456 msgid "GNU"
457 msgstr "GNU"
458
459 #. type: Plain text
460 #: build/C/man3/alloca.3:46
461 msgid "alloca - allocate memory that is automatically freed"
462 msgstr "alloca - 自動的に解放されるメモリを割り当てる"
463
464 #. type: Plain text
465 #: build/C/man3/alloca.3:48
466 msgid "B<#include E<lt>alloca.hE<gt>>"
467 msgstr "B<#include E<lt>alloca.hE<gt>>"
468
469 #. type: Plain text
470 #: build/C/man3/alloca.3:50
471 msgid "B<void *alloca(size_t >I<size>B<);>"
472 msgstr "B<void *alloca(size_t >I<size>B<);>"
473
474 #. type: Plain text
475 #: build/C/man3/alloca.3:60
476 msgid ""
477 "The B<alloca>()  function allocates I<size> bytes of space in the stack "
478 "frame of the caller.  This temporary space is automatically freed when the "
479 "function that called B<alloca>()  returns to its caller."
480 msgstr ""
481 "B<alloca>()  関数は、 I<size> バイトの領域を呼出元のスタック・フレームに割り"
482 "付ける。 この一時的な領域は、 B<alloca>()  を呼び出した関数が呼出元に返るとき"
483 "に自動的に解放される。"
484
485 #. type: Plain text
486 #: build/C/man3/alloca.3:65
487 msgid ""
488 "The B<alloca>()  function returns a pointer to the beginning of the "
489 "allocated space.  If the allocation causes stack overflow, program behavior "
490 "is undefined."
491 msgstr ""
492 "B<alloca>()  関数は、割り付けた領域の始まりを指すポインタを返す。 割り付けに"
493 "よってスタックオーバーフローが起った場合の プログラムの動作は定義されていな"
494 "い。"
495
496 #. type: SH
497 #: build/C/man3/alloca.3:65
498 #, no-wrap
499 msgid "ATTRIBUTES"
500 msgstr "属性"
501
502 #. type: SS
503 #: build/C/man3/alloca.3:66
504 #, no-wrap
505 msgid "Multithreading (see pthreads(7))"
506 msgstr "マルチスレッディング (pthreads(7) 参照)"
507
508 #. type: Plain text
509 #: build/C/man3/alloca.3:70
510 msgid "The B<alloca>()  function is thread-safe."
511 msgstr "B<alloca>() 関数はスレッドセーフである。"
512
513 #. type: Plain text
514 #: build/C/man3/alloca.3:72
515 msgid "This function is not in POSIX.1-2001."
516 msgstr "この関数は POSIX.1-2001 にはない。"
517
518 #. type: Plain text
519 #: build/C/man3/alloca.3:78
520 msgid ""
521 "There is evidence that the B<alloca>()  function appeared in 32V, PWB, "
522 "PWB.2, 3BSD, and 4BSD.  There is a man page for it in 4.3BSD.  Linux uses "
523 "the GNU version."
524 msgstr ""
525 "32V, PWB, PWB.2, 3BSD, 4BSD に B<alloca>()  関数が登場した証拠がある。 "
526 "4.3BSD には、マニュアルページがある。 Linux は、GNU 版を使っている。 この関数"
527 "は POSIX.1-2001 にはない。"
528
529 #. type: Plain text
530 #: build/C/man3/alloca.3:93
531 msgid ""
532 "The B<alloca>()  function is machine- and compiler-dependent.  For certain "
533 "applications, its use can improve efficiency compared to the use of B<malloc>"
534 "(3)  plus B<free>(3).  In certain cases, it can also simplify memory "
535 "deallocation in applications that use B<longjmp>(3)  or B<siglongjmp>(3).  "
536 "Otherwise, its use is discouraged."
537 msgstr ""
538 "B<alloca>()  関数は、機種とコンパイラに依存する。 特定のアプリケーションで"
539 "は、この関数を使うと B<malloc>(3)  と B<free>(3)  を組み合わせて使った場合に"
540 "比べて効率を改善することができる。 特定の場合では、この関数を使うことで、 "
541 "B<longjmp>(3)  や B<siglongjmp>(3)  を使うアプリケーションでのメモリの開放を"
542 "簡単にすることができる。 それ以外の場合では、この関数の使用は推奨されない。"
543
544 #. type: Plain text
545 #: build/C/man3/alloca.3:102
546 msgid ""
547 "Because the space allocated by B<alloca>()  is allocated within the stack "
548 "frame, that space is automatically freed if the function return is jumped "
549 "over by a call to B<longjmp>(3)  or B<siglongjmp>(3)."
550 msgstr ""
551 "B<alloca>()  により割り当てられる空間はスタックフレームから割り当てらるの"
552 "で、 関数の戻り先が B<longjmp>(3)  や B<siglongjmp>(3)  の呼び出しによりジャ"
553 "ンプした場合には、 割り当てられた空間は自動的に解放される。"
554
555 #. type: Plain text
556 #: build/C/man3/alloca.3:107
557 msgid "Do not attempt to B<free>(3)  space allocated by B<alloca>()!"
558 msgstr ""
559 "B<alloca>()  で割り当てられた空間を B<free>(3)  しようとすることのないよう"
560 "に!"
561
562 #. type: SS
563 #: build/C/man3/alloca.3:107
564 #, no-wrap
565 msgid "Notes on the GNU version"
566 msgstr "GNU 版についての注意"
567
568 #. type: Plain text
569 #: build/C/man3/alloca.3:129
570 msgid ""
571 "Normally, B<gcc>(1)  translates calls to B<alloca>()  with inlined code.  "
572 "This is not done when either the I<-ansi>, I<-std=c89>, I<-std=c99>, or the "
573 "I<-std=c11> option is given B<and> the header I<E<lt>alloca.hE<gt>> is not "
574 "included.  Otherwise (without an -ansi or -std=c* option) the glibc version "
575 "of I<E<lt>stdlib.hE<gt>> includes I<E<lt>alloca.hE<gt>> and that contains "
576 "the lines:"
577 msgstr ""
578 "通常 B<gcc>(1) は B<alloca>()  の呼び出しをインラインコードに変換する。 I<-"
579 "ansi>, I<-std=c89>, I<-std=c99>, I<-std=c11> のいずれかのオプションが指定さ"
580 "れ、B<かつ> I<E<lt>alloca.hE<gt>> がインクルードされていない場合、 この変換は"
581 "行われない。 それ以外の場合 (-ansi オプションも -std=c* オプションも指定され"
582 "ない場合) には、 glibc 版の I<E<lt>stdlib.hE<gt>> は I<E<lt>alloca.hE<gt>> を"
583 "インクルードするが、このファイルには以下の行が含まれており、"
584
585 #. type: Plain text
586 #: build/C/man3/alloca.3:134
587 #, no-wrap
588 msgid ""
589 "    #ifdef  __GNUC__\n"
590 "    #define alloca(size)   __builtin_alloca (size)\n"
591 "    #endif\n"
592 msgstr ""
593 "    #ifdef  __GNUC__\n"
594 "    #define alloca(size)   __builtin_alloca (size)\n"
595 "    #endif\n"
596
597 #. type: Plain text
598 #: build/C/man3/alloca.3:137
599 msgid "with messy consequences if one has a private version of this function."
600 msgstr "独自版の __builtin_alloca (size) 関数がある場合、厄介な結果になる。"
601
602 #. type: Plain text
603 #: build/C/man3/alloca.3:141
604 msgid ""
605 "The fact that the code is inlined means that it is impossible to take the "
606 "address of this function, or to change its behavior by linking with a "
607 "different library."
608 msgstr ""
609 "このコードはインライン化されているので、 この関数のアドレスを取得したり、 他"
610 "のライブラリをリンクして動作を変更することはできない。"
611
612 #. type: Plain text
613 #: build/C/man3/alloca.3:145
614 msgid ""
615 "The inlined code often consists of a single instruction adjusting the stack "
616 "pointer, and does not check for stack overflow.  Thus, there is no NULL "
617 "error return."
618 msgstr ""
619 "通常このインラインコードはスタックポインタを移動する 1 つの命令 "
620 "(instruction) から構成されており、 スタックオーバーフローをチェックしない。 "
621 "よって NULL エラーが返されることはない。"
622
623 #. type: SH
624 #: build/C/man3/alloca.3:145 build/C/man2/cacheflush.2:82
625 #: build/C/man3/mallinfo.3:114 build/C/man3/mallopt.3:406
626 #: build/C/man2/mlock.2:311 build/C/man2/mmap.2:585 build/C/man3/mtrace.3:102
627 #: build/C/man2/posix_fadvise.2:186 build/C/man2/readahead.2:98
628 #: build/C/man2/shmget.2:311
629 #, no-wrap
630 msgid "BUGS"
631 msgstr "バグ"
632
633 #. type: Plain text
634 #: build/C/man3/alloca.3:150
635 msgid ""
636 "There is no error indication if the stack frame cannot be extended.  "
637 "(However, after a failed allocation, the program is likely to receive a "
638 "B<SIGSEGV> signal if it attempts to access the unallocated space.)"
639 msgstr ""
640 "スタックフレームが拡張できなかった場合、エラー通知は行われない。 (しかしなが"
641 "ら、割り当てに失敗した後で、プログラムが割り当てられなかった 空間にアクセスし"
642 "ようとした場合に B<SIGSEGV> シグナルを受信することだろう。)"
643
644 #. type: Plain text
645 #: build/C/man3/alloca.3:158
646 msgid ""
647 "On many systems B<alloca>()  cannot be used inside the list of arguments of "
648 "a function call, because the stack space reserved by B<alloca>()  would "
649 "appear on the stack in the middle of the space for the function arguments."
650 msgstr ""
651 "多くのシステムにおいて、関数コールの引き数のリスト内では B<alloca>()  が使え"
652 "ない。 これは、 B<alloca>()  によって予約されるスタック領域が、 関数引き数に"
653 "使われるスタック領域の中に現れてしまうためである。"
654
655 #. type: SH
656 #: build/C/man3/alloca.3:158 build/C/man2/fallocate.2:324
657 #: build/C/man2/madvise.2:372 build/C/man3/mallinfo.3:270
658 #: build/C/man3/malloc_get_state.3:111 build/C/man3/malloc_hook.3:137
659 #: build/C/man3/malloc_info.3:256 build/C/man3/malloc_stats.3:61
660 #: build/C/man3/malloc_trim.3:78 build/C/man3/malloc_usable_size.3:62
661 #: build/C/man3/mallopt.3:566 build/C/man3/mcheck.3:204
662 #: build/C/man2/mlock.2:336 build/C/man2/mmap.2:710 build/C/man2/mmap2.2:95
663 #: build/C/man2/mprotect.2:226 build/C/man2/mremap.2:199
664 #: build/C/man2/msync.2:147 build/C/man3/mtrace.3:167
665 #: build/C/man2/posix_fadvise.2:191 build/C/man3/posix_fallocate.3:128
666 #: build/C/man3/posix_memalign.3:272 build/C/man2/readahead.2:107
667 #: build/C/man2/remap_file_pages.2:157 build/C/man3/shm_open.3:271
668 #: build/C/man7/shm_overview.7:114 build/C/man2/shmctl.2:428
669 #: build/C/man2/shmget.2:317 build/C/man2/shmop.2:287
670 #: build/C/man2/subpage_prot.2:128 build/C/man2/sync_file_range.2:221
671 #, no-wrap
672 msgid "SEE ALSO"
673 msgstr "関連項目"
674
675 #. type: Plain text
676 #: build/C/man3/alloca.3:162
677 msgid "B<brk>(2), B<longjmp>(3), B<malloc>(3)"
678 msgstr "B<brk>(2), B<longjmp>(3), B<malloc>(3)"
679
680 #. type: TH
681 #: build/C/man2/cacheflush.2:25
682 #, no-wrap
683 msgid "CACHEFLUSH"
684 msgstr "CACHEFLUSH"
685
686 #. type: TH
687 #: build/C/man2/cacheflush.2:25
688 #, no-wrap
689 msgid "2007-05-26"
690 msgstr "2007-05-26"
691
692 #. type: Plain text
693 #: build/C/man2/cacheflush.2:28
694 msgid "cacheflush - flush contents of instruction and/or data cache"
695 msgstr "cacheflush - 命令キャッシュやデータキャッシュの内容をフラッシュする"
696
697 #. type: Plain text
698 #: build/C/man2/cacheflush.2:31
699 #, no-wrap
700 msgid "B<#include E<lt>asm/cachectl.hE<gt>>\n"
701 msgstr "B<#include E<lt>asm/cachectl.hE<gt>>\n"
702
703 #. type: Plain text
704 #: build/C/man2/cacheflush.2:33
705 #, no-wrap
706 msgid "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
707 msgstr "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
708
709 #. type: Plain text
710 #: build/C/man2/cacheflush.2:43
711 msgid ""
712 "B<cacheflush>()  flushes the contents of the indicated cache(s) for the user "
713 "addresses in the range I<addr> to I<(addr+nbytes-1)>.  I<cache> may be one "
714 "of:"
715 msgstr ""
716 "B<cacheflush>()  は I<addr> から I<(addr+nbytes-1)> の範囲のユーザアドレスに"
717 "対応する 指定されたキャッシュをフラッシュする。 I<cache> には以下のいずれかを"
718 "指定する:"
719
720 #. type: TP
721 #: build/C/man2/cacheflush.2:43
722 #, no-wrap
723 msgid "B<ICACHE>"
724 msgstr "B<ICACHE>"
725
726 #. type: Plain text
727 #: build/C/man2/cacheflush.2:46
728 msgid "Flush the instruction cache."
729 msgstr "命令 (instruction) キャッシュをフラッシュする。"
730
731 #. type: TP
732 #: build/C/man2/cacheflush.2:46
733 #, no-wrap
734 msgid "B<DCACHE>"
735 msgstr "B<DCACHE>"
736
737 #. type: Plain text
738 #: build/C/man2/cacheflush.2:49
739 msgid "Write back to memory and invalidate the affected valid cache lines."
740 msgstr "変更があったキャッシュラインをメモリに書き戻し、無効にする。"
741
742 #. type: TP
743 #: build/C/man2/cacheflush.2:49
744 #, no-wrap
745 msgid "B<BCACHE>"
746 msgstr "B<BCACHE>"
747
748 #. type: Plain text
749 #: build/C/man2/cacheflush.2:53
750 msgid "Same as B<(ICACHE|DCACHE)>."
751 msgstr "B<(ICACHE|DCACHE)> と同じ。"
752
753 #. type: Plain text
754 #: build/C/man2/cacheflush.2:59
755 msgid ""
756 "B<cacheflush>()  returns 0 on success or -1 on error.  If errors are "
757 "detected, I<errno> will indicate the error."
758 msgstr ""
759 "B<cacheflush>()  は成功した場合は 0 を、失敗した場合は -1 を返す。エラーが検"
760 "出された場合は I<errno> にエラーが指示される。"
761
762 #. type: TP
763 #: build/C/man2/cacheflush.2:60 build/C/man2/mmap2.2:62
764 #: build/C/man2/mremap.2:142 build/C/man2/shmctl.2:314
765 #: build/C/man2/subpage_prot.2:72
766 #, no-wrap
767 msgid "B<EFAULT>"
768 msgstr "B<EFAULT>"
769
770 #. type: Plain text
771 #: build/C/man2/cacheflush.2:67
772 msgid ""
773 "Some or all of the address range I<addr> to I<(addr+nbytes-1)> is not "
774 "accessible."
775 msgstr ""
776 "I<addr> から I<(addr+nbytes-1)> の範囲のアドレスの全てまたは一部が アクセス可"
777 "能ではない。"
778
779 #. type: TP
780 #: build/C/man2/cacheflush.2:67 build/C/man2/fallocate.2:202
781 #: build/C/man2/fallocate.2:214 build/C/man2/fallocate.2:224
782 #: build/C/man2/fallocate.2:234 build/C/man2/madvise.2:282
783 #: build/C/man3/malloc_info.3:56 build/C/man2/mlock.2:157
784 #: build/C/man2/mlock.2:164 build/C/man2/mlock.2:176 build/C/man2/mmap.2:421
785 #: build/C/man2/mmap.2:429 build/C/man2/mmap.2:434 build/C/man2/mmap2.2:65
786 #: build/C/man2/mprotect.2:95 build/C/man2/mremap.2:151
787 #: build/C/man2/msync.2:80 build/C/man2/posix_fadvise.2:94
788 #: build/C/man3/posix_fallocate.3:81 build/C/man3/posix_memalign.3:158
789 #: build/C/man2/readahead.2:77 build/C/man2/remap_file_pages.2:132
790 #: build/C/man2/remap_file_pages.2:139 build/C/man3/shm_open.3:213
791 #: build/C/man2/shmctl.2:328 build/C/man2/shmget.2:199
792 #: build/C/man2/shmop.2:200 build/C/man2/shmop.2:223
793 #: build/C/man2/subpage_prot.2:77 build/C/man2/sync_file_range.2:152
794 #, no-wrap
795 msgid "B<EINVAL>"
796 msgstr "B<EINVAL>"
797
798 #. type: Plain text
799 #: build/C/man2/cacheflush.2:75
800 msgid "I<cache> is not one of B<ICACHE>, B<DCACHE>, or B<BCACHE>."
801 msgstr "I<cache> パラメータが B<ICACHE>, B<DCACHE>, B<BCACHE> のどれでもない。"
802
803 #.  FIXME This system call was only on MIPS back in 1.2 days, but
804 #.  by now it is on a number of other architectures (but not i386).
805 #.  Investigate the details and update this page.
806 #.  Irix 6.5 appears to have a cacheflush() syscall -- mtk
807 #. type: Plain text
808 #: build/C/man2/cacheflush.2:82
809 msgid ""
810 "This Linux-specific system call is available only on MIPS-based systems.  It "
811 "should not be used in programs intended to be portable."
812 msgstr ""
813 "この Linux 特有のシステムコールは MIPS ベースのシステムでのみ有効である。 移"
814 "植を意図したプログラムで使用すべきではない。"
815
816 #. type: Plain text
817 #: build/C/man2/cacheflush.2:89
818 msgid ""
819 "The current implementation ignores the I<addr> and I<nbytes> arguments.  "
820 "Therefore, the whole cache is always flushed."
821 msgstr ""
822 "現在の実装では、引き数 I<addr> と I<nbytes> は無視される。そのため、 常に全て"
823 "のキャッシュがフラッシュされる。"
824
825 #. type: TH
826 #: build/C/man2/fallocate.2:11
827 #, no-wrap
828 msgid "FALLOCATE"
829 msgstr "FALLOCATE"
830
831 #. type: TH
832 #: build/C/man2/fallocate.2:11 build/C/man2/shmget.2:38
833 #, no-wrap
834 msgid "2014-04-17"
835 msgstr "2014-04-17"
836
837 #. type: Plain text
838 #: build/C/man2/fallocate.2:14
839 msgid "fallocate - manipulate file space"
840 msgstr "fallocate - ファイル空間の操作"
841
842 #. type: Plain text
843 #: build/C/man2/fallocate.2:18 build/C/man2/readahead.2:35
844 #, no-wrap
845 msgid ""
846 "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
847 "B<#include E<lt>fcntl.hE<gt>>\n"
848 msgstr ""
849 "B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
850 "B<#include E<lt>fcntl.hE<gt>>\n"
851
852 #. type: Plain text
853 #: build/C/man2/fallocate.2:21
854 #, no-wrap
855 msgid "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
856 msgstr "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
857
858 #. type: Plain text
859 #: build/C/man2/fallocate.2:27
860 msgid ""
861 "This is a nonportable, Linux-specific system call.  For the portable, "
862 "POSIX.1-specified method of ensuring that space is allocated for a file, see "
863 "B<posix_fallocate>(3)."
864 msgstr ""
865 "このシステムコールは、移植性のない、Linux 固有のシステムコールである。 移植性"
866 "が必要な場合は、ファイルに対してディスク空間を確実に確保するために、 POSIX.1 "
867 "で規定された方法である B<posix_fallocate>(3)  を使うこと。"
868
869 #. type: Plain text
870 #: build/C/man2/fallocate.2:37
871 msgid ""
872 "B<fallocate>()  allows the caller to directly manipulate the allocated disk "
873 "space for the file referred to by I<fd> for the byte range starting at "
874 "I<offset> and continuing for I<len> bytes."
875 msgstr ""
876 "B<fallocate>()  を使うと、 I<fd> が参照するファイルに割り当てられたディスク空"
877 "間を直接操作できる。 操作対象は、 I<offset> から始まる長さ I<len> バイトの領"
878 "域である。"
879
880 #. type: Plain text
881 #: build/C/man2/fallocate.2:42
882 msgid ""
883 "The I<mode> argument determines the operation to be performed on the given "
884 "range.  Details of the supported operations are given in the subsections "
885 "below."
886 msgstr ""
887 "I<mode> 引き数は、指定された領域に対して実行する操作を指定する。\n"
888 "サポートされている操作の詳細は以下のサブセクションで説明する。"
889
890 #. type: SS
891 #: build/C/man2/fallocate.2:42
892 #, no-wrap
893 msgid "Allocating disk space"
894 msgstr "ディスク領域の割り当て"
895
896 #. type: Plain text
897 #: build/C/man2/fallocate.2:65
898 msgid ""
899 "The default operation (i.e., I<mode> is zero) of B<fallocate>()  allocates "
900 "the disk space within the range specified by I<offset> and I<len>.  The file "
901 "size (as reported by B<stat>(2))  will be changed if I<offset>+I<len> is "
902 "greater than the file size.  Any subregion within the range specified by "
903 "I<offset> and I<len> that did not contain data before the call will be "
904 "initialized to zero.  This default behavior closely resembles the behavior "
905 "of the B<posix_fallocate>(3)  library function, and is intended as a method "
906 "of optimally implementing that function."
907 msgstr ""
908 "B<fallocate>() のデフォルトの動作 (つまり I<mode> が 0 の場合) は、 "
909 "I<offset> と I<len> で指定された範囲のディスク領域の割り当てを行う。 "
910 "I<offset>+I<len> がファイルサイズよりも大きかった場合、 (B<stat>(2) で報告さ"
911 "れる) ファイルサイズが変更される。 I<offset> と I<len> で指定される範囲のサブ"
912 "領域で、 呼び出し前にデータを保持していなかった場合、そのサブ領域は 0 で初期"
913 "化される。 このデフォルトの動作は、 ライブラリ関数 B<posix_fallocate>(3) の動"
914 "作と非常に似ている。 これは、 このシステムコールが B<posix_fallocate>(3) を最"
915 "適に実装する手段を提供することを目的としているからである。"
916
917 #. type: Plain text
918 #: build/C/man2/fallocate.2:71
919 msgid ""
920 "After a successful call, subsequent writes into the range specified by "
921 "I<offset> and I<len> are guaranteed not to fail because of lack of disk "
922 "space."
923 msgstr ""
924 "呼び出しが成功した場合、\n"
925 "I<offset> と I<len> で指定された範囲へのそれ以降の書き込みでは、\n"
926 "ディスクの領域不足での書き込み失敗が起こらないことが保証される。"
927
928 #. type: Plain text
929 #: build/C/man2/fallocate.2:82
930 msgid ""
931 "If the B<FALLOC_FL_KEEP_SIZE> flag is specified in I<mode>, the behavior of "
932 "the call is similar, but the file size will not be changed even if I<offset>"
933 "+I<len> is greater than the file size.  Preallocating zeroed blocks beyond "
934 "the end of the file in this manner is useful for optimizing append workloads."
935 msgstr ""
936 "B<FALLOC_FL_KEEP_SIZE> フラグが I<mode> に指定された場合、このシステムコー"
937 "ル\n"
938 "の動作は似ているが、 I<offset>+I<len> がファイルサイズよりも大きい場合で\n"
939 "あってもファイルサイズは変更されない点が異なる。この場合のファイルの末尾\n"
940 "よりも後ろの前もって割り当てられた 0 で埋められたブロックは、ファイルへの\n"
941 "追記を最適化したい場合に役に立つ。"
942
943 #. type: Plain text
944 #: build/C/man2/fallocate.2:86
945 msgid ""
946 "Because allocation is done in block size chunks, B<fallocate>()  may "
947 "allocate a larger range of disk space than was specified."
948 msgstr ""
949 "割り当てはブロックサイズ単位で行われるため、 B<fallocate>() は指定されたよ"
950 "り\n"
951 "も大きなディスク領域を割り当てることがある。"
952
953 #. type: SS
954 #: build/C/man2/fallocate.2:86
955 #, no-wrap
956 msgid "Deallocating file space"
957 msgstr "ファイル空間の割り当て解除"
958
959 #. type: Plain text
960 #: build/C/man2/fallocate.2:101
961 msgid ""
962 "Specifying the B<FALLOC_FL_PUNCH_HOLE> flag (available since Linux 2.6.38) "
963 "in I<mode> deallocates space (i.e., creates a hole)  in the byte range "
964 "starting at I<offset> and continuing for I<len> bytes.  Within the specified "
965 "range, partial filesystem blocks are zeroed, and whole filesystem blocks are "
966 "removed from the file.  After a successful call, subsequent reads from this "
967 "range will return zeroes."
968 msgstr ""
969 "B<FALLOC_FL_PUNCH_HOLE> フラグ (Linux 2.6.38 以降で利用可能) を I<mode> に指"
970 "定すると、 I<offset> で始まる I<len> バイトの領域の空間を解放する (ホールを作"
971 "成する)。 指定された範囲のうち、 部分的に使用しているファイルシステムブロック"
972 "は 0 で埋められ、 全体を使用しているファイルシステムブロックはそのファイルか"
973 "ら削除される。 呼び出しが成功すると、 これ以降のこの範囲からの読み出しでは 0 "
974 "を返す。"
975
976 #. type: Plain text
977 #: build/C/man2/fallocate.2:112
978 msgid ""
979 "The B<FALLOC_FL_PUNCH_HOLE> flag must be ORed with B<FALLOC_FL_KEEP_SIZE> in "
980 "I<mode>; in other words, even when punching off the end of the file, the "
981 "file size (as reported by B<stat>(2))  does not change."
982 msgstr ""
983 "B<FALLOC_FL_PUNCH_HOLE> フラグは B<FALLOC_FL_KEEP_SIZE> と論理和 (OR) をとっ"
984 "て I<mode> に指定しなければならない。 つまり、 ファイル末尾の punch off を"
985 "行った場合でも、 (B<stat>(2) で報告される) ファイルサイズが変化しない。"
986
987 #. type: Plain text
988 #: build/C/man2/fallocate.2:117
989 msgid ""
990 "Not all filesystems support B<FALLOC_FL_PUNCH_HOLE>; if a filesystem doesn't "
991 "support the operation, an error is returned.  The operation is supported on "
992 "at least the following filesystems"
993 msgstr ""
994 "すべてのファイルシステムで B<FALLOC_FL_PUNCH_HOLE> がサポートされているわけで"
995 "はない。 ファイルシステムがこの操作をサポートしていない場合は、 エラーが返"
996 "る。 この操作は少なくとも以下のファイルシステムでサポートされている。"
997
998 #. type: IP
999 #: build/C/man2/fallocate.2:117 build/C/man2/fallocate.2:119
1000 #: build/C/man2/fallocate.2:122 build/C/man2/fallocate.2:124
1001 #: build/C/man2/madvise.2:286 build/C/man2/madvise.2:292
1002 #: build/C/man2/madvise.2:295 build/C/man2/madvise.2:298
1003 #: build/C/man2/madvise.2:301 build/C/man3/mallopt.3:235
1004 #: build/C/man3/mallopt.3:241
1005 #, no-wrap
1006 msgid "*"
1007 msgstr "*"
1008
1009 #. type: Plain text
1010 #: build/C/man2/fallocate.2:119
1011 msgid "XFS (since Linux 2.6.38)"
1012 msgstr "XFS (Linux 2.6.38 以降)"
1013
1014 #.  commit a4bb6b64e39abc0e41ca077725f2a72c868e7622
1015 #. type: Plain text
1016 #: build/C/man2/fallocate.2:122
1017 msgid "ext4 (since Linux 3.0)"
1018 msgstr "ext4 (Linux 3.0 以降)"
1019
1020 #. type: Plain text
1021 #: build/C/man2/fallocate.2:124
1022 msgid "Btrfs (since Linux 3.7)"
1023 msgstr "Btrfs (Linux 3.7 以降)"
1024
1025 #.  commit 83e4fa9c16e4af7122e31be3eca5d57881d236fe
1026 #. type: Plain text
1027 #: build/C/man2/fallocate.2:127
1028 msgid "tmpfs (since Linux 3.5)"
1029 msgstr "tmpfs (Linux 3.5 以降)"
1030
1031 #. type: SS
1032 #: build/C/man2/fallocate.2:127
1033 #, no-wrap
1034 msgid "Collapsing file space"
1035 msgstr "ファイル空間の一部削除"
1036
1037 #.  commit 00f5e61998dd17f5375d9dfc01331f104b83f841
1038 #. type: Plain text
1039 #: build/C/man2/fallocate.2:147
1040 msgid ""
1041 "Specifying the B<FALLOC_FL_COLLAPSE_RANGE> flag (available since Linux 3.15) "
1042 "in I<mode> removes a byte range from a file, without leaving a hole.  The "
1043 "byte range to be collapsed starts at I<offset> and continues for I<len> "
1044 "bytes.  At the completion of the operation, the contents of the file "
1045 "starting at the location I<offset+len> will be appended at the location "
1046 "I<offset>, and the file will be I<len> bytes smaller."
1047 msgstr "B<FALLOC_FL_COLLAPSE_RANGE> フラグ (Linux 3.15 以降で利用可能) を I<mode> に指定すると、 指定したバイト範囲をファイルから削除する。 その際、ホールを残らない。 削除されるバイト範囲は I<offset> から始まる I<len> バイトの範囲である。 操作が完了すると、 ファイルの I<offset+len> の位置から始まる内容が I<offset> の位置に見えるようになり、 ファイルのサイズは I<len> バイトだけ小さくなる。"
1048
1049 #. type: Plain text
1050 #: build/C/man2/fallocate.2:161
1051 msgid ""
1052 "A filesystem may place limitations on the granularity of the operation, in "
1053 "order to ensure efficient implementation.  Typically, I<offset> and I<len> "
1054 "must be a multiple of the filesystem logical block size, which varies "
1055 "according to the filesystem type and configuration.  If a filesystem has "
1056 "such a requirement, B<fallocate>()  will fail with the error B<EINVAL> if "
1057 "this requirement is violated."
1058 msgstr "効率的に動作する実装にするため、ファイルシステムはこの操作の粒度に制限を設けることがある。 通常は I<offset> と I<len> はファイルシステムの論理ブロックサイズの倍数でなければならない。 論理ブロックサイズはファイルシステムの種類や設定により様々である。 ファイルシステムにこのような要求条件がある場合、 その要求条件が満たされていなければ、 B<fallocate> はエラー B<EINVAL> で失敗する。"
1059
1060 #. type: Plain text
1061 #: build/C/man2/fallocate.2:170
1062 msgid ""
1063 "If the region specified by I<offset> plus I<len> reaches or passes the end "
1064 "of file, an error is returned; instead, use B<ftruncate>(2)  to truncate a "
1065 "file."
1066 msgstr "I<offset> と I<len> で指定された範囲がファイルの末尾かそれより先まで達している場合、 エラーが返される。 代わりに、ファイルの切り詰めを行う B<ftruncate>(2) を使用すること。"
1067
1068 #. type: Plain text
1069 #: build/C/man2/fallocate.2:175
1070 msgid ""
1071 "No other flags may be specified in I<mode> in conjunction with "
1072 "B<FALLOC_FL_COLLAPSE_RANGE>."
1073 msgstr "B<FALLOC_FL_COLLAPSE_RANGE> と他のフラグを同時に I<mode> に指定することはできない。"
1074
1075 #.  commit 9eb79482a97152930b113b51dff530aba9e28c8e
1076 #.  commit e1d8fb88a64c1f8094b9f6c3b6d2d9e6719c970d
1077 #. type: Plain text
1078 #: build/C/man2/fallocate.2:183
1079 msgid ""
1080 "As at Linux 3.15, B<FALLOC_FL_COLLAPSE_RANGE> is supported by ext4 (only for "
1081 "extent-based files)  and XFS."
1082 msgstr "Linux 3.15 時点では B<FALLOC_FL_COLLAPSE_RANGE> は ext4 (エクステントベースのファイル) と XFS でサポートされている。"
1083
1084 #. type: Plain text
1085 #: build/C/man2/fallocate.2:190
1086 msgid ""
1087 "On success, B<fallocate>()  returns zero.  On error, -1 is returned and "
1088 "I<errno> is set to indicate the error."
1089 msgstr ""
1090 "成功の場合、 B<fallocate>() は 0 を返す。 エラーの場合、-1 を返し、 I<error> "
1091 "にエラーを示す値を設定する。"
1092
1093 #. type: TP
1094 #: build/C/man2/fallocate.2:191 build/C/man2/madvise.2:279
1095 #: build/C/man2/mmap.2:415 build/C/man2/posix_fadvise.2:91
1096 #: build/C/man3/posix_fallocate.3:73 build/C/man2/readahead.2:73
1097 #: build/C/man2/sync_file_range.2:148
1098 #, no-wrap
1099 msgid "B<EBADF>"
1100 msgstr "B<EBADF>"
1101
1102 #. type: Plain text
1103 #: build/C/man2/fallocate.2:195 build/C/man3/posix_fallocate.3:77
1104 msgid "I<fd> is not a valid file descriptor, or is not opened for writing."
1105 msgstr ""
1106 "I<fd> が有効なファイルディスクリプタでないか、 書き込み用としてオープンされて"
1107 "いない。"
1108
1109 #. type: TP
1110 #: build/C/man2/fallocate.2:195 build/C/man3/posix_fallocate.3:77
1111 #, no-wrap
1112 msgid "B<EFBIG>"
1113 msgstr "B<EFBIG>"
1114
1115 #. type: Plain text
1116 #: build/C/man2/fallocate.2:199
1117 msgid "I<offset>+I<len> exceeds the maximum file size."
1118 msgstr "I<offset + len> がファイルサイズの最大値よりも大きい。"
1119
1120 #. type: TP
1121 #: build/C/man2/fallocate.2:199
1122 #, no-wrap
1123 msgid "B<EINTR>"
1124 msgstr "B<EINTR>"
1125
1126 #. type: Plain text
1127 #: build/C/man2/fallocate.2:202
1128 msgid "A signal was caught during execution."
1129 msgstr "実行中にシグナルが捕捉された。"
1130
1131 #. type: Plain text
1132 #: build/C/man2/fallocate.2:214 build/C/man3/posix_fallocate.3:87
1133 msgid "I<offset> was less than 0, or I<len> was less than or equal to 0."
1134 msgstr "I<offset> が 0 未満だったか、 I<len> が 0 以下だった。"
1135
1136 #. type: Plain text
1137 #: build/C/man2/fallocate.2:224
1138 msgid ""
1139 "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE> and the range specified by I<offset> "
1140 "plus I<len> reaches or passes the end of the file."
1141 msgstr "I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> で、 I<offset> と I<len> で指定された範囲がファイルの末尾かそれより先まで達している。"
1142
1143 #. type: Plain text
1144 #: build/C/man2/fallocate.2:234
1145 msgid ""
1146 "I<mode> is B<FALLOC_FL_COLLAPSE_RANGE>, but either I<offset> or I<len> is "
1147 "not a multiple of the filesystem block size."
1148 msgstr "I<mode> が B<FALLOC_FL_COLLAPSE_RANGE> だが、 I<offset> か I<len> のいずれかがファイルシステムのブロックサイズの倍数ではない。"
1149
1150 #. type: Plain text
1151 #: build/C/man2/fallocate.2:241
1152 msgid ""
1153 "mode contains both B<FALLOC_FL_COLLAPSE_RANGE> and other flags; no other "
1154 "flags are permitted with B<FALLOC_FL_COLLAPSE_RANGE>."
1155 msgstr "I<mode> に B<FALLOC_FL_COLLAPSE_RANGE> と他のフラグの両方が指定されている。 B<FALLOC_FL_COLLAPSE_RANGE> と他のフラグを一緒に使うことができない。"
1156
1157 #. type: TP
1158 #: build/C/man2/fallocate.2:241
1159 #, no-wrap
1160 msgid "I<mode>"
1161 msgstr "I<mode>"
1162
1163 #.  There was a inconsistency in 3.15-rc1, that should be resolved so that all
1164 #.  filesystems use this error for this case. (Tytso says ex4 will change.)
1165 #.  http://thread.gmane.org/gmane.comp.file-systems.xfs.general/60485/focus=5521
1166 #.  From: Michael Kerrisk (man-pages <mtk.manpages@...>
1167 #.  Subject: Re: [PATCH v5 10/10] manpage: update FALLOC_FL_COLLAPSE_RANGE flag in fallocate
1168 #.  Newsgroups: gmane.linux.man, gmane.linux.file-systems
1169 #.  Date: 2014-04-17 13:40:05 GMT
1170 #. type: Plain text
1171 #: build/C/man2/fallocate.2:255
1172 msgid ""
1173 "is B<FALLOC_FL_COLLAPSE_RANGE>, but the file referred to by I<fd> is not a "
1174 "regular file."
1175 msgstr "が B<FALLOC_FL_COLLAPSE_RANGE> だが、 I<fd> が参照しているファイルが通常のファイルではない。"
1176
1177 #. type: TP
1178 #: build/C/man2/fallocate.2:255 build/C/man2/madvise.2:310
1179 #: build/C/man2/sync_file_range.2:160
1180 #, no-wrap
1181 msgid "B<EIO>"
1182 msgstr "B<EIO>"
1183
1184 #. type: Plain text
1185 #: build/C/man2/fallocate.2:258
1186 msgid "An I/O error occurred while reading from or writing to a filesystem."
1187 msgstr "ファイルシステムとの読み書き中に入出力エラーが発生した。"
1188
1189 #. type: TP
1190 #: build/C/man2/fallocate.2:258 build/C/man2/mmap.2:450
1191 #: build/C/man3/posix_fallocate.3:87
1192 #, no-wrap
1193 msgid "B<ENODEV>"
1194 msgstr "B<ENODEV>"
1195
1196 #. type: Plain text
1197 #: build/C/man2/fallocate.2:265
1198 msgid ""
1199 "I<fd> does not refer to a regular file or a directory.  (If I<fd> is a pipe "
1200 "or FIFO, a different error results.)"
1201 msgstr ""
1202 "I<fd> が通常のファイルかディレクトリを参照していない (I<fd> がパイプや FIFO "
1203 "を参照している場合、別のエラーが発生する)。"
1204
1205 #. type: TP
1206 #: build/C/man2/fallocate.2:265 build/C/man3/posix_fallocate.3:91
1207 #: build/C/man2/shmget.2:217 build/C/man2/sync_file_range.2:166
1208 #, no-wrap
1209 msgid "B<ENOSPC>"
1210 msgstr "B<ENOSPC>"
1211
1212 #. type: Plain text
1213 #: build/C/man2/fallocate.2:270 build/C/man3/posix_fallocate.3:96
1214 msgid ""
1215 "There is not enough space left on the device containing the file referred to "
1216 "by I<fd>."
1217 msgstr "I<fd> が参照するファイルを含むデバイスに十分な空き領域がない。"
1218
1219 #. type: Plain text
1220 #: build/C/man2/fallocate.2:274
1221 msgid "This kernel does not implement B<fallocate>()."
1222 msgstr "このカーネルでは B<fallocate>() は実装されていない。"
1223
1224 #. type: TP
1225 #: build/C/man2/fallocate.2:274
1226 #, no-wrap
1227 msgid "B<EOPNOTSUPP>"
1228 msgstr "B<EOPNOTSUPP>"
1229
1230 #. type: Plain text
1231 #: build/C/man2/fallocate.2:283
1232 msgid ""
1233 "The filesystem containing the file referred to by I<fd> does not support "
1234 "this operation; or the I<mode> is not supported by the filesystem containing "
1235 "the file referred to by I<fd>."
1236 msgstr ""
1237 "I<fd> が参照するファイルを含むファイルシステムが 指定された操作を\n"
1238 "サポートしていない。 I<fd> が参照するファイルを含むファイルシステムが\n"
1239 "I<mode> をサポートしていない。"
1240
1241 #. type: TP
1242 #: build/C/man2/fallocate.2:283 build/C/man2/mlock.2:143
1243 #: build/C/man2/mlock.2:182 build/C/man2/mmap.2:458 build/C/man2/shmctl.2:353
1244 #: build/C/man2/shmget.2:225
1245 #, no-wrap
1246 msgid "B<EPERM>"
1247 msgstr "B<EPERM>"
1248
1249 #. type: Plain text
1250 #: build/C/man2/fallocate.2:301
1251 msgid ""
1252 "The file referred to by I<fd> is marked immutable (see B<chattr>(1)).  Or: "
1253 "I<mode> specifies B<FALLOC_FL_PUNCH_HOLE> or B<FALLOC_FL_COLLAPSE_RANGE> and "
1254 "the file referred to by I<fd> is marked append-only (see B<chattr>(1))."
1255 msgstr "I<fd> が参照するファイルに変更不可 (immutable) の属性が付いている (B<chattr>(1) 参照)。 I<mode> に B<FALLOC_FL_PUNCH_HOLE> か B<FALLOC_FL_COLLAPSE_RANGE> が指定されたが、 I<fd> が参照するファイルに追加のみ (append-only) の属性が付いている (B<chattr>(1) 参照)。"
1256
1257 #. type: TP
1258 #: build/C/man2/fallocate.2:301 build/C/man2/posix_fadvise.2:97
1259 #: build/C/man3/posix_fallocate.3:96 build/C/man2/sync_file_range.2:169
1260 #, no-wrap
1261 msgid "B<ESPIPE>"
1262 msgstr "B<ESPIPE>"
1263
1264 #. type: Plain text
1265 #: build/C/man2/fallocate.2:305
1266 msgid "I<fd> refers to a pipe or FIFO."
1267 msgstr "I<fd> がパイプか FIFO を参照している。"
1268
1269 #. type: TP
1270 #: build/C/man2/fallocate.2:305 build/C/man2/mmap.2:467
1271 #, no-wrap
1272 msgid "B<ETXTBSY>"
1273 msgstr "B<ETXTBSY>"
1274
1275 #. type: Plain text
1276 #: build/C/man2/fallocate.2:313
1277 msgid ""
1278 "I<mode> specifies B<FALLOC_FL_COLLAPSE_RANGE>, but the file referred to by "
1279 "I<fd> is currently being executed."
1280 msgstr "I<mode> に B<FALLOC_FL_COLLAPSE_RANGE> が指定されたが、 I<fd> が参照するファイルは現在実行中である。"
1281
1282 #. type: SH
1283 #: build/C/man2/fallocate.2:313 build/C/man3/malloc_info.3:60
1284 #: build/C/man3/mcheck.3:134 build/C/man2/mmap2.2:74
1285 #: build/C/man2/posix_fadvise.2:104 build/C/man3/posix_fallocate.3:100
1286 #: build/C/man3/posix_memalign.3:167 build/C/man2/readahead.2:83
1287 #: build/C/man2/remap_file_pages.2:148 build/C/man3/shm_open.3:249
1288 #: build/C/man2/subpage_prot.2:90 build/C/man2/sync_file_range.2:177
1289 #, no-wrap
1290 msgid "VERSIONS"
1291 msgstr "バージョン"
1292
1293 #.  See http://sourceware.org/bugzilla/show_bug.cgi?id=14964
1294 #. type: Plain text
1295 #: build/C/man2/fallocate.2:321
1296 msgid ""
1297 "B<fallocate>()  is available on Linux since kernel 2.6.23.  Support is "
1298 "provided by glibc since version 2.10.  The B<FALLOC_FL_*> flags are defined "
1299 "in glibc headers only since version 2.18."
1300 msgstr ""
1301 "B<fallocate>()  はカーネル 2.6.23 以降の Linux で利用可能である。 glibc での"
1302 "対応はバージョン 3.10 以降で行われている。 B<FALLOC_FL_*> が glibc のヘッダ"
1303 "ファイルで定義されているのは、バージョン 2.18 以降のみである。"
1304
1305 #. type: Plain text
1306 #: build/C/man2/fallocate.2:324
1307 msgid "B<fallocate>()  is Linux-specific."
1308 msgstr "B<fallocate>()  は Linux 固有である。"
1309
1310 #. type: Plain text
1311 #: build/C/man2/fallocate.2:329
1312 msgid ""
1313 "B<fallocate>(1), B<ftruncate>(2), B<posix_fadvise>(3), B<posix_fallocate>(3)"
1314 msgstr ""
1315 "B<fallocate>(1), B<ftruncate>(2), B<posix_fadvise>(3), B<posix_fallocate>(3)"
1316
1317 #. type: TH
1318 #: build/C/man2/madvise.2:35
1319 #, no-wrap
1320 msgid "MADVISE"
1321 msgstr "MADVISE"
1322
1323 #. type: TH
1324 #: build/C/man2/madvise.2:35 build/C/man2/msync.2:25
1325 #, no-wrap
1326 msgid "2014-04-20"
1327 msgstr "2014-04-20"
1328
1329 #. type: Plain text
1330 #: build/C/man2/madvise.2:38
1331 msgid "madvise - give advice about use of memory"
1332 msgstr "madvise - メモリ利用に関するアドバイスを与える"
1333
1334 #. type: Plain text
1335 #: build/C/man2/madvise.2:40 build/C/man2/msync.2:30
1336 #: build/C/man3/shm_open.3:31
1337 msgid "B<#include E<lt>sys/mman.hE<gt>>"
1338 msgstr "B<#include E<lt>sys/mman.hE<gt>>"
1339
1340 #. type: Plain text
1341 #: build/C/man2/madvise.2:42
1342 msgid ""
1343 "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
1344 msgstr ""
1345 "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
1346
1347 #. type: Plain text
1348 #: build/C/man2/madvise.2:46 build/C/man2/posix_fadvise.2:43
1349 #: build/C/man3/posix_fallocate.3:39 build/C/man3/posix_memalign.3:49
1350 msgid ""
1351 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
1352 msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)  参照):"
1353
1354 #. type: Plain text
1355 #: build/C/man2/madvise.2:50
1356 msgid "B<madvise>(): _BSD_SOURCE"
1357 msgstr "B<madvise>(): _BSD_SOURCE"
1358
1359 #. type: Plain text
1360 #: build/C/man2/madvise.2:68
1361 msgid ""
1362 "The B<madvise>()  system call advises the kernel about how to handle paging "
1363 "input/output in the address range beginning at address I<addr> and with size "
1364 "I<length> bytes.  It allows an application to tell the kernel how it expects "
1365 "to use some mapped or shared memory areas, so that the kernel can choose "
1366 "appropriate read-ahead and caching techniques.  This call does not influence "
1367 "the semantics of the application (except in the case of B<MADV_DONTNEED>), "
1368 "but may influence its performance.  The kernel is free to ignore the advice."
1369 msgstr ""
1370 "B<madvise>()  システムコールは、アドレス I<addr> からはじまる I<length> バイ"
1371 "トのメモリブロックのページング入出力をどう扱えば良いか、 カーネルにアドバイス"
1372 "する。 これを用いると、 アプリケーションからカーネルに、 マップされたメモリや"
1373 "共有メモリをどのように扱ってほしいか伝えることができ、 カーネルはそれに応じて"
1374 "先読みやキャッシュなどの適切な手法を選択できる。 このコールはアプリケーション"
1375 "の動作そのものには影響しない (B<MADV_DONTNEED> の場合は別) が、 性能には影響"
1376 "しうる。 なおこのアドバイスを受け入れるかどうかはカーネルに任される。"
1377
1378 #. type: Plain text
1379 #: build/C/man2/madvise.2:72
1380 msgid "The advice is indicated in the I<advice> argument which can be"
1381 msgstr ""
1382 "アドバイスは引き数 I<advice> によって与える。以下のいずれかを指定できる。"
1383
1384 #. type: TP
1385 #: build/C/man2/madvise.2:72
1386 #, no-wrap
1387 msgid "B<MADV_NORMAL>"
1388 msgstr "B<MADV_NORMAL>"
1389
1390 #. type: Plain text
1391 #: build/C/man2/madvise.2:76
1392 msgid "No special treatment.  This is the default."
1393 msgstr "特別な扱いは行わない。これがデフォルトである。"
1394
1395 #. type: TP
1396 #: build/C/man2/madvise.2:76
1397 #, no-wrap
1398 msgid "B<MADV_RANDOM>"
1399 msgstr "B<MADV_RANDOM>"
1400
1401 #. type: Plain text
1402 #: build/C/man2/madvise.2:80
1403 msgid ""
1404 "Expect page references in random order.  (Hence, read ahead may be less "
1405 "useful than normally.)"
1406 msgstr ""
1407 "ページ参照はランダムな順序で行われそうだ。 (したがって、先読みはあまり効果が"
1408 "なさそうだ。)"
1409
1410 #. type: TP
1411 #: build/C/man2/madvise.2:80
1412 #, no-wrap
1413 msgid "B<MADV_SEQUENTIAL>"
1414 msgstr "B<MADV_SEQUENTIAL>"
1415
1416 #. type: Plain text
1417 #: build/C/man2/madvise.2:85
1418 msgid ""
1419 "Expect page references in sequential order.  (Hence, pages in the given "
1420 "range can be aggressively read ahead, and may be freed soon after they are "
1421 "accessed.)"
1422 msgstr ""
1423 "ページ参照はシーケンシャルな順序で行われそうだ。 (したがって与えた範囲のペー"
1424 "ジは積極的に先読みしておくと良いだろう。 またアクセスが終わったら速やかに解放"
1425 "して良い。)"
1426
1427 #. type: TP
1428 #: build/C/man2/madvise.2:85
1429 #, no-wrap
1430 msgid "B<MADV_WILLNEED>"
1431 msgstr "B<MADV_WILLNEED>"
1432
1433 #. type: Plain text
1434 #: build/C/man2/madvise.2:89
1435 msgid ""
1436 "Expect access in the near future.  (Hence, it might be a good idea to read "
1437 "some pages ahead.)"
1438 msgstr ""
1439 "近い将来にアクセスされそうだ。 (したがってこれらのページを今のうちに先読みし"
1440 "ておくといいだろう。)"
1441
1442 #. type: TP
1443 #: build/C/man2/madvise.2:89
1444 #, no-wrap
1445 msgid "B<MADV_DONTNEED>"
1446 msgstr "B<MADV_DONTNEED>"
1447
1448 #. type: Plain text
1449 #: build/C/man2/madvise.2:100
1450 msgid ""
1451 "Do not expect access in the near future.  (For the time being, the "
1452 "application is finished with the given range, so the kernel can free "
1453 "resources associated with it.)  Subsequent accesses of pages in this range "
1454 "will succeed, but will result either in reloading of the memory contents "
1455 "from the underlying mapped file (see B<mmap>(2))  or zero-fill-on-demand "
1456 "pages for mappings without an underlying file."
1457 msgstr ""
1458 "しばらくアクセスはなさそうだ。 (現時点でアプリケーションは与えた範囲の処理を"
1459 "終えている。 したがってカーネルはこれに関連するリソースを解放して良い。)  こ"
1460 "れ以降この範囲のページへのアクセスがあると、 成功はするが、メモリの内容をマッ"
1461 "プ元のファイルからロードし直すことになる (B<mmap>(2)  を見よ) か、 または元"
1462 "ファイルがないマップページでは アクセスがあったときに 0 埋めが行われることに"
1463 "なる。"
1464
1465 #. type: TP
1466 #: build/C/man2/madvise.2:100
1467 #, no-wrap
1468 msgid "B<MADV_REMOVE> (since Linux 2.6.16)"
1469 msgstr "B<MADV_REMOVE> (Linux 2.6.16 以降)"
1470
1471 #.  2.6.18-rc5
1472 #.  Databases want to use this feature to drop a section of their
1473 #.  bufferpool (shared memory segments) - without writing back to
1474 #.  disk/swap space.  This feature is also useful for supporting
1475 #.  hot-plug memory on UML.
1476 #. type: Plain text
1477 #: build/C/man2/madvise.2:113
1478 msgid ""
1479 "Free up a given range of pages and its associated backing store.  Currently, "
1480 "only shmfs/tmpfs supports this; other filesystems return with the error "
1481 "B<ENOSYS>."
1482 msgstr ""
1483 "指定された範囲のページと関連するバッキングストアを解放する。 現在のところ、 "
1484 "shmfs/tmpfs だけがこれに対応している。 他のファイルシステムでは B<ENOSYS> が"
1485 "返される。"
1486
1487 #. type: TP
1488 #: build/C/man2/madvise.2:113
1489 #, no-wrap
1490 msgid "B<MADV_DONTFORK> (since Linux 2.6.16)"
1491 msgstr "B<MADV_DONTFORK> (Linux 2.6.16 以降)"
1492
1493 #.  See http://lwn.net/Articles/171941/
1494 #.  [PATCH] madvise MADV_DONTFORK/MADV_DOFORK
1495 #.  Currently, copy-on-write may change the physical address of
1496 #.  a page even if the user requested that the page is pinned in
1497 #.  memory (either by mlock or by get_user_pages).  This happens
1498 #.  if the process forks meanwhile, and the parent writes to that
1499 #.  page.  As a result, the page is orphaned: in case of
1500 #.  get_user_pages, the application will never see any data hardware
1501 #.  DMA's into this page after the COW.  In case of mlock'd memory,
1502 #.  the parent is not getting the realtime/security benefits of mlock.
1503 #.  In particular, this affects the Infiniband modules which do DMA from
1504 #.  and into user pages all the time.
1505 #.  This patch adds madvise options to control whether memory range is
1506 #.  inherited across fork. Useful e.g. for when hardware is doing DMA
1507 #.  from/into these pages.  Could also be useful to an application
1508 #.  wanting to speed up its forks by cutting large areas out of
1509 #.  consideration.
1510 #.  SEE ALSO: http://lwn.net/Articles/171941/
1511 #.  "Tweaks to madvise() and posix_fadvise()", 14 Feb 2006
1512 #. type: Plain text
1513 #: build/C/man2/madvise.2:144
1514 msgid ""
1515 "Do not make the pages in this range available to the child after a B<fork>"
1516 "(2).  This is useful to prevent copy-on-write semantics from changing the "
1517 "physical location of a page(s) if the parent writes to it after a B<fork>"
1518 "(2).  (Such page relocations cause problems for hardware that DMAs into the "
1519 "page(s).)"
1520 msgstr ""
1521 "B<fork>(2)  が行われた後、指定された範囲のページを子プロセスが利用できないよ"
1522 "うにする。 この機能は、書き込み時コピー (copy-on-write) 方式で、 B<fork>(2)  "
1523 "の後で親プロセスがページに書き込みを行った場合に ページの物理位置が変化しない"
1524 "ようにするのに有効である (ページの再配置はハードウェアがそのページに DMA 転送"
1525 "を行うような場合に 問題を起こすことがある)。"
1526
1527 #. type: TP
1528 #: build/C/man2/madvise.2:144
1529 #, no-wrap
1530 msgid "B<MADV_DOFORK> (since Linux 2.6.16)"
1531 msgstr "B<MADV_DOFORK> (Linux 2.6.16 以降)"
1532
1533 #. type: Plain text
1534 #: build/C/man2/madvise.2:150
1535 msgid ""
1536 "Undo the effect of B<MADV_DONTFORK>, restoring the default behavior, whereby "
1537 "a mapping is inherited across B<fork>(2)."
1538 msgstr ""
1539 "B<MADV_DONTFORK> の影響を取り消し、デフォルトの動作に戻す。 つまり、 B<fork>"
1540 "(2)  の前後でマッピングは継承されるようになる。"
1541
1542 #. type: TP
1543 #: build/C/man2/madvise.2:150
1544 #, no-wrap
1545 msgid "B<MADV_HWPOISON> (since Linux 2.6.32)"
1546 msgstr "B<MADV_HWPOISON> (Linux 2.6.32 以降)"
1547
1548 #. type: Plain text
1549 #: build/C/man2/madvise.2:162
1550 msgid ""
1551 "Poison a page and handle it like a hardware memory corruption.  This "
1552 "operation is available only for privileged (B<CAP_SYS_ADMIN>)  processes.  "
1553 "This operation may result in the calling process receiving a B<SIGBUS> and "
1554 "the page being unmapped.  This feature is intended for testing of memory "
1555 "error-handling code; it is available only if the kernel was configured with "
1556 "B<CONFIG_MEMORY_FAILURE>."
1557 msgstr ""
1558
1559 #. type: TP
1560 #: build/C/man2/madvise.2:162
1561 #, no-wrap
1562 msgid "B<MADV_SOFT_OFFLINE> (since Linux 2.6.33)"
1563 msgstr "B<MADV_SOFT_OFFLINE> (Linux 2.6.33 以降)"
1564
1565 #. type: Plain text
1566 #: build/C/man2/madvise.2:180
1567 msgid ""
1568 "Soft offline the pages in the range specified by I<addr> and I<length>.  The "
1569 "memory of each page in the specified range is preserved (i.e., when next "
1570 "accessed, the same content will be visible, but in a new physical page "
1571 "frame), and the original page is offlined (i.e., no longer used, and taken "
1572 "out of normal memory management).  The effect of the B<MADV_SOFT_OFFLINE> "
1573 "operation is invisible to (i.e., does not change the semantics of)  the "
1574 "calling process.  This feature is intended for testing of memory error-"
1575 "handling code; it is available only if the kernel was configured with "
1576 "B<CONFIG_MEMORY_FAILURE>."
1577 msgstr ""
1578
1579 #. type: TP
1580 #: build/C/man2/madvise.2:180
1581 #, no-wrap
1582 msgid "B<MADV_MERGEABLE> (since Linux 2.6.32)"
1583 msgstr "B<MADV_MERGEABLE> (Linux 2.6.32 以降)"
1584
1585 #. type: Plain text
1586 #: build/C/man2/madvise.2:205
1587 msgid ""
1588 "Enable Kernel Samepage Merging (KSM) for the pages in the range specified by "
1589 "I<addr> and I<length>.  The kernel regularly scans those areas of user "
1590 "memory that have been marked as mergeable, looking for pages with identical "
1591 "content.  These are replaced by a single write-protected page (which is "
1592 "automatically copied if a process later wants to update the content of the "
1593 "page).  KSM merges only private anonymous pages (see B<mmap>(2)).  The KSM "
1594 "feature is intended for applications that generate many instances of the "
1595 "same data (e.g., virtualization systems such as KVM).  It can consume a lot "
1596 "of processing power; use with care.  See the Linux kernel source file "
1597 "I<Documentation/vm/ksm.txt> for more details.  The B<MADV_MERGEABLE> and "
1598 "B<MADV_UNMERGEABLE> operations are available only if the kernel was "
1599 "configured with B<CONFIG_KSM>."
1600 msgstr ""
1601
1602 #. type: TP
1603 #: build/C/man2/madvise.2:205
1604 #, no-wrap
1605 msgid "B<MADV_UNMERGEABLE> (since Linux 2.6.32)"
1606 msgstr "B<MADV_UNMERGEABLE> (Linux 2.6.32 以降)"
1607
1608 #. type: Plain text
1609 #: build/C/man2/madvise.2:214
1610 msgid ""
1611 "Undo the effect of an earlier B<MADV_MERGEABLE> operation on the specified "
1612 "address range; KSM unmerges whatever pages it had merged in the address "
1613 "range specified by I<addr> and I<length>."
1614 msgstr ""
1615
1616 #. type: TP
1617 #: build/C/man2/madvise.2:214
1618 #, no-wrap
1619 msgid "B<MADV_HUGEPAGE> (since Linux 2.6.38)"
1620 msgstr "B<MADV_HUGEPAGE> (Linux 2.6.38 以降)"
1621
1622 #.  http://lwn.net/Articles/358904/
1623 #.  https://lwn.net/Articles/423584/
1624 #. type: Plain text
1625 #: build/C/man2/madvise.2:243
1626 msgid ""
1627 "Enables Transparent Huge Pages (THP) for pages in the range specified by "
1628 "I<addr> and I<length>.  Currently, Transparent Huge Pages work only with "
1629 "private anonymous pages (see B<mmap>(2)).  The kernel will regularly scan "
1630 "the areas marked as huge page candidates to replace them with huge pages.  "
1631 "The kernel will also allocate huge pages directly when the region is "
1632 "naturally aligned to the huge page size (see B<posix_memalign>(2)).  This "
1633 "feature is primarily aimed at applications that use large mappings of data "
1634 "and access large regions of that memory at a time (e.g., virtualization "
1635 "systems such as QEMU).  It can very easily waste memory (e.g., a 2MB mapping "
1636 "that only ever accesses 1 byte will result in 2MB of wired memory instead of "
1637 "one 4KB page).  See the Linux kernel source file I<Documentation/vm/"
1638 "transhuge.txt> for more details.  The B<MADV_HUGEPAGE> and "
1639 "B<MADV_NOHUGEPAGE> operations are available only if the kernel was "
1640 "configured with B<CONFIG_TRANSPARENT_HUGEPAGE>."
1641 msgstr ""
1642
1643 #. type: TP
1644 #: build/C/man2/madvise.2:243
1645 #, no-wrap
1646 msgid "B<MADV_NOHUGEPAGE> (since Linux 2.6.38)"
1647 msgstr "B<MADV_NOHUGEPAGE> (Linux 2.6.38 以降)"
1648
1649 #. type: Plain text
1650 #: build/C/man2/madvise.2:250
1651 msgid ""
1652 "Ensures that memory in the address range specified by I<addr> and I<length> "
1653 "will not be collapsed into huge pages."
1654 msgstr ""
1655
1656 #. type: TP
1657 #: build/C/man2/madvise.2:250
1658 #, no-wrap
1659 msgid "B<MADV_DONTDUMP> (since Linux 3.4)"
1660 msgstr "B<MADV_DONTDUMP> (Linux 3.4 以降)"
1661
1662 #. type: Plain text
1663 #: build/C/man2/madvise.2:264
1664 msgid ""
1665 "Exclude from a core dump those pages in the range specified by I<addr> and "
1666 "I<length>.  This is useful in applications that have large areas of memory "
1667 "that are known not to be useful in a core dump.  The effect of "
1668 "B<MADV_DONTDUMP> takes precedence over the bit mask that is set via the I</"
1669 "proc/PID/coredump_filter> file (see B<core>(5))."
1670 msgstr ""
1671
1672 #. type: TP
1673 #: build/C/man2/madvise.2:264
1674 #, no-wrap
1675 msgid "B<MADV_DODUMP> (since Linux 3.4)"
1676 msgstr "B<MADV_DODUMP> (Linux 3.4 以降)"
1677
1678 #. type: Plain text
1679 #: build/C/man2/madvise.2:268
1680 msgid "Undo the effect of an earlier B<MADV_DONTDUMP>."
1681 msgstr "以前の B<MADV_DONTDUMP> の効果を取り消す。"
1682
1683 #. type: Plain text
1684 #: build/C/man2/madvise.2:275
1685 msgid ""
1686 "On success B<madvise>()  returns zero.  On error, it returns -1 and I<errno> "
1687 "is set appropriately."
1688 msgstr ""
1689 "B<madvise>()  は成功すると 0 を返す。 エラーが起こると -1 を返し、 I<errno> "
1690 "を適切な値に設定する。"
1691
1692 #. type: TP
1693 #: build/C/man2/madvise.2:276 build/C/man2/mlock.2:154 build/C/man2/mmap.2:411
1694 #: build/C/man2/mremap.2:136
1695 #, no-wrap
1696 msgid "B<EAGAIN>"
1697 msgstr "B<EAGAIN>"
1698
1699 #. type: Plain text
1700 #: build/C/man2/madvise.2:279
1701 msgid "A kernel resource was temporarily unavailable."
1702 msgstr "何らかのカーネルリソースが一時的に利用できなかった。"
1703
1704 #. type: Plain text
1705 #: build/C/man2/madvise.2:282
1706 msgid "The map exists, but the area maps something that isn't a file."
1707 msgstr "指定したマップは存在するが、ファイルではないところをマップしている。"
1708
1709 #. type: Plain text
1710 #: build/C/man2/madvise.2:285
1711 msgid "This error can occur for the following reasons:"
1712 msgstr "このエラーは以下の理由で発生する。"
1713
1714 #.  .I len
1715 #.  is zero,
1716 #. type: Plain text
1717 #: build/C/man2/madvise.2:292
1718 msgid "The value I<len> is negative."
1719 msgstr "I<len> が負の値である。"
1720
1721 #. type: Plain text
1722 #: build/C/man2/madvise.2:295
1723 msgid "I<addr> is not page-aligned."
1724 msgstr "I<addr> がページ境界ではない。"
1725
1726 #. type: Plain text
1727 #: build/C/man2/madvise.2:298
1728 msgid "I<advice> is not a valid value"
1729 msgstr "I<advice> が有効な値でない。"
1730
1731 #. type: Plain text
1732 #: build/C/man2/madvise.2:301
1733 msgid ""
1734 "The application is attempting to release locked or shared pages (with "
1735 "B<MADV_DONTNEED>)."
1736 msgstr ""
1737 "アプリケーションがロックされたページや共有ページを (B<MADV_DONTNEED> で) 解"
1738 "放\n"
1739 "しようとしている。"
1740
1741 #. type: Plain text
1742 #: build/C/man2/madvise.2:309
1743 msgid ""
1744 "B<MADV_MERGEABLE> or B<MADV_UNMERGEABLE> was specified in I<advice>, but the "
1745 "kernel was not configured with B<CONFIG_KSM>."
1746 msgstr ""
1747 "I<advice> に B<MADV_MERGEABLE> か B<MADV_UNMERGEABLE> が指定されたが、 カーネ"
1748 "ルの設定が B<CONFIG_KSM> が有効になっていなかった。"
1749
1750 #. type: Plain text
1751 #: build/C/man2/madvise.2:316
1752 msgid ""
1753 "(for B<MADV_WILLNEED>)  Paging in this area would exceed the process's "
1754 "maximum resident set size."
1755 msgstr ""
1756 "(B<MADV_WILLNEED> の場合) この範囲のページングを行うと、 プロセスの RSS "
1757 "(resident set size) の最大値を越えてしまう。"
1758
1759 #. type: TP
1760 #: build/C/man2/madvise.2:316 build/C/man2/madvise.2:321
1761 #: build/C/man2/mlock.2:123 build/C/man2/mlock.2:131 build/C/man2/mlock.2:169
1762 #: build/C/man2/mmap.2:454 build/C/man2/mprotect.2:100
1763 #: build/C/man2/mprotect.2:103 build/C/man2/mremap.2:179
1764 #: build/C/man2/msync.2:93 build/C/man3/posix_memalign.3:164
1765 #: build/C/man2/shmctl.2:337 build/C/man2/shmget.2:214
1766 #: build/C/man2/shmop.2:214 build/C/man2/subpage_prot.2:87
1767 #: build/C/man2/sync_file_range.2:163
1768 #, no-wrap
1769 msgid "B<ENOMEM>"
1770 msgstr "B<ENOMEM>"
1771
1772 #. type: Plain text
1773 #: build/C/man2/madvise.2:321
1774 msgid "(for B<MADV_WILLNEED>)  Not enough memory: paging in failed."
1775 msgstr "(B<MADV_WILLNEED> の場合) メモリが足りず、ページングに失敗した。"
1776
1777 #. type: Plain text
1778 #: build/C/man2/madvise.2:325
1779 msgid ""
1780 "Addresses in the specified range are not currently mapped, or are outside "
1781 "the address space of the process."
1782 msgstr ""
1783 "指定した範囲のアドレスが、現在マップされていない。 あるいはプロセスのアドレス"
1784 "空間の内部にない。"
1785
1786 #.  FIXME . Write a posix_madvise(3) page.
1787 #. type: Plain text
1788 #: build/C/man2/madvise.2:338
1789 msgid ""
1790 "POSIX.1b.  POSIX.1-2001 describes B<posix_madvise>(3)  with constants "
1791 "B<POSIX_MADV_NORMAL>, B<POSIX_MADV_RANDOM>, and so on, with a behavior close "
1792 "to that described here.  There is a similar B<posix_fadvise>(2)  for file "
1793 "access."
1794 msgstr ""
1795 "POSIX.1b.  POSIX.1-2001 では、 B<posix_madvise>(3)  を B<POSIX_MADV_NORMAL>, "
1796 "B<POSIX_MADV_RANDOM> などの定数とともに記述していた (それぞれの振る舞いはここ"
1797 "で述べたものに近い)。 ファイルアクセスに対しても B<posix_fadvise>(2)  という"
1798 "類似の関数が存在する。"
1799
1800 #. type: Plain text
1801 #: build/C/man2/madvise.2:347
1802 msgid ""
1803 "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>, "
1804 "B<MADV_MERGEABLE>, and B<MADV_UNMERGEABLE> are Linux-specific."
1805 msgstr ""
1806 "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>,\n"
1807 "B<MADV_MERGEABLE>, B<MADV_UNMERGEABLE> は Linux 固有である。"
1808
1809 #. type: SS
1810 #: build/C/man2/madvise.2:348 build/C/man2/mlock.2:274
1811 #: build/C/man2/shmget.2:305
1812 #, no-wrap
1813 msgid "Linux notes"
1814 msgstr "Linux での注意"
1815
1816 #. type: Plain text
1817 #: build/C/man2/madvise.2:356
1818 msgid ""
1819 "The current Linux implementation (2.4.0) views this system call more as a "
1820 "command than as advice and hence may return an error when it cannot do what "
1821 "it usually would do in response to this advice.  (See the ERRORS description "
1822 "above.)  This is nonstandard behavior."
1823 msgstr ""
1824 "現在の Linux の実装 (2.4.0) では、 このシステムコールをアドバイスというよりは"
1825 "命令と見ている。 したがってこのアドバイスに対して通常行われる動作が不可能な場"
1826 "合は、 エラーを返すことがある (上記の エラー の記述を参照)。 この振舞いは標準"
1827 "とは異なる。"
1828
1829 #.  .SH HISTORY
1830 #.  The
1831 #.  .BR madvise ()
1832 #.  function first appeared in 4.4BSD.
1833 #. type: Plain text
1834 #: build/C/man2/madvise.2:372
1835 msgid ""
1836 "The Linux implementation requires that the address I<addr> be page-aligned, "
1837 "and allows I<length> to be zero.  If there are some parts of the specified "
1838 "address range that are not mapped, the Linux version of B<madvise>()  "
1839 "ignores them and applies the call to the rest (but returns B<ENOMEM> from "
1840 "the system call, as it should)."
1841 msgstr ""
1842 "Linux の実装では I<addr> のアドレスはページ境界の値でなければならない。また "
1843 "I<length> は 0 であっても構わない。 また Linux 版の B<madvise>()  では、指定"
1844 "されたアドレス範囲にマップされていない部分があると、 これらを無視して残りの部"
1845 "分にアドバイスを適用する (しかしシステムコールに対してはちゃんと B<ENOMEM> を"
1846 "返す)。"
1847
1848 #. type: Plain text
1849 #: build/C/man2/madvise.2:381
1850 msgid ""
1851 "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
1852 "B<munmap>(2), B<prctl>(2), B<core>(5)"
1853 msgstr "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), B<munmap>(2), B<prctl>(2), B<core>(5)"
1854
1855 #. type: TH
1856 #: build/C/man3/mallinfo.3:26
1857 #, no-wrap
1858 msgid "MALLINFO"
1859 msgstr "MALLINFO"
1860
1861 #. type: TH
1862 #: build/C/man3/mallinfo.3:26 build/C/man3/malloc_stats.3:26
1863 #, no-wrap
1864 msgid "2012-05-06"
1865 msgstr "2012-05-06"
1866
1867 #. type: Plain text
1868 #: build/C/man3/mallinfo.3:29
1869 msgid "mallinfo - obtain memory allocation information"
1870 msgstr "mallinfo - メモリ割り当て情報を取得する"
1871
1872 #. type: Plain text
1873 #: build/C/man3/mallinfo.3:31 build/C/man3/malloc_stats.3:31
1874 #: build/C/man3/malloc_trim.3:31 build/C/man3/malloc_usable_size.3:30
1875 #: build/C/man3/mallopt.3:31
1876 msgid "B<#include E<lt>malloc.hE<gt>>"
1877 msgstr "B<#include E<lt>malloc.hE<gt>>"
1878
1879 #. type: Plain text
1880 #: build/C/man3/mallinfo.3:33
1881 msgid "B<struct mallinfo mallinfo(void);>"
1882 msgstr "B<struct mallinfo mallinfo(void);>"
1883
1884 #. type: Plain text
1885 #: build/C/man3/mallinfo.3:41
1886 msgid ""
1887 "The B<mallinfo>()  function returns a copy of a structure containing "
1888 "information about memory allocations performed by B<malloc>(3)  and related "
1889 "functions.  This structure is defined as follows:"
1890 msgstr ""
1891 "B<mallinfo>() 関数は、 B<malloc>(3) や一連の関数により実行されたメモリ\n"
1892 "割り当てに関する情報を格納した構造体のコピーを返す。\n"
1893 "この構造体は以下のように定義されている。"
1894
1895 #. type: Plain text
1896 #: build/C/man3/mallinfo.3:56
1897 #, no-wrap
1898 msgid ""
1899 "struct mallinfo {\n"
1900 "    int arena;     /* Non-mmapped space allocated (bytes) */\n"
1901 "    int ordblks;   /* Number of free chunks */\n"
1902 "    int smblks;    /* Number of free fastbin blocks */\n"
1903 "    int hblks;     /* Number of mmapped regions */\n"
1904 "    int hblkhd;    /* Space allocated in mmapped regions (bytes) */\n"
1905 "    int usmblks;   /* Maximum total allocated space (bytes) */\n"
1906 "    int fsmblks;   /* Space in freed fastbin blocks (bytes) */\n"
1907 "    int uordblks;  /* Total allocated space (bytes) */\n"
1908 "    int fordblks;  /* Total free space (bytes) */\n"
1909 "    int keepcost;  /* Top-most, releasable space (bytes) */\n"
1910 "};\n"
1911 msgstr ""
1912 "struct mallinfo {\n"
1913 "    int arena;     /* Non-mmapped space allocated (bytes) */\n"
1914 "    int ordblks;   /* Number of free chunks */\n"
1915 "    int smblks;    /* Number of free fastbin blocks */\n"
1916 "    int hblks;     /* Number of mmapped regions */\n"
1917 "    int hblkhd;    /* Space allocated in mmapped regions (bytes) */\n"
1918 "    int usmblks;   /* Maximum total allocated space (bytes) */\n"
1919 "    int fsmblks;   /* Space in freed fastbin blocks (bytes) */\n"
1920 "    int uordblks;  /* Total allocated space (bytes) */\n"
1921 "    int fordblks;  /* Total free space (bytes) */\n"
1922 "    int keepcost;  /* Top-most, releasable space (bytes) */\n"
1923 "};\n"
1924
1925 #. type: Plain text
1926 #: build/C/man3/mallinfo.3:62
1927 msgid ""
1928 "The fields of the I<mallinfo> structure contain the following information:"
1929 msgstr "I<mallinfo> 構造体の各フィールドには以下の情報が格納される。"
1930
1931 #. type: TP
1932 #: build/C/man3/mallinfo.3:62
1933 #, no-wrap
1934 msgid "I<arena>"
1935 msgstr "I<arena>"
1936
1937 #. type: Plain text
1938 #: build/C/man3/mallinfo.3:68
1939 msgid ""
1940 "The total amount of memory allocated by means other than B<mmap>(2)  (i.e., "
1941 "memory allocated on the heap).  This figure includes both in-use blocks and "
1942 "blocks on the free list."
1943 msgstr ""
1944
1945 #. type: TP
1946 #: build/C/man3/mallinfo.3:68
1947 #, no-wrap
1948 msgid "I<ordblks>"
1949 msgstr "I<ordblks>"
1950
1951 #. type: Plain text
1952 #: build/C/man3/mallinfo.3:71
1953 msgid "The number of ordinary (i.e., non-fastbin) free blocks."
1954 msgstr ""
1955
1956 #. type: TP
1957 #: build/C/man3/mallinfo.3:71
1958 #, no-wrap
1959 msgid "I<smblks>"
1960 msgstr "I<smblks>"
1961
1962 #. type: Plain text
1963 #: build/C/man3/mallinfo.3:75
1964 msgid "The number of fastbin free blocks (see B<mallopt>(3))."
1965 msgstr ""
1966
1967 #. type: TP
1968 #: build/C/man3/mallinfo.3:75
1969 #, no-wrap
1970 msgid "I<hblks>"
1971 msgstr "I<hblks>"
1972
1973 #. type: Plain text
1974 #: build/C/man3/mallinfo.3:83
1975 msgid ""
1976 "The number of blocks currently allocated using B<mmap>(2).  (See the "
1977 "discussion of B<M_MMAP_THRESHOLD> in B<mallopt>(3).)"
1978 msgstr ""
1979
1980 #. type: TP
1981 #: build/C/man3/mallinfo.3:83
1982 #, no-wrap
1983 msgid "I<hblkhd>"
1984 msgstr "I<hblkhd>"
1985
1986 #. type: Plain text
1987 #: build/C/man3/mallinfo.3:87
1988 msgid "The number of bytes in blocks currently allocated using B<mmap>(2)."
1989 msgstr ""
1990
1991 #. type: TP
1992 #: build/C/man3/mallinfo.3:87
1993 #, no-wrap
1994 msgid "I<usmblks>"
1995 msgstr "I<usmblks>"
1996
1997 #. type: Plain text
1998 #: build/C/man3/mallinfo.3:92
1999 msgid ""
2000 "The \"highwater mark\" for allocated space\\(emthat is, the maximum amount "
2001 "of space that was ever allocated.  This field is maintained only in "
2002 "nonthreading environments."
2003 msgstr ""
2004
2005 #. type: TP
2006 #: build/C/man3/mallinfo.3:92
2007 #, no-wrap
2008 msgid "I<fsmblks>"
2009 msgstr "I<fsmblks>"
2010
2011 #. type: Plain text
2012 #: build/C/man3/mallinfo.3:95
2013 msgid "The total number of bytes in fastbin free blocks."
2014 msgstr ""
2015
2016 #. type: TP
2017 #: build/C/man3/mallinfo.3:95
2018 #, no-wrap
2019 msgid "I<uordblks>"
2020 msgstr "I<uordblks>"
2021
2022 #. type: Plain text
2023 #: build/C/man3/mallinfo.3:98
2024 msgid "The total number of bytes used by in-use allocations."
2025 msgstr ""
2026
2027 #. type: TP
2028 #: build/C/man3/mallinfo.3:98
2029 #, no-wrap
2030 msgid "I<fordblks>"
2031 msgstr "I<fordblks>"
2032
2033 #. type: Plain text
2034 #: build/C/man3/mallinfo.3:101
2035 msgid "The total number of bytes in free blocks."
2036 msgstr ""
2037
2038 #. type: TP
2039 #: build/C/man3/mallinfo.3:101
2040 #, no-wrap
2041 msgid "I<keepcost>"
2042 msgstr "I<keepcost>"
2043
2044 #.  .SH VERSIONS
2045 #.  Available already in glibc 2.0, possibly earlier
2046 #. type: Plain text
2047 #: build/C/man3/mallinfo.3:110
2048 msgid ""
2049 "The total amount of releasable free space at the top of the heap.  This is "
2050 "the maximum number of bytes that could ideally (i.e., ignoring page "
2051 "alignment restrictions, and so on) be released by B<malloc_trim>(3)."
2052 msgstr ""
2053
2054 #. type: Plain text
2055 #: build/C/man3/mallinfo.3:114
2056 msgid ""
2057 "This function is not specified by POSIX or the C standards.  A similar "
2058 "function exists on many System V derivatives, and was specified in the SVID."
2059 msgstr ""
2060
2061 #.  FIXME http://sourceware.org/bugzilla/show_bug.cgi?id=208
2062 #.  See the 24 Aug 2011 mail by Paul Pluzhnikov:
2063 #.      "[patch] Fix mallinfo() to accumulate results for all arenas"
2064 #.  on libc-alpha@sourceware.org
2065 #. type: Plain text
2066 #: build/C/man3/mallinfo.3:126
2067 msgid ""
2068 "B<Information is returned for only the main memory allocation area.> "
2069 "Allocations in other arenas are excluded.  See B<malloc_stats>(3)  and "
2070 "B<malloc_info>(3)  for alternatives that include information about other "
2071 "arenas."
2072 msgstr ""
2073
2074 #. type: Plain text
2075 #: build/C/man3/mallinfo.3:134
2076 msgid ""
2077 "The fields of the I<mallinfo> structure are typed as I<int>.  However, "
2078 "because some internal bookkeeping values may be of type I<long>, the "
2079 "reported values may wrap around zero and thus be inaccurate."
2080 msgstr ""
2081
2082 #. type: SH
2083 #: build/C/man3/mallinfo.3:134 build/C/man3/malloc_hook.3:89
2084 #: build/C/man3/malloc_info.3:84 build/C/man3/mallopt.3:466
2085 #: build/C/man3/mcheck.3:159 build/C/man2/mmap.2:628
2086 #: build/C/man2/mprotect.2:148 build/C/man3/mtrace.3:108
2087 #, no-wrap
2088 msgid "EXAMPLE"
2089 msgstr "例"
2090
2091 #. type: Plain text
2092 #: build/C/man3/mallinfo.3:140
2093 msgid ""
2094 "The program below employs B<mallinfo>()  to retrieve memory allocation "
2095 "statistics before and after allocating and freeing some blocks of memory.  "
2096 "The statistics are displayed on standard output."
2097 msgstr ""
2098
2099 #. type: Plain text
2100 #: build/C/man3/mallinfo.3:144
2101 msgid ""
2102 "The first two command-line arguments specify the number and size of blocks "
2103 "to be allocated with B<malloc>(3)."
2104 msgstr ""
2105
2106 #. type: Plain text
2107 #: build/C/man3/mallinfo.3:158
2108 msgid ""
2109 "The remaining three arguments specify which of the allocated blocks should "
2110 "be freed with B<free>(3).  These three arguments are optional, and specify "
2111 "(in order): the step size to be used in the loop that frees blocks (the "
2112 "default is 1, meaning free all blocks in the range); the ordinal position of "
2113 "the first block to be freed (default 0, meaning the first allocated block); "
2114 "and a number one greater than the ordinal position of the last block to be "
2115 "freed (default is one greater than the maximum block number).  If these "
2116 "three arguments are omitted, then the defaults cause all allocated blocks to "
2117 "be freed."
2118 msgstr ""
2119
2120 #. type: Plain text
2121 #: build/C/man3/mallinfo.3:162
2122 msgid ""
2123 "In the following example run of the program, 1000 allocations of 100 bytes "
2124 "are performed, and then every second allocated block is freed:"
2125 msgstr ""
2126
2127 #. type: Plain text
2128 #: build/C/man3/mallinfo.3:177
2129 #, no-wrap
2130 msgid ""
2131 "$ B<./a.out 1000 100 2>\n"
2132 "============== Before allocating blocks ==============\n"
2133 "Total non-mmapped bytes (arena):       0\n"
2134 "# of free chunks (ordblks):            1\n"
2135 "# of free fastbin blocks (smblks):     0\n"
2136 "# of mapped regions (hblks):           0\n"
2137 "Bytes in mapped regions (hblkhd):      0\n"
2138 "Max. total allocated space (usmblks):  0\n"
2139 "Free bytes held in fastbins (fsmblks): 0\n"
2140 "Total allocated space (uordblks):      0\n"
2141 "Total free space (fordblks):           0\n"
2142 "Topmost releasable block (keepcost):   0\n"
2143 msgstr ""
2144 "$ B<./a.out 1000 100 2>\n"
2145 "============== Before allocating blocks ==============\n"
2146 "Total non-mmapped bytes (arena):       0\n"
2147 "# of free chunks (ordblks):            1\n"
2148 "# of free fastbin blocks (smblks):     0\n"
2149 "# of mapped regions (hblks):           0\n"
2150 "Bytes in mapped regions (hblkhd):      0\n"
2151 "Max. total allocated space (usmblks):  0\n"
2152 "Free bytes held in fastbins (fsmblks): 0\n"
2153 "Total allocated space (uordblks):      0\n"
2154 "Total free space (fordblks):           0\n"
2155 "Topmost releasable block (keepcost):   0\n"
2156
2157 #. type: Plain text
2158 #: build/C/man3/mallinfo.3:189
2159 #, no-wrap
2160 msgid ""
2161 "============== After allocating blocks ==============\n"
2162 "Total non-mmapped bytes (arena):       135168\n"
2163 "# of free chunks (ordblks):            1\n"
2164 "# of free fastbin blocks (smblks):     0\n"
2165 "# of mapped regions (hblks):           0\n"
2166 "Bytes in mapped regions (hblkhd):      0\n"
2167 "Max. total allocated space (usmblks):  0\n"
2168 "Free bytes held in fastbins (fsmblks): 0\n"
2169 "Total allocated space (uordblks):      104000\n"
2170 "Total free space (fordblks):           31168\n"
2171 "Topmost releasable block (keepcost):   31168\n"
2172 msgstr ""
2173 "============== After allocating blocks ==============\n"
2174 "Total non-mmapped bytes (arena):       135168\n"
2175 "# of free chunks (ordblks):            1\n"
2176 "# of free fastbin blocks (smblks):     0\n"
2177 "# of mapped regions (hblks):           0\n"
2178 "Bytes in mapped regions (hblkhd):      0\n"
2179 "Max. total allocated space (usmblks):  0\n"
2180 "Free bytes held in fastbins (fsmblks): 0\n"
2181 "Total allocated space (uordblks):      104000\n"
2182 "Total free space (fordblks):           31168\n"
2183 "Topmost releasable block (keepcost):   31168\n"
2184
2185 #. type: Plain text
2186 #: build/C/man3/mallinfo.3:201
2187 #, no-wrap
2188 msgid ""
2189 "============== After freeing blocks ==============\n"
2190 "Total non-mmapped bytes (arena):       135168\n"
2191 "# of free chunks (ordblks):            501\n"
2192 "# of free fastbin blocks (smblks):     0\n"
2193 "# of mapped regions (hblks):           0\n"
2194 "Bytes in mapped regions (hblkhd):      0\n"
2195 "Max. total allocated space (usmblks):  0\n"
2196 "Free bytes held in fastbins (fsmblks): 0\n"
2197 "Total allocated space (uordblks):      52000\n"
2198 "Total free space (fordblks):           83168\n"
2199 "Topmost releasable block (keepcost):   31168\n"
2200 msgstr ""
2201 "============== After freeing blocks ==============\n"
2202 "Total non-mmapped bytes (arena):       135168\n"
2203 "# of free chunks (ordblks):            501\n"
2204 "# of free fastbin blocks (smblks):     0\n"
2205 "# of mapped regions (hblks):           0\n"
2206 "Bytes in mapped regions (hblkhd):      0\n"
2207 "Max. total allocated space (usmblks):  0\n"
2208 "Free bytes held in fastbins (fsmblks): 0\n"
2209 "Total allocated space (uordblks):      52000\n"
2210 "Total free space (fordblks):           83168\n"
2211 "Topmost releasable block (keepcost):   31168\n"
2212
2213 #. type: SS
2214 #: build/C/man3/mallinfo.3:203 build/C/man3/malloc_info.3:167
2215 #: build/C/man3/mallopt.3:532 build/C/man3/mcheck.3:176
2216 #: build/C/man2/mmap.2:640 build/C/man2/mprotect.2:165
2217 #, no-wrap
2218 msgid "Program source"
2219 msgstr "プログラムのソース"
2220
2221 #. type: Plain text
2222 #: build/C/man3/mallinfo.3:208
2223 #, no-wrap
2224 msgid ""
2225 "#include E<lt>malloc.hE<gt>\n"
2226 "#include \"tlpi_hdr.h\"\n"
2227 msgstr ""
2228 "#include E<lt>malloc.hE<gt>\n"
2229 "#include \"tlpi_hdr.h\"\n"
2230
2231 #. type: Plain text
2232 #: build/C/man3/mallinfo.3:213
2233 #, no-wrap
2234 msgid ""
2235 "static void\n"
2236 "display_mallinfo(void)\n"
2237 "{\n"
2238 "    struct mallinfo mi;\n"
2239 msgstr ""
2240 "static void\n"
2241 "display_mallinfo(void)\n"
2242 "{\n"
2243 "    struct mallinfo mi;\n"
2244
2245 #. type: Plain text
2246 #: build/C/man3/mallinfo.3:215
2247 #, no-wrap
2248 msgid "    mi = mallinfo();\n"
2249 msgstr "    mi = mallinfo();\n"
2250
2251 #. type: Plain text
2252 #: build/C/man3/mallinfo.3:227
2253 #, no-wrap
2254 msgid ""
2255 "    printf(\"Total non-mmapped bytes (arena):       %d\\en\", mi.arena);\n"
2256 "    printf(\"# of free chunks (ordblks):            %d\\en\", mi.ordblks);\n"
2257 "    printf(\"# of free fastbin blocks (smblks):     %d\\en\", mi.smblks);\n"
2258 "    printf(\"# of mapped regions (hblks):           %d\\en\", mi.hblks);\n"
2259 "    printf(\"Bytes in mapped regions (hblkhd):      %d\\en\", mi.hblkhd);\n"
2260 "    printf(\"Max. total allocated space (usmblks):  %d\\en\", mi.usmblks);\n"
2261 "    printf(\"Free bytes held in fastbins (fsmblks): %d\\en\", mi.fsmblks);\n"
2262 "    printf(\"Total allocated space (uordblks):      %d\\en\", mi.uordblks);\n"
2263 "    printf(\"Total free space (fordblks):           %d\\en\", mi.fordblks);\n"
2264 "    printf(\"Topmost releasable block (keepcost):   %d\\en\", mi.keepcost);\n"
2265 "}\n"
2266 msgstr ""
2267 "    printf(\"Total non-mmapped bytes (arena):       %d\\en\", mi.arena);\n"
2268 "    printf(\"# of free chunks (ordblks):            %d\\en\", mi.ordblks);\n"
2269 "    printf(\"# of free fastbin blocks (smblks):     %d\\en\", mi.smblks);\n"
2270 "    printf(\"# of mapped regions (hblks):           %d\\en\", mi.hblks);\n"
2271 "    printf(\"Bytes in mapped regions (hblkhd):      %d\\en\", mi.hblkhd);\n"
2272 "    printf(\"Max. total allocated space (usmblks):  %d\\en\", mi.usmblks);\n"
2273 "    printf(\"Free bytes held in fastbins (fsmblks): %d\\en\", mi.fsmblks);\n"
2274 "    printf(\"Total allocated space (uordblks):      %d\\en\", mi.uordblks);\n"
2275 "    printf(\"Total free space (fordblks):           %d\\en\", mi.fordblks);\n"
2276 "    printf(\"Topmost releasable block (keepcost):   %d\\en\", mi.keepcost);\n"
2277 "}\n"
2278
2279 #. type: Plain text
2280 #: build/C/man3/mallinfo.3:235
2281 #, no-wrap
2282 msgid ""
2283 "int\n"
2284 "main(int argc, char *argv[])\n"
2285 "{\n"
2286 "#define MAX_ALLOCS 2000000\n"
2287 "    char *alloc[MAX_ALLOCS];\n"
2288 "    int numBlocks, j, freeBegin, freeEnd, freeStep;\n"
2289 "    size_t blockSize;\n"
2290 msgstr ""
2291 "int\n"
2292 "main(int argc, char *argv[])\n"
2293 "{\n"
2294 "#define MAX_ALLOCS 2000000\n"
2295 "    char *alloc[MAX_ALLOCS];\n"
2296 "    int numBlocks, j, freeBegin, freeEnd, freeStep;\n"
2297 "    size_t blockSize;\n"
2298
2299 #. type: Plain text
2300 #: build/C/man3/mallinfo.3:239
2301 #, no-wrap
2302 msgid ""
2303 "    if (argc E<lt> 3 || strcmp(argv[1], \"--help\") == 0)\n"
2304 "        usageErr(\"%s num-blocks block-size [free-step [start-free \"\n"
2305 "                \"[end-free]]]\\en\", argv[0]);\n"
2306 msgstr ""
2307 "    if (argc E<lt> 3 || strcmp(argv[1], \"--help\") == 0)\n"
2308 "        usageErr(\"%s num-blocks block-size [free-step [start-free \"\n"
2309 "                \"[end-free]]]\\en\", argv[0]);\n"
2310
2311 #. type: Plain text
2312 #: build/C/man3/mallinfo.3:245
2313 #, no-wrap
2314 msgid ""
2315 "    numBlocks = atoi(argv[1]);\n"
2316 "    blockSize = atoi(argv[2]);\n"
2317 "    freeStep = (argc E<gt> 3) ? atoi(argv[3]) : 1;\n"
2318 "    freeBegin = (argc E<gt> 4) ? atoi(argv[4]) : 0;\n"
2319 "    freeEnd = (argc E<gt> 5) ? atoi(argv[5]) : numBlocks;\n"
2320 msgstr ""
2321 "    numBlocks = atoi(argv[1]);\n"
2322 "    blockSize = atoi(argv[2]);\n"
2323 "    freeStep = (argc E<gt> 3) ? atoi(argv[3]) : 1;\n"
2324 "    freeBegin = (argc E<gt> 4) ? atoi(argv[4]) : 0;\n"
2325 "    freeEnd = (argc E<gt> 5) ? atoi(argv[5]) : numBlocks;\n"
2326
2327 #. type: Plain text
2328 #: build/C/man3/mallinfo.3:248
2329 #, no-wrap
2330 msgid ""
2331 "    printf(\"============== Before allocating blocks ==============\\en\");\n"
2332 "    display_mallinfo();\n"
2333 msgstr ""
2334 "    printf(\"============== Before allocating blocks ==============\\en\");\n"
2335 "    display_mallinfo();\n"
2336
2337 #. type: Plain text
2338 #: build/C/man3/mallinfo.3:252
2339 #, no-wrap
2340 msgid ""
2341 "    for (j = 0; j E<lt> numBlocks; j++) {\n"
2342 "        if (numBlocks E<gt>= MAX_ALLOCS)\n"
2343 "            fatal(\"Too many allocations\");\n"
2344 msgstr ""
2345 "    for (j = 0; j E<lt> numBlocks; j++) {\n"
2346 "        if (numBlocks E<gt>= MAX_ALLOCS)\n"
2347 "            fatal(\"Too many allocations\");\n"
2348
2349 #. type: Plain text
2350 #: build/C/man3/mallinfo.3:257
2351 #, no-wrap
2352 msgid ""
2353 "        alloc[j] = malloc(blockSize);\n"
2354 "        if (alloc[j] == NULL)\n"
2355 "            errExit(\"malloc\");\n"
2356 "    }\n"
2357 msgstr ""
2358 "        alloc[j] = malloc(blockSize);\n"
2359 "        if (alloc[j] == NULL)\n"
2360 "            errExit(\"malloc\");\n"
2361 "    }\n"
2362
2363 #. type: Plain text
2364 #: build/C/man3/mallinfo.3:260
2365 #, no-wrap
2366 msgid ""
2367 "    printf(\"\\en============== After allocating blocks ==============\\en\");\n"
2368 "    display_mallinfo();\n"
2369 msgstr ""
2370 "    printf(\"\\en============== After allocating blocks ==============\\en\");\n"
2371 "    display_mallinfo();\n"
2372
2373 #. type: Plain text
2374 #: build/C/man3/mallinfo.3:263
2375 #, no-wrap
2376 msgid ""
2377 "    for (j = freeBegin; j E<lt> freeEnd; j += freeStep)\n"
2378 "        free(alloc[j]);\n"
2379 msgstr ""
2380 "    for (j = freeBegin; j E<lt> freeEnd; j += freeStep)\n"
2381 "        free(alloc[j]);\n"
2382
2383 #. type: Plain text
2384 #: build/C/man3/mallinfo.3:266
2385 #, no-wrap
2386 msgid ""
2387 "    printf(\"\\en============== After freeing blocks ==============\\en\");\n"
2388 "    display_mallinfo();\n"
2389 msgstr ""
2390 "    printf(\"\\en============== After freeing blocks ==============\\en\");\n"
2391 "    display_mallinfo();\n"
2392
2393 #. type: Plain text
2394 #: build/C/man3/mallinfo.3:269 build/C/man3/malloc_info.3:255
2395 #: build/C/man3/mallopt.3:565 build/C/man3/mcheck.3:203
2396 #: build/C/man2/mmap.2:709
2397 #, no-wrap
2398 msgid ""
2399 "    exit(EXIT_SUCCESS);\n"
2400 "}\n"
2401 msgstr ""
2402 "    exit(EXIT_SUCCESS);\n"
2403 "}\n"
2404
2405 #. type: Plain text
2406 #: build/C/man3/mallinfo.3:279
2407 msgid ""
2408 "B<mmap>(2), B<malloc>(3), B<malloc_info>(3), B<malloc_stats>(3), "
2409 "B<malloc_trim>(3), B<mallopt>(3)"
2410 msgstr ""
2411 "B<mmap>(2), B<malloc>(3), B<malloc_info>(3), B<malloc_stats>(3), "
2412 "B<malloc_trim>(3), B<mallopt>(3)"
2413
2414 #. type: TH
2415 #: build/C/man3/malloc_get_state.3:25
2416 #, no-wrap
2417 msgid "MALLOC_GET_STATE"
2418 msgstr "MALLOC_GET_STATE"
2419
2420 #. type: TH
2421 #: build/C/man3/malloc_get_state.3:25
2422 #, no-wrap
2423 msgid "2012-05-04"
2424 msgstr "2012-05-04"
2425
2426 #. type: Plain text
2427 #: build/C/man3/malloc_get_state.3:28
2428 msgid ""
2429 "malloc_get_state, malloc_set_state - record and restore state of malloc "
2430 "implementation"
2431 msgstr ""
2432
2433 #. type: Plain text
2434 #: build/C/man3/malloc_get_state.3:31 build/C/man3/posix_memalign.3:35
2435 #, no-wrap
2436 msgid "B<#include E<lt>stdlib.hE<gt>>\n"
2437 msgstr "B<#include E<lt>stdlib.hE<gt>>\n"
2438
2439 #. type: Plain text
2440 #: build/C/man3/malloc_get_state.3:33
2441 #, no-wrap
2442 msgid "B<void* malloc_get_state(void);>\n"
2443 msgstr "B<void* malloc_get_state(void);>\n"
2444
2445 #. type: Plain text
2446 #: build/C/man3/malloc_get_state.3:35
2447 #, no-wrap
2448 msgid "B<int malloc_set_state(void *>I<state>B<);>\n"
2449 msgstr "B<int malloc_set_state(void *>I<state>B<);>\n"
2450
2451 #. type: Plain text
2452 #: build/C/man3/malloc_get_state.3:53
2453 msgid ""
2454 "The B<malloc_get_state>()  function records the current state of all "
2455 "B<malloc>(3)  internal bookkeeping variables (but not the actual contents of "
2456 "the heap or the state of B<malloc_hook>(3)  functions pointers).  The state "
2457 "is recorded in a system-dependent opaque data structure dynamically "
2458 "allocated via B<malloc>(3), and a pointer to that data structure is returned "
2459 "as the function result.  (It is the caller's responsibility to B<free>(3)  "
2460 "this memory.)"
2461 msgstr ""
2462
2463 #. type: Plain text
2464 #: build/C/man3/malloc_get_state.3:61
2465 msgid ""
2466 "The B<malloc_set_state>()  function restores the state of all B<malloc>(3)  "
2467 "internal bookkeeping variables to the values recorded in the opaque data "
2468 "structure pointed to by I<state>."
2469 msgstr ""
2470
2471 #. type: Plain text
2472 #: build/C/man3/malloc_get_state.3:68
2473 msgid ""
2474 "On success, B<malloc_get_state>()  returns a pointer to a newly allocated "
2475 "opaque data structure.  On error (for example, memory could not be allocated "
2476 "for the data structure), B<malloc_get_state>()  returns NULL."
2477 msgstr ""
2478
2479 #.  if(ms->magic != MALLOC_STATE_MAGIC) return -1;
2480 #.  /* Must fail if the major version is too high. */
2481 #.  if((ms->version & ~0xffl) > (MALLOC_STATE_VERSION & ~0xffl)) return -2;
2482 #. type: Plain text
2483 #: build/C/man3/malloc_get_state.3:86
2484 msgid ""
2485 "On success, B<malloc_set_state>()  returns 0.  If the implementation detects "
2486 "that I<state> does not point to a correctly formed data structure, "
2487 "B<malloc_set_state>()  returns -1.  If the implementation detects that the "
2488 "version of the data structure referred to by I<state> is a more recent "
2489 "version than this implementation knows about, B<malloc_set_state>()  returns "
2490 "-2."
2491 msgstr ""
2492
2493 #. type: Plain text
2494 #: build/C/man3/malloc_get_state.3:88 build/C/man3/malloc_hook.3:82
2495 #: build/C/man3/mcheck.3:147 build/C/man3/mtrace.3:80
2496 msgid "These functions are GNU extensions."
2497 msgstr "これらの関数は GNU による拡張である。"
2498
2499 #. type: Plain text
2500 #: build/C/man3/malloc_get_state.3:94
2501 msgid ""
2502 "These functions are especially useful when using this B<malloc>(3)  "
2503 "implementation as part of a shared library, and the heap contents are saved/"
2504 "restored via some other method.  This technique is used by the GNU Emacs to "
2505 "implement its \"dumping\" function."
2506 msgstr ""
2507
2508 #.  i.e., calls __malloc_check_init()
2509 #.  i.e., malloc checking is not already in use
2510 #.  and the caller requested malloc checking
2511 #. type: Plain text
2512 #: build/C/man3/malloc_get_state.3:111
2513 msgid ""
2514 "Hook function pointers are never saved or restored by these functions, with "
2515 "two exceptions: if malloc checking (see B<mallopt>(3))  was in use when "
2516 "B<malloc_get_state>()  was called, then B<malloc_set_state>()  resets malloc "
2517 "checking hooks if possible; if malloc checking was not in use in the "
2518 "recorded state, but the caller has requested malloc checking, then the hooks "
2519 "are reset to 0."
2520 msgstr ""
2521
2522 #. type: Plain text
2523 #: build/C/man3/malloc_get_state.3:114
2524 msgid "B<malloc>(3), B<mallopt>(3)"
2525 msgstr "B<malloc>(3), B<mallopt>(3)"
2526
2527 #. type: TH
2528 #: build/C/man3/malloc_hook.3:10
2529 #, no-wrap
2530 msgid "MALLOC_HOOK"
2531 msgstr "MALLOC_HOOK"
2532
2533 #. type: TH
2534 #: build/C/man3/malloc_hook.3:10
2535 #, no-wrap
2536 msgid "2010-10-13"
2537 msgstr "2010-10-13"
2538
2539 #. type: Plain text
2540 #: build/C/man3/malloc_hook.3:15
2541 msgid ""
2542 "__malloc_hook, __malloc_initialize_hook, __memalign_hook, __free_hook, "
2543 "__realloc_hook, __after_morecore_hook - malloc debugging variables"
2544 msgstr ""
2545 "__malloc_hook, __malloc_initialize_hook, __memalign_hook, __free_hook, "
2546 "__realloc_hook, __after_morecore_hook - malloc デバッグ用の変数"
2547
2548 #. type: Plain text
2549 #: build/C/man3/malloc_hook.3:18 build/C/man3/malloc_info.3:31
2550 #: build/C/man3/posix_memalign.3:41
2551 #, no-wrap
2552 msgid "B<#include E<lt>malloc.hE<gt>>\n"
2553 msgstr "B<#include E<lt>malloc.hE<gt>>\n"
2554
2555 #. type: Plain text
2556 #: build/C/man3/malloc_hook.3:20
2557 #, no-wrap
2558 msgid "B<void *(*__malloc_hook)(size_t >I<size>B<, const void *>I<caller>B<);>\n"
2559 msgstr "B<void *(*__malloc_hook)(size_t >I<size>B<, const void *>I<caller>B<);>\n"
2560
2561 #. type: Plain text
2562 #: build/C/man3/malloc_hook.3:23
2563 #, no-wrap
2564 msgid "B<void *(*__realloc_hook)(void *>I<ptr>B<, size_t >I<size>B<, const void *>I<caller>B<);>\n"
2565 msgstr "B<void *(*__realloc_hook)(void *>I<ptr>B<, size_t >I<size>B<, const void *>I<caller>B<);>\n"
2566
2567 #. type: Plain text
2568 #: build/C/man3/malloc_hook.3:26
2569 #, no-wrap
2570 msgid ""
2571 "B<void *(*__memalign_hook)(size_t >I<alignment>B<, size_t >I<size>B<,>\n"
2572 "B<                         const void *>I<caller>B<);>\n"
2573 msgstr ""
2574 "B<void *(*__memalign_hook)(size_t >I<alignment>B<, size_t >I<size>B<,>\n"
2575 "B<                         const void *>I<caller>B<);>\n"
2576
2577 #. type: Plain text
2578 #: build/C/man3/malloc_hook.3:28
2579 #, no-wrap
2580 msgid "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
2581 msgstr "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
2582
2583 #. type: Plain text
2584 #: build/C/man3/malloc_hook.3:30
2585 #, no-wrap
2586 msgid "B<void (*__malloc_initialize_hook)(void);>\n"
2587 msgstr "B<void (*__malloc_initialize_hook)(void);>\n"
2588
2589 #. type: Plain text
2590 #: build/C/man3/malloc_hook.3:32
2591 #, no-wrap
2592 msgid "B<void (*__after_morecore_hook)(void);>\n"
2593 msgstr "B<void (*__after_morecore_hook)(void);>\n"
2594
2595 #. type: Plain text
2596 #: build/C/man3/malloc_hook.3:43
2597 msgid ""
2598 "The GNU C library lets you modify the behavior of B<malloc>(3), B<realloc>"
2599 "(3), and B<free>(3)  by specifying appropriate hook functions.  You can use "
2600 "these hooks to help you debug programs that use dynamic memory allocation, "
2601 "for example."
2602 msgstr ""
2603 "GNU C ライブラリでは、適切なフック関数 (hook function) を指定することで "
2604 "B<malloc>(3), B<realloc>(3), B<free>(3)  の動作を変更することができる。例え"
2605 "ば、動的にメモリ割り当てを行う プログラムのデバッグにこれらのフックを使うこと"
2606 "ができる。"
2607
2608 #. type: Plain text
2609 #: build/C/man3/malloc_hook.3:50
2610 msgid ""
2611 "The variable B<__malloc_initialize_hook> points at a function that is called "
2612 "once when the malloc implementation is initialized.  This is a weak "
2613 "variable, so it can be overridden in the application with a definition like "
2614 "the following:"
2615 msgstr ""
2616 "変数 B<__malloc_initialize_hook> は malloc の実装が初期化される際に一度だけ呼"
2617 "ばれる関数へのポインタである。 この変数は書き換え可能 (weak) であり、アプリ"
2618 "ケーション内で 以下のような定義で上書きできる:"
2619
2620 #. type: Plain text
2621 #: build/C/man3/malloc_hook.3:53
2622 #, no-wrap
2623 msgid "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
2624 msgstr "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
2625
2626 #. type: Plain text
2627 #: build/C/man3/malloc_hook.3:58
2628 msgid ""
2629 "Now the function I<my_init_hook>()  can do the initialization of all hooks."
2630 msgstr ""
2631 "なお、関数 I<my_init_hook>()  で全てのフックの初期化をすることができる。"
2632
2633 #. type: Plain text
2634 #: build/C/man3/malloc_hook.3:74
2635 msgid ""
2636 "The four functions pointed to by B<__malloc_hook>, B<__realloc_hook>, "
2637 "B<__memalign_hook>, B<__free_hook> have a prototype like the functions "
2638 "B<malloc>(3), B<realloc>(3), B<memalign>(3), B<free>(3), respectively, "
2639 "except that they have a final argument I<caller> that gives the address of "
2640 "the caller of B<malloc>(3), etc."
2641 msgstr ""
2642 "B<__malloc_hook>, B<__realloc_hook>, B<__memalign_hook>, B<__free_hook> で指"
2643 "される 4 つの関数は、各々 B<malloc>(3), B<realloc>(3), B<memalign>(3), "
2644 "B<free>(3)  とよく似たプロトタイプを持っているが、 一番最後の引き数 "
2645 "I<caller> をとる点が異なる。 引き数 I<caller> には、 B<malloc>(3)  などの呼び"
2646 "出し元 (caller) のアドレスが格納される。"
2647
2648 #. type: Plain text
2649 #: build/C/man3/malloc_hook.3:80
2650 msgid ""
2651 "The variable B<__after_morecore_hook> points at a function that is called "
2652 "each time after B<sbrk>(2)  was asked for more memory."
2653 msgstr ""
2654 "変数 B<__after_morecore_hook> は、領域の追加要求があり B<sbrk>(2)  が呼ばれた"
2655 "後で毎回呼び出される関数へのポインタである。"
2656
2657 #.  https://bugzilla.redhat.com/show_bug.cgi?id=450187
2658 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=9957
2659 #. type: Plain text
2660 #: build/C/man3/malloc_hook.3:89
2661 msgid ""
2662 "The use of these hook functions is not safe in multithreaded programs, and "
2663 "they are now deprecated.  Programmers should instead preempt calls to the "
2664 "relevant functions by defining and exporting functions such as \"malloc\" "
2665 "and \"free\"."
2666 msgstr ""
2667 "マルチスレッドプログラムでは、 これらのフック関数の使用は安全ではなく、 今で"
2668 "は非推奨である。 プログラマは、 \"malloc\" や \"free\" のような関数を定義して"
2669 "公開して、 関連する関数を呼び出すようにすべきである。"
2670
2671 #. type: Plain text
2672 #: build/C/man3/malloc_hook.3:91
2673 msgid "Here is a short example of how to use these variables."
2674 msgstr "これらの変数の使い方の簡単な例を以下に示す。"
2675
2676 #. type: Plain text
2677 #: build/C/man3/malloc_hook.3:95
2678 #, no-wrap
2679 msgid ""
2680 "#include E<lt>stdio.hE<gt>\n"
2681 "#include E<lt>malloc.hE<gt>\n"
2682 msgstr ""
2683 "#include E<lt>stdio.hE<gt>\n"
2684 "#include E<lt>malloc.hE<gt>\n"
2685
2686 #. type: Plain text
2687 #: build/C/man3/malloc_hook.3:99
2688 #, no-wrap
2689 msgid ""
2690 "/* Prototypes for our hooks.  */\n"
2691 "static void my_init_hook(void);\n"
2692 "static void *my_malloc_hook(size_t, const void *);\n"
2693 msgstr ""
2694 "/* 使おうとするフックのプロトタイプ宣言 */\n"
2695 "static void my_init_hook(void);\n"
2696 "static void *my_malloc_hook(size_t, const void *);\n"
2697
2698 #. type: Plain text
2699 #: build/C/man3/malloc_hook.3:102
2700 #, no-wrap
2701 msgid ""
2702 "/* Variables to save original hooks. */\n"
2703 "static void *(*old_malloc_hook)(size_t, const void *);\n"
2704 msgstr ""
2705 "/* 元々のフックを保存するための変数 */\n"
2706 "static void *(*old_malloc_hook)(size_t, const void *);\n"
2707
2708 #. type: Plain text
2709 #: build/C/man3/malloc_hook.3:105
2710 #, no-wrap
2711 msgid ""
2712 "/* Override initializing hook from the C library. */\n"
2713 "void (*__malloc_initialize_hook) (void) = my_init_hook;\n"
2714 msgstr ""
2715 "/* C ライブラリから呼ばれる初期化フックを上書きする */\n"
2716 "void (*__malloc_initialize_hook) (void) = my_init_hook;\n"
2717
2718 #. type: Plain text
2719 #: build/C/man3/malloc_hook.3:112
2720 #, no-wrap
2721 msgid ""
2722 "static void\n"
2723 "my_init_hook(void)\n"
2724 "{\n"
2725 "    old_malloc_hook = __malloc_hook;\n"
2726 "    __malloc_hook = my_malloc_hook;\n"
2727 "}\n"
2728 msgstr ""
2729 "static void\n"
2730 "my_init_hook(void)\n"
2731 "{\n"
2732 "    old_malloc_hook = __malloc_hook;\n"
2733 "    __malloc_hook = my_malloc_hook;\n"
2734 "}\n"
2735
2736 #. type: Plain text
2737 #: build/C/man3/malloc_hook.3:117
2738 #, no-wrap
2739 msgid ""
2740 "static void *\n"
2741 "my_malloc_hook(size_t size, const void *caller)\n"
2742 "{\n"
2743 "    void *result;\n"
2744 msgstr ""
2745 "static void *\n"
2746 "my_malloc_hook(size_t size, const void *caller)\n"
2747 "{\n"
2748 "    void *result;\n"
2749
2750 #. type: Plain text
2751 #: build/C/man3/malloc_hook.3:120
2752 #, no-wrap
2753 msgid ""
2754 "    /* Restore all old hooks */\n"
2755 "    __malloc_hook = old_malloc_hook;\n"
2756 msgstr ""
2757 "    /* 元々のフックを全て戻す */\n"
2758 "    __malloc_hook = old_malloc_hook;\n"
2759
2760 #. type: Plain text
2761 #: build/C/man3/malloc_hook.3:123
2762 #, no-wrap
2763 msgid ""
2764 "    /* Call recursively */\n"
2765 "    result = malloc(size);\n"
2766 msgstr ""
2767 "    /* malloc の再帰的呼び出し */\n"
2768 "    result = malloc(size);\n"
2769
2770 #. type: Plain text
2771 #: build/C/man3/malloc_hook.3:126
2772 #, no-wrap
2773 msgid ""
2774 "    /* Save underlying hooks */\n"
2775 "    old_malloc_hook = __malloc_hook;\n"
2776 msgstr ""
2777 "    /* 現在設定されているフック (underlying hook) を保存する */\n"
2778 "    old_malloc_hook = __malloc_hook;\n"
2779
2780 #. type: Plain text
2781 #: build/C/man3/malloc_hook.3:130
2782 #, no-wrap
2783 msgid ""
2784 "    /* printf() might call malloc(), so protect it too. */\n"
2785 "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
2786 "            (unsigned int) size, caller, result);\n"
2787 msgstr ""
2788 "    /* printf() は malloc() を呼び出す可能性があるので\n"
2789 "        ここでもガードを行う (元々のフックのままにしておく) */\n"
2790 "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
2791 "            (unsigned int) size, caller, result);\n"
2792
2793 #. type: Plain text
2794 #: build/C/man3/malloc_hook.3:133
2795 #, no-wrap
2796 msgid ""
2797 "    /* Restore our own hooks */\n"
2798 "    __malloc_hook = my_malloc_hook;\n"
2799 msgstr ""
2800 "    /* ユーザが使おうとするフックを再設定する */\n"
2801 "    __malloc_hook = my_malloc_hook;\n"
2802
2803 #. type: Plain text
2804 #: build/C/man3/malloc_hook.3:136
2805 #, no-wrap
2806 msgid ""
2807 "    return result;\n"
2808 "}\n"
2809 msgstr ""
2810 "    return result;\n"
2811 "}\n"
2812
2813 #. type: Plain text
2814 #: build/C/man3/malloc_hook.3:142
2815 msgid "B<mallinfo>(3), B<malloc>(3), B<mcheck>(3), B<mtrace>(3)"
2816 msgstr "B<mallinfo>(3), B<malloc>(3), B<mcheck>(3), B<mtrace>(3)"
2817
2818 #. type: TH
2819 #: build/C/man3/malloc_info.3:25
2820 #, no-wrap
2821 msgid "MALLOC_INFO"
2822 msgstr "MALLOC_INFO"
2823
2824 #. type: TH
2825 #: build/C/man3/malloc_info.3:25
2826 #, no-wrap
2827 msgid "2013-04-19"
2828 msgstr "2013-04-19"
2829
2830 #. type: Plain text
2831 #: build/C/man3/malloc_info.3:28
2832 msgid "malloc_info - export malloc state to a stream"
2833 msgstr "malloc_info - malloc の状態をストリームに出力する"
2834
2835 #. type: Plain text
2836 #: build/C/man3/malloc_info.3:33
2837 #, no-wrap
2838 msgid "B<int malloc_info(int >I<options>B<, FILE *>I<fp>B<);>\n"
2839 msgstr "B<int malloc_info(int >I<options>B<, FILE *>I<fp>B<);>\n"
2840
2841 #. type: Plain text
2842 #: build/C/man3/malloc_info.3:44
2843 msgid ""
2844 "The B<malloc_info>()  function exports an XML string that describes the "
2845 "current state of the memory-allocation implementation in the caller.  The "
2846 "string is printed on the file stream I<fp>.  The exported string includes "
2847 "information about all arenas (see B<malloc>(3))."
2848 msgstr ""
2849 "B<malloc_info>() 関数は、 呼び出し元のメモリ割り当て実装の現在の状態を表す "
2850 "XML 文字列を出力する。 文字列は、 ファイルストリーム I<fp> に出力される。 出"
2851 "力された文字列には、 全ての割り当て領域の情報が含まれる (B<malloc>(3) 参照)。"
2852
2853 #. type: Plain text
2854 #: build/C/man3/malloc_info.3:48
2855 msgid "As currently implemented, I<options> must be zero."
2856 msgstr "現在の実装では、 I<options> は 0 でなければならない。"
2857
2858 #. type: Plain text
2859 #: build/C/man3/malloc_info.3:55
2860 msgid ""
2861 "On success, B<malloc_info>()  returns 0; on error, it returns -1, with "
2862 "I<errno> set to indicate the cause."
2863 msgstr ""
2864 "B<malloc_info>() は、成功すると 0 を返す。 エラーの場合、-1 を返し、 "
2865 "I<errno> にエラーの原因を示す値を設定する。"
2866
2867 #. type: Plain text
2868 #: build/C/man3/malloc_info.3:60
2869 msgid "I<options> was nonzero."
2870 msgstr "I<options> が 0 でなかった。"
2871
2872 #. type: Plain text
2873 #: build/C/man3/malloc_info.3:63
2874 msgid "B<malloc_info>()  was added to glibc in version 2.10."
2875 msgstr "B<malloc_info>() は glibc バージョン 2.10 で追加された。"
2876
2877 #. type: Plain text
2878 #: build/C/man3/malloc_info.3:65 build/C/man3/malloc_stats.3:57
2879 #: build/C/man3/malloc_trim.3:62 build/C/man3/malloc_usable_size.3:50
2880 msgid "This function is a GNU extension."
2881 msgstr "この関数は GNU による拡張である。"
2882
2883 #. type: Plain text
2884 #: build/C/man3/malloc_info.3:71
2885 msgid ""
2886 "The memory-allocation information is provided as an XML string (rather than "
2887 "a C structure)  because the information may change over time (according to "
2888 "changes in the underlying implementation).  The output XML string includes a "
2889 "version field."
2890 msgstr ""
2891 "メモリ割り当て情報は (C の構造体ではなく) XML 文字列として提供される。 これ"
2892 "は、 この情報は時間をたつと (内部で使用している実装によって) 変わる可能性があ"
2893 "るからである。 出力される XML 文字列にはバージョンフィールドが付いている。"
2894
2895 #. type: Plain text
2896 #: build/C/man3/malloc_info.3:77
2897 msgid ""
2898 "The B<open_memstream>(3)  function can be used to send the output of "
2899 "B<malloc_info>()  directly into a buffer in memory, rather than to a file."
2900 msgstr ""
2901 "B<open_memstream>(3) 関数を使うと、 B<malloc_info>() の出力を、 ファイルでは"
2902 "なくメモリ内のバッファに直接送ることができる。"
2903
2904 #. type: Plain text
2905 #: build/C/man3/malloc_info.3:84
2906 msgid ""
2907 "The B<malloc_info>()  function is designed to address deficiencies in "
2908 "B<malloc_stats>(3)  and B<mallinfo>(3)."
2909 msgstr ""
2910 "B<malloc_info>() 関数は、 B<malloc_stats>(3) と B<mallinfo>(3) の不備を解決す"
2911 "るために設定された。"
2912
2913 #. type: Plain text
2914 #: build/C/man3/malloc_info.3:95
2915 msgid ""
2916 "The program below takes up to four command-line arguments, of which the "
2917 "first three are mandatory.  The first argument specifies the number of "
2918 "threads that the program should create.  All of the threads, including the "
2919 "main thread, allocate the number of blocks of memory specified by the second "
2920 "argument.  The third argument controls the size of the blocks to be "
2921 "allocated.  The main thread creates blocks of this size, the second thread "
2922 "created by the program allocates blocks of twice this size, the third thread "
2923 "allocates blocks of three times this size, and so on."
2924 msgstr ""
2925 "以下のプログラムは最大で 4 つのコマンドライン引数を取り、 最初の 3 つは必須で"
2926 "ある。 最初の引数は、このプログラムが生成するスレッド数を指定する。 メインス"
2927 "レッドを含む全てのスレッドが第 2 引数で指定した数のメモリブロックの割り当てを"
2928 "行う。 第 3 引数は割り当てるブロックのサイズを制御する。 メインスレッドはこの"
2929 "サイズのブロックを作成し、 このプログラムが生成する 2 番目のスレッドはこのサ"
2930 "イズの 2 倍のサイズのブロックを、 3 番目のスレッドはこのサイズの 3 倍のサイズ"
2931 "のブロックを割り当て、 以下同様である。"
2932
2933 #. type: Plain text
2934 #: build/C/man3/malloc_info.3:102
2935 msgid ""
2936 "The program calls B<malloc_info>()  twice to display the memory-allocation "
2937 "state.  The first call takes place before any threads are created or memory "
2938 "allocated.  The second call is performed after all threads have allocated "
2939 "memory."
2940 msgstr ""
2941 "このプログラムは B<malloc_info>() を 2 回呼び出し、メモリ割り当て状態を表示す"
2942 "る。 最初の呼び出しはスレッドの生成もメモリの割り当ても行われる前に実行され"
2943 "る。 2 回目の呼び出しは全てのスレッドがメモリ割り当てを行った後に実行される。"
2944
2945 #. type: Plain text
2946 #: build/C/man3/malloc_info.3:110
2947 msgid ""
2948 "In the following example, the command-line arguments specify the creation of "
2949 "one additional thread, and both the main thread and the additional thread "
2950 "allocate 10000 blocks of memory.  After the blocks of memory have been "
2951 "allocated, B<malloc_info>()  shows the state of two allocation arenas."
2952 msgstr ""
2953 "以下の例では、 コマンドライン引数で、 追加でスレッドを一つ生成し、メインス"
2954 "レッドと追加のスレッドの両方が 10000 個のメモリブロックを割り当てるように指定"
2955 "している。 メモリブロックの割り当て後の B<malloc_info>() では、 2 つの割り当"
2956 "て領域の状態が表示されている。"
2957
2958 #. type: Plain text
2959 #: build/C/man3/malloc_info.3:135
2960 #, no-wrap
2961 msgid ""
2962 "$ B<getconf GNU_LIBC_VERSION>\n"
2963 "glibc 2.13\n"
2964 "$ B<./a.out 1 10000 100>\n"
2965 "============ Before allocating blocks ============\n"
2966 "E<lt>malloc version=\"1\"E<gt>\n"
2967 "E<lt>heap nr=\"0\"E<gt>\n"
2968 "E<lt>sizesE<gt>\n"
2969 "E<lt>/sizesE<gt>\n"
2970 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
2971 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
2972 "E<lt>system type=\"current\" size=\"135168\"/E<gt>\n"
2973 "E<lt>system type=\"max\" size=\"135168\"/E<gt>\n"
2974 "E<lt>aspace type=\"total\" size=\"135168\"/E<gt>\n"
2975 "E<lt>aspace type=\"mprotect\" size=\"135168\"/E<gt>\n"
2976 "E<lt>/heapE<gt>\n"
2977 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
2978 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
2979 "E<lt>system type=\"current\" size=\"135168\"/E<gt>\n"
2980 "E<lt>system type=\"max\" size=\"135168\"/E<gt>\n"
2981 "E<lt>aspace type=\"total\" size=\"135168\"/E<gt>\n"
2982 "E<lt>aspace type=\"mprotect\" size=\"135168\"/E<gt>\n"
2983 "E<lt>/mallocE<gt>\n"
2984 msgstr ""
2985 "$ B<getconf GNU_LIBC_VERSION>\n"
2986 "glibc 2.13\n"
2987 "$ B<./a.out 1 10000 100>\n"
2988 "============ Before allocating blocks ============\n"
2989 "E<lt>malloc version=\"1\"E<gt>\n"
2990 "E<lt>heap nr=\"0\"E<gt>\n"
2991 "E<lt>sizesE<gt>\n"
2992 "E<lt>/sizesE<gt>\n"
2993 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
2994 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
2995 "E<lt>system type=\"current\" size=\"135168\"/E<gt>\n"
2996 "E<lt>system type=\"max\" size=\"135168\"/E<gt>\n"
2997 "E<lt>aspace type=\"total\" size=\"135168\"/E<gt>\n"
2998 "E<lt>aspace type=\"mprotect\" size=\"135168\"/E<gt>\n"
2999 "E<lt>/heapE<gt>\n"
3000 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3001 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3002 "E<lt>system type=\"current\" size=\"135168\"/E<gt>\n"
3003 "E<lt>system type=\"max\" size=\"135168\"/E<gt>\n"
3004 "E<lt>aspace type=\"total\" size=\"135168\"/E<gt>\n"
3005 "E<lt>aspace type=\"mprotect\" size=\"135168\"/E<gt>\n"
3006 "E<lt>/mallocE<gt>\n"
3007
3008 #. type: Plain text
3009 #: build/C/man3/malloc_info.3:165
3010 #, no-wrap
3011 msgid ""
3012 "============ After allocating blocks ============\n"
3013 "E<lt>malloc version=\"1\"E<gt>\n"
3014 "E<lt>heap nr=\"0\"E<gt>\n"
3015 "E<lt>sizesE<gt>\n"
3016 "E<lt>/sizesE<gt>\n"
3017 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3018 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3019 "E<lt>system type=\"current\" size=\"1081344\"/E<gt>\n"
3020 "E<lt>system type=\"max\" size=\"1081344\"/E<gt>\n"
3021 "E<lt>aspace type=\"total\" size=\"1081344\"/E<gt>\n"
3022 "E<lt>aspace type=\"mprotect\" size=\"1081344\"/E<gt>\n"
3023 "E<lt>/heapE<gt>\n"
3024 "E<lt>heap nr=\"1\"E<gt>\n"
3025 "E<lt>sizesE<gt>\n"
3026 "E<lt>/sizesE<gt>\n"
3027 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3028 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3029 "E<lt>system type=\"current\" size=\"1032192\"/E<gt>\n"
3030 "E<lt>system type=\"max\" size=\"1032192\"/E<gt>\n"
3031 "E<lt>aspace type=\"total\" size=\"1032192\"/E<gt>\n"
3032 "E<lt>aspace type=\"mprotect\" size=\"1032192\"/E<gt>\n"
3033 "E<lt>/heapE<gt>\n"
3034 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3035 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3036 "E<lt>system type=\"current\" size=\"2113536\"/E<gt>\n"
3037 "E<lt>system type=\"max\" size=\"2113536\"/E<gt>\n"
3038 "E<lt>aspace type=\"total\" size=\"2113536\"/E<gt>\n"
3039 "E<lt>aspace type=\"mprotect\" size=\"2113536\"/E<gt>\n"
3040 "E<lt>/mallocE<gt>\n"
3041 msgstr ""
3042 "============ After allocating blocks ============\n"
3043 "E<lt>malloc version=\"1\"E<gt>\n"
3044 "E<lt>heap nr=\"0\"E<gt>\n"
3045 "E<lt>sizesE<gt>\n"
3046 "E<lt>/sizesE<gt>\n"
3047 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3048 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3049 "E<lt>system type=\"current\" size=\"1081344\"/E<gt>\n"
3050 "E<lt>system type=\"max\" size=\"1081344\"/E<gt>\n"
3051 "E<lt>aspace type=\"total\" size=\"1081344\"/E<gt>\n"
3052 "E<lt>aspace type=\"mprotect\" size=\"1081344\"/E<gt>\n"
3053 "E<lt>/heapE<gt>\n"
3054 "E<lt>heap nr=\"1\"E<gt>\n"
3055 "E<lt>sizesE<gt>\n"
3056 "E<lt>/sizesE<gt>\n"
3057 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3058 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3059 "E<lt>system type=\"current\" size=\"1032192\"/E<gt>\n"
3060 "E<lt>system type=\"max\" size=\"1032192\"/E<gt>\n"
3061 "E<lt>aspace type=\"total\" size=\"1032192\"/E<gt>\n"
3062 "E<lt>aspace type=\"mprotect\" size=\"1032192\"/E<gt>\n"
3063 "E<lt>/heapE<gt>\n"
3064 "E<lt>total type=\"fast\" count=\"0\" size=\"0\"/E<gt>\n"
3065 "E<lt>total type=\"rest\" count=\"0\" size=\"0\"/E<gt>\n"
3066 "E<lt>system type=\"current\" size=\"2113536\"/E<gt>\n"
3067 "E<lt>system type=\"max\" size=\"2113536\"/E<gt>\n"
3068 "E<lt>aspace type=\"total\" size=\"2113536\"/E<gt>\n"
3069 "E<lt>aspace type=\"mprotect\" size=\"2113536\"/E<gt>\n"
3070 "E<lt>/mallocE<gt>\n"
3071
3072 #. type: Plain text
3073 #: build/C/man3/malloc_info.3:175
3074 #, no-wrap
3075 msgid ""
3076 "#include E<lt>unistd.hE<gt>\n"
3077 "#include E<lt>stdlib.hE<gt>\n"
3078 "#include E<lt>pthread.hE<gt>\n"
3079 "#include E<lt>malloc.hE<gt>\n"
3080 "#include E<lt>errno.hE<gt>\n"
3081 msgstr ""
3082 "#include E<lt>unistd.hE<gt>\n"
3083 "#include E<lt>stdlib.hE<gt>\n"
3084 "#include E<lt>pthread.hE<gt>\n"
3085 "#include E<lt>malloc.hE<gt>\n"
3086 "#include E<lt>errno.hE<gt>\n"
3087
3088 #. type: Plain text
3089 #: build/C/man3/malloc_info.3:178
3090 #, no-wrap
3091 msgid ""
3092 "static size_t blockSize;\n"
3093 "static int numThreads, numBlocks;\n"
3094 msgstr ""
3095 "static size_t blockSize;\n"
3096 "static int numThreads, numBlocks;\n"
3097
3098 #. type: Plain text
3099 #: build/C/man3/malloc_info.3:181
3100 #, no-wrap
3101 msgid ""
3102 "#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \\e\n"
3103 "                        } while (0)\n"
3104 msgstr ""
3105 "#define errExit(msg)    do { perror(msg); exit(EXIT_FAILURE); \\e\n"
3106 "                        } while (0)\n"
3107
3108 #. type: Plain text
3109 #: build/C/man3/malloc_info.3:187
3110 #, no-wrap
3111 msgid ""
3112 "static void *\n"
3113 "thread_func(void *arg)\n"
3114 "{\n"
3115 "    int j;\n"
3116 "    int tn = (int) arg;\n"
3117 msgstr ""
3118 "static void *\n"
3119 "thread_func(void *arg)\n"
3120 "{\n"
3121 "    int j;\n"
3122 "    int tn = (int) arg;\n"
3123
3124 #. type: Plain text
3125 #: build/C/man3/malloc_info.3:190
3126 #, no-wrap
3127 msgid ""
3128 "    /* The multiplier \\(aq(2 + tn)\\(aq ensures that each thread (including\n"
3129 "       the main thread) allocates a different amount of memory */\n"
3130 msgstr ""
3131 "    /* The multiplier \\(aq(2 + tn)\\(aq ensures that each thread (including\n"
3132 "       the main thread) allocates a different amount of memory */\n"
3133
3134 #. type: Plain text
3135 #: build/C/man3/malloc_info.3:194
3136 #, no-wrap
3137 msgid ""
3138 "    for (j = 0; j E<lt> numBlocks; j++)\n"
3139 "        if (malloc(blockSize * (2 + tn)) == NULL)\n"
3140 "            errExit(\"malloc-thread\");\n"
3141 msgstr ""
3142 "    for (j = 0; j E<lt> numBlocks; j++)\n"
3143 "        if (malloc(blockSize * (2 + tn)) == NULL)\n"
3144 "            errExit(\"malloc-thread\");\n"
3145
3146 #. type: Plain text
3147 #: build/C/man3/malloc_info.3:198
3148 #, no-wrap
3149 msgid ""
3150 "    sleep(100);         /* Sleep until main thread terminates */\n"
3151 "    return NULL;\n"
3152 "}\n"
3153 msgstr ""
3154 "    sleep(100);         /* Sleep until main thread terminates */\n"
3155 "    return NULL;\n"
3156 "}\n"
3157
3158 #. type: Plain text
3159 #: build/C/man3/malloc_info.3:204
3160 #, no-wrap
3161 msgid ""
3162 "int\n"
3163 "main(int argc, char *argv[])\n"
3164 "{\n"
3165 "    int j, tn, sleepTime;\n"
3166 "    pthread_t *thr;\n"
3167 msgstr ""
3168 "int\n"
3169 "main(int argc, char *argv[])\n"
3170 "{\n"
3171 "    int j, tn, sleepTime;\n"
3172 "    pthread_t *thr;\n"
3173
3174 #. type: Plain text
3175 #: build/C/man3/malloc_info.3:211
3176 #, no-wrap
3177 msgid ""
3178 "    if (argc E<lt> 4) {\n"
3179 "        fprintf(stderr,\n"
3180 "                \"%s num-threads num-blocks block-size [sleep-time]\\en\",\n"
3181 "                argv[0]);\n"
3182 "        exit(EXIT_FAILURE);\n"
3183 "    }\n"
3184 msgstr ""
3185 "    if (argc E<lt> 4) {\n"
3186 "        fprintf(stderr,\n"
3187 "                \"%s num-threads num-blocks block-size [sleep-time]\\en\",\n"
3188 "                argv[0]);\n"
3189 "        exit(EXIT_FAILURE);\n"
3190 "    }\n"
3191
3192 #. type: Plain text
3193 #: build/C/man3/malloc_info.3:216
3194 #, no-wrap
3195 msgid ""
3196 "    numThreads = atoi(argv[1]);\n"
3197 "    numBlocks = atoi(argv[2]);\n"
3198 "    blockSize = atoi(argv[3]);\n"
3199 "    sleepTime = (argc E<gt> 4) ? atoi(argv[4]) : 0;\n"
3200 msgstr ""
3201 "    numThreads = atoi(argv[1]);\n"
3202 "    numBlocks = atoi(argv[2]);\n"
3203 "    blockSize = atoi(argv[3]);\n"
3204 "    sleepTime = (argc E<gt> 4) ? atoi(argv[4]) : 0;\n"
3205
3206 #. type: Plain text
3207 #: build/C/man3/malloc_info.3:220
3208 #, no-wrap
3209 msgid ""
3210 "    thr = calloc(numThreads, sizeof(pthread_t));\n"
3211 "    if (thr == NULL)\n"
3212 "        errExit(\"calloc\");\n"
3213 msgstr ""
3214 "    thr = calloc(numThreads, sizeof(pthread_t));\n"
3215 "    if (thr == NULL)\n"
3216 "        errExit(\"calloc\");\n"
3217
3218 #. type: Plain text
3219 #: build/C/man3/malloc_info.3:223
3220 #, no-wrap
3221 msgid ""
3222 "    printf(\"============ Before allocating blocks ============\\en\");\n"
3223 "    malloc_info(0, stdout);\n"
3224 msgstr ""
3225 "    printf(\"============ Before allocating blocks ============\\en\");\n"
3226 "    malloc_info(0, stdout);\n"
3227
3228 #. type: Plain text
3229 #: build/C/man3/malloc_info.3:225
3230 #, no-wrap
3231 msgid "    /* Create threads that allocate different amounts of memory */\n"
3232 msgstr "    /* Create threads that allocate different amounts of memory */\n"
3233
3234 #. type: Plain text
3235 #: build/C/man3/malloc_info.3:231
3236 #, no-wrap
3237 msgid ""
3238 "    for (tn = 0; tn E<lt> numThreads; tn++) {\n"
3239 "        errno = pthread_create(&thr[tn], NULL, thread_func,\n"
3240 "                               (void *) tn);\n"
3241 "        if (errno != 0)\n"
3242 "            errExit(\"pthread_create\");\n"
3243 msgstr ""
3244 "    for (tn = 0; tn E<lt> numThreads; tn++) {\n"
3245 "        errno = pthread_create(&thr[tn], NULL, thread_func,\n"
3246 "                               (void *) tn);\n"
3247 "        if (errno != 0)\n"
3248 "            errExit(\"pthread_create\");\n"
3249
3250 #. type: Plain text
3251 #: build/C/man3/malloc_info.3:236
3252 #, no-wrap
3253 msgid ""
3254 "        /* If we add a sleep interval after the start-up of each\n"
3255 "           thread, the threads likely won\\(aqt contend for malloc\n"
3256 "           mutexes, and therefore additional arenas won\\(aqt be\n"
3257 "           allocated (see malloc(3)). */\n"
3258 msgstr ""
3259 "        /* If we add a sleep interval after the start-up of each\n"
3260 "           thread, the threads likely won\\(aqt contend for malloc\n"
3261 "           mutexes, and therefore additional arenas won\\(aqt be\n"
3262 "           allocated (see malloc(3)). */\n"
3263
3264 #. type: Plain text
3265 #: build/C/man3/malloc_info.3:240
3266 #, no-wrap
3267 msgid ""
3268 "        if (sleepTime E<gt> 0)\n"
3269 "            sleep(sleepTime);\n"
3270 "    }\n"
3271 msgstr ""
3272 "        if (sleepTime E<gt> 0)\n"
3273 "            sleep(sleepTime);\n"
3274 "    }\n"
3275
3276 #. type: Plain text
3277 #: build/C/man3/malloc_info.3:242
3278 #, no-wrap
3279 msgid "    /* The main thread also allocates some memory */\n"
3280 msgstr "    /* The main thread also allocates some memory */\n"
3281
3282 #. type: Plain text
3283 #: build/C/man3/malloc_info.3:246
3284 #, no-wrap
3285 msgid ""
3286 "    for (j = 0; j E<lt> numBlocks; j++)\n"
3287 "        if (malloc(blockSize) == NULL)\n"
3288 "            errExit(\"malloc\");\n"
3289 msgstr ""
3290 "    for (j = 0; j E<lt> numBlocks; j++)\n"
3291 "        if (malloc(blockSize) == NULL)\n"
3292 "            errExit(\"malloc\");\n"
3293
3294 #. type: Plain text
3295 #: build/C/man3/malloc_info.3:249
3296 #, no-wrap
3297 msgid ""
3298 "    sleep(2);           /* Give all threads a chance to\n"
3299 "                           complete allocations */\n"
3300 msgstr ""
3301 "    sleep(2);           /* Give all threads a chance to\n"
3302 "                           complete allocations */\n"
3303
3304 #. type: Plain text
3305 #: build/C/man3/malloc_info.3:252
3306 #, no-wrap
3307 msgid ""
3308 "    printf(\"\\en============ After allocating blocks ============\\en\");\n"
3309 "    malloc_info(0, stdout);\n"
3310 msgstr ""
3311 "    printf(\"\\en============ After allocating blocks ============\\en\");\n"
3312 "    malloc_info(0, stdout);\n"
3313
3314 #. type: Plain text
3315 #: build/C/man3/malloc_info.3:262
3316 msgid ""
3317 "B<mallinfo>(3), B<malloc>(3), B<malloc_stats>(3), B<mallopt>(3), "
3318 "B<open_memstream>(3)"
3319 msgstr ""
3320 "B<mallinfo>(3), B<malloc>(3), B<malloc_stats>(3), B<mallopt>(3), "
3321 "B<open_memstream>(3)"
3322
3323 #. type: TH
3324 #: build/C/man3/malloc_stats.3:26
3325 #, no-wrap
3326 msgid "MALLOC_STATS"
3327 msgstr "MALLOC_STATS"
3328
3329 #. type: Plain text
3330 #: build/C/man3/malloc_stats.3:29
3331 msgid "malloc_stats - print memory allocation statistics"
3332 msgstr "malloc_stats - メモリ割り当ての統計を表示する"
3333
3334 #. type: Plain text
3335 #: build/C/man3/malloc_stats.3:33
3336 msgid "B<void malloc_stats(void);>"
3337 msgstr "B<void malloc_stats(void);>"
3338
3339 #.  .SH VERSIONS
3340 #.  Available already in glibc 2.0, possibly earlier
3341 #. type: Plain text
3342 #: build/C/man3/malloc_stats.3:55
3343 msgid ""
3344 "The B<malloc_stats>()  function prints (on standard error) statistics about "
3345 "memory allocated by B<malloc>(3)  and related functions.  For each arena "
3346 "(allocation area), this function prints the total amount of memory allocated "
3347 "and the total number of bytes consumed by in-use allocations.  (These two "
3348 "values correspond to the I<arena> and I<uordblks> fields retrieved by "
3349 "B<mallinfo>(3).)  In addition, the function prints the sum of these two "
3350 "statistics for all arenas, and the maximum number of blocks and bytes that "
3351 "were ever simultaneously allocated using B<mmap>(2)."
3352 msgstr ""
3353 "B<malloc_stats>() 関数は B<malloc>(3) や関連する関数により割り当てられたメモ"
3354 "リに関する統計を (標準エラーに) 出力する。 各領域 (割り当てエリア) につい"
3355 "て、 この関数は割り当てられているメモリの総量と現在の割り当てが使用している総"
3356 "バイト数を出力する (これらの二つの値は B<mallinfo>(3) で取得できる I<arena> "
3357 "と I<uordblks> フィールドに対応している)。 また、この関数は、 すべての領域の"
3358 "これら二つの統計情報の合計値と、 B<mmap>(2) を使って同時に割り当てられたブ"
3359 "ロック数とバイト数の最大値を表示する。"
3360
3361 #. type: Plain text
3362 #: build/C/man3/malloc_stats.3:61
3363 msgid ""
3364 "More detailed information about memory allocations in the main arena can be "
3365 "obtained using B<mallinfo>(3)."
3366 msgstr ""
3367 "B<mallinfo>(3) を使用すると、 メイン領域のメモリ割り当てに関するより詳細な情"
3368 "報を取得できる。"
3369
3370 #. type: Plain text
3371 #: build/C/man3/malloc_stats.3:67
3372 msgid ""
3373 "B<mmap>(2), B<mallinfo>(3), B<malloc>(3), B<malloc_info>(3), B<mallopt>(3)"
3374 msgstr ""
3375 "B<mmap>(2), B<mallinfo>(3), B<malloc>(3), B<malloc_info>(3), B<mallopt>(3)"
3376
3377 #. type: TH
3378 #: build/C/man3/malloc_trim.3:26
3379 #, no-wrap
3380 msgid "MALLOC_TRIM"
3381 msgstr "MALLOC_TRIM"
3382
3383 #. type: TH
3384 #: build/C/man3/malloc_trim.3:26 build/C/man3/malloc_usable_size.3:25
3385 #, no-wrap
3386 msgid "2012-03-29"
3387 msgstr "2012-03-29"
3388
3389 #. type: Plain text
3390 #: build/C/man3/malloc_trim.3:29
3391 msgid "malloc_trim - release free memory from the top of the heap"
3392 msgstr ""
3393
3394 #. type: Plain text
3395 #: build/C/man3/malloc_trim.3:33
3396 msgid "B<void malloc_trim(size_t >I<pad>B<);>"
3397 msgstr "B<void malloc_trim(size_t >I<pad>B<);>"
3398
3399 #. type: Plain text
3400 #: build/C/man3/malloc_trim.3:40
3401 msgid ""
3402 "The B<malloc_trim>()  function attempts to release free memory at the top of "
3403 "the heap (by calling B<sbrk>(2)  with a suitable argument)."
3404 msgstr ""
3405
3406 #. type: Plain text
3407 #: build/C/man3/malloc_trim.3:51
3408 msgid ""
3409 "The I<pad> argument specifies the amount of free space to leave untrimmed at "
3410 "the top of the heap.  If this argument is 0, only the minimum amount of "
3411 "memory is maintained at the top of the heap (i.e., one page or less).  A "
3412 "nonzero argument can be used to maintain some trailing space at the top of "
3413 "the heap in order to allow future allocations to be made without having to "
3414 "extend the heap with B<sbrk>(2)."
3415 msgstr ""
3416
3417 #. type: Plain text
3418 #: build/C/man3/malloc_trim.3:56
3419 msgid ""
3420 "The B<malloc_trim>()  function returns 1 if memory was actually released "
3421 "back to the system, or 0 if it was not possible to release any memory."
3422 msgstr ""
3423
3424 #.  .SH VERSIONS
3425 #.  Available already in glibc 2.0, possibly earlier
3426 #. type: Plain text
3427 #: build/C/man3/malloc_trim.3:60
3428 msgid "No errors are defined."
3429 msgstr ""
3430
3431 #. type: Plain text
3432 #: build/C/man3/malloc_trim.3:71
3433 msgid ""
3434 "This function is automatically called by B<free>(3)  in certain "
3435 "circumstances; see the discussion of B<M_TOP_PAD> and B<M_TRIM_THRESHOLD> in "
3436 "B<mallopt>(3)."
3437 msgstr ""
3438
3439 #. type: Plain text
3440 #: build/C/man3/malloc_trim.3:74
3441 msgid ""
3442 "This function cannot release free memory located at places other than the "
3443 "top of the heap."
3444 msgstr ""
3445
3446 #.  malloc/malloc.c::mTRIm():
3447 #.      return result | (av == &main_arena ? sYSTRIm (pad, av) : 0);
3448 #. type: Plain text
3449 #: build/C/man3/malloc_trim.3:78
3450 msgid "This function releases only memory in the main arena."
3451 msgstr ""
3452
3453 #. type: Plain text
3454 #: build/C/man3/malloc_trim.3:82
3455 msgid "B<sbrk>(2), B<malloc>(3), B<mallopt>(3)"
3456 msgstr "B<sbrk>(2), B<malloc>(3), B<mallopt>(3)"
3457
3458 #. type: TH
3459 #: build/C/man3/malloc_usable_size.3:25
3460 #, no-wrap
3461 msgid "MALLOC_USABLE_SIZE"
3462 msgstr "MALLOC_USABLE_SIZE"
3463
3464 #. type: Plain text
3465 #: build/C/man3/malloc_usable_size.3:28
3466 msgid "malloc_usable_size - obtain size of block of memory allocated from heap"
3467 msgstr ""
3468
3469 #. type: Plain text
3470 #: build/C/man3/malloc_usable_size.3:32
3471 msgid "B<size_t malloc_usable_size (void *>I<ptr>B<);>"
3472 msgstr "B<size_t malloc_usable_size (void *>I<ptr>B<);>"
3473
3474 #. type: Plain text
3475 #: build/C/man3/malloc_usable_size.3:40
3476 msgid ""
3477 "The B<malloc_usable_size>()  function returns the number of usable bytes in "
3478 "the block pointed to by I<ptr>, a pointer to a block of memory allocated by "
3479 "B<malloc>(3)  or a related function."
3480 msgstr ""
3481
3482 #. type: Plain text
3483 #: build/C/man3/malloc_usable_size.3:48
3484 msgid ""
3485 "B<malloc_usable_size>()  returns the number of usable bytes in the block of "
3486 "allocated memory pointed to by I<ptr>.  If I<ptr> is NULL, 0 is returned."
3487 msgstr ""
3488
3489 #. type: Plain text
3490 #: build/C/man3/malloc_usable_size.3:60
3491 msgid ""
3492 "The value returned by B<malloc_usable_size>()  may be greater than the "
3493 "requested size of the allocation because of alignment and minimum size "
3494 "constraints.  Although the excess bytes can be overwritten by the "
3495 "application without ill effects, this is not good programming practice: the "
3496 "number of excess bytes in an allocation depends on the underlying "
3497 "implementation."
3498 msgstr ""
3499
3500 #. type: Plain text
3501 #: build/C/man3/malloc_usable_size.3:62
3502 msgid "The main use of this function is for debugging and introspection."
3503 msgstr ""
3504
3505 #. type: Plain text
3506 #: build/C/man3/malloc_usable_size.3:64
3507 msgid "B<malloc>(3)"
3508 msgstr "B<malloc>(3)"
3509
3510 #. type: TH
3511 #: build/C/man3/mallopt.3:26
3512 #, no-wrap
3513 msgid "MALLOPT"
3514 msgstr "MALLOPT"
3515
3516 #. type: TH
3517 #: build/C/man3/mallopt.3:26
3518 #, no-wrap
3519 msgid "2012-04-30"
3520 msgstr "2012-04-30"
3521
3522 #. type: Plain text
3523 #: build/C/man3/mallopt.3:29
3524 msgid "mallopt - set memory allocation parameters"
3525 msgstr "mallopt - メモリ割り当てパラメータを設定する"
3526
3527 #. type: Plain text
3528 #: build/C/man3/mallopt.3:33
3529 msgid "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
3530 msgstr "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
3531
3532 #. type: Plain text
3533 #: build/C/man3/mallopt.3:44
3534 msgid ""
3535 "The B<mallopt>()  function adjusts parameters that control the behavior of "
3536 "the memory-allocation functions (see B<malloc>(3)).  The I<param> argument "
3537 "specifies the parameter to be modified, and I<value> specifies the new value "
3538 "for that parameter."
3539 msgstr ""
3540 "B<mallopt>() 関数は、メモリ割り当て関数 (B<malloc>(3) を参照) の動作を\n"
3541 "制御するパラメータの調整を行う。\n"
3542 "I<param> 引き数で変更するパラメータを指定し、\n"
3543 "I<value> 引き数でそのパラメータの新しい値を指定する。"
3544
3545 #. type: Plain text
3546 #: build/C/man3/mallopt.3:47
3547 msgid "The following values can be specified for I<param>:"
3548 msgstr "I<param> には以下の値を指定することができる。"
3549
3550 #. type: TP
3551 #: build/C/man3/mallopt.3:47
3552 #, no-wrap
3553 msgid "B<M_CHECK_ACTION>"
3554 msgstr "B<M_CHECK_ACTION>"
3555
3556 #. type: Plain text
3557 #: build/C/man3/mallopt.3:53
3558 msgid ""
3559 "Setting this parameter controls how glibc responds when various kinds of "
3560 "programming errors are detected (e.g., freeing the same pointer twice).  The "
3561 "3 least significant bits (2, 1, and 0) of the value assigned to this "
3562 "parameter determine the glibc behavior, as follows:"
3563 msgstr ""
3564
3565 #. type: TP
3566 #: build/C/man3/mallopt.3:54
3567 #, no-wrap
3568 msgid "Bit 0"
3569 msgstr "Bit 0"
3570
3571 #. type: Plain text
3572 #: build/C/man3/mallopt.3:64
3573 msgid ""
3574 "If this bit is set, then print a one-line message on I<stderr> that provides "
3575 "details about the error.  The message starts with the string \"***\\ glibc "
3576 "detected\\ ***\", followed by the program name, the name of the memory-"
3577 "allocation function in which the error was detected, a brief description of "
3578 "the error, and the memory address where the error was detected."
3579 msgstr ""
3580
3581 #. type: TP
3582 #: build/C/man3/mallopt.3:64
3583 #, no-wrap
3584 msgid "Bit 1"
3585 msgstr "Bit 1"
3586
3587 #. type: Plain text
3588 #: build/C/man3/mallopt.3:79
3589 msgid ""
3590 "If this bit is set, then, after printing any error message specified by bit "
3591 "0, the program is terminated by calling B<abort>(3).  In glibc versions "
3592 "since 2.4, if bit 0 is also set, then, between printing the error message "
3593 "and aborting, the program also prints a stack trace in the manner of "
3594 "B<backtrace>(3), and prints the process's memory mapping in the style of I</"
3595 "proc/[pid]/maps> (see B<proc>(5))."
3596 msgstr ""
3597
3598 #. type: TP
3599 #: build/C/man3/mallopt.3:79
3600 #, no-wrap
3601 msgid "Bit 2 (since glibc 2.4)"
3602 msgstr "Bit 2 (glibc 2.4 以降)"
3603
3604 #. type: Plain text
3605 #: build/C/man3/mallopt.3:86
3606 msgid ""
3607 "This bit has an effect only if bit 0 is also set.  If this bit is set, then "
3608 "the one-line message describing the error is simplified to contain just the "
3609 "name of the function where the error was detected and the brief description "
3610 "of the error."
3611 msgstr ""
3612
3613 #. type: Plain text
3614 #: build/C/man3/mallopt.3:91
3615 msgid "The remaining bits in I<value> are ignored."
3616 msgstr ""
3617
3618 #. type: Plain text
3619 #: build/C/man3/mallopt.3:95
3620 msgid ""
3621 "Combining the above details, the following numeric values are meaningful for "
3622 "B<M_CHECK_ACTION>:"
3623 msgstr ""
3624
3625 #. type: IP
3626 #: build/C/man3/mallopt.3:96
3627 #, no-wrap
3628 msgid "0"
3629 msgstr "0"
3630
3631 #. type: Plain text
3632 #: build/C/man3/mallopt.3:98
3633 msgid "Ignore error conditions; continue execution (with undefined results)."
3634 msgstr ""
3635
3636 #. type: IP
3637 #: build/C/man3/mallopt.3:98
3638 #, no-wrap
3639 msgid "1"
3640 msgstr "1"
3641
3642 #. type: Plain text
3643 #: build/C/man3/mallopt.3:100
3644 msgid "Print a detailed error message and continue execution."
3645 msgstr ""
3646
3647 #. type: IP
3648 #: build/C/man3/mallopt.3:100
3649 #, no-wrap
3650 msgid "2"
3651 msgstr "2"
3652
3653 #. type: Plain text
3654 #: build/C/man3/mallopt.3:102
3655 msgid "Abort the program."
3656 msgstr ""
3657
3658 #. type: IP
3659 #: build/C/man3/mallopt.3:102
3660 #, no-wrap
3661 msgid "3"
3662 msgstr "3"
3663
3664 #. type: Plain text
3665 #: build/C/man3/mallopt.3:105
3666 msgid ""
3667 "Print detailed error message, stack trace, and memory mappings, and abort "
3668 "the program."
3669 msgstr ""
3670
3671 #. type: IP
3672 #: build/C/man3/mallopt.3:105
3673 #, no-wrap
3674 msgid "5"
3675 msgstr "5"
3676
3677 #. type: Plain text
3678 #: build/C/man3/mallopt.3:107
3679 msgid "Print a simple error message and continue execution."
3680 msgstr ""
3681
3682 #. type: IP
3683 #: build/C/man3/mallopt.3:107
3684 #, no-wrap
3685 msgid "7"
3686 msgstr "7"
3687
3688 #. type: Plain text
3689 #: build/C/man3/mallopt.3:110
3690 msgid ""
3691 "Print simple error message, stack trace, and memory mappings, and abort the "
3692 "program."
3693 msgstr ""
3694
3695 #. type: Plain text
3696 #: build/C/man3/mallopt.3:116
3697 msgid ""
3698 "Since glibc 2.3.4, the default value for the B<M_CHECK_ACTION> parameter is "
3699 "3.  In glibc version 2.3.3 and earlier, the default value is 1."
3700 msgstr ""
3701
3702 #. type: Plain text
3703 #: build/C/man3/mallopt.3:121
3704 msgid ""
3705 "Using a nonzero B<M_CHECK_ACTION> value can be useful because otherwise a "
3706 "crash may happen much later, and the true cause of the problem is then very "
3707 "hard to track down."
3708 msgstr ""
3709
3710 #. type: TP
3711 #: build/C/man3/mallopt.3:121
3712 #, no-wrap
3713 msgid "B<M_MMAP_MAX>"
3714 msgstr "B<M_MMAP_MAX>"
3715
3716 #.  The following text adapted from comments in the glibc source:
3717 #. type: Plain text
3718 #: build/C/man3/mallopt.3:131
3719 msgid ""
3720 "This parameter specifies the maximum number of allocation requests that may "
3721 "be simultaneously serviced using B<mmap>(2).  This parameter exists because "
3722 "some systems have a limited number of internal tables for use by B<mmap>(2), "
3723 "and using more than a few of them may degrade performance."
3724 msgstr ""
3725
3726 #. type: Plain text
3727 #: build/C/man3/mallopt.3:138
3728 msgid ""
3729 "The default value is 65,536, a value which has no special significance and "
3730 "which servers only as a safeguard.  Setting this parameter to 0 disables the "
3731 "use of B<mmap>(2)  for servicing large allocation requests."
3732 msgstr ""
3733
3734 #. type: TP
3735 #: build/C/man3/mallopt.3:138
3736 #, no-wrap
3737 msgid "B<M_MMAP_THRESHOLD>"
3738 msgstr "B<M_MMAP_THRESHOLD>"
3739
3740 #. type: Plain text
3741 #: build/C/man3/mallopt.3:147
3742 msgid ""
3743 "For allocations greater than or equal to the limit specified (in bytes) by "
3744 "B<M_MMAP_THRESHOLD> that can't be satisfied from the free list, the memory-"
3745 "allocation functions employ B<mmap>(2)  instead of increasing the program "
3746 "break using B<sbrk>(2)."
3747 msgstr ""
3748
3749 #. type: Plain text
3750 #: build/C/man3/mallopt.3:167
3751 msgid ""
3752 "Allocating memory using B<mmap>(2)  has the significant advantage that the "
3753 "allocated memory blocks can always be independently released back to the "
3754 "system.  (By contrast, the heap can be trimmed only if memory is freed at "
3755 "the top end.)  On the other hand, there are some disadvantages to the use of "
3756 "B<mmap>(2): deallocated space is not placed on the free list for reuse by "
3757 "later allocations; memory may be wasted because B<mmap>(2)  allocations must "
3758 "be page-aligned; and the kernel must perform the expensive task of zeroing "
3759 "out memory allocated via B<mmap>(2).  Balancing these factors leads to a "
3760 "default setting of 128*1024 for the B<M_MMAP_THRESHOLD> parameter."
3761 msgstr ""
3762
3763 #. type: Plain text
3764 #: build/C/man3/mallopt.3:174
3765 msgid ""
3766 "The lower limit for this parameter is 0.  The upper limit is "
3767 "B<DEFAULT_MMAP_THRESHOLD_MAX>: 512*1024 on 32-bit systems or "
3768 "I<4*1024*1024*sizeof(long)> on 64-bit systems."
3769 msgstr ""
3770
3771 #. type: Plain text
3772 #: build/C/man3/mallopt.3:192
3773 msgid ""
3774 "I<Note:> Nowadays, glibc uses a dynamic mmap threshold by default.  The "
3775 "initial value of the threshold is 128*1024, but when blocks larger than the "
3776 "current threshold and less than or equal to B<DEFAULT_MMAP_THRESHOLD_MAX> "
3777 "are freed, the threshold is adjusted upward to the size of the freed block.  "
3778 "When dynamic mmap thresholding is in effect, the threshold for trimming the "
3779 "heap is also dynamically adjusted to be twice the dynamic mmap threshold.  "
3780 "Dynamic adjustment of the mmap threshold is disabled if any of the "
3781 "B<M_TRIM_THRESHOLD>, B<M_TOP_PAD>, B<M_MMAP_THRESHOLD>, or B<M_MMAP_MAX> "
3782 "parameters is set."
3783 msgstr ""
3784
3785 #. type: TP
3786 #: build/C/man3/mallopt.3:192
3787 #, no-wrap
3788 msgid "B<M_MXFAST> (since glibc 2.3)"
3789 msgstr "B<M_MXFAST> (glibc 2.3 以降)"
3790
3791 #.  The following text adapted from comments in the glibc sources:
3792 #. type: Plain text
3793 #: build/C/man3/mallopt.3:212
3794 msgid ""
3795 "Set the upper limit for memory allocation requests that are satisfied using "
3796 "\"fastbins\".  (The measurement unit for this parameter is bytes.)  Fastbins "
3797 "are storage areas that hold deallocated blocks of memory of the same size "
3798 "without merging adjacent free blocks.  Subsequent reallocation of blocks of "
3799 "the same size can be handled very quickly by allocating from the fastbin, "
3800 "although memory fragmentation and the overall memory footprint of the "
3801 "program can increase.  The default value for this parameter is I<64*sizeof"
3802 "(size_t)/4> (i.e., 64 on 32-bit architectures).  The range for this "
3803 "parameter is 0 to I<80*sizeof(size_t)/4>.  Setting B<M_MXFAST> to 0 disables "
3804 "the use of fastbins."
3805 msgstr ""
3806
3807 #. type: TP
3808 #: build/C/man3/mallopt.3:212
3809 #, no-wrap
3810 msgid "B<M_PERTURB> (since glibc 2.4)"
3811 msgstr "B<M_PERTURB> (glibc 2.4 以降)"
3812
3813 #. type: Plain text
3814 #: build/C/man3/mallopt.3:227
3815 msgid ""
3816 "If this parameter is set to a nonzero value, then bytes of allocated memory "
3817 "(other than allocations via B<calloc>(3))  are initialized to the complement "
3818 "of the value in the least significant byte of I<value>, and when allocated "
3819 "memory is released using B<free>(3), the freed bytes are set to the least "
3820 "significant byte of I<value>.  This can be useful for detecting errors where "
3821 "programs incorrectly rely on allocated memory being initialized to zero, or "
3822 "reuse values in memory that has already been freed."
3823 msgstr ""
3824
3825 #. type: TP
3826 #: build/C/man3/mallopt.3:227
3827 #, no-wrap
3828 msgid "B<M_TOP_PAD>"
3829 msgstr "B<M_TOP_PAD>"
3830
3831 #. type: Plain text
3832 #: build/C/man3/mallopt.3:234
3833 msgid ""
3834 "This parameter defines the amount of padding to employ when calling B<sbrk>"
3835 "(2)  to modify the program break.  (The measurement unit for this parameter "
3836 "is bytes.)  This parameter has an effect in the following circumstances:"
3837 msgstr ""
3838
3839 #. type: Plain text
3840 #: build/C/man3/mallopt.3:241
3841 msgid ""
3842 "When the program break is increased, then B<M_TOP_PAD> bytes are added to "
3843 "the B<sbrk>(2)  request."
3844 msgstr ""
3845
3846 #. type: Plain text
3847 #: build/C/man3/mallopt.3:247
3848 msgid ""
3849 "When the heap is trimmed as a consequence of calling B<free>(3)  (see the "
3850 "discussion of B<M_TRIM_THRESHOLD>)  this much free space is preserved at the "
3851 "top of the heap."
3852 msgstr ""
3853
3854 #. type: Plain text
3855 #: build/C/man3/mallopt.3:251
3856 msgid ""
3857 "In either case, the amount of padding is always rounded to a system page "
3858 "boundary."
3859 msgstr ""
3860
3861 #. type: Plain text
3862 #: build/C/man3/mallopt.3:258
3863 msgid ""
3864 "Modifying B<M_TOP_PAD> is a trade-off between increasing the number of "
3865 "system calls (when the parameter is set low)  and wasting unused memory at "
3866 "the top of the heap (when the parameter is set high)."
3867 msgstr ""
3868
3869 #.  DEFAULT_TOP_PAD in glibc source
3870 #. type: Plain text
3871 #: build/C/man3/mallopt.3:261
3872 msgid "The default value for this parameter is 128*1024."
3873 msgstr ""
3874
3875 #. type: TP
3876 #: build/C/man3/mallopt.3:261
3877 #, no-wrap
3878 msgid "B<M_TRIM_THRESHOLD>"
3879 msgstr "B<M_TRIM_THRESHOLD>"
3880
3881 #. type: Plain text
3882 #: build/C/man3/mallopt.3:277
3883 msgid ""
3884 "When the amount of contiguous free memory at the top of the heap grows "
3885 "sufficiently large, B<free>(3)  employs B<sbrk>(2)  to release this memory "
3886 "back to the system.  (This can be useful in programs that continue to "
3887 "execute for a long period after freeing a significant amount of memory.)  "
3888 "The B<M_TRIM_THRESHOLD> parameter specifies the minimum size (in bytes) that "
3889 "this block of memory must reach before B<sbrk>(2)  is used to trim the heap."
3890 msgstr ""
3891
3892 #. type: Plain text
3893 #: build/C/man3/mallopt.3:282
3894 msgid ""
3895 "The default value for this parameter is 128*1024.  Setting "
3896 "B<M_TRIM_THRESHOLD> to -1 disables trimming completely."
3897 msgstr ""
3898
3899 #
3900 #
3901 #
3902 #.  FIXME Do the arena parameters need to be documented?
3903 #.  .TP
3904 #.  .BR M_ARENA_TEST " (since glibc 2.10)"
3905 #.  .TP
3906 #.  .BR M_ARENA_MAX " (since glibc 2.10)"
3907 #.  Environment variables
3908 #.      MALLOC_ARENA_MAX_
3909 #.      MALLOC_ARENA_TEST_
3910 #.  http://udrepper.livejournal.com/20948.html describes some details
3911 #.      of the MALLOC_ARENA_* environment variables.
3912 #.  These macros aren't enabled in production releases until 2.15?
3913 #.  (see glibc malloc/Makefile)
3914 #. type: Plain text
3915 #: build/C/man3/mallopt.3:305
3916 msgid ""
3917 "Modifying B<M_TRIM_THRESHOLD> is a trade-off between increasing the number "
3918 "of system calls (when the parameter is set low)  and wasting unused memory "
3919 "at the top of the heap (when the parameter is set high)."
3920 msgstr ""
3921
3922 #. type: SS
3923 #: build/C/man3/mallopt.3:305
3924 #, no-wrap
3925 msgid "Environment variables"
3926 msgstr "環境変数"
3927
3928 #. type: Plain text
3929 #: build/C/man3/mallopt.3:320
3930 msgid ""
3931 "A number of environment variables can be defined to modify some of the same "
3932 "parameters as are controlled by B<mallopt>().  Using these variables has the "
3933 "advantage that the source code of the program need not be changed.  To be "
3934 "effective, these variables must be defined before the first call to a memory-"
3935 "allocation function.  (If the same parameters are adjusted via B<mallopt>(), "
3936 "then the B<mallopt>()  settings take precedence.)  For security reasons, "
3937 "these variables are ignored in set-user-ID and set-group-ID programs."
3938 msgstr ""
3939
3940 #. type: Plain text
3941 #: build/C/man3/mallopt.3:323
3942 msgid ""
3943 "The environment variables are as follows (note the trailing underscore at "
3944 "the end of the name of each variable):"
3945 msgstr ""
3946
3947 #. type: TP
3948 #: build/C/man3/mallopt.3:323
3949 #, no-wrap
3950 msgid "B<MALLOC_CHECK_>"
3951 msgstr "B<MALLOC_CHECK_>"
3952
3953 #.  On glibc 2.12/x86, a simple malloc()+free() loop is about 70% slower
3954 #.  when MALLOC_CHECK_ was set.
3955 #. type: Plain text
3956 #: build/C/man3/mallopt.3:340
3957 msgid ""
3958 "This environment variable controls the same parameter as B<mallopt>()  "
3959 "B<M_CHECK_ACTION>.  If this variable is set to a nonzero value, then a "
3960 "special implementation of the memory-allocation functions is used.  (This is "
3961 "accomplished using the B<malloc_hook>(3)  feature.)  This implementation "
3962 "performs additional error checking, but is slower than the standard set of "
3963 "memory-allocation functions.  (This implementation does not detect all "
3964 "possible errors; memory leaks can still occur.)"
3965 msgstr ""
3966
3967 #. type: Plain text
3968 #: build/C/man3/mallopt.3:345
3969 msgid ""
3970 "The value assigned to this environment variable should be a single digit, "
3971 "whose meaning is as described for B<M_CHECK_ACTION>.  Any characters beyond "
3972 "the initial digit are ignored."
3973 msgstr ""
3974
3975 #. type: Plain text
3976 #: build/C/man3/mallopt.3:354
3977 msgid ""
3978 "For security reasons, the effect of B<MALLOC_CHECK_> is disabled by default "
3979 "for set-user-ID and set-group-ID programs.  However, if the file I</etc/suid-"
3980 "debug> exists (the content of the file is irrelevant), then B<MALLOC_CHECK_> "
3981 "also has an effect for set-user-ID and set-group-ID programs."
3982 msgstr ""
3983
3984 #. type: TP
3985 #: build/C/man3/mallopt.3:354
3986 #, no-wrap
3987 msgid "B<MALLOC_MMAP_MAX_>"
3988 msgstr "B<MALLOC_MMAP_MAX_>"
3989
3990 #. type: Plain text
3991 #: build/C/man3/mallopt.3:359
3992 msgid "Controls the same parameter as B<mallopt>()  B<M_MMAP_MAX>."
3993 msgstr ""
3994
3995 #. type: TP
3996 #: build/C/man3/mallopt.3:359
3997 #, no-wrap
3998 msgid "B<MALLOC_MMAP_THRESHOLD_>"
3999 msgstr "B<MALLOC_MMAP_THRESHOLD_>"
4000
4001 #. type: Plain text
4002 #: build/C/man3/mallopt.3:364
4003 msgid "Controls the same parameter as B<mallopt>()  B<M_MMAP_THRESHOLD>."
4004 msgstr ""
4005
4006 #. type: TP
4007 #: build/C/man3/mallopt.3:364
4008 #, no-wrap
4009 msgid "B<MALLOC_PERTURB_>"
4010 msgstr "B<MALLOC_PERTURB_>"
4011
4012 #. type: Plain text
4013 #: build/C/man3/mallopt.3:369
4014 msgid "Controls the same parameter as B<mallopt>()  B<M_PERTURB>."
4015 msgstr ""
4016
4017 #. type: TP
4018 #: build/C/man3/mallopt.3:369
4019 #, no-wrap
4020 msgid "B<MALLOC_TRIM_THRESHOLD_>"
4021 msgstr "B<MALLOC_TRIM_THRESHOLD_>"
4022
4023 #. type: Plain text
4024 #: build/C/man3/mallopt.3:374
4025 msgid "Controls the same parameter as B<mallopt>()  B<M_TRIM_THRESHOLD>."
4026 msgstr ""
4027
4028 #. type: TP
4029 #: build/C/man3/mallopt.3:374
4030 #, no-wrap
4031 msgid "B<MALLOC_TOP_PAD_>"
4032 msgstr "B<MALLOC_TOP_PAD_>"
4033
4034 #. type: Plain text
4035 #: build/C/man3/mallopt.3:379
4036 msgid "Controls the same parameter as B<mallopt>()  B<M_TOP_PAD>."
4037 msgstr ""
4038
4039 #. type: Plain text
4040 #: build/C/man3/mallopt.3:384
4041 msgid "On success, B<mallopt>()  returns 1.  On error, it returns 0."
4042 msgstr "B<mallopt>()  は成功すると 1 を返す。エラーの場合は 0 を返す。"
4043
4044 #.  .SH VERSIONS
4045 #.  Available already in glibc 2.0, possibly earlier
4046 #. type: Plain text
4047 #: build/C/man3/mallopt.3:392
4048 msgid "On error, I<errno> is I<not> set."
4049 msgstr "エラーの場合、I<errno> は設定I<されない>。"
4050
4051 #.  .SH NOTES
4052 #. type: Plain text
4053 #: build/C/man3/mallopt.3:406
4054 msgid ""
4055 "This function is not specified by POSIX or the C standards.  A similar "
4056 "function exists on many System V derivatives, but the range of values for "
4057 "I<param> varies across systems.  The SVID defined options B<M_MXFAST>, "
4058 "B<M_NLBLKS>, B<M_GRAIN>, and B<M_KEEP>, but only the first of these is "
4059 "implemented in glibc."
4060 msgstr ""
4061
4062 #. type: Plain text
4063 #: build/C/man3/mallopt.3:410
4064 msgid "Specifying an invalid value for I<param> does not generate an error."
4065 msgstr ""
4066
4067 #.  FIXME This looks buggy:
4068 #.  setting the M_MXFAST limit rounds up:    (s + SIZE_SZ) & ~MALLOC_ALIGN_MASK)
4069 #.  malloc requests are rounded up:
4070 #.     (req) + SIZE_SZ + MALLOC_ALIGN_MASK) & ~MALLOC_ALIGN_MASK
4071 #.  http://sources.redhat.com/bugzilla/show_bug.cgi?id=12129
4072 #. type: Plain text
4073 #: build/C/man3/mallopt.3:418
4074 msgid ""
4075 "A calculation error within the glibc implementation means that a call of the "
4076 "form:"
4077 msgstr ""
4078
4079 #. type: Plain text
4080 #: build/C/man3/mallopt.3:421
4081 #, no-wrap
4082 msgid "    mallopt(M_MXFAST, n)\n"
4083 msgstr "    mallopt(M_MXFAST, n)\n"
4084
4085 #.  Bins are multiples of 2 * sizeof(size_t) + sizeof(size_t)
4086 #. type: Plain text
4087 #: build/C/man3/mallopt.3:433
4088 msgid ""
4089 "does not result in fastbins being employed for all allocations of size up to "
4090 "I<n>.  To ensure desired results, I<n> should be rounded up to the next "
4091 "multiple greater than or equal to I<(2k+1)*sizeof(size_t)>, where I<k> is an "
4092 "integer."
4093 msgstr ""
4094
4095 #.  FIXME MALLOC_MMAP_THRESHOLD_ and MALLOC_MMAP_MAX_
4096 #.  do have an effect for set-user-ID programs (but not
4097 #.  set-group-ID programs).
4098 #.  http://sources.redhat.com/bugzilla/show_bug.cgi?id=12155
4099 #. type: Plain text
4100 #: build/C/man3/mallopt.3:445
4101 msgid ""
4102 "The B<MALLOC_MMAP_THRESHOLD_> and B<MALLOC_MMAP_MAX_> variables are I<not> "
4103 "ignored in set-group-ID programs."
4104 msgstr ""
4105
4106 #.  FIXME http://sources.redhat.com/bugzilla/show_bug.cgi?id=12140
4107 #. type: Plain text
4108 #: build/C/man3/mallopt.3:466
4109 msgid ""
4110 "If B<mallopt>()  is used to set B<M_PERTURB>, then, as expected, the bytes "
4111 "of allocated memory are initialized to the complement of the byte in "
4112 "I<value>, and when that memory is freed, the bytes of the region are "
4113 "initialized to the byte specified in I<value>.  However, there is an off-by-"
4114 "I<sizeof(size_t)> error in the implementation: instead of initializing "
4115 "precisely the block of memory being freed by the call I<free(p)>, the block "
4116 "starting at I<p+sizeof(size_t)> is initialized."
4117 msgstr ""
4118
4119 #. type: Plain text
4120 #: build/C/man3/mallopt.3:475
4121 msgid ""
4122 "The program below demonstrates the use of B<M_CHECK_ACTION>.  If the program "
4123 "is supplied with an (integer) command-line argument, then that argument is "
4124 "used to set the B<M_CHECK_ACTION> parameter.  The program then allocates a "
4125 "block of memory, and frees it twice (an error)."
4126 msgstr ""
4127
4128 #. type: Plain text
4129 #: build/C/man3/mallopt.3:479
4130 msgid ""
4131 "The following shell session shows what happens when we run this program "
4132 "under glibc, with the default value for B<M_CHECK_ACTION>:"
4133 msgstr ""
4134
4135 #. type: Plain text
4136 #: build/C/man3/mallopt.3:499
4137 #, no-wrap
4138 msgid ""
4139 "$ B<./a.out>\n"
4140 "main(): returned from first free() call\n"
4141 "*** glibc detected *** ./a.out: double free or corruption (top): 0x09d30008 ***\n"
4142 "======= Backtrace: =========\n"
4143 "/lib/libc.so.6(+0x6c501)[0x523501]\n"
4144 "/lib/libc.so.6(+0x6dd70)[0x524d70]\n"
4145 "/lib/libc.so.6(cfree+0x6d)[0x527e5d]\n"
4146 "\\&./a.out[0x80485db]\n"
4147 "/lib/libc.so.6(__libc_start_main+0xe7)[0x4cdce7]\n"
4148 "\\&./a.out[0x8048471]\n"
4149 "======= Memory map: ========\n"
4150 "001e4000-001fe000 r-xp 00000000 08:06 1083555    /lib/libgcc_s.so.1\n"
4151 "001fe000-001ff000 r--p 00019000 08:06 1083555    /lib/libgcc_s.so.1\n"
4152 "[some lines omitted]\n"
4153 "b7814000-b7817000 rw-p 00000000 00:00 0\n"
4154 "bff53000-bff74000 rw-p 00000000 00:00 0          [stack]\n"
4155 "Aborted (core dumped)\n"
4156 msgstr ""
4157 "$ B<./a.out>\n"
4158 "main(): returned from first free() call\n"
4159 "*** glibc detected *** ./a.out: double free or corruption (top): 0x09d30008 ***\n"
4160 "======= Backtrace: =========\n"
4161 "/lib/libc.so.6(+0x6c501)[0x523501]\n"
4162 "/lib/libc.so.6(+0x6dd70)[0x524d70]\n"
4163 "/lib/libc.so.6(cfree+0x6d)[0x527e5d]\n"
4164 "\\&./a.out[0x80485db]\n"
4165 "/lib/libc.so.6(__libc_start_main+0xe7)[0x4cdce7]\n"
4166 "\\&./a.out[0x8048471]\n"
4167 "======= Memory map: ========\n"
4168 "001e4000-001fe000 r-xp 00000000 08:06 1083555    /lib/libgcc_s.so.1\n"
4169 "001fe000-001ff000 r--p 00019000 08:06 1083555    /lib/libgcc_s.so.1\n"
4170 "[some lines omitted]\n"
4171 "b7814000-b7817000 rw-p 00000000 00:00 0\n"
4172 "bff53000-bff74000 rw-p 00000000 00:00 0          [stack]\n"
4173 "Aborted (core dumped)\n"
4174
4175 #. type: Plain text
4176 #: build/C/man3/mallopt.3:504
4177 msgid ""
4178 "The following runs show the results when employing other values for "
4179 "B<M_CHECK_ACTION>:"
4180 msgstr ""
4181
4182 #. type: Plain text
4183 #: build/C/man3/mallopt.3:517
4184 #, no-wrap
4185 msgid ""
4186 "$ B<./a.out 1>             # Diagnose error and continue\n"
4187 "main(): returned from first free() call\n"
4188 "*** glibc detected *** ./a.out: double free or corruption (top): 0x09cbe008 ***\n"
4189 "main(): returned from second free() call\n"
4190 "$ B<./a.out 2>             # Abort without error message\n"
4191 "main(): returned from first free() call\n"
4192 "Aborted (core dumped)\n"
4193 "$ B<./a.out 0>             # Ignore error and continue\n"
4194 "main(): returned from first free() call\n"
4195 "main(): returned from second free() call\n"
4196 msgstr ""
4197 "$ B<./a.out 1>             # Diagnose error and continue\n"
4198 "main(): returned from first free() call\n"
4199 "*** glibc detected *** ./a.out: double free or corruption (top): 0x09cbe008 ***\n"
4200 "main(): returned from second free() call\n"
4201 "$ B<./a.out 2>             # Abort without error message\n"
4202 "main(): returned from first free() call\n"
4203 "Aborted (core dumped)\n"
4204 "$ B<./a.out 0>             # Ignore error and continue\n"
4205 "main(): returned from first free() call\n"
4206 "main(): returned from second free() call\n"
4207
4208 #. type: Plain text
4209 #: build/C/man3/mallopt.3:523
4210 msgid ""
4211 "The next run shows how to set the same parameter using the B<MALLOC_CHECK_> "
4212 "environment variable:"
4213 msgstr ""
4214
4215 #. type: Plain text
4216 #: build/C/man3/mallopt.3:530
4217 #, no-wrap
4218 msgid ""
4219 "$ B<MALLOC_CHECK_=1 ./a.out>\n"
4220 "main(): returned from first free() call\n"
4221 "*** glibc detected *** ./a.out: free(): invalid pointer: 0x092c2008 ***\n"
4222 "main(): returned from second free() call\n"
4223 msgstr ""
4224 "$ B<MALLOC_CHECK_=1 ./a.out>\n"
4225 "main(): returned from first free() call\n"
4226 "*** glibc detected *** ./a.out: free(): invalid pointer: 0x092c2008 ***\n"
4227 "main(): returned from second free() call\n"
4228
4229 #. type: Plain text
4230 #: build/C/man3/mallopt.3:538
4231 #, no-wrap
4232 msgid ""
4233 "#include E<lt>malloc.hE<gt>\n"
4234 "#include E<lt>stdio.hE<gt>\n"
4235 "#include E<lt>stdlib.hE<gt>\n"
4236 msgstr ""
4237 "#include E<lt>malloc.hE<gt>\n"
4238 "#include E<lt>stdio.hE<gt>\n"
4239 "#include E<lt>stdlib.hE<gt>\n"
4240
4241 #. type: Plain text
4242 #: build/C/man3/mallopt.3:543 build/C/man3/mcheck.3:187
4243 #, no-wrap
4244 msgid ""
4245 "int\n"
4246 "main(int argc, char *argv[])\n"
4247 "{\n"
4248 "    char *p;\n"
4249 msgstr ""
4250 "int\n"
4251 "main(int argc, char *argv[])\n"
4252 "{\n"
4253 "    char *p;\n"
4254
4255 #. type: Plain text
4256 #: build/C/man3/mallopt.3:550
4257 #, no-wrap
4258 msgid ""
4259 "    if (argc E<gt> 1) {\n"
4260 "        if (mallopt(M_CHECK_ACTION, atoi(argv[1])) != 1) {\n"
4261 "            fprintf(stderr, \"mallopt() failed\");\n"
4262 "            exit(EXIT_FAILURE);\n"
4263 "        }\n"
4264 "    }\n"
4265 msgstr ""
4266 "    if (argc E<gt> 1) {\n"
4267 "        if (mallopt(M_CHECK_ACTION, atoi(argv[1])) != 1) {\n"
4268 "            fprintf(stderr, \"mallopt() failed\");\n"
4269 "            exit(EXIT_FAILURE);\n"
4270 "        }\n"
4271 "    }\n"
4272
4273 #. type: Plain text
4274 #: build/C/man3/mallopt.3:556
4275 #, no-wrap
4276 msgid ""
4277 "    p = malloc(1000);\n"
4278 "    if (p == NULL) {\n"
4279 "        fprintf(stderr, \"malloc() failed\");\n"
4280 "        exit(EXIT_FAILURE);\n"
4281 "    }\n"
4282 msgstr ""
4283 "    p = malloc(1000);\n"
4284 "    if (p == NULL) {\n"
4285 "        fprintf(stderr, \"malloc() failed\");\n"
4286 "        exit(EXIT_FAILURE);\n"
4287 "    }\n"
4288
4289 #. type: Plain text
4290 #: build/C/man3/mallopt.3:559
4291 #, no-wrap
4292 msgid ""
4293 "    free(p);\n"
4294 "    printf(\"main(): returned from first free() call\\en\");\n"
4295 msgstr ""
4296 "    free(p);\n"
4297 "    printf(\"main(): returned from first free() call\\en\");\n"
4298
4299 #. type: Plain text
4300 #: build/C/man3/mallopt.3:562
4301 #, no-wrap
4302 msgid ""
4303 "    free(p);\n"
4304 "    printf(\"main(): returned from second free() call\\en\");\n"
4305 msgstr ""
4306 "    free(p);\n"
4307 "    printf(\"main(): returned from second free() call\\en\");\n"
4308
4309 #. type: Plain text
4310 #: build/C/man3/mallopt.3:580
4311 msgid ""
4312 "B<mmap>(2), B<sbrk>(2), B<mallinfo>(3), B<malloc>(3), B<malloc_hook>(3), "
4313 "B<malloc_info>(3), B<malloc_stats>(3), B<malloc_trim>(3), B<mcheck>(3), "
4314 "B<mtrace>(3), B<posix_memalign>(3)"
4315 msgstr ""
4316 "B<mmap>(2), B<sbrk>(2), B<mallinfo>(3), B<malloc>(3), B<malloc_hook>(3), "
4317 "B<malloc_info>(3), B<malloc_stats>(3), B<malloc_trim>(3), B<mcheck>(3), "
4318 "B<mtrace>(3), B<posix_memalign>(3)"
4319
4320 #. type: TH
4321 #: build/C/man3/mcheck.3:25
4322 #, no-wrap
4323 msgid "MCHECK"
4324 msgstr "MCHECK"
4325
4326 #. type: TH
4327 #: build/C/man3/mcheck.3:25
4328 #, no-wrap
4329 msgid "2014-01-11"
4330 msgstr "2014-01-11"
4331
4332 #. type: Plain text
4333 #: build/C/man3/mcheck.3:28
4334 msgid ""
4335 "mcheck, mcheck_check_all, mcheck_pedantic, mprobe - heap consistency checking"
4336 msgstr ""
4337
4338 #. type: Plain text
4339 #: build/C/man3/mcheck.3:31
4340 #, no-wrap
4341 msgid "B<#include E<lt>mcheck.hE<gt>>\n"
4342 msgstr "B<#include E<lt>mcheck.hE<gt>>\n"
4343
4344 #. type: Plain text
4345 #: build/C/man3/mcheck.3:33
4346 #, no-wrap
4347 msgid "B<int mcheck(void (*>I<abortfunc>B<)(enum mcheck_status >I<mstatus>B<));>\n"
4348 msgstr ""
4349
4350 #. type: Plain text
4351 #: build/C/man3/mcheck.3:35
4352 #, no-wrap
4353 msgid "B<int mcheck_pedantic(void (*>I<abortfunc>B<)(enum mcheck_status >I<mstatus>B<));>\n"
4354 msgstr ""
4355
4356 #. type: Plain text
4357 #: build/C/man3/mcheck.3:37
4358 #, no-wrap
4359 msgid "B<void mcheck_check_all(void);>\n"
4360 msgstr "B<void mcheck_check_all(void);>\n"
4361
4362 #. type: Plain text
4363 #: build/C/man3/mcheck.3:39
4364 #, no-wrap
4365 msgid "B<enum mcheck_status mprobe(void *>I<ptr>B<);>\n"
4366 msgstr "B<enum mcheck_status mprobe(void *>I<ptr>B<);>\n"
4367
4368 #. type: Plain text
4369 #: build/C/man3/mcheck.3:51
4370 msgid ""
4371 "The B<mcheck>()  function installs a set of debugging hooks for the B<malloc>"
4372 "(3)  family of memory-allocation functions.  These hooks cause certain "
4373 "consistency checks to be performed on the state of the heap.  The checks can "
4374 "detect application errors such as freeing a block of memory more than once "
4375 "or corrupting the bookkeeping data structures that immediately precede a "
4376 "block of allocated memory."
4377 msgstr ""
4378
4379 #. type: Plain text
4380 #: build/C/man3/mcheck.3:63
4381 msgid ""
4382 "To be effective, the B<mcheck>()  function must be called before the first "
4383 "call to B<malloc>(3)  or a related function.  In cases where this is "
4384 "difficult to ensure, linking the program with I<-lmcheck> inserts an "
4385 "implicit call to B<mcheck>()  (with a NULL argument)  before the first call "
4386 "to a memory-allocation function."
4387 msgstr ""
4388
4389 #. type: Plain text
4390 #: build/C/man3/mcheck.3:71
4391 msgid ""
4392 "The B<mcheck_pedantic>()  function is similar to B<mcheck>(), but performs "
4393 "checks on all allocated blocks whenever one of the memory-allocation "
4394 "functions is called.  This can be very slow!"
4395 msgstr ""
4396
4397 #. type: Plain text
4398 #: build/C/man3/mcheck.3:78
4399 msgid ""
4400 "The B<mcheck_check_all>()  function causes an immediate check on all "
4401 "allocated blocks.  This call is effective only if B<mcheck>()  is called "
4402 "beforehand."
4403 msgstr ""
4404
4405 #. type: Plain text
4406 #: build/C/man3/mcheck.3:91
4407 msgid ""
4408 "If the system detects an inconsistency in the heap, the caller-supplied "
4409 "function pointed to by I<abortfunc> is invoked with a single argument "
4410 "argument, I<mstatus>, that indicates what type of inconsistency was "
4411 "detected.  If I<abortfunc> is NULL, a default function prints an error "
4412 "message on I<stderr> and calls B<abort>(3)."
4413 msgstr ""
4414
4415 #. type: Plain text
4416 #: build/C/man3/mcheck.3:103
4417 msgid ""
4418 "The B<mprobe>()  function performs a consistency check on the block of "
4419 "allocated memory pointed to by I<ptr>.  The B<mcheck>()  function should be "
4420 "called beforehand (otherwise B<mprobe>()  returns B<MCHECK_DISABLED>)."
4421 msgstr ""
4422
4423 #. type: Plain text
4424 #: build/C/man3/mcheck.3:111
4425 msgid ""
4426 "The following list describes the values returned by B<mprobe>()  or passed "
4427 "as the I<mstatus> argument when I<abortfunc> is invoked:"
4428 msgstr ""
4429
4430 #. type: TP
4431 #: build/C/man3/mcheck.3:111
4432 #, no-wrap
4433 msgid "B<MCHECK_DISABLED> (B<mprobe>() only)"
4434 msgstr ""
4435
4436 #. type: Plain text
4437 #: build/C/man3/mcheck.3:116
4438 msgid ""
4439 "B<mcheck>()  was not called before the first memory allocation function was "
4440 "called.  Consistency checking is not possible."
4441 msgstr ""
4442
4443 #. type: TP
4444 #: build/C/man3/mcheck.3:116
4445 #, no-wrap
4446 msgid "B<MCHECK_OK> (B<mprobe>() only)"
4447 msgstr ""
4448
4449 #. type: Plain text
4450 #: build/C/man3/mcheck.3:119
4451 msgid "No inconsistency detected."
4452 msgstr ""
4453
4454 #. type: TP
4455 #: build/C/man3/mcheck.3:119
4456 #, no-wrap
4457 msgid "B<MCHECK_HEAD>"
4458 msgstr "B<MCHECK_HEAD>"
4459
4460 #. type: Plain text
4461 #: build/C/man3/mcheck.3:122
4462 msgid "Memory preceding an allocated block was clobbered."
4463 msgstr ""
4464
4465 #. type: TP
4466 #: build/C/man3/mcheck.3:122
4467 #, no-wrap
4468 msgid "B<MCHECK_TAIL>"
4469 msgstr "B<MCHECK_TAIL>"
4470
4471 #. type: Plain text
4472 #: build/C/man3/mcheck.3:125
4473 msgid "Memory following an allocated block was clobbered."
4474 msgstr ""
4475
4476 #. type: TP
4477 #: build/C/man3/mcheck.3:125
4478 #, no-wrap
4479 msgid "B<MCHECK_FREE>"
4480 msgstr "B<MCHECK_FREE>"
4481
4482 #. type: Plain text
4483 #: build/C/man3/mcheck.3:129
4484 msgid "A block of memory was freed twice."
4485 msgstr ""
4486
4487 #. type: Plain text
4488 #: build/C/man3/mcheck.3:134
4489 msgid ""
4490 "B<mcheck>()  and B<mcheck_pedantic>()  return 0 on success, or -1 on error."
4491 msgstr ""
4492
4493 #. type: Plain text
4494 #: build/C/man3/mcheck.3:145
4495 msgid ""
4496 "The B<mcheck_pedantic>()  and B<mcheck_check_all>()  functions are available "
4497 "since glibc 2.2.  The B<mcheck>()  and B<mprobe>()  functions are present "
4498 "since at least glibc 2.0"
4499 msgstr ""
4500
4501 #.  But is MALLOC_CHECK_ slower?
4502 #. type: Plain text
4503 #: build/C/man3/mcheck.3:159
4504 msgid ""
4505 "Linking a program with I<-lmcheck> and using the B<MALLOC_CHECK_> "
4506 "environment variable (described in B<mallopt>(3))  cause the same kinds of "
4507 "errors to be detected.  But, using B<MALLOC_CHECK_> does not require the "
4508 "application to be relinked."
4509 msgstr ""
4510
4511 #. type: Plain text
4512 #: build/C/man3/mcheck.3:165
4513 msgid ""
4514 "The program below calls B<mcheck>()  with a NULL argument and then frees the "
4515 "same block of memory twice.  The following shell session demonstrates what "
4516 "happens when running the program:"
4517 msgstr ""
4518
4519 #. type: Plain text
4520 #: build/C/man3/mcheck.3:170
4521 #, no-wrap
4522 msgid ""
4523 "$B< ./a.out>\n"
4524 "About to free\n"
4525 msgstr ""
4526
4527 #. type: Plain text
4528 #: build/C/man3/mcheck.3:174
4529 #, no-wrap
4530 msgid ""
4531 "About to free a second time\n"
4532 "block freed twice\n"
4533 "Aborted (core dumped)\n"
4534 msgstr ""
4535
4536 #. type: Plain text
4537 #: build/C/man3/mcheck.3:182
4538 #, no-wrap
4539 msgid ""
4540 "#include E<lt>stdlib.hE<gt>\n"
4541 "#include E<lt>stdio.hE<gt>\n"
4542 "#include E<lt>mcheck.hE<gt>\n"
4543 msgstr ""
4544 "#include E<lt>stdlib.hE<gt>\n"
4545 "#include E<lt>stdio.hE<gt>\n"
4546 "#include E<lt>mcheck.hE<gt>\n"
4547
4548 #. type: Plain text
4549 #: build/C/man3/mcheck.3:190
4550 #, no-wrap
4551 msgid ""
4552 "    if (mcheck(NULL) != 0) {\n"
4553 "        fprintf(stderr, \"mcheck() failed\\en\");\n"
4554 msgstr ""
4555
4556 #. type: Plain text
4557 #: build/C/man3/mcheck.3:193
4558 #, no-wrap
4559 msgid ""
4560 "        exit(EXIT_FAILURE);\n"
4561 "    }\n"
4562 msgstr ""
4563 "        exit(EXIT_FAILURE);\n"
4564 "    }\n"
4565
4566 #. type: Plain text
4567 #: build/C/man3/mcheck.3:195
4568 #, no-wrap
4569 msgid "    p = malloc(1000);\n"
4570 msgstr "    p = malloc(1000);\n"
4571
4572 #. type: Plain text
4573 #: build/C/man3/mcheck.3:200
4574 #, no-wrap
4575 msgid ""
4576 "    fprintf(stderr, \"About to free\\en\");\n"
4577 "    free(p);\n"
4578 "    fprintf(stderr, \"\\enAbout to free a second time\\en\");\n"
4579 "    free(p);\n"
4580 msgstr ""
4581
4582 #. type: Plain text
4583 #: build/C/man3/mcheck.3:208
4584 msgid "B<malloc>(3), B<mallopt>(3), B<mtrace>(3)"
4585 msgstr "B<malloc>(3), B<mallopt>(3), B<mtrace>(3)"
4586
4587 #. type: TH
4588 #: build/C/man2/mlock.2:26
4589 #, no-wrap
4590 msgid "MLOCK"
4591 msgstr "MLOCK"
4592
4593 #. type: TH
4594 #: build/C/man2/mlock.2:26
4595 #, no-wrap
4596 msgid "2014-04-14"
4597 msgstr "2014-04-14"
4598
4599 #. type: Plain text
4600 #: build/C/man2/mlock.2:29
4601 msgid "mlock, munlock, mlockall, munlockall - lock and unlock memory"
4602 msgstr "mlock - メモリのロックとロック解除を行う"
4603
4604 #. type: Plain text
4605 #: build/C/man2/mlock.2:32 build/C/man2/mmap.2:46 build/C/man2/mmap2.2:35
4606 #: build/C/man2/mprotect.2:44 build/C/man2/mremap.2:38
4607 #, no-wrap
4608 msgid "B<#include E<lt>sys/mman.hE<gt>>\n"
4609 msgstr "B<#include E<lt>sys/mman.hE<gt>>\n"
4610
4611 #. type: Plain text
4612 #: build/C/man2/mlock.2:35
4613 #, no-wrap
4614 msgid ""
4615 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
4616 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
4617 msgstr ""
4618 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
4619 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
4620
4621 #. type: Plain text
4622 #: build/C/man2/mlock.2:38
4623 #, no-wrap
4624 msgid ""
4625 "B<int mlockall(int >I<flags>B<);>\n"
4626 "B<int munlockall(void);>\n"
4627 msgstr ""
4628 "B<int mlockall(int >I<flags>B<);>\n"
4629 "B<int munlockall(void);>\n"
4630
4631 #. type: Plain text
4632 #: build/C/man2/mlock.2:54
4633 msgid ""
4634 "B<mlock>()  and B<mlockall>()  respectively lock part or all of the calling "
4635 "process's virtual address space into RAM, preventing that memory from being "
4636 "paged to the swap area.  B<munlock>()  and B<munlockall>()  perform the "
4637 "converse operation, respectively unlocking part or all of the calling "
4638 "process's virtual address space, so that pages in the specified virtual "
4639 "address range may once more to be swapped out if required by the kernel "
4640 "memory manager.  Memory locking and unlocking are performed in units of "
4641 "whole pages."
4642 msgstr ""
4643 "B<mlock>()  と B<mlockall>()  はそれぞれ、呼び出し元プロセスの仮想アドレス空"
4644 "間の一部または全部を RAM 上にロックし、メモリがスワップエリアにページングされ"
4645 "るのを防ぐ。 B<munlock>()  と B<munlockall>()  は逆の操作で、それぞれ呼び出し"
4646 "元プロセスの仮想アドレス空間の一部または全部を ロック解除する。つまり、指定さ"
4647 "れた仮想アドレス範囲のページは カーネルメモリマネージャーから要求されればス"
4648 "ワップアウトするようになる。 メモリのロックとロック解除はページ単位で行われ"
4649 "る。"
4650
4651 #. type: SS
4652 #: build/C/man2/mlock.2:54
4653 #, no-wrap
4654 msgid "mlock() and munlock()"
4655 msgstr "mlock() と munlock()"
4656
4657 #. type: Plain text
4658 #: build/C/man2/mlock.2:64
4659 msgid ""
4660 "B<mlock>()  locks pages in the address range starting at I<addr> and "
4661 "continuing for I<len> bytes.  All pages that contain a part of the specified "
4662 "address range are guaranteed to be resident in RAM when the call returns "
4663 "successfully; the pages are guaranteed to stay in RAM until later unlocked."
4664 msgstr ""
4665 "B<mlock>()  は I<addr> から始まる長さ I<len> バイトのアドレス範囲のページを"
4666 "ロックする。 呼び出しが成功した場合には、 指定されたアドレス範囲を含む全ての"
4667 "ページは RAM に残り続けることが保証される。 これらのページは後でロック解除さ"
4668 "れるまで RAM に残り続けることが保証される。"
4669
4670 #. type: Plain text
4671 #: build/C/man2/mlock.2:73
4672 msgid ""
4673 "B<munlock>()  unlocks pages in the address range starting at I<addr> and "
4674 "continuing for I<len> bytes.  After this call, all pages that contain a part "
4675 "of the specified memory range can be moved to external swap space again by "
4676 "the kernel."
4677 msgstr ""
4678 "B<munlock>()  は、 I<addr> から始まる長さ I<len> バイトのアドレス範囲のページ"
4679 "のロックを解除する。 この呼び出しを行った後は、カーネルが、指定されたメモリ範"
4680 "囲を含む 全てのページを外部のスワップ空間に移動できるようになる。"
4681
4682 #. type: SS
4683 #: build/C/man2/mlock.2:73
4684 #, no-wrap
4685 msgid "mlockall() and munlockall()"
4686 msgstr "mlockall() と munlockall()"
4687
4688 #. type: Plain text
4689 #: build/C/man2/mlock.2:83
4690 msgid ""
4691 "B<mlockall>()  locks all pages mapped into the address space of the calling "
4692 "process.  This includes the pages of the code, data and stack segment, as "
4693 "well as shared libraries, user space kernel data, shared memory, and memory-"
4694 "mapped files.  All mapped pages are guaranteed to be resident in RAM when "
4695 "the call returns successfully; the pages are guaranteed to stay in RAM until "
4696 "later unlocked."
4697 msgstr ""
4698 "B<mlockall>()  は呼び出し元プロセスのアドレス空間にマップされている全てのペー"
4699 "ジを ロックする。これにはコード、データ、スタックの 各セグメント、共有ライブ"
4700 "ラリ、カーネルのユーザー空間データ、 共有メモリ、メモリ・マップされたファイル"
4701 "が含まれる。 システム・コールが成功した場合には全てのマップされたページは "
4702 "RAM に 残ることを保証される。 これらのページは後でロック解除されるまで RAM に"
4703 "残り続けることが保証される。"
4704
4705 #. type: Plain text
4706 #: build/C/man2/mlock.2:88
4707 msgid ""
4708 "The I<flags> argument is constructed as the bitwise OR of one or more of the "
4709 "following constants:"
4710 msgstr "I<flags> 引数は以下の内容の一つまたは複数のビット OR から構成される:"
4711
4712 #. type: TP
4713 #: build/C/man2/mlock.2:88
4714 #, no-wrap
4715 msgid "B<MCL_CURRENT>"
4716 msgstr "B<MCL_CURRENT>"
4717
4718 #. type: Plain text
4719 #: build/C/man2/mlock.2:92
4720 msgid ""
4721 "Lock all pages which are currently mapped into the address space of the "
4722 "process."
4723 msgstr ""
4724 "現在、プロセスのアドレス空間にマップされている全てのページをロックする。"
4725
4726 #. type: TP
4727 #: build/C/man2/mlock.2:92
4728 #, no-wrap
4729 msgid "B<MCL_FUTURE>"
4730 msgstr "B<MCL_FUTURE>"
4731
4732 #. type: Plain text
4733 #: build/C/man2/mlock.2:99
4734 msgid ""
4735 "Lock all pages which will become mapped into the address space of the "
4736 "process in the future.  These could be for instance new pages required by a "
4737 "growing heap and stack as well as new memory-mapped files or shared memory "
4738 "regions."
4739 msgstr ""
4740 "将来、プロセスのアドレス空間にマップされる全てのページをロックする。 例えば、"
4741 "ヒープ (heap) やスタックの成長により新しく必要になったページだけで なく、新し"
4742 "くメモリマップされたファイルや共有メモリ領域もロックされる。"
4743
4744 #. type: Plain text
4745 #: build/C/man2/mlock.2:112
4746 msgid ""
4747 "If B<MCL_FUTURE> has been specified, then a later system call (e.g., B<mmap>"
4748 "(2), B<sbrk>(2), B<malloc>(3)), may fail if it would cause the number of "
4749 "locked bytes to exceed the permitted maximum (see below).  In the same "
4750 "circumstances, stack growth may likewise fail: the kernel will deny stack "
4751 "expansion and deliver a B<SIGSEGV> signal to the process."
4752 msgstr ""
4753 "B<MCL_FUTURE> が指定されていると、以後のシステムコール (例えば、 B<mmap>(2), "
4754 "B<sbrk>(2), B<malloc>(3))  は、ロックするバイト数が許可された最大値 (下記参"
4755 "照) を超えた場合に 失敗する可能性がある。 同様に、スタックの成長も失敗する可"
4756 "能性がある。 その場合、カーネルはスタックの拡張を拒否し、 B<SIGSEGV> をプロセ"
4757 "スに送る。"
4758
4759 #. type: Plain text
4760 #: build/C/man2/mlock.2:116
4761 msgid ""
4762 "B<munlockall>()  unlocks all pages mapped into the address space of the "
4763 "calling process."
4764 msgstr ""
4765 "B<munlockall>()  は、呼び出し元プロセスのアドレス空間にマッピングされている "
4766 "全てのページをロック解除する。"
4767
4768 #. type: Plain text
4769 #: build/C/man2/mlock.2:122
4770 msgid ""
4771 "On success these system calls return 0.  On error, -1 is returned, I<errno> "
4772 "is set appropriately, and no changes are made to any locks in the address "
4773 "space of the process."
4774 msgstr ""
4775 "成功した場合は、これらのシステムコールはゼロを返す。 エラーの場合は -1 が返さ"
4776 "れ、 I<errno> が適切に設定され、プロセスのアドレス空間におけるロックは変更さ"
4777 "れない。"
4778
4779 #. type: Plain text
4780 #: build/C/man2/mlock.2:131
4781 msgid ""
4782 "(Linux 2.6.9 and later) the caller had a nonzero B<RLIMIT_MEMLOCK> soft "
4783 "resource limit, but tried to lock more memory than the limit permitted.  "
4784 "This limit is not enforced if the process is privileged (B<CAP_IPC_LOCK>)."
4785 msgstr ""
4786 "(Linux 2.6.9 以降) 呼び出し元は非ゼロの ソフト資源制限 B<RLIMIT_MEMLOCK> を持"
4787 "つが、制限が許可している以上のメモリをロックしようとした。 この制限は、プロセ"
4788 "スが特権 (B<CAP_IPC_LOCK>)  を持っている場合は適用されない。"
4789
4790 #.  In the case of mlock(), this check is somewhat buggy: it doesn't
4791 #.  take into account whether the to-be-locked range overlaps with
4792 #.  already locked pages.  Thus, suppose we allocate
4793 #.  (num_physpages / 4 + 1) of memory, and lock those pages once using
4794 #.  mlock(), and then lock the *same* page range a second time.
4795 #.  In the case, the second mlock() call will fail, since the check
4796 #.  calculates that the process is trying to lock (num_physpages / 2 + 2)
4797 #.  pages, which of course is not true.  (MTK, Nov 04, kernel 2.4.28)
4798 #. type: Plain text
4799 #: build/C/man2/mlock.2:143
4800 msgid ""
4801 "(Linux 2.4 and earlier) the calling process tried to lock more than half of "
4802 "RAM."
4803 msgstr ""
4804 "(Linux 2.4 以前) 呼び出し元プロセスが RAM の半分以上をロックしようとした。"
4805
4806 #. SVr4 documents an additional EAGAIN error code.
4807 #. type: Plain text
4808 #: build/C/man2/mlock.2:149
4809 msgid ""
4810 "The caller is not privileged, but needs privilege (B<CAP_IPC_LOCK>)  to "
4811 "perform the requested operation."
4812 msgstr ""
4813 "呼び出し側が特権を持っていないが、\n"
4814 "要求された操作を実行するには特権 (B<CAP_IPC_LOCK>) が必要である。"
4815
4816 #. type: Plain text
4817 #: build/C/man2/mlock.2:154
4818 msgid "For B<mlock>()  and B<munlock>():"
4819 msgstr "B<mlock>()  と B<munlock>()  用として:"
4820
4821 #. type: Plain text
4822 #: build/C/man2/mlock.2:157
4823 msgid "Some or all of the specified address range could not be locked."
4824 msgstr "指定されたアドレス範囲の一部または全てをロックすることができなかった。"
4825
4826 #. type: Plain text
4827 #: build/C/man2/mlock.2:164
4828 msgid ""
4829 "The result of the addition I<start>+I<len> was less than I<start> (e.g., the "
4830 "addition may have resulted in an overflow)."
4831 msgstr ""
4832 "I<start>+I<len> の加算の結果が I<start> よりも小さかった\n"
4833 "(例えば、加算でオーバーフローが発生したなど)。"
4834
4835 #. type: Plain text
4836 #: build/C/man2/mlock.2:169
4837 msgid "(Not on Linux)  I<addr> was not a multiple of the page size."
4838 msgstr ""
4839 "(Linux ではこの意味で使われない)  I<addr> がページサイズの倍数ではない。"
4840
4841 #. type: Plain text
4842 #: build/C/man2/mlock.2:173
4843 msgid ""
4844 "Some of the specified address range does not correspond to mapped pages in "
4845 "the address space of the process."
4846 msgstr ""
4847 "指定されたアドレス範囲がプロセスのアドレス空間にマップされたページと 一致しな"
4848 "い。"
4849
4850 #. type: Plain text
4851 #: build/C/man2/mlock.2:176
4852 msgid "For B<mlockall>():"
4853 msgstr "B<mlockall>()  用として:"
4854
4855 #. type: Plain text
4856 #: build/C/man2/mlock.2:179
4857 msgid "Unknown I<flags> were specified."
4858 msgstr "未知の I<flags> が指定された。"
4859
4860 #. type: Plain text
4861 #: build/C/man2/mlock.2:182
4862 msgid "For B<munlockall>():"
4863 msgstr "B<munlockall>()  用として:"
4864
4865 #. type: Plain text
4866 #: build/C/man2/mlock.2:186
4867 msgid ""
4868 "(Linux 2.6.8 and earlier) The caller was not privileged (B<CAP_IPC_LOCK>)."
4869 msgstr ""
4870 "(Linux 2.6.8 以前) 呼び出し元が権限 (B<CAP_IPC_LOCK>)  を持っていない。"
4871
4872 #. type: Plain text
4873 #: build/C/man2/mlock.2:188
4874 msgid "POSIX.1-2001, SVr4."
4875 msgstr "POSIX.1-2001, SVr4."
4876
4877 #. type: SH
4878 #: build/C/man2/mlock.2:188 build/C/man2/mmap.2:499 build/C/man2/msync.2:105
4879 #, no-wrap
4880 msgid "AVAILABILITY"
4881 msgstr "可用性"
4882
4883 #. type: Plain text
4884 #: build/C/man2/mlock.2:200
4885 msgid ""
4886 "On POSIX systems on which B<mlock>()  and B<munlock>()  are available, "
4887 "B<_POSIX_MEMLOCK_RANGE> is defined in I<E<lt>unistd.hE<gt>> and the number "
4888 "of bytes in a page can be determined from the constant B<PAGESIZE> (if "
4889 "defined) in I<E<lt>limits.hE<gt>> or by calling I<sysconf(_SC_PAGESIZE)>."
4890 msgstr ""
4891 "B<mlock>()  と B<munlock>()  が使用可能な POSIX システムでは "
4892 "B<_POSIX_MEMLOCK_RANGE> が I<E<lt>unistd.hE<gt>> で定義されている。 また、"
4893 "ページあたりのバイト数は、 I<E<lt>limits.hE<gt>> で定義される定数 "
4894 "B<PAGESIZE> から (定義されている場合)、もしくは I<sysconf(_SC_PAGESIZE)> を呼"
4895 "び出すことで決定できる。"
4896
4897 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
4898 #.  -1: unavailable, 0: ask using sysconf().
4899 #.  glibc defines it to 1.
4900 #. type: Plain text
4901 #: build/C/man2/mlock.2:213
4902 msgid ""
4903 "On POSIX systems on which B<mlockall>()  and B<munlockall>()  are available, "
4904 "B<_POSIX_MEMLOCK> is defined in I<E<lt>unistd.hE<gt>> to a value greater "
4905 "than 0.  (See also B<sysconf>(3).)"
4906 msgstr ""
4907 "B<mlockall>()  と B<munlockall>()  が利用可能な POSIX システムでは、 "
4908 "B<_POSIX_MEMLOCK> は I<E<lt>unistd.hE<gt>> で 0 より大きい値に定義されている "
4909 "(B<sysconf>(3)  も参照のこと)。"
4910
4911 #. type: Plain text
4912 #: build/C/man2/mlock.2:231
4913 msgid ""
4914 "Memory locking has two main applications: real-time algorithms and high-"
4915 "security data processing.  Real-time applications require deterministic "
4916 "timing, and, like scheduling, paging is one major cause of unexpected "
4917 "program execution delays.  Real-time applications will usually also switch "
4918 "to a real-time scheduler with B<sched_setscheduler>(2).  Cryptographic "
4919 "security software often handles critical bytes like passwords or secret keys "
4920 "as data structures.  As a result of paging, these secrets could be "
4921 "transferred onto a persistent swap store medium, where they might be "
4922 "accessible to the enemy long after the security software has erased the "
4923 "secrets in RAM and terminated.  (But be aware that the suspend mode on "
4924 "laptops and some desktop computers will save a copy of the system's RAM to "
4925 "disk, regardless of memory locks.)"
4926 msgstr ""
4927 "メモリのロックの用途としては主に二つある: リアルタイム アルゴリズムと高いセ"
4928 "キュリティの必要なデータ処理である。リアルタイムの アプリケーションは決定的な"
4929 "タイミングやスケジューリングを必要とするが、 ページングは予期しないプログラム"
4930 "の実行遅延をもたらす主要な要因となる。 リアルタイムのアプリケーションはたいて"
4931 "いは B<sched_setscheduler>(2)  でリアルタイムスケジューラに変更される。 暗号"
4932 "やセキュリティのソフトウェアはしばしばパスワードや秘密鍵のデータの ような重要"
4933 "なバイト列を扱う。ページングの結果、これらの秘密が スワップ用の固定媒体に転送"
4934 "されるかもしれない。そして、セキュリティ・ ソフトウェアが RAM 上の秘密を削除"
4935 "して終了したずっと後になっても、 このスワップされたデータには敵がアクセスでき"
4936 "る可能性がある (しかし、ラップトップといくつかのデスクトップコンピュータの サ"
4937 "スペンドモードはシステムの RAM の内容をメモリのロックに関わらず ディスクに保"
4938 "存することに注意)。"
4939
4940 #. type: Plain text
4941 #: build/C/man2/mlock.2:244
4942 msgid ""
4943 "Real-time processes that are using B<mlockall>()  to prevent delays on page "
4944 "faults should reserve enough locked stack pages before entering the time-"
4945 "critical section, so that no page fault can be caused by function calls.  "
4946 "This can be achieved by calling a function that allocates a sufficiently "
4947 "large automatic variable (an array) and writes to the memory occupied by "
4948 "this array in order to touch these stack pages.  This way, enough pages will "
4949 "be mapped for the stack and can be locked into RAM.  The dummy writes ensure "
4950 "that not even copy-on-write page faults can occur in the critical section."
4951 msgstr ""
4952 "リアルタイムプロセスが B<mlockall>()  を使ってページフォールトによる遅延を防"
4953 "ごうとする場合、 関数呼び出しによってページフォールトが発生しないように、 時"
4954 "間制限の厳しい部分 (time-critical section) に入る前に 十分な量のロックされた"
4955 "スタックを確保しておく必要がある。 これを実現するには、十分な大きさの自動変"
4956 "数 (の配列) を確保し、 これらのスタック用のページがメモリ上に確保されるように"
4957 "この配列に 書き込みを行う関数を用意し、これを呼び出せばよい。こうすること"
4958 "で、 十分な量のページがスタックにマッピングされ、RAM にロックされる。 ダミー"
4959 "の書き込みを行うことによって、 時間制限の厳しい部分 (critical section) 内では"
4960 "書き込み時コピーによる ページフォールトさえも発生しないことが保証される。"
4961
4962 #. type: Plain text
4963 #: build/C/man2/mlock.2:257
4964 msgid ""
4965 "Memory locks are not inherited by a child created via B<fork>(2)  and are "
4966 "automatically removed (unlocked) during an B<execve>(2)  or when the process "
4967 "terminates.  The B<mlockall>()  B<MCL_FUTURE> setting is not inherited by a "
4968 "child created via B<fork>(2)  and is cleared during an B<execve>(2)."
4969 msgstr "メモリロックは B<fork>(2)  で作成された子プロセスには継承されず、 B<execve>(2)  が呼ばれたり、プロセスが終了した場合は 自動的に削除される (ロック解除される)。 B<mlockall>() の B<MCL_FUTURE> 設定は B<fork>(2) で作成された子プロセスには継承されず、 B<execve>(2) の中でクリアされる。"
4970
4971 #. type: Plain text
4972 #: build/C/man2/mlock.2:261
4973 msgid ""
4974 "The memory lock on an address range is automatically removed if the address "
4975 "range is unmapped via B<munmap>(2)."
4976 msgstr ""
4977 "あるアドレス範囲に対するメモリロックは、そのアドレス範囲が B<munmap>(2)  に"
4978 "よってアンマップされた場合は削除される。"
4979
4980 #. type: Plain text
4981 #: build/C/man2/mlock.2:274
4982 msgid ""
4983 "Memory locks do not stack, that is, pages which have been locked several "
4984 "times by calls to B<mlock>()  or B<mlockall>()  will be unlocked by a single "
4985 "call to B<munlock>()  for the corresponding range or by B<munlockall>().  "
4986 "Pages which are mapped to several locations or by several processes stay "
4987 "locked into RAM as long as they are locked at least at one location or by at "
4988 "least one process."
4989 msgstr ""
4990 "メモリのロックは累積しない。 すなわち複数回 B<mlock>()  や B<mlockall>()  を"
4991 "呼び出してロックされたページでも、 対応する範囲に対して B<munlock>()  を 1 回"
4992 "呼び出したり B<munlockall>()  を呼び出したりするだけでロック解除される。 複数"
4993 "の場所や複数のプロセスにマップされているページは、少なくとも一つの場所、 一つ"
4994 "のプロセスでロックされている限りは RAM に残り続ける。"
4995
4996 #. type: Plain text
4997 #: build/C/man2/mlock.2:285
4998 msgid ""
4999 "Under Linux, B<mlock>()  and B<munlock>()  automatically round I<addr> down "
5000 "to the nearest page boundary.  However, POSIX.1-2001 allows an "
5001 "implementation to require that I<addr> is page aligned, so portable "
5002 "applications should ensure this."
5003 msgstr ""
5004 "Linux では、 B<mlock>()  と B<munlock>()  は自動的に I<addr> を端数切り捨てに"
5005 "より一番近いページ境界へと丸める。 しかし POSIX.1-2001 は I<addr> がページ境"
5006 "界に合っていることを要求する実装も許している。 そのため移植性を意図したアプリ"
5007 "ケーションではきちんと境界に合わせた方が良い。"
5008
5009 #. type: Plain text
5010 #: build/C/man2/mlock.2:298
5011 msgid ""
5012 "The I<VmLck> field of the Linux-specific I</proc/PID/status> file shows how "
5013 "many kilobytes of memory the process with ID I<PID> has locked using B<mlock>"
5014 "(), B<mlockall>(), and B<mmap>(2)  B<MAP_LOCKED>."
5015 msgstr ""
5016 "Linux 固有の I</proc/PID/status> ファイルの I<VmLck> フィールドには、\n"
5017 "B<mlock>(), B<mlockall>() および B<mmap>(2) B<MAP_LOCKED> を使って、\n"
5018 "ID が I<PID> のプロセスがロックしているメモリ量 (キロバイト単位) が\n"
5019 "表示される。"
5020
5021 #. type: SS
5022 #: build/C/man2/mlock.2:298
5023 #, no-wrap
5024 msgid "Limits and permissions"
5025 msgstr "制限と権限"
5026
5027 #. type: Plain text
5028 #: build/C/man2/mlock.2:305
5029 msgid ""
5030 "In Linux 2.6.8 and earlier, a process must be privileged (B<CAP_IPC_LOCK>)  "
5031 "in order to lock memory and the B<RLIMIT_MEMLOCK> soft resource limit "
5032 "defines a limit on how much memory the process may lock."
5033 msgstr ""
5034 "Linux 2.6.8 以前では、メモリをロックするためには特権 (B<CAP_IPC_LOCK>)  が必"
5035 "要で、 ソフト資源制限 B<RLIMIT_MEMLOCK> はプロセスがどれだけのメモリをロック"
5036 "できるかの制限を定義する。"
5037
5038 #. type: Plain text
5039 #: build/C/man2/mlock.2:311
5040 msgid ""
5041 "Since Linux 2.6.9, no limits are placed on the amount of memory that a "
5042 "privileged process can lock and the B<RLIMIT_MEMLOCK> soft resource limit "
5043 "instead defines a limit on how much memory an unprivileged process may lock."
5044 msgstr ""
5045 "Linux 2.6.9 以降では、特権を持つプロセスがロックできるメモリ量は無制限とな"
5046 "り、 代わりにソフト資源制限 B<RLIMIT_MEMLOCK> は特権を持たないプロセスがロッ"
5047 "クできるメモリ量の制限を定義する。"
5048
5049 #. type: Plain text
5050 #: build/C/man2/mlock.2:319
5051 msgid ""
5052 "In the 2.4 series Linux kernels up to and including 2.4.17, a bug caused the "
5053 "B<mlockall>()  B<MCL_FUTURE> flag to be inherited across a B<fork>(2).  This "
5054 "was rectified in kernel 2.4.18."
5055 msgstr ""
5056 "2.4.17 までの 2.4 シリーズの Linux カーネルには、 B<mlockall>()  "
5057 "B<MCL_FUTURE> フラグが B<fork>(2)  で継承されると言うバグがある。 これはカー"
5058 "ネル 2.4.18 で修正された。"
5059
5060 #.  See the following LKML thread:
5061 #.  http://marc.theaimsgroup.com/?l=linux-kernel&m=113801392825023&w=2
5062 #.  "Rationale for RLIMIT_MEMLOCK"
5063 #.  23 Jan 2006
5064 #. type: Plain text
5065 #: build/C/man2/mlock.2:336
5066 msgid ""
5067 "Since kernel 2.6.9, if a privileged process calls I<mlockall(MCL_FUTURE)> "
5068 "and later drops privileges (loses the B<CAP_IPC_LOCK> capability by, for "
5069 "example, setting its effective UID to a nonzero value), then subsequent "
5070 "memory allocations (e.g., B<mmap>(2), B<brk>(2))  will fail if the "
5071 "B<RLIMIT_MEMLOCK> resource limit is encountered."
5072 msgstr ""
5073 "カーネル 2.6.9 以降では、特権を持ったプロセスが I<mlockall(MCL_FUTURE)> を呼"
5074 "び出した後で、特権をなくした場合 (例えば、 実効 UID を 0 以外の値に変更するな"
5075 "どにより、 B<CAP_IPC_LOCK> ケーパビリティを失った場合)、リソース上限 "
5076 "B<RLIMIT_MEMLOCK> に達すると、それ以降のメモリ割り当て (例えば B<mmap>(2), "
5077 "B<brk>(2))  は失敗する。"
5078
5079 #. type: Plain text
5080 #: build/C/man2/mlock.2:343
5081 msgid ""
5082 "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5), "
5083 "B<capabilities>(7)"
5084 msgstr ""
5085 "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5),\n"
5086 "B<capabilities>(7)"
5087
5088 #. type: TH
5089 #: build/C/man2/mmap.2:40
5090 #, no-wrap
5091 msgid "MMAP"
5092 msgstr "MMAP"
5093
5094 #. type: TH
5095 #: build/C/man2/mmap.2:40
5096 #, no-wrap
5097 msgid "2014-04-06"
5098 msgstr "2014-04-06"
5099
5100 #. type: Plain text
5101 #: build/C/man2/mmap.2:43
5102 msgid "mmap, munmap - map or unmap files or devices into memory"
5103 msgstr "mmap, munmap - ファイルやデバイスをメモリにマップ/アンマップする"
5104
5105 #. type: Plain text
5106 #: build/C/man2/mmap.2:51
5107 #, no-wrap
5108 msgid ""
5109 "B<void *mmap(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<, int >I<flags>B<,>\n"
5110 "B<           int >I<fd>B<, off_t >I<offset>B<);>\n"
5111 "B<int munmap(void *>I<addr>B<, size_t >I<length>B<);>\n"
5112 msgstr ""
5113 "B<void *mmap(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<, int >I<flags>B<,>\n"
5114 "B<           int >I<fd>B<, off_t >I<offset>B<);>\n"
5115 "B<int munmap(void *>I<addr>B<, size_t >I<length>B<);>\n"
5116
5117 #. type: Plain text
5118 #: build/C/man2/mmap.2:54
5119 msgid "See NOTES for information on feature test macro requirements."
5120 msgstr "機能検査マクロの要件に関する情報は「注意」の節を参照。"
5121
5122 #. type: Plain text
5123 #: build/C/man2/mmap.2:63
5124 msgid ""
5125 "B<mmap>()  creates a new mapping in the virtual address space of the calling "
5126 "process.  The starting address for the new mapping is specified in I<addr>.  "
5127 "The I<length> argument specifies the length of the mapping."
5128 msgstr ""
5129 "B<mmap>()  は、新しいマッピングを呼び出し元プロセスの仮想アドレス空間に作成す"
5130 "る。 新しいマッピングの開始アドレスは I<addr> で指定される。マッピングの長さ"
5131 "は I<length> 引き数で指定される。"
5132
5133 #.  Before Linux 2.6.24, the address was rounded up to the next page
5134 #.  boundary; since 2.6.24, it is rounded down!
5135 #. type: Plain text
5136 #: build/C/man2/mmap.2:77
5137 msgid ""
5138 "If I<addr> is NULL, then the kernel chooses the address at which to create "
5139 "the mapping; this is the most portable method of creating a new mapping.  If "
5140 "I<addr> is not NULL, then the kernel takes it as a hint about where to place "
5141 "the mapping; on Linux, the mapping will be created at a nearby page "
5142 "boundary.  The address of the new mapping is returned as the result of the "
5143 "call."
5144 msgstr ""
5145 "I<addr> が NULL の場合、カーネルがマッピングを作成するアドレスを選択する。 こ"
5146 "の方法は最も移植性のある新しいマッピングの作成方法である。 I<addr> が NULL で"
5147 "ない場合、カーネルはマッピングをどこに配置するかのヒントとして I<addr> を使用"
5148 "する。Linux では、マッピングはすぐ近くのページ境界に作成される。 新しいマッピ"
5149 "ングのアドレスは、呼び出しの返り値として返される。"
5150
5151 #. type: Plain text
5152 #: build/C/man2/mmap.2:89
5153 msgid ""
5154 "The contents of a file mapping (as opposed to an anonymous mapping; see "
5155 "B<MAP_ANONYMOUS> below), are initialized using I<length> bytes starting at "
5156 "offset I<offset> in the file (or other object) referred to by the file "
5157 "descriptor I<fd>.  I<offset> must be a multiple of the page size as returned "
5158 "by I<sysconf(_SC_PAGE_SIZE)>."
5159 msgstr ""
5160 "ファイルマッピングの内容は、 ファイルディスクリプタ I<fd> で参照されるファイ"
5161 "ル (もしくは他のオブジェクト) のオフセット I<offset> から開始される "
5162 "I<length> バイトのデータで初期化される (ファイルマッピングは無名マッピングの"
5163 "反対語である。 B<MAP_ANONYMOUS> を参照)。 I<offset> は I<sysconf"
5164 "(_SC_PAGE_SIZE)> が返すページサイズの倍数でなければならない。"
5165
5166 #. type: Plain text
5167 #: build/C/man2/mmap.2:97
5168 msgid ""
5169 "The I<prot> argument describes the desired memory protection of the mapping "
5170 "(and must not conflict with the open mode of the file).  It is either "
5171 "B<PROT_NONE> or the bitwise OR of one or more of the following flags:"
5172 msgstr ""
5173 "引き数 I<prot> には、マッピングのメモリ保護をどのように行なうかを指定する "
5174 "(ファイルのオープンモードと矛盾してはいけない)。 I<prot> には、 B<PROT_NONE> "
5175 "か、以下のフラグをひとつ以上ビット毎の論理和 (OR) をとったものを 指定できる。"
5176
5177 #. type: TP
5178 #: build/C/man2/mmap.2:97 build/C/man2/mprotect.2:73
5179 #, no-wrap
5180 msgid "B<PROT_EXEC>"
5181 msgstr "B<PROT_EXEC>"
5182
5183 #. type: Plain text
5184 #: build/C/man2/mmap.2:100
5185 msgid "Pages may be executed."
5186 msgstr "ページは実行可能である。"
5187
5188 #. type: TP
5189 #: build/C/man2/mmap.2:100 build/C/man2/mprotect.2:67
5190 #, no-wrap
5191 msgid "B<PROT_READ>"
5192 msgstr "B<PROT_READ>"
5193
5194 #. type: Plain text
5195 #: build/C/man2/mmap.2:103
5196 msgid "Pages may be read."
5197 msgstr "ページは読み込み可能である。"
5198
5199 #. type: TP
5200 #: build/C/man2/mmap.2:103 build/C/man2/mprotect.2:70
5201 #, no-wrap
5202 msgid "B<PROT_WRITE>"
5203 msgstr "B<PROT_WRITE>"
5204
5205 #. type: Plain text
5206 #: build/C/man2/mmap.2:106
5207 msgid "Pages may be written."
5208 msgstr "ページに書き込み可能である。"
5209
5210 #. type: TP
5211 #: build/C/man2/mmap.2:106 build/C/man2/mprotect.2:64
5212 #, no-wrap
5213 msgid "B<PROT_NONE>"
5214 msgstr "B<PROT_NONE>"
5215
5216 #. type: Plain text
5217 #: build/C/man2/mmap.2:109
5218 msgid "Pages may not be accessed."
5219 msgstr "ページにはアクセスできない。"
5220
5221 #. type: Plain text
5222 #: build/C/man2/mmap.2:118
5223 msgid ""
5224 "The I<flags> argument determines whether updates to the mapping are visible "
5225 "to other processes mapping the same region, and whether updates are carried "
5226 "through to the underlying file.  This behavior is determined by including "
5227 "exactly one of the following values in I<flags>:"
5228 msgstr ""
5229 "I<flags> 引き数により、マッピングに対する更新が同じ領域をマッピングしている "
5230 "他のプロセスに見えるか、更新がマッピング元のファイルを通じて 伝えられるか、が"
5231 "決定される。この動作は、以下の値のいずれか一つだけ (複数は指定できない) を "
5232 "I<flags> に含めることで指定する。"
5233
5234 #. type: TP
5235 #: build/C/man2/mmap.2:118
5236 #, no-wrap
5237 msgid "B<MAP_SHARED>"
5238 msgstr "B<MAP_SHARED>"
5239
5240 #. type: Plain text
5241 #: build/C/man2/mmap.2:128
5242 msgid ""
5243 "Share this mapping.  Updates to the mapping are visible to other processes "
5244 "that map this file, and are carried through to the underlying file.  The "
5245 "file may not actually be updated until B<msync>(2)  or B<munmap>()  is "
5246 "called."
5247 msgstr ""
5248 "このマッピングを共有する。 マッピングに対する更新はこのファイルをマッピングし"
5249 "ている他のプロセス から見える。更新はマッピング元のファイルを通じて伝えられ"
5250 "る。 ただし、ファイルの実際の更新は B<msync>(2)  または B<munmap>()  が呼ばれ"
5251 "るまで行われないこともある。"
5252
5253 #. type: TP
5254 #: build/C/man2/mmap.2:128
5255 #, no-wrap
5256 msgid "B<MAP_PRIVATE>"
5257 msgstr "B<MAP_PRIVATE>"
5258
5259 #. type: Plain text
5260 #: build/C/man2/mmap.2:137
5261 msgid ""
5262 "Create a private copy-on-write mapping.  Updates to the mapping are not "
5263 "visible to other processes mapping the same file, and are not carried "
5264 "through to the underlying file.  It is unspecified whether changes made to "
5265 "the file after the B<mmap>()  call are visible in the mapped region."
5266 msgstr ""
5267 "プライベートな copy-on-write (書き込み時コピー) マップを生成する。 マッピング"
5268 "に対する更新は同じファイルをマッピングしている他のプロセス には見えず、更新が"
5269 "マッピング元のファイルを通じて伝えられることもない。 B<mmap>()  の呼び出し後"
5270 "にマッピング元のファイルに対して行われた変更が、 マップ領域に反映されるかどう"
5271 "かは規定されていない。"
5272
5273 #. type: Plain text
5274 #: build/C/man2/mmap.2:139
5275 msgid "Both of these flags are described in POSIX.1-2001."
5276 msgstr "上記の二つのフラグは POSIX.1-2001 で規定されている。"
5277
5278 #. type: Plain text
5279 #: build/C/man2/mmap.2:142
5280 msgid ""
5281 "In addition, zero or more of the following values can be ORed in I<flags>:"
5282 msgstr ""
5283 "さらに、以下の値のうち 0 個以上をビット毎の論理和 (OR) で I<flags> に指定する"
5284 "ことができる。"
5285
5286 #. type: TP
5287 #: build/C/man2/mmap.2:142
5288 #, no-wrap
5289 msgid "B<MAP_32BIT> (since Linux 2.4.20, 2.6)"
5290 msgstr "B<MAP_32BIT> (Linux 2.4.20, 2.6 以降)"
5291
5292 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
5293 #. type: Plain text
5294 #: build/C/man2/mmap.2:158
5295 msgid ""
5296 "Put the mapping into the first 2 Gigabytes of the process address space.  "
5297 "This flag is supported only on x86-64, for 64-bit programs.  It was added to "
5298 "allow thread stacks to be allocated somewhere in the first 2GB of memory, so "
5299 "as to improve context-switch performance on some early 64-bit processors.  "
5300 "Modern x86-64 processors no longer have this performance problem, so use of "
5301 "this flag is not required on those systems.  The B<MAP_32BIT> flag is "
5302 "ignored when B<MAP_FIXED> is set."
5303 msgstr ""
5304 "マッピングをプロセスのアドレス空間の先頭 2 ギガバイト以内に配置する。 このフ"
5305 "ラグがサポートされているのは x86-64 アーキテクチャ上の 64 ビットプログラムの"
5306 "みである。 このフラグが追加されたのは、スレッドのスタックをメモリの先頭 2GB "
5307 "以内の どこかに割り当てることで、初期のいくつかの 64 ビットプロセッサにおけ"
5308 "る コンテキストスイッチの性能問題を改善するためである。 最近の x86-64 プロ"
5309 "セッサではこの性能問題はもはや存在せず、 そのようなシステムではこのフラグを使"
5310 "用する必要はない。 B<MAP_FIXED> がセットされている場合は、 B<MAP_32BIT> フラ"
5311 "グは無視される。"
5312
5313 #. type: TP
5314 #: build/C/man2/mmap.2:158
5315 #, no-wrap
5316 msgid "B<MAP_ANON>"
5317 msgstr "B<MAP_ANON>"
5318
5319 #. type: Plain text
5320 #: build/C/man2/mmap.2:163
5321 msgid "Synonym for B<MAP_ANONYMOUS>.  Deprecated."
5322 msgstr "B<MAP_ANONYMOUS> の同義語。非推奨。"
5323
5324 #. type: TP
5325 #: build/C/man2/mmap.2:163
5326 #, no-wrap
5327 msgid "B<MAP_ANONYMOUS>"
5328 msgstr "B<MAP_ANONYMOUS>"
5329
5330 #. type: Plain text
5331 #: build/C/man2/mmap.2:185
5332 msgid ""
5333 "The mapping is not backed by any file; its contents are initialized to "
5334 "zero.  The I<fd> and I<offset> arguments are ignored; however, some "
5335 "implementations require I<fd> to be -1 if B<MAP_ANONYMOUS> (or B<MAP_ANON>)  "
5336 "is specified, and portable applications should ensure this.  The use of "
5337 "B<MAP_ANONYMOUS> in conjunction with B<MAP_SHARED> is supported on Linux "
5338 "only since kernel 2.4."
5339 msgstr ""
5340 "マッピングはどのファイルとも関連付けされない。 マッピングの内容は 0 で初期化"
5341 "される。 引き数 I<fd> と I<offset> は無視される。 ただし、実装によっては "
5342 "B<MAP_ANONYMOUS> (もしくは B<MAP_ANON>)  が指定された場合、 I<fd> を -1 にす"
5343 "る必要があり、 移植性が必要なアプリケーションでは必ず I<fd> を -1 にすべきで"
5344 "ある。 B<MAP_ANONYMOUS> と B<MAP_SHARED> を組み合わせての利用は カーネル 2.4 "
5345 "以降の Linux でのみサポートされている。"
5346
5347 #. type: TP
5348 #: build/C/man2/mmap.2:185
5349 #, no-wrap
5350 msgid "B<MAP_DENYWRITE>"
5351 msgstr "B<MAP_DENYWRITE>"
5352
5353 #.  Introduced in 1.1.36, removed in 1.3.24.
5354 #. type: Plain text
5355 #: build/C/man2/mmap.2:193
5356 msgid ""
5357 "This flag is ignored.  (Long ago, it signaled that attempts to write to the "
5358 "underlying file should fail with B<ETXTBUSY>.  But this was a source of "
5359 "denial-of-service attacks.)"
5360 msgstr ""
5361 "このフラグは無視される (ずっと前は、マップ元のファイルへの書き込みを行おうと"
5362 "すると、エラー B<ETXTBUSY> で失敗するようにシグナルが設定されていたが、これ"
5363 "は denial-of-service (サービス拒否) 攻撃の原因となった)。"
5364
5365 #. type: TP
5366 #: build/C/man2/mmap.2:193
5367 #, no-wrap
5368 msgid "B<MAP_EXECUTABLE>"
5369 msgstr "B<MAP_EXECUTABLE>"
5370
5371 #.  Introduced in 1.1.38, removed in 1.3.24. Flag tested in proc_follow_link.
5372 #.  (Long ago, it signaled that the underlying file is an executable.
5373 #.  However, that information was not really used anywhere.)
5374 #.  Linus talked about DOS related to MAP_EXECUTABLE, but he was thinking of
5375 #.  MAP_DENYWRITE?
5376 #. type: Plain text
5377 #: build/C/man2/mmap.2:201
5378 msgid "This flag is ignored."
5379 msgstr "このフラグは無視される。"
5380
5381 #. type: TP
5382 #: build/C/man2/mmap.2:201
5383 #, no-wrap
5384 msgid "B<MAP_FILE>"
5385 msgstr "B<MAP_FILE>"
5386
5387 #.  On some systems, this was required as the opposite of
5388 #.  MAP_ANONYMOUS -- mtk, 1 May 2007
5389 #. type: Plain text
5390 #: build/C/man2/mmap.2:207
5391 msgid "Compatibility flag.  Ignored."
5392 msgstr "互換性のためのフラグ。無視される。"
5393
5394 #. type: TP
5395 #: build/C/man2/mmap.2:207
5396 #, no-wrap
5397 msgid "B<MAP_FIXED>"
5398 msgstr "B<MAP_FIXED>"
5399
5400 #. type: Plain text
5401 #: build/C/man2/mmap.2:225
5402 msgid ""
5403 "Don't interpret I<addr> as a hint: place the mapping at exactly that "
5404 "address.  I<addr> must be a multiple of the page size.  If the memory region "
5405 "specified by I<addr> and I<len> overlaps pages of any existing mapping(s), "
5406 "then the overlapped part of the existing mapping(s) will be discarded.  If "
5407 "the specified address cannot be used, B<mmap>()  will fail.  Because "
5408 "requiring a fixed address for a mapping is less portable, the use of this "
5409 "option is discouraged."
5410 msgstr ""
5411 "I<addr> をアドレスのヒントとして使用するのではなく、 I<addr> で指定されたアド"
5412 "レスをそのまま使用してマッピングを配置する。 I<addr> はページサイズの倍数でな"
5413 "ければならない。 I<addr> と I<len> で指定されたメモリ領域が既存のマッピングの"
5414 "ページと重なる場合、 既存のマッピングの重なった部分は捨てられる。 もし指定さ"
5415 "れたアドレスが使用できない場合、 B<mmap>()  は失敗する。 マッピングに対して固"
5416 "定アドレスを要求するのは移植性の面で劣るので、 このオプションは使用しないこと"
5417 "を推奨する。"
5418
5419 #. type: TP
5420 #: build/C/man2/mmap.2:225
5421 #, no-wrap
5422 msgid "B<MAP_GROWSDOWN>"
5423 msgstr "B<MAP_GROWSDOWN>"
5424
5425 #. type: Plain text
5426 #: build/C/man2/mmap.2:230
5427 msgid ""
5428 "Used for stacks.  Indicates to the kernel virtual memory system that the "
5429 "mapping should extend downward in memory."
5430 msgstr ""
5431 "スタック用に使用される。マッピングをメモリ内で逆向きに行うことを カーネル仮想"
5432 "メモリシステムに指示する。 (訳注:マッピングは通常はメモリ・アドレスが増加す"
5433 "る向きに行うが、 このオプションを指定すると逆向きにマッピングを行う)"
5434
5435 #. type: TP
5436 #: build/C/man2/mmap.2:230
5437 #, no-wrap
5438 msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
5439 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
5440
5441 #. type: Plain text
5442 #: build/C/man2/mmap.2:236
5443 msgid ""
5444 "Allocate the mapping using \"huge pages.\" See the Linux kernel source file "
5445 "I<Documentation/vm/hugetlbpage.txt> for further information."
5446 msgstr ""
5447 "\"huge page\" を使ってマッピングを割り当てる。詳しい情報は、Linux カーネル"
5448 "ソースの I<Documentation/vm/hugetlbpage.txt> を参照。"
5449
5450 #. type: TP
5451 #: build/C/man2/mmap.2:236
5452 #, no-wrap
5453 msgid "B<MAP_LOCKED> (since Linux 2.5.37)"
5454 msgstr "B<MAP_LOCKED> (Linux 2.5.37 以降)"
5455
5456 #.  If set, the mapped pages will not be swapped out.
5457 #. type: Plain text
5458 #: build/C/man2/mmap.2:242
5459 msgid ""
5460 "Lock the pages of the mapped region into memory in the manner of B<mlock>"
5461 "(2).  This flag is ignored in older kernels."
5462 msgstr ""
5463 "マップされた領域のページを B<mlock>(2)  の方法でメモリ内にロックする。 それ以"
5464 "前のカーネルでは、このフラグは無視される。"
5465
5466 #. type: TP
5467 #: build/C/man2/mmap.2:242
5468 #, no-wrap
5469 msgid "B<MAP_NONBLOCK> (since Linux 2.5.46)"
5470 msgstr "B<MAP_NONBLOCK> (Linux 2.5.46 以降)"
5471
5472 #. type: Plain text
5473 #: build/C/man2/mmap.2:257
5474 msgid ""
5475 "Only meaningful in conjunction with B<MAP_POPULATE>.  Don't perform read-"
5476 "ahead: create page tables entries only for pages that are already present in "
5477 "RAM.  Since Linux 2.6.23, this flag causes B<MAP_POPULATE> to do nothing.  "
5478 "One day the combination of B<MAP_POPULATE> and B<MAP_NONBLOCK> may be "
5479 "reimplemented."
5480 msgstr ""
5481 "B<MAP_POPULATE> と組み合わせた場合のみ意味を持つ。 read-ahead (前もって読み込"
5482 "むこと) を実行しない。 単に、すでに RAM 上に存在するページに対してのみページ"
5483 "テーブルエントリを作成する。 Linux 2.6.23 以降では、このフラグは "
5484 "B<MAP_POPULATE> に何の影響も与えない。 いつか B<MAP_POPULATE> と "
5485 "B<MAP_NONBLOCK> を組み合わせた場合の動作は実装し直されるかもしれない。"
5486
5487 #. type: TP
5488 #: build/C/man2/mmap.2:257
5489 #, no-wrap
5490 msgid "B<MAP_NORESERVE>"
5491 msgstr "B<MAP_NORESERVE>"
5492
5493 #. type: Plain text
5494 #: build/C/man2/mmap.2:272
5495 msgid ""
5496 "Do not reserve swap space for this mapping.  When swap space is reserved, "
5497 "one has the guarantee that it is possible to modify the mapping.  When swap "
5498 "space is not reserved one might get B<SIGSEGV> upon a write if no physical "
5499 "memory is available.  See also the discussion of the file I</proc/sys/vm/"
5500 "overcommit_memory> in B<proc>(5).  In kernels before 2.6, this flag had "
5501 "effect only for private writable mappings."
5502 msgstr ""
5503 "このマッピングに対するスワップ空間の予約を行わない。 スワップ空間を予約した場"
5504 "合は、このマッピングの変更が必ず可能なことが 保証される。予約を行わなかった場"
5505 "合、物理メモリに空きがないと 書き込み時に B<SIGSEGV> エラーを受け取ることがあ"
5506 "る。 B<proc>(5)  の I</proc/sys/vm/overcommit_memory> ファイルについての議論"
5507 "も参照。 バージョン 2.6 より前のカーネルでは、このフラグは書き込み可能な プラ"
5508 "イベート・マッピングについてのみ効果があった。"
5509
5510 #. type: TP
5511 #: build/C/man2/mmap.2:272
5512 #, no-wrap
5513 msgid "B<MAP_POPULATE> (since Linux 2.5.46)"
5514 msgstr "B<MAP_POPULATE> (Linux 2.5.46 以降)"
5515
5516 #. type: Plain text
5517 #: build/C/man2/mmap.2:279
5518 msgid ""
5519 "Populate (prefault) page tables for a mapping.  For a file mapping, this "
5520 "causes read-ahead on the file.  Later accesses to the mapping will not be "
5521 "blocked by page faults.  B<MAP_POPULATE> is supported for private mappings "
5522 "only since Linux 2.6.23."
5523 msgstr ""
5524 "マッピング用のページテーブルを配置 (populate) する ファイルマッピングの場合に"
5525 "は、これによりファイルが先読み (read-ahead)  が行われる。この以後は、マッピン"
5526 "グに対するアクセスがページフォールトで ブロックされることがなくなる。 Linux "
5527 "2.6.23 以降でのみプライベート・マッピングについて B<MAP_POPULATE> がサポート"
5528 "されている。"
5529
5530 #. type: TP
5531 #: build/C/man2/mmap.2:279
5532 #, no-wrap
5533 msgid "B<MAP_STACK> (since Linux 2.6.27)"
5534 msgstr "B<MAP_STACK> (Linux 2.6.27 以降)"
5535
5536 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
5537 #.  commit cd98a04a59e2f94fa64d5bf1e26498d27427d5e7
5538 #.  http://thread.gmane.org/gmane.linux.kernel/720412
5539 #.  "pthread_create() slow for many threads; also time to revisit 64b
5540 #.   context switch optimization?"
5541 #. type: Plain text
5542 #: build/C/man2/mmap.2:292
5543 msgid ""
5544 "Allocate the mapping at an address suitable for a process or thread stack.  "
5545 "This flag is currently a no-op, but is used in the glibc threading "
5546 "implementation so that if some architectures require special treatment for "
5547 "stack allocations, support can later be transparently implemented for glibc."
5548 msgstr ""
5549 "プロセスやスレッドのスタックに適したアドレスにマッピングを割り当てる。 現在の"
5550 "ところ、このフラグは何もしないが、 glibc のスレッド実装では使用されている。 "
5551 "これは、いくつかのアーキテクチャではスタックの割り当てに関して特別な扱い が必"
5552 "要な場合に、glibc にそのサポートを後で透過的に実装できるようにする ためであ"
5553 "る。"
5554
5555 #. type: TP
5556 #: build/C/man2/mmap.2:292
5557 #, no-wrap
5558 msgid "B<MAP_UNINITIALIZED> (since Linux 2.6.33)"
5559 msgstr "B<MAP_UNINITIALIZED> (Linux 2.6.33 以降)"
5560
5561 #. type: Plain text
5562 #: build/C/man2/mmap.2:302
5563 msgid ""
5564 "Don't clear anonymous pages.  This flag is intended to improve performance "
5565 "on embedded devices.  This flag is honored only if the kernel was configured "
5566 "with the B<CONFIG_MMAP_ALLOW_UNINITIALIZED> option.  Because of the security "
5567 "implications, that option is normally enabled only on embedded devices (i."
5568 "e., devices where one has complete control of the contents of user memory)."
5569 msgstr ""
5570 "無名ページ (anonymous page) のクリアを行わない。このフラグは組み込みデバイ"
5571 "ス\n"
5572 "での性能向上を目的に作られてものである。カーネルの設定で\n"
5573 "B<CONFIG_MMAP_ALLOW_UNINITIALIZED> オプションが有効になっている場合のみ、\n"
5574 "このフラグは効果を持つ。\n"
5575 "セキュリティ面の考慮から、このオプションは通常組み込みデバイス (すなわち、\n"
5576 "ユーザメモリの内容を完全に制御化におけるデバイス) においてのみ有効にされる。"
5577
5578 #. type: Plain text
5579 #: build/C/man2/mmap.2:310
5580 msgid ""
5581 "Of the above flags, only B<MAP_FIXED> is specified in POSIX.1-2001.  "
5582 "However, most systems also support B<MAP_ANONYMOUS> (or its synonym "
5583 "B<MAP_ANON>)."
5584 msgstr ""
5585 "上記のフラグの中では、 B<MAP_FIXED> だけが POSIX.1-2001 で規定されている。 し"
5586 "かしながら、ほとんどのシステムで B<MAP_ANONYMOUS> (またはその同義語である "
5587 "B<MAP_ANON>)  もサポートされている。"
5588
5589 #. type: Plain text
5590 #: build/C/man2/mmap.2:317
5591 msgid ""
5592 "Some systems document the additional flags B<MAP_AUTOGROW>, "
5593 "B<MAP_AUTORESRV>, B<MAP_COPY>, and B<MAP_LOCAL>."
5594 msgstr ""
5595 "いくつかのシステムでは、上記以外にフラグとして B<MAP_AUTOGROW>, "
5596 "B<MAP_AUTORESRV>, B<MAP_COPY>, B<MAP_LOCAL> が規定されている。"
5597
5598 #. type: Plain text
5599 #: build/C/man2/mmap.2:323
5600 msgid ""
5601 "Memory mapped by B<mmap>()  is preserved across B<fork>(2), with the same "
5602 "attributes."
5603 msgstr ""
5604 "B<mmap>()  によってマップされたメモリの属性は B<fork>(2)  の際に継承される。"
5605
5606 #. type: Plain text
5607 #: build/C/man2/mmap.2:331
5608 msgid ""
5609 "A file is mapped in multiples of the page size.  For a file that is not a "
5610 "multiple of the page size, the remaining memory is zeroed when mapped, and "
5611 "writes to that region are not written out to the file.  The effect of "
5612 "changing the size of the underlying file of a mapping on the pages that "
5613 "correspond to added or removed regions of the file is unspecified."
5614 msgstr ""
5615 "ファイルはページサイズの整数倍の領域にマップされる。サイズがページサイズの 整"
5616 "数倍でないファイルの場合、マップ時に残りの領域は 0 で埋められ、この領域へ 書"
5617 "きこみを行ってもファイルに書き出されることはない。マッピングを行った元 ファイ"
5618 "ルのサイズを変更した場合、元ファイルの追加されたり削除された領域に対応 する"
5619 "マップされたページに対してどのような影響があるかは規定されていない。"
5620
5621 #. type: SS
5622 #: build/C/man2/mmap.2:331
5623 #, no-wrap
5624 msgid "munmap()"
5625 msgstr "munmap()"
5626
5627 #. type: Plain text
5628 #: build/C/man2/mmap.2:341
5629 msgid ""
5630 "The B<munmap>()  system call deletes the mappings for the specified address "
5631 "range, and causes further references to addresses within the range to "
5632 "generate invalid memory references.  The region is also automatically "
5633 "unmapped when the process is terminated.  On the other hand, closing the "
5634 "file descriptor does not unmap the region."
5635 msgstr ""
5636 "システムコール B<munmap>()  は指定されたアドレス範囲のマップを消去し、 これ以"
5637 "降のその範囲内へのメモリ参照は不正となる。 この領域は、プロセスが終了したとき"
5638 "にも自動的にアンマップされる。 一方、ファイル記述子をクローズしても、この領域"
5639 "はアンマップされない。"
5640
5641 #. type: Plain text
5642 #: build/C/man2/mmap.2:351
5643 msgid ""
5644 "The address I<addr> must be a multiple of the page size.  All pages "
5645 "containing a part of the indicated range are unmapped, and subsequent "
5646 "references to these pages will generate B<SIGSEGV>.  It is not an error if "
5647 "the indicated range does not contain any mapped pages."
5648 msgstr ""
5649 "I<addr> アドレスはページサイズの整数倍でなければならない。指定された範囲の一"
5650 "部分を 含む全てのページはアンマップされ、これ以降にこれらのページへの参照があ"
5651 "ると B<SIGSEGV> が発生する。 指定した範囲内にマップされたページが一つも含まれ"
5652 "ていない場合でも エラーにならない。"
5653
5654 #. type: SS
5655 #: build/C/man2/mmap.2:351
5656 #, no-wrap
5657 msgid "Timestamps changes for file-backed mappings"
5658 msgstr "ファイルと関連付けられたマッピングに対するタイムスタンプの更新"
5659
5660 #. type: Plain text
5661 #: build/C/man2/mmap.2:358
5662 msgid ""
5663 "For file-backed mappings, the I<st_atime> field for the mapped file may be "
5664 "updated at any time between the B<mmap>()  and the corresponding unmapping; "
5665 "the first reference to a mapped page will update the field if it has not "
5666 "been already."
5667 msgstr ""
5668 "ファイルと関連付けられたマッピングの場合、マッピングされたファイルの "
5669 "I<st_atime> フィールドは、 B<mmap>()  されてからアンマップ (unmap) されるまで"
5670 "の間に更新されることがある。 それまでに更新が行われていなければ、マップされた"
5671 "ページへの最初の参照があった 際に更新される。"
5672
5673 #. type: Plain text
5674 #: build/C/man2/mmap.2:375
5675 msgid ""
5676 "The I<st_ctime> and I<st_mtime> field for a file mapped with B<PROT_WRITE> "
5677 "and B<MAP_SHARED> will be updated after a write to the mapped region, and "
5678 "before a subsequent B<msync>(2)  with the B<MS_SYNC> or B<MS_ASYNC> flag, if "
5679 "one occurs."
5680 msgstr ""
5681 "B<PROT_WRITE> と B<MAP_SHARED> の両方を指定してマップされたファイルの場合、書"
5682 "き込みがあると、 I<st_ctime> と I<st_mtime> の両フィールドは、マップされた領"
5683 "域への書き込みより後で、 B<MS_SYNC> または B<MS_ASYNC> フラグを指定して "
5684 "B<msync>(2)  が呼ばれる前までに更新される。"
5685
5686 #. type: Plain text
5687 #: build/C/man2/mmap.2:392
5688 msgid ""
5689 "On success, B<mmap>()  returns a pointer to the mapped area.  On error, the "
5690 "value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>)  is returned, and I<errno> "
5691 "is set appropriately.  On success, B<munmap>()  returns 0, on failure -1, "
5692 "and I<errno> is set (probably to B<EINVAL>)."
5693 msgstr ""
5694 "B<mmap>()  は成功するとマップされた領域へのポインタを返す。 失敗すると値 "
5695 "B<MAP_FAILED> (つまり I<(void\\ *)\\ -1>)  を返し、 I<errno> がエラーの内容に"
5696 "したがってセットされる。 B<munmap>()  は成功すると 0 を返す。失敗すると -1 を"
5697 "返し、 I<errno> がセットされる (多くの場合 B<EINVAL> になるだろう)。"
5698
5699 #. type: TP
5700 #: build/C/man2/mmap.2:393 build/C/man2/mprotect.2:86
5701 #: build/C/man3/shm_open.3:187 build/C/man3/shm_open.3:192
5702 #: build/C/man2/shmctl.2:306 build/C/man2/shmget.2:189
5703 #: build/C/man2/shmop.2:191
5704 #, no-wrap
5705 msgid "B<EACCES>"
5706 msgstr "B<EACCES>"
5707
5708 #. type: Plain text
5709 #: build/C/man2/mmap.2:411
5710 msgid ""
5711 "A file descriptor refers to a non-regular file.  Or a file mapping was "
5712 "requested, but I<fd> is not open for reading.  Or B<MAP_SHARED> was "
5713 "requested and B<PROT_WRITE> is set, but I<fd> is not open in read/write "
5714 "(B<O_RDWR>)  mode.  Or B<PROT_WRITE> is set, but the file is append-only."
5715 msgstr ""
5716 "以下のいずれかの場合。 ファイル記述子の参照先が通常のファイルではない (non-"
5717 "regular file) 。 ファイルマッピングを要求したが I<fd> は読み込み用にオープン"
5718 "されていない。 B<MAP_SHARED> を要求して B<PROT_WRITE> をセットしたが I<fd> は"
5719 "読み書きモード (B<O_RDWR>)  でオープンされていない、 B<PROT_WRITE> をセットし"
5720 "たが、ファイルは追加 (append) 専用である。"
5721
5722 #. type: Plain text
5723 #: build/C/man2/mmap.2:415
5724 msgid ""
5725 "The file has been locked, or too much memory has been locked (see "
5726 "B<setrlimit>(2))."
5727 msgstr ""
5728 "ファイルがロックされている。またはロックされているメモリが多すぎる "
5729 "(B<setrlimit>(2)  を参照)。"
5730
5731 #. type: Plain text
5732 #: build/C/man2/mmap.2:421
5733 msgid ""
5734 "I<fd> is not a valid file descriptor (and B<MAP_ANONYMOUS> was not set)."
5735 msgstr ""
5736 "I<fd> が有効なファイル記述子 (file descriptor) ではない (かつ "
5737 "B<MAP_ANONYMOUS> がセットされていない)。"
5738
5739 #. type: Plain text
5740 #: build/C/man2/mmap.2:429
5741 msgid ""
5742 "We don't like I<addr>, I<length>, or I<offset> (e.g., they are too large, or "
5743 "not aligned on a page boundary)."
5744 msgstr ""
5745 "I<addr> か I<length> か I<offset> が適切でない (例えば、大きすぎるとか、ペー"
5746 "ジ境界にアラインメントされていない)。"
5747
5748 #. type: Plain text
5749 #: build/C/man2/mmap.2:434
5750 msgid "(since Linux 2.6.12)  I<length> was 0."
5751 msgstr "(Linux 2.6.12 以降)  I<length> が 0 であった。"
5752
5753 #. type: Plain text
5754 #: build/C/man2/mmap.2:442
5755 msgid ""
5756 "I<flags> contained neither B<MAP_PRIVATE> or B<MAP_SHARED>, or contained "
5757 "both of these values."
5758 msgstr ""
5759 "I<flags> に B<MAP_PRIVATE> と B<MAP_SHARED> のどちらも含まれていなかった、も"
5760 "しくは その両方が含まれていた。"
5761
5762 #. type: TP
5763 #: build/C/man2/mmap.2:442 build/C/man3/shm_open.3:229
5764 #: build/C/man2/shmget.2:205
5765 #, no-wrap
5766 msgid "B<ENFILE>"
5767 msgstr "B<ENFILE>"
5768
5769 #.  [2.6.7] shmem_zero_setup()-->shmem_file_setup()-->get_empty_filp()
5770 #. type: Plain text
5771 #: build/C/man2/mmap.2:450 build/C/man2/shmget.2:209
5772 msgid "The system limit on the total number of open files has been reached."
5773 msgstr "システム全体でオープンされているファイルの総数が上限に達した。"
5774
5775 #. type: Plain text
5776 #: build/C/man2/mmap.2:454
5777 msgid ""
5778 "The underlying filesystem of the specified file does not support memory "
5779 "mapping."
5780 msgstr ""
5781 "指定されたファイルが置かれているファイルシステムがメモリマッピングをサポート "
5782 "していない。"
5783
5784 #. type: Plain text
5785 #: build/C/man2/mmap.2:458
5786 msgid ""
5787 "No memory is available, or the process's maximum number of mappings would "
5788 "have been exceeded."
5789 msgstr ""
5790 "メモリに空きがない、または処理中のプロセスのマッピング数が最大数を超過した。"
5791
5792 #.  (Since 2.4.25 / 2.6.0.)
5793 #. type: Plain text
5794 #: build/C/man2/mmap.2:467
5795 msgid ""
5796 "The I<prot> argument asks for B<PROT_EXEC> but the mapped area belongs to a "
5797 "file on a filesystem that was mounted no-exec."
5798 msgstr ""
5799 "I<prot> 引き数は B<PROT_EXEC> を行うように指定されているが、 no-exec でマウン"
5800 "トされたファイルシステム上のファイルに マップ領域が対応している。"
5801
5802 #. type: Plain text
5803 #: build/C/man2/mmap.2:473
5804 msgid ""
5805 "B<MAP_DENYWRITE> was set but the object specified by I<fd> is open for "
5806 "writing."
5807 msgstr ""
5808 "B<MAP_DENYWRITE> がセットされているが I<fd> で指定されているオブジェクトは書"
5809 "き込み用に開かれている。"
5810
5811 #. type: TP
5812 #: build/C/man2/mmap.2:473 build/C/man2/shmctl.2:348
5813 #, no-wrap
5814 msgid "B<EOVERFLOW>"
5815 msgstr "B<EOVERFLOW>"
5816
5817 #. type: Plain text
5818 #: build/C/man2/mmap.2:485
5819 msgid ""
5820 "On 32-bit architecture together with the large file extension (i.e., using "
5821 "64-bit I<off_t>): the number of pages used for I<length> plus number of "
5822 "pages used for I<offset> would overflow I<unsigned long> (32 bits)."
5823 msgstr ""
5824 "32 ビットアーキテクチャで large file 拡張を使っている場合 (つまり 64 ビット"
5825 "の I<off_t> を使う場合)、 I<length> で使うページ数と I<offset> で使うページ数"
5826 "を足した値は I<unsigned long> (32 ビット) を超えてしまう (オーバーフローして"
5827 "しまう) 場合がある。"
5828
5829 #. type: Plain text
5830 #: build/C/man2/mmap.2:487
5831 msgid "Use of a mapped region can result in these signals:"
5832 msgstr "マップ領域を利用する際に、以下のシグナルが発生することがある:"
5833
5834 #. type: TP
5835 #: build/C/man2/mmap.2:487
5836 #, no-wrap
5837 msgid "B<SIGSEGV>"
5838 msgstr "B<SIGSEGV>"
5839
5840 #. type: Plain text
5841 #: build/C/man2/mmap.2:490
5842 msgid "Attempted write into a region mapped as read-only."
5843 msgstr "読み込み専用で mmap された領域へ書き込みを行おうとした。"
5844
5845 #. type: TP
5846 #: build/C/man2/mmap.2:490
5847 #, no-wrap
5848 msgid "B<SIGBUS>"
5849 msgstr "B<SIGBUS>"
5850
5851 #. type: Plain text
5852 #: build/C/man2/mmap.2:495
5853 msgid ""
5854 "Attempted access to a portion of the buffer that does not correspond to the "
5855 "file (for example, beyond the end of the file, including the case where "
5856 "another process has truncated the file)."
5857 msgstr ""
5858 "バッファのうち、ファイルに関連づけられていない部分 (例えばファイル末尾を越え"
5859 "た部分など。これには 他のプロセスがファイルを切り詰めた場合なども含まれる)  "
5860 "にアクセスしようとした。"
5861
5862 #.  SVr4 documents additional error codes ENXIO and ENODEV.
5863 #.  SUSv2 documents additional error codes EMFILE and EOVERFLOW.
5864 #. type: Plain text
5865 #: build/C/man2/mmap.2:499
5866 msgid "SVr4, 4.4BSD, POSIX.1-2001."
5867 msgstr "SVr4, 4.4BSD, POSIX.1-2001."
5868
5869 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
5870 #.  -1: unavailable, 0: ask using sysconf().
5871 #.  glibc defines it to 1.
5872 #. type: Plain text
5873 #: build/C/man2/mmap.2:513
5874 msgid ""
5875 "On POSIX systems on which B<mmap>(), B<msync>(2)  and B<munmap>()  are "
5876 "available, B<_POSIX_MAPPED_FILES> is defined in I<E<lt>unistd.hE<gt>> to a "
5877 "value greater than 0.  (See also B<sysconf>(3).)"
5878 msgstr ""
5879 "B<mmap>(), B<msync>(2)  B<munmap>()  が利用可能な POSIX システムでは、 "
5880 "B<_POSIX_MAPPED_FILES> は E<lt>unistd.hE<gt> で 0 より大きな値に定義される "
5881 "(B<sysconf>(3)  も参照のこと)。"
5882
5883 #.  Since around glibc 2.1/2.2, depending on the platform.
5884 #. type: Plain text
5885 #: build/C/man2/mmap.2:528
5886 msgid ""
5887 "This page describes the interface provided by the glibc B<mmap>()  wrapper "
5888 "function.  Originally, this function invoked a system call of the same "
5889 "name.  Since kernel 2.4, that system call has been superseded by B<mmap2>"
5890 "(2), and nowadays the glibc B<mmap>()  wrapper function invokes B<mmap2>(2)  "
5891 "with a suitably adjusted value for I<offset>."
5892 msgstr ""
5893 "このページでは glibc の B<mmap>() のラッパー関数が提供するインターフェース"
5894 "に\n"
5895 "ついて説明している。元々は、この関数は同じ名前のシステムコールを起動してい"
5896 "た。\n"
5897 "カーネル 2.4 以降、このシステムコールは B<mmap2>(2) に取って代わられ、現在\n"
5898 "では、 glibc の B<mmap>() のラッパー関数は I<offset> を適切に調整してから\n"
5899 "B<mmap2>(2) を起動する。"
5900
5901 #. type: Plain text
5902 #: build/C/man2/mmap.2:541
5903 msgid ""
5904 "On some hardware architectures (e.g., i386), B<PROT_WRITE> implies "
5905 "B<PROT_READ>.  It is architecture dependent whether B<PROT_READ> implies "
5906 "B<PROT_EXEC> or not.  Portable programs should always set B<PROT_EXEC> if "
5907 "they intend to execute code in the new mapping."
5908 msgstr ""
5909 "(i386 などの) いくつかのアーキテクチャでは、 B<PROT_WRITE> をセットすると、暗"
5910 "黙のうちに B<PROT_READ> がセットされる。 B<PROT_READ> をセットした際に暗黙の"
5911 "うちに B<PROT_EXEC> がセットされるかどうかは、アーキテクチャ依存である。 移植"
5912 "性を考慮したプログラムでは、 新規にマップした領域でコードを実行したい場合は、"
5913 "常に B<PROT_EXEC> をセットすべきである。"
5914
5915 #. type: Plain text
5916 #: build/C/man2/mmap.2:556
5917 msgid ""
5918 "The portable way to create a mapping is to specify I<addr> as 0 (NULL), and "
5919 "omit B<MAP_FIXED> from I<flags>.  In this case, the system chooses the "
5920 "address for the mapping; the address is chosen so as not to conflict with "
5921 "any existing mapping, and will not be 0.  If the B<MAP_FIXED> flag is "
5922 "specified, and I<addr> is 0 (NULL), then the mapped address will be 0 (NULL)."
5923 msgstr ""
5924 "マッピングを作成する移植性のある方法は、 I<addr> に 0 (NULL) を指定し、 "
5925 "I<flags> から B<MAP_FIXED> を外すことである。 この場合、システムがマッピング"
5926 "用のアドレスの選択を行う。 アドレスは既存のマッピングと衝突しないように、 か"
5927 "つ 0 にならないように選択される。 B<MAP_FIXED> フラグが指定され、かつ "
5928 "I<addr> が 0 (NULL)  の場合には、マップされるアドレスが 0 (NULL) になる。"
5929
5930 #. type: Plain text
5931 #: build/C/man2/mmap.2:585
5932 msgid ""
5933 "Certain I<flags> constants are defined only if either B<_BSD_SOURCE> or "
5934 "B<_SVID_SOURCE> is defined.  (Requiring B<_GNU_SOURCE> also suffices, and "
5935 "requiring that macro specifically would have been more logical, since these "
5936 "flags are all Linux-specific.)  The relevant flags are: B<MAP_32BIT>, "
5937 "B<MAP_ANONYMOUS> (and the synonym B<MAP_ANON>), B<MAP_DENYWRITE>, "
5938 "B<MAP_EXECUTABLE>, B<MAP_FILE>, B<MAP_GROWSDOWN>, B<MAP_HUGETLB>, "
5939 "B<MAP_LOCKED>, B<MAP_NONBLOCK>, B<MAP_NORESERVE>, B<MAP_POPULATE>, and "
5940 "B<MAP_STACK>."
5941 msgstr ""
5942 "特定の I<flags> 定数は B<_BSD_SOURCE> か B<_SVID_SOURCE> のいずれかが定義され"
5943 "た場合にのみ定義される。 (B<_GNU_SOURCE> も定義されている必要がある。これらの"
5944 "フラグはすべて Linux 固有のものなので、 特に B<_GNU_SOURCE> を必要とする点は"
5945 "もっと論理的に決められるべきであった。) 関係するフラグは B<MAP_32BIT>, "
5946 "B<MAP_ANONYMOUS> (とその同義語の B<MAP_ANON>), B<MAP_DENYWRITE>, "
5947 "B<MAP_EXECUTABLE>, B<MAP_FILE>, B<MAP_GROWSDOWN>, B<MAP_HUGETLB>, "
5948 "B<MAP_LOCKED>, B<MAP_NONBLOCK>, B<MAP_NORESERVE>, B<MAP_POPULATE>, "
5949 "B<MAP_STACK> である。"
5950
5951 #. type: Plain text
5952 #: build/C/man2/mmap.2:590
5953 msgid ""
5954 "On Linux there are no guarantees like those suggested above under "
5955 "B<MAP_NORESERVE>.  By default, any process can be killed at any moment when "
5956 "the system runs out of memory."
5957 msgstr ""
5958 "Linux においては、上記の B<MAP_NORESERVE> で述べられているような保証はない。 "
5959 "デフォルトでは、システムがメモリを使い切った場合には、 どのプロセスがいつ強制"
5960 "終了されるか分からないからである。"
5961
5962 #. type: Plain text
5963 #: build/C/man2/mmap.2:597
5964 msgid ""
5965 "In kernels before 2.6.7, the B<MAP_POPULATE> flag has effect only if I<prot> "
5966 "is specified as B<PROT_NONE>."
5967 msgstr ""
5968 "2.6.7 より前のカーネルでは、 I<prot> に B<PROT_NONE> が指定された場合にの"
5969 "み、 B<MAP_POPULATE> フラグが効力を持つ。"
5970
5971 #. type: Plain text
5972 #: build/C/man2/mmap.2:612
5973 msgid ""
5974 "SUSv3 specifies that B<mmap>()  should fail if I<length> is 0.  However, in "
5975 "kernels before 2.6.12, B<mmap>()  succeeded in this case: no mapping was "
5976 "created and the call returned I<addr>.  Since kernel 2.6.12, B<mmap>()  "
5977 "fails with the error B<EINVAL> for this case."
5978 msgstr ""
5979 "SUSv3 では、 I<length> が 0 の場合、 B<mmap>()  は失敗すると規定されている。"
5980 "しかしながら、2.6.12 より前のカーネルでは、 この場合に B<mmap>()  は成功して"
5981 "いた (マッピングは作成されず、 I<addr> が返されていた)。 カーネル 2.6.12 以降"
5982 "では、 B<mmap>()  はエラー B<EINVAL> で失敗する。"
5983
5984 #. type: Plain text
5985 #: build/C/man2/mmap.2:628
5986 msgid ""
5987 "POSIX specifies that the system shall always zero fill any partial page at "
5988 "the end of the object and that system will never write any modification of "
5989 "the object beyond its end.  On Linux, when you write data to such partial "
5990 "page after the end of the object, the data stays in the page cache even "
5991 "after the file is closed and unmapped and even though the data is never "
5992 "written to the file itself, subsequent mappings may see the modified "
5993 "content.  In some cases, this could be fixed by calling B<msync>(2)  before "
5994 "the unmap takes place; however, this doesn't work on tmpfs (for example, "
5995 "when using POSIX shared memory interface documented in B<shm_overview>(7))."
5996 msgstr ""
5997 "POSIX では、 システムはオブジェクト末尾の部分ページを常に 0 で埋め、 末尾より"
5998 "後ろのオブジェクトを決して変更してはならない、と規定している。 Linux では、 "
5999 "オブジェクト末尾より後ろの部分ページにデータを書き込んだ場合、 そのファイルを"
6000 "クローズしてアンマップした後であってもページキャッシュにデータが残り続け、 "
6001 "データがファイル自体に書き込まれていなくても、 それ以降のマッピングで変更され"
6002 "た内容が見える可能性がある。 いくつかの場合では、 アンマップを行う前に "
6003 "B<msync>(2) を呼び出すことで、 この状況を修正することができる。 しかし、 これ"
6004 "は tmpfs では機能しない (例えば、 B<shm_overview>(7) で説明されている POSIX "
6005 "共有メモリインターフェースを使った場合)。"
6006
6007 #. type: Plain text
6008 #: build/C/man2/mmap.2:640
6009 msgid ""
6010 "The following program prints part of the file specified in its first command-"
6011 "line argument to standard output.  The range of bytes to be printed is "
6012 "specified via offset and length values in the second and third command-line "
6013 "arguments.  The program creates a memory mapping of the required pages of "
6014 "the file and then uses B<write>(2)  to output the desired bytes."
6015 msgstr ""
6016 "以下のプログラムは、一番目のコマンドライン引き数で指定された ファイルの一部を"
6017 "標準出力に表示する。 表示する範囲は、二番目、三番目のコマンドライン引き数で渡"
6018 "される オフセットと長さで指定される。 このプログラムは、指定されたファイルの"
6019 "必要なページのメモリ・ マッピングを作成し、 B<write>(2)  を使って所望のバイト"
6020 "を出力する。"
6021
6022 #. type: Plain text
6023 #: build/C/man2/mmap.2:648
6024 #, no-wrap
6025 msgid ""
6026 "#include E<lt>sys/mman.hE<gt>\n"
6027 "#include E<lt>sys/stat.hE<gt>\n"
6028 "#include E<lt>fcntl.hE<gt>\n"
6029 "#include E<lt>stdio.hE<gt>\n"
6030 "#include E<lt>stdlib.hE<gt>\n"
6031 "#include E<lt>unistd.hE<gt>\n"
6032 msgstr ""
6033 "#include E<lt>sys/mman.hE<gt>\n"
6034 "#include E<lt>sys/stat.hE<gt>\n"
6035 "#include E<lt>fcntl.hE<gt>\n"
6036 "#include E<lt>stdio.hE<gt>\n"
6037 "#include E<lt>stdlib.hE<gt>\n"
6038 "#include E<lt>unistd.hE<gt>\n"
6039
6040 #. type: Plain text
6041 #: build/C/man2/mmap.2:651 build/C/man2/mprotect.2:178
6042 #, no-wrap
6043 msgid ""
6044 "#define handle_error(msg) \\e\n"
6045 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
6046 msgstr ""
6047 "#define handle_error(msg) \\e\n"
6048 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
6049
6050 #. type: Plain text
6051 #: build/C/man2/mmap.2:661
6052 #, no-wrap
6053 msgid ""
6054 "int\n"
6055 "main(int argc, char *argv[])\n"
6056 "{\n"
6057 "    char *addr;\n"
6058 "    int fd;\n"
6059 "    struct stat sb;\n"
6060 "    off_t offset, pa_offset;\n"
6061 "    size_t length;\n"
6062 "    ssize_t s;\n"
6063 msgstr ""
6064 "int\n"
6065 "main(int argc, char *argv[])\n"
6066 "{\n"
6067 "    char *addr;\n"
6068 "    int fd;\n"
6069 "    struct stat sb;\n"
6070 "    off_t offset, pa_offset;\n"
6071 "    size_t length;\n"
6072 "    ssize_t s;\n"
6073
6074 #. type: Plain text
6075 #: build/C/man2/mmap.2:666
6076 #, no-wrap
6077 msgid ""
6078 "    if (argc E<lt> 3 || argc E<gt> 4) {\n"
6079 "        fprintf(stderr, \"%s file offset [length]\\en\", argv[0]);\n"
6080 "        exit(EXIT_FAILURE);\n"
6081 "    }\n"
6082 msgstr ""
6083 "    if (argc E<lt> 3 || argc E<gt> 4) {\n"
6084 "        fprintf(stderr, \"%s file offset [length]\\en\", argv[0]);\n"
6085 "        exit(EXIT_FAILURE);\n"
6086 "    }\n"
6087
6088 #. type: Plain text
6089 #: build/C/man2/mmap.2:670
6090 #, no-wrap
6091 msgid ""
6092 "    fd = open(argv[1], O_RDONLY);\n"
6093 "    if (fd == -1)\n"
6094 "        handle_error(\"open\");\n"
6095 msgstr ""
6096 "    fd = open(argv[1], O_RDONLY);\n"
6097 "    if (fd == -1)\n"
6098 "        handle_error(\"open\");\n"
6099
6100 #. type: Plain text
6101 #: build/C/man2/mmap.2:673
6102 #, no-wrap
6103 msgid ""
6104 "    if (fstat(fd, &sb) == -1)           /* To obtain file size */\n"
6105 "        handle_error(\"fstat\");\n"
6106 msgstr ""
6107 "    if (fstat(fd, &sb) == -1)           /* To obtain file size */\n"
6108 "        handle_error(\"fstat\");\n"
6109
6110 #. type: Plain text
6111 #: build/C/man2/mmap.2:677
6112 #, no-wrap
6113 msgid ""
6114 "    offset = atoi(argv[2]);\n"
6115 "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
6116 "        /* offset for mmap() must be page aligned */\n"
6117 msgstr ""
6118 "    offset = atoi(argv[2]);\n"
6119 "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
6120 "        /* offset for mmap() must be page aligned */\n"
6121
6122 #. type: Plain text
6123 #: build/C/man2/mmap.2:682
6124 #, no-wrap
6125 msgid ""
6126 "    if (offset E<gt>= sb.st_size) {\n"
6127 "        fprintf(stderr, \"offset is past end of file\\en\");\n"
6128 "        exit(EXIT_FAILURE);\n"
6129 "    }\n"
6130 msgstr ""
6131 "    if (offset E<gt>= sb.st_size) {\n"
6132 "        fprintf(stderr, \"offset is past end of file\\en\");\n"
6133 "        exit(EXIT_FAILURE);\n"
6134 "    }\n"
6135
6136 #. type: Plain text
6137 #: build/C/man2/mmap.2:688
6138 #, no-wrap
6139 msgid ""
6140 "    if (argc == 4) {\n"
6141 "        length = atoi(argv[3]);\n"
6142 "        if (offset + length E<gt> sb.st_size)\n"
6143 "            length = sb.st_size - offset;\n"
6144 "                /* Can\\(aqt display bytes past end of file */\n"
6145 msgstr ""
6146 "    if (argc == 4) {\n"
6147 "        length = atoi(argv[3]);\n"
6148 "        if (offset + length E<gt> sb.st_size)\n"
6149 "            length = sb.st_size - offset;\n"
6150 "                /* Can\\(aqt display bytes past end of file */\n"
6151
6152 #. type: Plain text
6153 #: build/C/man2/mmap.2:692
6154 #, no-wrap
6155 msgid ""
6156 "    } else {    /* No length arg ==E<gt> display to end of file */\n"
6157 "        length = sb.st_size - offset;\n"
6158 "    }\n"
6159 msgstr ""
6160 "    } else {    /* No length arg ==E<gt> display to end of file */\n"
6161 "        length = sb.st_size - offset;\n"
6162 "    }\n"
6163
6164 #. type: Plain text
6165 #: build/C/man2/mmap.2:697
6166 #, no-wrap
6167 msgid ""
6168 "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
6169 "                MAP_PRIVATE, fd, pa_offset);\n"
6170 "    if (addr == MAP_FAILED)\n"
6171 "        handle_error(\"mmap\");\n"
6172 msgstr ""
6173 "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
6174 "                MAP_PRIVATE, fd, pa_offset);\n"
6175 "    if (addr == MAP_FAILED)\n"
6176 "        handle_error(\"mmap\");\n"
6177
6178 #. type: Plain text
6179 #: build/C/man2/mmap.2:702
6180 #, no-wrap
6181 msgid ""
6182 "    s = write(STDOUT_FILENO, addr + offset - pa_offset, length);\n"
6183 "    if (s != length) {\n"
6184 "        if (s == -1)\n"
6185 "            handle_error(\"write\");\n"
6186 msgstr ""
6187 "    s = write(STDOUT_FILENO, addr + offset - pa_offset, length);\n"
6188 "    if (s != length) {\n"
6189 "        if (s == -1)\n"
6190 "            handle_error(\"write\");\n"
6191
6192 #. type: Plain text
6193 #: build/C/man2/mmap.2:706
6194 #, no-wrap
6195 msgid ""
6196 "        fprintf(stderr, \"partial write\");\n"
6197 "        exit(EXIT_FAILURE);\n"
6198 "    }\n"
6199 msgstr ""
6200 "        fprintf(stderr, \"partial write\");\n"
6201 "        exit(EXIT_FAILURE);\n"
6202 "    }\n"
6203
6204 #. type: Plain text
6205 #: build/C/man2/mmap.2:723
6206 msgid ""
6207 "B<getpagesize>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), "
6208 "B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>"
6209 "(2), B<shm_open>(3), B<shm_overview>(7)"
6210 msgstr ""
6211 "B<getpagesize>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), "
6212 "B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>"
6213 "(2), B<shm_open>(3), B<shm_overview>(7)"
6214
6215 #. type: Plain text
6216 #: build/C/man2/mmap.2:730
6217 msgid ""
6218 "The descriptions of the following files in B<proc>(5): I</proc/[pid]/maps>, "
6219 "I</proc/[pid]/map_files>, and I</proc/[pid]/smaps>."
6220 msgstr ""
6221 "B<proc>(5) の I</proc/[pid]/maps>, I</proc/[pid]/map_files>, I</proc/[pid]/"
6222 "smaps> の説明。"
6223
6224 #. type: Plain text
6225 #: build/C/man2/mmap.2:735 build/C/man2/msync.2:151
6226 msgid "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
6227 msgstr "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
6228
6229 #. type: TH
6230 #: build/C/man2/mmap2.2:29
6231 #, no-wrap
6232 msgid "MMAP2"
6233 msgstr "MMAP2"
6234
6235 #. type: TH
6236 #: build/C/man2/mmap2.2:29
6237 #, no-wrap
6238 msgid "2014-02-25"
6239 msgstr "2014-02-25"
6240
6241 #. type: Plain text
6242 #: build/C/man2/mmap2.2:32
6243 msgid "mmap2 - map files or devices into memory"
6244 msgstr "mmap2 - ファイルやデバイスをメモリにマップする"
6245
6246 #. type: Plain text
6247 #: build/C/man2/mmap2.2:38
6248 #, no-wrap
6249 msgid ""
6250 "B<void *mmap2(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<,>\n"
6251 "B<             int >I<flags>B<, int >I<fd>B<, off_t >I<pgoffset>B<);>\n"
6252 msgstr ""
6253 "B<void *mmap2(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<,>\n"
6254 "B<            int >I<flags>B<, int >I<fd>B<, off_t >I<pgoffset>B<);>\n"
6255
6256 #. type: Plain text
6257 #: build/C/man2/mmap2.2:43
6258 msgid ""
6259 "This is probably not the system call that you are interested in; instead, "
6260 "see B<mmap>(2), which describes the glibc wrapper function that invokes this "
6261 "system call."
6262 msgstr ""
6263 "これはおそらくあなたが興味のあるシステムコールではないだろう。代わりに\n"
6264 "B<mmap>(2) を見るとよい。そのページにはこのシステムコールを起動する glibc "
6265 "の\n"
6266 "ラッパー関数についての説明がある。"
6267
6268 #. type: Plain text
6269 #: build/C/man2/mmap2.2:54
6270 msgid ""
6271 "The B<mmap2>()  system call provides the same interface as B<mmap>(2), "
6272 "except that the final argument specifies the offset into the file in 4096-"
6273 "byte units (instead of bytes, as is done by B<mmap>(2)).  This enables "
6274 "applications that use a 32-bit I<off_t> to map large files (up to 2^44 "
6275 "bytes)."
6276 msgstr ""
6277 "B<mmap2>() システムコールは B<mmap>(2) と同じインターフェースを提供する。た"
6278 "だ\n"
6279 "し、最後の引き数には、ファイルのオフセットを (B<mmap>(2) が行っている、バイ"
6280 "ト\n"
6281 "単位ではなく) 4096 バイトを単位として指定する。 これにより、32 ビットの\n"
6282 "I<off_t> を使うアプリケーションで (2^44 バイトまでの) 大きなファイルをマッ"
6283 "プ\n"
6284 "できるようになる。"
6285
6286 #. type: Plain text
6287 #: build/C/man2/mmap2.2:61
6288 msgid ""
6289 "On success, B<mmap2>()  returns a pointer to the mapped area.  On error, -1 "
6290 "is returned and I<errno> is set appropriately."
6291 msgstr ""
6292 "成功した場合、 B<mmap2>()  はマップされた領域へのポインタを返す。 エラーの場"
6293 "合は -1 が返されて、 I<errno> が適切に設定される。"
6294
6295 #. type: Plain text
6296 #: build/C/man2/mmap2.2:65
6297 msgid "Problem with getting the data from user space."
6298 msgstr "ユーザ空間からデータを取得するときに問題があった。"
6299
6300 #. type: Plain text
6301 #: build/C/man2/mmap2.2:70
6302 msgid ""
6303 "(Various platforms where the page size is not 4096 bytes.)  I<offset\\ *\\ "
6304 "4096> is not a multiple of the system page size."
6305 msgstr ""
6306 "(ページサイズが 4096 バイトでないプラットフォームにおいて)  I<offset\\ *\\ "
6307 "4096> がシステムのページサイズの倍数ではない。"
6308
6309 #. type: Plain text
6310 #: build/C/man2/mmap2.2:74
6311 msgid "B<mmap2>()  can also return any of the errors described in B<mmap>(2)."
6312 msgstr "B<mmap2>() は B<mmap>(2) に載っているエラーを返すこともある。"
6313
6314 #. type: Plain text
6315 #: build/C/man2/mmap2.2:77
6316 msgid "B<mmap2>()  is available since Linux 2.3.31."
6317 msgstr "B<mmap2>()  は、Linux 2.3.31 以降で使用可能である。"
6318
6319 #. type: Plain text
6320 #: build/C/man2/mmap2.2:79 build/C/man2/subpage_prot.2:98
6321 msgid "This system call is Linux-specific."
6322 msgstr "このシステムコールは Linux 独自である。"
6323
6324 #. type: Plain text
6325 #: build/C/man2/mmap2.2:86
6326 msgid ""
6327 "On architectures where this system call is present, the glibc B<mmap>()  "
6328 "wrapper function invokes this system call rather than the B<mmap>(2)  system "
6329 "call."
6330 msgstr ""
6331 "このシステムコールが存在するアーキテクチャーでは、glibc の B<mmap>()  のラッ"
6332 "パー関数は、 B<mmap>(2)  システムコールではなく、このシステムコール (B<mmap2>"
6333 "(2))  を起動する。"
6334
6335 #. type: Plain text
6336 #: build/C/man2/mmap2.2:88
6337 msgid "This system call does not exist on x86-64."
6338 msgstr "このシステムコールは x86-64 には存在しない。"
6339
6340 #.  ia64 can have page sizes ranging from 4kB to 64kB.
6341 #.  On cris, it looks like the unit might also be the page size,
6342 #.  which is 8192 bytes. -- mtk, June 2007
6343 #. type: Plain text
6344 #: build/C/man2/mmap2.2:95
6345 msgid ""
6346 "On ia64, the unit for I<offset> is actually the system page size, rather "
6347 "than 4096 bytes."
6348 msgstr ""
6349 "ia64 では、 I<offset> の単位は、実際にはシステムのページサイズであり、 4096 "
6350 "バイトではない。"
6351
6352 #. type: Plain text
6353 #: build/C/man2/mmap2.2:101
6354 msgid ""
6355 "B<getpagesize>(2), B<mmap>(2), B<mremap>(2), B<msync>(2), B<shm_open>(3)"
6356 msgstr ""
6357 "B<getpagesize>(2), B<mmap>(2), B<mremap>(2), B<msync>(2), B<shm_open>(3)"
6358
6359 #. type: TH
6360 #: build/C/man2/mprotect.2:38
6361 #, no-wrap
6362 msgid "MPROTECT"
6363 msgstr "MPROTECT"
6364
6365 #. type: TH
6366 #: build/C/man2/mprotect.2:38
6367 #, no-wrap
6368 msgid "2014-01-05"
6369 msgstr "2014-01-05"
6370
6371 #. type: Plain text
6372 #: build/C/man2/mprotect.2:41
6373 msgid "mprotect - set protection on a region of memory"
6374 msgstr "mprotect - メモリ領域の保護を設定する"
6375
6376 #. type: Plain text
6377 #: build/C/man2/mprotect.2:46
6378 #, no-wrap
6379 msgid "B<int mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
6380 msgstr "B<int mprotect(void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
6381
6382 #. type: Plain text
6383 #: build/C/man2/mprotect.2:54
6384 msgid ""
6385 "B<mprotect>()  changes protection for the calling process's memory page(s)  "
6386 "containing any part of the address range in the interval [I<addr>,\\ I<addr>"
6387 "+I<len>-1].  I<addr> must be aligned to a page boundary."
6388 msgstr ""
6389 "B<mprotect>()  は、区間 [I<addr>,\\ I<addr>+I<len>-1] のアドレス範囲を含む 呼"
6390 "び出し元のプロセスのメモリページのアクセス保護を変更する。 I<addr> はページ境"
6391 "界に一致していなければならない。"
6392
6393 #. type: Plain text
6394 #: build/C/man2/mprotect.2:59
6395 msgid ""
6396 "If the calling process tries to access memory in a manner that violates the "
6397 "protection, then the kernel generates a B<SIGSEGV> signal for the process."
6398 msgstr ""
6399 "呼び出し元のプロセスがアクセス保護に違反するようなメモリアクセスを 行おうとす"
6400 "ると、カーネルはシグナル B<SIGSEGV> をそのプロセスに対して生成する。"
6401
6402 #. type: Plain text
6403 #: build/C/man2/mprotect.2:64
6404 msgid ""
6405 "I<prot> is either B<PROT_NONE> or a bitwise-or of the other values in the "
6406 "following list:"
6407 msgstr ""
6408 "I<prot> には、 B<PROT_NONE> か、以下のリストの B<PROT_NONE> 以外の値をビット"
6409 "毎の論理和 (bitwize-or) で指定する:"
6410
6411 #. type: Plain text
6412 #: build/C/man2/mprotect.2:67
6413 msgid "The memory cannot be accessed at all."
6414 msgstr "そのメモリには全くアクセスできない。"
6415
6416 #. type: Plain text
6417 #: build/C/man2/mprotect.2:70
6418 msgid "The memory can be read."
6419 msgstr "そのメモリを読み取ることができる。"
6420
6421 #. type: Plain text
6422 #: build/C/man2/mprotect.2:73
6423 msgid "The memory can be modified."
6424 msgstr "そのメモリを変更できる。"
6425
6426 #.  FIXME
6427 #.  Document PROT_GROWSUP and PROT_GROWSDOWN
6428 #. type: Plain text
6429 #: build/C/man2/mprotect.2:78
6430 msgid "The memory can be executed."
6431 msgstr "そのメモリは実行可能である。"
6432
6433 #. type: Plain text
6434 #: build/C/man2/mprotect.2:85
6435 msgid ""
6436 "On success, B<mprotect>()  returns zero.  On error, -1 is returned, and "
6437 "I<errno> is set appropriately."
6438 msgstr ""
6439 "成功した場合、 B<mprotect>()  は 0 を返す。エラーの場合は -1 が返り、 "
6440 "I<errno> が適切に設定される。"
6441
6442 #. type: Plain text
6443 #: build/C/man2/mprotect.2:95
6444 msgid ""
6445 "The memory cannot be given the specified access.  This can happen, for "
6446 "example, if you B<mmap>(2)  a file to which you have read-only access, then "
6447 "ask B<mprotect>()  to mark it B<PROT_WRITE>."
6448 msgstr ""
6449 "指定されたアクセスをメモリに設定することができない。 これは、例えば ファイル"
6450 "を読み取り専用で B<mmap>(2)  しており、その領域に対して B<mprotect>()  を呼び"
6451 "出して B<PROT_WRITE> に設定しようとした場合に発生する。"
6452
6453 #.  Or: both PROT_GROWSUP and PROT_GROWSDOWN were specified in 'prot'.
6454 #. type: Plain text
6455 #: build/C/man2/mprotect.2:100
6456 msgid ""
6457 "I<addr> is not a valid pointer, or not a multiple of the system page size."
6458 msgstr ""
6459 "I<addr> が有効なポインタでないか、 システムのページサイズの倍数でない。"
6460
6461 #. type: Plain text
6462 #: build/C/man2/mprotect.2:103
6463 msgid "Internal kernel structures could not be allocated."
6464 msgstr "カーネル内部の構造体を割り当てることができなかった。"
6465
6466 #. type: Plain text
6467 #: build/C/man2/mprotect.2:113
6468 msgid ""
6469 "Addresses in the range [I<addr>, I<addr>+I<len>-1] are invalid for the "
6470 "address space of the process, or specify one or more pages that are not "
6471 "mapped.  (Before kernel 2.4.19, the error B<EFAULT> was incorrectly produced "
6472 "for these cases.)"
6473 msgstr ""
6474 "[I<addr>, I<addr>+I<len>-1] という範囲のアドレスがプロセスのアドレス空間とし"
6475 "て不正であるか、 その範囲のアドレスがマップされていない 1 つ以上のページを指"
6476 "している (カーネル 2.4.19 より前では、この状況でエラー B<EFAULT> が間違って生"
6477 "成されていた)。"
6478
6479 #.  SVr4 defines an additional error
6480 #.  code EAGAIN. The SVr4 error conditions don't map neatly onto Linux's.
6481 #. type: Plain text
6482 #: build/C/man2/mprotect.2:122
6483 msgid ""
6484 "SVr4, POSIX.1-2001.  POSIX says that the behavior of B<mprotect>()  is "
6485 "unspecified if it is applied to a region of memory that was not obtained via "
6486 "B<mmap>(2)."
6487 msgstr ""
6488 "SVr4, POSIX.1-2001.  POSIX では、 B<mmap>(2)  経由で獲得していないメモリ領域"
6489 "に対して B<mprotect>()  を行った場合の B<mprotect>()  の動作は未定義であると"
6490 "されている。"
6491
6492 #. type: Plain text
6493 #: build/C/man2/mprotect.2:129
6494 msgid ""
6495 "On Linux it is always permissible to call B<mprotect>()  on any address in a "
6496 "process's address space (except for the kernel vsyscall area).  In "
6497 "particular it can be used to change existing code mappings to be writable."
6498 msgstr ""
6499 "Linux では、(カーネル vsyscall 領域以外の)  任意のプロセスアドレス空間に対し"
6500 "て B<mprotect>()  を呼び出すことが、常に許されている。 これは特に既存のコード"
6501 "マッピングを書き込み可能にするために使われる。"
6502
6503 #. type: Plain text
6504 #: build/C/man2/mprotect.2:139
6505 msgid ""
6506 "Whether B<PROT_EXEC> has any effect different from B<PROT_READ> is "
6507 "architecture- and kernel version-dependent.  On some hardware architectures "
6508 "(e.g., i386), B<PROT_WRITE> implies B<PROT_READ>."
6509 msgstr ""
6510 "B<PROT_EXEC> が B<PROT_READ> と異なる影響を持つか否かは、アーキテクチャとカー"
6511 "ネルのバージョンに依存する。 (i386 などの) いくつかのアーキテクチャでは、 "
6512 "B<PROT_WRITE> をセットすると、暗黙のうちに B<PROT_READ> がセットされる。"
6513
6514 #. type: Plain text
6515 #: build/C/man2/mprotect.2:148
6516 msgid ""
6517 "POSIX.1-2001 says that an implementation may permit access other than that "
6518 "specified in I<prot>, but at a minimum can allow write access only if "
6519 "B<PROT_WRITE> has been set, and must not allow any access if B<PROT_NONE> "
6520 "has been set."
6521 msgstr ""
6522 "POSIX.1-2001 では、 I<prot> で指定されていないアクセスを許可する実装を認めて"
6523 "いる。 ただし、最低限、 B<PROT_WRITE> がセットされている場合にのみ書き込みア"
6524 "クセスが許可され、 B<PROT_NONE> がセットされている場合にはアクセスは許可され"
6525 "ない点だけは 満たす必要がある。"
6526
6527 #. type: Plain text
6528 #: build/C/man2/mprotect.2:154
6529 msgid ""
6530 "The program below allocates four pages of memory, makes the third of these "
6531 "pages read-only, and then executes a loop that walks upward through the "
6532 "allocated region modifying bytes."
6533 msgstr ""
6534 "以下のプログラムは、メモリページを 4つ確保し、そのうち 3番目のページを 読み込"
6535 "み専用に設定する。その後で、確保した領域のアドレスの小さい方から 大きな方に向"
6536 "かって順番にバイト値を変更するループを実行する。"
6537
6538 #. type: Plain text
6539 #: build/C/man2/mprotect.2:157
6540 msgid ""
6541 "An example of what we might see when running the program is the following:"
6542 msgstr "プログラムを実行した場合の一例を以下に示す。"
6543
6544 #. type: Plain text
6545 #: build/C/man2/mprotect.2:163
6546 #, no-wrap
6547 msgid ""
6548 "$B< ./a.out>\n"
6549 "Start of region:        0x804c000\n"
6550 "Got SIGSEGV at address: 0x804e000\n"
6551 msgstr ""
6552 "$B< ./a.out>\n"
6553 "Start of region:        0x804c000\n"
6554 "Got SIGSEGV at address: 0x804e000\n"
6555
6556 #. type: Plain text
6557 #: build/C/man2/mprotect.2:175
6558 #, no-wrap
6559 msgid ""
6560 "#include E<lt>unistd.hE<gt>\n"
6561 "#include E<lt>signal.hE<gt>\n"
6562 "#include E<lt>stdio.hE<gt>\n"
6563 "#include E<lt>malloc.hE<gt>\n"
6564 "#include E<lt>stdlib.hE<gt>\n"
6565 "#include E<lt>errno.hE<gt>\n"
6566 "#include E<lt>sys/mman.hE<gt>\n"
6567 msgstr ""
6568 "#include E<lt>unistd.hE<gt>\n"
6569 "#include E<lt>signal.hE<gt>\n"
6570 "#include E<lt>stdio.hE<gt>\n"
6571 "#include E<lt>malloc.hE<gt>\n"
6572 "#include E<lt>stdlib.hE<gt>\n"
6573 "#include E<lt>errno.hE<gt>\n"
6574 "#include E<lt>sys/mman.hE<gt>\n"
6575
6576 #. type: Plain text
6577 #: build/C/man2/mprotect.2:180
6578 #, no-wrap
6579 msgid "static char *buffer;\n"
6580 msgstr "static char *buffer;\n"
6581
6582 #. type: Plain text
6583 #: build/C/man2/mprotect.2:188
6584 #, no-wrap
6585 msgid ""
6586 "static void\n"
6587 "handler(int sig, siginfo_t *si, void *unused)\n"
6588 "{\n"
6589 "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
6590 "            (long) si-E<gt>si_addr);\n"
6591 "    exit(EXIT_FAILURE);\n"
6592 "}\n"
6593 msgstr ""
6594 "static void\n"
6595 "handler(int sig, siginfo_t *si, void *unused)\n"
6596 "{\n"
6597 "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
6598 "            (long) si-E<gt>si_addr);\n"
6599 "    exit(EXIT_FAILURE);\n"
6600 "}\n"
6601
6602 #. type: Plain text
6603 #: build/C/man2/mprotect.2:195
6604 #, no-wrap
6605 msgid ""
6606 "int\n"
6607 "main(int argc, char *argv[])\n"
6608 "{\n"
6609 "    char *p;\n"
6610 "    int pagesize;\n"
6611 "    struct sigaction sa;\n"
6612 msgstr ""
6613 "int\n"
6614 "main(void)\n"
6615 "{\n"
6616 "    char *p;\n"
6617 "    int pagesize;\n"
6618 "    struct sigaction sa;\n"
6619
6620 #. type: Plain text
6621 #: build/C/man2/mprotect.2:201
6622 #, no-wrap
6623 msgid ""
6624 "    sa.sa_flags = SA_SIGINFO;\n"
6625 "    sigemptyset(&sa.sa_mask);\n"
6626 "    sa.sa_sigaction = handler;\n"
6627 "    if (sigaction(SIGSEGV, &sa, NULL) == -1)\n"
6628 "        handle_error(\"sigaction\");\n"
6629 msgstr ""
6630 "    sa.sa_flags = SA_SIGINFO;\n"
6631 "    sigemptyset(&sa.sa_mask);\n"
6632 "    sa.sa_sigaction = handler;\n"
6633 "    if (sigaction(SIGSEGV, &sa, NULL) == -1)\n"
6634 "        handle_error(\"sigaction\");\n"
6635
6636 #. type: Plain text
6637 #: build/C/man2/mprotect.2:205
6638 #, no-wrap
6639 msgid ""
6640 "    pagesize = sysconf(_SC_PAGE_SIZE);\n"
6641 "    if (pagesize == -1)\n"
6642 "        handle_error(\"sysconf\");\n"
6643 msgstr ""
6644 "    pagesize = sysconf(_SC_PAGE_SIZE);\n"
6645 "    if (pagesize == -1)\n"
6646 "        handle_error(\"sysconf\");\n"
6647
6648 #. type: Plain text
6649 #: build/C/man2/mprotect.2:208
6650 #, no-wrap
6651 msgid ""
6652 "    /* Allocate a buffer aligned on a page boundary;\n"
6653 "       initial protection is PROT_READ | PROT_WRITE */\n"
6654 msgstr ""
6655 "    /* Allocate a buffer aligned on a page boundary;\n"
6656 "       initial protection is PROT_READ | PROT_WRITE */\n"
6657
6658 #. type: Plain text
6659 #: build/C/man2/mprotect.2:212
6660 #, no-wrap
6661 msgid ""
6662 "    buffer = memalign(pagesize, 4 * pagesize);\n"
6663 "    if (buffer == NULL)\n"
6664 "        handle_error(\"memalign\");\n"
6665 msgstr ""
6666 "    buffer = memalign(pagesize, 4 * pagesize);\n"
6667 "    if (buffer == NULL)\n"
6668 "        handle_error(\"memalign\");\n"
6669
6670 #. type: Plain text
6671 #: build/C/man2/mprotect.2:214
6672 #, no-wrap
6673 msgid "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
6674 msgstr "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
6675
6676 #. type: Plain text
6677 #: build/C/man2/mprotect.2:218
6678 #, no-wrap
6679 msgid ""
6680 "    if (mprotect(buffer + pagesize * 2, pagesize,\n"
6681 "                PROT_READ) == -1)\n"
6682 "        handle_error(\"mprotect\");\n"
6683 msgstr ""
6684 "    if (mprotect(buffer + pagesize * 2, pagesize,\n"
6685 "                PROT_READ) == -1)\n"
6686 "        handle_error(\"mprotect\");\n"
6687
6688 #. type: Plain text
6689 #: build/C/man2/mprotect.2:221
6690 #, no-wrap
6691 msgid ""
6692 "    for (p = buffer ; ; )\n"
6693 "        *(p++) = \\(aqa\\(aq;\n"
6694 msgstr ""
6695 "    for (p = buffer ; ; )\n"
6696 "        *(p++) = \\(aqa\\(aq;\n"
6697
6698 #. type: Plain text
6699 #: build/C/man2/mprotect.2:225
6700 #, no-wrap
6701 msgid ""
6702 "    printf(\"Loop completed\\en\");     /* Should never happen */\n"
6703 "    exit(EXIT_SUCCESS);\n"
6704 "}\n"
6705 msgstr ""
6706 "    printf(\"Loop completed\\en\");     /* Should never happen */\n"
6707 "    exit(EXIT_SUCCESS);\n"
6708 "}\n"
6709
6710 #. type: Plain text
6711 #: build/C/man2/mprotect.2:229
6712 msgid "B<mmap>(2), B<sysconf>(3)"
6713 msgstr "B<mmap>(2), B<sysconf>(3)"
6714
6715 #. type: TH
6716 #: build/C/man2/mremap.2:30
6717 #, no-wrap
6718 msgid "MREMAP"
6719 msgstr "MREMAP"
6720
6721 #. type: TH
6722 #: build/C/man2/mremap.2:30
6723 #, no-wrap
6724 msgid "2010-06-10"
6725 msgstr "2010-06-10"
6726
6727 #. type: Plain text
6728 #: build/C/man2/mremap.2:33
6729 msgid "mremap - remap a virtual memory address"
6730 msgstr "mremap - 仮想メモリ・アドレスを再マッピングする"
6731
6732 #. type: Plain text
6733 #: build/C/man2/mremap.2:36
6734 #, no-wrap
6735 msgid "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
6736 msgstr "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
6737
6738 #. type: Plain text
6739 #: build/C/man2/mremap.2:41
6740 #, no-wrap
6741 msgid ""
6742 "B<void *mremap(void *>I<old_address>B<, size_t >I<old_size>B<,>\n"
6743 "B<             size_t >I<new_size>B<, int >I<flags>B<, ... /* void *>I<new_address>B< */);>\n"
6744 msgstr ""
6745 "B<void *mremap(void *>I<old_address>B<, size_t >I<old_size>B<,>\n"
6746 "B<             size_t >I<new_size>B<, int >I<flags>B<, ... /* void *>I<new_address>B< */);>\n"
6747
6748 #. type: Plain text
6749 #: build/C/man2/mremap.2:47
6750 msgid ""
6751 "B<mremap>()  expands (or shrinks) an existing memory mapping, potentially "
6752 "moving it at the same time (controlled by the I<flags> argument and the "
6753 "available virtual address space)."
6754 msgstr ""
6755 "B<mremap>()  は既存のメモリ・マッピングの拡張 (または縮小) を行う。 同時に移"
6756 "動されることもある (I<flags> 引き数と利用可能な仮想アドレス空間によって決ま"
6757 "る)。"
6758
6759 #. type: Plain text
6760 #: build/C/man2/mremap.2:61
6761 msgid ""
6762 "I<old_address> is the old address of the virtual memory block that you want "
6763 "to expand (or shrink).  Note that I<old_address> has to be page aligned.  "
6764 "I<old_size> is the old size of the virtual memory block.  I<new_size> is the "
6765 "requested size of the virtual memory block after the resize.  An optional "
6766 "fifth argument, I<new_address>, may be provided; see the description of "
6767 "B<MREMAP_FIXED> below."
6768 msgstr ""
6769 "I<old_address> は拡張 (または縮小) しようとする仮想メモリ・ブロック の元のア"
6770 "ドレスである。I<old_address> はページ境界に合っていなければ ならない点に注意"
6771 "すること。I<old_size> は元の仮想メモリ・ブロックの サイズである。 "
6772 "I<new_size> は要求する変更後の仮想メモリ・ブロックのサイズである。 5 番目の引"
6773 "き数として I<new_address> を指定することができる。下記の B<MREMAP_FIXED> の説"
6774 "明を参照のこと。"
6775
6776 #. type: Plain text
6777 #: build/C/man2/mremap.2:73
6778 msgid ""
6779 "In Linux the memory is divided into pages.  A user process has (one or)  "
6780 "several linear virtual memory segments.  Each virtual memory segment has one "
6781 "or more mappings to real memory pages (in the page table).  Each virtual "
6782 "memory segment has its own protection (access rights), which may cause a "
6783 "segmentation violation if the memory is accessed incorrectly (e.g., writing "
6784 "to a read-only segment).  Accessing virtual memory outside of the segments "
6785 "will also cause a segmentation violation."
6786 msgstr ""
6787 "Linux ではメモリはページに分割される。ユーザー・プロセスは (一つまたは)  複数"
6788 "のリニアな仮想メモリセグメントを持つ。 それぞれの仮想メモリセグメントは一つ以"
6789 "上の実メモリ・ページ にマッピングされている (マッピング情報はページ・テーブル"
6790 "で管理される)。 仮想メモリセグメントにはセグメント毎の保護 (アクセス権) が設"
6791 "定されており、 メモリが不正にアクセスされた場合 (例えば読み込み専用のセグメン"
6792 "トに 書き込んだ場合)、セグメンテーション侵害 (segmentation violation) を 引き"
6793 "起こす。また、セグメント外の仮想メモリにアクセスした場合にも セグメンテーショ"
6794 "ン侵害が発生する。"
6795
6796 #. type: Plain text
6797 #: build/C/man2/mremap.2:81
6798 msgid ""
6799 "B<mremap>()  uses the Linux page table scheme.  B<mremap>()  changes the "
6800 "mapping between virtual addresses and memory pages.  This can be used to "
6801 "implement a very efficient B<realloc>(3)."
6802 msgstr ""
6803 "B<mremap>()  は Linux のページ・テーブル方式を使用する。 B<mremap>()  は仮想"
6804 "アドレスとメモリ・ページのマッピングを変更する。これは非常に効率的な "
6805 "B<realloc>(3)  を実装するのに使用されている。"
6806
6807 #. type: Plain text
6808 #: build/C/man2/mremap.2:83
6809 msgid "The I<flags> bit-mask argument may be 0, or include the following flag:"
6810 msgstr "I<flags> ビットマスク引数は 0 または以下のフラグを含む:"
6811
6812 #. type: TP
6813 #: build/C/man2/mremap.2:83
6814 #, no-wrap
6815 msgid "B<MREMAP_MAYMOVE>"
6816 msgstr "B<MREMAP_MAYMOVE>"
6817
6818 #. type: Plain text
6819 #: build/C/man2/mremap.2:95
6820 msgid ""
6821 "By default, if there is not sufficient space to expand a mapping at its "
6822 "current location, then B<mremap>()  fails.  If this flag is specified, then "
6823 "the kernel is permitted to relocate the mapping to a new virtual address, if "
6824 "necessary.  If the mapping is relocated, then absolute pointers into the old "
6825 "mapping location become invalid (offsets relative to the starting address of "
6826 "the mapping should be employed)."
6827 msgstr ""
6828 "デフォルトでは、現在の位置にマッピングを拡張するための 十分な空きがなければ "
6829 "B<mremap>()  は失敗する。 このフラグが指定されると、カーネルは必要があれば"
6830 "マッピングを 新しい仮想アドレスに再配置することができる マッピングが再配置さ"
6831 "れると、古いマッピング位置への絶対ポインタは 無効になる (マッピングの開始アド"
6832 "レスからの相対オフセットは有効のままである)。"
6833
6834 #. type: TP
6835 #: build/C/man2/mremap.2:95
6836 #, no-wrap
6837 msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
6838 msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
6839
6840 #. type: Plain text
6841 #: build/C/man2/mremap.2:117
6842 msgid ""
6843 "This flag serves a similar purpose to the B<MAP_FIXED> flag of B<mmap>(2).  "
6844 "If this flag is specified, then B<mremap>()  accepts a fifth argument, I<void"
6845 "\\ *new_address>, which specifies a page-aligned address to which the "
6846 "mapping must be moved.  Any previous mapping at the address range specified "
6847 "by I<new_address> and I<new_size> is unmapped.  If B<MREMAP_FIXED> is "
6848 "specified, then B<MREMAP_MAYMOVE> must also be specified."
6849 msgstr ""
6850 "このフラグは B<mmap>(2)  の B<MAP_FIXED> フラグと似たような目的で用いられ"
6851 "る。 このフラグが指定されると、 B<mremap>()  は 5 番目の引き数 I<void\\ "
6852 "*new_address> を受け取り、この引数はマッピングが移動されるべきアドレスを指定"
6853 "する。 このアドレスはページ境界に合っていなければならない。 I<new_address> "
6854 "と I<new_size> で指定されるアドレス範囲に過去のマッピングがあった場合、 その"
6855 "マッピングはアンマップされる (unmapped)。 B<MREMAP_FIXED> を指定した場合は、 "
6856 "B<MREMAP_MAYMOVE> も指定しなければならない。"
6857
6858 #. type: Plain text
6859 #: build/C/man2/mremap.2:127
6860 msgid ""
6861 "If the memory segment specified by I<old_address> and I<old_size> is locked "
6862 "(using B<mlock>(2)  or similar), then this lock is maintained when the "
6863 "segment is resized and/or relocated.  As a consequence, the amount of memory "
6864 "locked by the process may change."
6865 msgstr ""
6866 "I<old_address> と I<old_size> で指定されるメモリセグメントが (B<mlock>(2)  や"
6867 "同様のもので) ロックされている場合、セグメントのサイズが変わったり 再配置され"
6868 "たりした時にロックも維持される。 その結果、プロセスによってロックされるメモリ"
6869 "の量は変化する。"
6870
6871 #. type: Plain text
6872 #: build/C/man2/mremap.2:135
6873 msgid ""
6874 "On success B<mremap>()  returns a pointer to the new virtual memory area.  "
6875 "On error, the value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>) is returned, "
6876 "and I<errno> is set appropriately."
6877 msgstr ""
6878 "成功した場合は B<mremap>()  は新しい仮想メモリ領域へのポインタを返す。 エラー"
6879 "の場合は B<MAP_FAILED> (すなわち I<(void\\ *)\\ -1>) が返され、 I<errno> が適"
6880 "切に設定される。"
6881
6882 #. type: Plain text
6883 #: build/C/man2/mremap.2:142
6884 msgid ""
6885 "The caller tried to expand a memory segment that is locked, but this was not "
6886 "possible without exceeding the B<RLIMIT_MEMLOCK> resource limit."
6887 msgstr ""
6888 "呼び出し元がロックされているメモリセグメントを拡張しようとしたが、 "
6889 "B<RLIMIT_MEMLOCK> リソース制限を越えずにこれを行うことができない。"
6890
6891 #. type: Plain text
6892 #: build/C/man2/mremap.2:151
6893 msgid ""
6894 "\"Segmentation fault.\" Some address in the range I<old_address> to "
6895 "I<old_address>+I<old_size> is an invalid virtual memory address for this "
6896 "process.  You can also get B<EFAULT> even if there exist mappings that cover "
6897 "the whole address space requested, but those mappings are of different types."
6898 msgstr ""
6899 "「セグメンテーション違反(segmentation fault)」 I<old_address> から "
6900 "I<old_address>+I<old_size> の 範囲のアドレスのどれかがこのプロセスにおいて不"
6901 "正な仮想メモリ・アドレスである。 たとえ要求したアドレス空間全体を含むような"
6902 "マッピングがあったとしても、 それらのマッピングが異なった型ならば B<EFAULT> "
6903 "を受け取るだろう。"
6904
6905 #. type: Plain text
6906 #: build/C/man2/mremap.2:179
6907 msgid ""
6908 "An invalid argument was given.  Possible causes are: I<old_address> was not "
6909 "page aligned; a value other than B<MREMAP_MAYMOVE> or B<MREMAP_FIXED> was "
6910 "specified in I<flags>; I<new_size> was zero; I<new_size> or I<new_address> "
6911 "was invalid; or the new address range specified by I<new_address> and "
6912 "I<new_size> overlapped the old address range specified by I<old_address> and "
6913 "I<old_size>; or B<MREMAP_FIXED> was specified without also specifying "
6914 "B<MREMAP_MAYMOVE>."
6915 msgstr ""
6916 "不正な引き数が与えられた。 可能性のある原因は以下の通りである: たいていは "
6917 "I<old_address> がページ境界に 合ってない; I<flags> に B<MREMAP_MAYMOVE> また"
6918 "は B<MREMAP_FIXED> 以外の値が指定されている; I<new_size> がゼロ; I<new_size> "
6919 "または I<new_address> の値が不正; I<new_address> と I<new_size> で指定される"
6920 "新しいアドレス範囲が I<old_address> と I<old_size> で指定される古いアドレス範"
6921 "囲と重なっている; B<MREMAP_FIXED> が指定されているが B<MREMAP_MAYMOVE> が指定"
6922 "されていない。"
6923
6924 #. type: Plain text
6925 #: build/C/man2/mremap.2:185
6926 msgid ""
6927 "The memory area cannot be expanded at the current virtual address, and the "
6928 "B<MREMAP_MAYMOVE> flag is not set in I<flags>.  Or, there is not enough "
6929 "(virtual) memory available."
6930 msgstr ""
6931 "現在の仮想アドレスではメモリ領域が拡張できず、 B<MREMAP_MAYMOVE> フラグが "
6932 "I<flags> に設定されていない。 または十分な (仮想) メモリが存在しない。"
6933
6934 #.  4.2BSD had a (never actually implemented)
6935 #.  .BR mremap (2)
6936 #.  call with completely different semantics.
6937 #. type: Plain text
6938 #: build/C/man2/mremap.2:191
6939 msgid ""
6940 "This call is Linux-specific, and should not be used in programs intended to "
6941 "be portable."
6942 msgstr ""
6943 "このコールは Linux 特有であり、移植を意図したプログラムで 使用すべきではな"
6944 "い。"
6945
6946 #. type: Plain text
6947 #: build/C/man2/mremap.2:199
6948 msgid ""
6949 "Prior to version 2.4, glibc did not expose the definition of "
6950 "B<MREMAP_FIXED>, and the prototype for B<mremap>()  did not allow for the "
6951 "I<new_address> argument."
6952 msgstr ""
6953 "バージョン 2.4 より前の glibc では、 B<MREMAP_FIXED> の定義は公開されておら"
6954 "ず、 B<mremap>()  のプロトタイプは I<new_address> 引き数を取らなかった。"
6955
6956 #. type: Plain text
6957 #: build/C/man2/mremap.2:208
6958 msgid ""
6959 "B<brk>(2), B<getpagesize>(2), B<getrlimit>(2), B<mlock>(2), B<mmap>(2), "
6960 "B<sbrk>(2), B<malloc>(3), B<realloc>(3)"
6961 msgstr ""
6962 "B<brk>(2), B<getpagesize>(2), B<getrlimit>(2), B<mlock>(2), B<mmap>(2), "
6963 "B<sbrk>(2), B<realloc>(3), B<malloc>(3)"
6964
6965 #. type: Plain text
6966 #: build/C/man2/mremap.2:214
6967 msgid ""
6968 "Your favorite text book on operating systems for more information on paged "
6969 "memory (e.g., I<Modern Operating Systems> by Andrew S. Tanenbaum, I<Inside "
6970 "Linux> by Randolf Bentson, I<The Design of the UNIX Operating System> by "
6971 "Maurice J. Bach)"
6972 msgstr ""
6973 "ページ分割されたメモリについてもっと詳しく知りたいならば、あなたのお気に入り"
6974 "のオペレーティングシステムの教科書を参照してほしい (例えば、 I<Modern "
6975 "Operating Systems> by Andrew S. Tanenbaum, I<Inside Linux> by Randolf "
6976 "Bentson, I<The Design of the UNIX Operating System> by Maurice J. Bach.)"
6977
6978 #. type: TH
6979 #: build/C/man2/msync.2:25
6980 #, no-wrap
6981 msgid "MSYNC"
6982 msgstr "MSYNC"
6983
6984 #. type: Plain text
6985 #: build/C/man2/msync.2:28
6986 msgid "msync - synchronize a file with a memory map"
6987 msgstr "msync - ファイルをマップしたメモリと同期させる"
6988
6989 #. type: Plain text
6990 #: build/C/man2/msync.2:32
6991 msgid "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
6992 msgstr "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
6993
6994 #. type: Plain text
6995 #: build/C/man2/msync.2:48
6996 msgid ""
6997 "B<msync>()  flushes changes made to the in-core copy of a file that was "
6998 "mapped into memory using B<mmap>(2)  back to disk.  Without use of this call "
6999 "there is no guarantee that changes are written back before B<munmap>(2)  is "
7000 "called.  To be more precise, the part of the file that corresponds to the "
7001 "memory area starting at I<addr> and having length I<length> is updated."
7002 msgstr ""
7003 "B<msync>()  は B<mmap>(2)  を使ってメモリにマップされたファイルの、 メモリ上"
7004 "のコピーになされた変更をディスクに反映させる。 この関数を使用しないと、 "
7005 "B<munmap>(2)  が呼び出されるまで変更が書き戻される保証はない。 より正確には、"
7006 "ファイルのうち I<addr> から始まり長さ I<length> のメモリ領域に対応する部分が"
7007 "更新される。"
7008
7009 #. type: Plain text
7010 #: build/C/man2/msync.2:68
7011 msgid ""
7012 "The I<flags> argument may have the bits B<MS_ASYNC>, B<MS_SYNC>, and "
7013 "B<MS_INVALIDATE> set, but not both B<MS_ASYNC> and B<MS_SYNC>.  B<MS_ASYNC> "
7014 "specifies that an update be scheduled, but the call returns immediately.  "
7015 "B<MS_SYNC> asks for an update and waits for it to complete.  "
7016 "B<MS_INVALIDATE> asks to invalidate other mappings of the same file (so that "
7017 "they can be updated with the fresh values just written)."
7018 msgstr ""
7019 "I<flags> 引数にはビット B<MS_ASYNC>, B<MS_SYNC>, B<MS_INVALIDATE> を設定する"
7020 "ことができるが、 B<MS_ASYNC> と B<MS_SYNC> を同時に指定することはできない。 "
7021 "B<MS_ASYNC> は更新を予定に組み込むことを表し、呼び出しは直ちに返る。 "
7022 "B<MS_SYNC> は更新を要求し、更新が完了するまで待つ。 B<MS_INVALIDATE> は(たっ"
7023 "た今書き込んだ新しい値でマッピングを更新することができるように)  同じファイル"
7024 "に対する他のマッピングを無効にすることを要求する。"
7025
7026 #. type: Plain text
7027 #: build/C/man2/msync.2:73
7028 msgid ""
7029 "On success, zero is returned.  On error, -1 is returned, and I<errno> is set "
7030 "appropriately."
7031 msgstr ""
7032 "成功した場合、 0 が返る。エラーの場合、 -1 が返り、 I<errno> が適切に設定され"
7033 "る。"
7034
7035 #. type: TP
7036 #: build/C/man2/msync.2:74
7037 #, no-wrap
7038 msgid "B<EBUSY>"
7039 msgstr "B<EBUSY>"
7040
7041 #. type: Plain text
7042 #: build/C/man2/msync.2:80
7043 msgid ""
7044 "B<MS_INVALIDATE> was specified in I<flags>, and a memory lock exists for the "
7045 "specified address range."
7046 msgstr ""
7047 "I flags に B<MS_INVALIDATE> が指定されたが、指定されたアドレス範囲にロックが"
7048 "存在する。"
7049
7050 #. type: Plain text
7051 #: build/C/man2/msync.2:93
7052 msgid ""
7053 "I<addr> is not a multiple of PAGESIZE; or any bit other than B<MS_ASYNC> | "
7054 "B<MS_INVALIDATE> | B<MS_SYNC> is set in I<flags>; or both B<MS_SYNC> and "
7055 "B<MS_ASYNC> are set in I<flags>."
7056 msgstr ""
7057 "I<addr> が PAGESIZE の倍数でない。または、 I<flags> に B<MS_ASYNC>、"
7058 "B<MS_INVALIDATE>、B<MS_SYNC> 以外のビットが設定された。 または、 I<flags> に "
7059 "B<MS_SYNC> と B<MS_ASYNC> の両方が設定された。"
7060
7061 #. type: Plain text
7062 #: build/C/man2/msync.2:96
7063 msgid "The indicated memory (or part of it) was not mapped."
7064 msgstr "指定されたメモリ (またはその一部) がマップされていない。"
7065
7066 #. type: Plain text
7067 #: build/C/man2/msync.2:98 build/C/man3/posix_fallocate.3:105
7068 #: build/C/man3/shm_open.3:253 build/C/man7/shm_overview.7:103
7069 msgid "POSIX.1-2001."
7070 msgstr "POSIX.1-2001."
7071
7072 #. type: Plain text
7073 #: build/C/man2/msync.2:105
7074 msgid ""
7075 "This call was introduced in Linux 1.3.21, and then used B<EFAULT> instead of "
7076 "B<ENOMEM>.  In Linux 2.4.19 this was changed to the POSIX value B<ENOMEM>."
7077 msgstr ""
7078 "この関数は Linux 1.3.21 で導入されたが、 B<ENOMEM> ではなく B<EFAULT> が使わ"
7079 "れていた。 これは Linux 2.4.19 で POSIX における値 B<ENOMEM> に変更された。"
7080
7081 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
7082 #.  -1: unavailable, 0: ask using sysconf().
7083 #.  glibc defines them to 1.
7084 #. type: Plain text
7085 #: build/C/man2/msync.2:120
7086 msgid ""
7087 "On POSIX systems on which B<msync>()  is available, both "
7088 "B<_POSIX_MAPPED_FILES> and B<_POSIX_SYNCHRONIZED_IO> are defined in "
7089 "I<E<lt>unistd.hE<gt>> to a value greater than 0.  (See also B<sysconf>(3).)"
7090 msgstr ""
7091 "B<msync>()  が使用可能な POSIX システムでは B<_POSIX_MAPPED_FILES> と "
7092 "B<_POSIX_SYNCHRONIZED_IO> の両方が I<E<lt>unistd.hE<gt>> で 0 より大きい値に"
7093 "定義される。 (B<sysconf>(3)  を参照すること。 )"
7094
7095 #.  commit 204ec841fbea3e5138168edbc3a76d46747cc987
7096 #. type: Plain text
7097 #: build/C/man2/msync.2:147
7098 msgid ""
7099 "According to POSIX, either B<MS_SYNC> or B<MS_ASYNC> must be specified in "
7100 "I<flags>, and indeed failure to include one of these flags will cause "
7101 "B<msync>()  to fail on some systems.  However, Linux permits a call to "
7102 "B<msync>()  that specifies neither of these flags, with semantics that are "
7103 "(currently) equivalent to specifying B<MS_ASYNC>.  (Since Linux 2.6.19, "
7104 "B<MS_ASYNC> is in fact a no-op, since the kernel properly tracks dirty pages "
7105 "and flushes them to storage as necessary.)  Notwithstanding the Linux "
7106 "behavior, portable, future-proof applications should ensure that they "
7107 "specify either B<MS_SYNC> or B<MS_ASYNC> in I<flags>."
7108 msgstr "POSIX では B<MS_SYNC> と B<MS_ASYNC> のいずれかは必ず I<flags> に指定しなければならないとされており、 実際にこれらのフラグのいずれかを指定しなかった場合 B<msync>() が失敗するシステムもある。 しかし、 Linux ではこれらのフラグのいずれも指定せずに B<msync>() を呼び出すことができ、 その場合の動作は (現在のところ) B<MS_ASYNC> を指定した場合と等価である。 (Linux 2.6.19 以降では B<MS_ASYNC> は実際には no-op (何もしない命令) である。 これはカーネルが正しく dirty ページを追跡し、必要に応じてストレージにそれらをフラッシュするからである。) Linux の動作に関係なく、アプリケーションの移植性を考慮し、将来も確実に動くようにするには、 B<MS_SYNC> か B<MS_ASYNC> のいずれかを必ず I<flags> に指定するようにすべきである。"
7109
7110 #. type: TP
7111 #: build/C/man2/msync.2:149 build/C/man7/shm_overview.7:46
7112 #, no-wrap
7113 msgid "B<mmap>(2)"
7114 msgstr "B<mmap>(2)"
7115
7116 #. type: TH
7117 #: build/C/man3/mtrace.3:25
7118 #, no-wrap
7119 msgid "MTRACE"
7120 msgstr "MTRACE"
7121
7122 #. type: TH
7123 #: build/C/man3/mtrace.3:25
7124 #, no-wrap
7125 msgid "2012-04-18"
7126 msgstr "2012-04-18"
7127
7128 #. type: Plain text
7129 #: build/C/man3/mtrace.3:28
7130 msgid "mtrace, muntrace - malloc tracing"
7131 msgstr "mtrace, muntrace - malloc のトレース"
7132
7133 #. type: Plain text
7134 #: build/C/man3/mtrace.3:30
7135 msgid "B<#include E<lt>mcheck.hE<gt>>"
7136 msgstr "B<#include E<lt>mcheck.hE<gt>>"
7137
7138 #. type: Plain text
7139 #: build/C/man3/mtrace.3:32
7140 msgid "B<void mtrace(void);>"
7141 msgstr "B<void mtrace(void);>"
7142
7143 #. type: Plain text
7144 #: build/C/man3/mtrace.3:34
7145 msgid "B<void muntrace(void);>"
7146 msgstr "B<void muntrace(void);>"
7147
7148 #. type: Plain text
7149 #: build/C/man3/mtrace.3:46
7150 msgid ""
7151 "The B<mtrace>()  function installs hook functions for the memory-allocation "
7152 "functions (B<malloc>(3), B<realloc>(3)  B<memalign>(3), B<free>(3)).  These "
7153 "hook functions record tracing information about memory allocation and "
7154 "deallocation.  The tracing information can be used to discover memory leaks "
7155 "and attempts to free nonallocated memory in a program."
7156 msgstr ""
7157
7158 #. type: Plain text
7159 #: build/C/man3/mtrace.3:57
7160 msgid ""
7161 "The B<muntrace>()  function disables the hook functions installed by "
7162 "B<mtrace>(), so that tracing information is no longer recorded for the "
7163 "memory-allocation functions.  If no hook functions were successfully "
7164 "installed by B<mtrace>(), B<muntrace>()  does nothing."
7165 msgstr ""
7166
7167 #. type: Plain text
7168 #: build/C/man3/mtrace.3:65
7169 msgid ""
7170 "When B<mtrace>()  is called, it checks the value of the environment variable "
7171 "B<MALLOC_TRACE>, which should contain the pathname of a file in which the "
7172 "tracing information is to be recorded.  If the pathname is successfully "
7173 "opened, it is truncated to zero length."
7174 msgstr ""
7175
7176 #. type: Plain text
7177 #: build/C/man3/mtrace.3:78
7178 msgid ""
7179 "If B<MALLOC_TRACE> is not set, or the pathname it specifies is invalid or "
7180 "not writable, then no hook functions are installed, and B<mtrace>()  has no "
7181 "effect.  In set-user-ID and set-group-ID programs, B<MALLOC_TRACE> is "
7182 "ignored, and B<mtrace>()  has no effect."
7183 msgstr ""
7184
7185 #. type: Plain text
7186 #: build/C/man3/mtrace.3:86
7187 msgid ""
7188 "In normal usage, B<mtrace>()  is called once at the start of execution of a "
7189 "program, and B<muntrace>()  is never called."
7190 msgstr ""
7191
7192 #. type: Plain text
7193 #: build/C/man3/mtrace.3:96
7194 msgid ""
7195 "The tracing output produced after a call to B<mtrace>()  is textual, but not "
7196 "designed to be human readable.  The GNU C library provides a Perl script, "
7197 "B<mtrace>(1), that interprets the trace log and produces human-readable "
7198 "output.  For best results, the traced program should be compiled with "
7199 "debugging enabled, so that line-number information is recorded in the "
7200 "executable."
7201 msgstr ""
7202
7203 #. type: Plain text
7204 #: build/C/man3/mtrace.3:102
7205 msgid ""
7206 "The tracing performed by B<mtrace>()  incurs a performance penalty (if "
7207 "B<MALLOC_TRACE> points to a valid, writable pathname)."
7208 msgstr ""
7209
7210 #. type: Plain text
7211 #: build/C/man3/mtrace.3:108
7212 msgid ""
7213 "The line-number information produced by B<mtrace>(1)  is not always precise: "
7214 "the line number references may refer to the previous or following "
7215 "(nonblank)  line of the source code."
7216 msgstr ""
7217
7218 #. type: Plain text
7219 #: build/C/man3/mtrace.3:115
7220 msgid ""
7221 "The shell session below demonstrates the use of the B<mtrace>()  function "
7222 "and the B<mtrace>(1)  command in a program that has memory leaks at two "
7223 "different locations.  The demonstration uses the following program:"
7224 msgstr ""
7225
7226 #. type: Plain text
7227 #: build/C/man3/mtrace.3:122
7228 #, no-wrap
7229 msgid ""
7230 "$ B<cat t_mtrace.c>\n"
7231 "#include E<lt>mcheck.hE<gt>\n"
7232 "#include E<lt>stdlib.hE<gt>\n"
7233 "#include E<lt>stdio.hE<gt>\n"
7234 msgstr ""
7235 "$ B<cat t_mtrace.c>\n"
7236 "#include E<lt>mcheck.hE<gt>\n"
7237 "#include E<lt>stdlib.hE<gt>\n"
7238 "#include E<lt>stdio.hE<gt>\n"
7239
7240 #. type: Plain text
7241 #: build/C/man3/mtrace.3:127
7242 #, no-wrap
7243 msgid ""
7244 "int\n"
7245 "main(int argc, char *argv[])\n"
7246 "{\n"
7247 "    int j;\n"
7248 msgstr ""
7249 "int\n"
7250 "main(int argc, char *argv[])\n"
7251 "{\n"
7252 "    int j;\n"
7253
7254 #. type: Plain text
7255 #: build/C/man3/mtrace.3:129
7256 #, no-wrap
7257 msgid "    mtrace();\n"
7258 msgstr "    mtrace();\n"
7259
7260 #. type: Plain text
7261 #: build/C/man3/mtrace.3:132
7262 #, no-wrap
7263 msgid ""
7264 "    for (j = 0; j E<lt> 2; j++)\n"
7265 "        malloc(100);            /* Never freed--a memory leak */\n"
7266 msgstr ""
7267 "    for (j = 0; j E<lt> 2; j++)\n"
7268 "        malloc(100);            /* Never freed--a memory leak */\n"
7269
7270 #. type: Plain text
7271 #: build/C/man3/mtrace.3:136
7272 #, no-wrap
7273 msgid ""
7274 "    calloc(16, 16);             /* Never freed--a memory leak */\n"
7275 "    exit(EXIT_SUCCESS);\n"
7276 "}\n"
7277 msgstr ""
7278 "    calloc(16, 16);             /* Never freed--a memory leak */\n"
7279 "    exit(EXIT_SUCCESS);\n"
7280 "}\n"
7281
7282 #. type: Plain text
7283 #: build/C/man3/mtrace.3:142
7284 msgid ""
7285 "When we run the program as follows, we see that B<mtrace>()  diagnosed "
7286 "memory leaks at two different locations in the program:"
7287 msgstr ""
7288
7289 #. type: Plain text
7290 #: build/C/man3/mtrace.3:155
7291 #, no-wrap
7292 msgid ""
7293 "$ B<cc -g t_mtrace.c -o t_mtrace>\n"
7294 "$ B<export MALLOC_TRACE=/tmp/t>\n"
7295 "$ B<./t_mtrace>\n"
7296 "$ B<mtrace ./t_mtrace $MALLOC_TRACE>\n"
7297 "Memory not freed:\n"
7298 "-----------------\n"
7299 "   Address     Size     Caller\n"
7300 "0x084c9378     0x64  at /home/cecilia/t_mtrace.c:12\n"
7301 "0x084c93e0     0x64  at /home/cecilia/t_mtrace.c:12\n"
7302 "0x084c9448    0x100  at /home/cecilia/t_mtrace.c:16\n"
7303 msgstr ""
7304 "$ B<cc -g t_mtrace.c -o t_mtrace>\n"
7305 "$ B<export MALLOC_TRACE=/tmp/t>\n"
7306 "$ B<./t_mtrace>\n"
7307 "$ B<mtrace ./t_mtrace $MALLOC_TRACE>\n"
7308 "Memory not freed:\n"
7309 "-----------------\n"
7310 "   Address     Size     Caller\n"
7311 "0x084c9378     0x64  at /home/cecilia/t_mtrace.c:12\n"
7312 "0x084c93e0     0x64  at /home/cecilia/t_mtrace.c:12\n"
7313 "0x084c9448    0x100  at /home/cecilia/t_mtrace.c:16\n"
7314
7315 #. type: Plain text
7316 #: build/C/man3/mtrace.3:167
7317 msgid ""
7318 "The first two messages about unfreed memory correspond to the two B<malloc>"
7319 "(3)  calls inside the I<for> loop.  The final message corresponds to the "
7320 "call to B<calloc>(3)  (which in turn calls B<malloc>(3))."
7321 msgstr ""
7322
7323 #. type: Plain text
7324 #: build/C/man3/mtrace.3:172
7325 msgid "B<mtrace>(1), B<malloc>(3), B<malloc_hook>(3), B<mcheck>(3)"
7326 msgstr "B<mtrace>(1), B<malloc>(3), B<malloc_hook>(3), B<mcheck>(3)"
7327
7328 #. type: TH
7329 #: build/C/man2/posix_fadvise.2:28
7330 #, no-wrap
7331 msgid "POSIX_FADVISE"
7332 msgstr "POSIX_FADVISE"
7333
7334 #. type: TH
7335 #: build/C/man2/posix_fadvise.2:28 build/C/man2/sync_file_range.2:30
7336 #, no-wrap
7337 msgid "2013-04-01"
7338 msgstr "2013-04-01"
7339
7340 #. type: Plain text
7341 #: build/C/man2/posix_fadvise.2:31
7342 msgid "posix_fadvise - predeclare an access pattern for file data"
7343 msgstr "posix_fadvise - ファイルデータのアクセスパターンをあらかじめ宣言する"
7344
7345 #. type: Plain text
7346 #: build/C/man2/posix_fadvise.2:34 build/C/man3/posix_fallocate.3:31
7347 #, no-wrap
7348 msgid "B<#include E<lt>fcntl.hE<gt>>\n"
7349 msgstr "B<#include E<lt>fcntl.hE<gt>>\n"
7350
7351 #. type: Plain text
7352 #: build/C/man2/posix_fadvise.2:37
7353 #, no-wrap
7354 msgid "B<int posix_fadvise(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<, int >I<advice>B<);>\n"
7355 msgstr "B<int posix_fadvise(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<, int >I<advice>B<);>\n"
7356
7357 #. type: Plain text
7358 #: build/C/man2/posix_fadvise.2:46
7359 msgid "B<posix_fadvise>():"
7360 msgstr "B<posix_fadvise>():"
7361
7362 #. type: Plain text
7363 #: build/C/man2/posix_fadvise.2:48 build/C/man3/posix_fallocate.3:44
7364 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
7365 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
7366
7367 #. type: Plain text
7368 #: build/C/man2/posix_fadvise.2:56
7369 msgid ""
7370 "Programs can use B<posix_fadvise>()  to announce an intention to access file "
7371 "data in a specific pattern in the future, thus allowing the kernel to "
7372 "perform appropriate optimizations."
7373 msgstr ""
7374 "プログラムは、将来特定のパターンでファイルデータに アクセスする意思を伝えるた"
7375 "めに B<posix_fadvise>()  を使うことができる。 これにより、カーネルが適切な最"
7376 "適化を実行することが可能になる。"
7377
7378 #. type: Plain text
7379 #: build/C/man2/posix_fadvise.2:63
7380 msgid ""
7381 "The I<advice> applies to a (not necessarily existent) region starting at "
7382 "I<offset> and extending for I<len> bytes (or until the end of the file if "
7383 "I<len> is 0) within the file referred to by I<fd>.  The I<advice> is not "
7384 "binding; it merely constitutes an expectation on behalf of the application."
7385 msgstr ""
7386 "I<advice> は I<fd> が参照しているファイルの I<offset> から始まる I<len> バ"
7387 "イ\n"
7388 "トの範囲内 (I<len> が 0 の場合はファイルの終りまで) の (必ずしも存在しない)\n"
7389 "領域に適用される。 I<advice> は義務づけではない。 I<advice> は単にアプリ"
7390 "ケー\n"
7391 "ションのために可能性を構成するだけである。"
7392
7393 #. type: Plain text
7394 #: build/C/man2/posix_fadvise.2:65
7395 msgid "Permissible values for I<advice> include:"
7396 msgstr "I<advice> に許される値には、以下のものが含まれる:"
7397
7398 #. type: TP
7399 #: build/C/man2/posix_fadvise.2:65
7400 #, no-wrap
7401 msgid "B<POSIX_FADV_NORMAL>"
7402 msgstr "B<POSIX_FADV_NORMAL>"
7403
7404 #. type: Plain text
7405 #: build/C/man2/posix_fadvise.2:71
7406 msgid ""
7407 "Indicates that the application has no advice to give about its access "
7408 "pattern for the specified data.  If no advice is given for an open file, "
7409 "this is the default assumption."
7410 msgstr ""
7411 "指定されたデータのアクセスパターンを指示するアドバイスを アプリケーションが何"
7412 "も持っていないことを示す。 オープンされたファイルにアドバイスが指定されない場"
7413 "合、 これがデフォルトで仮定される。"
7414
7415 #. type: TP
7416 #: build/C/man2/posix_fadvise.2:71
7417 #, no-wrap
7418 msgid "B<POSIX_FADV_SEQUENTIAL>"
7419 msgstr "B<POSIX_FADV_SEQUENTIAL>"
7420
7421 #. type: Plain text
7422 #: build/C/man2/posix_fadvise.2:75
7423 msgid ""
7424 "The application expects to access the specified data sequentially (with "
7425 "lower offsets read before higher ones)."
7426 msgstr ""
7427 "アプリケーションは指定されたデータがシーケンシャルに (大きなオフセットの前に"
7428 "小さなオフセットのデータを読むように)  アクセスされることを期待する。"
7429
7430 #. type: TP
7431 #: build/C/man2/posix_fadvise.2:75
7432 #, no-wrap
7433 msgid "B<POSIX_FADV_RANDOM>"
7434 msgstr "B<POSIX_FADV_RANDOM>"
7435
7436 #. type: Plain text
7437 #: build/C/man2/posix_fadvise.2:78
7438 msgid "The specified data will be accessed in random order."
7439 msgstr "指定されたデータがランダムな順番でアクセスされる。"
7440
7441 #. type: TP
7442 #: build/C/man2/posix_fadvise.2:78
7443 #, no-wrap
7444 msgid "B<POSIX_FADV_NOREUSE>"
7445 msgstr "B<POSIX_FADV_NOREUSE>"
7446
7447 #. type: Plain text
7448 #: build/C/man2/posix_fadvise.2:81
7449 msgid "The specified data will be accessed only once."
7450 msgstr "指定されたデータは 1 度しかアクセスされない。"
7451
7452 #. type: TP
7453 #: build/C/man2/posix_fadvise.2:81
7454 #, no-wrap
7455 msgid "B<POSIX_FADV_WILLNEED>"
7456 msgstr "B<POSIX_FADV_WILLNEED>"
7457
7458 #. type: Plain text
7459 #: build/C/man2/posix_fadvise.2:84
7460 msgid "The specified data will be accessed in the near future."
7461 msgstr "指定されたデータは近い将来アクセスされる。"
7462
7463 #. type: TP
7464 #: build/C/man2/posix_fadvise.2:84
7465 #, no-wrap
7466 msgid "B<POSIX_FADV_DONTNEED>"
7467 msgstr "B<POSIX_FADV_DONTNEED>"
7468
7469 #. type: Plain text
7470 #: build/C/man2/posix_fadvise.2:87
7471 msgid "The specified data will not be accessed in the near future."
7472 msgstr "指定されたデータは近い将来アクセスされない。"
7473
7474 #. type: Plain text
7475 #: build/C/man2/posix_fadvise.2:90
7476 msgid "On success, zero is returned.  On error, an error number is returned."
7477 msgstr "成功した場合は 0 が返される。 失敗した場合はエラー番号が返される。"
7478
7479 #. type: Plain text
7480 #: build/C/man2/posix_fadvise.2:94
7481 msgid "The I<fd> argument was not a valid file descriptor."
7482 msgstr "I<fd> 引き数が有効なファイルディスクリプタでない。"
7483
7484 #. type: Plain text
7485 #: build/C/man2/posix_fadvise.2:97
7486 msgid "An invalid value was specified for I<advice>."
7487 msgstr "無効な値が I<advice> に指定された。"
7488
7489 #. type: Plain text
7490 #: build/C/man2/posix_fadvise.2:104
7491 msgid ""
7492 "The specified file descriptor refers to a pipe or FIFO.  (Linux actually "
7493 "returns B<EINVAL> in this case.)"
7494 msgstr ""
7495 "指定されたファイルディスクリプタがパイプまたは FIFO を参照している (この場"
7496 "合、Linux は実際には B<EINVAL> を返す)。"
7497
7498 #.  of fadvise64_64()
7499 #. type: Plain text
7500 #: build/C/man2/posix_fadvise.2:112
7501 msgid ""
7502 "Kernel support first appeared in Linux 2.5.60; the underlying system call is "
7503 "called B<fadvise64>().  Library support has been provided since glibc "
7504 "version 2.2, via the wrapper function B<posix_fadvise>()."
7505 msgstr ""
7506 "カーネルによるサポートは Linux 2.5.60 で最初に登場し、\n"
7507 "対応するシステムコールは B<fadvise64>() という名前である。\n"
7508 "ライブラリによるサポートは glibc バージョン 2.2 以降で提供されており、\n"
7509 "ラッパー関数は B<posix_fadvise>() という名前である。"
7510
7511 #. type: Plain text
7512 #: build/C/man2/posix_fadvise.2:121
7513 msgid ""
7514 "POSIX.1-2001.  Note that the type of the I<len> argument was changed from "
7515 "I<size_t> to I<off_t> in POSIX.1-2003 TC1."
7516 msgstr ""
7517 "POSIX.1-2001.  I<len> 引き数の型が POSIX.1-2003 TC1 において I<size_t> から "
7518 "I<off_t> に変更された点に注意すること。"
7519
7520 #. type: Plain text
7521 #: build/C/man2/posix_fadvise.2:127
7522 msgid ""
7523 "Under Linux, B<POSIX_FADV_NORMAL> sets the readahead window to the default "
7524 "size for the backing device; B<POSIX_FADV_SEQUENTIAL> doubles this size, and "
7525 "B<POSIX_FADV_RANDOM> disables file readahead entirely.  These changes affect "
7526 "the entire file, not just the specified region (but other open file handles "
7527 "to the same file are unaffected)."
7528 msgstr ""
7529 "Linux では、B<POSIX_FADV_NORMAL> はバッキングデバイスの デフォルトサイズに先"
7530 "読み (readahead) ウインドウを設定する。 B<POSIX_FADV_SEQUENTIAL> はこのサイズ"
7531 "を 2 倍し、 B<POSIX_FADV_RANDOM> は先読みを全く無効にする。 これらの変更は"
7532 "ファイル全体に影響し、指定された領域のみに影響するわけではない (しかし同じ"
7533 "ファイルに対する他のオープンファイルハンドルは影響を受けない)。"
7534
7535 #. type: Plain text
7536 #: build/C/man2/posix_fadvise.2:134
7537 msgid ""
7538 "B<POSIX_FADV_WILLNEED> initiates a nonblocking read of the specified region "
7539 "into the page cache.  The amount of data read may be decreased by the kernel "
7540 "depending on virtual memory load.  (A few megabytes will usually be fully "
7541 "satisfied, and more is rarely useful.)"
7542 msgstr ""
7543 "B<POSIX_FADV_WILLNEED> は、 ページキャッシュに指定領域のブロックされない読み"
7544 "込みを開始する。 読み込まれるデータの総量は、 仮想メモリの負荷に依ってカーネ"
7545 "ルが減らすかもしれない (数メガバイトであれば通常は全く十分であり、 それより多"
7546 "くてもめったに役に立たない)。"
7547
7548 #. type: Plain text
7549 #: build/C/man2/posix_fadvise.2:138
7550 msgid ""
7551 "In kernels before 2.6.18, B<POSIX_FADV_NOREUSE> had the same semantics as "
7552 "B<POSIX_FADV_WILLNEED>.  This was probably a bug; since kernel 2.6.18, this "
7553 "flag is a no-op."
7554 msgstr ""
7555 "2.6.18 より前のカーネルでは、B<POSIX_FADV_NOREUSE> は B<POSIX_FADV_WILLNEED> "
7556 "と同じ意味であった。 これは多分バグであった。 カーネル 2.6.18 以降では、この"
7557 "フラグは何も行わない。"
7558
7559 #. type: Plain text
7560 #: build/C/man2/posix_fadvise.2:146
7561 msgid ""
7562 "B<POSIX_FADV_DONTNEED> attempts to free cached pages associated with the "
7563 "specified region.  This is useful, for example, while streaming large "
7564 "files.  A program may periodically request the kernel to free cached data "
7565 "that has already been used, so that more useful cached pages are not "
7566 "discarded instead."
7567 msgstr ""
7568 "B<POSIX_FADV_DONTNEED> は指定された領域に関連付けられた キャッシュページを解"
7569 "放しようとする。 例えば、これは大きなファイルをストリーミングするときに役立"
7570 "つ。 プログラムは、使用済みのキャッシュされたデータを解放するように、 定期的"
7571 "にカーネルに要求するかもしれない。 そうすることにより、さらに有効なキャッシュ"
7572 "されたページが、 代わりに破棄されることはない。"
7573
7574 #. type: Plain text
7575 #: build/C/man2/posix_fadvise.2:154
7576 msgid ""
7577 "Pages that have not yet been written out will be unaffected, so if the "
7578 "application wishes to guarantee that pages will be released, it should call "
7579 "B<fsync>(2)  or B<fdatasync>(2)  first."
7580 msgstr ""
7581 "まだ書き出されていないページは影響を受けないので、 そのページの解放が保証され"
7582 "ることをアプリケーションが望んでいるなら、 最初に B<fsync>(2)  または "
7583 "B<fdatasync>(2)  を呼ぶべきである。"
7584
7585 #. type: SS
7586 #: build/C/man2/posix_fadvise.2:154
7587 #, no-wrap
7588 msgid "Architecture-specific variants"
7589 msgstr "アーキテクチャ固有の派生バージョン"
7590
7591 #. type: Plain text
7592 #: build/C/man2/posix_fadvise.2:171
7593 msgid ""
7594 "Some architectures require 64-bit arguments to be aligned in a suitable pair "
7595 "of registers (see B<syscall>(2)  for further detail).  On such "
7596 "architectures, the call signature of B<posix_fadvise>()  shown in the "
7597 "SYNOPSIS would force a register to be wasted as padding between the I<fd> "
7598 "and I<len> arguments.  Therefore, these architectures define a version of "
7599 "the system call that orders the arguments suitably, but otherwise is "
7600 "otherwise exactly the same as B<posix_fadvise>()."
7601 msgstr ""
7602 "いくつかのアーキテクチャでは、 64 ビットの引き数は適切なレジスタの組に割り当"
7603 "てる必要がある (B<syscall>(2) 参照)。 このようなアーキテクチャでは、 「書式」"
7604 "に書かれている  B<posix_fadvise>() の呼び出しシグネチャーで、 引き数 I<fd> "
7605 "と I<offset> の間のパディング (詰めもの) でレジスタが一つ消費されてしまう。 "
7606 "そのため、 これらのアーキテクチャでは引き数が適切な順序になった別のシステム"
7607 "コールが定義されているが、 それ以外は B<posix_fadvise>() と全く同じである。"
7608
7609 #. type: Plain text
7610 #: build/C/man2/posix_fadvise.2:173
7611 msgid "For example, since Linux 2.6.14, ARM has the following system call:"
7612 msgstr ""
7613 "例えば、 Linux 2.6.14 以降では、 ARM には以下のシステムコールが存在する。"
7614
7615 #. type: Plain text
7616 #: build/C/man2/posix_fadvise.2:178
7617 #, no-wrap
7618 msgid ""
7619 "B<long arm_fadvise64_64(int >I<fd>B<, int >I<advice>B<,>\n"
7620 "B<                      loff_t >I<offset>B<, loff_t >I<len>B<);>\n"
7621 msgstr ""
7622 "B<long arm_fadvise64_64(int >I<fd>B<, int >I<advice>B<,>\n"
7623 "B<                      loff_t >I<offset>B<, loff_t >I<len>B<);>\n"
7624
7625 #. type: Plain text
7626 #: build/C/man2/posix_fadvise.2:186
7627 msgid ""
7628 "These architecture-specific details are generally hidden from applications "
7629 "by the glibc B<posix_fadvise>()  wrapper function, which invokes the "
7630 "appropriate architecture-specific system call."
7631 msgstr ""
7632 "通常、 glibc の B<posix_fadvise>() ラッパー関数により、 これらのアーキテク"
7633 "チャ固有の詳細はアプリケーションには見えない。 glibc のラッパー関数では、適切"
7634 "なアーキテクチャ固有のシステムコールが呼び出される。"
7635
7636 #. type: Plain text
7637 #: build/C/man2/posix_fadvise.2:191
7638 msgid ""
7639 "In kernels before 2.6.6, if I<len> was specified as 0, then this was "
7640 "interpreted literally as \"zero bytes\", rather than as meaning \"all bytes "
7641 "through to the end of the file\"."
7642 msgstr ""
7643 "2.6.6 より前のカーネルでは、 I<len> に 0 が指定された場合、 「ファイルの終り"
7644 "までの全てのバイト」という意味ではなく、 文字通り「0 バイト」として解釈されて"
7645 "いた。"
7646
7647 #.  FIXME . Write a posix_fadvise(3) page.
7648 #. type: Plain text
7649 #: build/C/man2/posix_fadvise.2:197
7650 msgid ""
7651 "B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3), "
7652 "B<posix_madvise>(3)"
7653 msgstr ""
7654 "B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3),\n"
7655 "B<posix_madvise>(3)"
7656
7657 #. type: TH
7658 #: build/C/man3/posix_fallocate.3:25
7659 #, no-wrap
7660 msgid "POSIX_FALLOCATE"
7661 msgstr "POSIX_FALLOCATE"
7662
7663 #. type: TH
7664 #: build/C/man3/posix_fallocate.3:25 build/C/man2/shmop.2:41
7665 #, no-wrap
7666 msgid "2013-02-12"
7667 msgstr "2013-02-12"
7668
7669 #. type: Plain text
7670 #: build/C/man3/posix_fallocate.3:28
7671 msgid "posix_fallocate - allocate file space"
7672 msgstr "posix_fallocate - ファイルのスペースを確保する"
7673
7674 #. type: Plain text
7675 #: build/C/man3/posix_fallocate.3:33
7676 #, no-wrap
7677 msgid "B<int posix_fallocate(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
7678 msgstr "B<int posix_fallocate(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
7679
7680 #. type: Plain text
7681 #: build/C/man3/posix_fallocate.3:42
7682 msgid "B<posix_fallocate>():"
7683 msgstr "B<posix_fallocate>():"
7684
7685 #. type: Plain text
7686 #: build/C/man3/posix_fallocate.3:61
7687 msgid ""
7688 "The function B<posix_fallocate>()  ensures that disk space is allocated for "
7689 "the file referred to by the descriptor I<fd> for the bytes in the range "
7690 "starting at I<offset> and continuing for I<len> bytes.  After a successful "
7691 "call to B<posix_fallocate>(), subsequent writes to bytes in the specified "
7692 "range are guaranteed not to fail because of lack of disk space."
7693 msgstr ""
7694 "関数 B<posix_fallocate>()  は、ディスクリプタ I<fd> で参照されるファイルに対"
7695 "して、ディスクスペースを確実に確保する。 ディスクスペースは I<offset> から始"
7696 "まる I<len> バイトの範囲のバイトである。 B<posix_fallocate>()  の呼び出しが成"
7697 "功した後、指定された範囲のバイトに対する書き込みは、 ディスクスペースの不足で"
7698 "失敗しないことが保証される。"
7699
7700 #. type: Plain text
7701 #: build/C/man3/posix_fallocate.3:66
7702 msgid ""
7703 "If the size of the file is less than I<offset>+I<len>, then the file is "
7704 "increased to this size; otherwise the file size is left unchanged."
7705 msgstr ""
7706 "ファイルのサイズが I<offset>+I<len> より小さい場合、ファイルはこのサイズにな"
7707 "るように拡大される。 それ以外の場合、ファイルサイズは変わらない。"
7708
7709 #. type: Plain text
7710 #: build/C/man3/posix_fallocate.3:72
7711 msgid ""
7712 "B<posix_fallocate>()  returns zero on success, or an error number on "
7713 "failure.  Note that I<errno> is not set."
7714 msgstr ""
7715 "B<posix_fallocate>()  は成功した場合、0 を返す。 失敗した場合、エラー番号を返"
7716 "す。 I<errno> が設定されない点に注意すること。"
7717
7718 #. type: Plain text
7719 #: build/C/man3/posix_fallocate.3:81
7720 msgid "I<offset+len> exceeds the maximum file size."
7721 msgstr "I<offset+len> が最大ファイルサイズを超えている。"
7722
7723 #. type: Plain text
7724 #: build/C/man3/posix_fallocate.3:91
7725 msgid "I<fd> does not refer to a regular file."
7726 msgstr "I<fd> が通常のファイルとして参照されていない。"
7727
7728 #. type: Plain text
7729 #: build/C/man3/posix_fallocate.3:100
7730 msgid "I<fd> refers to a pipe."
7731 msgstr "I<fd> がパイプを参照している。"
7732
7733 #. type: Plain text
7734 #: build/C/man3/posix_fallocate.3:103
7735 msgid "B<posix_fallocate>()  is available since glibc 2.1.94."
7736 msgstr "B<posix_fallocate>()  は glibc 2.1.94 以降で利用可能である。"
7737
7738 #. type: Plain text
7739 #: build/C/man3/posix_fallocate.3:128
7740 msgid ""
7741 "POSIX.1-2008 says that an implementation I<shall> give the B<EINVAL> error "
7742 "if I<len> was 0, or I<offset> was less than 0.  POSIX.1-2001 says that an "
7743 "implementation I<shall> give the B<EINVAL> error if I<len> is less than 0, "
7744 "or I<offset> was less than 0, and I<may> give the error if I<len> equals "
7745 "zero."
7746 msgstr ""
7747 "POSIX.1-2008 では、 I<len> が 0 の場合、もしくは I<offset> が 0 未満の場合、 "
7748 "B<EINVAL> エラーを返すものとされている。 POSIX.1-2001 では、 I<len> が 0 未満"
7749 "の場合、もしくは I<offset> が 0 未満の場合、 B<EINVAL> エラーを返すものとされ"
7750 "ている。また、 I<len> が 0 の場合、 B<EINVAL> エラーを返してもよいとされてい"
7751 "る。"
7752
7753 #. type: Plain text
7754 #: build/C/man3/posix_fallocate.3:133
7755 msgid "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
7756 msgstr "B<fallocate>(1), B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
7757
7758 #. type: TH
7759 #: build/C/man3/posix_memalign.3:29
7760 #, no-wrap
7761 msgid "POSIX_MEMALIGN"
7762 msgstr "POSIX_MEMALIGN"
7763
7764 #. type: TH
7765 #: build/C/man3/posix_memalign.3:29
7766 #, no-wrap
7767 msgid "2013-09-02"
7768 msgstr "2013-09-02"
7769
7770 #. type: Plain text
7771 #: build/C/man3/posix_memalign.3:32
7772 msgid ""
7773 "posix_memalign, aligned_alloc, memalign, valloc, pvalloc - allocate aligned "
7774 "memory"
7775 msgstr ""
7776 "posix_memalign, aligned_alloc, memalign, valloc, pvalloc - アラインメント\n"
7777 "されたメモリの割り当てを行う"
7778
7779 #. type: Plain text
7780 #: build/C/man3/posix_memalign.3:39
7781 #, no-wrap
7782 msgid ""
7783 "B<int posix_memalign(void **>I<memptr>B<, size_t >I<alignment>B<, size_t >I<size>B<);>\n"
7784 "B<void *aligned_alloc(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
7785 "B<void *valloc(size_t >I<size>B<);>\n"
7786 msgstr ""
7787 "B<int posix_memalign(void **>I<memptr>B<, size_t >I<alignment>B<, size_t >I<size>B<);>\n"
7788 "B<void *aligned_alloc(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
7789 "B<void *valloc(size_t >I<size>B<);>\n"
7790
7791 #. type: Plain text
7792 #: build/C/man3/posix_memalign.3:44
7793 #, no-wrap
7794 msgid ""
7795 "B<void *memalign(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
7796 "B<void *pvalloc(size_t >I<size>B<);>\n"
7797 msgstr ""
7798 "B<void *memalign(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
7799 "B<void *pvalloc(size_t >I<size>B<);>\n"
7800
7801 #. type: Plain text
7802 #: build/C/man3/posix_memalign.3:54
7803 msgid ""
7804 "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
7805 "E<gt>=\\ 600"
7806 msgstr ""
7807 "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
7808 "E<gt>=\\ 600"
7809
7810 #. type: Plain text
7811 #: build/C/man3/posix_memalign.3:57
7812 msgid "B<aligned_alloc>(): _ISOC11_SOURCE"
7813 msgstr "B<aligned_alloc>(): _ISOC11_SOURCE"
7814
7815 #. type: Plain text
7816 #: build/C/man3/posix_memalign.3:59
7817 msgid "B<valloc>():"
7818 msgstr "B<valloc>():"
7819
7820 #. type: TP
7821 #: build/C/man3/posix_memalign.3:62
7822 #, no-wrap
7823 msgid "Since glibc 2.12:"
7824 msgstr "glibc 2.12 以降:"
7825
7826 #. type: Plain text
7827 #: build/C/man3/posix_memalign.3:69
7828 #, no-wrap
7829 msgid ""
7830 "_BSD_SOURCE ||\n"
7831 "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
7832 "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
7833 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
7834 msgstr ""
7835 "_BSD_SOURCE ||\n"
7836 "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
7837 "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
7838 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
7839
7840 #. type: TP
7841 #: build/C/man3/posix_memalign.3:71
7842 #, no-wrap
7843 msgid "Before glibc 2.12:"
7844 msgstr "glibc 2.12 より前:"
7845
7846 #. type: Plain text
7847 #: build/C/man3/posix_memalign.3:75
7848 msgid ""
7849 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
7850 "_XOPEN_SOURCE_EXTENDED"
7851 msgstr ""
7852 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
7853 "_XOPEN_SOURCE_EXTENDED"
7854
7855 #. type: Plain text
7856 #: build/C/man3/posix_memalign.3:82
7857 msgid ""
7858 "(The (nonstandard) header file I<E<lt>malloc.hE<gt>> also exposes the "
7859 "declaration of B<valloc>(); no feature test macros are required.)"
7860 msgstr ""
7861 "((非標準の) ヘッダファイル I<E<lt>malloc.hE<gt>> も\n"
7862 "B<valloc>() の宣言も公開する。機能検査マクロは不要である。"
7863
7864 #.  glibc does this:
7865 #. type: Plain text
7866 #: build/C/man3/posix_memalign.3:104
7867 msgid ""
7868 "The function B<posix_memalign>()  allocates I<size> bytes and places the "
7869 "address of the allocated memory in I<*memptr>.  The address of the allocated "
7870 "memory will be a multiple of I<alignment>, which must be a power of two and "
7871 "a multiple of I<sizeof(void\\ *)>.  If I<size> is 0, then the value placed "
7872 "in I<*memptr> is either NULL, or a unique pointer value that can later be "
7873 "successfully passed to B<free>(3)."
7874 msgstr ""
7875 "関数 B<posix_memalign>()  は、 I<size> バイトのメモリを割り当て、割り当てられ"
7876 "たメモリのアドレスを I<*memptr> に設定する。 割り当てられたメモリのアドレス"
7877 "は I<alignment> の倍数になっているはずである。 I<alignment> は 2 のべき乗で、"
7878 "かつ I<sizeof(void\\ *)> の倍数でなければならない。 I<size> が 0 の場合、 "
7879 "I<*memptr> には NULL か一意なポインタ値が書かれる。 このポインタ値は、後で "
7880 "B<free>(3)  に問題なく渡すことができる。"
7881
7882 #.  The behavior of memalign() for size==0 is as for posix_memalign()
7883 #.  but no standards govern this.
7884 #. type: Plain text
7885 #: build/C/man3/posix_memalign.3:115
7886 msgid ""
7887 "The obsolete function B<memalign>()  allocates I<size> bytes and returns a "
7888 "pointer to the allocated memory.  The memory address will be a multiple of "
7889 "I<alignment>, which must be a power of two."
7890 msgstr ""
7891 "廃止された関数である B<memalign>() は、 I<size> バイトのメモリを割り当て、\n"
7892 "割り当てられたメモリへのポインタを返す。 メモリのアドレスは I<alignment> \n"
7893 "の倍数になっているはずである。 I<alignment> は 2 のべき乗でなければならない。"
7894
7895 #. type: Plain text
7896 #: build/C/man3/posix_memalign.3:124
7897 msgid ""
7898 "The function B<aligned_alloc>()  is the same as B<memalign>(), except for "
7899 "the added restriction that I<size> should be a multiple of I<alignment>."
7900 msgstr ""
7901 "関数 B<aligned_alloc>() は B<memalign>() と同じだが、I<size> が "
7902 "I<alignment>\n"
7903 "の倍数でなければならないという追加の制限がある点が異なる。"
7904
7905 #. type: Plain text
7906 #: build/C/man3/posix_memalign.3:133
7907 msgid ""
7908 "The obsolete function B<valloc>()  allocates I<size> bytes and returns a "
7909 "pointer to the allocated memory.  The memory address will be a multiple of "
7910 "the page size.  It is equivalent to I<memalign(sysconf(_SC_PAGESIZE),size)>."
7911 msgstr ""
7912 "廃止された関数である B<valloc>()  は I<size> バイトのメモリを割り当て、割り当"
7913 "てられたメモリへのポインタを返す。 メモリのアドレスはページサイズの倍数になっ"
7914 "ているはずである。 これは I<memalign(sysconf(_SC_PAGESIZE),size)> と等価であ"
7915 "る。"
7916
7917 #. type: Plain text
7918 #: build/C/man3/posix_memalign.3:140
7919 msgid ""
7920 "The obsolete function B<pvalloc>()  is similar to B<valloc>(), but rounds "
7921 "the size of the allocation up to the next multiple of the system page size."
7922 msgstr ""
7923 "廃止された関数 B<pvalloc>() は B<valloc>() と同様だが、\n"
7924 "割り当てられるサイズがシステムのページサイズの倍数に切り上げられる。"
7925
7926 #. type: Plain text
7927 #: build/C/man3/posix_memalign.3:142
7928 msgid "For all of these functions, the memory is not zeroed."
7929 msgstr "これらの関数はいずれもメモリのゼロクリアを行わない。"
7930
7931 #. type: Plain text
7932 #: build/C/man3/posix_memalign.3:149
7933 msgid ""
7934 "B<aligned_alloc>(), B<memalign>(), B<valloc>(), and B<pvalloc>()  return a "
7935 "pointer to the allocated memory, or NULL if the request fails."
7936 msgstr ""
7937 "B<aligned_alloc>(), B<memalign>(), B<valloc>(), B<pvalloc>() は割り当てられ"
7938 "た\n"
7939 "メモリへのポインタを返す。 割り当てに失敗した場合は NULL を返す。"
7940
7941 #. type: Plain text
7942 #: build/C/man3/posix_memalign.3:157
7943 msgid ""
7944 "B<posix_memalign>()  returns zero on success, or one of the error values "
7945 "listed in the next section on failure.  The value of I<errno> is "
7946 "indeterminate after a call to B<posix_memalign>()."
7947 msgstr ""
7948 "B<posix_memalign>()  は成功した場合は 0 を返し、 失敗した場合は次のセクション"
7949 "に記載されたエラー値のいずれかを返す。 B<posix_memalign>() の呼び出し後は "
7950 "I<errno> の値は不定である。"
7951
7952 #. type: Plain text
7953 #: build/C/man3/posix_memalign.3:164
7954 msgid ""
7955 "The I<alignment> argument was not a power of two, or was not a multiple of "
7956 "I<sizeof(void\\ *)>."
7957 msgstr ""
7958 "I<alignment> 引き数が 2 のべき乗でなかったか、 I<sizeof(void\\ *)> の倍数でな"
7959 "かった。"
7960
7961 #. type: Plain text
7962 #: build/C/man3/posix_memalign.3:167
7963 msgid "There was insufficient memory to fulfill the allocation request."
7964 msgstr "割り当て要求を満たすのに十分なメモリがなかった。"
7965
7966 #. type: Plain text
7967 #: build/C/man3/posix_memalign.3:174
7968 msgid ""
7969 "The functions B<memalign>(), B<valloc>(), and B<pvalloc>()  have been "
7970 "available in all Linux libc libraries."
7971 msgstr ""
7972 "関数 B<memalign>(), B<valloc>(), B<pvalloc>() は\n"
7973 "すべての Linux libc ライブラリで使用可能である。"
7974
7975 #. type: Plain text
7976 #: build/C/man3/posix_memalign.3:178
7977 msgid "The function B<aligned_alloc>()  was added to glibc in version 2.16."
7978 msgstr "関数 B<aligned_alloc>() は glibc バージョン 2.16 で追加された。"
7979
7980 #. type: Plain text
7981 #: build/C/man3/posix_memalign.3:182
7982 msgid "The function B<posix_memalign>()  is available since glibc 2.1.91."
7983 msgstr "関数 B<posix_fallocate>() は glibc 2.1.91 以降で利用可能である。"
7984
7985 #. type: Plain text
7986 #: build/C/man3/posix_memalign.3:189
7987 msgid ""
7988 "The function B<valloc>()  appeared in 3.0BSD.  It is documented as being "
7989 "obsolete in 4.3BSD, and as legacy in SUSv2.  It does not appear in "
7990 "POSIX.1-2001."
7991 msgstr ""
7992 "関数 B<valloc>() は 3.0BSD で登場した。4.3BSD では廃止されたと記載されてお"
7993 "り、\n"
7994 "SUSv2 では過去の名残だと記載されている。 POSIX.1-2001 には存在しない。"
7995
7996 #. type: Plain text
7997 #: build/C/man3/posix_memalign.3:193
7998 msgid "The function B<pvalloc>()  is a GNU extension."
7999 msgstr "関数 B<pvalloc>() は GNU による拡張である。"
8000
8001 #. type: Plain text
8002 #: build/C/man3/posix_memalign.3:197
8003 msgid "The function B<memalign>()  appears in SunOS 4.1.3 but not in 4.4BSD."
8004 msgstr "関数 B<memalign>() は SunOS 4.1.3 で登場したが、4.4BSD にはない。"
8005
8006 #. type: Plain text
8007 #: build/C/man3/posix_memalign.3:201
8008 msgid "The function B<posix_memalign>()  comes from POSIX.1d."
8009 msgstr "関数 B<posix_memalign>() は POSIX.1d に由来する。"
8010
8011 #. type: Plain text
8012 #: build/C/man3/posix_memalign.3:206
8013 msgid "The function B<aligned_alloc>()  is specified in the C11 standard."
8014 msgstr "関数 I<aligned_alloc>() は C11 標準で規定されている。"
8015
8016 #. type: SS
8017 #: build/C/man3/posix_memalign.3:206
8018 #, no-wrap
8019 msgid "Headers"
8020 msgstr "ヘッダ"
8021
8022 #. type: Plain text
8023 #: build/C/man3/posix_memalign.3:210
8024 msgid ""
8025 "Everybody agrees that B<posix_memalign>()  is declared in I<E<lt>stdlib."
8026 "hE<gt>>."
8027 msgstr ""
8028 "B<posix_memalign>()  の宣言を I<E<lt>stdlib.hE<gt>> で行うことに関しては、 皆"
8029 "の意見が一致している。"
8030
8031 #. type: Plain text
8032 #: build/C/man3/posix_memalign.3:214
8033 msgid ""
8034 "On some systems B<memalign>()  is declared in I<E<lt>stdlib.hE<gt>> instead "
8035 "of I<E<lt>malloc.hE<gt>>."
8036 msgstr ""
8037 "いくつかのシステムでは、 B<memalign>()  は I<E<lt>malloc.hE<gt>> ではなく "
8038 "I<E<lt>stdlib.hE<gt>> で宣言されている。"
8039
8040 #. type: Plain text
8041 #: build/C/man3/posix_memalign.3:221
8042 msgid ""
8043 "According to SUSv2, B<valloc>()  is declared in I<E<lt>stdlib.hE<gt>>.  "
8044 "Libc4,5 and glibc declare it in I<E<lt>malloc.hE<gt>>, and also in "
8045 "I<E<lt>stdlib.hE<gt>> if suitable feature test macros are defined (see "
8046 "above)."
8047 msgstr ""
8048 "SUSv2 によると、 B<valloc>() は I<E<lt>stdlib.hE<gt>> で宣言される。 "
8049 "libc4,5\n"
8050 "や glibc では I<E<lt>malloc.hE<gt>> で宣言されており、 さらに適切な機能検査\n"
8051 "マクロが定義された場合には I<E<lt>stdlib.hE<gt>> でも宣言される(上記を参照)。"
8052
8053 #. type: Plain text
8054 #: build/C/man3/posix_memalign.3:230
8055 msgid ""
8056 "On many systems there are alignment restrictions, for example, on buffers "
8057 "used for direct block device I/O.  POSIX specifies the I<pathconf(path,"
8058 "_PC_REC_XFER_ALIGN)> call that tells what alignment is needed.  Now one can "
8059 "use B<posix_memalign>()  to satisfy this requirement."
8060 msgstr ""
8061 "多くのシステムでは、アラインメントに関して制限がある。例えば、 ブロックデバイ"
8062 "スに対するダイレクト I/O に使用するバッファには アラインメントに関する制限が"
8063 "ある。 POSIX では、どんなアラインメントが必要かを知るために I<pathconf(path,"
8064 "_PC_REC_XFER_ALIGN)> コールを規定している。ここで B<posix_memalign>()  を使う"
8065 "と、この必要条件を満たすことができる。"
8066
8067 #. type: Plain text
8068 #: build/C/man3/posix_memalign.3:239
8069 msgid ""
8070 "B<posix_memalign>()  verifies that I<alignment> matches the requirements "
8071 "detailed above.  B<memalign>()  may not check that the I<alignment> argument "
8072 "is correct."
8073 msgstr ""
8074 "B<posix_memalign>() は I<alignment> が上で詳細に述べた必要条件を満たすか\n"
8075 "どうかを確かめる。 B<memalign>() は I<alignment> 引き数が正しいかどうかの\n"
8076 "確認を行わないかもしれない。"
8077
8078 #.  Other systems allow passing the result of
8079 #.  .IR valloc ()
8080 #.  to
8081 #.  .IR free (3),
8082 #.  but not to
8083 #.  .IR realloc (3).
8084 #. type: Plain text
8085 #: build/C/man3/posix_memalign.3:267
8086 msgid ""
8087 "POSIX requires that memory obtained from B<posix_memalign>()  can be freed "
8088 "using B<free>(3).  Some systems provide no way to reclaim memory allocated "
8089 "with B<memalign>()  or B<valloc>()  (because one can pass to B<free>(3)  "
8090 "only a pointer obtained from B<malloc>(3), while, for example, B<memalign>"
8091 "()  would call B<malloc>(3)  and then align the obtained value).  The glibc "
8092 "implementation allows memory obtained from any of these functions to be "
8093 "reclaimed with B<free>(3)."
8094 msgstr ""
8095 "POSIX では B<posix_memalign>() によって獲得したメモリは B<free>(3) を\n"
8096 "使って解放することができる必要がある。 いくつかのシステムでは\n"
8097 "B<memalign>() やB<valloc>() で割り当てられたメモリを再利用する手段が\n"
8098 "提供されていない(なぜなら B<free>(3) に渡すことができるのは\n"
8099 "B<malloc>(3) から受け取ったポインタだけだが、例えば B<memalign>() は\n"
8100 "B<malloc>(3) を呼び出し、得た値をアラインメントしてしまうからである)。\n"
8101 "glibc の実装では、 ここに述べた関数のいずれで獲得したメモリも\n"
8102 "B<free>(3) で再利用することができる。"
8103
8104 #. type: Plain text
8105 #: build/C/man3/posix_memalign.3:272
8106 msgid ""
8107 "The glibc B<malloc>(3)  always returns 8-byte aligned memory addresses, so "
8108 "these functions are needed only if you require larger alignment values."
8109 msgstr ""
8110 "glibc の B<malloc>(3) は常に 8 バイトにアラインメントされたメモリアドレスを\n"
8111 "返すので、ここで述べた関数が必要になるのは 8 バイトよりも大きなアラインメン"
8112 "ト\n"
8113 "が必要な場合だけである。"
8114
8115 #. type: Plain text
8116 #: build/C/man3/posix_memalign.3:277
8117 msgid "B<brk>(2), B<getpagesize>(2), B<free>(3), B<malloc>(3)"
8118 msgstr "B<brk>(2), B<getpagesize>(2), B<free>(3), B<malloc>(3)"
8119
8120 #. type: TH
8121 #: build/C/man2/readahead.2:28
8122 #, no-wrap
8123 msgid "READAHEAD"
8124 msgstr "READAHEAD"
8125
8126 #. type: TH
8127 #: build/C/man2/readahead.2:28
8128 #, no-wrap
8129 msgid "2014-03-15"
8130 msgstr "2014-03-15"
8131
8132 #. type: Plain text
8133 #: build/C/man2/readahead.2:31
8134 msgid "readahead - initiate file readahead into page cache"
8135 msgstr "readahead - 前もってファイルをページ・キャッシュに読み込む"
8136
8137 #. type: Plain text
8138 #: build/C/man2/readahead.2:37
8139 #, no-wrap
8140 msgid "B<ssize_t readahead(int >I<fd>B<, off64_t >I<offset>B<, size_t >I<count>B<);>\n"
8141 msgstr "B<ssize_t readahead(int >I<fd>B<, off64_t >I<offset>B<, size_t >I<count>B<);>\n"
8142
8143 #. type: Plain text
8144 #: build/C/man2/readahead.2:44
8145 msgid ""
8146 "B<readahead>()  initiates readahead on a file so that subsequent reads from "
8147 "that file will be satisfied from the cache, and not block on disk I/O "
8148 "(assuming the readahead was initiated early enough and that other activity "
8149 "on the system did not in the meantime flush pages from the cache)."
8150 msgstr "B<readahead>() はファイルの先読みを行い、そのファイルに対する後の読み込みがキャッシュから行われ、ディスク I/O で停止しないようにする (この条件を満たせるのは、先読みは十分早く行われ、システムの他の動作によりその後にキャッシュからページがフラッシュされない場合である)。"
8151
8152 #. type: Plain text
8153 #: build/C/man2/readahead.2:66
8154 msgid ""
8155 "The I<fd> argument is a file descriptor identifying the file which is to be "
8156 "read.  The I<offset> argument specifies the starting point from which data "
8157 "is to be read and I<count> specifies the number of bytes to be read.  I/O is "
8158 "performed in whole pages, so that I<offset> is effectively rounded down to a "
8159 "page boundary and bytes are read up to the next page boundary greater than "
8160 "or equal to I<(offset+count)>.  B<readahead>()  does not read beyond the end "
8161 "of the file.  The current file offset of the open file referred to by I<fd> "
8162 "is left unchanged."
8163 msgstr ""
8164 "I<fd> 引き数は読み込みを行うファイルを識別するファイル・ディスクリプタであ"
8165 "る。 I<offset> 引き数はデータの読み込み開始位置を指定し、 I<count> は読み込む"
8166 "データのバイト数を指定する。 ディスク I/O はページ単位で実行されるので、 実際"
8167 "には I<offset> はページ境界に切り下げられ、読み込みバイト数は I<(offset"
8168 "+count)> より小さくない次のページ境界まで切り上げられる。 B<readahead>()  は"
8169 "ファイルの末尾を越えた範囲まで読み出しを行うことはない。 I<fd> で参照された"
8170 "オープン済のファイルのファイルオフセットの現在値は 変更されない。"
8171
8172 #. type: Plain text
8173 #: build/C/man2/readahead.2:72
8174 msgid ""
8175 "On success, B<readahead>()  returns 0; on failure, -1 is returned, with "
8176 "I<errno> set to indicate the cause of the error."
8177 msgstr ""
8178 "B<readahead>()  は成功すると 0 を返す。失敗した場合 -1 を返し、 I<errno> にエ"
8179 "ラーの原因を示す値を設定する。"
8180
8181 #. type: Plain text
8182 #: build/C/man2/readahead.2:77
8183 msgid "I<fd> is not a valid file descriptor or is not open for reading."
8184 msgstr ""
8185 "I<fd> が有効なファイル・ディスクリプタでない、または 読み込み用にオープンされ"
8186 "ていない。"
8187
8188 #. type: Plain text
8189 #: build/C/man2/readahead.2:83
8190 msgid ""
8191 "I<fd> does not refer to a file type to which B<readahead>()  can be applied."
8192 msgstr ""
8193 "I<fd> が参照しているファイルが、 B<readahead>()  を行うことができないタイプの"
8194 "ファイルであった。"
8195
8196 #. type: Plain text
8197 #: build/C/man2/readahead.2:88
8198 msgid ""
8199 "The B<readahead>()  system call appeared in Linux 2.4.13; glibc support has "
8200 "been provided since version 2.3."
8201 msgstr ""
8202 "B<readahead>()  システムコールは Linux 2.4.13 で登場した。 glibc でのサポート"
8203 "は glibc バージョン 2.3 以降で行われている。"
8204
8205 #. type: Plain text
8206 #: build/C/man2/readahead.2:93
8207 msgid ""
8208 "The B<readahead>()  system call is Linux-specific, and its use should be "
8209 "avoided in portable applications."
8210 msgstr ""
8211 "B<readahead>()  システムコールは Linux 固有であり、移植を考慮したプログラムで"
8212 "は 使用を避けるべきである。"
8213
8214 #. type: Plain text
8215 #: build/C/man2/readahead.2:98
8216 msgid ""
8217 "On some 32-bit architectures, the calling signature for this system call "
8218 "differs, for the reasons described in B<syscall>(2)."
8219 msgstr ""
8220 "いくつかの 32 ビットアーキテクチャでは、このシステムコールの呼び出しシグネ"
8221 "チャーが違っている。 理由は B<syscall>(2) で説明されている。"
8222
8223 #. type: Plain text
8224 #: build/C/man2/readahead.2:107
8225 msgid ""
8226 "B<readahead>()  attempts to schedule the reads in the background and return "
8227 "immediately.  However, it may block while it reads the filesystem metadata "
8228 "needed to locate the requested blocks.  This occurs frequently with ext[234] "
8229 "on large files using indirect blocks instead of extents, giving the "
8230 "appearance that the call blocks until the requested data has been read."
8231 msgstr "B<readahead>() は読み込みをバックグラウンドで行うようにスケジューリングを行い、すぐに返る。 しかしながら、要求されたブロックの位置を知るために必要なファイルシステムのメタデータを読み込む間は B<readahead>() は停止することがある。 これは ext[234] で大きなファイルをエクステントではなく間接ブロックを使う場合にしばしば発生し、 要求したデータが読み込まれるまで呼び出しが停止しているように見える。"
8232
8233 #. type: Plain text
8234 #: build/C/man2/readahead.2:113
8235 msgid "B<lseek>(2), B<madvise>(2), B<mmap>(2), B<posix_fadvise>(2), B<read>(2)"
8236 msgstr ""
8237 "B<lseek>(2), B<madvise>(2), B<mmap>(2), B<posix_fadvise>(2), B<read>(2)"
8238
8239 #. type: TH
8240 #: build/C/man2/remap_file_pages.2:28
8241 #, no-wrap
8242 msgid "REMAP_FILE_PAGES"
8243 msgstr "REMAP_FILE_PAGES"
8244
8245 #. type: TH
8246 #: build/C/man2/remap_file_pages.2:28
8247 #, no-wrap
8248 msgid "2008-04-22"
8249 msgstr "2008-04-22"
8250
8251 #. type: Plain text
8252 #: build/C/man2/remap_file_pages.2:31
8253 msgid "remap_file_pages - create a nonlinear file mapping"
8254 msgstr "remap_file_pages - 非線形ファイルマッピングを作成する。"
8255
8256 #. type: Plain text
8257 #: build/C/man2/remap_file_pages.2:35
8258 #, no-wrap
8259 msgid ""
8260 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
8261 "B<#include E<lt>sys/mman.hE<gt>>\n"
8262 msgstr ""
8263 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
8264 "B<#include E<lt>sys/mman.hE<gt>>\n"
8265
8266 #. type: Plain text
8267 #: build/C/man2/remap_file_pages.2:38
8268 #, no-wrap
8269 msgid ""
8270 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
8271 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
8272 msgstr ""
8273 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
8274 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
8275
8276 #. type: Plain text
8277 #: build/C/man2/remap_file_pages.2:51
8278 msgid ""
8279 "The B<remap_file_pages>()  system call is used to create a nonlinear "
8280 "mapping, that is, a mapping in which the pages of the file are mapped into a "
8281 "nonsequential order in memory.  The advantage of using B<remap_file_pages>"
8282 "()  over using repeated calls to B<mmap>(2)  is that the former approach "
8283 "does not require the kernel to create additional VMA (Virtual Memory Area) "
8284 "data structures."
8285 msgstr ""
8286 "B<remap_file_pages>()  システムコールは非線形なマッピング、 つまりファイルの"
8287 "ページがメモリ上で連続しない順番でマップされる マッピングを作成するために使わ"
8288 "れる。 B<remap_file_pages>()  を使う方が B<mmap>(2)  を繰り返して使うより優れ"
8289 "ている点は、 前者の方法ではカーネルが VMA (Virtual Memory Area, 仮想メモリ領"
8290 "域)  データ構造体を追加で作成する必要がないことである。"
8291
8292 #. type: Plain text
8293 #: build/C/man2/remap_file_pages.2:53
8294 msgid "To create a nonlinear mapping we perform the following steps:"
8295 msgstr "非線形マッピングを作成するためには、 以下のようなステップを実行する:"
8296
8297 #. type: TP
8298 #: build/C/man2/remap_file_pages.2:53
8299 #, no-wrap
8300 msgid "1."
8301 msgstr "1."
8302
8303 #. type: Plain text
8304 #: build/C/man2/remap_file_pages.2:61
8305 msgid ""
8306 "Use B<mmap>(2)  to create a mapping (which is initially linear).  This "
8307 "mapping must be created with the B<MAP_SHARED> flag."
8308 msgstr ""
8309 "B<mmap>(2)  を使い、マッピングを作成する (このマッピングは最初は線形であ"
8310 "る)。 このマッピングは B<MAP_SHARED> フラグを指定して作成されなければならな"
8311 "い。"
8312
8313 #. type: TP
8314 #: build/C/man2/remap_file_pages.2:61
8315 #, no-wrap
8316 msgid "2."
8317 msgstr "2."
8318
8319 #. type: Plain text
8320 #: build/C/man2/remap_file_pages.2:69
8321 msgid ""
8322 "Use one or more calls to B<remap_file_pages>()  to rearrange the "
8323 "correspondence between the pages of the mapping and the pages of the file.  "
8324 "It is possible to map the same page of a file into multiple locations within "
8325 "the mapped region."
8326 msgstr ""
8327 "B<remap_file_pages>()  を 1 回以上呼び出して、 マッピングのページとファイルの"
8328 "ページの対応関係を再構成する。 ファイルの同じページをマッピング領域の複数の場"
8329 "所に マップすることが可能である。"
8330
8331 #. type: Plain text
8332 #: build/C/man2/remap_file_pages.2:80
8333 msgid ""
8334 "The I<pgoff> and I<size> arguments specify the region of the file that is to "
8335 "be relocated within the mapping: I<pgoff> is a file offset in units of the "
8336 "system page size; I<size> is the length of the region in bytes."
8337 msgstr ""
8338 "I<pgoff> と I<size> 引き数は、マッピング内で再配置されるファイルの領域を指定"
8339 "する。 I<pgoff> はファイルオフセットであり、単位はシステムのページサイズであ"
8340 "る。 I<size> は領域の長さであり、単位はバイトである。"
8341
8342 #. type: Plain text
8343 #: build/C/man2/remap_file_pages.2:98
8344 msgid ""
8345 "The I<addr> argument serves two purposes.  First, it identifies the mapping "
8346 "whose pages we want to rearrange.  Thus, I<addr> must be an address that "
8347 "falls within a region previously mapped by a call to B<mmap>(2).  Second, "
8348 "I<addr> specifies the address at which the file pages identified by I<pgoff> "
8349 "and I<size> will be placed."
8350 msgstr ""
8351 "I<addr> 引き数は 2 つの目的で使われる。 第 1 の目的は、この引き数によって再編"
8352 "成したいページの マッピングを識別することである。 よって I<addr> は B<mmap>"
8353 "(2)  の呼び出しで過去にマップされた領域内のアドレスでなければならない。 第 2 "
8354 "の目的は、 I<pgoff> と I<size> で識別されるファイルページが置かれる予定のアド"
8355 "レスを、 I<addr> によって指定することである。"
8356
8357 #.  This rounding is weird, and not consistent with the treatment of
8358 #.  the analogous arguments for munmap()/mprotect() and for mlock().
8359 #.  MTK, 14 Sep 2005
8360 #. type: Plain text
8361 #: build/C/man2/remap_file_pages.2:112
8362 msgid ""
8363 "The values specified in I<addr> and I<size> should be multiples of the "
8364 "system page size.  If they are not, then the kernel rounds I<both> values "
8365 "I<down> to the nearest multiple of the page size."
8366 msgstr ""
8367 "I<addr> と I<size> に指定する値は、システムのページサイズの倍数とすべきであ"
8368 "る。 それ以外の場合、カーネルは「両方」の値を 最も近いページサイズの倍数へ"
8369 "「切り下げる」。"
8370
8371 #. type: Plain text
8372 #: build/C/man2/remap_file_pages.2:116
8373 msgid "The I<prot> argument must be specified as 0."
8374 msgstr "I<prot> 引き数は 0 に指定されなければならない。"
8375
8376 #. type: Plain text
8377 #: build/C/man2/remap_file_pages.2:124
8378 msgid ""
8379 "The I<flags> argument has the same meaning as for B<mmap>(2), but all flags "
8380 "other than B<MAP_NONBLOCK> are ignored."
8381 msgstr ""
8382 "I<flags> 引き数は B<mmap>(2)  のものと同じ意味であるが、 B<MAP_NONBLOCK> 以外"
8383 "の全てのフラグは無視される。"
8384
8385 #. type: Plain text
8386 #: build/C/man2/remap_file_pages.2:131
8387 msgid ""
8388 "On success, B<remap_file_pages>()  returns 0.  On error, -1 is returned, and "
8389 "I<errno> is set appropriately."
8390 msgstr ""
8391 "成功した場合、 B<remap_file_pages>()  は 0 を返す。 エラーの場合、-1 が返さ"
8392 "れ、 I<errno> が適切に設定される。"
8393
8394 #. type: Plain text
8395 #: build/C/man2/remap_file_pages.2:139
8396 msgid ""
8397 "I<addr> does not refer to a valid mapping created with the B<MAP_SHARED> "
8398 "flag."
8399 msgstr ""
8400 "I<addr> が B<MAP_SHARED> フラグを指定して作成された有効なマッピングを参照して"
8401 "いない。"
8402
8403 #.  And possibly others from vma->vm_ops->populate()
8404 #. type: Plain text
8405 #: build/C/man2/remap_file_pages.2:148
8406 msgid "I<addr>, I<size>, I<prot>, or I<pgoff> is invalid."
8407 msgstr "I<addr>, I<size>, I<prot>, I<pgoff> のいずれかが不正である。"
8408
8409 #. type: Plain text
8410 #: build/C/man2/remap_file_pages.2:153
8411 msgid ""
8412 "The B<remap_file_pages>()  system call appeared in Linux 2.5.46; glibc "
8413 "support was added in version 2.3.3."
8414 msgstr ""
8415 "B<remap_file_pages>()  システムコールは Linux 2.5.46 で登場した。 glibc での"
8416 "サポートは glibc バージョン 2.3.3 で追加された。"
8417
8418 #. type: Plain text
8419 #: build/C/man2/remap_file_pages.2:157
8420 msgid "The B<remap_file_pages>()  system call is Linux-specific."
8421 msgstr "B<remap_file_pages>()  システムコールは Linux 固有のものである。"
8422
8423 #. type: Plain text
8424 #: build/C/man2/remap_file_pages.2:164
8425 msgid ""
8426 "B<getpagesize>(2), B<mmap>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), "
8427 "B<msync>(2)"
8428 msgstr ""
8429 "B<getpagesize>(2), B<mmap>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), "
8430 "B<msync>(2)"
8431
8432 #. type: TH
8433 #: build/C/man3/shm_open.3:26
8434 #, no-wrap
8435 msgid "SHM_OPEN"
8436 msgstr "SHM_OPEN"
8437
8438 #. type: TH
8439 #: build/C/man3/shm_open.3:26
8440 #, no-wrap
8441 msgid "2009-02-25"
8442 msgstr "2009-02-25"
8443
8444 #. type: Plain text
8445 #: build/C/man3/shm_open.3:29
8446 msgid ""
8447 "shm_open, shm_unlink - create/open or unlink POSIX shared memory objects"
8448 msgstr ""
8449 "shm_open, shm_unlink - POSIX 共有メモリ・オブジェクトの作成/オープン/削除を行"
8450 "う"
8451
8452 #. type: Plain text
8453 #: build/C/man3/shm_open.3:33
8454 msgid "B<#include E<lt>sys/stat.hE<gt>> /* For mode constants */"
8455 msgstr "B<#include E<lt>sys/stat.hE<gt>> /* mode 定数用 */"
8456
8457 #. type: Plain text
8458 #: build/C/man3/shm_open.3:35
8459 msgid "B<#include E<lt>fcntl.hE<gt>> /* For O_* constants */"
8460 msgstr "B<#include E<lt>fcntl.hE<gt>> /* O_* 定数の定義用 */"
8461
8462 #. type: Plain text
8463 #: build/C/man3/shm_open.3:37
8464 msgid ""
8465 "B<int shm_open(const char *>I<name>B<, int >I<oflag>B<, mode_t >I<mode>B<);>"
8466 msgstr ""
8467 "B<int shm_open(const char *>I<name>B<, int >I<oflag>B<, mode_t >I<mode>B<);>"
8468
8469 #. type: Plain text
8470 #: build/C/man3/shm_open.3:39
8471 msgid "B<int shm_unlink(const char *>I<name>B<);>"
8472 msgstr "B<int shm_unlink(const char *>I<name>B<);>"
8473
8474 #. type: Plain text
8475 #: build/C/man3/shm_open.3:41
8476 msgid "Link with I<-lrt>."
8477 msgstr "I<-lrt> でリンクする。"
8478
8479 #. type: Plain text
8480 #: build/C/man3/shm_open.3:53
8481 msgid ""
8482 "B<shm_open>()  creates and opens a new, or opens an existing, POSIX shared "
8483 "memory object.  A POSIX shared memory object is in effect a handle which can "
8484 "be used by unrelated processes to B<mmap>(2)  the same region of shared "
8485 "memory.  The B<shm_unlink>()  function performs the converse operation, "
8486 "removing an object previously created by B<shm_open>()."
8487 msgstr ""
8488 "B<shm_open>()  は、POSIX 共有メモリ・オブジェクトを新規に作成/オープンした"
8489 "り、 すでに存在するオブジェクトをオープンしたりする。 POSIX 共有メモリ・オブ"
8490 "ジェクトは、実際には、関係のないプロセスが 共有メモリの同じ領域を B<mmap>"
8491 "(2)  するために使用することができる手段である。 B<shm_unlink>()  は、逆の操"
8492 "作、つまり以前に B<shm_open>()  で作成されたオブジェクトの削除を行う。"
8493
8494 #.  glibc allows the initial slash to be omitted, and makes
8495 #.  multiple initial slashes equivalent to a single slash.
8496 #.  This differs from the implementation of POSIX message queues.
8497 #.  glibc allows subdirectory components in the name, in which
8498 #.  case the subdirectory must exist under /dev/shm, and allow the
8499 #.  required permissions if a user wants to create a shared memory
8500 #.  object in that subdirectory.
8501 #. type: Plain text
8502 #: build/C/man3/shm_open.3:74
8503 msgid ""
8504 "The operation of B<shm_open>()  is analogous to that of B<open>(2).  I<name> "
8505 "specifies the shared memory object to be created or opened.  For portable "
8506 "use, a shared memory object should be identified by a name of the form I</"
8507 "somename>; that is, a null-terminated string of up to B<NAME_MAX> (i.e., "
8508 "255) characters consisting of an initial slash, followed by one or more "
8509 "characters, none of which are slashes."
8510 msgstr ""
8511 "B<shm_open>()  の動作は B<open>(2)  とよく似ている。 I<name> で作成したりオー"
8512 "プンしたりする共有メモリ・オブジェクトを指定する。 移植性を持たせるためには、"
8513 "共有メモリ・オブジェクトは I</somename> という形式の名前で識別し、 その名前"
8514 "は、最大で B<NAME_MAX> (すなわち 255) 文字のヌル終端された文字列で、 スラッ"
8515 "シュで始まり、スラッシュ以外の文字が 1 文字以上続く形式 にすべきである。"
8516
8517 #. type: Plain text
8518 #: build/C/man3/shm_open.3:81
8519 msgid ""
8520 "I<oflag> is a bit mask created by ORing together exactly one of B<O_RDONLY> "
8521 "or B<O_RDWR> and any of the other flags listed here:"
8522 msgstr ""
8523 "I<oflag> はビットマスクで、 B<O_RDONLY> と B<O_RDWR> のいずれか一方と、以下に"
8524 "述べる他のフラグの論理和をとったもの を指定する。"
8525
8526 #. type: TP
8527 #: build/C/man3/shm_open.3:81
8528 #, no-wrap
8529 msgid "B<O_RDONLY>"
8530 msgstr "B<O_RDONLY>"
8531
8532 #. type: Plain text
8533 #: build/C/man3/shm_open.3:89
8534 msgid ""
8535 "Open the object for read access.  A shared memory object opened in this way "
8536 "can be B<mmap>(2)ed only for read (B<PROT_READ>)  access."
8537 msgstr ""
8538 "読み出しアクセス用にオブジェクトをオープンする。 このフラグを指定してオープン"
8539 "された共有メモリ・オブジェクトは、 読み出し (B<PROT_READ>) アクセスでのみ "
8540 "B<mmap>(2)  することができる。"
8541
8542 #. type: TP
8543 #: build/C/man3/shm_open.3:89
8544 #, no-wrap
8545 msgid "B<O_RDWR>"
8546 msgstr "B<O_RDWR>"
8547
8548 #. type: Plain text
8549 #: build/C/man3/shm_open.3:92
8550 msgid "Open the object for read-write access."
8551 msgstr "読み書きアクセス用にオブジェクトをオープンする。"
8552
8553 #. type: TP
8554 #: build/C/man3/shm_open.3:92
8555 #, no-wrap
8556 msgid "B<O_CREAT>"
8557 msgstr "B<O_CREAT>"
8558
8559 #.  In truth it is actually the filesystem IDs on Linux, but these
8560 #.  are nearly always the same as the effective IDs.  (MTK, Jul 05)
8561 #. type: Plain text
8562 #: build/C/man3/shm_open.3:112
8563 msgid ""
8564 "Create the shared memory object if it does not exist.  The user and group "
8565 "ownership of the object are taken from the corresponding effective IDs of "
8566 "the calling process, and the object's permission bits are set according to "
8567 "the low-order 9 bits of I<mode>, except that those bits set in the process "
8568 "file mode creation mask (see B<umask>(2))  are cleared for the new object.  "
8569 "A set of macro constants which can be used to define I<mode> is listed in "
8570 "B<open>(2).  (Symbolic definitions of these constants can be obtained by "
8571 "including I<E<lt>sys/stat.hE<gt>>.)"
8572 msgstr ""
8573 "存在しない場合、共有メモリ・オブジェクトを作成する。 オブジェクトのユーザとグ"
8574 "ループの所有権は、 呼び出し元プロセスの対応する実効 ID が使われ、 オブジェク"
8575 "トの許可ビットは I<mode> の下位 9 ビットに基づいて設定される。ただし、 ファイ"
8576 "ルモード作成マスク (B<umask>(2)  参照) に設定されている値は、新規オブジェクト"
8577 "に関してはクリアされる。 I<mode> を定義するために使用できるマクロ定数(群)は "
8578 "B<open>(2)  に記載されている (これらの定数のシンボル定義は I<E<lt>sys/stat."
8579 "hE<gt>> のインクルードにより得られる)。"
8580
8581 #. type: Plain text
8582 #: build/C/man3/shm_open.3:118
8583 msgid ""
8584 "A new shared memory object initially has zero length\\(emthe size of the "
8585 "object can be set using B<ftruncate>(2).  The newly allocated bytes of a "
8586 "shared memory object are automatically initialized to 0."
8587 msgstr ""
8588 "新規に作成された共有メモリ・オブジェクトは長さ 0 で初期化される。 オブジェク"
8589 "トの大きさは B<ftruncate>(2)  を使って設定できる。 共有メモリ・オブジェクトと"
8590 "して新規に確保されたバイトは自動的に 0 に初期化される。"
8591
8592 #. type: TP
8593 #: build/C/man3/shm_open.3:118
8594 #, no-wrap
8595 msgid "B<O_EXCL>"
8596 msgstr "B<O_EXCL>"
8597
8598 #. type: Plain text
8599 #: build/C/man3/shm_open.3:127
8600 msgid ""
8601 "If B<O_CREAT> was also specified, and a shared memory object with the given "
8602 "I<name> already exists, return an error.  The check for the existence of the "
8603 "object, and its creation if it does not exist, are performed atomically."
8604 msgstr ""
8605 "B<O_CREAT> が一緒に指定されており、 I<name> で指定された共有メモリ・オブジェ"
8606 "クトが既に存在した場合、 エラーを返す。 オブジェクトの存在確認と、存在しな"
8607 "かった場合のオブジェクト作成は、 必ず一連の操作として実行される (performed "
8608 "atomically)。"
8609
8610 #. type: TP
8611 #: build/C/man3/shm_open.3:127
8612 #, no-wrap
8613 msgid "B<O_TRUNC>"
8614 msgstr "B<O_TRUNC>"
8615
8616 #. type: Plain text
8617 #: build/C/man3/shm_open.3:130
8618 msgid "If the shared memory object already exists, truncate it to zero bytes."
8619 msgstr ""
8620 "共有メモリ・オブジェクトがすでに存在した場合、 そのオブジェクトを 0 バイトに"
8621 "切り詰める。"
8622
8623 #. type: Plain text
8624 #: build/C/man3/shm_open.3:133
8625 msgid ""
8626 "Definitions of these flag values can be obtained by including I<E<lt>fcntl."
8627 "hE<gt>>."
8628 msgstr ""
8629 "これらのフラグ値の定義は I<E<lt>fcntl.hE<gt>> のインクルードにより得られる。"
8630
8631 #. type: Plain text
8632 #: build/C/man3/shm_open.3:144
8633 msgid ""
8634 "On successful completion B<shm_open>()  returns a new file descriptor "
8635 "referring to the shared memory object.  This file descriptor is guaranteed "
8636 "to be the lowest-numbered file descriptor not previously opened within the "
8637 "process.  The B<FD_CLOEXEC> flag (see B<fcntl>(2))  is set for the file "
8638 "descriptor."
8639 msgstr ""
8640 "成功して完了した場合、 B<shm_open>()  は共有メモリ・オブジェクトを参照する新"
8641 "しいファイル・ディスクリプタを返す。 このファイル・ディスクリプタは、そのプロ"
8642 "セス内で過去にオープンされていない ファイル・ディスクリプタの中で最も小さな数"
8643 "になることが保証される。 B<FD_CLOEXEC> フラグ (B<fcntl>(2)  を参照) が、この"
8644 "ファイル・ディスクリプタに設定される。"
8645
8646 #. type: Plain text
8647 #: build/C/man3/shm_open.3:153
8648 msgid ""
8649 "The file descriptor is normally used in subsequent calls to B<ftruncate>(2)  "
8650 "(for a newly created object) and B<mmap>(2).  After a call to B<mmap>(2)  "
8651 "the file descriptor may be closed without affecting the memory mapping."
8652 msgstr ""
8653 "通常、これらのファイル・ディスクリプタは、この後続けて実行される B<ftruncate>"
8654 "(2)  (新規に作成されたオブジェクトの場合のみ) と B<mmap>(2)  の呼び出しに使用"
8655 "される。 B<mmap>(2)  を呼び出した後は、ファイル・ディスクリプタをクローズして"
8656 "もよく、 クローズしてもメモリ・マッピングに影響を与えることはない。"
8657
8658 #. type: Plain text
8659 #: build/C/man3/shm_open.3:171
8660 msgid ""
8661 "The operation of B<shm_unlink>()  is analogous to B<unlink>(2): it removes a "
8662 "shared memory object name, and, once all processes have unmapped the object, "
8663 "de-allocates and destroys the contents of the associated memory region.  "
8664 "After a successful B<shm_unlink>(), attempts to B<shm_open>()  an object "
8665 "with the same I<name> will fail (unless B<O_CREAT> was specified, in which "
8666 "case a new, distinct object is created)."
8667 msgstr ""
8668 "B<shm_unlink>()  の動作は B<unlink>(2)  とよく似ている: 共有メモリ・オブジェ"
8669 "クト名を削除し、すべてのプロセスが処理対象の オブジェクトをアンマップした時点"
8670 "でオブジェクトの割り当てを解除し、 対応するメモリ領域の内容を破棄する。 "
8671 "B<shm_unlink>()  が成功した後で、同じ I<name> を持つオブジェクトに対して "
8672 "B<shm_open>()  を行うと、 (B<O_CREAT> が指定されていない場合) 失敗する。 "
8673 "(B<O_CREAT> が指定されている場合、新しく別のオブジェクトが作成される)。"
8674
8675 #. type: Plain text
8676 #: build/C/man3/shm_open.3:180
8677 msgid ""
8678 "On success, B<shm_open>()  returns a nonnegative file descriptor.  On "
8679 "failure, B<shm_open>()  returns -1.  B<shm_unlink>()  returns 0 on success, "
8680 "or -1 on error."
8681 msgstr ""
8682 "成功した場合、 B<shm_open>()  は非負のファイル・ディスクリプタを返す。 失敗し"
8683 "た場合、 B<shm_open>()  は -1 を返す。 B<shm_unlink>()  は、成功した場合 0 "
8684 "を、エラーが起こった場合 -1 を返す。"
8685
8686 #. type: Plain text
8687 #: build/C/man3/shm_open.3:187
8688 msgid ""
8689 "On failure, I<errno> is set to indicate the cause of the error.  Values "
8690 "which may appear in I<errno> include the following:"
8691 msgstr ""
8692 "失敗した場合、エラーの原因を示すため I<errno> が設定される。 I<errno> に設定"
8693 "される値は以下の通りである:"
8694
8695 #. type: Plain text
8696 #: build/C/man3/shm_open.3:192
8697 msgid "Permission to B<shm_unlink>()  the shared memory object was denied."
8698 msgstr "共有メモリオブジェクトを B<shm_unlink>()  する権限がなかった。"
8699
8700 #. type: Plain text
8701 #: build/C/man3/shm_open.3:202
8702 msgid ""
8703 "Permission was denied to B<shm_open>()  I<name> in the specified I<mode>, or "
8704 "B<O_TRUNC> was specified and the caller does not have write permission on "
8705 "the object."
8706 msgstr ""
8707 "指定された I<mode> で I<name> を B<shm_open>()  する権限がなかった。もしく"
8708 "は、 B<O_TRUNC> が指定されたが、呼び出し元にはそのオブジェクトに対する書き込"
8709 "み権限が なかった。"
8710
8711 #. type: TP
8712 #: build/C/man3/shm_open.3:202 build/C/man2/shmget.2:195
8713 #, no-wrap
8714 msgid "B<EEXIST>"
8715 msgstr "B<EEXIST>"
8716
8717 #. type: Plain text
8718 #: build/C/man3/shm_open.3:213
8719 msgid ""
8720 "Both B<O_CREAT> and B<O_EXCL> were specified to B<shm_open>()  and the "
8721 "shared memory object specified by I<name> already exists."
8722 msgstr ""
8723 "B<O_CREAT> と B<O_EXCL> の両方が B<shm_open>()  に指定されたが、 I<name> で指"
8724 "定された共有メモリ・オブジェクトが既に存在した。"
8725
8726 #. type: Plain text
8727 #: build/C/man3/shm_open.3:220
8728 msgid "The I<name> argument to B<shm_open>()  was invalid."
8729 msgstr "B<shm_open>()  に与えられた I<name> 引き数が不正であった。"
8730
8731 #. type: TP
8732 #: build/C/man3/shm_open.3:220
8733 #, no-wrap
8734 msgid "B<EMFILE>"
8735 msgstr "B<EMFILE>"
8736
8737 #. type: Plain text
8738 #: build/C/man3/shm_open.3:223
8739 msgid "The process already has the maximum number of files open."
8740 msgstr "プロセスがオープン可能なファイル数の上限にすでに達していた。"
8741
8742 #. type: TP
8743 #: build/C/man3/shm_open.3:223
8744 #, no-wrap
8745 msgid "B<ENAMETOOLONG>"
8746 msgstr "B<ENAMETOOLONG>"
8747
8748 #. type: Plain text
8749 #: build/C/man3/shm_open.3:229
8750 msgid "The length of I<name> exceeds B<PATH_MAX>."
8751 msgstr "I<name> の長さが B<PATH_MAX> を越えている。"
8752
8753 #. type: Plain text
8754 #: build/C/man3/shm_open.3:233
8755 msgid ""
8756 "The limit on the total number of files open on the system has been reached."
8757 msgstr "ファイルシステムでオープンできるファイル数の上限に達した。"
8758
8759 #. type: TP
8760 #: build/C/man3/shm_open.3:233 build/C/man3/shm_open.3:242
8761 #: build/C/man2/shmget.2:209
8762 #, no-wrap
8763 msgid "B<ENOENT>"
8764 msgstr "B<ENOENT>"
8765
8766 #. type: Plain text
8767 #: build/C/man3/shm_open.3:242
8768 msgid ""
8769 "An attempt was made to B<shm_open>()  a I<name> that did not exist, and "
8770 "B<O_CREAT> was not specified."
8771 msgstr ""
8772 "存在していない I<name> のオブジェクトを B<shm_open>()  しようとしたが、 "
8773 "B<O_CREAT> が指定されていなかった。"
8774
8775 #. type: Plain text
8776 #: build/C/man3/shm_open.3:249
8777 msgid ""
8778 "An attempt was to made to B<shm_unlink>()  a I<name> that does not exist."
8779 msgstr "存在しない I<name> のオブジェクトを B<shm_unlink>()  しようとした。"
8780
8781 #. type: Plain text
8782 #: build/C/man3/shm_open.3:251
8783 msgid "These functions are provided in glibc 2.2 and later."
8784 msgstr "これらの関数は glibc 2.2 以降で提供されている。"
8785
8786 #. type: Plain text
8787 #: build/C/man3/shm_open.3:257
8788 msgid ""
8789 "POSIX.1-2001 says that the group ownership of a newly created shared memory "
8790 "object is set to either the calling process's effective group ID or \"a "
8791 "system default group ID\"."
8792 msgstr ""
8793 "POSIX.1-2001 には、新規に作成される共有メモリオブジェクトのグループ所有権"
8794 "は、 呼び出し元プロセスの実効グループ ID か 「システムのデフォルトのグループ "
8795 "ID」 のどちらかに設定される、と書かれている。"
8796
8797 #. type: Plain text
8798 #: build/C/man3/shm_open.3:266
8799 msgid ""
8800 "POSIX leaves the behavior of the combination of B<O_RDONLY> and B<O_TRUNC> "
8801 "unspecified.  On Linux, this will successfully truncate an existing shared "
8802 "memory object\\(emthis may not be so on other UNIX systems."
8803 msgstr ""
8804 "POSIX は B<O_RDONLY> と B<O_TRUNC> が一緒に指定された場合の動作を未定義にして"
8805 "いる。Linux では、 既存の共有メモリ・オブジェクトに対する切り詰め (truncate) "
8806 "は成功する。 しかし、他の UNIX システムでも同じであるとは限らない。"
8807
8808 #. type: Plain text
8809 #: build/C/man3/shm_open.3:271
8810 msgid ""
8811 "The POSIX shared memory object implementation on Linux 2.4 makes use of a "
8812 "dedicated filesystem, which is normally mounted under I</dev/shm>."
8813 msgstr ""
8814 "Linux 2.4 における POSIX 共有メモリ・オブジェクトの実装は 専用のファイルシス"
8815 "テムを使用する。そのファイルシステムは通常 I</dev/shm> にマウントされる。"
8816
8817 #. type: Plain text
8818 #: build/C/man3/shm_open.3:282
8819 msgid ""
8820 "B<close>(2), B<fchmod>(2), B<fchown>(2), B<fcntl>(2), B<fstat>(2), "
8821 "B<ftruncate>(2), B<mmap>(2), B<open>(2), B<umask>(2), B<shm_overview>(7)"
8822 msgstr ""
8823 "B<close>(2), B<fchmod>(2), B<fchown>(2), B<fcntl>(2), B<fstat>(2), "
8824 "B<ftruncate>(2), B<mmap>(2), B<open>(2), B<umask>(2), B<shm_overview>(7)"
8825
8826 #. type: TH
8827 #: build/C/man7/shm_overview.7:27
8828 #, no-wrap
8829 msgid "SHM_OVERVIEW"
8830 msgstr "SHM_OVERVIEW"
8831
8832 #. type: TH
8833 #: build/C/man7/shm_overview.7:27
8834 #, no-wrap
8835 msgid "2010-09-10"
8836 msgstr "2010-09-10"
8837
8838 #. type: Plain text
8839 #: build/C/man7/shm_overview.7:30
8840 msgid "shm_overview - overview of POSIX shared memory"
8841 msgstr "shm_overview - POSIX 共有メモリの概要"
8842
8843 #. type: Plain text
8844 #: build/C/man7/shm_overview.7:33
8845 msgid ""
8846 "The POSIX shared memory API allows processes to communicate information by "
8847 "sharing a region of memory."
8848 msgstr ""
8849 "POSIX 共有メモリ API を使用すると、メモリのある領域を共有して、 プロセス間で"
8850 "情報をやり取りすることができる。"
8851
8852 #. type: Plain text
8853 #: build/C/man7/shm_overview.7:35
8854 msgid "The interfaces employed in the API are:"
8855 msgstr "この API では以下のインターフェースが採用されている。"
8856
8857 #. type: TP
8858 #: build/C/man7/shm_overview.7:35
8859 #, no-wrap
8860 msgid "B<shm_open>(3)"
8861 msgstr "B<shm_open>(3)"
8862
8863 #. type: Plain text
8864 #: build/C/man7/shm_overview.7:42
8865 msgid ""
8866 "Create and open a new object, or open an existing object.  This is analogous "
8867 "to B<open>(2).  The call returns a file descriptor for use by the other "
8868 "interfaces listed below."
8869 msgstr ""
8870 "新しいオブジェクトを生成しオープンする、もしくは 既存のオブジェクトをオープン"
8871 "する。これは B<open>(2)  と同じである。下記にある他のインターフェースで使用す"
8872 "る ファイルディスクリプタを返す。"
8873
8874 #. type: TP
8875 #: build/C/man7/shm_overview.7:42
8876 #, no-wrap
8877 msgid "B<ftruncate>(2)"
8878 msgstr "B<ftruncate>(2)"
8879
8880 #. type: Plain text
8881 #: build/C/man7/shm_overview.7:46
8882 msgid ""
8883 "Set the size of the shared memory object.  (A newly created shared memory "
8884 "object has a length of zero.)"
8885 msgstr "共有メモリオブジェクトの大きさを設定する。"
8886
8887 #. type: Plain text
8888 #: build/C/man7/shm_overview.7:50
8889 msgid ""
8890 "Map the shared memory object into the virtual address space of the calling "
8891 "process."
8892 msgstr ""
8893 "呼び出したプロセスの仮想アドレス空間に共有メモリオブジェクトを マップする。"
8894
8895 #. type: TP
8896 #: build/C/man7/shm_overview.7:50
8897 #, no-wrap
8898 msgid "B<munmap>(2)"
8899 msgstr "B<munmap>(2)"
8900
8901 #. type: Plain text
8902 #: build/C/man7/shm_overview.7:54
8903 msgid ""
8904 "Unmap the shared memory object from the virtual address space of the calling "
8905 "process."
8906 msgstr ""
8907 "呼び出したプロセスの仮想アドレス空間から 共有メモリオブジェクトをアンマップす"
8908 "る。"
8909
8910 #. type: TP
8911 #: build/C/man7/shm_overview.7:54
8912 #, no-wrap
8913 msgid "B<shm_unlink>(3)"
8914 msgstr "B<shm_unlink>(3)"
8915
8916 #. type: Plain text
8917 #: build/C/man7/shm_overview.7:57
8918 msgid "Remove a shared memory object name."
8919 msgstr "共有メモリオブジェクト名を削除する。"
8920
8921 #. type: TP
8922 #: build/C/man7/shm_overview.7:57
8923 #, no-wrap
8924 msgid "B<close>(2)"
8925 msgstr "B<close>(2)"
8926
8927 #. type: Plain text
8928 #: build/C/man7/shm_overview.7:62
8929 msgid ""
8930 "Close the file descriptor allocated by B<shm_open>(3)  when it is no longer "
8931 "needed."
8932 msgstr ""
8933 "B<shm_open>(3)  で割り当てられたファイルディスクリプタが不要になった際に、 そ"
8934 "のファイルディスクリプタをクローズする。"
8935
8936 #. type: TP
8937 #: build/C/man7/shm_overview.7:62
8938 #, no-wrap
8939 msgid "B<fstat>(2)"
8940 msgstr "B<fstat>(2)"
8941
8942 #. type: Plain text
8943 #: build/C/man7/shm_overview.7:76
8944 msgid ""
8945 "Obtain a I<stat> structure that describes the shared memory object.  Among "
8946 "the information returned by this call are the object's size (I<st_size>), "
8947 "permissions (I<st_mode>), owner (I<st_uid>), and group (I<st_gid>)."
8948 msgstr ""
8949 "その共有メモリオブジェクトについての情報が入った I<stat> 構造体を取得する。 "
8950 "このシステムコールが返す情報には、オブジェクトのサイズ (I<st_size>)、 許可属"
8951 "性 (I<st_mode>)、 所有者 (I<st_uid>)、 グループ (I<st_gid>)  がある。"
8952
8953 #. type: TP
8954 #: build/C/man7/shm_overview.7:76
8955 #, no-wrap
8956 msgid "B<fchown>(2)"
8957 msgstr "B<fchown>(2)"
8958
8959 #. type: Plain text
8960 #: build/C/man7/shm_overview.7:79
8961 msgid "To change the ownership of a shared memory object."
8962 msgstr "共有メモリオブジェクトの所有権を変更する。"
8963
8964 #. type: TP
8965 #: build/C/man7/shm_overview.7:79
8966 #, no-wrap
8967 msgid "B<fchmod>(2)"
8968 msgstr "B<fchmod>(2)"
8969
8970 #. type: Plain text
8971 #: build/C/man7/shm_overview.7:82
8972 msgid "To change the permissions of a shared memory object."
8973 msgstr "共有メモリオブジェクトの許可属性を変更する。"
8974
8975 #. type: SS
8976 #: build/C/man7/shm_overview.7:82
8977 #, no-wrap
8978 msgid "Versions"
8979 msgstr "Versions"
8980
8981 #. type: Plain text
8982 #: build/C/man7/shm_overview.7:84
8983 msgid "POSIX shared memory is supported since Linux 2.4 and glibc 2.2."
8984 msgstr "POSIX 共有メモリは Linux 2.4 と glibc 2.2 以降でサポートされている。"
8985
8986 #. type: SS
8987 #: build/C/man7/shm_overview.7:84
8988 #, no-wrap
8989 msgid "Persistence"
8990 msgstr "持続性"
8991
8992 #. type: Plain text
8993 #: build/C/man7/shm_overview.7:89
8994 msgid ""
8995 "POSIX shared memory objects have kernel persistence: a shared memory object "
8996 "will exist until the system is shut down, or until all processes have "
8997 "unmapped the object and it has been deleted with B<shm_unlink>(3)"
8998 msgstr ""
8999 "POSIX 共有メモリオブジェクトはカーネル内で保持される。 共有メモリオブジェクト"
9000 "は、システムがシャットダウンされるか、 全てのプロセスがそのオブジェクトをアン"
9001 "マップし、 B<shm_unlink>(3)  で削除されるまで、存在し続ける。"
9002
9003 #. type: SS
9004 #: build/C/man7/shm_overview.7:89
9005 #, no-wrap
9006 msgid "Linking"
9007 msgstr "リンク"
9008
9009 #. type: Plain text
9010 #: build/C/man7/shm_overview.7:94
9011 msgid ""
9012 "Programs using the POSIX shared memory API must be compiled with I<cc -lrt> "
9013 "to link against the real-time library, I<librt>."
9014 msgstr ""
9015 "POSIX 共有メモリ API を使用したプログラムは I<cc -lrt> でコンパイルし、リアル"
9016 "タイムライブラリ I<librt> とリンクしなければならない。"
9017
9018 #. type: SS
9019 #: build/C/man7/shm_overview.7:94
9020 #, no-wrap
9021 msgid "Accessing shared memory objects via the filesystem"
9022 msgstr "ファイルシステム経由での共有メモリオブジェクトへのアクセス"
9023
9024 #. type: Plain text
9025 #: build/C/man7/shm_overview.7:101
9026 msgid ""
9027 "On Linux, shared memory objects are created in a (I<tmpfs>)  virtual "
9028 "filesystem, normally mounted under I</dev/shm>.  Since kernel 2.6.19, Linux "
9029 "supports the use of access control lists (ACLs)  to control the permissions "
9030 "of objects in the virtual filesystem."
9031 msgstr ""
9032 "Linux では、共有メモリオブジェクトは通常 I</dev/shm> 以下にマウントされる仮想"
9033 "ファイルシステム (I<tmpfs>)  内に作成される。 カーネル 2.6.19 以降の Linux で"
9034 "は、 仮想ファイルシステム内のオブジェクトの許可属性の制御に、 アクセス制御リ"
9035 "スト (ACL; access control lists) を使うことができる。"
9036
9037 #. type: Plain text
9038 #: build/C/man7/shm_overview.7:106
9039 msgid ""
9040 "Typically, processes must synchronize their access to a shared memory "
9041 "object, using, for example, POSIX semaphores."
9042 msgstr ""
9043 "通常は、共有メモリオブジェクトにアクセスするプロセスは、 POSIX セマフォなどを"
9044 "使ってプロセス間で同期をとらなければならない。"
9045
9046 #. type: Plain text
9047 #: build/C/man7/shm_overview.7:114
9048 msgid ""
9049 "System V shared memory (B<shmget>(2), B<shmop>(2), etc.) is an older shared "
9050 "memory API.  POSIX shared memory provides a simpler, and better designed "
9051 "interface; on the other hand POSIX shared memory is somewhat less widely "
9052 "available (especially on older systems) than System V shared memory."
9053 msgstr ""
9054 "System V 共有メモリ (B<shmget>(2), B<shmop>(2)  など) は古い共有メモリ API で"
9055 "ある。 POSIX 共有メモリは、より簡単で、うまく設計されたインタフェースを提供し"
9056 "ている。 一方で、POSIX 共有メモリは System V 共有メモリと比べると 利用できる"
9057 "システムが少ない (特に、古いシステムでは少ない)。"
9058
9059 #. type: Plain text
9060 #: build/C/man7/shm_overview.7:127
9061 msgid ""
9062 "B<fchmod>(2), B<fchown>(2), B<fstat>(2), B<ftruncate>(2), B<mmap>(2), "
9063 "B<mprotect>(2), B<munmap>(2), B<shmget>(2), B<shmop>(2), B<shm_open>(3), "
9064 "B<shm_unlink>(3), B<sem_overview>(7)"
9065 msgstr ""
9066 "B<fchmod>(2), B<fchown>(2), B<fstat>(2), B<ftruncate>(2), B<mmap>(2), "
9067 "B<mprotect>(2), B<munmap>(2), B<shmget>(2), B<shmop>(2), B<shm_open>(3), "
9068 "B<shm_unlink>(3), B<sem_overview>(7)"
9069
9070 #. type: TH
9071 #: build/C/man2/shmctl.2:45
9072 #, no-wrap
9073 msgid "SHMCTL"
9074 msgstr "SHMCTL"
9075
9076 #. type: TH
9077 #: build/C/man2/shmctl.2:45
9078 #, no-wrap
9079 msgid "2014-02-07"
9080 msgstr "2014-02-07"
9081
9082 #. type: Plain text
9083 #: build/C/man2/shmctl.2:48
9084 msgid "shmctl - System V shared memory control"
9085 msgstr "shmctl - System V 共有メモリ (shared memory) を制御する"
9086
9087 #. type: Plain text
9088 #: build/C/man2/shmctl.2:51 build/C/man2/shmget.2:44
9089 msgid "B<#include E<lt>sys/ipc.hE<gt>>"
9090 msgstr "B<#include E<lt>sys/ipc.hE<gt>>"
9091
9092 #. type: Plain text
9093 #: build/C/man2/shmctl.2:53 build/C/man2/shmget.2:46
9094 msgid "B<#include E<lt>sys/shm.hE<gt>>"
9095 msgstr "B<#include E<lt>sys/shm.hE<gt>>"
9096
9097 #. type: Plain text
9098 #: build/C/man2/shmctl.2:55
9099 msgid ""
9100 "B<int shmctl(int >I<shmid>B<, int >I<cmd>B<, struct shmid_ds *>I<buf>B<);>"
9101 msgstr ""
9102 "B<int shmctl(int >I<shmid>B<, int >I<cmd>B<, struct shmid_ds *>I<buf>B<);>"
9103
9104 #. type: Plain text
9105 #: build/C/man2/shmctl.2:62
9106 msgid ""
9107 "B<shmctl>()  performs the control operation specified by I<cmd> on the "
9108 "System V shared memory segment whose identifier is given in I<shmid>."
9109 msgstr ""
9110 "B<shmctl>()  は、識別子が I<shmid> の System V 共有メモリ・セグメントに対し"
9111 "て I<cmd> で指示した制御命令を実行する。"
9112
9113 #. type: Plain text
9114 #: build/C/man2/shmctl.2:67
9115 msgid ""
9116 "The I<buf> argument is a pointer to a I<shmid_ds> structure, defined in "
9117 "I<E<lt>sys/shm.hE<gt>> as follows:"
9118 msgstr ""
9119 "I<buf> 引き数は、 I<shmid_ds> 構造体へのポインタである。 この構造体は "
9120 "I<E<lt>sys/shm.hE<gt>> で以下のように定義されている"
9121
9122 #. type: Plain text
9123 #: build/C/man2/shmctl.2:81
9124 #, no-wrap
9125 msgid ""
9126 "struct shmid_ds {\n"
9127 "    struct ipc_perm shm_perm;    /* Ownership and permissions */\n"
9128 "    size_t          shm_segsz;   /* Size of segment (bytes) */\n"
9129 "    time_t          shm_atime;   /* Last attach time */\n"
9130 "    time_t          shm_dtime;   /* Last detach time */\n"
9131 "    time_t          shm_ctime;   /* Last change time */\n"
9132 "    pid_t           shm_cpid;    /* PID of creator */\n"
9133 "    pid_t           shm_lpid;    /* PID of last shmat(2)/shmdt(2) */\n"
9134 "    shmatt_t        shm_nattch;  /* No. of current attaches */\n"
9135 "    ...\n"
9136 "};\n"
9137 msgstr ""
9138 "struct shmid_ds {\n"
9139 "    struct ipc_perm shm_perm;    /* 所有権と許可 */\n"
9140 "    size_t          shm_segsz;   /* セグメントのサイズ (バイト) */\n"
9141 "    time_t          shm_atime;   /* 最後の付加 (attach) の時刻 */\n"
9142 "    time_t          shm_dtime;   /* 最後の分離 (detach) の時刻 */\n"
9143 "    time_t          shm_ctime;   /* 最後に変更が行われた時刻 */\n"
9144 "    pid_t           shm_cpid;    /* 作成者 (creator) の PID */\n"
9145 "    pid_t           shm_lpid;    /* 最後の shmat(2)/shmdt(2) の PID */\n"
9146 "    shmatt_t        shm_nattch;  /* 現在付加されている数 */\n"
9147 "    ...\n"
9148 "};\n"
9149
9150 #. type: Plain text
9151 #: build/C/man2/shmctl.2:89
9152 msgid ""
9153 "The I<ipc_perm> structure is defined as follows (the highlighted fields are "
9154 "settable using B<IPC_SET>):"
9155 msgstr ""
9156 "I<ipc_perm> 構造体は以下のように定義されている (強調されたフィールドは "
9157 "B<IPC_SET> を使って設定可能である):"
9158
9159 #. type: Plain text
9160 #: build/C/man2/shmctl.2:102
9161 #, no-wrap
9162 msgid ""
9163 "struct ipc_perm {\n"
9164 "    key_t          __key;    /* Key supplied to shmget(2) */\n"
9165 "    uid_t          B<uid>;      /* Effective UID of owner */\n"
9166 "    gid_t          B<gid>;      /* Effective GID of owner */\n"
9167 "    uid_t          cuid;     /* Effective UID of creator */\n"
9168 "    gid_t          cgid;     /* Effective GID of creator */\n"
9169 "    unsigned short B<mode>;     /* B<Permissions> + SHM_DEST and\n"
9170 "                                SHM_LOCKED flags */\n"
9171 "    unsigned short __seq;    /* Sequence number */\n"
9172 "};\n"
9173 msgstr ""
9174 "struct ipc_perm {\n"
9175 "    key_t          __key;    /* shmget(2) に与えられるキー */\n"
9176 "    uid_t          B<uid>;      /* 所有者の実効 UID */\n"
9177 "    gid_t          B<gid>;      /* 所有者の実効 GID */\n"
9178 "    uid_t          cuid;     /* 作成者の実効 UID */\n"
9179 "    gid_t          cgid;     /* 作成者の実効 GID */\n"
9180 "    unsigned short B<mode>;     /* B<許可> + SHM_DEST と\n"
9181 "                                SHM_LOCKED フラグ */\n"
9182 "    unsigned short __seq;    /* シーケンス番号 */\n"
9183 "};\n"
9184
9185 #. type: Plain text
9186 #: build/C/man2/shmctl.2:108
9187 msgid "Valid values for I<cmd> are:"
9188 msgstr "I<cmd> として有効な値は以下の通り:"
9189
9190 #. type: TP
9191 #: build/C/man2/shmctl.2:109
9192 #, no-wrap
9193 msgid "B<IPC_STAT>"
9194 msgstr "B<IPC_STAT>"
9195
9196 #. type: Plain text
9197 #: build/C/man2/shmctl.2:118
9198 msgid ""
9199 "Copy information from the kernel data structure associated with I<shmid> "
9200 "into the I<shmid_ds> structure pointed to by I<buf>.  The caller must have "
9201 "read permission on the shared memory segment."
9202 msgstr ""
9203 "I<shmid> に関連づけられたカーネルデータ構造体の情報を I<buf> で指された "
9204 "I<shmid_ds> 構造体にコピーする。 呼び出し元は共有メモリ・セグメントに対する "
9205 "読み込み許可を持たなければならない。"
9206
9207 #. type: TP
9208 #: build/C/man2/shmctl.2:118
9209 #, no-wrap
9210 msgid "B<IPC_SET>"
9211 msgstr "B<IPC_SET>"
9212
9213 #. type: Plain text
9214 #: build/C/man2/shmctl.2:136
9215 msgid ""
9216 "Write the values of some members of the I<shmid_ds> structure pointed to by "
9217 "I<buf> to the kernel data structure associated with this shared memory "
9218 "segment, updating also its I<shm_ctime> member.  The following fields can be "
9219 "changed: I<shm_perm.uid>, I<shm_perm.gid>, and (the least significant 9 bits "
9220 "of) I<shm_perm.mode>.  The effective UID of the calling process must match "
9221 "the owner (I<shm_perm.uid>)  or creator (I<shm_perm.cuid>)  of the shared "
9222 "memory segment, or the caller must be privileged."
9223 msgstr ""
9224 "I<buf> によって指される I<shmid_ds> 構造体のいくつかのメンバーの値を、 この共"
9225 "有メモリ・セグメントに関連づけられたカーネルデータ構造体に書き込み、 "
9226 "I<shm_ctime> メンバーも更新する。 以下のフィールドは変更できる。 I<shm_perm."
9227 "uid>, I<shm_perm.gid>, I<shm_perm.mode> (の最下位 9 ビット)。 呼び出したプロ"
9228 "セスの実効 UID が所有者 (I<shm_perm.uid>)  または作成者 (I<shm_perm.cuid>)  "
9229 "と一致するか、呼び出し元が特権を持たなければならない。"
9230
9231 #. type: TP
9232 #: build/C/man2/shmctl.2:136
9233 #, no-wrap
9234 msgid "B<IPC_RMID>"
9235 msgstr "B<IPC_RMID>"
9236
9237 #. type: Plain text
9238 #: build/C/man2/shmctl.2:149
9239 msgid ""
9240 "Mark the segment to be destroyed.  The segment will only actually be "
9241 "destroyed after the last process detaches it (i.e., when the I<shm_nattch> "
9242 "member of the associated structure I<shmid_ds> is zero).  The caller must be "
9243 "the owner or creator of the segment, or be privileged.  The I<buf> argument "
9244 "is ignored."
9245 msgstr ""
9246 "セグメントに破棄済みのマークを付ける。 セグメントは、実際には最後プロセスがセ"
9247 "グメントを分離した (関連する I<shmid_ds> 構造体の I<shm_nattch> メンバーが 0 "
9248 "になった) 後でのみ破棄される。 呼び出し元はそのセグメントの所有者か作成者であ"
9249 "るか、特権を持たなければならない。 I<buf> 引き数は無視される。"
9250
9251 #. type: Plain text
9252 #: build/C/man2/shmctl.2:157
9253 msgid ""
9254 "If a segment has been marked for destruction, then the (nonstandard)  "
9255 "B<SHM_DEST> flag of the I<shm_perm.mode> field in the associated data "
9256 "structure retrieved by B<IPC_STAT> will be set."
9257 msgstr ""
9258 "セグメントに破棄のマークが付けられると、 関連するデータ構造体において "
9259 "I<shm_perm.mode> フィールドの (標準ではない)  B<SHM_DEST> フラグが設定され"
9260 "る。 このデータ構造体は B<IPC_STAT> で取得される。"
9261
9262 #. type: Plain text
9263 #: build/C/man2/shmctl.2:160
9264 msgid ""
9265 "The caller I<must> ensure that a segment is eventually destroyed; otherwise "
9266 "its pages that were faulted in will remain in memory or swap."
9267 msgstr ""
9268 "呼び出し元は最終的にはセグメントを忘れずに破棄I<しなければならない>。 そうで"
9269 "なれば、フォールト (fault) されたページは メモリかスワップ (swap) に残り続け"
9270 "る。"
9271
9272 #. type: Plain text
9273 #: build/C/man2/shmctl.2:165
9274 msgid ""
9275 "See also the description of I</proc/sys/kernel/shm_rmid_forced> in B<proc>"
9276 "(5)."
9277 msgstr "B<proc>(5) の I</proc/sys/kernel/shm_rmid_forced> の説明も参照のこと。"
9278
9279 #. type: TP
9280 #: build/C/man2/shmctl.2:165
9281 #, no-wrap
9282 msgid "B<IPC_INFO> (Linux-specific)"
9283 msgstr "B<IPC_INFO> (Linux 固有)"
9284
9285 #. type: Plain text
9286 #: build/C/man2/shmctl.2:178
9287 msgid ""
9288 "Returns information about system-wide shared memory limits and parameters in "
9289 "the structure pointed to by I<buf>.  This structure is of type I<shminfo> "
9290 "(thus, a cast is required), defined in I<E<lt>sys/shm.hE<gt>> if the "
9291 "B<_GNU_SOURCE> feature test macro is defined:"
9292 msgstr ""
9293 "システム全体での共有メモリの制限とパラメータに関する情報を、 I<buf> が指す構"
9294 "造体に入れて返す。 この構造体は I<shminfo> 型である (そのためキャストが必要で"
9295 "ある)。 I<shminfo> は B<_GNU_SOURCE> 機能検査マクロが定義された場合に "
9296 "I<E<lt>sys/shm.hE<gt>> で以下のように定義される:"
9297
9298 #. type: Plain text
9299 #: build/C/man2/shmctl.2:192
9300 #, no-wrap
9301 msgid ""
9302 "struct  shminfo {\n"
9303 "    unsigned long shmmax; /* Maximum segment size */\n"
9304 "    unsigned long shmmin; /* Minimum segment size;\n"
9305 "                             always 1 */\n"
9306 "    unsigned long shmmni; /* Maximum number of segments */\n"
9307 "    unsigned long shmseg; /* Maximum number of segments\n"
9308 "                             that a process can attach;\n"
9309 "                             unused within kernel */\n"
9310 "    unsigned long shmall; /* Maximum number of pages of\n"
9311 "                             shared memory, system-wide */\n"
9312 "};\n"
9313 msgstr ""
9314 "struct  shminfo {\n"
9315 "    unsigned long shmmax; /* 最大セグメントサイズ */\n"
9316 "    unsigned long shmmin; /* 最小セグメントサイズ。\n"
9317 "                             常に 1 */\n"
9318 "    unsigned long shmmni; /* 最大セグメント数 */\n"
9319 "    unsigned long shmseg; /* プロセスが付加できる\n"
9320 "                             セグメントの最大数。\n"
9321 "                             カーネル内では未使用 */\n"
9322 "    unsigned long shmall; /* 共有メモリの最大ページ数。\n"
9323 "                             システム全体での値 */\n"
9324 "};\n"
9325
9326 #. type: Plain text
9327 #: build/C/man2/shmctl.2:205
9328 msgid ""
9329 "The I<shmmni>, I<shmmax>, and I<shmall> settings can be changed via I</proc> "
9330 "files of the same name; see B<proc>(5)  for details."
9331 msgstr ""
9332 "設定 I<shmmni>, I<shmmax>, I<shmall> は I</proc> にある同じ名前のファイル経由"
9333 "で変更可能である。 詳しくは B<proc>(5)  を参照。"
9334
9335 #. type: TP
9336 #: build/C/man2/shmctl.2:205
9337 #, no-wrap
9338 msgid "B<SHM_INFO> (Linux-specific)"
9339 msgstr "B<SHM_INFO> (Linux 固有)"
9340
9341 #. type: Plain text
9342 #: build/C/man2/shmctl.2:216
9343 msgid ""
9344 "Returns a I<shm_info> structure whose fields contain information about "
9345 "system resources consumed by shared memory.  This structure is defined in "
9346 "I<E<lt>sys/shm.hE<gt>> if the B<_GNU_SOURCE> feature test macro is defined:"
9347 msgstr ""
9348 "共有メモリが消費しているシステム資源に関する情報を 格納した I<shm_info> 構造"
9349 "体を返す。 この構造体は、 B<_GNU_SOURCE> 機能検査マクロが定義された場合に "
9350 "I<E<lt>sys/shm.hE<gt>> で以下のように定義される:"
9351
9352 #. type: Plain text
9353 #: build/C/man2/shmctl.2:233
9354 #, no-wrap
9355 msgid ""
9356 "struct shm_info {\n"
9357 "    int           used_ids; /* # of currently existing\n"
9358 "                               segments */\n"
9359 "    unsigned long shm_tot;  /* Total number of shared\n"
9360 "                               memory pages */\n"
9361 "    unsigned long shm_rss;  /* # of resident shared\n"
9362 "                               memory pages */\n"
9363 "    unsigned long shm_swp;  /* # of swapped shared\n"
9364 "                               memory pages */\n"
9365 "    unsigned long swap_attempts;\n"
9366 "                            /* Unused since Linux 2.4 */\n"
9367 "    unsigned long swap_successes;\n"
9368 "                            /* Unused since Linux 2.4 */\n"
9369 "};\n"
9370 msgstr ""
9371 "struct shm_info {\n"
9372 "    int           used_ids; /* 現在存在するセグメント数 */\n"
9373 "    unsigned long shm_tot;  /* 共有メモリのページ総数 */\n"
9374 "    unsigned long shm_rss;  /* メモリ上にある (スワップされて\n"
9375 "                               いない) 共有メモリページ数 */\n"
9376 "    unsigned long shm_swp;  /* スワップされている共有メモリ\n"
9377 "                               ページ数 */\n"
9378 "    unsigned long swap_attempts;\n"
9379 "                            /* Linux 2.4 以降では未使用 */\n"
9380 "    unsigned long swap_successes;\n"
9381 "                            /* Linux 2.4 以降では未使用 */\n"
9382 "};\n"
9383
9384 #. type: TP
9385 #: build/C/man2/shmctl.2:235
9386 #, no-wrap
9387 msgid "B<SHM_STAT> (Linux-specific)"
9388 msgstr "B<SHM_STAT> (Linux 固有)"
9389
9390 #. type: Plain text
9391 #: build/C/man2/shmctl.2:246
9392 msgid ""
9393 "Returns a I<shmid_ds> structure as for B<IPC_STAT>.  However, the I<shmid> "
9394 "argument is not a segment identifier, but instead an index into the kernel's "
9395 "internal array that maintains information about all shared memory segments "
9396 "on the system."
9397 msgstr ""
9398 "B<IPC_STAT> と同じく I<shmid_ds> 構造体を返す。 但し、 I<shmid> 引き数は、セ"
9399 "グメント識別子ではなく、システム上の全ての共有メモリ セグメントに関する情報を"
9400 "管理するカーネルの内部配列へのインデックス である。"
9401
9402 #. type: Plain text
9403 #: build/C/man2/shmctl.2:249
9404 msgid ""
9405 "The caller can prevent or allow swapping of a shared memory segment with the "
9406 "following I<cmd> values:"
9407 msgstr ""
9408 "呼び出し元は、I<cmd> に以下の値を指定することで、共有メモリ・セグメントが ス"
9409 "ワップされることを防止したり、許可したりできる:"
9410
9411 #. type: TP
9412 #: build/C/man2/shmctl.2:250
9413 #, no-wrap
9414 msgid "B<SHM_LOCK> (Linux-specific)"
9415 msgstr "B<SHM_LOCK> (Linux 固有)"
9416
9417 #. type: Plain text
9418 #: build/C/man2/shmctl.2:262
9419 msgid ""
9420 "Prevent swapping of the shared memory segment.  The caller must fault in any "
9421 "pages that are required to be present after locking is enabled.  If a "
9422 "segment has been locked, then the (nonstandard)  B<SHM_LOCKED> flag of the "
9423 "I<shm_perm.mode> field in the associated data structure retrieved by "
9424 "B<IPC_STAT> will be set."
9425 msgstr ""
9426 "共有メモリ・セグメントをスワップすることを防止する。 ロックが有効になった後、"
9427 "呼び出し元は、 存在することが要求された全てのページをフォールトさせなければな"
9428 "らない。 セグメントがロックされると、 関連するデータ構造体において "
9429 "I<shm_perm.mode> フィールドの (標準的ではない)  B<SHM_LOCKED> フラグが設定さ"
9430 "れる。 このデータ構造体は B<IPC_STAT> で取得される。"
9431
9432 #. type: TP
9433 #: build/C/man2/shmctl.2:262
9434 #, no-wrap
9435 msgid "B<SHM_UNLOCK> (Linux-specific)"
9436 msgstr "B<SHM_UNLOCK> (Linux 固有)"
9437
9438 #. type: Plain text
9439 #: build/C/man2/shmctl.2:265
9440 msgid "Unlock the segment, allowing it to be swapped out."
9441 msgstr "セグメントのロックを解除し、スワップ・アウトすることを可能にする。"
9442
9443 #.  There was some weirdness in 2.6.9: SHM_LOCK and SHM_UNLOCK could
9444 #.  be applied to a segment, regardless of ownership of the segment.
9445 #.  This was a botch-up in the move to RLIMIT_MEMLOCK, and was fixed
9446 #.  in 2.6.10.  MTK, May 2005
9447 #. type: Plain text
9448 #: build/C/man2/shmctl.2:283
9449 msgid ""
9450 "In kernels before 2.6.10, only a privileged process could employ B<SHM_LOCK> "
9451 "and B<SHM_UNLOCK>.  Since kernel 2.6.10, an unprivileged process can employ "
9452 "these operations if its effective UID matches the owner or creator UID of "
9453 "the segment, and (for B<SHM_LOCK>)  the amount of memory to be locked falls "
9454 "within the B<RLIMIT_MEMLOCK> resource limit (see B<setrlimit>(2))."
9455 msgstr ""
9456 "2.6.10 より前のカーネルでは、特権プロセスだけが B<SHM_LOCK> と B<SHM_UNLOCK> "
9457 "を利用することができた。 2.6.10 以降のカーネルでは、非特権プロセスであっても"
9458 "次の条件を満たせば これらの操作を利用することができる。その条件とは、プロセス"
9459 "の実効 UID がそのセグメントの所有者もしくは作成者の UID と一致し、 "
9460 "(B<SHM_LOCK> の場合には) ロックするメモリの合計が B<RLIMIT_MEMLOCK> リソース"
9461 "上限 (B<setrlimit>(2)  参照) の範囲内に入っていることである。"
9462
9463 #. type: Plain text
9464 #: build/C/man2/shmctl.2:301
9465 msgid ""
9466 "A successful B<IPC_INFO> or B<SHM_INFO> operation returns the index of the "
9467 "highest used entry in the kernel's internal array recording information "
9468 "about all shared memory segments.  (This information can be used with "
9469 "repeated B<SHM_STAT> operations to obtain information about all shared "
9470 "memory segments on the system.)  A successful B<SHM_STAT> operation returns "
9471 "the identifier of the shared memory segment whose index was given in "
9472 "I<shmid>.  Other operations return 0 on success."
9473 msgstr ""
9474 "B<IPC_INFO> と B<SHM_INFO> 操作は、成功すると、全ての共有メモリセグメントに関"
9475 "する情報を 管理しているカーネルの内部配列の使用中エントリのインデックスの う"
9476 "ち最大値を返す (この情報は、システムの全ての共有メモリセグメントに関する情報"
9477 "を 取得するために、 B<SHM_STAT> 操作を繰り返し実行する際に使用できる)。 "
9478 "B<SHM_STAT> 操作は、成功すると、 I<shmid> で指定されたインデックスを持つ共有"
9479 "メモリセグメントの識別子を返す。 他の操作は、成功の場合 0 を返す。"
9480
9481 #. type: Plain text
9482 #: build/C/man2/shmctl.2:305
9483 msgid "On error, -1 is returned, and I<errno> is set appropriately."
9484 msgstr "エラーの場合は -1 を返し、 I<errno> を適切に設定する。"
9485
9486 #. type: Plain text
9487 #: build/C/man2/shmctl.2:314
9488 msgid ""
9489 "B<IPC_STAT> or B<SHM_STAT> is requested and I<shm_perm.mode> does not allow "
9490 "read access for I<shmid>, and the calling process does not have the "
9491 "B<CAP_IPC_OWNER> capability."
9492 msgstr ""
9493 "B<IPC_STAT> または B<SHM_STAT> が要求され、 I<shm_perm.mode> が I<shmid> への"
9494 "読み込みアクセスを許しておらず、 かつ呼び出したプロセスが B<CAP_IPC_OWNER> "
9495 "ケーパビリティ (capability) を持っていない。"
9496
9497 #. type: Plain text
9498 #: build/C/man2/shmctl.2:325
9499 msgid ""
9500 "The argument I<cmd> has value B<IPC_SET> or B<IPC_STAT> but the address "
9501 "pointed to by I<buf> isn't accessible."
9502 msgstr ""
9503 "I<cmd> 引き数に B<IPC_SET> か B<IPC_STAT> が指定されたが I<buf> で指されてい"
9504 "るアドレスにアクセスできない。"
9505
9506 #. type: TP
9507 #: build/C/man2/shmctl.2:325 build/C/man2/shmop.2:197
9508 #, no-wrap
9509 msgid "B<EIDRM>"
9510 msgstr "B<EIDRM>"
9511
9512 #. type: Plain text
9513 #: build/C/man2/shmctl.2:328 build/C/man2/shmop.2:200
9514 msgid "I<shmid> points to a removed identifier."
9515 msgstr "I<shmid> が削除 (remove) された識別子 (identifier) を指している。"
9516
9517 #. type: Plain text
9518 #: build/C/man2/shmctl.2:337
9519 msgid ""
9520 "I<shmid> is not a valid identifier, or I<cmd> is not a valid command.  Or: "
9521 "for a B<SHM_STAT> operation, the index value specified in I<shmid> referred "
9522 "to an array slot that is currently unused."
9523 msgstr ""
9524 "I<shmid> が有効な識別子でないか、 I<cmd> が有効なコマンドでない。 もしくは、 "
9525 "B<SHM_STAT> 操作の場合に、 I<shmid> で指定されたインデックス値が現在未使用の"
9526 "配列のスロットを参照していた。"
9527
9528 #. type: Plain text
9529 #: build/C/man2/shmctl.2:348
9530 msgid ""
9531 "(In kernels since 2.6.9), B<SHM_LOCK> was specified and the size of the to-"
9532 "be-locked segment would mean that the total bytes in locked shared memory "
9533 "segments would exceed the limit for the real user ID of the calling "
9534 "process.  This limit is defined by the B<RLIMIT_MEMLOCK> soft resource limit "
9535 "(see B<setrlimit>(2))."
9536 msgstr ""
9537 "(2.6.9 以降のカーネルにおいて)  B<SHM_LOCK> が指定され、 ロックされる予定のセ"
9538 "グメントのサイズ (ロックされる共有メモリ・セグメントの合計バイト数) が、 呼び"
9539 "出したプロセスの実ユーザー ID についての制限を超えた。 この制限は "
9540 "B<RLIMIT_MEMLOCK> ソフト資源制限で定義される (B<setrlimit>(2)  を参照)。"
9541
9542 #. type: Plain text
9543 #: build/C/man2/shmctl.2:353
9544 msgid ""
9545 "B<IPC_STAT> is attempted, and the GID or UID value is too large to be stored "
9546 "in the structure pointed to by I<buf>."
9547 msgstr ""
9548 "B<IPC_STAT> が試みられ、GID や UID の値が I<buf> で指示される構造体に格納する"
9549 "には大き過ぎる。"
9550
9551 #. type: Plain text
9552 #: build/C/man2/shmctl.2:365
9553 msgid ""
9554 "B<IPC_SET> or B<IPC_RMID> is attempted, and the effective user ID of the "
9555 "calling process is not that of the creator (found in I<shm_perm.cuid>), or "
9556 "the owner (found in I<shm_perm.uid>), and the process was not privileged "
9557 "(Linux: did not have the B<CAP_SYS_ADMIN> capability)."
9558 msgstr ""
9559 "B<IPC_SET> か B<IPC_RMID> が試みられ、 呼び出したプロセスの実効ユーザー ID が"
9560 "作成者 (I<shm_perm.cuid>)  でも所有者 (I<shm_perm.uid>)  でもなく、プロセスが"
9561 "特権を持たない (Linux では B<CAP_SYS_ADMIN> ケーパビリティを持たない)。"
9562
9563 #. type: Plain text
9564 #: build/C/man2/shmctl.2:377
9565 msgid ""
9566 "Or (in kernels before 2.6.9), B<SHM_LOCK> or B<SHM_UNLOCK> was specified, "
9567 "but the process was not privileged (Linux: did not have the B<CAP_IPC_LOCK> "
9568 "capability).  (Since Linux 2.6.9, this error can also occur if the "
9569 "B<RLIMIT_MEMLOCK> is 0 and the caller is not privileged.)"
9570 msgstr ""
9571 "または (2.6.9 より前のカーネルで)  B<SHM_LOCK> または B<SHM_UNLOCK> が指定さ"
9572 "れているが、プロセスが特権を持たない (Linux では B<CAP_IPC_LOCK> ケーパビリ"
9573 "ティを持たない)。 (Linux 2.6.9 以降では、 B<RLIMIT_MEMLOCK> が 0 で呼び出し元"
9574 "が特権を持たない場合にも、このエラーが起こる。)"
9575
9576 #.  SVr4 documents an additional error condition EMFILE.
9577 #. type: Plain text
9578 #: build/C/man2/shmctl.2:382 build/C/man2/shmget.2:235
9579 #: build/C/man2/shmop.2:234
9580 msgid "SVr4, POSIX.1-2001."
9581 msgstr "SVr4, POSIX.1-2001."
9582
9583 #.  Like Linux, the FreeBSD man pages still document
9584 #.  the inclusion of these header files.
9585 #. type: Plain text
9586 #: build/C/man2/shmctl.2:395 build/C/man2/shmget.2:251
9587 msgid ""
9588 "The inclusion of I<E<lt>sys/types.hE<gt>> and I<E<lt>sys/ipc.hE<gt>> isn't "
9589 "required on Linux or by any version of POSIX.  However, some old "
9590 "implementations required the inclusion of these header files, and the SVID "
9591 "also documented their inclusion.  Applications intended to be portable to "
9592 "such old systems may need to include these header files."
9593 msgstr ""
9594 "Linux や POSIX の全てのバージョンでは、 I<E<lt>sys/types.hE<gt>> と "
9595 "I<E<lt>sys/ipc.hE<gt>> のインクルードは必要ない。しかしながら、いくつかの古い"
9596 "実装ではこれらのヘッダファイルのインクルードが必要であり、 SVID でもこれらの"
9597 "インクルードをするように記載されている。このような古いシステムへの移植性を意"
9598 "図したアプリケーションではこれらのファイルをインクルードする必要があるかもし"
9599 "れない。"
9600
9601 #. type: Plain text
9602 #: build/C/man2/shmctl.2:407
9603 msgid ""
9604 "The B<IPC_INFO>, B<SHM_STAT> and B<SHM_INFO> operations are used by the "
9605 "B<ipcs>(1)  program to provide information on allocated resources.  In the "
9606 "future these may modified or moved to a I</proc> filesystem interface."
9607 msgstr ""
9608 "B<IPC_INFO>, B<SHM_STAT>, B<SHM_INFO> 操作は、 B<ipcs>(1)  プログラムで割り当"
9609 "て済の資源に関する情報を提供するために 使用されている。将来、これらの操作は変"
9610 "更されたり、 I</proc> ファイルシステムのインタフェースに移動されるかもしれな"
9611 "い。"
9612
9613 #. type: Plain text
9614 #: build/C/man2/shmctl.2:415
9615 msgid ""
9616 "Linux permits a process to attach (B<shmat>(2))  a shared memory segment "
9617 "that has already been marked for deletion using I<shmctl(IPC_RMID)>.  This "
9618 "feature is not available on other UNIX implementations; portable "
9619 "applications should avoid relying on it."
9620 msgstr ""
9621 "Linux では、 I<shmctl(IPC_RMID)> を使ってすでに削除マークがつけられている共有"
9622 "メモリ・セグメントを あるプロセスが付加 (attach)  (B<shmat>(2))  することを許"
9623 "可している。 この機能は他の UNIX の実装では利用できない。 移植性を考慮したア"
9624 "プリケーションではこれに依存しないようにすべきである。"
9625
9626 #. type: Plain text
9627 #: build/C/man2/shmctl.2:428
9628 msgid ""
9629 "Various fields in a I<struct shmid_ds> were typed as I<short> under Linux "
9630 "2.2 and have become I<long> under Linux 2.4.  To take advantage of this, a "
9631 "recompilation under glibc-2.1.91 or later should suffice.  (The kernel "
9632 "distinguishes old and new calls by an B<IPC_64> flag in I<cmd>.)"
9633 msgstr ""
9634 "I<構造体 shmid_ds> 内の多くのフィールドは、 Linux 2.2 では I<short> 型だった"
9635 "が、Linux 2.4 では I<long> 型になった。 この利点を生かすには、glibc-2.1.91 以"
9636 "降の環境下で 再コンパイルすれば十分である。 カーネルは新しい形式の呼び出しと"
9637 "古い形式の呼び出しを I<cmd> 内の B<IPC_64> フラグで区別する。"
9638
9639 #. type: Plain text
9640 #: build/C/man2/shmctl.2:435
9641 msgid ""
9642 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
9643 "B<svipc>(7)"
9644 msgstr ""
9645 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
9646 "B<shm_overview>(7), B<svipc>(7)"
9647
9648 #. type: TH
9649 #: build/C/man2/shmget.2:38
9650 #, no-wrap
9651 msgid "SHMGET"
9652 msgstr "SHMGET"
9653
9654 #. type: Plain text
9655 #: build/C/man2/shmget.2:41
9656 msgid "shmget - allocates a System V shared memory segment"
9657 msgstr "shmget - System V 共有メモリ・セグメントを割り当てる"
9658
9659 #. type: Plain text
9660 #: build/C/man2/shmget.2:48
9661 msgid "B<int shmget(key_t >I<key>B<, size_t >I<size>B<, int >I<shmflg>B<);>"
9662 msgstr "B<int shmget(key_t >I<key>B<, size_t >I<size>B<, int >I<shmflg>B<);>"
9663
9664 #. type: Plain text
9665 #: build/C/man2/shmget.2:72
9666 msgid ""
9667 "B<shmget>()  returns the identifier of the System V shared memory segment "
9668 "associated with the value of the argument I<key>.  A new shared memory "
9669 "segment, with size equal to the value of I<size> rounded up to a multiple of "
9670 "B<PAGE_SIZE>, is created if I<key> has the value B<IPC_PRIVATE> or I<key> "
9671 "isn't B<IPC_PRIVATE>, no shared memory segment corresponding to I<key> "
9672 "exists, and B<IPC_CREAT> is specified in I<shmflg>."
9673 msgstr ""
9674 "B<shmget>()  は I<key> 引き数に対応する System V 共有メモリ・セグメントの識別"
9675 "子を返す。 I<key> の値が B<IPC_PRIVATE> の場合、もしくは I<key> に対応する共"
9676 "有メモリ・セグメントが存在せず、 I<shmflg> に B<IPC_CREAT> が指定されていた場"
9677 "合、 新しい共有メモリ・セグメントを作成する。 作成される共有メモリ・セグメン"
9678 "トは、 I<size> 引き数の値を B<PAGE_SIZE> の倍数へと切り上げた (round up) 大き"
9679 "さとなる。"
9680
9681 #. type: Plain text
9682 #: build/C/man2/shmget.2:91
9683 msgid ""
9684 "If I<shmflg> specifies both B<IPC_CREAT> and B<IPC_EXCL> and a shared memory "
9685 "segment already exists for I<key>, then B<shmget>()  fails with I<errno> set "
9686 "to B<EEXIST>.  (This is analogous to the effect of the combination B<O_CREAT "
9687 "| O_EXCL> for B<open>(2).)"
9688 msgstr ""
9689 "I<shmflg> に B<IPC_CREAT> と B<IPC_EXCL> の両方が指定された場合、 I<key> に対"
9690 "応する共有メモリ・セグメントが既に存在すると、 B<shmget>()  は失敗し、 "
9691 "I<errno> に B<EEXIST> が設定される (これは B<open>(2)  に B<O_CREAT | "
9692 "O_EXCL> を指定した場合の動作と同じである)。"
9693
9694 #. type: Plain text
9695 #: build/C/man2/shmget.2:95
9696 msgid "The value I<shmflg> is composed of:"
9697 msgstr "I<shmflg> は以下の内容から構成される:"
9698
9699 #. type: TP
9700 #: build/C/man2/shmget.2:95
9701 #, no-wrap
9702 msgid "B<IPC_CREAT>"
9703 msgstr "B<IPC_CREAT>"
9704
9705 #. type: Plain text
9706 #: build/C/man2/shmget.2:102
9707 msgid ""
9708 "to create a new segment.  If this flag is not used, then B<shmget>()  will "
9709 "find the segment associated with I<key> and check to see if the user has "
9710 "permission to access the segment."
9711 msgstr ""
9712 "新しいセグメントを作成する。このフラグが指定されなかった場合、 B<shmget>()  "
9713 "は I<key> に対応するセグメントを探し、 ユーザがそのセグメントにアクセスする許"
9714 "可があるかどうかをチェックする。"
9715
9716 #. type: TP
9717 #: build/C/man2/shmget.2:102
9718 #, no-wrap
9719 msgid "B<IPC_EXCL>"
9720 msgstr "B<IPC_EXCL>"
9721
9722 #. type: Plain text
9723 #: build/C/man2/shmget.2:105
9724 msgid "used with B<IPC_CREAT> to ensure failure if the segment already exists."
9725 msgstr ""
9726 "B<IPC_CREAT> と共に使用し、セグメントが既に存在した場合には 失敗することを保"
9727 "証する。"
9728
9729 #. type: TP
9730 #: build/C/man2/shmget.2:105
9731 #, no-wrap
9732 msgid "I<mode_flags>"
9733 msgstr "I<mode_flags>"
9734
9735 #. type: Plain text
9736 #: build/C/man2/shmget.2:115
9737 msgid ""
9738 "(least significant 9 bits)  specifying the permissions granted to the owner, "
9739 "group, and world.  These bits have the same format, and the same meaning, as "
9740 "the I<mode> argument of B<open>(2).  Presently, the execute permissions are "
9741 "not used by the system."
9742 msgstr ""
9743 "(下位 9 ビット)  所有者、グループ、他人 (world) への許可を指定する。 これらの"
9744 "ビットは B<open>(2)  の I<mode> 引き数と同じ形式で同じ意味を持つ。 今のとこ"
9745 "ろ、システムは実行 (execute) 許可を参照しない。"
9746
9747 #. type: TP
9748 #: build/C/man2/shmget.2:115
9749 #, no-wrap
9750 msgid "B<SHM_HUGETLB> (since Linux 2.6)"
9751 msgstr "B<SHM_HUGETLB> (Linux 2.6 以降)"
9752
9753 #. type: Plain text
9754 #: build/C/man2/shmget.2:121
9755 msgid ""
9756 "Allocate the segment using \"huge pages.\" See the Linux kernel source file "
9757 "I<Documentation/vm/hugetlbpage.txt> for further information."
9758 msgstr ""
9759 "\"ヒュージページ (huge page)\" を使うセグメントを割り当てる。詳細な情報は、"
9760 "Linux カーネルソースのファイル I<Documentation/vm/hugetlbpage.txt> を参照。"
9761
9762 #. type: TP
9763 #: build/C/man2/shmget.2:121
9764 #, no-wrap
9765 msgid "B<SHM_NORESERVE> (since Linux 2.6.15)"
9766 msgstr "B<SHM_NORESERVE> (Linux 2.6.15 以降)"
9767
9768 #.  As at 2.6.17-rc2, this flag has no effect if SHM_HUGETLB was also
9769 #.  specified.
9770 #. type: Plain text
9771 #: build/C/man2/shmget.2:140
9772 msgid ""
9773 "This flag serves the same purpose as the B<mmap>(2)  B<MAP_NORESERVE> flag.  "
9774 "Do not reserve swap space for this segment.  When swap space is reserved, "
9775 "one has the guarantee that it is possible to modify the segment.  When swap "
9776 "space is not reserved one might get B<SIGSEGV> upon a write if no physical "
9777 "memory is available.  See also the discussion of the file I</proc/sys/vm/"
9778 "overcommit_memory> in B<proc>(5)."
9779 msgstr ""
9780 "このフラグは、 B<mmap>(2)  の B<MAP_NORESERVE> フラグと同じ役割を果たす。 こ"
9781 "のセグメントに対するスワップ空間の予約を行わない。 スワップ空間を予約した場合"
9782 "は、そのセグメントの変更が必ず成功することが 保証される。スワップ空間の予約を"
9783 "行わなかった場合は、物理メモリに空きが ないと書き込み時に B<SIGSEGV> を受け取"
9784 "る可能性がある。 B<proc>(5)  にある I</proc/sys/vm/overcommit_memory> ファイ"
9785 "ルに関する議論も参照のこと。"
9786
9787 #. type: Plain text
9788 #: build/C/man2/shmget.2:148
9789 msgid ""
9790 "When a new shared memory segment is created, its contents are initialized to "
9791 "zero values, and its associated data structure, I<shmid_ds> (see B<shmctl>"
9792 "(2)), is initialized as follows:"
9793 msgstr ""
9794 "共有メモリ・セグメントが新たに作成される際、 共有メモリ・セグメントの内容は "
9795 "0 で初期化され、 関連情報を保持するデータ構造体 I<shmid_ds> は以下のように初"
9796 "期化される。"
9797
9798 #. type: Plain text
9799 #: build/C/man2/shmget.2:153
9800 msgid ""
9801 "I<shm_perm.cuid> and I<shm_perm.uid> are set to the effective user ID of the "
9802 "calling process."
9803 msgstr ""
9804 "I<shm_perm.cuid> と I<shm_perm.uid> に呼び出し元プロセスの実効 (effective) "
9805 "ユーザーID を設定する。"
9806
9807 #. type: Plain text
9808 #: build/C/man2/shmget.2:158
9809 msgid ""
9810 "I<shm_perm.cgid> and I<shm_perm.gid> are set to the effective group ID of "
9811 "the calling process."
9812 msgstr ""
9813 "I<shm_perm.cgid> と I<shm_perm.gid> に呼び出し元プロセスの実効グループID を設"
9814 "定する。"
9815
9816 #. type: Plain text
9817 #: build/C/man2/shmget.2:163
9818 msgid ""
9819 "The least significant 9 bits of I<shm_perm.mode> are set to the least "
9820 "significant 9 bit of I<shmflg>."
9821 msgstr ""
9822 "I<shm_perm.mode> の下位 9 ビットに I<shmflg> の下位 9 ビットを設定する。"
9823
9824 #. type: Plain text
9825 #: build/C/man2/shmget.2:167
9826 msgid "I<shm_segsz> is set to the value of I<size>."
9827 msgstr "I<shm_segsz> に I<size> の値を設定する。"
9828
9829 #. type: Plain text
9830 #: build/C/man2/shmget.2:174
9831 msgid ""
9832 "I<shm_lpid>, I<shm_nattch>, I<shm_atime>, and I<shm_dtime> are set to 0."
9833 msgstr ""
9834 "I<shm_lpid>, I<shm_nattch>, I<shm_atime>, I<shm_dtime> に 0 を設定する。"
9835
9836 #. type: Plain text
9837 #: build/C/man2/shmget.2:177
9838 msgid "I<shm_ctime> is set to the current time."
9839 msgstr "I<shm_ctime> に現在の時刻を設定する。"
9840
9841 #. type: Plain text
9842 #: build/C/man2/shmget.2:180
9843 msgid ""
9844 "If the shared memory segment already exists, the permissions are verified, "
9845 "and a check is made to see if it is marked for destruction."
9846 msgstr ""
9847 "共有メモリ・セグメントが既に存在する場合、アクセス許可の検査と、 破壊 "
9848 "(destruction) マークがつけられていないかのチェックが行われる。"
9849
9850 #. type: Plain text
9851 #: build/C/man2/shmget.2:185
9852 msgid ""
9853 "On success, a valid shared memory identifier is returned.  On error, -1 is "
9854 "returned, and I<errno> is set to indicate the error."
9855 msgstr ""
9856 "成功の場合、有効な共有メモリ・セグメントの識別子が返される。 エラーの場合、 "
9857 "-1 が返り、 I<error> にエラーを示す値が設定される。"
9858
9859 #. type: Plain text
9860 #: build/C/man2/shmget.2:189
9861 msgid "On failure, I<errno> is set to one of the following:"
9862 msgstr "失敗した場合は I<errno> が以下のどれかに設定される:"
9863
9864 #. type: Plain text
9865 #: build/C/man2/shmget.2:195
9866 msgid ""
9867 "The user does not have permission to access the shared memory segment, and "
9868 "does not have the B<CAP_IPC_OWNER> capability."
9869 msgstr ""
9870 "ユーザーはその共有メモリ・セグメントへのアクセス許可を持たず、 "
9871 "B<CAP_IPC_OWNER> ケーパビリティも持っていない。"
9872
9873 #. type: Plain text
9874 #: build/C/man2/shmget.2:199
9875 msgid "B<IPC_CREAT | IPC_EXCL> was specified and the segment exists."
9876 msgstr ""
9877 "B<IPC_CREAT | IPC_EXCL> が指定されていたが、そのセグメントが既に存在する。"
9878
9879 #. type: Plain text
9880 #: build/C/man2/shmget.2:205
9881 msgid ""
9882 "A new segment was to be created and I<size> E<lt> B<SHMMIN> or I<size> E<gt> "
9883 "B<SHMMAX>, or no new segment was to be created, a segment with given key "
9884 "existed, but I<size> is greater than the size of that segment."
9885 msgstr ""
9886 "新しいセグメントを作成しようとした際に I<size> E<lt> B<SHMMIN> または "
9887 "I<size> E<gt> B<SHMMAX> であった。 もしくは、指定されたキーに対応するセグメン"
9888 "トが既に存在して、新しい セグメントを作成しようとはしなかったが、I<size> が存"
9889 "在するセグメントの サイズよりも大きかった。"
9890
9891 #. type: Plain text
9892 #: build/C/man2/shmget.2:214
9893 msgid ""
9894 "No segment exists for the given I<key>, and B<IPC_CREAT> was not specified."
9895 msgstr ""
9896 "指定された I<key> に対応するセグメントが存在せず、 B<IPC_CREAT> も指定されて"
9897 "いなかった。"
9898
9899 #. type: Plain text
9900 #: build/C/man2/shmget.2:217
9901 msgid "No memory could be allocated for segment overhead."
9902 msgstr "セグメントの管理情報 (overhead) に割り当てるメモリがなかった。"
9903
9904 #. type: Plain text
9905 #: build/C/man2/shmget.2:225
9906 msgid ""
9907 "All possible shared memory IDs have been taken (B<SHMMNI>), or allocating a "
9908 "segment of the requested I<size> would cause the system to exceed the system-"
9909 "wide limit on shared memory (B<SHMALL>)."
9910 msgstr ""
9911 "システム全体の共有メモリ・セグメント数の制限 (B<SHMMNI>)  に達した、または要"
9912 "求された I<size> のセグメントの割り当てが システム全体の共有メモリサイズの制"
9913 "限 (B<SHMALL>)  を超過した。"
9914
9915 #. type: Plain text
9916 #: build/C/man2/shmget.2:232
9917 msgid ""
9918 "The B<SHM_HUGETLB> flag was specified, but the caller was not privileged "
9919 "(did not have the B<CAP_IPC_LOCK> capability)."
9920 msgstr ""
9921 "B<SHM_HUGETLB> フラグが指定されたが、呼び出し元には権限がなかった "
9922 "(B<CAP_IPC_LOCK> ケーパビリティを持っていなかった)。"
9923
9924 #. type: Plain text
9925 #: build/C/man2/shmget.2:238
9926 msgid "B<SHM_HUGETLB> is a nonportable Linux extension."
9927 msgstr "B<SHM_HUGETLB> は Linux での拡張であり、移植性はない。"
9928
9929 #. type: Plain text
9930 #: build/C/man2/shmget.2:261
9931 msgid ""
9932 "B<IPC_PRIVATE> isn't a flag field but a I<key_t> type.  If this special "
9933 "value is used for I<key>, the system call ignores everything but the least "
9934 "significant 9 bits of I<shmflg> and creates a new shared memory segment (on "
9935 "success)."
9936 msgstr ""
9937 "B<IPC_PRIVATE> はフラグではなく I<key_t> 型である。 この特別な値が I<key> に"
9938 "使用された場合は、 B<shmget>()  は I<shmflg> の下位 9 ビットを除いた全てを無"
9939 "視し、 (成功すれば) 新しい共有メモリ・セグメントを作成する。"
9940
9941 #. type: Plain text
9942 #: build/C/man2/shmget.2:265
9943 msgid ""
9944 "The following limits on shared memory segment resources affect the B<shmget>"
9945 "()  call:"
9946 msgstr ""
9947 "B<shmget>()  コールに影響する共有メモリ・セグメント資源の制限は以下の通りであ"
9948 "る:"
9949
9950 #. type: TP
9951 #: build/C/man2/shmget.2:265
9952 #, no-wrap
9953 msgid "B<SHMALL>"
9954 msgstr "B<SHMALL>"
9955
9956 #. type: Plain text
9957 #: build/C/man2/shmget.2:269
9958 msgid ""
9959 "System wide maximum of shared memory pages.  Since Linux 2.2, the default "
9960 "value for this limit is"
9961 msgstr "システム全体の共有メモリ・ページの最大数。 Linux 2.2 以降では、この上限値のデフォルトは以下である。"
9962
9963 #. type: Plain text
9964 #: build/C/man2/shmget.2:271
9965 #, no-wrap
9966 msgid "    SHMMAX / PAGE_SIZE * (SHMMNI / 16)\n"
9967 msgstr "    SHMMAX / PAGE_SIZE * (SHMMNI / 16)\n"
9968
9969 #. type: Plain text
9970 #: build/C/man2/shmget.2:274
9971 msgid ""
9972 "Assuming a 4kB page size, this formula yields (since Linux 2.4) the value "
9973 "2^20 (2,097,152)."
9974 msgstr "4kB ページサイズと仮定すると、 (Linux 2.4 以降では) この式の結果は 2^20 (2,097,152) になる。"
9975
9976 #. type: Plain text
9977 #: build/C/man2/shmget.2:277
9978 msgid ""
9979 "On Linux, this limit can be read and modified via I</proc/sys/kernel/shmall>."
9980 msgstr "Linux では、この上限値は I</proc/sys/kernel/shmall> 経由で参照したり、変更したりできる。"
9981
9982 #. type: TP
9983 #: build/C/man2/shmget.2:277
9984 #, no-wrap
9985 msgid "B<SHMMAX>"
9986 msgstr "B<SHMMAX>"
9987
9988 #. type: Plain text
9989 #: build/C/man2/shmget.2:281
9990 msgid ""
9991 "Maximum size in bytes for a shared memory segment.  Since Linux 2.2, the "
9992 "default value of this limit is 0x2000000 (32MB)."
9993 msgstr "共有メモリ・セグメントの最大バイト数。 Linux 2.2 以降では、 この上限値のデフォルトは 0x2000000 (32MB) である。"
9994
9995 #. type: Plain text
9996 #: build/C/man2/shmget.2:284
9997 msgid ""
9998 "On Linux, this limit can be read and modified via I</proc/sys/kernel/shmmax>."
9999 msgstr "Linux では、この上限値は I</proc/sys/kernel/shmmax> 経由で参照したり、変更したりできる。"
10000
10001 #. type: TP
10002 #: build/C/man2/shmget.2:284
10003 #, no-wrap
10004 msgid "B<SHMMIN>"
10005 msgstr "B<SHMMIN>"
10006
10007 #. type: Plain text
10008 #: build/C/man2/shmget.2:290
10009 msgid ""
10010 "Minimum size in bytes for a shared memory segment: implementation dependent "
10011 "(currently 1 byte, though B<PAGE_SIZE> is the effective minimum size)."
10012 msgstr ""
10013 "共有メモリ・セグメントのバイト単位の大きさの下限: 実装依存 (現在は 1 バイトだ"
10014 "が、実質的な最小サイズは B<PAGE_SIZE> である)。"
10015
10016 #. type: TP
10017 #: build/C/man2/shmget.2:290
10018 #, no-wrap
10019 msgid "B<SHMMNI>"
10020 msgstr "B<SHMMNI>"
10021
10022 #. type: Plain text
10023 #: build/C/man2/shmget.2:295
10024 msgid ""
10025 "System wide maximum number of shared memory segments.  In Linux 2.2, the "
10026 "default value for this limit was 128; since Linux 2.4, the default value is "
10027 "4096."
10028 msgstr "システム全体の共有メモリ・セグメントの最大数。 この上限値のデフォルトは、 Linux 2.2 以降では 128、 Linux 2.4 以降で 4096 である。"
10029
10030 #.  Kernels between 2.4.x and 2.6.8 had an off-by-one error that meant
10031 #.  that we could create one more segment than SHMMNI -- MTK
10032 #.  This /proc file is not available in Linux 2.2 and earlier -- MTK
10033 #. type: Plain text
10034 #: build/C/man2/shmget.2:301
10035 msgid ""
10036 "On Linux, this limit can be read and modified via I</proc/sys/kernel/shmmni>."
10037 msgstr "Linux では、この上限値は I</proc/sys/kernel/shmmni> 経由で参照したり、変更したりできる。"
10038
10039 #. type: Plain text
10040 #: build/C/man2/shmget.2:305
10041 msgid ""
10042 "The implementation has no specific limits for the per-process maximum number "
10043 "of shared memory segments (B<SHMSEG>)."
10044 msgstr ""
10045 "プロセス当りの共有メモリ・セグメントの個数の最大値 (B<SHMSEG>)  に関する実装"
10046 "上の制限はない。"
10047
10048 #. type: Plain text
10049 #: build/C/man2/shmget.2:311
10050 msgid ""
10051 "Until version 2.3.30 Linux would return B<EIDRM> for a B<shmget>()  on a "
10052 "shared memory segment scheduled for deletion."
10053 msgstr ""
10054 "バージョン 2.3.30 までは、Linux は 削除が予定されている共有メモリ・セグメント"
10055 "に対して B<shmget>()  が行われると B<EIDRM> を返していた。"
10056
10057 #. type: Plain text
10058 #: build/C/man2/shmget.2:317
10059 msgid ""
10060 "The name choice B<IPC_PRIVATE> was perhaps unfortunate, B<IPC_NEW> would "
10061 "more clearly show its function."
10062 msgstr ""
10063 "B<IPC_PRIVATE> という名前を選んだのはおそらく失敗であろう。 B<IPC_NEW> の方が"
10064 "より明確にその機能を表しているだろう。"
10065
10066 #. type: Plain text
10067 #: build/C/man2/shmget.2:325
10068 msgid ""
10069 "B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), "
10070 "B<shm_overview>(7), B<svipc>(7)"
10071 msgstr ""
10072 "B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), "
10073 "B<shm_overview>(7), B<svipc>(7)"
10074
10075 #. type: TH
10076 #: build/C/man2/shmop.2:41
10077 #, no-wrap
10078 msgid "SHMOP"
10079 msgstr "SHMOP"
10080
10081 #. type: Plain text
10082 #: build/C/man2/shmop.2:44
10083 msgid "shmat, shmdt - System V shared memory operations"
10084 msgstr "shmat, shmdt - System V 共有メモリ (shared memory) の操作"
10085
10086 #. type: Plain text
10087 #: build/C/man2/shmop.2:48
10088 #, no-wrap
10089 msgid ""
10090 "B<#include E<lt>sys/types.hE<gt>>\n"
10091 "B<#include E<lt>sys/shm.hE<gt>>\n"
10092 msgstr ""
10093 "B<#include E<lt>sys/types.hE<gt>>\n"
10094 "B<#include E<lt>sys/shm.hE<gt>>\n"
10095
10096 #. type: Plain text
10097 #: build/C/man2/shmop.2:50
10098 #, no-wrap
10099 msgid "B<void *shmat(int >I<shmid>B<, const void *>I<shmaddr>B<, int >I<shmflg>B<);>\n"
10100 msgstr "B<void *shmat(int >I<shmid>B<, const void *>I<shmaddr>B<, int >I<shmflg>B<);>\n"
10101
10102 #. type: Plain text
10103 #: build/C/man2/shmop.2:52
10104 #, no-wrap
10105 msgid "B<int shmdt(const void *>I<shmaddr>B<);>\n"
10106 msgstr "B<int shmdt(const void *>I<shmaddr>B<);>\n"
10107
10108 #. type: Plain text
10109 #: build/C/man2/shmop.2:61
10110 msgid ""
10111 "B<shmat>()  attaches the System V shared memory segment identified by "
10112 "I<shmid> to the address space of the calling process.  The attaching address "
10113 "is specified by I<shmaddr> with one of the following criteria:"
10114 msgstr ""
10115 "B<shmat>()  は I<shmid> で指定された System V 共有メモリ・セグメント (shared "
10116 "memory segment) を コールしたプロセスのアドレス空間に付加 (attach) する。 付"
10117 "加するアドレスは I<shmaddr> に以下のどれかの形式で指定する:"
10118
10119 #. type: Plain text
10120 #: build/C/man2/shmop.2:67
10121 msgid ""
10122 "If I<shmaddr> is NULL, the system chooses a suitable (unused) address at "
10123 "which to attach the segment."
10124 msgstr ""
10125 "I<shmaddr> が NULL ならば、システムはセグメントを付加するための 適切な (使用"
10126 "されていない) アドレスを選択する。"
10127
10128 #. type: Plain text
10129 #: build/C/man2/shmop.2:82
10130 msgid ""
10131 "If I<shmaddr> isn't NULL and B<SHM_RND> is specified in I<shmflg>, the "
10132 "attach occurs at the address equal to I<shmaddr> rounded down to the nearest "
10133 "multiple of B<SHMLBA>.  Otherwise I<shmaddr> must be a page-aligned address "
10134 "at which the attach occurs."
10135 msgstr ""
10136 "I<shmaddr> が NULL でなく B<SHM_RND> が I<shmflg> に指定されている場合は、 "
10137 "I<shmaddr> を B<SHMLBA> の倍数へと切り捨てた (rounding down) のと等しいアドレ"
10138 "スへ付加する。 その他の場合は I<shmaddr> は付加を行なうアドレスで、ページ境界"
10139 "を指している必要がある。"
10140
10141 #. type: Plain text
10142 #: build/C/man2/shmop.2:92
10143 msgid ""
10144 "If B<SHM_RDONLY> is specified in I<shmflg>, the segment is attached for "
10145 "reading and the process must have read permission for the segment.  "
10146 "Otherwise the segment is attached for read and write and the process must "
10147 "have read and write permission for the segment.  There is no notion of a "
10148 "write-only shared memory segment."
10149 msgstr ""
10150 "B<SHM_RDONLY> が I<shmflg> に指定されていた場合は、 セグメントは読み込み専用"
10151 "に付加され、プロセスはそのセグメントへの 読み込み許可を持たなければならな"
10152 "い。 そうでなければそのセグメントは読み込みと書き込みのために付加され、 プロ"
10153 "セスはそのセグメントに読み込みと書き込みの許可を持つ必要がある。 書き込み専用"
10154 "の共有メモリ・セグメントという概念は存在しない。"
10155
10156 #. type: Plain text
10157 #: build/C/man2/shmop.2:107
10158 msgid ""
10159 "The (Linux-specific)  B<SHM_REMAP> flag may be specified in I<shmflg> to "
10160 "indicate that the mapping of the segment should replace any existing mapping "
10161 "in the range starting at I<shmaddr> and continuing for the size of the "
10162 "segment.  (Normally an B<EINVAL> error would result if a mapping already "
10163 "exists in this address range.)  In this case, I<shmaddr> must not be NULL."
10164 msgstr ""
10165 "(Linux 特有の)  B<SHM_REMAP> フラグが I<shmflg> に指定された場合は、 セグメン"
10166 "トのマッピングを既存のマッピングに置き換える。 マッピングの範囲は、 "
10167 "I<shmaddr> から始まりセグメントのサイズ分だけある (通常 B<EINVAL> エラーは、"
10168 "このアドレス範囲にマッピングが既に存在するために起る)。 このフラグを指定する"
10169 "場合は、 I<shmaddr> が NULL であってはならない。"
10170
10171 #. type: Plain text
10172 #: build/C/man2/shmop.2:114
10173 msgid ""
10174 "The B<brk>(2)  value of the calling process is not altered by the attach.  "
10175 "The segment will automatically be detached at process exit.  The same "
10176 "segment may be attached as a read and as a read-write one, and more than "
10177 "once, in the process's address space."
10178 msgstr ""
10179 "呼び出したプロセスの B<brk>(2)  の値は付加によって変化しない。 そのセグメント"
10180 "はプロセスが終了 (exit) したら自動的に分離 (detach) される。 同じセグメントを"
10181 "プロセスのアドレス空間に、読み込み専用および読み書き両用 として付加でき、また"
10182 "複数回付加することもできる。"
10183
10184 #. type: Plain text
10185 #: build/C/man2/shmop.2:122
10186 msgid ""
10187 "A successful B<shmat>()  call updates the members of the I<shmid_ds> "
10188 "structure (see B<shmctl>(2))  associated with the shared memory segment as "
10189 "follows:"
10190 msgstr ""
10191 "成功した B<shmat>()  コールは共有メモリ・セグメントに関連する I<shmid_ds> 構"
10192 "造体 (B<shmctl>(2)  を参照) のメンバーを以下のように更新する:"
10193
10194 #. type: Plain text
10195 #: build/C/man2/shmop.2:125
10196 msgid "I<shm_atime> is set to the current time."
10197 msgstr "I<shm_atime> には現在の時刻を設定する。"
10198
10199 #. type: Plain text
10200 #: build/C/man2/shmop.2:128 build/C/man2/shmop.2:154
10201 msgid "I<shm_lpid> is set to the process-ID of the calling process."
10202 msgstr "I<shm_lpid> には呼び出したプロセスのプロセス ID が設定される。"
10203
10204 #. type: Plain text
10205 #: build/C/man2/shmop.2:131
10206 msgid "I<shm_nattch> is incremented by one."
10207 msgstr "I<shm_nattch> を 1 増加させる。"
10208
10209 #. type: Plain text
10210 #: build/C/man2/shmop.2:142
10211 msgid ""
10212 "B<shmdt>()  detaches the shared memory segment located at the address "
10213 "specified by I<shmaddr> from the address space of the calling process.  The "
10214 "to-be-detached segment must be currently attached with I<shmaddr> equal to "
10215 "the value returned by the attaching B<shmat>()  call."
10216 msgstr ""
10217 "B<shmdt>()  は呼び出したプロセスのアドレス空間から I<shmaddr> で指定されたア"
10218 "ドレスに配置された共有メモリ・セグメントを分離 (detach) する。 分離する共有メ"
10219 "モリ・セグメントは、現在 I<shmaddr> に付加されているものでなければならない。 "
10220 "I<shmaddr> は、それを付加した時に B<shmat>()  が返した値に等しくなければなら"
10221 "ない。"
10222
10223 #. type: Plain text
10224 #: build/C/man2/shmop.2:148
10225 msgid ""
10226 "On a successful B<shmdt>()  call the system updates the members of the "
10227 "I<shmid_ds> structure associated with the shared memory segment as follows:"
10228 msgstr ""
10229 "成功した B<shmdt>()  コールはその共有メモリ・セグメントに関連する "
10230 "I<shmid_ds> 構造体のメンバーを以下のように更新する:"
10231
10232 #. type: Plain text
10233 #: build/C/man2/shmop.2:151
10234 msgid "I<shm_dtime> is set to the current time."
10235 msgstr "I<shm_dtime> には現在の時刻が設定される。"
10236
10237 #. type: Plain text
10238 #: build/C/man2/shmop.2:159
10239 msgid ""
10240 "I<shm_nattch> is decremented by one.  If it becomes 0 and the segment is "
10241 "marked for deletion, the segment is deleted."
10242 msgstr ""
10243 "I<shm_nattch> を 1 減少させる。 もし 0 になり、削除マークがあった場合は その"
10244 "セグメントは削除される。"
10245
10246 #. type: Plain text
10247 #: build/C/man2/shmop.2:163
10248 msgid ""
10249 "After a B<fork>(2)  the child inherits the attached shared memory segments."
10250 msgstr ""
10251 "B<fork>(2)  した後、子プロセスは付加された共有メモリ・セグメントを継承する。"
10252
10253 #. type: Plain text
10254 #: build/C/man2/shmop.2:167
10255 msgid ""
10256 "After an B<execve>(2)  all attached shared memory segments are detached from "
10257 "the process."
10258 msgstr ""
10259 "B<exec>(2)  した後、全ての付加された共有メモリ・セグメントはプロセスから分離"
10260 "される。"
10261
10262 #. type: Plain text
10263 #: build/C/man2/shmop.2:171
10264 msgid ""
10265 "Upon B<_exit>(2)  all attached shared memory segments are detached from the "
10266 "process."
10267 msgstr ""
10268 "B<exit>(2)  において、全ての付加された共有メモリ・セグメントはプロセスから分"
10269 "離される。"
10270
10271 #. type: Plain text
10272 #: build/C/man2/shmop.2:179
10273 msgid ""
10274 "On success B<shmat>()  returns the address of the attached shared memory "
10275 "segment; on error I<(void\\ *)\\ -1> is returned, and I<errno> is set to "
10276 "indicate the cause of the error."
10277 msgstr ""
10278 "B<shmat>()  は、成功した場合、 付加された共有メモリ・セグメントのアドレスを返"
10279 "す。 エラーの場合、 I<(void\\ *)\\ -1> を返し、 I<errno> にエラーの原因を示す"
10280 "値を設定する。"
10281
10282 #. type: Plain text
10283 #: build/C/man2/shmop.2:185
10284 msgid ""
10285 "On success B<shmdt>()  returns 0; on error -1 is returned, and I<errno> is "
10286 "set to indicate the cause of the error."
10287 msgstr ""
10288 "B<shmdt>()  は、成功すると 0 を返す。 エラーの場合、-1 を返し、 I<errno> にエ"
10289 "ラーの原因を示す値を設定する。"
10290
10291 #. type: Plain text
10292 #: build/C/man2/shmop.2:191
10293 msgid "When B<shmat>()  fails, I<errno> is set to one of the following:"
10294 msgstr ""
10295 "B<shmat>()  が失敗した場合、 I<errno> に以下の値のどれかを設定して返す:"
10296
10297 #. type: Plain text
10298 #: build/C/man2/shmop.2:197
10299 msgid ""
10300 "The calling process does not have the required permissions for the requested "
10301 "attach type, and does not have the B<CAP_IPC_OWNER> capability."
10302 msgstr ""
10303 "呼び出したプロセスに要求された種類の付加に必要な許可がなく、 "
10304 "B<CAP_IPC_OWNER> ケーパビリティ (capability) がない。"
10305
10306 #. type: Plain text
10307 #: build/C/man2/shmop.2:214
10308 msgid ""
10309 "Invalid I<shmid> value, unaligned (i.e., not page-aligned and B<SHM_RND> was "
10310 "not specified) or invalid I<shmaddr> value, or can't attach segment at "
10311 "I<shmaddr>, or B<SHM_REMAP> was specified and I<shmaddr> was NULL."
10312 msgstr ""
10313 "I<shmid> の値が不正である。 I<shmaddr> の値が境界違反 (unaligned) (つまり、"
10314 "ページ境界に合っておらず、 B<SHM_RND> が指定されていない) または が不正であ"
10315 "る。 I<shmaddr> へのセグメントの付加に失敗した。 または B<SHM_REMAP> が指定さ"
10316 "れているが、 I<shmaddr> が NULL であった。"
10317
10318 #. type: Plain text
10319 #: build/C/man2/shmop.2:217
10320 msgid "Could not allocate memory for the descriptor or for the page tables."
10321 msgstr ""
10322 "ディスクリプター (descriptor) やページ・テーブルのためのメモリを 割り当てるこ"
10323 "とができない。"
10324
10325 #. type: Plain text
10326 #: build/C/man2/shmop.2:223
10327 msgid "When B<shmdt>()  fails, I<errno> is set as follows:"
10328 msgstr "B<shmdt>()  が失敗した場合、 B<EINVAL> は以下のようにセットされる:"
10329
10330 #.  The following since 2.6.17-rc1:
10331 #. type: Plain text
10332 #: build/C/man2/shmop.2:231
10333 msgid ""
10334 "There is no shared memory segment attached at I<shmaddr>; or, I<shmaddr> is "
10335 "not aligned on a page boundary."
10336 msgstr ""
10337 "I<shmaddr> に付加された共有メモリ・セグメントが存在しない。 もしくは、 "
10338 "I<shmaddr> がページ境界に合っていない。"
10339
10340 #. type: Plain text
10341 #: build/C/man2/shmop.2:250
10342 msgid ""
10343 "In SVID 3 (or perhaps earlier)  the type of the I<shmaddr> argument was "
10344 "changed from I<char\\ *> into I<const void\\ *>, and the returned type of "
10345 "B<shmat>()  from I<char\\ *> into I<void\\ *>.  (Linux libc4 and libc5 have "
10346 "the I<char\\ *> prototypes; glibc2 has I<void\\ *>.)"
10347 msgstr ""
10348 "SVID 3 で (たぶんそれより前だと思うが)  I<shmaddr> 引き数の型は I<char\\ *> "
10349 "から I<const void\\ *> に、I<shmat>() の返り値の型は I<char\\ *> から I<void"
10350 "\\ *> に変更された (Linux では libc4 と libc5 のプロトタイプは I<char\\ *> で"
10351 "あり、glibc2 のプロトタイプは I<void\\ *> である)。"
10352
10353 #. type: Plain text
10354 #: build/C/man2/shmop.2:262
10355 msgid ""
10356 "Using B<shmat>()  with I<shmaddr> equal to NULL is the preferred, portable "
10357 "way of attaching a shared memory segment.  Be aware that the shared memory "
10358 "segment attached in this way may be attached at different addresses in "
10359 "different processes.  Therefore, any pointers maintained within the shared "
10360 "memory must be made relative (typically to the starting address of the "
10361 "segment), rather than absolute."
10362 msgstr ""
10363 "共有メモリセグメントを付加する場合の移植性の高い方法としては、 I<shmaddr> を "
10364 "NULL にして B<shmat>()  を使用するのがよい。 このような方法で付加される共有メ"
10365 "モリセグメントは、 プロセスが異なれば別のアドレスに付加される、という点に注意"
10366 "すること。 よって共有メモリ内で管理されるポインタは、 絶対アドレスではなく、 "
10367 "(一般的にはセグメントの開始アドレスからの)  相対アドレスで作成するべきであ"
10368 "る。"
10369
10370 #. type: Plain text
10371 #: build/C/man2/shmop.2:267
10372 msgid ""
10373 "On Linux, it is possible to attach a shared memory segment even if it is "
10374 "already marked to be deleted.  However, POSIX.1-2001 does not specify this "
10375 "behavior and many other implementations do not support it."
10376 msgstr ""
10377 "Linux では共有メモリセグメントに既に削除マークが付けられていても、 その共有メ"
10378 "モリセグメントを付加することができる。 しかし POSIX.1-2001 ではこのような動作"
10379 "を指定しておらず、 他の多くの実装もこれをサポートしていない。"
10380
10381 #. type: Plain text
10382 #: build/C/man2/shmop.2:270
10383 msgid "The following system parameter affects B<shmat>():"
10384 msgstr "以下のシステム・パラメーターは、 B<shmat>()  に影響する:"
10385
10386 #.  FIXME A good explanation of the rationale for the existence
10387 #.  of SHMLBA would be useful here
10388 #. type: TP
10389 #: build/C/man2/shmop.2:270
10390 #, no-wrap
10391 msgid "B<SHMLBA>"
10392 msgstr "B<SHMLBA>"
10393
10394 #.  FIXME That last sentence isn't true for all Linux
10395 #.  architectures (i.e., SHMLBA != PAGE_SIZE for some architectures)
10396 #.  -- MTK, Nov 04
10397 #. type: Plain text
10398 #: build/C/man2/shmop.2:283
10399 msgid ""
10400 "Segment low boundary address multiple.  Must be page aligned.  For the "
10401 "current implementation the B<SHMLBA> value is B<PAGE_SIZE>."
10402 msgstr ""
10403 "セグメントの境界アドレスの最小倍数。ページ境界に合ってなければならない。 現在"
10404 "の実装では B<SHMLBA> の値は B<PAGE_SIZE> である。"
10405
10406 #. type: Plain text
10407 #: build/C/man2/shmop.2:287
10408 msgid ""
10409 "The implementation places no intrinsic limit on the per-process maximum "
10410 "number of shared memory segments (B<SHMSEG>)."
10411 msgstr ""
10412 "現在の実装では、プロセスごとの 共有メモリ・セグメントの最大数 (B<SHMSEG>)  に"
10413 "関する実装依存の制限はない。"
10414
10415 #. type: Plain text
10416 #: build/C/man2/shmop.2:295
10417 msgid ""
10418 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
10419 "B<shm_overview>(7), B<svipc>(7)"
10420 msgstr ""
10421 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
10422 "B<shm_overview>(7), B<svipc>(7)"
10423
10424 #. type: TH
10425 #: build/C/man2/subpage_prot.2:30
10426 #, no-wrap
10427 msgid "SUBPAGE_PROT"
10428 msgstr "SUBPAGE_PROT"
10429
10430 #. type: TH
10431 #: build/C/man2/subpage_prot.2:30
10432 #, no-wrap
10433 msgid "2012-07-13"
10434 msgstr "2012-07-13"
10435
10436 #. type: Plain text
10437 #: build/C/man2/subpage_prot.2:33
10438 msgid "subpage_prot - define a subpage protection for an address range"
10439 msgstr ""
10440
10441 #. type: Plain text
10442 #: build/C/man2/subpage_prot.2:37
10443 #, no-wrap
10444 msgid ""
10445 "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
10446 "B<                  uint32_t *>I<map>B<);>\n"
10447 msgstr ""
10448 "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
10449 "B<                  uint32_t *>I<map>B<);>\n"
10450
10451 #. type: Plain text
10452 #: build/C/man2/subpage_prot.2:41
10453 msgid "I<Note>: There is no glibc wrapper for this system call; see NOTES."
10454 msgstr ""
10455 "I<注>: このシステムコールには glibc のラッパー関数は存在しない。「注意」の節"
10456 "を参照。"
10457
10458 #. type: Plain text
10459 #: build/C/man2/subpage_prot.2:47
10460 msgid ""
10461 "The PowerPC-specific B<subpage_prot>()  system call provides the facility to "
10462 "control the access permissions on individual 4kB subpages on systems "
10463 "configured with a page size of 64kB."
10464 msgstr ""
10465
10466 #. type: Plain text
10467 #: build/C/man2/subpage_prot.2:54
10468 msgid ""
10469 "The protection map is applied to the memory pages in the region starting at "
10470 "I<addr> and continuing for I<len> bytes.  Both of these arguments must be "
10471 "aligned to a 64-kB boundary."
10472 msgstr ""
10473
10474 #. type: Plain text
10475 #: build/C/man2/subpage_prot.2:66
10476 msgid ""
10477 "The protection map is specified in the buffer pointed to by I<map>.  The map "
10478 "has 2 bits per 4kB subpage; thus each 32-bit word specifies the protections "
10479 "of 16 4kB subpages inside a 64kB page (so, the number of 32-bit words "
10480 "pointed to by I<map> should equate to the number of 64-kB pages specified by "
10481 "I<len>).  Each 2-bit field in the protection map is either 0 to allow any "
10482 "access, 1 to prevent writes, or 2 or 3 to prevent all accesses."
10483 msgstr ""
10484
10485 #. type: Plain text
10486 #: build/C/man2/subpage_prot.2:71
10487 msgid ""
10488 "On success, B<subpage_prot>()  returns 0.  Otherwise, one of the error codes "
10489 "specified below is returned."
10490 msgstr ""
10491
10492 #. type: Plain text
10493 #: build/C/man2/subpage_prot.2:77
10494 msgid "The buffer referred to by I<map> is not accessible."
10495 msgstr ""
10496
10497 #. type: Plain text
10498 #: build/C/man2/subpage_prot.2:87
10499 msgid ""
10500 "The I<addr> or I<len> arguments are incorrect.  Both of these arguments must "
10501 "be aligned to a multiple of the system page size, and they must not refer to "
10502 "a region outside of the address space of the process or to a region that "
10503 "consists of huge pages."
10504 msgstr ""
10505
10506 #. type: Plain text
10507 #: build/C/man2/subpage_prot.2:90 build/C/man2/sync_file_range.2:166
10508 msgid "Out of memory."
10509 msgstr "メモリ不足である。"
10510
10511 #. type: Plain text
10512 #: build/C/man2/subpage_prot.2:96
10513 msgid ""
10514 "This system call is provided on the PowerPC architecture since Linux "
10515 "2.6.25.  The system call is provided only if the kernel is configured with "
10516 "B<CONFIG_PPC_64K_PAGES>.  No library support is provided."
10517 msgstr ""
10518
10519 #. type: Plain text
10520 #: build/C/man2/subpage_prot.2:101
10521 msgid ""
10522 "Glibc does not provide a wrapper for this system call; call it using "
10523 "B<syscall>(2)."
10524 msgstr ""
10525
10526 #. type: Plain text
10527 #: build/C/man2/subpage_prot.2:106
10528 msgid ""
10529 "Normal page protections (at the 64-kB page level) also apply; the subpage "
10530 "protection mechanism is an additional constraint, so putting 0 in a 2-bit "
10531 "field won't allow writes to a page that is otherwise write-protected."
10532 msgstr ""
10533
10534 #. type: SS
10535 #: build/C/man2/subpage_prot.2:106
10536 #, no-wrap
10537 msgid "Rationale"
10538 msgstr ""
10539
10540 #.  In the initial implementation, it was the case that:
10541 #.      In fact the whole process is switched to use 4k hardware pages when the
10542 #.      subpage_prot system call is used, but this could be improved in future
10543 #.      to switch only the affected segments.
10544 #.  But Paul Mackerass says (Oct 2010): I'm pretty sure we now only switch
10545 #.  the affected segment, not the whole process.
10546 #. type: Plain text
10547 #: build/C/man2/subpage_prot.2:128
10548 msgid ""
10549 "This system call is provided to assist writing emulators that operate using "
10550 "64-kB pages on PowerPC systems.  When emulating systems such as x86, which "
10551 "uses a smaller page size, the emulator can no longer use the memory-"
10552 "management unit (MMU)  and normal system calls for controlling page "
10553 "protections.  (The emulator could emulate the MMU by checking and possibly "
10554 "remapping the address for each memory access in software, but that is "
10555 "slow.)  The idea is that the emulator supplies an array of protection masks "
10556 "to apply to a specified range of virtual addresses.  These masks are applied "
10557 "at the level where hardware page-table entries (PTEs)  are inserted into the "
10558 "hardware page table based on the Linux PTEs, so the Linux PTEs are not "
10559 "affected.  Implicit in this is that the regions of the address space that "
10560 "are protected are switched to use 4-kB hardware pages rather than 64-kB "
10561 "hardware pages (on machines with hardware 64-kB page support)."
10562 msgstr ""
10563
10564 #. type: Plain text
10565 #: build/C/man2/subpage_prot.2:131
10566 msgid "B<mprotect>(2), B<syscall>(2)"
10567 msgstr "B<mprotect>(2), B<syscall>(2)"
10568
10569 #. type: Plain text
10570 #: build/C/man2/subpage_prot.2:134
10571 msgid "I<Documentation/vm/hugetlbpage.txt> in the Linux kernel source tree"
10572 msgstr "Linux カーネルソースの I<Documentation/vm/hugetlbpage.txt>"
10573
10574 #. type: TH
10575 #: build/C/man2/sync_file_range.2:30
10576 #, no-wrap
10577 msgid "SYNC_FILE_RANGE"
10578 msgstr "SYNC_FILE_RANGE"
10579
10580 #. type: Plain text
10581 #: build/C/man2/sync_file_range.2:33
10582 msgid "sync_file_range - sync a file segment with disk"
10583 msgstr "sync_file_range - ファイルセグメントをディスクと同期する"
10584
10585 #. type: Plain text
10586 #: build/C/man2/sync_file_range.2:37
10587 #, no-wrap
10588 msgid ""
10589 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
10590 "B<#include E<lt>fcntl.hE<gt>>\n"
10591 msgstr ""
10592 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
10593 "B<#include E<lt>fcntl.hE<gt>>\n"
10594
10595 #. type: Plain text
10596 #: build/C/man2/sync_file_range.2:40
10597 #, no-wrap
10598 msgid ""
10599 "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
10600 "B<                    unsigned int >I<flags>B<);>\n"
10601 msgstr ""
10602 "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
10603 "B<                    unsigned int >I<flags>B<);>\n"
10604
10605 #. type: Plain text
10606 #: build/C/man2/sync_file_range.2:47
10607 msgid ""
10608 "B<sync_file_range>()  permits fine control when synchronizing the open file "
10609 "referred to by the file descriptor I<fd> with disk."
10610 msgstr ""
10611 "B<sync_file_range>()  を使うと、ファイルディスクリプタ I<fd> で参照されるオー"
10612 "プンされたファイルのディスクとの同期に関して、 きめ細かな制御が可能となる。"
10613
10614 #. type: Plain text
10615 #: build/C/man2/sync_file_range.2:61
10616 msgid ""
10617 "I<offset> is the starting byte of the file range to be synchronized.  "
10618 "I<nbytes> specifies the length of the range to be synchronized, in bytes; if "
10619 "I<nbytes> is zero, then all bytes from I<offset> through to the end of file "
10620 "are synchronized.  Synchronization is in units of the system page size: "
10621 "I<offset> is rounded down to a page boundary; I<(offset+nbytes-1)> is "
10622 "rounded up to a page boundary."
10623 msgstr ""
10624 "I<offset> は、同期を行うファイルの領域の開始バイトである。 I<nbytes> には同期"
10625 "を行う領域の長さをバイト単位で指定する。 I<nbytes> が 0 の場合は、 I<offset> "
10626 "からファイル末尾までの全バイトを同期する。 同期はシステムのページサイズの単位"
10627 "で行われる。 I<offset> はページ境界にあわせて切り下げられ、 I<(offset"
10628 "+nbytes-1)> はページ境界にあわせて切り上げられる。"
10629
10630 #. type: Plain text
10631 #: build/C/man2/sync_file_range.2:65
10632 msgid "The I<flags> bit-mask argument can include any of the following values:"
10633 msgstr "ビットマスク引き数 I<flags> には以下の値を指定することができる:"
10634
10635 #. type: TP
10636 #: build/C/man2/sync_file_range.2:65
10637 #, no-wrap
10638 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE>"
10639 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE>"
10640
10641 #. type: Plain text
10642 #: build/C/man2/sync_file_range.2:70
10643 msgid ""
10644 "Wait upon write-out of all pages in the specified range that have already "
10645 "been submitted to the device driver for write-out before performing any "
10646 "write."
10647 msgstr ""
10648 "何らかの書き込みを行う前に、指定された領域のページで 書き出しを行うようにデバ"
10649 "イスドライバにすでに要求が発行されている ページの書き出しが全て完了するのを待"
10650 "つ。"
10651
10652 #. type: TP
10653 #: build/C/man2/sync_file_range.2:70 build/C/man2/sync_file_range.2:120
10654 #, no-wrap
10655 msgid "B<SYNC_FILE_RANGE_WRITE>"
10656 msgstr "B<SYNC_FILE_RANGE_WRITE>"
10657
10658 #. type: Plain text
10659 #: build/C/man2/sync_file_range.2:76
10660 msgid ""
10661 "Initiate write-out of all dirty pages in the specified range which are not "
10662 "presently submitted write-out.  Note that even this may block if you attempt "
10663 "to write more than request queue size."
10664 msgstr ""
10665 "指定された領域のページで、書き出し要求が発行されていない 全ての dirty (キャッ"
10666 "シュだけが変更されている) ページの 書き出しを開始する。 リクエストキューの大"
10667 "きさより多く書き込もうとした場合には、 この処理は停止 (block) する可能性があ"
10668 "る点に注意すること。"
10669
10670 #. type: TP
10671 #: build/C/man2/sync_file_range.2:76
10672 #, no-wrap
10673 msgid "B<SYNC_FILE_RANGE_WAIT_AFTER>"
10674 msgstr "B<SYNC_FILE_RANGE_WAIT_AFTER>"
10675
10676 #. type: Plain text
10677 #: build/C/man2/sync_file_range.2:80
10678 msgid ""
10679 "Wait upon write-out of all pages in the range after performing any write."
10680 msgstr ""
10681 "何らかの書き込み後に、指定された領域の全てのページの 書き出しが行われるのを待"
10682 "つ。"
10683
10684 #. type: Plain text
10685 #: build/C/man2/sync_file_range.2:84
10686 msgid "Specifying I<flags> as 0 is permitted, as a no-op."
10687 msgstr "I<flags> に 0 を指定した場合、何もしないことを表す。"
10688
10689 #. type: SS
10690 #: build/C/man2/sync_file_range.2:84
10691 #, no-wrap
10692 msgid "Warning"
10693 msgstr "警告"
10694
10695 #. type: Plain text
10696 #: build/C/man2/sync_file_range.2:100
10697 msgid ""
10698 "This system call is extremely dangerous and should not be used in portable "
10699 "programs.  None of these operations writes out the file's metadata.  "
10700 "Therefore, unless the application is strictly performing overwrites of "
10701 "already-instantiated disk blocks, there are no guarantees that the data will "
10702 "be available after a crash.  There is no user interface to know if a write "
10703 "is purely an overwrite.  On filesystems using copy-on-write semantics (e.g., "
10704 "I<btrfs>)  an overwrite of existing allocated blocks is impossible.  When "
10705 "writing into preallocated space, many filesystems also require calls into "
10706 "the block allocator, which this system call does not sync out to disk.  This "
10707 "system call does not flush disk write caches and thus does not provide any "
10708 "data integrity on systems with volatile disk write caches."
10709 msgstr ""
10710 "このシステムコールは非常に危険であり、 移植性が必要なプログラムで使用すべきで"
10711 "はない。 これらの操作ではどれもファイルのメタデータの書き出しを行わない。 し"
10712 "たがって、アプリケーションにより作成済みのディスクブロックの 上書きの実行が確"
10713 "実に行われない限り、クラッシュの後でもデータが 利用できる保証はない。 書き込"
10714 "みが上書きだけであるかを知るためのユーザインタフェースは存在しない。 "
10715 "(I<btrfs> などの) copy-on-write 動作を使ったファイルシステムでは、 既存の割り"
10716 "当て済みのブロックに対する上書き自体ができない。 前もって割り当てられた領域に"
10717 "書き込みを行う場合、 多くのファイルシステムでは block allocator への書き込み"
10718 "も必要となるが、 このシステムコールは block allocator のディスクへの同期を行"
10719 "わない。 このシステムコールはディスク書き込みキャッシュのフラッシュを 行わな"
10720 "いので、揮発性のディスク書き込みキャッシュを使ったシステムでは このシステム"
10721 "コールではデータの一貫性を確保できないことになる。"
10722
10723 #. type: SS
10724 #: build/C/man2/sync_file_range.2:100
10725 #, no-wrap
10726 msgid "Some details"
10727 msgstr "詳細"
10728
10729 #. type: Plain text
10730 #: build/C/man2/sync_file_range.2:108
10731 msgid ""
10732 "B<SYNC_FILE_RANGE_WAIT_BEFORE> and B<SYNC_FILE_RANGE_WAIT_AFTER> will detect "
10733 "any I/O errors or B<ENOSPC> conditions and will return these to the caller."
10734 msgstr ""
10735 "B<SYNC_FILE_RANGE_WAIT_BEFORE> と B<SYNC_FILE_RANGE_WAIT_AFTER> は I/O エラー"
10736 "や B<ENOSPC> 状態を検出し、呼び出し元にこれらの情報を返す。"
10737
10738 #. type: Plain text
10739 #: build/C/man2/sync_file_range.2:112
10740 msgid "Useful combinations of the I<flags> bits are:"
10741 msgstr "I<flags> の役に立つビットの組み合わせを以下に示す:"
10742
10743 #. type: TP
10744 #: build/C/man2/sync_file_range.2:112
10745 #, no-wrap
10746 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE>"
10747 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE>"
10748
10749 #. type: Plain text
10750 #: build/C/man2/sync_file_range.2:120
10751 msgid ""
10752 "Ensures that all pages in the specified range which were dirty when "
10753 "B<sync_file_range>()  was called are placed under write-out.  This is a "
10754 "start-write-for-data-integrity operation."
10755 msgstr ""
10756 "指定された範囲内のページで、 B<sync_file_range>()  が呼び出された際に dirty "
10757 "であった全てのページが、 確実に書き出し対象となるようにする。 これは、start-"
10758 "write-for-data-integrity 操作 (データ完全性確保のための書き込み開始の操作) で"
10759 "ある。"
10760
10761 #. type: Plain text
10762 #: build/C/man2/sync_file_range.2:127
10763 msgid ""
10764 "Start write-out of all dirty pages in the specified range which are not "
10765 "presently under write-out.  This is an asynchronous flush-to-disk "
10766 "operation.  This is not suitable for data integrity operations."
10767 msgstr ""
10768 "指定された範囲内のページで、現在書き出し中でない全ての dirty ページの 書き出"
10769 "しを開始する。これは非同期のディスクへのフラッシュ (flush-to-disk)  操作であ"
10770 "る。データ完全性確保が必要な操作としては適切ではない。"
10771
10772 #. type: TP
10773 #: build/C/man2/sync_file_range.2:127
10774 #, no-wrap
10775 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE> (or B<SYNC_FILE_RANGE_WAIT_AFTER>)"
10776 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE> (or B<SYNC_FILE_RANGE_WAIT_AFTER>)"
10777
10778 #. type: Plain text
10779 #: build/C/man2/sync_file_range.2:134
10780 msgid ""
10781 "Wait for completion of write-out of all pages in the specified range.  This "
10782 "can be used after an earlier B<SYNC_FILE_RANGE_WAIT_BEFORE | "
10783 "SYNC_FILE_RANGE_WRITE> operation to wait for completion of that operation, "
10784 "and obtain its result."
10785 msgstr ""
10786 "指定された範囲内の全てのページの書き出しの完了を待つ。 このフラグは、前に行わ"
10787 "れた操作 B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE> の後に使用で"
10788 "き、この操作の完了を待ち、結果を取得することができる。"
10789
10790 #. type: TP
10791 #: build/C/man2/sync_file_range.2:134
10792 #, no-wrap
10793 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE | SYNC_FILE_RANGE_WAIT_AFTER>"
10794 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE | SYNC_FILE_RANGE_WAIT_AFTER>"
10795
10796 #. type: Plain text
10797 #: build/C/man2/sync_file_range.2:141
10798 msgid ""
10799 "This is a write-for-data-integrity operation that will ensure that all pages "
10800 "in the specified range which were dirty when B<sync_file_range>()  was "
10801 "called are committed to disk."
10802 msgstr ""
10803 "これは write-for-data-integrity 操作 (データ完全性確保のための書き込み) であ"
10804 "り、指定された範囲内の、 B<sync_file_range>()  が呼ばれた時点で dirty な全て"
10805 "のページが ディスクに格納されることが保証される。"
10806
10807 #. type: Plain text
10808 #: build/C/man2/sync_file_range.2:147
10809 msgid ""
10810 "On success, B<sync_file_range>()  returns 0; on failure -1 is returned and "
10811 "I<errno> is set to indicate the error."
10812 msgstr ""
10813 "成功の場合、 B<sync_file_range>()  は 0 を返す。失敗の場合、-1 を返し、 "
10814 "I<error> にエラーを示す値を設定する。"
10815
10816 #. type: Plain text
10817 #: build/C/man2/sync_file_range.2:152
10818 msgid "I<fd> is not a valid file descriptor."
10819 msgstr "I<fd> が有効なファイルディスクリプタではない。"
10820
10821 #. type: Plain text
10822 #: build/C/man2/sync_file_range.2:160
10823 msgid ""
10824 "I<flags> specifies an invalid bit; or I<offset> or I<nbytes> is invalid."
10825 msgstr ""
10826 "I<flags> に不正なビットが指定されている。または I<offset> か I<nbytes> が不正"
10827 "である。"
10828
10829 #. type: Plain text
10830 #: build/C/man2/sync_file_range.2:163
10831 msgid "I/O error."
10832 msgstr "I/O エラー。"
10833
10834 #. type: Plain text
10835 #: build/C/man2/sync_file_range.2:169
10836 msgid "Out of disk space."
10837 msgstr "ディスク領域不足である。"
10838
10839 #.  FIXME . (bug?) Actually, how can 'fd' refer to a symbolic link (S_ISLNK)?
10840 #.  (In user space at least) it isn't possible to obtain a file descriptor
10841 #.  for a symbolic link.
10842 #. type: Plain text
10843 #: build/C/man2/sync_file_range.2:177
10844 msgid ""
10845 "I<fd> refers to something other than a regular file, a block device, a "
10846 "directory, or a symbolic link."
10847 msgstr ""
10848 "I<fd> が、通常のファイル、ブロックデバイス、ディレクトリ、シンボリックリンク "
10849 "以外のものを指している。"
10850
10851 #. type: Plain text
10852 #: build/C/man2/sync_file_range.2:180
10853 msgid "B<sync_file_range>()  appeared on Linux in kernel 2.6.17."
10854 msgstr "B<sync_file_range>()  はカーネル 2.6.17 で Linux に登場した。"
10855
10856 #. type: Plain text
10857 #: build/C/man2/sync_file_range.2:183
10858 msgid ""
10859 "This system call is Linux-specific, and should be avoided in portable "
10860 "programs."
10861 msgstr ""
10862 "このシステムコールは Linux 独自であり、 移植性が必要なプログラムでは使用を避"
10863 "けるべきである。"
10864
10865 #.  See kernel commit edd5cd4a9424f22b0fa08bef5e299d41befd5622
10866 #. type: Plain text
10867 #: build/C/man2/sync_file_range.2:200
10868 msgid ""
10869 "Some architectures (e.g., PowerPC, ARM)  need 64-bit arguments to be aligned "
10870 "in a suitable pair of registers.  On such architectures, the call signature "
10871 "of B<sync_file_range>()  shown in the SYNOPSIS would force a register to be "
10872 "wasted as padding between the I<fd> and I<offset> arguments.  (See B<syscall>"
10873 "(2)  for details.)  Therefore, these architectures define a different system "
10874 "call that orders the arguments suitably:"
10875 msgstr ""
10876 "いくつかのアーキテクチャ (例えば、 PowerPC や ARM) では、 64 ビットの引き数は"
10877 "適切なレジスタの組に割り当てる必要がある。 このようなアーキテクチャでは、 "
10878 "「書式」に書かれている B<sync_file_range>() の呼び出しシグネチャーで、 引き"
10879 "数 I<fd> と I<offset> の間のパディング (詰めもの) でレジスタが一つ消費されて"
10880 "しまう (詳細は B<syscall>(2) 参照)。 そのため、 これらのアーキテクチャでは引"
10881 "き数が適切な順序になった別のシステムコールが定義されている。"
10882
10883 #. type: Plain text
10884 #: build/C/man2/sync_file_range.2:205
10885 #, no-wrap
10886 msgid ""
10887 "B<int sync_file_range2(int >I<fd>B<, unsigned int >I<flags>B<,>\n"
10888 "B<                     off64_t >I<offset>B<, off64_t >I<nbytes>B<);>\n"
10889 msgstr ""
10890 "B<int sync_file_range2(int >I<fd>B<, unsigned int >I<flags>B<,>\n"
10891 "B<                     off64_t >I<offset>B<, off64_t >I<nbytes>B<);>\n"
10892
10893 #. type: Plain text
10894 #: build/C/man2/sync_file_range.2:210
10895 msgid ""
10896 "The behavior of this system call is otherwise exactly the same as "
10897 "B<sync_file_range>()."
10898 msgstr ""
10899 "上記の点以外は、このシステムコールの動作は B<sync_file_range>() と\n"
10900 "全く同じである。このシステムコールに対するライブラリによるサポートは\n"
10901 "glibc では提供されていない。"
10902
10903 #. type: Plain text
10904 #: build/C/man2/sync_file_range.2:221
10905 msgid ""
10906 "A system call with this signature first appeared on the ARM architecture in "
10907 "Linux 2.6.20, with the name B<arm_sync_file_range>().  It was renamed in "
10908 "Linux 2.6.22, when the analogous system call was added for PowerPC.  On "
10909 "architectures where glibc support is provided, glibc transparently wraps "
10910 "B<sync_file_range2>()  under the name B<sync_file_range>()."
10911 msgstr ""
10912 "このバージョンのシステムコールは、Linux 2.6.20 で ARM アーキテクチャで\n"
10913 "初めて登場し、 B<arm_sync_file_range>() という名前であった。\n"
10914 "Linux 2.6.22 で、同様のシステムコールが PowerPC 用に追加された際に、\n"
10915 "システムコールの名前が変更された。\n"
10916 "glibc によるサポートが提供されているアーキテクチャでは、\n"
10917 "glibc のラッパー関数は B<sync_file_range>() という名前で\n"
10918 "B<sync_file_range2>() を適切に使用するようになっている。"
10919
10920 #. type: Plain text
10921 #: build/C/man2/sync_file_range.2:226
10922 msgid "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2)"
10923 msgstr "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2)"
10924
10925 #~ msgid "2014-01-24"
10926 #~ msgstr "2014-01-24"
10927
10928 #~ msgid "2012-04-28"
10929 #~ msgstr "2012-04-28"
10930
10931 #~ msgid "2011-09-14"
10932 #~ msgstr "2011-09-14"
10933
10934 #~ msgid ""
10935 #~ "Maximum size in bytes for a shared memory segment: policy dependent (on "
10936 #~ "Linux, this limit can be read and modified via I</proc/sys/kernel/"
10937 #~ "shmmax>)."
10938 #~ msgstr ""
10939 #~ "共有メモリ・セグメントのバイト単位の大きさの上限: 方針依存 (Linux では、こ"
10940 #~ "の上限値は I</proc/sys/kernel/shmmax> 経由で参照したり、変更したりでき"
10941 #~ "る)。"
10942
10943 #~ msgid ""
10944 #~ "System wide maximum number of shared memory segments: implementation "
10945 #~ "dependent (currently 4096, was 128 before Linux 2.3.99; on Linux, this "
10946 #~ "limit can be read and modified via I</proc/sys/kernel/shmmni>)."
10947 #~ msgstr ""
10948 #~ "システム全体の共有メモリーの数の上限: 実装依存 (現在は 4096。Linux 2.3.99 "
10949 #~ "より前では 128。 Linux では、この上限値は I</proc/sys/kernel/shmmni> 経由"
10950 #~ "で参照したり、変更したりできる)。"
10951
10952 #~ msgid "2013-05-12"
10953 #~ msgstr "2013-05-12"
10954
10955 #~ msgid "2012-04-16"
10956 #~ msgstr "2012-04-16"
10957
10958 #~ msgid "2012-08-14"
10959 #~ msgstr "2012-08-14"
10960
10961 #~ msgid "2012-03-23"
10962 #~ msgstr "2012-03-23"
10963
10964 #~ msgid "B<fallocate>()  returns zero on success, and -1 on failure."
10965 #~ msgstr "B<fallocate>()  は成功すると 0 を返し、エラーの場合は -1 を返す。"
10966
10967 #~ msgid "On success, B<malloc_info>()  returns 0; on error, it returns -1."
10968 #~ msgstr "B<malloc_info>() は成功すると 0 を返す。エラーの場合は -1 を返す。"
10969
10970 #~ msgid "2012-05-31"
10971 #~ msgstr "2012-05-31"
10972
10973 #~ msgid ""
10974 #~ "A valid segment identifier, I<shmid>, is returned on success, -1 on error."
10975 #~ msgstr ""
10976 #~ "成功した場合、有効なセグメント識別子 I<shmid> が返される。エラーの場合、 "
10977 #~ "-1 が返される。"
10978
10979 #~ msgid ""
10980 #~ "The ARM architecture needs 64-bit arguments to be aligned in a suitable "
10981 #~ "pair of registers.  On this architecture, the call signature of "
10982 #~ "B<posix_fadvise>()  is flawed, since it forces a register to be wasted as "
10983 #~ "padding between the I<fd> and I<len> arguments.  Therefore, since Linux "
10984 #~ "2.6.14, ARM defines a different system call that orders the arguments "
10985 #~ "suitably:"
10986 #~ msgstr ""
10987 #~ "ARM アーキテクチャでは、64 ビットの引き数は適切なレジスタの組に割り当て\n"
10988 #~ "る必要がある。このアーキテクチャでは、B<posix_fadvise>() の呼び出し方に\n"
10989 #~ "は欠陥があり、それはこのシステムコールでは引き数 I<fd> と I<len> の間の\n"
10990 #~ "パディング (詰めもの) でレジスタが一つ消費されてしまうというものである。\n"
10991 #~ "そのため、Linux 2.6.14 以降では、ARM では引き数が適切な順序になった別の\n"
10992 #~ "システムコールが定義されている。"
10993
10994 #~ msgid ""
10995 #~ "The behavior of this system call is otherwise exactly the same as "
10996 #~ "B<posix_fadvise>().  No library support is provided for this system call "
10997 #~ "in glibc."
10998 #~ msgstr ""
10999 #~ "上記の点以外は、このシステムコールの動作は B<posix_fadvise>() と全く\n"
11000 #~ "同じである。このシステムコールに対するライブラリによるサポートは glibc\n"
11001 #~ "では提供されていない。"
11002
11003 #~ msgid ""
11004 #~ "The I<mode> is not supported by the file system containing the file "
11005 #~ "referred to by I<fd>."
11006 #~ msgstr ""
11007 #~ "I<fd> が参照するファイルを含むファイルシステムが I<mode> をサポートしてい"
11008 #~ "ない。"
11009
11010 #~ msgid ""
11011 #~ "The function B<mtrace>()  installs handlers for B<malloc>(3), B<realloc>"
11012 #~ "(3)  and B<free>(3).  The function B<muntrace>()  disables these handlers."
11013 #~ msgstr ""
11014 #~ "関数 B<mtrace>()  は、 B<malloc>(3), B<realloc>(3), B<free>(3)  のハンドラ"
11015 #~ "を組み込む。 関数 B<muntrace>()  はこれらのハンドラを解除する。"
11016
11017 #~ msgid ""
11018 #~ "The environment variable B<MALLOC_TRACE> defines a file where B<mtrace>"
11019 #~ "()  writes its output.  This file must be writable to the user or "
11020 #~ "B<mtrace>()  will do nothing.  If the file is not empty it will be "
11021 #~ "truncated."
11022 #~ msgstr ""
11023 #~ "環境変数 B<MALLOC_TRACE> は B<mtrace>()  が出力を書き出すファイルを指定す"
11024 #~ "る。 ユーザが書き込み権限を持つファイルを指定しなければならない。 書き込み"
11025 #~ "権限がない場合、 B<mtrace>()  は何もしない。 ファイルが空でない場合、ファ"
11026 #~ "イルの元の内容を上書きする。"
11027
11028 #~ msgid ""
11029 #~ "The output of B<mtrace>()  will be ASCII but not in a friendly format.  "
11030 #~ "So glibc comes with a perl-script called mtrace to make sense of it."
11031 #~ msgstr ""
11032 #~ "B<mtrace>()  の出力は ASCII 形式だが、人が読みやすいフォーマットではな"
11033 #~ "い。 そこで、glibc には mtrace 出力を分かりやすい形式に変換する perl スク"
11034 #~ "リプトが付属している。"
11035
11036 #~ msgid ""
11037 #~ "This flag allocates and initializes to zero the disk space within the "
11038 #~ "range specified by I<offset> and I<len>.  After a successful call, "
11039 #~ "subsequent writes into this range are guaranteed not to fail because of "
11040 #~ "lack of disk space.  Preallocating zeroed blocks beyond the end of the "
11041 #~ "file is useful for optimizing append workloads.  Preallocating blocks "
11042 #~ "does not change the file size (as reported by B<stat>(2))  even if it is "
11043 #~ "less than I<offset>+I<len>."
11044 #~ msgstr ""
11045 #~ "このフラグは、 I<offset> と I<len> で指定された領域のディスク空間を割り当"
11046 #~ "て、その空間を 0 で初期化する。 呼び出しが成功すると、それに続いてこの領域"
11047 #~ "への書き込みが行われるが、 ディスク空間の不足による書き込み失敗が発生しな"
11048 #~ "いことが保証される。 ファイル末尾より後ろの領域について 0 で埋めたブロック"
11049 #~ "を前もって 割り当てておくことは、追記 (append) の作業負荷を最適化するのに "
11050 #~ "有用である。 ファイルサイズが I<offset>+I<len> よりも小さい場合であって"
11051 #~ "も、ブロックの前もっての割り当てにより (B<stat>(2)  が返す) ファイルサイズ"
11052 #~ "は変更されることはない。"
11053
11054 #~ msgid ""
11055 #~ "(Linux 2.6.9 and later) the caller was not privileged (B<CAP_IPC_LOCK>)  "
11056 #~ "and its B<RLIMIT_MEMLOCK> soft resource limit was 0."
11057 #~ msgstr ""
11058 #~ "(Linux 2.6.9 以降) 呼び出し元は特権 (B<CAP_IPC_LOCK>)  を持たず、ソフト資"
11059 #~ "源制限 B<RLIMIT_MEMLOCK> が 0 である。"
11060
11061 #~ msgid ""
11062 #~ "(Linux 2.6.8 and earlier)  The calling process has insufficient privilege "
11063 #~ "to call B<munlockall>().  Under Linux the B<CAP_IPC_LOCK> capability is "
11064 #~ "required."
11065 #~ msgstr ""
11066 #~ "(Linux 2.6.8 以前)  呼び出し元プロセスが B<munlockall>()  を呼び出すのに必"
11067 #~ "要な特権を所有していなかった。 Linux では、 B<CAP_IPC_LOCK> ケーパビリティ"
11068 #~ "が必要である。"
11069
11070 #~ msgid ""
11071 #~ "B<posix_fadvise>()  appeared in kernel 2.5.60.  Glibc support has been "
11072 #~ "provided since version 2.2."
11073 #~ msgstr ""
11074 #~ "B<posix_fadvise>()  はカーネル 2.5.60 で登場した。 glibc でのサポートは "
11075 #~ "glibc バージョン 2.2 以降で行われている。"