OSDN Git Service

(split) LDP: Translation snapshots of memory/ja.po.
[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: 2012-04-25 05:59+0900\n"
10 "PO-Revision-Date: 2012-05-01 00:10+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:24
32 #: build/C/man2/fallocate.2:8 build/C/man2/madvise.2:35
33 #: build/C/man3/mallopt.3:24 build/C/man2/mlock.2:27 build/C/man2/mmap.2:40
34 #: build/C/man2/mmap2.2:29 build/C/man2/mprotect.2:32 build/C/man2/mremap.2:31
35 #: build/C/man2/msync.2:25 build/C/man2/posix_fadvise.2:27
36 #: build/C/man2/readahead.2:28 build/C/man2/remap_file_pages.2:26
37 #: build/C/man3/shm_open.3:26 build/C/man7/shm_overview.7:27
38 #: build/C/man2/shmctl.2:43 build/C/man2/shmget.2:36 build/C/man2/shmop.2:39
39 #: build/C/man2/subpage_prot.2:28 build/C/man2/sync_file_range.2:30
40 #: build/C/man3/malloc_trim.3:24
41 #, no-wrap
42 msgid "Linux"
43 msgstr "Linux"
44
45 #. type: TH
46 #: build/C/man2/alloc_hugepages.2:25 build/C/man3/alloca.3:41
47 #: build/C/man2/cacheflush.2:24 build/C/man2/fallocate.2:8
48 #: build/C/man2/madvise.2:35 build/C/man3/malloc_hook.3:6
49 #: build/C/man3/mallopt.3:24 build/C/man2/mlock.2:27 build/C/man2/mmap.2:40
50 #: build/C/man2/mmap2.2:29 build/C/man2/mprotect.2:32 build/C/man2/mremap.2:31
51 #: build/C/man2/msync.2:25 build/C/man3/mtrace.3:23
52 #: build/C/man2/posix_fadvise.2:27 build/C/man3/posix_fallocate.3:23
53 #: build/C/man3/posix_memalign.3:28 build/C/man2/readahead.2:28
54 #: build/C/man2/remap_file_pages.2:26 build/C/man3/shm_open.3:26
55 #: build/C/man7/shm_overview.7:27 build/C/man2/shmctl.2:43
56 #: build/C/man2/shmget.2:36 build/C/man2/shmop.2:39
57 #: build/C/man2/subpage_prot.2:28 build/C/man2/sync_file_range.2:30
58 #: build/C/man3/malloc_get_state.3:23 build/C/man3/malloc_trim.3:24
59 #: build/C/man3/malloc_usable_size.3:23
60 #, no-wrap
61 msgid "Linux Programmer's Manual"
62 msgstr "Linux Programmer's Manual"
63
64 #. type: SH
65 #: build/C/man2/alloc_hugepages.2:26 build/C/man3/alloca.3:42
66 #: build/C/man2/cacheflush.2:25 build/C/man2/fallocate.2:9
67 #: build/C/man2/madvise.2:36 build/C/man3/malloc_hook.3:7
68 #: build/C/man3/mallopt.3:25 build/C/man2/mlock.2:28 build/C/man2/mmap.2:41
69 #: build/C/man2/mmap2.2:30 build/C/man2/mprotect.2:33 build/C/man2/mremap.2:32
70 #: build/C/man2/msync.2:26 build/C/man3/mtrace.3:24
71 #: build/C/man2/posix_fadvise.2:28 build/C/man3/posix_fallocate.3:24
72 #: build/C/man3/posix_memalign.3:29 build/C/man2/readahead.2:29
73 #: build/C/man2/remap_file_pages.2:27 build/C/man3/shm_open.3:27
74 #: build/C/man7/shm_overview.7:28 build/C/man2/shmctl.2:44
75 #: build/C/man2/shmget.2:37 build/C/man2/shmop.2:40
76 #: build/C/man2/subpage_prot.2:29 build/C/man2/sync_file_range.2:31
77 #: build/C/man3/malloc_get_state.3:24 build/C/man3/malloc_trim.3:25
78 #: build/C/man3/malloc_usable_size.3:24
79 #, no-wrap
80 msgid "NAME"
81 msgstr "名前"
82
83 #. type: Plain text
84 #: build/C/man2/alloc_hugepages.2:28
85 msgid "alloc_hugepages, free_hugepages - allocate or free huge pages"
86 msgstr ""
87 "alloc_hugepages, free_hugepages - 大きなサイズのページの割り当てと解放を行う"
88
89 #. type: SH
90 #: build/C/man2/alloc_hugepages.2:28 build/C/man3/alloca.3:44
91 #: build/C/man2/cacheflush.2:27 build/C/man2/fallocate.2:11
92 #: build/C/man2/madvise.2:38 build/C/man3/malloc_hook.3:11
93 #: build/C/man3/mallopt.3:27 build/C/man2/mlock.2:30 build/C/man2/mmap.2:43
94 #: build/C/man2/mmap2.2:32 build/C/man2/mprotect.2:35 build/C/man2/mremap.2:34
95 #: build/C/man2/msync.2:28 build/C/man3/mtrace.3:26
96 #: build/C/man2/posix_fadvise.2:30 build/C/man3/posix_fallocate.3:26
97 #: build/C/man3/posix_memalign.3:31 build/C/man2/readahead.2:31
98 #: build/C/man2/remap_file_pages.2:29 build/C/man3/shm_open.3:29
99 #: build/C/man2/shmctl.2:46 build/C/man2/shmget.2:39 build/C/man2/shmop.2:42
100 #: build/C/man2/subpage_prot.2:31 build/C/man2/sync_file_range.2:33
101 #: build/C/man3/malloc_get_state.3:26 build/C/man3/malloc_trim.3:27
102 #: build/C/man3/malloc_usable_size.3:26
103 #, no-wrap
104 msgid "SYNOPSIS"
105 msgstr "書式"
106
107 #.  asmlinkage unsigned long sys_alloc_hugepages(int key, unsigned long addr,
108 #.  unsigned long len, int prot, int flag);
109 #. type: Plain text
110 #: build/C/man2/alloc_hugepages.2:34
111 #, no-wrap
112 msgid ""
113 "B<void *alloc_hugepages(int >I<key>B<, void *>I<addr>B<, size_t >I<len>B<,>\n"
114 "B<                      int >I<prot>B<, int >I<flag>B<);>\n"
115 msgstr ""
116 "B<void *alloc_hugepages(int >I<key>B<, void *>I<addr>B<, size_t >I<len>B<,>\n"
117 "B<                      int >I<prot>B<, int >I<flag>B<);>\n"
118
119 #.  asmlinkage int sys_free_hugepages(unsigned long addr);
120 #. type: Plain text
121 #: build/C/man2/alloc_hugepages.2:37
122 #, no-wrap
123 msgid "B<int free_hugepages(void *>I<addr>B<);>\n"
124 msgstr "B<int free_hugepages(void *>I<addr>B<);>\n"
125
126 #. type: SH
127 #: build/C/man2/alloc_hugepages.2:38 build/C/man3/alloca.3:48
128 #: build/C/man2/cacheflush.2:33 build/C/man2/fallocate.2:19
129 #: build/C/man2/madvise.2:50 build/C/man3/malloc_hook.3:29
130 #: build/C/man3/mallopt.3:31 build/C/man2/mlock.2:40 build/C/man2/mmap.2:52
131 #: build/C/man2/mmap2.2:39 build/C/man2/mprotect.2:41 build/C/man2/mremap.2:43
132 #: build/C/man2/msync.2:32 build/C/man3/mtrace.3:32
133 #: build/C/man2/posix_fadvise.2:49 build/C/man3/posix_fallocate.3:44
134 #: build/C/man3/posix_memalign.3:83 build/C/man2/readahead.2:38
135 #: build/C/man2/remap_file_pages.2:37 build/C/man3/shm_open.3:41
136 #: build/C/man7/shm_overview.7:30 build/C/man2/shmctl.2:54
137 #: build/C/man2/shmget.2:47 build/C/man2/shmop.2:51
138 #: build/C/man2/subpage_prot.2:36 build/C/man2/sync_file_range.2:41
139 #: build/C/man3/malloc_get_state.3:34 build/C/man3/malloc_trim.3:31
140 #: build/C/man3/malloc_usable_size.3:30
141 #, no-wrap
142 msgid "DESCRIPTION"
143 msgstr "説明"
144
145 #. type: Plain text
146 #: build/C/man2/alloc_hugepages.2:49
147 msgid ""
148 "The system calls B<alloc_hugepages>()  and B<free_hugepages>()  were "
149 "introduced in Linux 2.5.36 and removed again in 2.5.54.  They existed only "
150 "on i386 and ia64 (when built with B<CONFIG_HUGETLB_PAGE>).  In Linux 2.4.20 "
151 "the syscall numbers exist, but the calls fail with the error B<ENOSYS>."
152 msgstr ""
153 "システムコール B<alloc_hugepages>()  と B<free_hugepages>()  は Linux 2.5.36 "
154 "で導入され、2.5.54 で再び削除された。 これらのシステムコールは i386 と ia64 "
155 "のみで (かつ B<CONFIG_HUGETLB_PAGE> を指定してビルドされた場合に) 存在する。 "
156 "Linux 2.4.20 では syscall 番号が存在するが、 呼び出すとエラー B<ENOSYS> で失"
157 "敗する。"
158
159 #. type: Plain text
160 #: build/C/man2/alloc_hugepages.2:57
161 msgid ""
162 "On i386 the memory management hardware knows about ordinary pages (4 KiB)  "
163 "and huge pages (2 or 4 MiB).  Similarly ia64 knows about huge pages of "
164 "several sizes.  These system calls serve to map huge pages into the "
165 "process's memory or to free them again.  Huge pages are locked into memory, "
166 "and are not swapped."
167 msgstr ""
168 "i386 では、メモリ管理ハードウェアは通常のページ (4 KiB) と 大きなサイズのペー"
169 "ジ (以下、ヒュージページ; 2MiB または 4 MiB) を 扱うことができる。 同様に、"
170 "ia64 もいくつかのサイズのヒュージページを扱うことができる。 これらのシステム"
171 "コールは、ヒュージページをプロセスのメモリにマップしたり、 再び解放したりす"
172 "る。 ヒュージページはメモリ内にロックされ、スワップされない。"
173
174 #. type: Plain text
175 #: build/C/man2/alloc_hugepages.2:66
176 msgid ""
177 "The I<key> argument is an identifier.  When zero the pages are private, and "
178 "not inherited by children.  When positive the pages are shared with other "
179 "applications using the same I<key>, and inherited by child processes."
180 msgstr ""
181 "I<key> 引き数は識別子である。 0 の場合、ページは非公開になり、子プロセスに継"
182 "承されない。 正の場合、ページは同じ I<key> を使う他のアプリケーションと共有さ"
183 "れ、子プロセスに継承される。"
184
185 #. type: Plain text
186 #: build/C/man2/alloc_hugepages.2:81
187 msgid ""
188 "The I<addr> argument of B<free_hugepages>()  tells which page is being "
189 "freed: it was the return value of a call to B<alloc_hugepages>().  (The "
190 "memory is first actually freed when all users have released it.)  The "
191 "I<addr> argument of B<alloc_hugepages>()  is a hint, that the kernel may or "
192 "may not follow.  Addresses must be properly aligned."
193 msgstr ""
194 "B<free_hugepages>()  の I<addr> 引き数は、どのページを解放するかを指定する: "
195 "I<addr> は B<alloc_hugepages>()  の呼び出しの返り値である (全てのユーザがメモ"
196 "リを解放したときに、 そのメモリは初めて実際に解放される)。 B<alloc_hugepages>"
197 "()  の I<addr> 引き数はヒントであり、カーネルはそれに従うかもしれないし、 従"
198 "わないかもしれない。 アドレスは正しく配置されなければならない。"
199
200 #. type: Plain text
201 #: build/C/man2/alloc_hugepages.2:86
202 msgid ""
203 "The I<len> argument is the length of the required segment.  It must be a "
204 "multiple of the huge page size."
205 msgstr ""
206 "I<len> 引き数は要求されたセグメントの長さである。 これはヒュージページのサイ"
207 "ズの倍数にしなければならない。"
208
209 #. type: Plain text
210 #: build/C/man2/alloc_hugepages.2:94
211 msgid ""
212 "The I<prot> argument specifies the memory protection of the segment.  It is "
213 "one of B<PROT_READ>, B<PROT_WRITE>, B<PROT_EXEC>."
214 msgstr ""
215 "I<prot> 引き数はセグメントのメモリ保護を指定する。 これは B<PROT_READ>, "
216 "B<PROT_WRITE>, B<PROT_EXEC> のいずれかである。"
217
218 #. type: Plain text
219 #: build/C/man2/alloc_hugepages.2:109
220 msgid ""
221 "The I<flag> argument is ignored, unless I<key> is positive.  In that case, "
222 "if I<flag> is B<IPC_CREAT>, then a new huge page segment is created when "
223 "none with the given key existed.  If this flag is not set, then B<ENOENT> is "
224 "returned when no segment with the given key exists."
225 msgstr ""
226 "I<key> が正でない限り、 I<flag> 引き数は無視される。 I<key> が正で、かつ "
227 "I<flag> が B<IPC_CREAT> であり、かつ指定された I<key> で (セグメントが) 何も"
228 "存在しない場合、 新しいヒュージページセグメントが作成される。 I<flag> が設定"
229 "されておらず、かつ指定された I<key> のセグメントが存在しない場合、 B<ENOENT> "
230 "が返される。"
231
232 #. type: SH
233 #: build/C/man2/alloc_hugepages.2:109 build/C/man3/alloca.3:58
234 #: build/C/man2/cacheflush.2:52 build/C/man2/fallocate.2:109
235 #: build/C/man2/madvise.2:250 build/C/man3/mallopt.3:377
236 #: build/C/man2/mlock.2:117 build/C/man2/mmap.2:373 build/C/man2/mmap2.2:54
237 #: build/C/man2/mprotect.2:72 build/C/man2/mremap.2:128
238 #: build/C/man2/msync.2:68 build/C/man2/posix_fadvise.2:86
239 #: build/C/man3/posix_fallocate.3:64 build/C/man3/posix_memalign.3:141
240 #: build/C/man2/readahead.2:65 build/C/man2/remap_file_pages.2:122
241 #: build/C/man3/shm_open.3:169 build/C/man2/shmctl.2:272
242 #: build/C/man2/shmget.2:178 build/C/man2/shmop.2:169
243 #: build/C/man2/subpage_prot.2:61 build/C/man2/sync_file_range.2:141
244 #: build/C/man3/malloc_get_state.3:59 build/C/man3/malloc_trim.3:49
245 #: build/C/man3/malloc_usable_size.3:38
246 #, no-wrap
247 msgid "RETURN VALUE"
248 msgstr "返り値"
249
250 #. type: Plain text
251 #: build/C/man2/alloc_hugepages.2:118
252 msgid ""
253 "On success, B<alloc_hugepages>()  returns the allocated virtual address, and "
254 "B<free_hugepages>()  returns zero.  On error, -1 is returned, and I<errno> "
255 "is set appropriately."
256 msgstr ""
257 "成功した場合、 B<alloc_hugepages>()  は割り当てられた仮想アドレスを返し、 "
258 "B<free_hugepages>()  は 0 を返す。 失敗した場合、-1 を返し、 I<errno> が適切"
259 "に設定される。"
260
261 #. type: SH
262 #: build/C/man2/alloc_hugepages.2:118 build/C/man2/cacheflush.2:58
263 #: build/C/man2/fallocate.2:112 build/C/man2/madvise.2:257
264 #: build/C/man3/mallopt.3:382 build/C/man2/mlock.2:123 build/C/man2/mmap.2:390
265 #: build/C/man2/mmap2.2:61 build/C/man2/mprotect.2:79
266 #: build/C/man2/mremap.2:136 build/C/man2/msync.2:73
267 #: build/C/man2/posix_fadvise.2:89 build/C/man3/posix_fallocate.3:70
268 #: build/C/man3/posix_memalign.3:155 build/C/man2/readahead.2:71
269 #: build/C/man2/remap_file_pages.2:129 build/C/man3/shm_open.3:178
270 #: build/C/man2/shmctl.2:294 build/C/man2/shmget.2:182
271 #: build/C/man2/shmop.2:183 build/C/man2/subpage_prot.2:66
272 #: build/C/man2/sync_file_range.2:147 build/C/man3/malloc_trim.3:54
273 #, no-wrap
274 msgid "ERRORS"
275 msgstr "エラー"
276
277 #. type: TP
278 #: build/C/man2/alloc_hugepages.2:119 build/C/man2/fallocate.2:151
279 #, no-wrap
280 msgid "B<ENOSYS>"
281 msgstr "B<ENOSYS>"
282
283 #. type: Plain text
284 #: build/C/man2/alloc_hugepages.2:122
285 msgid "The system call is not supported on this kernel."
286 msgstr "このシステムコールはカーネルでサポートされていない。"
287
288 #. type: SH
289 #: build/C/man2/alloc_hugepages.2:122
290 #, no-wrap
291 msgid "FILES"
292 msgstr "ファイル"
293
294 #. type: Plain text
295 #: build/C/man2/alloc_hugepages.2:126
296 msgid ""
297 "I</proc/sys/vm/nr_hugepages> Number of configured hugetlb pages.  This can "
298 "be read and written."
299 msgstr ""
300 "I</proc/sys/vm/nr_hugepages> 設定された hugetlb ページの数。 このファイルは読"
301 "み書きできる。"
302
303 #. type: Plain text
304 #: build/C/man2/alloc_hugepages.2:130
305 msgid ""
306 "I</proc/meminfo> Gives info on the number of configured hugetlb pages and on "
307 "their size in the three variables HugePages_Total, HugePages_Free, "
308 "Hugepagesize."
309 msgstr ""
310 "I</proc/meminfo> 設定された hugetlb ページの数と、 3 つの変数 "
311 "HugePages_Total, HugePages_Free, Hugepagesize の サイズについての情報を提供す"
312 "る。"
313
314 #. type: SH
315 #: build/C/man2/alloc_hugepages.2:130 build/C/man3/alloca.3:63
316 #: build/C/man2/cacheflush.2:74 build/C/man2/fallocate.2:186
317 #: build/C/man2/madvise.2:307 build/C/man3/malloc_hook.3:76
318 #: build/C/man3/mallopt.3:390 build/C/man2/mlock.2:187 build/C/man2/mmap.2:483
319 #: build/C/man2/mmap2.2:77 build/C/man2/mprotect.2:107
320 #: build/C/man2/mremap.2:186 build/C/man2/msync.2:96 build/C/man3/mtrace.3:76
321 #: build/C/man2/posix_fadvise.2:111 build/C/man3/posix_fallocate.3:101
322 #: build/C/man3/posix_memalign.3:180 build/C/man2/readahead.2:87
323 #: build/C/man2/remap_file_pages.2:151 build/C/man3/shm_open.3:249
324 #: build/C/man7/shm_overview.7:101 build/C/man2/shmctl.2:366
325 #: build/C/man2/shmget.2:229 build/C/man2/shmop.2:226
326 #: build/C/man2/subpage_prot.2:91 build/C/man2/sync_file_range.2:180
327 #: build/C/man3/malloc_get_state.3:84 build/C/man3/malloc_trim.3:58
328 #: build/C/man3/malloc_usable_size.3:46
329 #, no-wrap
330 msgid "CONFORMING TO"
331 msgstr "準拠"
332
333 #. type: Plain text
334 #: build/C/man2/alloc_hugepages.2:133
335 msgid ""
336 "These calls are specific to Linux on Intel processors, and should not be "
337 "used in programs intended to be portable."
338 msgstr ""
339 "このシステムコールは Intel プロセッサ上の Linux に固有のものであり、 移植性が"
340 "必要なプログラムで使うべきでない。"
341
342 #. type: SH
343 #: build/C/man2/alloc_hugepages.2:133 build/C/man3/alloca.3:71
344 #: build/C/man2/madvise.2:328 build/C/man3/malloc_hook.3:78
345 #: build/C/man2/mlock.2:214 build/C/man2/mmap.2:501 build/C/man2/mmap2.2:79
346 #: build/C/man2/mprotect.2:116 build/C/man2/mremap.2:192
347 #: build/C/man3/mtrace.3:78 build/C/man2/posix_fadvise.2:120
348 #: build/C/man3/posix_memalign.3:219 build/C/man3/shm_open.3:255
349 #: build/C/man7/shm_overview.7:103 build/C/man2/shmctl.2:371
350 #: build/C/man2/shmget.2:235 build/C/man2/shmop.2:245
351 #: build/C/man2/subpage_prot.2:93 build/C/man2/sync_file_range.2:183
352 #: build/C/man3/malloc_get_state.3:86 build/C/man3/malloc_trim.3:60
353 #: build/C/man3/malloc_trim.3:72 build/C/man3/malloc_usable_size.3:48
354 #, no-wrap
355 msgid "NOTES"
356 msgstr "注意"
357
358 #. type: Plain text
359 #: build/C/man2/alloc_hugepages.2:141
360 msgid ""
361 "These system calls are gone; they existed only in Linux 2.5.36 through to "
362 "2.5.54.  Now the hugetlbfs file system can be used instead.  Memory backed "
363 "by huge pages (if the CPU supports them) is obtained by using B<mmap>(2)  to "
364 "map files in this virtual file system."
365 msgstr ""
366 "これらのシステムコールはなくなった。 これらは Linux 2.5.36 から 2.5.54 にのみ"
367 "存在する。 代わりに今は hugetlbfs ファイルシステムを使うことができる。 (CPU "
368 "がサポートしている場合) ヒュージページを持つメモリは、 B<mmap>(2)  を使ってこ"
369 "の仮想ファイルシステムでファイルをマップすることで取得できる。"
370
371 #. type: Plain text
372 #: build/C/man2/alloc_hugepages.2:145
373 msgid ""
374 "The maximal number of huge pages can be specified using the B<hugepages=> "
375 "boot parameter."
376 msgstr ""
377 "ヒュージページの最大数は、 B<hugepages=> 起動パラメータを使って指定できる。"
378
379 #. type: TH
380 #: build/C/man3/alloca.3:41
381 #, no-wrap
382 msgid "ALLOCA"
383 msgstr "ALLOCA"
384
385 #. type: TH
386 #: build/C/man3/alloca.3:41
387 #, no-wrap
388 msgid "2008-01-24"
389 msgstr "2008-01-24"
390
391 #. type: TH
392 #: build/C/man3/alloca.3:41 build/C/man3/malloc_hook.3:6
393 #: build/C/man3/mtrace.3:23 build/C/man3/posix_fallocate.3:23
394 #: build/C/man3/posix_memalign.3:28 build/C/man3/malloc_get_state.3:23
395 #: build/C/man3/malloc_usable_size.3:23
396 #, no-wrap
397 msgid "GNU"
398 msgstr "GNU"
399
400 #. type: Plain text
401 #: build/C/man3/alloca.3:44
402 msgid "alloca - allocate memory that is automatically freed"
403 msgstr "alloca - 自動的に解放されるメモリを割り当てる"
404
405 #. type: Plain text
406 #: build/C/man3/alloca.3:46
407 msgid "B<#include E<lt>alloca.hE<gt>>"
408 msgstr "B<#include E<lt>alloca.hE<gt>>"
409
410 #. type: Plain text
411 #: build/C/man3/alloca.3:48
412 msgid "B<void *alloca(size_t >I<size>B<);>"
413 msgstr "B<void *alloca(size_t >I<size>B<);>"
414
415 #. type: Plain text
416 #: build/C/man3/alloca.3:58
417 msgid ""
418 "The B<alloca>()  function allocates I<size> bytes of space in the stack "
419 "frame of the caller.  This temporary space is automatically freed when the "
420 "function that called B<alloca>()  returns to its caller."
421 msgstr ""
422 "B<alloca>()  関数は、 I<size> バイトの領域を呼出元のスタック・フレームに割り"
423 "付ける。 この一時的な領域は、 B<alloca>()  を呼び出した関数が呼出元に返るとき"
424 "に自動的に解放される。"
425
426 #. type: Plain text
427 #: build/C/man3/alloca.3:63
428 msgid ""
429 "The B<alloca>()  function returns a pointer to the beginning of the "
430 "allocated space.  If the allocation causes stack overflow, program behavior "
431 "is undefined."
432 msgstr ""
433 "B<alloca>()  関数は、割り付けた領域の始まりを指すポインタを返す。 割り付けに"
434 "よってスタックオーバーフローが起った場合の プログラムの動作は定義されていな"
435 "い。"
436
437 #. type: Plain text
438 #: build/C/man3/alloca.3:65
439 msgid "This function is not in POSIX.1-2001."
440 msgstr "この関数は POSIX.1-2001 にはない。"
441
442 #. type: Plain text
443 #: build/C/man3/alloca.3:71
444 msgid ""
445 "There is evidence that the B<alloca>()  function appeared in 32V, PWB, "
446 "PWB.2, 3BSD, and 4BSD.  There is a man page for it in 4.3BSD.  Linux uses "
447 "the GNU version."
448 msgstr ""
449 "32V, PWB, PWB.2, 3BSD, 4BSD に B<alloca>()  関数が登場した証拠がある。 "
450 "4.3BSD には、マニュアルページがある。 Linux は、GNU 版を使っている。 この関数"
451 "は POSIX.1-2001 にはない。"
452
453 #. type: Plain text
454 #: build/C/man3/alloca.3:86
455 msgid ""
456 "The B<alloca>()  function is machine- and compiler-dependent.  For certain "
457 "applications, its use can improve efficiency compared to the use of B<malloc>"
458 "(3)  plus B<free>(3).  In certain cases, it can also simplify memory "
459 "deallocation in applications that use B<longjmp>(3)  or B<siglongjmp>(3).  "
460 "Otherwise, its use is discouraged."
461 msgstr ""
462 "B<alloca>()  関数は、機種とコンパイラに依存する。 特定のアプリケーションで"
463 "は、この関数を使うと B<malloc>(3)  と B<free>(3)  を組み合わせて使った場合に"
464 "比べて効率を改善することができる。 特定の場合では、この関数を使うことで、 "
465 "B<longjmp>(3)  や B<siglongjmp>(3)  を使うアプリケーションでのメモリの開放を"
466 "簡単にすることができる。 それ以外の場合では、この関数の使用は推奨されない。"
467
468 #. type: Plain text
469 #: build/C/man3/alloca.3:95
470 msgid ""
471 "Because the space allocated by B<alloca>()  is allocated within the stack "
472 "frame, that space is automatically freed if the function return is jumped "
473 "over by a call to B<longjmp>(3)  or B<siglongjmp>(3)."
474 msgstr ""
475 "B<alloca>()  により割り当てられる空間はスタックフレームから割り当てらるの"
476 "で、 関数の戻り先が B<longjmp>(3)  や B<siglongjmp>(3)  の呼び出しによりジャ"
477 "ンプした場合には、 割り当てられた空間は自動的に解放される。"
478
479 #. type: Plain text
480 #: build/C/man3/alloca.3:100
481 msgid "Do not attempt to B<free>(3)  space allocated by B<alloca>()!"
482 msgstr ""
483 "B<alloca>()  で割り当てられた空間を B<free>(3)  しようとすることのないよう"
484 "に!"
485
486 #. type: SS
487 #: build/C/man3/alloca.3:100
488 #, no-wrap
489 msgid "Notes on the GNU Version"
490 msgstr "GNU 版についての注意"
491
492 #. type: Plain text
493 #: build/C/man3/alloca.3:122
494 msgid ""
495 "Normally, B<gcc>(1)  translates calls to B<alloca>()  with inlined code.  "
496 "This is not done when either the I<-ansi>, I<-std=c89>, I<-std=c99>, or the "
497 "I<-fno-builtin> option is given (and the header I<E<lt>alloca.hE<gt>> is not "
498 "included).  But beware! By default the glibc version of I<E<lt>stdlib."
499 "hE<gt>> includes I<E<lt>alloca.hE<gt>> and that contains the line:"
500 msgstr ""
501 "通常 B<gcc>(1)  は B<alloca>()  の呼び出しをインラインコードに変換する。 I<-"
502 "ansi>, I<-std=c89>, I<-std=c99>, I<-fno-builtin> のいずれかのオプションが指定"
503 "された場合、この変換は行われない (また I<E<lt>alloca.hE<gt>> のインクルードも"
504 "行われない)。 だだし、デフォルトでは glibc 版の I<E<lt>stdlib.hE<gt>> は "
505 "I<E<lt>alloca.hE<gt>> をインクルードしており、これには以下の行が含まれている"
506 "ので注意すること。"
507
508 #. type: Plain text
509 #: build/C/man3/alloca.3:125
510 #, no-wrap
511 msgid "    #define alloca(size)   __builtin_alloca (size)\n"
512 msgstr "    #define alloca(size)   __builtin_alloca (size)\n"
513
514 #. type: Plain text
515 #: build/C/man3/alloca.3:128
516 msgid "with messy consequences if one has a private version of this function."
517 msgstr "独自版の __builtin_alloca (size) 関数があると厄介な結果になる。"
518
519 #. type: Plain text
520 #: build/C/man3/alloca.3:132
521 msgid ""
522 "The fact that the code is inlined means that it is impossible to take the "
523 "address of this function, or to change its behavior by linking with a "
524 "different library."
525 msgstr ""
526 "このコードはインライン化されているので、 この関数のアドレスを取得したり、 他"
527 "のライブラリをリンクして動作を変更することはできない。"
528
529 #. type: Plain text
530 #: build/C/man3/alloca.3:136
531 msgid ""
532 "The inlined code often consists of a single instruction adjusting the stack "
533 "pointer, and does not check for stack overflow.  Thus, there is no NULL "
534 "error return."
535 msgstr ""
536 "通常このインラインコードはスタックポインタを移動する 1 つの命令 "
537 "(instruction) から構成されており、 スタックオーバーフローをチェックしない。 "
538 "よって NULL エラーが返されることはない。"
539
540 #. type: SH
541 #: build/C/man3/alloca.3:136 build/C/man2/cacheflush.2:81
542 #: build/C/man3/mallopt.3:404 build/C/man2/mlock.2:305 build/C/man2/mmap.2:544
543 #: build/C/man3/mtrace.3:100 build/C/man2/posix_fadvise.2:177
544 #: build/C/man2/shmget.2:284
545 #, no-wrap
546 msgid "BUGS"
547 msgstr "バグ"
548
549 #. type: Plain text
550 #: build/C/man3/alloca.3:141
551 msgid ""
552 "There is no error indication if the stack frame cannot be extended.  "
553 "(However, after a failed allocation, the program is likely to receive a "
554 "B<SIGSEGV> signal if it attempts to access the unallocated space.)"
555 msgstr ""
556 "スタックフレームが拡張できなかった場合、エラー通知は行われない。 (しかしなが"
557 "ら、割り当てに失敗した後で、プログラムが割り当てられなかった 空間にアクセスし"
558 "ようとした場合に B<SIGSEGV> シグナルを受信することだろう。)"
559
560 #. type: Plain text
561 #: build/C/man3/alloca.3:149
562 msgid ""
563 "On many systems B<alloca>()  cannot be used inside the list of arguments of "
564 "a function call, because the stack space reserved by B<alloca>()  would "
565 "appear on the stack in the middle of the space for the function arguments."
566 msgstr ""
567 "多くのシステムにおいて、関数コールの引き数のリスト内では B<alloca>()  が使え"
568 "ない。 これは、 B<alloca>()  によって予約されるスタック領域が、 関数引き数に"
569 "使われるスタック領域の中に現れてしまうためである。"
570
571 #. type: SH
572 #: build/C/man3/alloca.3:149 build/C/man2/fallocate.2:189
573 #: build/C/man2/madvise.2:353 build/C/man3/malloc_hook.3:133
574 #: build/C/man3/mallopt.3:568 build/C/man2/mlock.2:330 build/C/man2/mmap.2:653
575 #: build/C/man2/mmap2.2:92 build/C/man2/mprotect.2:220
576 #: build/C/man2/mremap.2:200 build/C/man2/msync.2:118
577 #: build/C/man3/mtrace.3:165 build/C/man2/posix_fadvise.2:182
578 #: build/C/man3/posix_fallocate.3:126 build/C/man3/posix_memalign.3:270
579 #: build/C/man2/readahead.2:92 build/C/man2/remap_file_pages.2:155
580 #: build/C/man3/shm_open.3:269 build/C/man7/shm_overview.7:114
581 #: build/C/man2/shmctl.2:403 build/C/man2/shmget.2:290
582 #: build/C/man2/shmop.2:282 build/C/man2/subpage_prot.2:120
583 #: build/C/man2/sync_file_range.2:217 build/C/man3/malloc_get_state.3:109
584 #: build/C/man3/malloc_trim.3:76 build/C/man3/malloc_usable_size.3:60
585 #, no-wrap
586 msgid "SEE ALSO"
587 msgstr "関連項目"
588
589 #. type: Plain text
590 #: build/C/man3/alloca.3:152
591 msgid "B<brk>(2), B<longjmp>(3), B<malloc>(3)"
592 msgstr "B<brk>(2), B<longjmp>(3), B<malloc>(3)"
593
594 #. type: TH
595 #: build/C/man2/cacheflush.2:24
596 #, no-wrap
597 msgid "CACHEFLUSH"
598 msgstr "CACHEFLUSH"
599
600 #. type: TH
601 #: build/C/man2/cacheflush.2:24
602 #, no-wrap
603 msgid "2007-05-26"
604 msgstr "2007-05-26"
605
606 #. type: Plain text
607 #: build/C/man2/cacheflush.2:27
608 msgid "cacheflush - flush contents of instruction and/or data cache"
609 msgstr "cacheflush - 命令キャッシュやデータキャッシュの内容をフラッシュする"
610
611 #. type: Plain text
612 #: build/C/man2/cacheflush.2:30
613 #, no-wrap
614 msgid "B<#include E<lt>asm/cachectl.hE<gt>>\n"
615 msgstr "B<#include E<lt>asm/cachectl.hE<gt>>\n"
616
617 #. type: Plain text
618 #: build/C/man2/cacheflush.2:32
619 #, no-wrap
620 msgid "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
621 msgstr "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
622
623 #. type: Plain text
624 #: build/C/man2/cacheflush.2:42
625 msgid ""
626 "B<cacheflush>()  flushes the contents of the indicated cache(s) for the user "
627 "addresses in the range I<addr> to I<(addr+nbytes-1)>.  I<cache> may be one "
628 "of:"
629 msgstr ""
630 "B<cacheflush>()  は I<addr> から I<(addr+nbytes-1)> の範囲のユーザアドレスに"
631 "対応する 指定されたキャッシュをフラッシュする。 I<cache> には以下のいずれかを"
632 "指定する:"
633
634 #. type: TP
635 #: build/C/man2/cacheflush.2:42
636 #, no-wrap
637 msgid "B<ICACHE>"
638 msgstr "B<ICACHE>"
639
640 #. type: Plain text
641 #: build/C/man2/cacheflush.2:45
642 msgid "Flush the instruction cache."
643 msgstr "命令 (instruction) キャッシュをフラッシュする。"
644
645 #. type: TP
646 #: build/C/man2/cacheflush.2:45
647 #, no-wrap
648 msgid "B<DCACHE>"
649 msgstr "B<DCACHE>"
650
651 #. type: Plain text
652 #: build/C/man2/cacheflush.2:48
653 msgid "Write back to memory and invalidate the affected valid cache lines."
654 msgstr "変更があったキャッシュラインをメモリに書き戻し、無効にする。"
655
656 #. type: TP
657 #: build/C/man2/cacheflush.2:48
658 #, no-wrap
659 msgid "B<BCACHE>"
660 msgstr "B<BCACHE>"
661
662 #. type: Plain text
663 #: build/C/man2/cacheflush.2:52
664 msgid "Same as B<(ICACHE|DCACHE)>."
665 msgstr "B<(ICACHE|DCACHE)> と同じ。"
666
667 #. type: Plain text
668 #: build/C/man2/cacheflush.2:58
669 msgid ""
670 "B<cacheflush>()  returns 0 on success or -1 on error.  If errors are "
671 "detected, I<errno> will indicate the error."
672 msgstr ""
673 "B<cacheflush>()  は成功した場合は 0 を、失敗した場合は -1 を返す。エラーが検"
674 "出された場合は I<errno> にエラーが指示される。"
675
676 #. type: TP
677 #: build/C/man2/cacheflush.2:59 build/C/man2/mmap2.2:62
678 #: build/C/man2/mremap.2:143 build/C/man2/shmctl.2:303
679 #: build/C/man2/subpage_prot.2:67
680 #, no-wrap
681 msgid "B<EFAULT>"
682 msgstr "B<EFAULT>"
683
684 #. type: Plain text
685 #: build/C/man2/cacheflush.2:66
686 msgid ""
687 "Some or all of the address range I<addr> to I<(addr+nbytes-1)> is not "
688 "accessible."
689 msgstr ""
690 "I<addr> から I<(addr+nbytes-1)> の範囲のアドレスの全てまたは一部が アクセス可"
691 "能ではない。"
692
693 #. type: TP
694 #: build/C/man2/cacheflush.2:66 build/C/man2/fallocate.2:124
695 #: build/C/man2/madvise.2:264 build/C/man2/mlock.2:158
696 #: build/C/man2/mlock.2:165 build/C/man2/mlock.2:177 build/C/man2/mmap.2:421
697 #: build/C/man2/mmap.2:429 build/C/man2/mmap.2:434 build/C/man2/mmap2.2:65
698 #: build/C/man2/mprotect.2:89 build/C/man2/mremap.2:152
699 #: build/C/man2/msync.2:80 build/C/man2/posix_fadvise.2:93
700 #: build/C/man3/posix_fallocate.3:79 build/C/man3/posix_memalign.3:156
701 #: build/C/man2/readahead.2:76 build/C/man2/remap_file_pages.2:130
702 #: build/C/man2/remap_file_pages.2:137 build/C/man3/shm_open.3:211
703 #: build/C/man2/shmctl.2:317 build/C/man2/shmget.2:196
704 #: build/C/man2/shmop.2:195 build/C/man2/shmop.2:218
705 #: build/C/man2/subpage_prot.2:72 build/C/man2/sync_file_range.2:152
706 #, no-wrap
707 msgid "B<EINVAL>"
708 msgstr "B<EINVAL>"
709
710 #. type: Plain text
711 #: build/C/man2/cacheflush.2:74
712 msgid "I<cache> is not one of B<ICACHE>, B<DCACHE>, or B<BCACHE>."
713 msgstr "I<cache> パラメータが B<ICACHE>, B<DCACHE>, B<BCACHE> のどれでもない。"
714
715 #.  FIXME This system call was only on MIPS back in 1.2 days, but
716 #.  by now it is on a number of other architectures (but not i386).
717 #.  Investigate the details and update this page.
718 #.  Irix 6.5 appears to have a cacheflush() syscall -- mtk
719 #. type: Plain text
720 #: build/C/man2/cacheflush.2:81
721 msgid ""
722 "This Linux-specific system call is only available on MIPS-based systems.  It "
723 "should not be used in programs intended to be portable."
724 msgstr ""
725 "この Linux 特有のシステムコールは MIPS ベースのシステムでのみ有効である。 移"
726 "植を意図したプログラムで使用すべきではない。"
727
728 #. type: Plain text
729 #: build/C/man2/cacheflush.2:87
730 msgid ""
731 "The current implementation ignores the I<addr> and I<nbytes> arguments.  "
732 "Therefore, the whole cache is always flushed."
733 msgstr ""
734 "現在の実装では、引き数 I<addr> と I<nbytes> は無視される。そのため、 常に全て"
735 "のキャッシュがフラッシュされる。"
736
737 #. type: TH
738 #: build/C/man2/fallocate.2:8
739 #, no-wrap
740 msgid "FALLOCATE"
741 msgstr "FALLOCATE"
742
743 #. type: TH
744 #: build/C/man2/fallocate.2:8
745 #, no-wrap
746 msgid "2012-02-27"
747 msgstr "2012-02-27"
748
749 #. type: Plain text
750 #: build/C/man2/fallocate.2:11
751 msgid "fallocate - manipulate file space"
752 msgstr "fallocate - ファイル空間の操作"
753
754 #. type: Plain text
755 #: build/C/man2/fallocate.2:15 build/C/man2/readahead.2:35
756 #, no-wrap
757 msgid ""
758 "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
759 "B<#include E<lt>fcntl.hE<gt>>\n"
760 msgstr ""
761 "B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
762 "B<#include E<lt>fcntl.hE<gt>>\n"
763
764 #. type: Plain text
765 #: build/C/man2/fallocate.2:18
766 #, no-wrap
767 msgid "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
768 msgstr "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
769
770 #. type: Plain text
771 #: build/C/man2/fallocate.2:24
772 msgid ""
773 "This is a nonportable, Linux-specific system call.  For the portable, "
774 "POSIX.1-specified method of ensuring that space is allocated for a file, see "
775 "B<posix_fallocate>(3)."
776 msgstr ""
777 "このシステムコールは、移植性のない、Linux 固有のシステムコールである。 移植性"
778 "が必要な場合は、ファイルに対してディスク空間を確実に確保するために、 POSIX.1 "
779 "で規定された方法である B<posix_fallocate>(3)  を使うこと。"
780
781 #. type: Plain text
782 #: build/C/man2/fallocate.2:34
783 msgid ""
784 "B<fallocate>()  allows the caller to directly manipulate the allocated disk "
785 "space for the file referred to by I<fd> for the byte range starting at "
786 "I<offset> and continuing for I<len> bytes."
787 msgstr ""
788 "B<fallocate>()  を使うと、 I<fd> が参照するファイルに割り当てられたディスク空"
789 "間を直接操作できる。 操作対象は、 I<offset> から始まる長さ I<len> バイトの領"
790 "域である。"
791
792 #. type: Plain text
793 #: build/C/man2/fallocate.2:39
794 msgid ""
795 "The I<mode> argument determines the operation to be performed on the given "
796 "range.  Details of the supported operations are given in the subsections "
797 "below."
798 msgstr ""
799 "I<mode> 引き数は、指定された領域に対して実行する操作を指定する。\n"
800 "サポートされている操作の詳細は以下のサブセクションで説明する。"
801
802 #. type: SS
803 #: build/C/man2/fallocate.2:39
804 #, no-wrap
805 msgid "Allocating disk space"
806 msgstr "ディスク領域の割り当て"
807
808 #. type: Plain text
809 #: build/C/man2/fallocate.2:58
810 msgid ""
811 "The default operation (i.e., I<mode> is zero) of B<fallocate>()  allocates "
812 "and initializes to zero the disk space within the range specified by "
813 "I<offset> and I<len>.  The file size (as reported by B<stat>(2))  will be "
814 "changed if I<offset>+I<len> is greater than the file size.  This default "
815 "behavior closely resembles the behavior of the B<posix_fallocate>(3)  "
816 "library function, and is intended as a method of optimally implementing that "
817 "function."
818 msgstr ""
819 "B<fallocate>() のデフォルトの動作 (つまり I<mode> が 0 の場合) は、\n"
820 "I<offset> と I<len> で指定された範囲のディスク領域の割り当てと初期化を行う。\n"
821 "I<offset>+I<len> がファイルサイズよりも大きかった場合、\n"
822 "(B<stat>(2) で報告される) ファイルサイズが変更される。このデフォルトの動作は、\n"
823 "ライブラリ関数 B<posix_fallocate>(3) の動作と非常に似ている。これは、\n"
824 "このシステムコールが B<posix_fallocate>(3) を最適に実装する手段を提供する\n"
825 "ことを目的としているからである。"
826
827 #. type: Plain text
828 #: build/C/man2/fallocate.2:64
829 msgid ""
830 "After a successful call, subsequent writes into the range specified by "
831 "I<offset> and I<len> are guaranteed not to fail because of lack of disk "
832 "space."
833 msgstr ""
834
835 #. type: Plain text
836 #: build/C/man2/fallocate.2:75
837 msgid ""
838 "If the B<FALLOC_FL_KEEP_SIZE> flag is specified in I<mode>, the behavior of "
839 "the call is similar, but the file size will not be changed even if I<offset>"
840 "+I<len> is greater than the file size.  Preallocating zeroed blocks beyond "
841 "the end of the file in this manner is useful for optimizing append workloads."
842 msgstr ""
843 "B<FALLOC_FL_KEEP_SIZE> フラグが I<mode> に指定された場合、このシステムコール\n"
844 "の動作は似ているが、 I<offset>+I<len> がファイルサイズよりも大きい場合で\n"
845 "あってもファイルサイズは変更されない点が異なる。この場合のファイルの末尾\n"
846 "よりも後ろの前もって割り当てられた 0 で埋められたブロックは、ファイルへの\n"
847 "追記を最適化したい場合に役に立つ。"
848
849 #. type: Plain text
850 #: build/C/man2/fallocate.2:79
851 msgid ""
852 "Because allocation is done in block size chunks, B<fallocate>()  may "
853 "allocate a larger range of disk space than was specified."
854 msgstr ""
855 "割り当てはブロックサイズ単位で行われるため、 B<fallocate>() は指定されたより\n"
856 "も大きなディスク領域を割り当てることがある。"
857
858 #. type: SS
859 #: build/C/man2/fallocate.2:79
860 #, no-wrap
861 msgid "Deallocating file space"
862 msgstr "ファイル空間の割り当て解除"
863
864 #. type: Plain text
865 #: build/C/man2/fallocate.2:94
866 msgid ""
867 "Specifying the B<FALLOC_FL_PUNCH_HOLE> flag (available since Linux 2.6.38) "
868 "in I<mode> deallocates space (i.e., creates a hole)  in the byte range "
869 "starting at I<offset> and continuing for I<len> bytes.  Within the specified "
870 "range, partial file system blocks are zeroed, and whole file system blocks "
871 "are removed from the file.  After a successful call, subsequent reads from "
872 "this range will return zeroes."
873 msgstr ""
874
875 #. type: Plain text
876 #: build/C/man2/fallocate.2:105
877 msgid ""
878 "The B<FALLOC_FL_PUNCH_HOLE> flag must be ORed with B<FALLOC_FL_KEEP_SIZE> in "
879 "I<mode>; in other words, even when punching off the end of the file, the "
880 "file size (as reported by B<stat>(2))  does not change."
881 msgstr ""
882
883 #. type: Plain text
884 #: build/C/man2/fallocate.2:109
885 msgid ""
886 "Not all file systems support B<FALLOC_FL_PUNCH_HOLE>; if a file system "
887 "doesn't support the operation, an error is returned."
888 msgstr ""
889
890 #. type: Plain text
891 #: build/C/man2/fallocate.2:112
892 msgid "B<fallocate>()  returns zero on success, and -1 on failure."
893 msgstr "B<fallocate>()  は成功すると 0 を返し、エラーの場合は -1 を返す。"
894
895 #. type: TP
896 #: build/C/man2/fallocate.2:113 build/C/man2/madvise.2:261
897 #: build/C/man2/mmap.2:415 build/C/man2/posix_fadvise.2:90
898 #: build/C/man3/posix_fallocate.3:71 build/C/man2/readahead.2:72
899 #: build/C/man2/sync_file_range.2:148
900 #, no-wrap
901 msgid "B<EBADF>"
902 msgstr "B<EBADF>"
903
904 #. type: Plain text
905 #: build/C/man2/fallocate.2:117 build/C/man3/posix_fallocate.3:75
906 msgid "I<fd> is not a valid file descriptor, or is not opened for writing."
907 msgstr ""
908 "I<fd> が有効なファイルディスクリプタでないか、 書き込み用としてオープンされて"
909 "いない。"
910
911 #. type: TP
912 #: build/C/man2/fallocate.2:117 build/C/man3/posix_fallocate.3:75
913 #, no-wrap
914 msgid "B<EFBIG>"
915 msgstr "B<EFBIG>"
916
917 #. type: Plain text
918 #: build/C/man2/fallocate.2:121
919 msgid "I<offset>+I<len> exceeds the maximum file size."
920 msgstr "I<offset + len> がファイルサイズの最大値よりも大きい。"
921
922 #. type: TP
923 #: build/C/man2/fallocate.2:121
924 #, no-wrap
925 msgid "B<EINTR>"
926 msgstr "B<EINTR>"
927
928 #. type: Plain text
929 #: build/C/man2/fallocate.2:124
930 msgid "A signal was caught during execution."
931 msgstr "実行中にシグナルが捕捉された。"
932
933 #. type: Plain text
934 #: build/C/man2/fallocate.2:136 build/C/man3/posix_fallocate.3:85
935 msgid "I<offset> was less than 0, or I<len> was less than or equal to 0."
936 msgstr "I<offset> が 0 未満だったか、 I<len> が 0 以下だった。"
937
938 #. type: TP
939 #: build/C/man2/fallocate.2:136 build/C/man2/madvise.2:292
940 #: build/C/man2/sync_file_range.2:160
941 #, no-wrap
942 msgid "B<EIO>"
943 msgstr "B<EIO>"
944
945 #. type: Plain text
946 #: build/C/man2/fallocate.2:139
947 msgid "An I/O error occurred while reading from or writing to a file system."
948 msgstr "ファイルシステムとの読み書き中に入出力エラーが発生した。"
949
950 #. type: TP
951 #: build/C/man2/fallocate.2:139 build/C/man2/mmap.2:450
952 #: build/C/man3/posix_fallocate.3:85
953 #, no-wrap
954 msgid "B<ENODEV>"
955 msgstr "B<ENODEV>"
956
957 #. type: Plain text
958 #: build/C/man2/fallocate.2:146
959 msgid ""
960 "I<fd> does not refer to a regular file or a directory.  (If I<fd> is a pipe "
961 "or FIFO, a different error results.)"
962 msgstr ""
963 "I<fd> が通常のファイルかディレクトリを参照していない (I<fd> がパイプや FIFO "
964 "を参照している場合、別のエラーが発生する)。"
965
966 #. type: TP
967 #: build/C/man2/fallocate.2:146 build/C/man3/posix_fallocate.3:89
968 #: build/C/man2/shmget.2:214 build/C/man2/sync_file_range.2:166
969 #, no-wrap
970 msgid "B<ENOSPC>"
971 msgstr "B<ENOSPC>"
972
973 #. type: Plain text
974 #: build/C/man2/fallocate.2:151 build/C/man3/posix_fallocate.3:94
975 msgid ""
976 "There is not enough space left on the device containing the file referred to "
977 "by I<fd>."
978 msgstr "I<fd> が参照するファイルを含むデバイスに十分な空き領域がない。"
979
980 #. type: Plain text
981 #: build/C/man2/fallocate.2:156
982 msgid ""
983 "The file system containing the file referred to by I<fd> does not support "
984 "this operation."
985 msgstr ""
986 "I<fd> が参照するファイルを含むファイルシステムが 指定された操作をサポートして"
987 "いない。"
988
989 #. type: TP
990 #: build/C/man2/fallocate.2:156
991 #, no-wrap
992 msgid "B<EOPNOTSUPP>"
993 msgstr "B<EOPNOTSUPP>"
994
995 #. type: Plain text
996 #: build/C/man2/fallocate.2:162
997 msgid ""
998 "The I<mode> is not supported by the file system containing the file referred "
999 "to by I<fd>."
1000 msgstr ""
1001 "I<fd> が参照するファイルを含むファイルシステムが I<mode> をサポートしていな"
1002 "い。"
1003
1004 #. type: TP
1005 #: build/C/man2/fallocate.2:162 build/C/man2/mlock.2:144
1006 #: build/C/man2/mlock.2:183 build/C/man2/mmap.2:458 build/C/man2/shmctl.2:342
1007 #: build/C/man2/shmget.2:222
1008 #, no-wrap
1009 msgid "B<EPERM>"
1010 msgstr "B<EPERM>"
1011
1012 #. type: Plain text
1013 #: build/C/man2/fallocate.2:178
1014 msgid ""
1015 "The file referred to by I<fd> is marked immutable (see B<chattr>(1)).  Or: "
1016 "I<mode> specifies B<FALLOC_FL_PUNCH_HOLE> and the file referred to by I<fd> "
1017 "is marked append-only (see B<chattr>(1))."
1018 msgstr ""
1019
1020 #. type: TP
1021 #: build/C/man2/fallocate.2:178 build/C/man2/posix_fadvise.2:96
1022 #: build/C/man3/posix_fallocate.3:94 build/C/man2/sync_file_range.2:169
1023 #, no-wrap
1024 msgid "B<ESPIPE>"
1025 msgstr "B<ESPIPE>"
1026
1027 #. type: Plain text
1028 #: build/C/man2/fallocate.2:182
1029 msgid "I<fd> refers to a pipe or FIFO."
1030 msgstr "I<fd> がパイプか FIFO を参照している。"
1031
1032 #. type: SH
1033 #: build/C/man2/fallocate.2:182 build/C/man2/mmap2.2:74
1034 #: build/C/man2/posix_fadvise.2:103 build/C/man3/posix_fallocate.3:98
1035 #: build/C/man3/posix_memalign.3:165 build/C/man2/readahead.2:82
1036 #: build/C/man2/remap_file_pages.2:146 build/C/man3/shm_open.3:247
1037 #: build/C/man2/subpage_prot.2:85 build/C/man2/sync_file_range.2:177
1038 #, no-wrap
1039 msgid "VERSIONS"
1040 msgstr "バージョン"
1041
1042 #. type: Plain text
1043 #: build/C/man2/fallocate.2:186
1044 msgid ""
1045 "B<fallocate>()  is available on Linux since kernel 2.6.23.  Support is "
1046 "provided by glibc since version 2.10."
1047 msgstr ""
1048 "B<fallocate>()  はカーネル 2.6.23 以降の Linux で利用可能である。 glibc での"
1049 "対応はバージョン 3.10 以降で行われている。"
1050
1051 #. type: Plain text
1052 #: build/C/man2/fallocate.2:189
1053 msgid "B<fallocate>()  is Linux-specific."
1054 msgstr "B<fallocate>()  は Linux 固有である。"
1055
1056 #. type: Plain text
1057 #: build/C/man2/fallocate.2:192
1058 msgid "B<ftruncate>(2), B<posix_fadvise>(3), B<posix_fallocate>(3)"
1059 msgstr "B<ftruncate>(2), B<posix_fadvise>(3), B<posix_fallocate>(3)"
1060
1061 #. type: TH
1062 #: build/C/man2/madvise.2:35
1063 #, no-wrap
1064 msgid "MADVISE"
1065 msgstr "MADVISE"
1066
1067 #. type: TH
1068 #: build/C/man2/madvise.2:35
1069 #, no-wrap
1070 msgid "2011-09-18"
1071 msgstr "2011-09-18"
1072
1073 #. type: Plain text
1074 #: build/C/man2/madvise.2:38
1075 msgid "madvise - give advice about use of memory"
1076 msgstr "madvise - メモリ利用に関するアドバイスを与える"
1077
1078 #. type: Plain text
1079 #: build/C/man2/madvise.2:40 build/C/man2/msync.2:30
1080 #: build/C/man3/shm_open.3:31
1081 msgid "B<#include E<lt>sys/mman.hE<gt>>"
1082 msgstr "B<#include E<lt>sys/mman.hE<gt>>"
1083
1084 #. type: Plain text
1085 #: build/C/man2/madvise.2:42
1086 msgid ""
1087 "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
1088 msgstr ""
1089 "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
1090
1091 #. type: Plain text
1092 #: build/C/man2/madvise.2:46 build/C/man2/posix_fadvise.2:42
1093 #: build/C/man3/posix_fallocate.3:37 build/C/man3/posix_memalign.3:48
1094 msgid ""
1095 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
1096 msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)  参照):"
1097
1098 #. type: Plain text
1099 #: build/C/man2/madvise.2:50
1100 msgid "B<madvise>(): _BSD_SOURCE"
1101 msgstr "B<madvise>(): _BSD_SOURCE"
1102
1103 #. type: Plain text
1104 #: build/C/man2/madvise.2:68
1105 msgid ""
1106 "The B<madvise>()  system call advises the kernel about how to handle paging "
1107 "input/output in the address range beginning at address I<addr> and with size "
1108 "I<length> bytes.  It allows an application to tell the kernel how it expects "
1109 "to use some mapped or shared memory areas, so that the kernel can choose "
1110 "appropriate read-ahead and caching techniques.  This call does not influence "
1111 "the semantics of the application (except in the case of B<MADV_DONTNEED>), "
1112 "but may influence its performance.  The kernel is free to ignore the advice."
1113 msgstr ""
1114 "B<madvise>()  システムコールは、アドレス I<addr> からはじまる I<length> バイ"
1115 "トのメモリブロックのページング入出力をどう扱えば良いか、 カーネルにアドバイス"
1116 "する。 これを用いると、 アプリケーションからカーネルに、 マップされたメモリや"
1117 "共有メモリをどのように扱ってほしいか伝えることができ、 カーネルはそれに応じて"
1118 "先読みやキャッシュなどの適切な手法を選択できる。 このコールはアプリケーション"
1119 "の動作そのものには影響しない (B<MADV_DONTNEED> の場合は別) が、 性能には影響"
1120 "しうる。 なおこのアドバイスを受け入れるかどうかはカーネルに任される。"
1121
1122 #. type: Plain text
1123 #: build/C/man2/madvise.2:72
1124 msgid "The advice is indicated in the I<advice> argument which can be"
1125 msgstr ""
1126 "アドバイスは引き数 I<advice> によって与える。以下のいずれかを指定できる。"
1127
1128 #. type: TP
1129 #: build/C/man2/madvise.2:72
1130 #, no-wrap
1131 msgid "B<MADV_NORMAL>"
1132 msgstr "B<MADV_NORMAL>"
1133
1134 #. type: Plain text
1135 #: build/C/man2/madvise.2:76
1136 msgid "No special treatment.  This is the default."
1137 msgstr "特別な扱いは行わない。これがデフォルトである。"
1138
1139 #. type: TP
1140 #: build/C/man2/madvise.2:76
1141 #, no-wrap
1142 msgid "B<MADV_RANDOM>"
1143 msgstr "B<MADV_RANDOM>"
1144
1145 #. type: Plain text
1146 #: build/C/man2/madvise.2:80
1147 msgid ""
1148 "Expect page references in random order.  (Hence, read ahead may be less "
1149 "useful than normally.)"
1150 msgstr ""
1151 "ページ参照はランダムな順序で行われそうだ。 (したがって、先読みはあまり効果が"
1152 "なさそうだ。)"
1153
1154 #. type: TP
1155 #: build/C/man2/madvise.2:80
1156 #, no-wrap
1157 msgid "B<MADV_SEQUENTIAL>"
1158 msgstr "B<MADV_SEQUENTIAL>"
1159
1160 #. type: Plain text
1161 #: build/C/man2/madvise.2:85
1162 msgid ""
1163 "Expect page references in sequential order.  (Hence, pages in the given "
1164 "range can be aggressively read ahead, and may be freed soon after they are "
1165 "accessed.)"
1166 msgstr ""
1167 "ページ参照はシーケンシャルな順序で行われそうだ。 (したがって与えた範囲のペー"
1168 "ジは積極的に先読みしておくと良いだろう。 またアクセスが終わったら速やかに解放"
1169 "して良い。)"
1170
1171 #. type: TP
1172 #: build/C/man2/madvise.2:85
1173 #, no-wrap
1174 msgid "B<MADV_WILLNEED>"
1175 msgstr "B<MADV_WILLNEED>"
1176
1177 #. type: Plain text
1178 #: build/C/man2/madvise.2:89
1179 msgid ""
1180 "Expect access in the near future.  (Hence, it might be a good idea to read "
1181 "some pages ahead.)"
1182 msgstr ""
1183 "近い将来にアクセスされそうだ。 (したがってこれらのページを今のうちに先読みし"
1184 "ておくといいだろう。)"
1185
1186 #. type: TP
1187 #: build/C/man2/madvise.2:89
1188 #, no-wrap
1189 msgid "B<MADV_DONTNEED>"
1190 msgstr "B<MADV_DONTNEED>"
1191
1192 #. type: Plain text
1193 #: build/C/man2/madvise.2:100
1194 msgid ""
1195 "Do not expect access in the near future.  (For the time being, the "
1196 "application is finished with the given range, so the kernel can free "
1197 "resources associated with it.)  Subsequent accesses of pages in this range "
1198 "will succeed, but will result either in reloading of the memory contents "
1199 "from the underlying mapped file (see B<mmap>(2))  or zero-fill-on-demand "
1200 "pages for mappings without an underlying file."
1201 msgstr ""
1202 "しばらくアクセスはなさそうだ。 (現時点でアプリケーションは与えた範囲の処理を"
1203 "終えている。 したがってカーネルはこれに関連するリソースを解放して良い。)  こ"
1204 "れ以降この範囲のページへのアクセスがあると、 成功はするが、メモリの内容をマッ"
1205 "プ元のファイルからロードし直すことになる (B<mmap>(2)  を見よ) か、 または元"
1206 "ファイルがないマップページでは アクセスがあったときに 0 埋めが行われることに"
1207 "なる。"
1208
1209 #. type: TP
1210 #: build/C/man2/madvise.2:100
1211 #, no-wrap
1212 msgid "B<MADV_REMOVE> (Since Linux 2.6.16)"
1213 msgstr "B<MADV_REMOVE> (Linux 2.6.16 以降)"
1214
1215 #.  2.6.18-rc5
1216 #.  Databases want to use this feature to drop a section of their
1217 #.  bufferpool (shared memory segments) - without writing back to
1218 #.  disk/swap space.  This feature is also useful for supporting
1219 #.  hot-plug memory on UML.
1220 #. type: Plain text
1221 #: build/C/man2/madvise.2:113
1222 msgid ""
1223 "Free up a given range of pages and its associated backing store.  Currently, "
1224 "only shmfs/tmpfs supports this; other file systems return with the error "
1225 "B<ENOSYS>."
1226 msgstr ""
1227 "指定された範囲のページと関連するバッキングストアを解放する。 現在のところ、 "
1228 "shmfs/tmpfs だけがこれに対応している。 他のファイルシステムでは B<ENOSYS> が"
1229 "返される。"
1230
1231 #. type: TP
1232 #: build/C/man2/madvise.2:113
1233 #, no-wrap
1234 msgid "B<MADV_DONTFORK> (Since Linux 2.6.16)"
1235 msgstr "B<MADV_DONTFORK> (Linux 2.6.16 以降)"
1236
1237 #.  See http://lwn.net/Articles/171941/
1238 #.  [PATCH] madvise MADV_DONTFORK/MADV_DOFORK
1239 #.  Currently, copy-on-write may change the physical address of
1240 #.  a page even if the user requested that the page is pinned in
1241 #.  memory (either by mlock or by get_user_pages).  This happens
1242 #.  if the process forks meanwhile, and the parent writes to that
1243 #.  page.  As a result, the page is orphaned: in case of
1244 #.  get_user_pages, the application will never see any data hardware
1245 #.  DMA's into this page after the COW.  In case of mlock'd memory,
1246 #.  the parent is not getting the realtime/security benefits of mlock.
1247 #.  In particular, this affects the Infiniband modules which do DMA from
1248 #.  and into user pages all the time.
1249 #.  This patch adds madvise options to control whether memory range is
1250 #.  inherited across fork. Useful e.g. for when hardware is doing DMA
1251 #.  from/into these pages.  Could also be useful to an application
1252 #.  wanting to speed up its forks by cutting large areas out of
1253 #.  consideration.
1254 #.  SEE ALSO: http://lwn.net/Articles/171941/
1255 #.  "Tweaks to madvise() and posix_fadvise()", 14 Feb 2006
1256 #. type: Plain text
1257 #: build/C/man2/madvise.2:144
1258 msgid ""
1259 "Do not make the pages in this range available to the child after a B<fork>"
1260 "(2).  This is useful to prevent copy-on-write semantics from changing the "
1261 "physical location of a page(s) if the parent writes to it after a B<fork>"
1262 "(2).  (Such page relocations cause problems for hardware that DMAs into the "
1263 "page(s).)"
1264 msgstr ""
1265 "B<fork>(2)  が行われた後、指定された範囲のページを子プロセスが利用できないよ"
1266 "うにする。 この機能は、書き込み時コピー (copy-on-write) 方式で、 B<fork>(2)  "
1267 "の後で親プロセスがページに書き込みを行った場合に ページの物理位置が変化しない"
1268 "ようにするのに有効である (ページの再配置はハードウェアがそのページに DMA 転送"
1269 "を行うような場合に 問題を起こすことがある)。"
1270
1271 #. type: TP
1272 #: build/C/man2/madvise.2:144
1273 #, no-wrap
1274 msgid "B<MADV_DOFORK> (Since Linux 2.6.16)"
1275 msgstr "B<MADV_DOFORK> (Linux 2.6.16 以降)"
1276
1277 #. type: Plain text
1278 #: build/C/man2/madvise.2:150
1279 msgid ""
1280 "Undo the effect of B<MADV_DONTFORK>, restoring the default behavior, whereby "
1281 "a mapping is inherited across B<fork>(2)."
1282 msgstr ""
1283 "B<MADV_DONTFORK> の影響を取り消し、デフォルトの動作に戻す。 つまり、 B<fork>"
1284 "(2)  の前後でマッピングは継承されるようになる。"
1285
1286 #. type: TP
1287 #: build/C/man2/madvise.2:150
1288 #, no-wrap
1289 msgid "B<MADV_HWPOISON> (Since Linux 2.6.32)"
1290 msgstr "B<MADV_HWPOISON> (Linux 2.6.32 以降)"
1291
1292 #. type: Plain text
1293 #: build/C/man2/madvise.2:162
1294 msgid ""
1295 "Poison a page and handle it like a hardware memory corruption.  This "
1296 "operation is only available for privileged (B<CAP_SYS_ADMIN>)  processes.  "
1297 "This operation may result in the calling process receiving a B<SIGBUS> and "
1298 "the page being unmapped.  This feature is intended for testing of memory "
1299 "error-handling code; it is only available if the kernel was configured with "
1300 "B<CONFIG_MEMORY_FAILURE>."
1301 msgstr ""
1302
1303 #. type: TP
1304 #: build/C/man2/madvise.2:162
1305 #, no-wrap
1306 msgid "B<MADV_SOFT_OFFLINE> (Since Linux 2.6.33)"
1307 msgstr "B<MADV_SOFT_OFFLINE> (Linux 2.6.33 以降)"
1308
1309 #. type: Plain text
1310 #: build/C/man2/madvise.2:180
1311 msgid ""
1312 "Soft offline the pages in the range specified by I<addr> and I<length>.  The "
1313 "memory of each page in the specified range is preserved (i.e., when next "
1314 "accessed, the same content will be visible, but in a new physical page "
1315 "frame), and the original page is offlined (i.e., no longer used, and taken "
1316 "out of normal memory management).  The effect of the B<MADV_SOFT_OFFLINE> "
1317 "operation is invisible to (i.e., does not change the semantics of)  the "
1318 "calling process.  This feature is intended for testing of memory error-"
1319 "handling code; it is only available if the kernel was configured with "
1320 "B<CONFIG_MEMORY_FAILURE>."
1321 msgstr ""
1322
1323 #. type: TP
1324 #: build/C/man2/madvise.2:180
1325 #, no-wrap
1326 msgid "B<MADV_MERGEABLE> (since Linux 2.6.32)"
1327 msgstr "B<MADV_MERGEABLE> (Linux 2.6.32 以降)"
1328
1329 #. type: Plain text
1330 #: build/C/man2/madvise.2:205
1331 msgid ""
1332 "Enable Kernel Samepage Merging (KSM) for the pages in the range specified by "
1333 "I<addr> and I<length>.  The kernel regularly scans those areas of user "
1334 "memory that have been marked as mergeable, looking for pages with identical "
1335 "content.  These are replaced by a single write-protected page (which is "
1336 "automatically copied if a process later wants to update the content of the "
1337 "page).  KSM only merges private anonymous pages (see B<mmap>(2)).  The KSM "
1338 "feature is intended for applications that generate many instances of the "
1339 "same data (e.g., virtualization systems such as KVM).  It can consume a lot "
1340 "of processing power; use with care.  See the kernel source file "
1341 "I<Documentation/vm/ksm.txt> for more details.  The B<MADV_MERGEABLE> and "
1342 "B<MADV_UNMERGEABLE> operations are only available if the kernel was "
1343 "configured with B<CONFIG_KSM>."
1344 msgstr ""
1345
1346 #. type: TP
1347 #: build/C/man2/madvise.2:205
1348 #, no-wrap
1349 msgid "B<MADV_UNMERGEABLE> (since Linux 2.6.32)"
1350 msgstr "B<MADV_UNMERGEABLE> (Linux 2.6.32 以降)"
1351
1352 #. type: Plain text
1353 #: build/C/man2/madvise.2:214
1354 msgid ""
1355 "Undo the effect of an earlier B<MADV_MERGEABLE> operation on the specified "
1356 "address range; KSM unmerges whatever pages it had merged in the address "
1357 "range specified by I<addr> and I<length>."
1358 msgstr ""
1359
1360 #. type: TP
1361 #: build/C/man2/madvise.2:214
1362 #, no-wrap
1363 msgid "B<MADV_HUGEPAGE> (since Linux 2.6.38)"
1364 msgstr "B<MADV_HUGEPAGE> (Linux 2.6.38 以降)"
1365
1366 #.  http://lwn.net/Articles/358904/
1367 #.  https://lwn.net/Articles/423584/
1368 #. type: Plain text
1369 #: build/C/man2/madvise.2:243
1370 msgid ""
1371 "Enables Transparent Huge Pages (THP) for pages in the range specified by "
1372 "I<addr> and I<length>.  Currently, Transparent Huge Pages only work with "
1373 "private anonymous pages (see B<mmap>(2)).  The kernel will regularly scan "
1374 "the areas marked as huge page candidates to replace them with huge pages.  "
1375 "The kernel will also allocate huge pages directly when the region is "
1376 "naturally aligned to the huge page size (see B<posix_memalign>(2)).  This "
1377 "feature is primarily aimed at applications that use large mappings of data "
1378 "and access large regions of that memory at a time (e.g. virtualization "
1379 "systems such as QEMU).  It can very easily waste memory (e.g. a 2MB mapping "
1380 "that only ever accesses 1 byte will result in 2MB of wired memory instead of "
1381 "one 4KB page).  See the kernel source file I<Documentation/vm/transhuge.txt> "
1382 "for more details.  The B<MADV_HUGEPAGE> and B<MADV_NOHUGEPAGE> operations "
1383 "are only available if the kernel was configured with "
1384 "B<CONFIG_TRANSPARENT_HUGEPAGE>."
1385 msgstr ""
1386
1387 #. type: TP
1388 #: build/C/man2/madvise.2:243
1389 #, no-wrap
1390 msgid "B<MADV_NOHUGEPAGE> (since Linux 2.6.38)"
1391 msgstr "B<MADV_NOHUGEPAGE> (Linux 2.6.38 以降)"
1392
1393 #. type: Plain text
1394 #: build/C/man2/madvise.2:250
1395 msgid ""
1396 "Ensures that memory in the address range specified by I<addr> and I<length> "
1397 "will not be collapsed into huge pages."
1398 msgstr ""
1399
1400 #. type: Plain text
1401 #: build/C/man2/madvise.2:257
1402 msgid ""
1403 "On success B<madvise>()  returns zero.  On error, it returns -1 and I<errno> "
1404 "is set appropriately."
1405 msgstr ""
1406 "B<madvise>()  は成功すると 0 を返す。 エラーが起こると -1 を返し、 I<errno> "
1407 "を適切な値に設定する。"
1408
1409 #. type: TP
1410 #: build/C/man2/madvise.2:258 build/C/man2/mlock.2:155 build/C/man2/mmap.2:411
1411 #: build/C/man2/mremap.2:137
1412 #, no-wrap
1413 msgid "B<EAGAIN>"
1414 msgstr "B<EAGAIN>"
1415
1416 #. type: Plain text
1417 #: build/C/man2/madvise.2:261
1418 msgid "A kernel resource was temporarily unavailable."
1419 msgstr "何らかのカーネルリソースが一時的に利用できなかった。"
1420
1421 #. type: Plain text
1422 #: build/C/man2/madvise.2:264
1423 msgid "The map exists, but the area maps something that isn't a file."
1424 msgstr "指定したマップは存在するが、ファイルではないところをマップしている。"
1425
1426 #. type: Plain text
1427 #: build/C/man2/madvise.2:267
1428 msgid "This error can occur for the following reasons:"
1429 msgstr ""
1430
1431 #. type: IP
1432 #: build/C/man2/madvise.2:268 build/C/man2/madvise.2:274
1433 #: build/C/man2/madvise.2:277 build/C/man2/madvise.2:280
1434 #: build/C/man2/madvise.2:283 build/C/man3/mallopt.3:233
1435 #: build/C/man3/mallopt.3:239
1436 #, no-wrap
1437 msgid "*"
1438 msgstr ""
1439
1440 #.  .I len
1441 #.  is zero,
1442 #. type: Plain text
1443 #: build/C/man2/madvise.2:274
1444 msgid "The value I<len> is negative."
1445 msgstr "I<len> が負の値である。"
1446
1447 #. type: Plain text
1448 #: build/C/man2/madvise.2:277
1449 msgid "I<addr> is not page-aligned."
1450 msgstr ""
1451
1452 #. type: Plain text
1453 #: build/C/man2/madvise.2:280
1454 msgid "I<advice> is not a valid value"
1455 msgstr "I<advice> が有効な値でない。"
1456
1457 #. type: Plain text
1458 #: build/C/man2/madvise.2:283
1459 msgid ""
1460 "The application is attempting to release locked or shared pages (with "
1461 "B<MADV_DONTNEED>)."
1462 msgstr ""
1463 "アプリケーションがロックされたページや共有ページを (B<MADV_DONTNEED> で) 解放\n"
1464 "しようとしている。"
1465
1466 #. type: Plain text
1467 #: build/C/man2/madvise.2:291
1468 msgid ""
1469 "B<MADV_MERGEABLE> or B<MADV_UNMERGEABLE> was specified in I<advice>, but the "
1470 "kernel was not configured with B<CONFIG_KSM>."
1471 msgstr ""
1472
1473 #. type: Plain text
1474 #: build/C/man2/madvise.2:298
1475 msgid ""
1476 "(for B<MADV_WILLNEED>)  Paging in this area would exceed the process's "
1477 "maximum resident set size."
1478 msgstr ""
1479 "(B<MADV_WILLNEED> の場合) この範囲のページングを行うと、 プロセスの RSS "
1480 "(resident set size) の最大値を越えてしまう。"
1481
1482 #. type: TP
1483 #: build/C/man2/madvise.2:298 build/C/man2/madvise.2:303
1484 #: build/C/man2/mlock.2:124 build/C/man2/mlock.2:132 build/C/man2/mlock.2:170
1485 #: build/C/man2/mmap.2:454 build/C/man2/mprotect.2:94
1486 #: build/C/man2/mprotect.2:97 build/C/man2/mremap.2:180
1487 #: build/C/man2/msync.2:93 build/C/man3/posix_memalign.3:162
1488 #: build/C/man2/shmctl.2:326 build/C/man2/shmget.2:211
1489 #: build/C/man2/shmop.2:209 build/C/man2/subpage_prot.2:82
1490 #: build/C/man2/sync_file_range.2:163
1491 #, no-wrap
1492 msgid "B<ENOMEM>"
1493 msgstr "B<ENOMEM>"
1494
1495 #. type: Plain text
1496 #: build/C/man2/madvise.2:303
1497 msgid "(for B<MADV_WILLNEED>)  Not enough memory: paging in failed."
1498 msgstr "(B<MADV_WILLNEED> の場合) メモリが足りず、ページングに失敗した。"
1499
1500 #. type: Plain text
1501 #: build/C/man2/madvise.2:307
1502 msgid ""
1503 "Addresses in the specified range are not currently mapped, or are outside "
1504 "the address space of the process."
1505 msgstr ""
1506 "指定した範囲のアドレスが、現在マップされていない。 あるいはプロセスのアドレス"
1507 "空間の内部にない。"
1508
1509 #.  FIXME . Write a posix_fadvise(3) page.
1510 #. type: Plain text
1511 #: build/C/man2/madvise.2:319
1512 msgid ""
1513 "POSIX.1b.  POSIX.1-2001 describes B<posix_madvise>(3)  with constants "
1514 "B<POSIX_MADV_NORMAL>, etc., with a behavior close to that described here.  "
1515 "There is a similar B<posix_fadvise>(2)  for file access."
1516 msgstr ""
1517 "POSIX.1b.  POSIX.1-2001 では、 B<posix_madvise>(3)  を B<POSIX_MADV_NORMAL> "
1518 "などの定数とともに記述していた (それぞれの振る舞いはここで述べたものに近"
1519 "い)。 ファイルアクセスに対しても B<posix_fadvise>(2)  という類似の関数が存在"
1520 "する。"
1521
1522 #. type: Plain text
1523 #: build/C/man2/madvise.2:328
1524 msgid ""
1525 "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>, "
1526 "B<MADV_MERGEABLE>, and B<MADV_UNMERGEABLE> are Linux-specific."
1527 msgstr ""
1528 "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>,\n"
1529 "B<MADV_MERGEABLE>, B<MADV_UNMERGEABLE> は Linux 固有である。"
1530
1531 #. type: SS
1532 #: build/C/man2/madvise.2:329 build/C/man2/mlock.2:268
1533 #: build/C/man2/shmget.2:278
1534 #, no-wrap
1535 msgid "Linux Notes"
1536 msgstr "Linux での注意"
1537
1538 #. type: Plain text
1539 #: build/C/man2/madvise.2:337
1540 msgid ""
1541 "The current Linux implementation (2.4.0) views this system call more as a "
1542 "command than as advice and hence may return an error when it cannot do what "
1543 "it usually would do in response to this advice.  (See the ERRORS description "
1544 "above.)  This is nonstandard behavior."
1545 msgstr ""
1546 "現在の Linux の実装 (2.4.0) では、 このシステムコールをアドバイスというよりは"
1547 "命令と見ている。 したがってこのアドバイスに対して通常行われる動作が不可能な場"
1548 "合は、 エラーを返すことがある (上記の エラー の記述を参照)。 この振舞いは標準"
1549 "とは異なる。"
1550
1551 #.  .SH HISTORY
1552 #.  The
1553 #.  .BR madvise ()
1554 #.  function first appeared in 4.4BSD.
1555 #. type: Plain text
1556 #: build/C/man2/madvise.2:353
1557 msgid ""
1558 "The Linux implementation requires that the address I<addr> be page-aligned, "
1559 "and allows I<length> to be zero.  If there are some parts of the specified "
1560 "address range that are not mapped, the Linux version of B<madvise>()  "
1561 "ignores them and applies the call to the rest (but returns B<ENOMEM> from "
1562 "the system call, as it should)."
1563 msgstr ""
1564 "Linux の実装では I<addr> のアドレスはページ境界の値でなければならない。また "
1565 "I<length> は 0 であっても構わない。 また Linux 版の B<madvise>()  では、指定"
1566 "されたアドレス範囲にマップされていない部分があると、 これらを無視して残りの部"
1567 "分にアドバイスを適用する (しかしシステムコールに対してはちゃんと B<ENOMEM> を"
1568 "返す)。"
1569
1570 #. type: Plain text
1571 #: build/C/man2/madvise.2:359
1572 msgid ""
1573 "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
1574 "B<munmap>(2)"
1575 msgstr ""
1576 "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
1577 "B<munmap>(2)"
1578
1579 #. type: TH
1580 #: build/C/man3/malloc_hook.3:6
1581 #, no-wrap
1582 msgid "MALLOC_HOOK"
1583 msgstr "MALLOC_HOOK"
1584
1585 #. type: TH
1586 #: build/C/man3/malloc_hook.3:6
1587 #, no-wrap
1588 msgid "2010-10-13"
1589 msgstr "2010-10-13"
1590
1591 #. type: Plain text
1592 #: build/C/man3/malloc_hook.3:11
1593 msgid ""
1594 "__malloc_hook, __malloc_initialize_hook, __memalign_hook, __free_hook, "
1595 "__realloc_hook, __after_morecore_hook - malloc debugging variables"
1596 msgstr ""
1597 "__malloc_hook, __malloc_initialize_hook, __memalign_hook, __free_hook, "
1598 "__realloc_hook, __after_morecore_hook - malloc デバッグ用の変数"
1599
1600 #. type: Plain text
1601 #: build/C/man3/malloc_hook.3:14 build/C/man3/posix_memalign.3:40
1602 #, no-wrap
1603 msgid "B<#include E<lt>malloc.hE<gt>>\n"
1604 msgstr "B<#include E<lt>malloc.hE<gt>>\n"
1605
1606 #. type: Plain text
1607 #: build/C/man3/malloc_hook.3:16
1608 #, no-wrap
1609 msgid "B<void *(*__malloc_hook)(size_t >I<size>B<, const void *>I<caller>B<);>\n"
1610 msgstr "B<void *(*__malloc_hook)(size_t >I<size>B<, const void *>I<caller>B<);>\n"
1611
1612 #. type: Plain text
1613 #: build/C/man3/malloc_hook.3:19
1614 #, no-wrap
1615 msgid "B<void *(*__realloc_hook)(void *>I<ptr>B<, size_t >I<size>B<, const void *>I<caller>B<);>\n"
1616 msgstr "B<void *(*__realloc_hook)(void *>I<ptr>B<, size_t >I<size>B<, const void *>I<caller>B<);>\n"
1617
1618 #. type: Plain text
1619 #: build/C/man3/malloc_hook.3:22
1620 #, no-wrap
1621 msgid ""
1622 "B<void *(*__memalign_hook)(size_t >I<alignment>B<, size_t >I<size>B<,>\n"
1623 "B<                         const void *>I<caller>B<);>\n"
1624 msgstr ""
1625 "B<void *(*__memalign_hook)(size_t >I<alignment>B<, size_t >I<size>B<,>\n"
1626 "B<                         const void *>I<caller>B<);>\n"
1627
1628 #. type: Plain text
1629 #: build/C/man3/malloc_hook.3:24
1630 #, no-wrap
1631 msgid "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
1632 msgstr "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
1633
1634 #. type: Plain text
1635 #: build/C/man3/malloc_hook.3:26
1636 #, no-wrap
1637 msgid "B<void (*__malloc_initialize_hook)(void);>\n"
1638 msgstr "B<void (*__malloc_initialize_hook)(void);>\n"
1639
1640 #. type: Plain text
1641 #: build/C/man3/malloc_hook.3:28
1642 #, no-wrap
1643 msgid "B<void (*__after_morecore_hook)(void);>\n"
1644 msgstr "B<void (*__after_morecore_hook)(void);>\n"
1645
1646 #. type: Plain text
1647 #: build/C/man3/malloc_hook.3:39
1648 msgid ""
1649 "The GNU C library lets you modify the behavior of B<malloc>(3), B<realloc>"
1650 "(3), and B<free>(3)  by specifying appropriate hook functions.  You can use "
1651 "these hooks to help you debug programs that use dynamic memory allocation, "
1652 "for example."
1653 msgstr ""
1654 "GNU C ライブラリでは、適切なフック関数 (hook function) を指定することで "
1655 "B<malloc>(3), B<realloc>(3), B<free>(3)  の動作を変更することができる。例え"
1656 "ば、動的にメモリ割り当てを行う プログラムのデバッグにこれらのフックを使うこと"
1657 "ができる。"
1658
1659 #. type: Plain text
1660 #: build/C/man3/malloc_hook.3:46
1661 msgid ""
1662 "The variable B<__malloc_initialize_hook> points at a function that is called "
1663 "once when the malloc implementation is initialized.  This is a weak "
1664 "variable, so it can be overridden in the application with a definition like "
1665 "the following:"
1666 msgstr ""
1667 "変数 B<__malloc_initialize_hook> は malloc の実装が初期化される際に一度だけ呼"
1668 "ばれる関数へのポインタである。 この変数は書き換え可能 (weak) であり、アプリ"
1669 "ケーション内で 以下のような定義で上書きできる:"
1670
1671 #. type: Plain text
1672 #: build/C/man3/malloc_hook.3:49
1673 #, no-wrap
1674 msgid "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
1675 msgstr "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
1676
1677 #. type: Plain text
1678 #: build/C/man3/malloc_hook.3:54
1679 msgid ""
1680 "Now the function I<my_init_hook>()  can do the initialization of all hooks."
1681 msgstr ""
1682 "なお、関数 I<my_init_hook>()  で全てのフックの初期化をすることができる。"
1683
1684 #. type: Plain text
1685 #: build/C/man3/malloc_hook.3:70
1686 msgid ""
1687 "The four functions pointed to by B<__malloc_hook>, B<__realloc_hook>, "
1688 "B<__memalign_hook>, B<__free_hook> have a prototype like the functions "
1689 "B<malloc>(3), B<realloc>(3), B<memalign>(3), B<free>(3), respectively, "
1690 "except that they have a final argument I<caller> that gives the address of "
1691 "the caller of B<malloc>(3), etc."
1692 msgstr ""
1693 "B<__malloc_hook>, B<__realloc_hook>, B<__memalign_hook>, B<__free_hook> で指"
1694 "される 4 つの関数は、各々 B<malloc>(3), B<realloc>(3), B<memalign>(3), "
1695 "B<free>(3)  とよく似たプロトタイプを持っているが、 一番最後の引き数 "
1696 "I<caller> をとる点が異なる。 引き数 I<caller> には、 B<malloc>(3)  などの呼び"
1697 "出し元 (caller) のアドレスが格納される。"
1698
1699 #. type: Plain text
1700 #: build/C/man3/malloc_hook.3:76
1701 msgid ""
1702 "The variable B<__after_morecore_hook> points at a function that is called "
1703 "each time after B<sbrk>(2)  was asked for more memory."
1704 msgstr ""
1705 "変数 B<__after_morecore_hook> は、領域の追加要求があり B<sbrk>(2)  が呼ばれた"
1706 "後で毎回呼び出される関数へのポインタである。"
1707
1708 #. type: Plain text
1709 #: build/C/man3/malloc_hook.3:78 build/C/man3/mtrace.3:78
1710 #: build/C/man3/malloc_get_state.3:86
1711 msgid "These functions are GNU extensions."
1712 msgstr "これらの関数は GNU による拡張である。"
1713
1714 #.  https://bugzilla.redhat.com/show_bug.cgi?id=450187
1715 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=9957
1716 #. type: Plain text
1717 #: build/C/man3/malloc_hook.3:85
1718 msgid ""
1719 "The use of these hook functions is not safe in multithreaded programs, and "
1720 "they are now deprecated.  Programmers should instead preempt calls to the "
1721 "relevant functions by defining and exporting functions such as \"malloc\" "
1722 "and \"free\"."
1723 msgstr ""
1724
1725 #. type: SH
1726 #: build/C/man3/malloc_hook.3:85 build/C/man3/mallopt.3:464
1727 #: build/C/man2/mmap.2:571 build/C/man2/mprotect.2:142
1728 #: build/C/man3/mtrace.3:106
1729 #, no-wrap
1730 msgid "EXAMPLE"
1731 msgstr "例"
1732
1733 #. type: Plain text
1734 #: build/C/man3/malloc_hook.3:87
1735 msgid "Here is a short example of how to use these variables."
1736 msgstr "これらの変数の使い方の簡単な例を以下に示す。"
1737
1738 #. type: Plain text
1739 #: build/C/man3/malloc_hook.3:91
1740 #, no-wrap
1741 msgid ""
1742 "#include E<lt>stdio.hE<gt>\n"
1743 "#include E<lt>malloc.hE<gt>\n"
1744 msgstr ""
1745 "#include E<lt>stdio.hE<gt>\n"
1746 "#include E<lt>malloc.hE<gt>\n"
1747
1748 #. type: Plain text
1749 #: build/C/man3/malloc_hook.3:95
1750 #, no-wrap
1751 msgid ""
1752 "/* Prototypes for our hooks.  */\n"
1753 "static void my_init_hook(void);\n"
1754 "static void *my_malloc_hook(size_t, const void *);\n"
1755 msgstr ""
1756 "/* 使おうとするフックのプロトタイプ宣言 */\n"
1757 "static void my_init_hook(void);\n"
1758 "static void *my_malloc_hook(size_t, const void *);\n"
1759
1760 #. type: Plain text
1761 #: build/C/man3/malloc_hook.3:98
1762 #, no-wrap
1763 msgid ""
1764 "/* Variables to save original hooks. */\n"
1765 "static void *(*old_malloc_hook)(size_t, const void *);\n"
1766 msgstr ""
1767 "/* 元々のフックを保存するための変数 */\n"
1768 "static void *(*old_malloc_hook)(size_t, const void *);\n"
1769
1770 #. type: Plain text
1771 #: build/C/man3/malloc_hook.3:101
1772 #, no-wrap
1773 msgid ""
1774 "/* Override initializing hook from the C library. */\n"
1775 "void (*__malloc_initialize_hook) (void) = my_init_hook;\n"
1776 msgstr ""
1777 "/* C ライブラリから呼ばれる初期化フックを上書きする */\n"
1778 "void (*__malloc_initialize_hook) (void) = my_init_hook;\n"
1779
1780 #. type: Plain text
1781 #: build/C/man3/malloc_hook.3:108
1782 #, no-wrap
1783 msgid ""
1784 "static void\n"
1785 "my_init_hook(void)\n"
1786 "{\n"
1787 "    old_malloc_hook = __malloc_hook;\n"
1788 "    __malloc_hook = my_malloc_hook;\n"
1789 "}\n"
1790 msgstr ""
1791 "static void\n"
1792 "my_init_hook(void)\n"
1793 "{\n"
1794 "    old_malloc_hook = __malloc_hook;\n"
1795 "    __malloc_hook = my_malloc_hook;\n"
1796 "}\n"
1797
1798 #. type: Plain text
1799 #: build/C/man3/malloc_hook.3:113
1800 #, no-wrap
1801 msgid ""
1802 "static void *\n"
1803 "my_malloc_hook(size_t size, const void *caller)\n"
1804 "{\n"
1805 "    void *result;\n"
1806 msgstr ""
1807 "static void *\n"
1808 "my_malloc_hook(size_t size, const void *caller)\n"
1809 "{\n"
1810 "    void *result;\n"
1811
1812 #. type: Plain text
1813 #: build/C/man3/malloc_hook.3:116
1814 #, no-wrap
1815 msgid ""
1816 "    /* Restore all old hooks */\n"
1817 "    __malloc_hook = old_malloc_hook;\n"
1818 msgstr ""
1819 "    /* 元々のフックを全て戻す */\n"
1820 "    __malloc_hook = old_malloc_hook;\n"
1821
1822 #. type: Plain text
1823 #: build/C/man3/malloc_hook.3:119
1824 #, no-wrap
1825 msgid ""
1826 "    /* Call recursively */\n"
1827 "    result = malloc(size);\n"
1828 msgstr ""
1829 "    /* malloc の再帰的呼び出し */\n"
1830 "    result = malloc(size);\n"
1831
1832 #. type: Plain text
1833 #: build/C/man3/malloc_hook.3:122
1834 #, no-wrap
1835 msgid ""
1836 "    /* Save underlying hooks */\n"
1837 "    old_malloc_hook = __malloc_hook;\n"
1838 msgstr ""
1839 "    /* 現在設定されているフック (underlying hook) を保存する */\n"
1840 "    old_malloc_hook = __malloc_hook;\n"
1841
1842 #. type: Plain text
1843 #: build/C/man3/malloc_hook.3:126
1844 #, no-wrap
1845 msgid ""
1846 "    /* printf() might call malloc(), so protect it too. */\n"
1847 "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
1848 "            (unsigned int) size, caller, result);\n"
1849 msgstr ""
1850 "    /* printf() は malloc() を呼び出す可能性があるので\n"
1851 "        ここでもガードを行う (元々のフックのままにしておく) */\n"
1852 "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
1853 "            (unsigned int) size, caller, result);\n"
1854
1855 #. type: Plain text
1856 #: build/C/man3/malloc_hook.3:129
1857 #, no-wrap
1858 msgid ""
1859 "    /* Restore our own hooks */\n"
1860 "    __malloc_hook = my_malloc_hook;\n"
1861 msgstr ""
1862 "    /* ユーザが使おうとするフックを再設定する */\n"
1863 "    __malloc_hook = my_malloc_hook;\n"
1864
1865 #. type: Plain text
1866 #: build/C/man3/malloc_hook.3:132
1867 #, no-wrap
1868 msgid ""
1869 "    return result;\n"
1870 "}\n"
1871 msgstr ""
1872 "    return result;\n"
1873 "}\n"
1874
1875 #. type: Plain text
1876 #: build/C/man3/malloc_hook.3:137
1877 msgid "B<mallinfo>(3), B<malloc>(3), B<mcheck>(3), B<mtrace>(3)"
1878 msgstr "B<mallinfo>(3), B<malloc>(3), B<mcheck>(3), B<mtrace>(3)"
1879
1880 #. type: TH
1881 #: build/C/man3/mallopt.3:24
1882 #, no-wrap
1883 msgid "MALLOPT"
1884 msgstr "MALLOPT"
1885
1886 #. type: TH
1887 #: build/C/man3/mallopt.3:24
1888 #, no-wrap
1889 msgid "2012-04-17"
1890 msgstr "2012-04-17"
1891
1892 #. type: Plain text
1893 #: build/C/man3/mallopt.3:27
1894 msgid "mallopt - set memory allocation parameters"
1895 msgstr ""
1896
1897 #. type: Plain text
1898 #: build/C/man3/mallopt.3:29 build/C/man3/malloc_trim.3:29
1899 #: build/C/man3/malloc_usable_size.3:28
1900 msgid "B<#include E<lt>malloc.hE<gt>>"
1901 msgstr "B<#include E<lt>malloc.hE<gt>>"
1902
1903 #. type: Plain text
1904 #: build/C/man3/mallopt.3:31
1905 msgid "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
1906 msgstr "B<int mallopt(int >I<param>B<, int >I<value>B<);>"
1907
1908 #. type: Plain text
1909 #: build/C/man3/mallopt.3:42
1910 msgid ""
1911 "The B<mallopt>()  function adjusts parameters that control the behavior of "
1912 "the memory-allocation functions (see B<malloc>(3)).  The I<param> argument "
1913 "specifies the parameter to be modified, and I<value> specifies the new value "
1914 "for that parameter."
1915 msgstr ""
1916
1917 #. type: Plain text
1918 #: build/C/man3/mallopt.3:45
1919 msgid "The following values can be specified for I<param>:"
1920 msgstr "I<param> には以下の値を指定することができる。"
1921
1922 #. type: TP
1923 #: build/C/man3/mallopt.3:45
1924 #, no-wrap
1925 msgid "B<M_CHECK_ACTION>"
1926 msgstr "B<M_CHECK_ACTION>"
1927
1928 #. type: Plain text
1929 #: build/C/man3/mallopt.3:51
1930 msgid ""
1931 "Setting this parameter controls how glibc responds when various kinds of "
1932 "programming errors are detected (e.g., freeing the same pointer twice).  The "
1933 "3 least significant bits (2, 1, and 0) of the value assigned to this "
1934 "parameter determine the glibc behavior, as follows:"
1935 msgstr ""
1936
1937 #. type: TP
1938 #: build/C/man3/mallopt.3:52
1939 #, no-wrap
1940 msgid "Bit 0"
1941 msgstr "Bit 0"
1942
1943 #. type: Plain text
1944 #: build/C/man3/mallopt.3:62
1945 msgid ""
1946 "If this bit is set, then print a one-line message on I<stderr> that provides "
1947 "details about the error.  The message starts with the string \"***\\ glibc "
1948 "detected\\ ***\", followed by the program name, the name of the memory-"
1949 "allocation function in which the error was detected, a brief description of "
1950 "the error, and the memory address where the error was detected."
1951 msgstr ""
1952
1953 #. type: TP
1954 #: build/C/man3/mallopt.3:62
1955 #, no-wrap
1956 msgid "Bit 1"
1957 msgstr "Bit 1"
1958
1959 #. type: Plain text
1960 #: build/C/man3/mallopt.3:77
1961 msgid ""
1962 "If this bit is set, then, after printing any error message specified by bit "
1963 "0, the program is terminated by calling B<abort>(3).  In glibc versions "
1964 "since 2.4, if bit 0 is also set, then, between printing the error message "
1965 "and aborting, the program also prints a stack trace in the manner of "
1966 "B<backtrace>(3), and prints the process's memory mapping in the style of I</"
1967 "proc/[pid]/maps> (see B<proc>(5))."
1968 msgstr ""
1969
1970 #. type: TP
1971 #: build/C/man3/mallopt.3:77
1972 #, no-wrap
1973 msgid "Bit 2 (since glibc 2.4)"
1974 msgstr "Bit 2 (glibc 2.4 以降)"
1975
1976 #. type: Plain text
1977 #: build/C/man3/mallopt.3:84
1978 msgid ""
1979 "This bit has an effect only if bit 0 is also set.  If this bit is set, then "
1980 "the one-line message describing the error is simplified to contain just the "
1981 "name of the function where the error was detected and the brief description "
1982 "of the error."
1983 msgstr ""
1984
1985 #. type: Plain text
1986 #: build/C/man3/mallopt.3:89
1987 msgid "The remaining bits in I<value> are ignored."
1988 msgstr ""
1989
1990 #. type: Plain text
1991 #: build/C/man3/mallopt.3:93
1992 msgid ""
1993 "Combining the above details, the following numeric values are meaningful for "
1994 "B<M_CHECK_ACTION>:"
1995 msgstr ""
1996
1997 #. type: IP
1998 #: build/C/man3/mallopt.3:94
1999 #, no-wrap
2000 msgid "0"
2001 msgstr ""
2002
2003 #. type: Plain text
2004 #: build/C/man3/mallopt.3:96
2005 msgid "Ignore error conditions; continue execution (with undefined results)."
2006 msgstr ""
2007
2008 #. type: IP
2009 #: build/C/man3/mallopt.3:96
2010 #, no-wrap
2011 msgid "1"
2012 msgstr "1"
2013
2014 #. type: Plain text
2015 #: build/C/man3/mallopt.3:98
2016 msgid "Print a detailed error message and continue execution."
2017 msgstr ""
2018
2019 #. type: IP
2020 #: build/C/man3/mallopt.3:98
2021 #, no-wrap
2022 msgid "2"
2023 msgstr "2"
2024
2025 #. type: Plain text
2026 #: build/C/man3/mallopt.3:100
2027 msgid "Abort the program."
2028 msgstr ""
2029
2030 #. type: IP
2031 #: build/C/man3/mallopt.3:100
2032 #, no-wrap
2033 msgid "3"
2034 msgstr ""
2035
2036 #. type: Plain text
2037 #: build/C/man3/mallopt.3:103
2038 msgid ""
2039 "Print detailed error message, stack trace, and memory mappings, and abort "
2040 "the program."
2041 msgstr ""
2042
2043 #. type: IP
2044 #: build/C/man3/mallopt.3:103
2045 #, no-wrap
2046 msgid "5"
2047 msgstr ""
2048
2049 #. type: Plain text
2050 #: build/C/man3/mallopt.3:105
2051 msgid "Print a simple error message and continue execution."
2052 msgstr ""
2053
2054 #. type: IP
2055 #: build/C/man3/mallopt.3:105
2056 #, no-wrap
2057 msgid "7"
2058 msgstr ""
2059
2060 #. type: Plain text
2061 #: build/C/man3/mallopt.3:108
2062 msgid ""
2063 "Print simple error message, stack trace, and memory mappings, and abort the "
2064 "program."
2065 msgstr ""
2066
2067 #. type: Plain text
2068 #: build/C/man3/mallopt.3:114
2069 msgid ""
2070 "Since glibc 2.3.4, the default value for the B<M_CHECK_ACTION> parameter is "
2071 "3.  In glibc version 2.3.3 and earlier, the default value is 1."
2072 msgstr ""
2073
2074 #. type: Plain text
2075 #: build/C/man3/mallopt.3:119
2076 msgid ""
2077 "Using a nonzero B<M_CHECK_ACTION> value can be useful because otherwise a "
2078 "crash may happen much later, and the true cause of the problem is then very "
2079 "hard to track down."
2080 msgstr ""
2081
2082 #. type: TP
2083 #: build/C/man3/mallopt.3:119
2084 #, no-wrap
2085 msgid "B<M_MMAP_MAX>"
2086 msgstr "B<M_MMAP_MAX>"
2087
2088 #.  The following text adapted from comments in the glibc source:
2089 #. type: Plain text
2090 #: build/C/man3/mallopt.3:129
2091 msgid ""
2092 "This parameter specifies the maximum number of allocation requests that may "
2093 "be simultaneously serviced using B<mmap>(2).  This parameter exists because "
2094 "some systems have a limited number of internal tables for use by B<mmap>(2), "
2095 "and using more than a few of them may degrade performance."
2096 msgstr ""
2097
2098 #. type: Plain text
2099 #: build/C/man3/mallopt.3:136
2100 msgid ""
2101 "The default value is 65,536, a value which has no special significance and "
2102 "which servers only as a safeguard.  Setting this parameter to 0 disables the "
2103 "use of B<mmap>(2)  for servicing large allocation requests."
2104 msgstr ""
2105
2106 #. type: TP
2107 #: build/C/man3/mallopt.3:136
2108 #, no-wrap
2109 msgid "B<M_MMAP_THRESHOLD>"
2110 msgstr "B<M_MMAP_THRESHOLD>"
2111
2112 #. type: Plain text
2113 #: build/C/man3/mallopt.3:145
2114 msgid ""
2115 "For allocations greater than or equal to the limit specified (in bytes) by "
2116 "B<M_MMAP_THRESHOLD> that can't be satisfied from the free list, the memory-"
2117 "allocation functions employ B<mmap>(2)  instead of increasing the program "
2118 "break using B<sbrk>(2)."
2119 msgstr ""
2120
2121 #. type: Plain text
2122 #: build/C/man3/mallopt.3:165
2123 msgid ""
2124 "Allocating memory using B<mmap>(2)  has the significant advantage that the "
2125 "allocated memory blocks can always be independently released back to the "
2126 "system.  (By contrast, the heap can be trimmed only if memory is freed at "
2127 "the top end.)  On the other hand, there are some disadvantages to the use of "
2128 "B<mmap>(2): deallocated space is not placed on the free list for reuse by "
2129 "later allocations; memory may be wasted because B<mmap>(2)  allocations must "
2130 "be page-aligned; and the kernel must perform the expensive task of zeroing "
2131 "out memory allocated via B<mmap>(2).  Balancing these factors leads to a "
2132 "default setting of 128*1024 for the B<M_MMAP_THRESHOLD> parameter."
2133 msgstr ""
2134
2135 #. type: Plain text
2136 #: build/C/man3/mallopt.3:172
2137 msgid ""
2138 "The lower limit for this parameter is 0.  The upper limit is "
2139 "B<DEFAULT_MMAP_THRESHOLD_MAX>: 512*1024 on 32-bit systems or "
2140 "I<4*1024*1024*sizeof(long)> on 64-bit systems."
2141 msgstr ""
2142
2143 #. type: Plain text
2144 #: build/C/man3/mallopt.3:190
2145 msgid ""
2146 "I<Note:> Nowadays, glibc uses a dynamic mmap threshold by default.  The "
2147 "initial value of the threshold is 128*1024, but when blocks larger than the "
2148 "current threshold and less than or equal to B<DEFAULT_MMAP_THRESHOLD_MAX> "
2149 "are freed, the threshold is adjusted upwards to the size of the freed "
2150 "block.  When dynamic mmap thresholding is in effect, the threshold for "
2151 "trimming the heap is also dynamically adjusted to be twice the dynamic mmap "
2152 "threshold.  Dynamic adjustment of the mmap threshold is disabled if any of "
2153 "the B<M_TRIM_THRESHOLD>, B<M_TOP_PAD>, B<M_MMAP_THRESHOLD>, or B<M_MMAP_MAX> "
2154 "parameters is set."
2155 msgstr ""
2156
2157 #. type: TP
2158 #: build/C/man3/mallopt.3:190
2159 #, no-wrap
2160 msgid "B<M_MXFAST> (since glibc 2.3)"
2161 msgstr "B<M_MXFAST> (glibc 2.3 以降)"
2162
2163 #.  The following text adapted from comments in the glibc sources:
2164 #. type: Plain text
2165 #: build/C/man3/mallopt.3:210
2166 msgid ""
2167 "Set the upper limit for memory allocation requests that are satisfied using "
2168 "\"fastbins\".  (The measurement unit for this parameter is bytes.)  Fastbins "
2169 "are storage areas that hold deallocated blocks of memory of the same size "
2170 "without merging adjacent free blocks.  Subsequent reallocation of blocks of "
2171 "the same size can be handled very quickly by allocating from the fastbin, "
2172 "although memory fragmentation and the overall memory footprint of the "
2173 "program can increase.  The default value for this parameter is I<64*sizeof"
2174 "(size_t)/4> (i.e., 64 on 32-bit architectures).  The range for this "
2175 "parameter is 0 to I<80*sizeof(size_t)/4>.  Setting B<M_MXFAST> to 0 disables "
2176 "the use of fastbins."
2177 msgstr ""
2178
2179 #. type: TP
2180 #: build/C/man3/mallopt.3:210
2181 #, no-wrap
2182 msgid "B<M_PERTURB> (since glibc 2.4)"
2183 msgstr "B<M_PERTURB> (glibc 2.4 以降)"
2184
2185 #. type: Plain text
2186 #: build/C/man3/mallopt.3:225
2187 msgid ""
2188 "If this parameter is set to a nonzero value, then bytes of allocated memory "
2189 "(other than allocations via B<calloc>(3))  are initialized to the complement "
2190 "of the value in the least significant byte of I<value>, and when allocated "
2191 "memory is released using B<free>(3), the freed bytes are set to the least "
2192 "significant byte of I<value>.  This can be useful for detecting errors where "
2193 "programs incorrectly rely on allocated memory being initialized to zero, or "
2194 "reuse values in memory that has already been freed."
2195 msgstr ""
2196
2197 #. type: TP
2198 #: build/C/man3/mallopt.3:225
2199 #, no-wrap
2200 msgid "B<M_TOP_PAD>"
2201 msgstr ""
2202
2203 #. type: Plain text
2204 #: build/C/man3/mallopt.3:232
2205 msgid ""
2206 "This parameter defines the amount of padding to employ when calling B<sbrk>"
2207 "(2)  to modify the program break.  (The measurement unit for this parameter "
2208 "is bytes.)  This parameter has an effect in the following circumstances:"
2209 msgstr ""
2210
2211 #. type: Plain text
2212 #: build/C/man3/mallopt.3:239
2213 msgid ""
2214 "When the program break is increased, then B<M_TOP_PAD> bytes are added to "
2215 "the B<sbrk>(2)  request."
2216 msgstr ""
2217
2218 #. type: Plain text
2219 #: build/C/man3/mallopt.3:245
2220 msgid ""
2221 "When the heap is trimmed as a consequence of calling B<free>(3)  (see the "
2222 "discussion of B<M_TRIM_THRESHOLD>)  this much free space is preserved at the "
2223 "top of the heap."
2224 msgstr ""
2225
2226 #. type: Plain text
2227 #: build/C/man3/mallopt.3:249
2228 msgid ""
2229 "In either case, the amount of padding is always rounded to a system page "
2230 "boundary."
2231 msgstr ""
2232
2233 #. type: Plain text
2234 #: build/C/man3/mallopt.3:256
2235 msgid ""
2236 "Modifying B<M_TOP_PAD> is a trade-off between increasing the number of "
2237 "system calls (when the parameter is set low)  and wasting unused memory at "
2238 "the top of the heap (when the parameter is set high)."
2239 msgstr ""
2240
2241 #.  DEFAULT_TOP_PAD in glibc source
2242 #. type: Plain text
2243 #: build/C/man3/mallopt.3:259
2244 msgid "The default value for this parameter is 128*1024."
2245 msgstr ""
2246
2247 #. type: TP
2248 #: build/C/man3/mallopt.3:259
2249 #, no-wrap
2250 msgid "B<M_TRIM_THRESHOLD>"
2251 msgstr ""
2252
2253 #. type: Plain text
2254 #: build/C/man3/mallopt.3:275
2255 msgid ""
2256 "When the amount of contiguous free memory at the top of the heap grows "
2257 "sufficiently large, B<free>(3)  employs B<sbrk>(2)  to release this memory "
2258 "back to the system.  (This can be useful in programs that continue to "
2259 "execute for a long period after freeing a significant amount of memory.)  "
2260 "The B<M_TRIM_THRESHOLD> parameter specifies the minimum size (in bytes) that "
2261 "this block of memory must reach before B<sbrk>(2)  is used to trim the heap."
2262 msgstr ""
2263
2264 #. type: Plain text
2265 #: build/C/man3/mallopt.3:280
2266 msgid ""
2267 "The default value for this parameter is 128*1024.  Setting "
2268 "B<M_TRIM_THRESHOLD> to -1 disables trimming completely."
2269 msgstr ""
2270
2271 #
2272 #
2273 #
2274 #.  FIXME Do the arena parameters need to be documented?
2275 #.  .TP
2276 #.  .BR M_ARENA_TEST " (since glibc 2.10)"
2277 #.  .TP
2278 #.  .BR M_ARENA_MAX " (since glibc 2.10)"
2279 #.  Environment variables
2280 #.      MALLOC_ARENA_MAX_
2281 #.      MALLOC_ARENA_TEST_
2282 #.  http://udrepper.livejournal.com/20948.html describes some details
2283 #.      of the MALLOC_ARENA_* environment variables.
2284 #.  These macros aren't enabled in production releases until 2.15?
2285 #.  (see glibc malloc/Makefile)
2286 #. type: Plain text
2287 #: build/C/man3/mallopt.3:303
2288 msgid ""
2289 "Modifying B<M_TRIM_THRESHOLD> is a trade-off between increasing the number "
2290 "of system calls (when the parameter is set low)  and wasting unused memory "
2291 "at the top of the heap (when the parameter is set high)."
2292 msgstr ""
2293
2294 #. type: SS
2295 #: build/C/man3/mallopt.3:303
2296 #, no-wrap
2297 msgid "Environment Variables"
2298 msgstr ""
2299
2300 #. type: Plain text
2301 #: build/C/man3/mallopt.3:318
2302 msgid ""
2303 "A number of environment variables can be defined to modify some of the same "
2304 "parameters as are controlled by B<mallopt>().  Using these variables has the "
2305 "advantage that the source code of the program need not be changed.  To be "
2306 "effective, these variables must be defined before the first call to a memory-"
2307 "allocation function.  (If the same parameters are adjusted via B<mallopt>()  "
2308 "then the B<mallopt>()  settings take precedence.)  For security reasons, "
2309 "these variables are ignored in set-user-ID and set-group-ID programs."
2310 msgstr ""
2311
2312 #. type: Plain text
2313 #: build/C/man3/mallopt.3:321
2314 msgid ""
2315 "The environment variables are as follows (note the trailing underscore at "
2316 "the end of the name of each variable):"
2317 msgstr ""
2318
2319 #. type: TP
2320 #: build/C/man3/mallopt.3:321
2321 #, no-wrap
2322 msgid "B<MALLOC_CHECK_>"
2323 msgstr "B<MALLOC_CHECK_>"
2324
2325 #.  On glibc 2.12/x86, a simple malloc()+free() loop is about 70% slower
2326 #.  when MALLOC_CHECK_ was set.
2327 #. type: Plain text
2328 #: build/C/man3/mallopt.3:338
2329 msgid ""
2330 "This environment variable controls the same parameter as B<mallopt>()  "
2331 "B<M_CHECK_ACTION>.  If this variable is set to a nonzero value, then a "
2332 "special implementation of the memory-allocation functions is used.  (This is "
2333 "accomplished using the B<malloc_hook>(3)  feature.)  This implementation "
2334 "performs additional error checking, but is slower than the standard set of "
2335 "memory-allocation functions.  (This implementation does not detect all "
2336 "possible errors; memory leaks can still occur.)"
2337 msgstr ""
2338
2339 #. type: Plain text
2340 #: build/C/man3/mallopt.3:343
2341 msgid ""
2342 "The value assigned to this environment variable should be a single digit, "
2343 "whose meaning is as described for B<M_CHECK_ACTION>.  Any characters beyond "
2344 "the initial digit are ignored."
2345 msgstr ""
2346
2347 #. type: Plain text
2348 #: build/C/man3/mallopt.3:352
2349 msgid ""
2350 "For security reasons, the effect of B<MALLOC_CHECK_> is disabled by default "
2351 "for set-user-ID and set-group-ID programs.  However, if the file I</etc/suid-"
2352 "debug> exists (the content of the file is irrelevant), then B<MALLOC_CHECK_> "
2353 "also has an effect for set-user-ID and set-group-ID programs."
2354 msgstr ""
2355
2356 #. type: TP
2357 #: build/C/man3/mallopt.3:352
2358 #, no-wrap
2359 msgid "B<MALLOC_MMAP_MAX_>"
2360 msgstr ""
2361
2362 #. type: Plain text
2363 #: build/C/man3/mallopt.3:357
2364 msgid "Controls the same parameter as B<mallopt>()  B<M_MMAP_MAX>."
2365 msgstr ""
2366
2367 #. type: TP
2368 #: build/C/man3/mallopt.3:357
2369 #, no-wrap
2370 msgid "B<MALLOC_MMAP_THRESHOLD_>"
2371 msgstr ""
2372
2373 #. type: Plain text
2374 #: build/C/man3/mallopt.3:362
2375 msgid "Controls the same parameter as B<mallopt>()  B<M_MMAP_THRESHOLD>."
2376 msgstr ""
2377
2378 #. type: TP
2379 #: build/C/man3/mallopt.3:362
2380 #, no-wrap
2381 msgid "B<MALLOC_PERTURB_>"
2382 msgstr ""
2383
2384 #. type: Plain text
2385 #: build/C/man3/mallopt.3:367
2386 msgid "Controls the same parameter as B<mallopt>()  B<M_PERTURB>."
2387 msgstr ""
2388
2389 #. type: TP
2390 #: build/C/man3/mallopt.3:367
2391 #, no-wrap
2392 msgid "B<MALLOC_TRIM_THRESHOLD_>"
2393 msgstr ""
2394
2395 #. type: Plain text
2396 #: build/C/man3/mallopt.3:372
2397 msgid "Controls the same parameter as B<mallopt>()  B<M_TRIM_THRESHOLD>."
2398 msgstr ""
2399
2400 #. type: TP
2401 #: build/C/man3/mallopt.3:372
2402 #, no-wrap
2403 msgid "B<MALLOC_TOP_PAD_>"
2404 msgstr "B<MALLOC_TOP_PAD_>"
2405
2406 #. type: Plain text
2407 #: build/C/man3/mallopt.3:377
2408 msgid "Controls the same parameter as B<mallopt>()  B<M_TOP_PAD>."
2409 msgstr ""
2410
2411 #. type: Plain text
2412 #: build/C/man3/mallopt.3:382
2413 msgid "On success, B<mallopt>()  returns 1.  On error, it returns 0."
2414 msgstr "B<mallopt>()  は成功すると 1 を返す。エラーの場合は 0 を返す。"
2415
2416 #.  .SH VERSIONS
2417 #.  Available already in glibc 2.0, possibly earlier
2418 #. type: Plain text
2419 #: build/C/man3/mallopt.3:390
2420 msgid "On error, I<errno> is I<not> set."
2421 msgstr "エラーの場合、I<errno> は設定I<されない>。"
2422
2423 #.  .SH NOTES
2424 #. type: Plain text
2425 #: build/C/man3/mallopt.3:404
2426 msgid ""
2427 "This function is not specified by POSIX or the C standards.  A similar "
2428 "function exists on many System V derivatives, but the range of values for "
2429 "I<param> varies across systems.  The SVID defined options B<M_MXFAST>, "
2430 "B<M_NLBLKS>, B<M_GRAIN>, and B<M_KEEP>, but only the first of these is "
2431 "implemented in glibc."
2432 msgstr ""
2433
2434 #. type: Plain text
2435 #: build/C/man3/mallopt.3:408
2436 msgid "Specifying an invalid value for I<param> does not generate an error."
2437 msgstr ""
2438
2439 #.  FIXME This looks buggy:
2440 #.  setting the M_MXFAST limit rounds up:    (s + SIZE_SZ) & ~MALLOC_ALIGN_MASK)
2441 #.  malloc requests are rounded up:
2442 #.     (req) + SIZE_SZ + MALLOC_ALIGN_MASK) & ~MALLOC_ALIGN_MASK
2443 #.  http://sources.redhat.com/bugzilla/show_bug.cgi?id=12129
2444 #. type: Plain text
2445 #: build/C/man3/mallopt.3:416
2446 msgid ""
2447 "A calculation error within the glibc implementation means that a call of the "
2448 "form:"
2449 msgstr ""
2450
2451 #. type: Plain text
2452 #: build/C/man3/mallopt.3:419
2453 #, no-wrap
2454 msgid "    mallopt(M_MXFAST, n)\n"
2455 msgstr ""
2456
2457 #.  Bins are multiples of 2 * sizeof(size_t) + sizeof(size_t)
2458 #. type: Plain text
2459 #: build/C/man3/mallopt.3:431
2460 msgid ""
2461 "does not result in fastbins being employed for all allocations of size up to "
2462 "I<n>.  To ensure desired results, I<n> should be rounded up to the next "
2463 "multiple greater than or equal to I<(2k+1)*sizeof(size_t)>, where I<k> is an "
2464 "integer."
2465 msgstr ""
2466
2467 #.  FIXME MALLOC_MMAP_THRESHOLD_ and MALLOC_MMAP_MAX_
2468 #.  do have an effect for set-user-ID programs (but not
2469 #.  set-group-ID programs).
2470 #.  http://sources.redhat.com/bugzilla/show_bug.cgi?id=12155
2471 #. type: Plain text
2472 #: build/C/man3/mallopt.3:443
2473 msgid ""
2474 "The B<MALLOC_MMAP_THRESHOLD_> and B<MALLOC_MMAP_MAX_> variables are I<not> "
2475 "ignored in set-group-ID programs."
2476 msgstr ""
2477
2478 #.  FIXME http://sources.redhat.com/bugzilla/show_bug.cgi?id=12140
2479 #. type: Plain text
2480 #: build/C/man3/mallopt.3:464
2481 msgid ""
2482 "If B<mallopt>()  is used to set B<M_PERTURB>, then, as expected, the bytes "
2483 "of allocated memory are initialized to the complement of the byte in "
2484 "I<value>, and when that memory is freed, the bytes of the region are "
2485 "initialized to the byte specified in I<value>.  However, there is an off-by-"
2486 "I<sizeof(size_t)> error in the implementation: instead of initializing "
2487 "precisely the block of memory being freed by the call I<free(p)>, the block "
2488 "starting at I<p+sizeof(size_t)> is initialized."
2489 msgstr ""
2490
2491 #. type: Plain text
2492 #: build/C/man3/mallopt.3:473
2493 msgid ""
2494 "The program below demonstrates the use of B<M_CHECK_ACTION>.  If the program "
2495 "is supplied with an (integer) command-line argument, then that argument is "
2496 "used to set the B<M_CHECK_ACTION> parameter.  The program then allocates a "
2497 "block of memory, and frees it twice (an error)."
2498 msgstr ""
2499
2500 #. type: Plain text
2501 #: build/C/man3/mallopt.3:477
2502 msgid ""
2503 "The following shell session shows what happens when we run this program "
2504 "under glibc, with the default value for B<M_CHECK_ACTION>:"
2505 msgstr ""
2506
2507 #. type: Plain text
2508 #: build/C/man3/mallopt.3:496
2509 #, no-wrap
2510 msgid ""
2511 "$ B<./a.out>\n"
2512 "*** glibc detected *** ./a.out: double free or corruption (top): 0x09d30008 ***\n"
2513 "======= Backtrace: =========\n"
2514 "/lib/libc.so.6(+0x6c501)[0x523501]\n"
2515 "/lib/libc.so.6(+0x6dd70)[0x524d70]\n"
2516 "/lib/libc.so.6(cfree+0x6d)[0x527e5d]\n"
2517 "\\&./a.out[0x80485db]\n"
2518 "/lib/libc.so.6(__libc_start_main+0xe7)[0x4cdce7]\n"
2519 "\\&./a.out[0x8048471]\n"
2520 "======= Memory map: ========\n"
2521 "001e4000-001fe000 r-xp 00000000 08:06 1083555    /lib/libgcc_s.so.1\n"
2522 "001fe000-001ff000 r--p 00019000 08:06 1083555    /lib/libgcc_s.so.1\n"
2523 "[some lines omitted]\n"
2524 "b7814000-b7817000 rw-p 00000000 00:00 0\n"
2525 "bff53000-bff74000 rw-p 00000000 00:00 0          [stack]\n"
2526 "Aborted (core dumped)\n"
2527 msgstr ""
2528
2529 #. type: Plain text
2530 #: build/C/man3/mallopt.3:501
2531 msgid ""
2532 "The following runs show the results when employing other values for "
2533 "B<M_CHECK_ACTION:>"
2534 msgstr ""
2535
2536 #. type: Plain text
2537 #: build/C/man3/mallopt.3:514
2538 #, no-wrap
2539 msgid ""
2540 "$ B<./a.out 1>             # Diagnose error and continue\n"
2541 "main(): returned from first free() call\n"
2542 "*** glibc detected *** ./a.out: double free or corruption (top): 0x09cbe008 ***\n"
2543 "main(): returned from second free() call\n"
2544 "$ B<./a.out 2>             # Abort without error message\n"
2545 "main(): returned from first free() call\n"
2546 "Aborted (core dumped)\n"
2547 "$ B<./a.out 0>             # Ignore error and continue\n"
2548 "main(): returned from first free() call\n"
2549 "main(): returned from second free() call\n"
2550 msgstr ""
2551
2552 #. type: Plain text
2553 #: build/C/man3/mallopt.3:520
2554 msgid ""
2555 "The next run shows how to set the same parameter using the B<MALLOC_CHECK_> "
2556 "environment variable:"
2557 msgstr ""
2558
2559 #. type: Plain text
2560 #: build/C/man3/mallopt.3:527
2561 #, no-wrap
2562 msgid ""
2563 "$ B<MALLOC_CHECK_=1 ./a.out>\n"
2564 "main(): returned from first free() call\n"
2565 "*** glibc detected *** ./a.out: free(): invalid pointer: 0x092c2008 ***\n"
2566 "main(): returned from second free() call\n"
2567 msgstr ""
2568
2569 #. type: SS
2570 #: build/C/man3/mallopt.3:529 build/C/man2/mprotect.2:159
2571 #, no-wrap
2572 msgid "Program source"
2573 msgstr "プログラムのソース"
2574
2575 #. type: Plain text
2576 #: build/C/man3/mallopt.3:535
2577 #, no-wrap
2578 msgid ""
2579 "#include E<lt>malloc.hE<gt>\n"
2580 "#include E<lt>stdio.hE<gt>\n"
2581 "#include E<lt>stdlib.hE<gt>\n"
2582 msgstr ""
2583 "#include E<lt>malloc.hE<gt>\n"
2584 "#include E<lt>stdio.hE<gt>\n"
2585 "#include E<lt>stdlib.hE<gt>\n"
2586
2587 #. type: Plain text
2588 #: build/C/man3/mallopt.3:540
2589 #, no-wrap
2590 msgid ""
2591 "int\n"
2592 "main(int argc, char *argv[])\n"
2593 "{\n"
2594 "    char *p;\n"
2595 msgstr ""
2596 "int\n"
2597 "main(int argc, char *argv[])\n"
2598 "{\n"
2599 "    char *p;\n"
2600
2601 #. type: Plain text
2602 #: build/C/man3/mallopt.3:547
2603 #, no-wrap
2604 msgid ""
2605 "    if (argc E<gt> 1) {\n"
2606 "        if (argc != 2) {\n"
2607 "            fprintf(stderr, \"%s E<lt>M_CHECK_ACTION-valueE<gt>\\en\", argv[0]);\n"
2608 "            exit(EXIT_FAILURE);\n"
2609 "        }\n"
2610 "    }\n"
2611 msgstr ""
2612 "    if (argc E<gt> 1) {\n"
2613 "        if (argc != 2) {\n"
2614 "            fprintf(stderr, \"%s E<lt>M_CHECK_ACTION-valueE<gt>\\en\", argv[0]);\n"
2615 "            exit(EXIT_FAILURE);\n"
2616 "        }\n"
2617 "    }\n"
2618
2619 #. type: Plain text
2620 #: build/C/man3/mallopt.3:552
2621 #, no-wrap
2622 msgid ""
2623 "    if (mallopt(M_CHECK_ACTION, atoi(argv[1])) != 1) {\n"
2624 "        fprintf(stderr, \"mallopt() failed\");\n"
2625 "        exit(EXIT_FAILURE);\n"
2626 "    }\n"
2627 msgstr ""
2628 "    if (mallopt(M_CHECK_ACTION, atoi(argv[1])) != 1) {\n"
2629 "        fprintf(stderr, \"mallopt() failed\");\n"
2630 "        exit(EXIT_FAILURE);\n"
2631 "    }\n"
2632
2633 #. type: Plain text
2634 #: build/C/man3/mallopt.3:558
2635 #, no-wrap
2636 msgid ""
2637 "    p = malloc(1000);\n"
2638 "    if (p == NULL) {\n"
2639 "        fprintf(stderr, \"malloc() failed\");\n"
2640 "        exit(EXIT_FAILURE);\n"
2641 "    }\n"
2642 msgstr ""
2643 "    p = malloc(1000);\n"
2644 "    if (p == NULL) {\n"
2645 "        fprintf(stderr, \"malloc() failed\");\n"
2646 "        exit(EXIT_FAILURE);\n"
2647 "    }\n"
2648
2649 #. type: Plain text
2650 #: build/C/man3/mallopt.3:561
2651 #, no-wrap
2652 msgid ""
2653 "    free(p);\n"
2654 "    printf(\"main(): returned from first free() call\\en\");\n"
2655 msgstr ""
2656
2657 #. type: Plain text
2658 #: build/C/man3/mallopt.3:564
2659 #, no-wrap
2660 msgid ""
2661 "    free(p);\n"
2662 "    printf(\"main(): returned from second free() call\\en\");\n"
2663 msgstr ""
2664
2665 #. type: Plain text
2666 #: build/C/man3/mallopt.3:567 build/C/man2/mmap.2:652
2667 #, no-wrap
2668 msgid ""
2669 "    exit(EXIT_SUCCESS);\n"
2670 "}\n"
2671 msgstr ""
2672 "    exit(EXIT_SUCCESS);\n"
2673 "}\n"
2674
2675 #. type: Plain text
2676 #: build/C/man3/mallopt.3:578
2677 msgid ""
2678 "B<mmap>(2)  B<sbrk>(2), B<mallinfo>(3), B<malloc>(3), B<malloc_hook>(3), "
2679 "B<malloc_trim>(3), B<mtrace>(3), B<posix_memalign>(3)"
2680 msgstr ""
2681 "B<mmap>(2) B<sbrk>(2), B<mallinfo>(3), B<malloc>(3), B<malloc_hook>(3),\n"
2682 "B<malloc_trim>(3), B<mtrace>(3), B<posix_memalign>(3)"
2683
2684 #. type: TH
2685 #: build/C/man2/mlock.2:27
2686 #, no-wrap
2687 msgid "MLOCK"
2688 msgstr "MLOCK"
2689
2690 #. type: TH
2691 #: build/C/man2/mlock.2:27
2692 #, no-wrap
2693 msgid "2011-09-14"
2694 msgstr "2011-09-14"
2695
2696 #. type: Plain text
2697 #: build/C/man2/mlock.2:30
2698 msgid "mlock, munlock, mlockall, munlockall - lock and unlock memory"
2699 msgstr "mlock - メモリのロックとロック解除を行う"
2700
2701 #. type: Plain text
2702 #: build/C/man2/mlock.2:33 build/C/man2/mmap.2:46 build/C/man2/mmap2.2:35
2703 #: build/C/man2/mprotect.2:38 build/C/man2/mremap.2:39
2704 #, no-wrap
2705 msgid "B<#include E<lt>sys/mman.hE<gt>>\n"
2706 msgstr "B<#include E<lt>sys/mman.hE<gt>>\n"
2707
2708 #. type: Plain text
2709 #: build/C/man2/mlock.2:36
2710 #, no-wrap
2711 msgid ""
2712 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
2713 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
2714 msgstr ""
2715 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
2716 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
2717
2718 #. type: Plain text
2719 #: build/C/man2/mlock.2:39
2720 #, no-wrap
2721 msgid ""
2722 "B<int mlockall(int >I<flags>B<);>\n"
2723 "B<int munlockall(void);>\n"
2724 msgstr ""
2725 "B<int mlockall(int >I<flags>B<);>\n"
2726 "B<int munlockall(void);>\n"
2727
2728 #. type: Plain text
2729 #: build/C/man2/mlock.2:55
2730 msgid ""
2731 "B<mlock>()  and B<mlockall>()  respectively lock part or all of the calling "
2732 "process's virtual address space into RAM, preventing that memory from being "
2733 "paged to the swap area.  B<munlock>()  and B<munlockall>()  perform the "
2734 "converse operation, respectively unlocking part or all of the calling "
2735 "process's virtual address space, so that pages in the specified virtual "
2736 "address range may once more to be swapped out if required by the kernel "
2737 "memory manager.  Memory locking and unlocking are performed in units of "
2738 "whole pages."
2739 msgstr ""
2740 "B<mlock>()  と B<mlockall>()  はそれぞれ、呼び出し元プロセスの仮想アドレス空"
2741 "間の一部または全部を RAM 上にロックし、メモリがスワップエリアにページングされ"
2742 "るのを防ぐ。 B<munlock>()  と B<munlockall>()  は逆の操作で、それぞれ呼び出し"
2743 "元プロセスの仮想アドレス空間の一部または全部を ロック解除する。つまり、指定さ"
2744 "れた仮想アドレス範囲のページは カーネルメモリマネージャーから要求されればス"
2745 "ワップアウトするようになる。 メモリのロックとロック解除はページ単位で行われ"
2746 "る。"
2747
2748 #. type: SS
2749 #: build/C/man2/mlock.2:55
2750 #, no-wrap
2751 msgid "mlock() and munlock()"
2752 msgstr "mlock() と munlock()"
2753
2754 #. type: Plain text
2755 #: build/C/man2/mlock.2:65
2756 msgid ""
2757 "B<mlock>()  locks pages in the address range starting at I<addr> and "
2758 "continuing for I<len> bytes.  All pages that contain a part of the specified "
2759 "address range are guaranteed to be resident in RAM when the call returns "
2760 "successfully; the pages are guaranteed to stay in RAM until later unlocked."
2761 msgstr ""
2762 "B<mlock>()  は I<addr> から始まる長さ I<len> バイトのアドレス範囲のページを"
2763 "ロックする。 呼び出しが成功した場合には、 指定されたアドレス範囲を含む全ての"
2764 "ページは RAM に残り続けることが保証される。 これらのページは後でロック解除さ"
2765 "れるまで RAM に残り続けることが保証される。"
2766
2767 #. type: Plain text
2768 #: build/C/man2/mlock.2:74
2769 msgid ""
2770 "B<munlock>()  unlocks pages in the address range starting at I<addr> and "
2771 "continuing for I<len> bytes.  After this call, all pages that contain a part "
2772 "of the specified memory range can be moved to external swap space again by "
2773 "the kernel."
2774 msgstr ""
2775 "B<munlock>()  は、 I<addr> から始まる長さ I<len> バイトのアドレス範囲のページ"
2776 "のロックを解除する。 この呼び出しを行った後は、カーネルが、指定されたメモリ範"
2777 "囲を含む 全てのページを外部のスワップ空間に移動できるようになる。"
2778
2779 #. type: SS
2780 #: build/C/man2/mlock.2:74
2781 #, no-wrap
2782 msgid "mlockall() and munlockall()"
2783 msgstr "mlockall() と munlockall()"
2784
2785 #. type: Plain text
2786 #: build/C/man2/mlock.2:84
2787 msgid ""
2788 "B<mlockall>()  locks all pages mapped into the address space of the calling "
2789 "process.  This includes the pages of the code, data and stack segment, as "
2790 "well as shared libraries, user space kernel data, shared memory, and memory-"
2791 "mapped files.  All mapped pages are guaranteed to be resident in RAM when "
2792 "the call returns successfully; the pages are guaranteed to stay in RAM until "
2793 "later unlocked."
2794 msgstr ""
2795 "B<mlockall>()  は呼び出し元プロセスのアドレス空間にマップされている全てのペー"
2796 "ジを ロックする。これにはコード、データ、スタックの 各セグメント、共有ライブ"
2797 "ラリ、カーネルのユーザー空間データ、 共有メモリ、メモリ・マップされたファイル"
2798 "が含まれる。 システム・コールが成功した場合には全てのマップされたページは "
2799 "RAM に 残ることを保証される。 これらのページは後でロック解除されるまで RAM に"
2800 "残り続けることが保証される。"
2801
2802 #. type: Plain text
2803 #: build/C/man2/mlock.2:89
2804 msgid ""
2805 "The I<flags> argument is constructed as the bitwise OR of one or more of the "
2806 "following constants:"
2807 msgstr "I<flags> 引数は以下の内容の一つまたは複数のビット OR から構成される:"
2808
2809 #. type: TP
2810 #: build/C/man2/mlock.2:89
2811 #, no-wrap
2812 msgid "B<MCL_CURRENT>"
2813 msgstr "B<MCL_CURRENT>"
2814
2815 #. type: Plain text
2816 #: build/C/man2/mlock.2:93
2817 msgid ""
2818 "Lock all pages which are currently mapped into the address space of the "
2819 "process."
2820 msgstr ""
2821 "現在、プロセスのアドレス空間にマップされている全てのページをロックする。"
2822
2823 #. type: TP
2824 #: build/C/man2/mlock.2:93
2825 #, no-wrap
2826 msgid "B<MCL_FUTURE>"
2827 msgstr "B<MCL_FUTURE>"
2828
2829 #. type: Plain text
2830 #: build/C/man2/mlock.2:100
2831 msgid ""
2832 "Lock all pages which will become mapped into the address space of the "
2833 "process in the future.  These could be for instance new pages required by a "
2834 "growing heap and stack as well as new memory mapped files or shared memory "
2835 "regions."
2836 msgstr ""
2837 "将来、プロセスのアドレス空間にマップされる全てのページをロックする。 例えば、"
2838 "ヒープ (heap) やスタックの成長により新しく必要になったページだけで なく、新し"
2839 "くメモリマップされたファイルや共有メモリ領域もロックされる。"
2840
2841 #. type: Plain text
2842 #: build/C/man2/mlock.2:113
2843 msgid ""
2844 "If B<MCL_FUTURE> has been specified, then a later system call (e.g., B<mmap>"
2845 "(2), B<sbrk>(2), B<malloc>(3)), may fail if it would cause the number of "
2846 "locked bytes to exceed the permitted maximum (see below).  In the same "
2847 "circumstances, stack growth may likewise fail: the kernel will deny stack "
2848 "expansion and deliver a B<SIGSEGV> signal to the process."
2849 msgstr ""
2850 "B<MCL_FUTURE> が指定されていると、以後のシステムコール (例えば、 B<mmap>(2), "
2851 "B<sbrk>(2), B<malloc>(3))  は、ロックするバイト数が許可された最大値 (下記参"
2852 "照) を超えた場合に 失敗する可能性がある。 同様に、スタックの成長も失敗する可"
2853 "能性がある。 その場合、カーネルはスタックの拡張を拒否し、 B<SIGSEGV> をプロセ"
2854 "スに送る。"
2855
2856 #. type: Plain text
2857 #: build/C/man2/mlock.2:117
2858 msgid ""
2859 "B<munlockall>()  unlocks all pages mapped into the address space of the "
2860 "calling process."
2861 msgstr ""
2862 "B<munlockall>()  は、呼び出し元プロセスのアドレス空間にマッピングされている "
2863 "全てのページをロック解除する。"
2864
2865 #. type: Plain text
2866 #: build/C/man2/mlock.2:123
2867 msgid ""
2868 "On success these system calls return 0.  On error, -1 is returned, I<errno> "
2869 "is set appropriately, and no changes are made to any locks in the address "
2870 "space of the process."
2871 msgstr ""
2872 "成功した場合は、これらのシステムコールはゼロを返す。 エラーの場合は -1 が返さ"
2873 "れ、 I<errno> が適切に設定され、プロセスのアドレス空間におけるロックは変更さ"
2874 "れない。"
2875
2876 #. type: Plain text
2877 #: build/C/man2/mlock.2:132
2878 msgid ""
2879 "(Linux 2.6.9 and later) the caller had a nonzero B<RLIMIT_MEMLOCK> soft "
2880 "resource limit, but tried to lock more memory than the limit permitted.  "
2881 "This limit is not enforced if the process is privileged (B<CAP_IPC_LOCK>)."
2882 msgstr ""
2883 "(Linux 2.6.9 以降) 呼び出し元は非ゼロの ソフト資源制限 B<RLIMIT_MEMLOCK> を持"
2884 "つが、制限が許可している以上のメモリをロックしようとした。 この制限は、プロセ"
2885 "スが特権 (B<CAP_IPC_LOCK>)  を持っている場合は適用されない。"
2886
2887 #.  In the case of mlock(), this check is somewhat buggy: it doesn't
2888 #.  take into account whether the to-be-locked range overlaps with
2889 #.  already locked pages.  Thus, suppose we allocate
2890 #.  (num_physpages / 4 + 1) of memory, and lock those pages once using
2891 #.  mlock(), and then lock the *same* page range a second time.
2892 #.  In the case, the second mlock() call will fail, since the check
2893 #.  calculates that the process is trying to lock (num_physpages / 2 + 2)
2894 #.  pages, which of course is not true.  (MTK, Nov 04, kernel 2.4.28)
2895 #. type: Plain text
2896 #: build/C/man2/mlock.2:144
2897 msgid ""
2898 "(Linux 2.4 and earlier) the calling process tried to lock more than half of "
2899 "RAM."
2900 msgstr ""
2901 "(Linux 2.4 以前) 呼び出し元プロセスが RAM の半分以上をロックしようとした。"
2902
2903 #. SVr4 documents an additional EAGAIN error code.
2904 #. type: Plain text
2905 #: build/C/man2/mlock.2:150
2906 msgid ""
2907 "The caller is not privileged, but needs privilege (B<CAP_IPC_LOCK>)  to "
2908 "perform the requested operation."
2909 msgstr ""
2910 "呼び出し側が特権を持っていないが、\n"
2911 "要求された操作を実行するには特権 (B<CAP_IPC_LOCK>) が必要である。"
2912
2913 #. type: Plain text
2914 #: build/C/man2/mlock.2:155
2915 msgid "For B<mlock>()  and B<munlock>():"
2916 msgstr "B<mlock>()  と B<munlock>()  用として:"
2917
2918 #. type: Plain text
2919 #: build/C/man2/mlock.2:158
2920 msgid "Some or all of the specified address range could not be locked."
2921 msgstr "指定されたアドレス範囲の一部または全てをロックすることができなかった。"
2922
2923 #. type: Plain text
2924 #: build/C/man2/mlock.2:165
2925 msgid ""
2926 "The result of the addition I<start>+I<len> was less than I<start> (e.g., the "
2927 "addition may have resulted in an overflow)."
2928 msgstr ""
2929 "I<start>+I<len> の加算の結果が I<start> よりも小さかった\n"
2930 "(例えば、加算でオーバーフローが発生したなど)。"
2931
2932 #. type: Plain text
2933 #: build/C/man2/mlock.2:170
2934 msgid "(Not on Linux)  I<addr> was not a multiple of the page size."
2935 msgstr ""
2936 "(Linux ではこの意味で使われない)  I<addr> がページサイズの倍数ではない。"
2937
2938 #. type: Plain text
2939 #: build/C/man2/mlock.2:174
2940 msgid ""
2941 "Some of the specified address range does not correspond to mapped pages in "
2942 "the address space of the process."
2943 msgstr ""
2944 "指定されたアドレス範囲がプロセスのアドレス空間にマップされたページと 一致しな"
2945 "い。"
2946
2947 #. type: Plain text
2948 #: build/C/man2/mlock.2:177
2949 msgid "For B<mlockall>():"
2950 msgstr "B<mlockall>()  用として:"
2951
2952 #. type: Plain text
2953 #: build/C/man2/mlock.2:180
2954 msgid "Unknown I<flags> were specified."
2955 msgstr "未知の I<flags> が指定された。"
2956
2957 #. type: Plain text
2958 #: build/C/man2/mlock.2:183
2959 msgid "For B<munlockall>():"
2960 msgstr "B<munlockall>()  用として:"
2961
2962 #. type: Plain text
2963 #: build/C/man2/mlock.2:187
2964 msgid ""
2965 "(Linux 2.6.8 and earlier) The caller was not privileged (B<CAP_IPC_LOCK>)."
2966 msgstr ""
2967 "(Linux 2.6.8 以前) 呼び出し元が権限 (B<CAP_IPC_LOCK>)  を持っていない。"
2968
2969 #. type: Plain text
2970 #: build/C/man2/mlock.2:189
2971 msgid "POSIX.1-2001, SVr4."
2972 msgstr "POSIX.1-2001, SVr4."
2973
2974 #. type: SH
2975 #: build/C/man2/mlock.2:189 build/C/man2/mmap.2:487 build/C/man2/msync.2:105
2976 #, no-wrap
2977 msgid "AVAILABILITY"
2978 msgstr "可用性"
2979
2980 #. type: Plain text
2981 #: build/C/man2/mlock.2:201
2982 msgid ""
2983 "On POSIX systems on which B<mlock>()  and B<munlock>()  are available, "
2984 "B<_POSIX_MEMLOCK_RANGE> is defined in I<E<lt>unistd.hE<gt>> and the number "
2985 "of bytes in a page can be determined from the constant B<PAGESIZE> (if "
2986 "defined) in I<E<lt>limits.hE<gt>> or by calling I<sysconf(_SC_PAGESIZE)>."
2987 msgstr ""
2988 "B<mlock>()  と B<munlock>()  が使用可能な POSIX システムでは "
2989 "B<_POSIX_MEMLOCK_RANGE> が I<E<lt>unistd.hE<gt>> で定義されている。 また、"
2990 "ページあたりのバイト数は、 I<E<lt>limits.hE<gt>> で定義される定数 "
2991 "B<PAGESIZE> から (定義されている場合)、もしくは I<sysconf(_SC_PAGESIZE)> を呼"
2992 "び出すことで決定できる。"
2993
2994 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
2995 #.  -1: unavailable, 0: ask using sysconf().
2996 #.  glibc defines it to 1.
2997 #. type: Plain text
2998 #: build/C/man2/mlock.2:214
2999 msgid ""
3000 "On POSIX systems on which B<mlockall>()  and B<munlockall>()  are available, "
3001 "B<_POSIX_MEMLOCK> is defined in I<E<lt>unistd.hE<gt>> to a value greater "
3002 "than 0.  (See also B<sysconf>(3).)"
3003 msgstr ""
3004 "B<mlockall>()  と B<munlockall>()  が利用可能な POSIX システムでは、 "
3005 "B<_POSIX_MEMLOCK> は I<E<lt>unistd.hE<gt>> で 0 より大きい値に定義されている "
3006 "(B<sysconf>(3)  も参照のこと)。"
3007
3008 #. type: Plain text
3009 #: build/C/man2/mlock.2:232
3010 msgid ""
3011 "Memory locking has two main applications: real-time algorithms and high-"
3012 "security data processing.  Real-time applications require deterministic "
3013 "timing, and, like scheduling, paging is one major cause of unexpected "
3014 "program execution delays.  Real-time applications will usually also switch "
3015 "to a real-time scheduler with B<sched_setscheduler>(2).  Cryptographic "
3016 "security software often handles critical bytes like passwords or secret keys "
3017 "as data structures.  As a result of paging, these secrets could be "
3018 "transferred onto a persistent swap store medium, where they might be "
3019 "accessible to the enemy long after the security software has erased the "
3020 "secrets in RAM and terminated.  (But be aware that the suspend mode on "
3021 "laptops and some desktop computers will save a copy of the system's RAM to "
3022 "disk, regardless of memory locks.)"
3023 msgstr ""
3024 "メモリのロックの用途としては主に二つある: リアルタイム アルゴリズムと高いセ"
3025 "キュリティの必要なデータ処理である。リアルタイムの アプリケーションは決定的な"
3026 "タイミングやスケジューリングを必要とするが、 ページングは予期しないプログラム"
3027 "の実行遅延をもたらす主要な要因となる。 リアルタイムのアプリケーションはたいて"
3028 "いは B<sched_setscheduler>(2)  でリアルタイムスケジューラに変更される。 暗号"
3029 "やセキュリティのソフトウェアはしばしばパスワードや秘密鍵のデータの ような重要"
3030 "なバイト列を扱う。ページングの結果、これらの秘密が スワップ用の固定媒体に転送"
3031 "されるかもしれない。そして、セキュリティ・ ソフトウェアが RAM 上の秘密を削除"
3032 "して終了したずっと後になっても、 このスワップされたデータには敵がアクセスでき"
3033 "る可能性がある (しかし、ラップトップといくつかのデスクトップコンピュータの サ"
3034 "スペンドモードはシステムの RAM の内容をメモリのロックに関わらず ディスクに保"
3035 "存することに注意)。"
3036
3037 #. type: Plain text
3038 #: build/C/man2/mlock.2:245
3039 msgid ""
3040 "Real-time processes that are using B<mlockall>()  to prevent delays on page "
3041 "faults should reserve enough locked stack pages before entering the time-"
3042 "critical section, so that no page fault can be caused by function calls.  "
3043 "This can be achieved by calling a function that allocates a sufficiently "
3044 "large automatic variable (an array) and writes to the memory occupied by "
3045 "this array in order to touch these stack pages.  This way, enough pages will "
3046 "be mapped for the stack and can be locked into RAM.  The dummy writes ensure "
3047 "that not even copy-on-write page faults can occur in the critical section."
3048 msgstr ""
3049 "リアルタイムプロセスが B<mlockall>()  を使ってページフォールトによる遅延を防"
3050 "ごうとする場合、 関数呼び出しによってページフォールトが発生しないように、 時"
3051 "間制限の厳しい部分 (time-critical section) に入る前に 十分な量のロックされた"
3052 "スタックを確保しておく必要がある。 これを実現するには、十分な大きさの自動変"
3053 "数 (の配列) を確保し、 これらのスタック用のページがメモリ上に確保されるように"
3054 "この配列に 書き込みを行う関数を用意し、これを呼び出せばよい。こうすること"
3055 "で、 十分な量のページがスタックにマッピングされ、RAM にロックされる。 ダミー"
3056 "の書き込みを行うことによって、 時間制限の厳しい部分 (critical section) 内では"
3057 "書き込み時コピーによる ページフォールトさえも発生しないことが保証される。"
3058
3059 #. type: Plain text
3060 #: build/C/man2/mlock.2:251
3061 msgid ""
3062 "Memory locks are not inherited by a child created via B<fork>(2)  and are "
3063 "automatically removed (unlocked) during an B<execve>(2)  or when the process "
3064 "terminates."
3065 msgstr ""
3066 "メモリロックは B<fork>(2)  で作成された子プロセスには継承されず、 B<execve>"
3067 "(2)  が呼ばれたり、プロセスが終了した場合は 自動的に削除される (ロック解除さ"
3068 "れる)。"
3069
3070 #. type: Plain text
3071 #: build/C/man2/mlock.2:255
3072 msgid ""
3073 "The memory lock on an address range is automatically removed if the address "
3074 "range is unmapped via B<munmap>(2)."
3075 msgstr ""
3076 "あるアドレス範囲に対するメモリロックは、そのアドレス範囲が B<munmap>(2)  に"
3077 "よってアンマップされた場合は削除される。"
3078
3079 #. type: Plain text
3080 #: build/C/man2/mlock.2:268
3081 msgid ""
3082 "Memory locks do not stack, that is, pages which have been locked several "
3083 "times by calls to B<mlock>()  or B<mlockall>()  will be unlocked by a single "
3084 "call to B<munlock>()  for the corresponding range or by B<munlockall>().  "
3085 "Pages which are mapped to several locations or by several processes stay "
3086 "locked into RAM as long as they are locked at least at one location or by at "
3087 "least one process."
3088 msgstr ""
3089 "メモリのロックは累積しない。 すなわち複数回 B<mlock>()  や B<mlockall>()  を"
3090 "呼び出してロックされたページでも、 対応する範囲に対して B<munlock>()  を 1 回"
3091 "呼び出したり B<munlockall>()  を呼び出したりするだけでロック解除される。 複数"
3092 "の場所や複数のプロセスにマップされているページは、少なくとも一つの場所、 一つ"
3093 "のプロセスでロックされている限りは RAM に残り続ける。"
3094
3095 #. type: Plain text
3096 #: build/C/man2/mlock.2:279
3097 msgid ""
3098 "Under Linux, B<mlock>()  and B<munlock>()  automatically round I<addr> down "
3099 "to the nearest page boundary.  However, POSIX.1-2001 allows an "
3100 "implementation to require that I<addr> is page aligned, so portable "
3101 "applications should ensure this."
3102 msgstr ""
3103 "Linux では、 B<mlock>()  と B<munlock>()  は自動的に I<addr> を端数切り捨てに"
3104 "より一番近いページ境界へと丸める。 しかし POSIX.1-2001 は I<addr> がページ境"
3105 "界に合っていることを要求する実装も許している。 そのため移植性を意図したアプリ"
3106 "ケーションではきちんと境界に合わせた方が良い。"
3107
3108 #. type: Plain text
3109 #: build/C/man2/mlock.2:292
3110 msgid ""
3111 "The I<VmLck> field of the Linux-specific I</proc/PID/status> file shows how "
3112 "many kilobytes of memory the process with ID I<PID> has locked using B<mlock>"
3113 "(), B<mlockall>(), and B<mmap>(2)  B<MAP_LOCKED>."
3114 msgstr ""
3115 "Linux 固有の I</proc/PID/status> ファイルの I<VmLck> フィールドには、\n"
3116 "B<mlock>(), B<mlockall>() および B<mmap>(2) B<MAP_LOCKED> を使って、\n"
3117 "ID が I<PID> のプロセスがロックしているメモリ量 (キロバイト単位) が\n"
3118 "表示される。"
3119
3120 #. type: SS
3121 #: build/C/man2/mlock.2:292
3122 #, no-wrap
3123 msgid "Limits and permissions"
3124 msgstr "制限と権限"
3125
3126 #. type: Plain text
3127 #: build/C/man2/mlock.2:299
3128 msgid ""
3129 "In Linux 2.6.8 and earlier, a process must be privileged (B<CAP_IPC_LOCK>)  "
3130 "in order to lock memory and the B<RLIMIT_MEMLOCK> soft resource limit "
3131 "defines a limit on how much memory the process may lock."
3132 msgstr ""
3133 "Linux 2.6.8 以前では、メモリをロックするためには特権 (B<CAP_IPC_LOCK>)  が必"
3134 "要で、 ソフト資源制限 B<RLIMIT_MEMLOCK> はプロセスがどれだけのメモリをロック"
3135 "できるかの制限を定義する。"
3136
3137 #. type: Plain text
3138 #: build/C/man2/mlock.2:305
3139 msgid ""
3140 "Since Linux 2.6.9, no limits are placed on the amount of memory that a "
3141 "privileged process can lock and the B<RLIMIT_MEMLOCK> soft resource limit "
3142 "instead defines a limit on how much memory an unprivileged process may lock."
3143 msgstr ""
3144 "Linux 2.6.9 以降では、特権を持つプロセスがロックできるメモリ量は無制限とな"
3145 "り、 代わりにソフト資源制限 B<RLIMIT_MEMLOCK> は特権を持たないプロセスがロッ"
3146 "クできるメモリ量の制限を定義する。"
3147
3148 #. type: Plain text
3149 #: build/C/man2/mlock.2:313
3150 msgid ""
3151 "In the 2.4 series Linux kernels up to and including 2.4.17, a bug caused the "
3152 "B<mlockall>()  B<MCL_FUTURE> flag to be inherited across a B<fork>(2).  This "
3153 "was rectified in kernel 2.4.18."
3154 msgstr ""
3155 "2.4.17 までの 2.4 シリーズの Linux カーネルには、 B<mlockall>()  "
3156 "B<MCL_FUTURE> フラグが B<fork>(2)  で継承されると言うバグがある。 これはカー"
3157 "ネル 2.4.18 で修正された。"
3158
3159 #.  See the following LKML thread:
3160 #.  http://marc.theaimsgroup.com/?l=linux-kernel&m=113801392825023&w=2
3161 #.  "Rationale for RLIMIT_MEMLOCK"
3162 #.  23 Jan 2006
3163 #. type: Plain text
3164 #: build/C/man2/mlock.2:330
3165 msgid ""
3166 "Since kernel 2.6.9, if a privileged process calls I<mlockall(MCL_FUTURE)> "
3167 "and later drops privileges (loses the B<CAP_IPC_LOCK> capability by, for "
3168 "example, setting its effective UID to a nonzero value), then subsequent "
3169 "memory allocations (e.g., B<mmap>(2), B<brk>(2))  will fail if the "
3170 "B<RLIMIT_MEMLOCK> resource limit is encountered."
3171 msgstr ""
3172 "カーネル 2.6.9 以降では、特権を持ったプロセスが I<mlockall(MCL_FUTURE)> を呼"
3173 "び出した後で、特権をなくした場合 (例えば、 実効 UID を 0 以外の値に変更するな"
3174 "どにより、 B<CAP_IPC_LOCK> ケーパビリティを失った場合)、リソース上限 "
3175 "B<RLIMIT_MEMLOCK> に達すると、それ以降のメモリ割り当て (例えば B<mmap>(2), "
3176 "B<brk>(2))  は失敗する。"
3177
3178 #. type: Plain text
3179 #: build/C/man2/mlock.2:336
3180 msgid ""
3181 "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5), "
3182 "B<capabilities>(7)"
3183 msgstr ""
3184 "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5),\n"
3185 "B<capabilities>(7)"
3186
3187 #. type: TH
3188 #: build/C/man2/mmap.2:40
3189 #, no-wrap
3190 msgid "MMAP"
3191 msgstr "MMAP"
3192
3193 #. type: TH
3194 #: build/C/man2/mmap.2:40 build/C/man2/mmap2.2:29
3195 #, no-wrap
3196 msgid "2012-04-16"
3197 msgstr "2012-04-16"
3198
3199 #. type: Plain text
3200 #: build/C/man2/mmap.2:43
3201 msgid "mmap, munmap - map or unmap files or devices into memory"
3202 msgstr "mmap, munmap - ファイルやデバイスをメモリにマップ/アンマップする"
3203
3204 #. type: Plain text
3205 #: build/C/man2/mmap.2:51
3206 #, no-wrap
3207 msgid ""
3208 "B<void *mmap(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<, int >I<flags>B<,>\n"
3209 "B<           int >I<fd>B<, off_t >I<offset>B<);>\n"
3210 "B<int munmap(void *>I<addr>B<, size_t >I<length>B<);>\n"
3211 msgstr ""
3212 "B<void *mmap(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<, int >I<flags>B<,>\n"
3213 "B<           int >I<fd>B<, off_t >I<offset>B<);>\n"
3214 "B<int munmap(void *>I<addr>B<, size_t >I<length>B<);>\n"
3215
3216 #. type: Plain text
3217 #: build/C/man2/mmap.2:61
3218 msgid ""
3219 "B<mmap>()  creates a new mapping in the virtual address space of the calling "
3220 "process.  The starting address for the new mapping is specified in I<addr>.  "
3221 "The I<length> argument specifies the length of the mapping."
3222 msgstr ""
3223 "B<mmap>()  は、新しいマッピングを呼び出し元プロセスの仮想アドレス空間に作成す"
3224 "る。 新しいマッピングの開始アドレスは I<addr> で指定される。マッピングの長さ"
3225 "は I<length> 引き数で指定される。"
3226
3227 #.  Before Linux 2.6.24, the address was rounded up to the next page
3228 #.  boundary; since 2.6.24, it is rounded down!
3229 #. type: Plain text
3230 #: build/C/man2/mmap.2:75
3231 msgid ""
3232 "If I<addr> is NULL, then the kernel chooses the address at which to create "
3233 "the mapping; this is the most portable method of creating a new mapping.  If "
3234 "I<addr> is not NULL, then the kernel takes it as a hint about where to place "
3235 "the mapping; on Linux, the mapping will be created at a nearby page "
3236 "boundary.  The address of the new mapping is returned as the result of the "
3237 "call."
3238 msgstr ""
3239 "I<addr> が NULL の場合、カーネルがマッピングを作成するアドレスを選択する。 こ"
3240 "の方法は最も移植性のある新しいマッピングの作成方法である。 I<addr> が NULL で"
3241 "ない場合、カーネルはマッピングをどこに配置するかのヒントとして I<addr> を使用"
3242 "する。Linux では、マッピングはすぐ近くのページ境界に作成される。 新しいマッピ"
3243 "ングのアドレスは、呼び出しの返り値として返される。"
3244
3245 #. type: Plain text
3246 #: build/C/man2/mmap.2:87
3247 msgid ""
3248 "The contents of a file mapping (as opposed to an anonymous mapping; see "
3249 "B<MAP_ANONYMOUS> below), are initialized using I<length> bytes starting at "
3250 "offset I<offset> in the file (or other object) referred to by the file "
3251 "descriptor I<fd>.  I<offset> must be a multiple of the page size as returned "
3252 "by I<sysconf(_SC_PAGE_SIZE)>."
3253 msgstr ""
3254 "ファイルマッピングの内容は、 ファイルディスクリプタ I<fd> で参照されるファイ"
3255 "ル (もしくは他のオブジェクト) のオフセット I<offset> から開始される "
3256 "I<length> バイトのデータで初期化される (ファイルマッピングは無名マッピングの"
3257 "反対語である。 B<MAP_ANONYMOUS> を参照)。 I<offset> は I<sysconf"
3258 "(_SC_PAGE_SIZE)> が返すページサイズの倍数でなければならない。"
3259
3260 #. type: Plain text
3261 #: build/C/man2/mmap.2:95
3262 msgid ""
3263 "The I<prot> argument describes the desired memory protection of the mapping "
3264 "(and must not conflict with the open mode of the file).  It is either "
3265 "B<PROT_NONE> or the bitwise OR of one or more of the following flags:"
3266 msgstr ""
3267 "引き数 I<prot> には、マッピングのメモリ保護をどのように行なうかを指定する "
3268 "(ファイルのオープンモードと矛盾してはいけない)。 I<prot> には、 B<PROT_NONE> "
3269 "か、以下のフラグをひとつ以上ビット毎の論理和 (OR) をとったものを 指定できる。"
3270
3271 #. type: TP
3272 #: build/C/man2/mmap.2:95 build/C/man2/mprotect.2:67
3273 #, no-wrap
3274 msgid "B<PROT_EXEC>"
3275 msgstr "B<PROT_EXEC>"
3276
3277 #. type: Plain text
3278 #: build/C/man2/mmap.2:98
3279 msgid "Pages may be executed."
3280 msgstr "ページは実行可能である。"
3281
3282 #. type: TP
3283 #: build/C/man2/mmap.2:98 build/C/man2/mprotect.2:61
3284 #, no-wrap
3285 msgid "B<PROT_READ>"
3286 msgstr "B<PROT_READ>"
3287
3288 #. type: Plain text
3289 #: build/C/man2/mmap.2:101
3290 msgid "Pages may be read."
3291 msgstr "ページは読み込み可能である。"
3292
3293 #. type: TP
3294 #: build/C/man2/mmap.2:101 build/C/man2/mprotect.2:64
3295 #, no-wrap
3296 msgid "B<PROT_WRITE>"
3297 msgstr "B<PROT_WRITE>"
3298
3299 #. type: Plain text
3300 #: build/C/man2/mmap.2:104
3301 msgid "Pages may be written."
3302 msgstr "ページに書き込み可能である。"
3303
3304 #. type: TP
3305 #: build/C/man2/mmap.2:104 build/C/man2/mprotect.2:58
3306 #, no-wrap
3307 msgid "B<PROT_NONE>"
3308 msgstr "B<PROT_NONE>"
3309
3310 #. type: Plain text
3311 #: build/C/man2/mmap.2:107
3312 msgid "Pages may not be accessed."
3313 msgstr "ページにはアクセスできない。"
3314
3315 #. type: Plain text
3316 #: build/C/man2/mmap.2:116
3317 msgid ""
3318 "The I<flags> argument determines whether updates to the mapping are visible "
3319 "to other processes mapping the same region, and whether updates are carried "
3320 "through to the underlying file.  This behavior is determined by including "
3321 "exactly one of the following values in I<flags>:"
3322 msgstr ""
3323 "I<flags> 引き数により、マッピングに対する更新が同じ領域をマッピングしている "
3324 "他のプロセスに見えるか、更新がマッピング元のファイルを通じて 伝えられるか、が"
3325 "決定される。この動作は、以下の値のいずれか一つだけ (複数は指定できない) を "
3326 "I<flags> に含めることで指定する。"
3327
3328 #. type: TP
3329 #: build/C/man2/mmap.2:116
3330 #, no-wrap
3331 msgid "B<MAP_SHARED>"
3332 msgstr "B<MAP_SHARED>"
3333
3334 #. type: Plain text
3335 #: build/C/man2/mmap.2:126
3336 msgid ""
3337 "Share this mapping.  Updates to the mapping are visible to other processes "
3338 "that map this file, and are carried through to the underlying file.  The "
3339 "file may not actually be updated until B<msync>(2)  or B<munmap>()  is "
3340 "called."
3341 msgstr ""
3342 "このマッピングを共有する。 マッピングに対する更新はこのファイルをマッピングし"
3343 "ている他のプロセス から見える。更新はマッピング元のファイルを通じて伝えられ"
3344 "る。 ただし、ファイルの実際の更新は B<msync>(2)  または B<munmap>()  が呼ばれ"
3345 "るまで行われないこともある。"
3346
3347 #. type: TP
3348 #: build/C/man2/mmap.2:126
3349 #, no-wrap
3350 msgid "B<MAP_PRIVATE>"
3351 msgstr "B<MAP_PRIVATE>"
3352
3353 #. type: Plain text
3354 #: build/C/man2/mmap.2:135
3355 msgid ""
3356 "Create a private copy-on-write mapping.  Updates to the mapping are not "
3357 "visible to other processes mapping the same file, and are not carried "
3358 "through to the underlying file.  It is unspecified whether changes made to "
3359 "the file after the B<mmap>()  call are visible in the mapped region."
3360 msgstr ""
3361 "プライベートな copy-on-write (書き込み時コピー) マップを生成する。 マッピング"
3362 "に対する更新は同じファイルをマッピングしている他のプロセス には見えず、更新が"
3363 "マッピング元のファイルを通じて伝えられることもない。 B<mmap>()  の呼び出し後"
3364 "にマッピング元のファイルに対して行われた変更が、 マップ領域に反映されるかどう"
3365 "かは規定されていない。"
3366
3367 #. type: Plain text
3368 #: build/C/man2/mmap.2:137
3369 msgid "Both of these flags are described in POSIX.1-2001."
3370 msgstr "上記の二つのフラグは POSIX.1-2001 で規定されている。"
3371
3372 #. type: Plain text
3373 #: build/C/man2/mmap.2:140
3374 msgid ""
3375 "In addition, zero or more of the following values can be ORed in I<flags>:"
3376 msgstr ""
3377 "さらに、以下の値のうち 0 個以上をビット毎の論理和 (OR) で I<flags> に指定する"
3378 "ことができる。"
3379
3380 #. type: TP
3381 #: build/C/man2/mmap.2:140
3382 #, no-wrap
3383 msgid "B<MAP_32BIT> (since Linux 2.4.20, 2.6)"
3384 msgstr "B<MAP_32BIT> (Linux 2.4.20, 2.6 以降)"
3385
3386 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
3387 #. type: Plain text
3388 #: build/C/man2/mmap.2:156
3389 msgid ""
3390 "Put the mapping into the first 2 Gigabytes of the process address space.  "
3391 "This flag is only supported on x86-64, for 64-bit programs.  It was added to "
3392 "allow thread stacks to be allocated somewhere in the first 2GB of memory, so "
3393 "as to improve context-switch performance on some early 64-bit processors.  "
3394 "Modern x86-64 processors no longer have this performance problem, so use of "
3395 "this flag is not required on those systems.  The B<MAP_32BIT> flag is "
3396 "ignored when B<MAP_FIXED> is set."
3397 msgstr ""
3398 "マッピングをプロセスのアドレス空間の先頭 2 ギガバイト以内に配置する。 このフ"
3399 "ラグがサポートされているのは x86-64 アーキテクチャ上の 64 ビットプログラムの"
3400 "みである。 このフラグが追加されたのは、スレッドのスタックをメモリの先頭 2GB "
3401 "以内の どこかに割り当てることで、初期のいくつかの 64 ビットプロセッサにおけ"
3402 "る コンテキストスイッチの性能問題を改善するためである。 最近の x86-64 プロ"
3403 "セッサではこの性能問題はもはや存在せず、 そのようなシステムではこのフラグを使"
3404 "用する必要はない。 B<MAP_FIXED> がセットされている場合は、 B<MAP_32BIT> フラ"
3405 "グは無視される。"
3406
3407 #. type: TP
3408 #: build/C/man2/mmap.2:156
3409 #, no-wrap
3410 msgid "B<MAP_ANON>"
3411 msgstr "B<MAP_ANON>"
3412
3413 #. type: Plain text
3414 #: build/C/man2/mmap.2:161
3415 msgid "Synonym for B<MAP_ANONYMOUS>.  Deprecated."
3416 msgstr "B<MAP_ANONYMOUS> の同義語。非推奨。"
3417
3418 #. type: TP
3419 #: build/C/man2/mmap.2:161
3420 #, no-wrap
3421 msgid "B<MAP_ANONYMOUS>"
3422 msgstr "B<MAP_ANONYMOUS>"
3423
3424 #. type: Plain text
3425 #: build/C/man2/mmap.2:183
3426 msgid ""
3427 "The mapping is not backed by any file; its contents are initialized to "
3428 "zero.  The I<fd> and I<offset> arguments are ignored; however, some "
3429 "implementations require I<fd> to be -1 if B<MAP_ANONYMOUS> (or B<MAP_ANON>)  "
3430 "is specified, and portable applications should ensure this.  The use of "
3431 "B<MAP_ANONYMOUS> in conjunction with B<MAP_SHARED> is only supported on "
3432 "Linux since kernel 2.4."
3433 msgstr ""
3434 "マッピングはどのファイルとも関連付けされない。 マッピングの内容は 0 で初期化"
3435 "される。 引き数 I<fd> と I<offset> は無視される。 ただし、実装によっては "
3436 "B<MAP_ANONYMOUS> (もしくは B<MAP_ANON>)  が指定された場合、 I<fd> を -1 にす"
3437 "る必要があり、 移植性が必要なアプリケーションでは必ず I<fd> を -1 にすべきで"
3438 "ある。 B<MAP_ANONYMOUS> と B<MAP_SHARED> を組み合わせての利用は カーネル 2.4 "
3439 "以降の Linux でのみサポートされている。"
3440
3441 #. type: TP
3442 #: build/C/man2/mmap.2:183
3443 #, no-wrap
3444 msgid "B<MAP_DENYWRITE>"
3445 msgstr "B<MAP_DENYWRITE>"
3446
3447 #.  Introduced in 1.1.36, removed in 1.3.24.
3448 #. type: Plain text
3449 #: build/C/man2/mmap.2:191
3450 msgid ""
3451 "This flag is ignored.  (Long ago, it signaled that attempts to write to the "
3452 "underlying file should fail with B<ETXTBUSY>.  But this was a source of "
3453 "denial-of-service attacks.)"
3454 msgstr ""
3455 "このフラグは無視される (ずっと前は、マップ元のファイルへの書き込みを行おうと"
3456 "すると、エラー B<ETXTBUSY> で失敗するようにシグナルが設定されていたが、これ"
3457 "は denial-of-service (サービス拒否) 攻撃の原因となった)。"
3458
3459 #. type: TP
3460 #: build/C/man2/mmap.2:191
3461 #, no-wrap
3462 msgid "B<MAP_EXECUTABLE>"
3463 msgstr "B<MAP_EXECUTABLE>"
3464
3465 #.  Introduced in 1.1.38, removed in 1.3.24. Flag tested in proc_follow_link.
3466 #.  (Long ago, it signaled that the underlying file is an executable.
3467 #.  However, that information was not really used anywhere.)
3468 #.  Linus talked about DOS related to MAP_EXECUTABLE, but he was thinking of
3469 #.  MAP_DENYWRITE?
3470 #. type: Plain text
3471 #: build/C/man2/mmap.2:199
3472 msgid "This flag is ignored."
3473 msgstr "このフラグは無視される。"
3474
3475 #. type: TP
3476 #: build/C/man2/mmap.2:199
3477 #, no-wrap
3478 msgid "B<MAP_FILE>"
3479 msgstr "B<MAP_FILE>"
3480
3481 #.  On some systems, this was required as the opposite of
3482 #.  MAP_ANONYMOUS -- mtk, 1 May 2007
3483 #. type: Plain text
3484 #: build/C/man2/mmap.2:205
3485 msgid "Compatibility flag.  Ignored."
3486 msgstr "互換性のためのフラグ。無視される。"
3487
3488 #. type: TP
3489 #: build/C/man2/mmap.2:205
3490 #, no-wrap
3491 msgid "B<MAP_FIXED>"
3492 msgstr "B<MAP_FIXED>"
3493
3494 #. type: Plain text
3495 #: build/C/man2/mmap.2:223
3496 msgid ""
3497 "Don't interpret I<addr> as a hint: place the mapping at exactly that "
3498 "address.  I<addr> must be a multiple of the page size.  If the memory region "
3499 "specified by I<addr> and I<len> overlaps pages of any existing mapping(s), "
3500 "then the overlapped part of the existing mapping(s) will be discarded.  If "
3501 "the specified address cannot be used, B<mmap>()  will fail.  Because "
3502 "requiring a fixed address for a mapping is less portable, the use of this "
3503 "option is discouraged."
3504 msgstr ""
3505 "I<addr> をアドレスのヒントとして使用するのではなく、 I<addr> で指定されたアド"
3506 "レスをそのまま使用してマッピングを配置する。 I<addr> はページサイズの倍数でな"
3507 "ければならない。 I<addr> と I<len> で指定されたメモリ領域が既存のマッピングの"
3508 "ページと重なる場合、 既存のマッピングの重なった部分は捨てられる。 もし指定さ"
3509 "れたアドレスが使用できない場合、 B<mmap>()  は失敗する。 マッピングに対して固"
3510 "定アドレスを要求するのは移植性の面で劣るので、 このオプションは使用しないこと"
3511 "を推奨する。"
3512
3513 #. type: TP
3514 #: build/C/man2/mmap.2:223
3515 #, no-wrap
3516 msgid "B<MAP_GROWSDOWN>"
3517 msgstr "B<MAP_GROWSDOWN>"
3518
3519 #. type: Plain text
3520 #: build/C/man2/mmap.2:228
3521 msgid ""
3522 "Used for stacks.  Indicates to the kernel virtual memory system that the "
3523 "mapping should extend downward in memory."
3524 msgstr ""
3525 "スタック用に使用される。マッピングをメモリ内で逆向きに行うことを カーネル仮想"
3526 "メモリシステムに指示する。 (訳注:マッピングは通常はメモリ・アドレスが増加す"
3527 "る向きに行うが、 このオプションを指定すると逆向きにマッピングを行う)"
3528
3529 #. type: TP
3530 #: build/C/man2/mmap.2:228
3531 #, no-wrap
3532 msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
3533 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
3534
3535 #. type: Plain text
3536 #: build/C/man2/mmap.2:234
3537 msgid ""
3538 "Allocate the mapping using \"huge pages.\" See the kernel source file "
3539 "I<Documentation/vm/hugetlbpage.txt> for further information."
3540 msgstr ""
3541 "\"huge page\" を使ってマッピングを割り当てる。 詳しい情報は、カーネル・ソース"
3542 "の I<Documentation/vm/hugetlbpage.txt> を参照。"
3543
3544 #. type: TP
3545 #: build/C/man2/mmap.2:234
3546 #, no-wrap
3547 msgid "B<MAP_LOCKED> (since Linux 2.5.37)"
3548 msgstr "B<MAP_LOCKED> (Linux 2.5.37 以降)"
3549
3550 #.  If set, the mapped pages will not be swapped out.
3551 #. type: Plain text
3552 #: build/C/man2/mmap.2:240
3553 msgid ""
3554 "Lock the pages of the mapped region into memory in the manner of B<mlock>"
3555 "(2).  This flag is ignored in older kernels."
3556 msgstr ""
3557 "マップされた領域のページを B<mlock>(2)  の方法でメモリ内にロックする。 それ以"
3558 "前のカーネルでは、このフラグは無視される。"
3559
3560 #. type: TP
3561 #: build/C/man2/mmap.2:240
3562 #, no-wrap
3563 msgid "B<MAP_NONBLOCK> (since Linux 2.5.46)"
3564 msgstr "B<MAP_NONBLOCK> (Linux 2.5.46 以降)"
3565
3566 #. type: Plain text
3567 #: build/C/man2/mmap.2:255
3568 msgid ""
3569 "Only meaningful in conjunction with B<MAP_POPULATE>.  Don't perform read-"
3570 "ahead: only create page tables entries for pages that are already present in "
3571 "RAM.  Since Linux 2.6.23, this flag causes B<MAP_POPULATE> to do nothing.  "
3572 "One day the combination of B<MAP_POPULATE> and B<MAP_NONBLOCK> may be "
3573 "reimplemented."
3574 msgstr ""
3575 "B<MAP_POPULATE> と組み合わせた場合のみ意味を持つ。 read-ahead (前もって読み込"
3576 "むこと) を実行しない。 単に、すでに RAM 上に存在するページに対して ページテー"
3577 "ブルエントリを作成するだけである。 Linux 2.6.23 以降では、このフラグは "
3578 "B<MAP_POPULATE> に何の影響も与えない。 いつか B<MAP_POPULATE> と "
3579 "B<MAP_NONBLOCK> を組み合わせた場合の動作は実装し直されるかもしれない。"
3580
3581 #. type: TP
3582 #: build/C/man2/mmap.2:255
3583 #, no-wrap
3584 msgid "B<MAP_NORESERVE>"
3585 msgstr "B<MAP_NORESERVE>"
3586
3587 #. type: Plain text
3588 #: build/C/man2/mmap.2:270
3589 msgid ""
3590 "Do not reserve swap space for this mapping.  When swap space is reserved, "
3591 "one has the guarantee that it is possible to modify the mapping.  When swap "
3592 "space is not reserved one might get B<SIGSEGV> upon a write if no physical "
3593 "memory is available.  See also the discussion of the file I</proc/sys/vm/"
3594 "overcommit_memory> in B<proc>(5).  In kernels before 2.6, this flag only had "
3595 "effect for private writable mappings."
3596 msgstr ""
3597 "このマッピングに対するスワップ空間の予約を行わない。 スワップ空間を予約した場"
3598 "合は、このマッピングの変更が必ず可能なことが 保証される。予約を行わなかった場"
3599 "合、物理メモリに空きがないと 書き込み時に B<SIGSEGV> エラーを受け取ることがあ"
3600 "る。 B<proc>(5)  の I</proc/sys/vm/overcommit_memory> ファイルについての議論"
3601 "も参照。 バージョン 2.6 より前のカーネルでは、このフラグは書き込み可能な プラ"
3602 "イベート・マッピングについてのみ効果があった。"
3603
3604 #. type: TP
3605 #: build/C/man2/mmap.2:270
3606 #, no-wrap
3607 msgid "B<MAP_POPULATE> (since Linux 2.5.46)"
3608 msgstr "B<MAP_POPULATE> (Linux 2.5.46 以降)"
3609
3610 #. type: Plain text
3611 #: build/C/man2/mmap.2:277
3612 msgid ""
3613 "Populate (prefault) page tables for a mapping.  For a file mapping, this "
3614 "causes read-ahead on the file.  Later accesses to the mapping will not be "
3615 "blocked by page faults.  B<MAP_POPULATE> is only supported for private "
3616 "mappings since Linux 2.6.23."
3617 msgstr ""
3618 "マッピング用のページテーブルを配置 (populate) する ファイルマッピングの場合に"
3619 "は、これによりファイルが先読み (read-ahead)  が行われる。この以後は、マッピン"
3620 "グに対するアクセスがページフォールトで ブロックされることがなくなる。 "
3621 "B<MAP_POPULATE> は Linux 2.6.23 以降でプライベート・マッピングについてのみ サ"
3622 "ポートされている。"
3623
3624 #. type: TP
3625 #: build/C/man2/mmap.2:277
3626 #, no-wrap
3627 msgid "B<MAP_STACK> (since Linux 2.6.27)"
3628 msgstr "B<MAP_STACK> (Linux 2.6.27 以降)"
3629
3630 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
3631 #.  commit cd98a04a59e2f94fa64d5bf1e26498d27427d5e7
3632 #.  http://thread.gmane.org/gmane.linux.kernel/720412
3633 #.  "pthread_create() slow for many threads; also time to revisit 64b
3634 #.   context switch optimization?"
3635 #. type: Plain text
3636 #: build/C/man2/mmap.2:290
3637 msgid ""
3638 "Allocate the mapping at an address suitable for a process or thread stack.  "
3639 "This flag is currently a no-op, but is used in the glibc threading "
3640 "implementation so that if some architectures require special treatment for "
3641 "stack allocations, support can later be transparently implemented for glibc."
3642 msgstr ""
3643 "プロセスやスレッドのスタックに適したアドレスにマッピングを割り当てる。 現在の"
3644 "ところ、このフラグは何もしないが、 glibc のスレッド実装では使用されている。 "
3645 "これは、いくつかのアーキテクチャではスタックの割り当てに関して特別な扱い が必"
3646 "要な場合に、glibc にそのサポートを後で透過的に実装できるようにする ためであ"
3647 "る。"
3648
3649 #. type: TP
3650 #: build/C/man2/mmap.2:290
3651 #, no-wrap
3652 msgid "B<MAP_UNINITIALIZED> (since Linux 2.6.33)"
3653 msgstr "B<MAP_UNINITIALIZED> (Linux 2.6.33 以降)"
3654
3655 #. type: Plain text
3656 #: build/C/man2/mmap.2:300
3657 msgid ""
3658 "Don't clear anonymous pages.  This flag is intended to improve performance "
3659 "on embedded devices.  This flag is only honored if the kernel was configured "
3660 "with the B<CONFIG_MMAP_ALLOW_UNINITIALIZED> option.  Because of the security "
3661 "implications, that option is normally enabled only on embedded devices (i."
3662 "e., devices where one has complete control of the contents of user memory)."
3663 msgstr ""
3664 "無名ページ (anonymous page) のクリアを行わない。このフラグは組み込みデバイス\n"
3665 "での性能向上を目的に作られてものである。カーネルの設定で\n"
3666 "B<CONFIG_MMAP_ALLOW_UNINITIALIZED> オプションが有効になっている場合のみ、\n"
3667 "このフラグは効果を持つ。\n"
3668 "セキュリティ面の考慮から、このオプションは通常組み込みデバイス (すなわち、\n"
3669 "ユーザメモリの内容を完全に制御化におけるデバイス) においてのみ有効にされる。"
3670
3671 #. type: Plain text
3672 #: build/C/man2/mmap.2:308
3673 msgid ""
3674 "Of the above flags, only B<MAP_FIXED> is specified in POSIX.1-2001.  "
3675 "However, most systems also support B<MAP_ANONYMOUS> (or its synonym "
3676 "B<MAP_ANON>)."
3677 msgstr ""
3678 "上記のフラグの中では、 B<MAP_FIXED> だけが POSIX.1-2001 で規定されている。 し"
3679 "かしながら、ほとんどのシステムで B<MAP_ANONYMOUS> (またはその同義語である "
3680 "B<MAP_ANON>)  もサポートされている。"
3681
3682 #. type: Plain text
3683 #: build/C/man2/mmap.2:315
3684 msgid ""
3685 "Some systems document the additional flags B<MAP_AUTOGROW>, "
3686 "B<MAP_AUTORESRV>, B<MAP_COPY>, and B<MAP_LOCAL>."
3687 msgstr ""
3688 "いくつかのシステムでは、上記以外にフラグとして B<MAP_AUTOGROW>, "
3689 "B<MAP_AUTORESRV>, B<MAP_COPY>, B<MAP_LOCAL> が規定されている。"
3690
3691 #. type: Plain text
3692 #: build/C/man2/mmap.2:321
3693 msgid ""
3694 "Memory mapped by B<mmap>()  is preserved across B<fork>(2), with the same "
3695 "attributes."
3696 msgstr ""
3697 "B<mmap>()  によってマップされたメモリの属性は B<fork>(2)  の際に継承される。"
3698
3699 #. type: Plain text
3700 #: build/C/man2/mmap.2:329
3701 msgid ""
3702 "A file is mapped in multiples of the page size.  For a file that is not a "
3703 "multiple of the page size, the remaining memory is zeroed when mapped, and "
3704 "writes to that region are not written out to the file.  The effect of "
3705 "changing the size of the underlying file of a mapping on the pages that "
3706 "correspond to added or removed regions of the file is unspecified."
3707 msgstr ""
3708 "ファイルはページサイズの整数倍の領域にマップされる。サイズがページサイズの 整"
3709 "数倍でないファイルの場合、マップ時に残りの領域は 0 で埋められ、この領域へ 書"
3710 "きこみを行ってもファイルに書き出されることはない。マッピングを行った元 ファイ"
3711 "ルのサイズを変更した場合、元ファイルの追加されたり削除された領域に対応 する"
3712 "マップされたページに対してどのような影響があるかは規定されていない。"
3713
3714 #. type: SS
3715 #: build/C/man2/mmap.2:329
3716 #, no-wrap
3717 msgid "munmap()"
3718 msgstr "munmap()"
3719
3720 #. type: Plain text
3721 #: build/C/man2/mmap.2:339
3722 msgid ""
3723 "The B<munmap>()  system call deletes the mappings for the specified address "
3724 "range, and causes further references to addresses within the range to "
3725 "generate invalid memory references.  The region is also automatically "
3726 "unmapped when the process is terminated.  On the other hand, closing the "
3727 "file descriptor does not unmap the region."
3728 msgstr ""
3729 "システムコール B<munmap>()  は指定されたアドレス範囲のマップを消去し、 これ以"
3730 "降のその範囲内へのメモリ参照は不正となる。 この領域は、プロセスが終了したとき"
3731 "にも自動的にアンマップされる。 一方、ファイル記述子をクローズしても、この領域"
3732 "はアンマップされない。"
3733
3734 #. type: Plain text
3735 #: build/C/man2/mmap.2:349
3736 msgid ""
3737 "The address I<addr> must be a multiple of the page size.  All pages "
3738 "containing a part of the indicated range are unmapped, and subsequent "
3739 "references to these pages will generate B<SIGSEGV>.  It is not an error if "
3740 "the indicated range does not contain any mapped pages."
3741 msgstr ""
3742 "I<addr> アドレスはページサイズの整数倍でなければならない。指定された範囲の一"
3743 "部分を 含む全てのページはアンマップされ、これ以降にこれらのページへの参照があ"
3744 "ると B<SIGSEGV> が発生する。 指定した範囲内にマップされたページが一つも含まれ"
3745 "ていない場合でも エラーにならない。"
3746
3747 #. type: SS
3748 #: build/C/man2/mmap.2:349
3749 #, no-wrap
3750 msgid "Timestamps changes for file-backed mappings"
3751 msgstr "ファイルと関連付けられたマッピングに対するタイムスタンプの更新"
3752
3753 #. type: Plain text
3754 #: build/C/man2/mmap.2:356
3755 msgid ""
3756 "For file-backed mappings, the I<st_atime> field for the mapped file may be "
3757 "updated at any time between the B<mmap>()  and the corresponding unmapping; "
3758 "the first reference to a mapped page will update the field if it has not "
3759 "been already."
3760 msgstr ""
3761 "ファイルと関連付けられたマッピングの場合、マッピングされたファイルの "
3762 "I<st_atime> フィールドは、 B<mmap>()  されてからアンマップ (unmap) されるまで"
3763 "の間に更新されることがある。 それまでに更新が行われていなければ、マップされた"
3764 "ページへの最初の参照があった 際に更新される。"
3765
3766 #. type: Plain text
3767 #: build/C/man2/mmap.2:373
3768 msgid ""
3769 "The I<st_ctime> and I<st_mtime> field for a file mapped with B<PROT_WRITE> "
3770 "and B<MAP_SHARED> will be updated after a write to the mapped region, and "
3771 "before a subsequent B<msync>(2)  with the B<MS_SYNC> or B<MS_ASYNC> flag, if "
3772 "one occurs."
3773 msgstr ""
3774 "B<PROT_WRITE> と B<MAP_SHARED> の両方を指定してマップされたファイルの場合、書"
3775 "き込みがあると、 I<st_ctime> と I<st_mtime> の両フィールドは、マップされた領"
3776 "域への書き込みより後で、 B<MS_SYNC> または B<MS_ASYNC> フラグを指定して "
3777 "B<msync>(2)  が呼ばれる前までに更新される。"
3778
3779 #. type: Plain text
3780 #: build/C/man2/mmap.2:390
3781 msgid ""
3782 "On success, B<mmap>()  returns a pointer to the mapped area.  On error, the "
3783 "value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>)  is returned, and I<errno> "
3784 "is set appropriately.  On success, B<munmap>()  returns 0, on failure -1, "
3785 "and I<errno> is set (probably to B<EINVAL>)."
3786 msgstr ""
3787 "B<mmap>()  は成功するとマップされた領域へのポインタを返す。 失敗すると値 "
3788 "B<MAP_FAILED> (つまり I<(void\\ *)\\ -1>)  を返し、 I<errno> がエラーの内容に"
3789 "したがってセットされる。 B<munmap>()  は成功すると 0 を返す。失敗すると -1 を"
3790 "返し、 I<errno> がセットされる (多くの場合 B<EINVAL> になるだろう)。"
3791
3792 #. type: TP
3793 #: build/C/man2/mmap.2:391 build/C/man2/mprotect.2:80
3794 #: build/C/man3/shm_open.3:185 build/C/man3/shm_open.3:190
3795 #: build/C/man2/shmctl.2:295 build/C/man2/shmget.2:186
3796 #: build/C/man2/shmop.2:189
3797 #, no-wrap
3798 msgid "B<EACCES>"
3799 msgstr "B<EACCES>"
3800
3801 #. type: Plain text
3802 #: build/C/man2/mmap.2:411
3803 msgid ""
3804 "A file descriptor refers to a non-regular file.  Or B<MAP_PRIVATE> was "
3805 "requested, but I<fd> is not open for reading.  Or B<MAP_SHARED> was "
3806 "requested and B<PROT_WRITE> is set, but I<fd> is not open in read/write "
3807 "(B<O_RDWR>)  mode.  Or B<PROT_WRITE> is set, but the file is append-only."
3808 msgstr ""
3809 "以下のいずれかの場合。 ファイル記述子の参照先が通常のファイルではない (non-"
3810 "regular file) 。 B<MAP_PRIVATE> を要求したが I<fd> は読み込み用にオープンされ"
3811 "ていない。 B<MAP_SHARED> を要求して B<PROT_WRITE> をセットしたが I<fd> は読み"
3812 "書きモード (B<O_RDWR>)  でオープンされていない、 B<PROT_WRITE> をセットした"
3813 "が、ファイルは追加 (append) 専用である。"
3814
3815 #. type: Plain text
3816 #: build/C/man2/mmap.2:415
3817 msgid ""
3818 "The file has been locked, or too much memory has been locked (see "
3819 "B<setrlimit>(2))."
3820 msgstr ""
3821 "ファイルがロックされている。またはロックされているメモリが多すぎる "
3822 "(B<setrlimit>(2)  を参照)。"
3823
3824 #. type: Plain text
3825 #: build/C/man2/mmap.2:421
3826 msgid ""
3827 "I<fd> is not a valid file descriptor (and B<MAP_ANONYMOUS> was not set)."
3828 msgstr ""
3829 "I<fd> が有効なファイル記述子 (file descriptor) ではない (かつ "
3830 "B<MAP_ANONYMOUS> がセットされていない)。"
3831
3832 #. type: Plain text
3833 #: build/C/man2/mmap.2:429
3834 msgid ""
3835 "We don't like I<addr>, I<length>, or I<offset> (e.g., they are too large, or "
3836 "not aligned on a page boundary)."
3837 msgstr ""
3838 "I<addr> か I<length> か I<offset> が適切でない (例えば、大きすぎるとか、ペー"
3839 "ジ境界にアラインメントされていない)。"
3840
3841 #. type: Plain text
3842 #: build/C/man2/mmap.2:434
3843 msgid "(since Linux 2.6.12)  I<length> was 0."
3844 msgstr "(Linux 2.6.12 以降)  I<length> が 0 であった。"
3845
3846 #. type: Plain text
3847 #: build/C/man2/mmap.2:442
3848 msgid ""
3849 "I<flags> contained neither B<MAP_PRIVATE> or B<MAP_SHARED>, or contained "
3850 "both of these values."
3851 msgstr ""
3852 "I<flags> に B<MAP_PRIVATE> と B<MAP_SHARED> のどちらも含まれていなかった、も"
3853 "しくは その両方が含まれていた。"
3854
3855 #. type: TP
3856 #: build/C/man2/mmap.2:442 build/C/man3/shm_open.3:227
3857 #: build/C/man2/shmget.2:202
3858 #, no-wrap
3859 msgid "B<ENFILE>"
3860 msgstr "B<ENFILE>"
3861
3862 #.  [2.6.7] shmem_zero_setup()-->shmem_file_setup()-->get_empty_filp()
3863 #. type: Plain text
3864 #: build/C/man2/mmap.2:450 build/C/man2/shmget.2:206
3865 msgid "The system limit on the total number of open files has been reached."
3866 msgstr "システム全体でオープンされているファイルの総数が上限に達した。"
3867
3868 #. type: Plain text
3869 #: build/C/man2/mmap.2:454
3870 msgid ""
3871 "The underlying file system of the specified file does not support memory "
3872 "mapping."
3873 msgstr ""
3874 "指定されたファイルが置かれているファイルシステムがメモリマッピングをサポート "
3875 "していない。"
3876
3877 #. type: Plain text
3878 #: build/C/man2/mmap.2:458
3879 msgid ""
3880 "No memory is available, or the process's maximum number of mappings would "
3881 "have been exceeded."
3882 msgstr ""
3883 "メモリに空きがない、または処理中のプロセスのマッピング数が最大数を超過した。"
3884
3885 #.  (Since 2.4.25 / 2.6.0.)
3886 #. type: Plain text
3887 #: build/C/man2/mmap.2:467
3888 msgid ""
3889 "The I<prot> argument asks for B<PROT_EXEC> but the mapped area belongs to a "
3890 "file on a file system that was mounted no-exec."
3891 msgstr ""
3892 "I<prot> 引き数は B<PROT_EXEC> を行うように指定されているが、 no-exec でマウン"
3893 "トされたファイルシステム上のファイルに マップ領域が対応している。"
3894
3895 #. type: TP
3896 #: build/C/man2/mmap.2:467
3897 #, no-wrap
3898 msgid "B<ETXTBSY>"
3899 msgstr "B<ETXTBSY>"
3900
3901 #. type: Plain text
3902 #: build/C/man2/mmap.2:473
3903 msgid ""
3904 "B<MAP_DENYWRITE> was set but the object specified by I<fd> is open for "
3905 "writing."
3906 msgstr ""
3907 "B<MAP_DENYWRITE> がセットされているが I<fd> で指定されているオブジェクトは書"
3908 "き込み用に開かれている。"
3909
3910 #. type: Plain text
3911 #: build/C/man2/mmap.2:475
3912 msgid "Use of a mapped region can result in these signals:"
3913 msgstr "マップ領域を利用する際に、以下のシグナルが発生することがある:"
3914
3915 #. type: TP
3916 #: build/C/man2/mmap.2:475
3917 #, no-wrap
3918 msgid "B<SIGSEGV>"
3919 msgstr "B<SIGSEGV>"
3920
3921 #. type: Plain text
3922 #: build/C/man2/mmap.2:478
3923 msgid "Attempted write into a region mapped as read-only."
3924 msgstr "読み込み専用で mmap された領域へ書き込みを行おうとした。"
3925
3926 #. type: TP
3927 #: build/C/man2/mmap.2:478
3928 #, no-wrap
3929 msgid "B<SIGBUS>"
3930 msgstr "B<SIGBUS>"
3931
3932 #. type: Plain text
3933 #: build/C/man2/mmap.2:483
3934 msgid ""
3935 "Attempted access to a portion of the buffer that does not correspond to the "
3936 "file (for example, beyond the end of the file, including the case where "
3937 "another process has truncated the file)."
3938 msgstr ""
3939 "バッファのうち、ファイルに関連づけられていない部分 (例えばファイル末尾を越え"
3940 "た部分など。これには 他のプロセスがファイルを切り詰めた場合なども含まれる)  "
3941 "にアクセスしようとした。"
3942
3943 #.  SVr4 documents additional error codes ENXIO and ENODEV.
3944 #.  SUSv2 documents additional error codes EMFILE and EOVERFLOW.
3945 #. type: Plain text
3946 #: build/C/man2/mmap.2:487
3947 msgid "SVr4, 4.4BSD, POSIX.1-2001."
3948 msgstr "SVr4, 4.4BSD, POSIX.1-2001."
3949
3950 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
3951 #.  -1: unavailable, 0: ask using sysconf().
3952 #.  glibc defines it to 1.
3953 #. type: Plain text
3954 #: build/C/man2/mmap.2:501
3955 msgid ""
3956 "On POSIX systems on which B<mmap>(), B<msync>(2)  and B<munmap>()  are "
3957 "available, B<_POSIX_MAPPED_FILES> is defined in I<E<lt>unistd.hE<gt>> to a "
3958 "value greater than 0.  (See also B<sysconf>(3).)"
3959 msgstr ""
3960 "B<mmap>(), B<msync>(2)  B<munmap>()  が利用可能な POSIX システムでは、 "
3961 "B<_POSIX_MAPPED_FILES> は E<lt>unistd.hE<gt> で 0 より大きな値に定義される "
3962 "(B<sysconf>(3)  も参照のこと)。"
3963
3964 #.  Since around glibc 2.1/2.2, depending on the platform.
3965 #. type: Plain text
3966 #: build/C/man2/mmap.2:516
3967 msgid ""
3968 "This page describes the interface provided by the glibc B<mmap>()  wrapper "
3969 "function.  Originally, this function invoked a system call of the same "
3970 "name.  Since kernel 2.4, that system call has been superseded by B<mmap2>"
3971 "(2), and nowadays the glibc B<mmap>()  wrapper function invokes B<mmap2>(2)  "
3972 "with a suitably adjusted value for I<offset>."
3973 msgstr ""
3974 "このページでは glibc の B<mmap>() のラッパー関数が提供するインターフェースに\n"
3975 "ついて説明している。元々は、この関数は同じ名前のシステムコールを起動していた。\n"
3976 "カーネル 2.4 以降、このシステムコールは B<mmap2>(2) に取って代わられ、現在\n"
3977 "では、 glibc の B<mmap>() のラッパー関数は I<offset> を適切に調整してから\n"
3978 "B<mmap2>(2) を起動する。"
3979
3980 #. type: Plain text
3981 #: build/C/man2/mmap.2:529
3982 msgid ""
3983 "On some hardware architectures (e.g., i386), B<PROT_WRITE> implies "
3984 "B<PROT_READ>.  It is architecture dependent whether B<PROT_READ> implies "
3985 "B<PROT_EXEC> or not.  Portable programs should always set B<PROT_EXEC> if "
3986 "they intend to execute code in the new mapping."
3987 msgstr ""
3988 "(i386 などの) いくつかのアーキテクチャでは、 B<PROT_WRITE> をセットすると、暗"
3989 "黙のうちに B<PROT_READ> がセットされる。 B<PROT_READ> をセットした際に暗黙の"
3990 "うちに B<PROT_EXEC> がセットされるかどうかは、アーキテクチャ依存である。 移植"
3991 "性を考慮したプログラムでは、 新規にマップした領域でコードを実行したい場合は、"
3992 "常に B<PROT_EXEC> をセットすべきである。"
3993
3994 #. type: Plain text
3995 #: build/C/man2/mmap.2:544
3996 msgid ""
3997 "The portable way to create a mapping is to specify I<addr> as 0 (NULL), and "
3998 "omit B<MAP_FIXED> from I<flags>.  In this case, the system chooses the "
3999 "address for the mapping; the address is chosen so as not to conflict with "
4000 "any existing mapping, and will not be 0.  If the B<MAP_FIXED> flag is "
4001 "specified, and I<addr> is 0 (NULL), then the mapped address will be 0 (NULL)."
4002 msgstr ""
4003 "マッピングを作成する移植性のある方法は、 I<addr> に 0 (NULL) を指定し、 "
4004 "I<flags> から B<MAP_FIXED> を外すことである。 この場合、システムがマッピング"
4005 "用のアドレスの選択を行う。 アドレスは既存のマッピングと衝突しないように、 か"
4006 "つ 0 にならないように選択される。 B<MAP_FIXED> フラグが指定され、かつ "
4007 "I<addr> が 0 (NULL)  の場合には、マップされるアドレスが 0 (NULL) になる。"
4008
4009 #. type: Plain text
4010 #: build/C/man2/mmap.2:549
4011 msgid ""
4012 "On Linux there are no guarantees like those suggested above under "
4013 "B<MAP_NORESERVE>.  By default, any process can be killed at any moment when "
4014 "the system runs out of memory."
4015 msgstr ""
4016 "Linux においては、上記の B<MAP_NORESERVE> で述べられているような保証はない。 "
4017 "デフォルトでは、システムがメモリを使い切った場合には、 どのプロセスがいつ強制"
4018 "終了されるか分からないからである。"
4019
4020 #. type: Plain text
4021 #: build/C/man2/mmap.2:556
4022 msgid ""
4023 "In kernels before 2.6.7, the B<MAP_POPULATE> flag only has effect if I<prot> "
4024 "is specified as B<PROT_NONE>."
4025 msgstr ""
4026 "2.6.7 より前のカーネルでは、 I<prot> に B<PROT_NONE> が指定された場合にの"
4027 "み、 B<MAP_POPULATE> フラグが効力を持つ。"
4028
4029 #. type: Plain text
4030 #: build/C/man2/mmap.2:571
4031 msgid ""
4032 "SUSv3 specifies that B<mmap>()  should fail if I<length> is 0.  However, in "
4033 "kernels before 2.6.12, B<mmap>()  succeeded in this case: no mapping was "
4034 "created and the call returned I<addr>.  Since kernel 2.6.12, B<mmap>()  "
4035 "fails with the error B<EINVAL> for this case."
4036 msgstr ""
4037 "SUSv3 では、 I<length> が 0 の場合、 B<mmap>()  は失敗すると規定されている。"
4038 "しかしながら、2.6.12 より前のカーネルでは、 この場合に B<mmap>()  は成功して"
4039 "いた (マッピングは作成されず、 I<addr> が返されていた)。 カーネル 2.6.12 以降"
4040 "では、 B<mmap>()  はエラー B<EINVAL> で失敗する。"
4041
4042 #. type: Plain text
4043 #: build/C/man2/mmap.2:583
4044 msgid ""
4045 "The following program prints part of the file specified in its first command-"
4046 "line argument to standard output.  The range of bytes to be printed is "
4047 "specified via offset and length values in the second and third command-line "
4048 "arguments.  The program creates a memory mapping of the required pages of "
4049 "the file and then uses B<write>(2)  to output the desired bytes."
4050 msgstr ""
4051 "以下のプログラムは、一番目のコマンドライン引き数で指定された ファイルの一部を"
4052 "標準出力に表示する。 表示する範囲は、二番目、三番目のコマンドライン引き数で渡"
4053 "される オフセットと長さで指定される。 このプログラムは、指定されたファイルの"
4054 "必要なページのメモリ・ マッピングを作成し、 B<write>(2)  を使って所望のバイト"
4055 "を出力する。"
4056
4057 #. type: Plain text
4058 #: build/C/man2/mmap.2:591
4059 #, no-wrap
4060 msgid ""
4061 "#include E<lt>sys/mman.hE<gt>\n"
4062 "#include E<lt>sys/stat.hE<gt>\n"
4063 "#include E<lt>fcntl.hE<gt>\n"
4064 "#include E<lt>stdio.hE<gt>\n"
4065 "#include E<lt>stdlib.hE<gt>\n"
4066 "#include E<lt>unistd.hE<gt>\n"
4067 msgstr ""
4068 "#include E<lt>sys/mman.hE<gt>\n"
4069 "#include E<lt>sys/stat.hE<gt>\n"
4070 "#include E<lt>fcntl.hE<gt>\n"
4071 "#include E<lt>stdio.hE<gt>\n"
4072 "#include E<lt>stdlib.hE<gt>\n"
4073 "#include E<lt>unistd.hE<gt>\n"
4074
4075 #. type: Plain text
4076 #: build/C/man2/mmap.2:594 build/C/man2/mprotect.2:172
4077 #, no-wrap
4078 msgid ""
4079 "#define handle_error(msg) \\e\n"
4080 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
4081 msgstr ""
4082 "#define handle_error(msg) \\e\n"
4083 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
4084
4085 #. type: Plain text
4086 #: build/C/man2/mmap.2:604
4087 #, no-wrap
4088 msgid ""
4089 "int\n"
4090 "main(int argc, char *argv[])\n"
4091 "{\n"
4092 "    char *addr;\n"
4093 "    int fd;\n"
4094 "    struct stat sb;\n"
4095 "    off_t offset, pa_offset;\n"
4096 "    size_t length;\n"
4097 "    ssize_t s;\n"
4098 msgstr ""
4099 "int\n"
4100 "main(int argc, char *argv[])\n"
4101 "{\n"
4102 "    char *addr;\n"
4103 "    int fd;\n"
4104 "    struct stat sb;\n"
4105 "    off_t offset, pa_offset;\n"
4106 "    size_t length;\n"
4107 "    ssize_t s;\n"
4108
4109 #. type: Plain text
4110 #: build/C/man2/mmap.2:609
4111 #, no-wrap
4112 msgid ""
4113 "    if (argc E<lt> 3 || argc E<gt> 4) {\n"
4114 "        fprintf(stderr, \"%s file offset [length]\\en\", argv[0]);\n"
4115 "        exit(EXIT_FAILURE);\n"
4116 "    }\n"
4117 msgstr ""
4118 "    if (argc E<lt> 3 || argc E<gt> 4) {\n"
4119 "        fprintf(stderr, \"%s file offset [length]\\en\", argv[0]);\n"
4120 "        exit(EXIT_FAILURE);\n"
4121 "    }\n"
4122
4123 #. type: Plain text
4124 #: build/C/man2/mmap.2:613
4125 #, no-wrap
4126 msgid ""
4127 "    fd = open(argv[1], O_RDONLY);\n"
4128 "    if (fd == -1)\n"
4129 "        handle_error(\"open\");\n"
4130 msgstr ""
4131 "    fd = open(argv[1], O_RDONLY);\n"
4132 "    if (fd == -1)\n"
4133 "        handle_error(\"open\");\n"
4134
4135 #. type: Plain text
4136 #: build/C/man2/mmap.2:616
4137 #, no-wrap
4138 msgid ""
4139 "    if (fstat(fd, &sb) == -1)           /* To obtain file size */\n"
4140 "        handle_error(\"fstat\");\n"
4141 msgstr ""
4142 "    if (fstat(fd, &sb) == -1)           /* To obtain file size */\n"
4143 "        handle_error(\"fstat\");\n"
4144
4145 #. type: Plain text
4146 #: build/C/man2/mmap.2:620
4147 #, no-wrap
4148 msgid ""
4149 "    offset = atoi(argv[2]);\n"
4150 "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
4151 "        /* offset for mmap() must be page aligned */\n"
4152 msgstr ""
4153 "    offset = atoi(argv[2]);\n"
4154 "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
4155 "        /* offset for mmap() must be page aligned */\n"
4156
4157 #. type: Plain text
4158 #: build/C/man2/mmap.2:625
4159 #, no-wrap
4160 msgid ""
4161 "    if (offset E<gt>= sb.st_size) {\n"
4162 "        fprintf(stderr, \"offset is past end of file\\en\");\n"
4163 "        exit(EXIT_FAILURE);\n"
4164 "    }\n"
4165 msgstr ""
4166 "    if (offset E<gt>= sb.st_size) {\n"
4167 "        fprintf(stderr, \"offset is past end of file\\en\");\n"
4168 "        exit(EXIT_FAILURE);\n"
4169 "    }\n"
4170
4171 #. type: Plain text
4172 #: build/C/man2/mmap.2:631
4173 #, no-wrap
4174 msgid ""
4175 "    if (argc == 4) {\n"
4176 "        length = atoi(argv[3]);\n"
4177 "        if (offset + length E<gt> sb.st_size)\n"
4178 "            length = sb.st_size - offset;\n"
4179 "                /* Can\\(aqt display bytes past end of file */\n"
4180 msgstr ""
4181 "    if (argc == 4) {\n"
4182 "        length = atoi(argv[3]);\n"
4183 "        if (offset + length E<gt> sb.st_size)\n"
4184 "            length = sb.st_size - offset;\n"
4185 "                /* Can\\(aqt display bytes past end of file */\n"
4186
4187 #. type: Plain text
4188 #: build/C/man2/mmap.2:635
4189 #, no-wrap
4190 msgid ""
4191 "    } else {    /* No length arg ==E<gt> display to end of file */\n"
4192 "        length = sb.st_size - offset;\n"
4193 "    }\n"
4194 msgstr ""
4195 "    } else {    /* No length arg ==E<gt> display to end of file */\n"
4196 "        length = sb.st_size - offset;\n"
4197 "    }\n"
4198
4199 #. type: Plain text
4200 #: build/C/man2/mmap.2:640
4201 #, no-wrap
4202 msgid ""
4203 "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
4204 "                MAP_PRIVATE, fd, pa_offset);\n"
4205 "    if (addr == MAP_FAILED)\n"
4206 "        handle_error(\"mmap\");\n"
4207 msgstr ""
4208 "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
4209 "                MAP_PRIVATE, fd, pa_offset);\n"
4210 "    if (addr == MAP_FAILED)\n"
4211 "        handle_error(\"mmap\");\n"
4212
4213 #. type: Plain text
4214 #: build/C/man2/mmap.2:645
4215 #, no-wrap
4216 msgid ""
4217 "    s = write(STDOUT_FILENO, addr + offset - pa_offset, length);\n"
4218 "    if (s != length) {\n"
4219 "        if (s == -1)\n"
4220 "            handle_error(\"write\");\n"
4221 msgstr ""
4222 "    s = write(STDOUT_FILENO, addr + offset - pa_offset, length);\n"
4223 "    if (s != length) {\n"
4224 "        if (s == -1)\n"
4225 "            handle_error(\"write\");\n"
4226
4227 #. type: Plain text
4228 #: build/C/man2/mmap.2:649
4229 #, no-wrap
4230 msgid ""
4231 "        fprintf(stderr, \"partial write\");\n"
4232 "        exit(EXIT_FAILURE);\n"
4233 "    }\n"
4234 msgstr ""
4235 "        fprintf(stderr, \"partial write\");\n"
4236 "        exit(EXIT_FAILURE);\n"
4237 "    }\n"
4238
4239 #. type: Plain text
4240 #: build/C/man2/mmap.2:666
4241 msgid ""
4242 "B<getpagesize>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), "
4243 "B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>"
4244 "(2), B<shm_open>(3), B<shm_overview>(7)"
4245 msgstr ""
4246 "B<getpagesize>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), "
4247 "B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>"
4248 "(2), B<shm_open>(3), B<shm_overview>(7)"
4249
4250 #. type: Plain text
4251 #: build/C/man2/mmap.2:667 build/C/man2/msync.2:121
4252 msgid "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
4253 msgstr "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
4254
4255 #. type: TH
4256 #: build/C/man2/mmap2.2:29
4257 #, no-wrap
4258 msgid "MMAP2"
4259 msgstr "MMAP2"
4260
4261 #. type: Plain text
4262 #: build/C/man2/mmap2.2:32
4263 msgid "mmap2 - map files or devices into memory"
4264 msgstr "mmap2 - ファイルやデバイスをメモリにマップする"
4265
4266 #. type: Plain text
4267 #: build/C/man2/mmap2.2:38
4268 #, no-wrap
4269 msgid ""
4270 "B<void *mmap2(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<,>\n"
4271 "B<             int >I<flags>B<, int >I<fd>B<, off_t >I<pgoffset>B<);>\n"
4272 msgstr ""
4273 "B<void *mmap2(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<,>\n"
4274 "B<            int >I<flags>B<, int >I<fd>B<, off_t >I<pgoffset>B<);>\n"
4275
4276 #. type: Plain text
4277 #: build/C/man2/mmap2.2:43
4278 msgid ""
4279 "This is probably not the system call you are interested; instead, see B<mmap>"
4280 "(2), which describes the glibc wrapper function that invokes this system "
4281 "call."
4282 msgstr ""
4283 "これはおそらくあなたが興味のあるシステムコールではないだろう。代わりに\n"
4284 "B<mmap>(2) を見るとよい。そのページにはこのシステムコールを起動する glibc の\n"
4285 "ラッパー関数についての説明がある。"
4286
4287 #. type: Plain text
4288 #: build/C/man2/mmap2.2:54
4289 msgid ""
4290 "The B<mmap2>()  system call provides the same interface as B<mmap>(2), "
4291 "except that the final argument specifies the offset into the file in 4096-"
4292 "byte units (instead of bytes, as is done by B<mmap>(2)).  This enables "
4293 "applications that use a 32-bit I<off_t> to map large files (up to 2^44 "
4294 "bytes)."
4295 msgstr ""
4296 "B<mmap2>() システムコールは B<mmap>(2) と同じインターフェースを提供する。ただ\n"
4297 "し、最後の引き数には、ファイルのオフセットを (B<mmap>(2) が行っている、バイト\n"
4298 "単位ではなく) 4096 バイトを単位として指定する。 これにより、32 ビットの\n"
4299 "I<off_t> を使うアプリケーションで (2^44 バイトまでの) 大きなファイルをマップ\n"
4300 "できるようになる。"
4301
4302 #. type: Plain text
4303 #: build/C/man2/mmap2.2:61
4304 msgid ""
4305 "On success, B<mmap2>()  returns a pointer to the mapped area.  On error -1 "
4306 "is returned and I<errno> is set appropriately."
4307 msgstr ""
4308 "成功した場合、 B<mmap2>()  はマップされた領域へのポインタを返す。 エラーの場"
4309 "合は -1 が返されて、 I<errno> が適切に設定される。"
4310
4311 #. type: Plain text
4312 #: build/C/man2/mmap2.2:65
4313 msgid "Problem with getting the data from userspace."
4314 msgstr "ユーザ空間からデータを取得するときに問題があった。"
4315
4316 #. type: Plain text
4317 #: build/C/man2/mmap2.2:70
4318 msgid ""
4319 "(Various platforms where the page size is not 4096 bytes.)  I<offset * 4096> "
4320 "is not a multiple of the system page size."
4321 msgstr ""
4322 "(ページサイズが 4096 バイトでないプラットフォームにおいて)  I<offset * 4096> "
4323 "がシステムのページサイズの倍数ではない。"
4324
4325 #. type: Plain text
4326 #: build/C/man2/mmap2.2:74
4327 msgid "B<mmap2>()  can also return any of the errors described in B<mmap>(2)."
4328 msgstr "B<mmap2>() は B<mmap>(2) に載っているエラーを返すこともある。"
4329
4330 #. type: Plain text
4331 #: build/C/man2/mmap2.2:77
4332 msgid "B<mmap2>()  is available since Linux 2.3.31."
4333 msgstr "B<mmap2>()  は、Linux 2.3.31 以降で使用可能である。"
4334
4335 #. type: Plain text
4336 #: build/C/man2/mmap2.2:79 build/C/man2/subpage_prot.2:93
4337 msgid "This system call is Linux-specific."
4338 msgstr "このシステムコールは Linux 独自である。"
4339
4340 #. type: Plain text
4341 #: build/C/man2/mmap2.2:85
4342 msgid ""
4343 "Nowadays, the glibc B<mmap>()  wrapper function invokes this system call "
4344 "rather than the B<mmap>(2)  system call."
4345 msgstr ""
4346 "現在では、glibc の B<mmap>()  のラッパー関数は、 B<mmap>(2)  システムコールで"
4347 "はなく、このシステムコール (B<mmap2>(2))  を起動する。"
4348
4349 #.  ia64 can have page sizes ranging from 4kB to 64kB.
4350 #.  On cris, it looks like the unit might also be the page size,
4351 #.  which is 8192 bytes. -- mtk, June 2007
4352 #. type: Plain text
4353 #: build/C/man2/mmap2.2:92
4354 msgid ""
4355 "On ia64, the unit for I<offset> is actually the system page size, rather "
4356 "than 4096 bytes."
4357 msgstr ""
4358 "ia64 では、 I<offset> の単位は、実際にはシステムのページサイズであり、 4096 "
4359 "バイトではない。"
4360
4361 #. type: Plain text
4362 #: build/C/man2/mmap2.2:97
4363 msgid ""
4364 "B<getpagesize>(2), B<mmap>(2), B<mremap>(2), B<msync>(2), B<shm_open>(3)"
4365 msgstr ""
4366 "B<getpagesize>(2), B<mmap>(2), B<mremap>(2), B<msync>(2), B<shm_open>(3)"
4367
4368 #. type: TH
4369 #: build/C/man2/mprotect.2:32
4370 #, no-wrap
4371 msgid "MPROTECT"
4372 msgstr "MPROTECT"
4373
4374 #. type: TH
4375 #: build/C/man2/mprotect.2:32
4376 #, no-wrap
4377 msgid "2011-09-08"
4378 msgstr "2011-09-08"
4379
4380 #. type: Plain text
4381 #: build/C/man2/mprotect.2:35
4382 msgid "mprotect - set protection on a region of memory"
4383 msgstr "mprotect - メモリ領域の保護を設定する"
4384
4385 #. type: Plain text
4386 #: build/C/man2/mprotect.2:40
4387 #, no-wrap
4388 msgid "B<int mprotect(const void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
4389 msgstr "B<int mprotect(const void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
4390
4391 #. type: Plain text
4392 #: build/C/man2/mprotect.2:48
4393 msgid ""
4394 "B<mprotect>()  changes protection for the calling process's memory page(s)  "
4395 "containing any part of the address range in the interval [I<addr>,\\ I<addr>"
4396 "+I<len>-1].  I<addr> must be aligned to a page boundary."
4397 msgstr ""
4398 "B<mprotect>()  は、区間 [I<addr>,\\ I<addr>+I<len>-1] のアドレス範囲を含む 呼"
4399 "び出し元のプロセスのメモリページのアクセス保護を変更する。 I<addr> はページ境"
4400 "界に一致していなければならない。"
4401
4402 #. type: Plain text
4403 #: build/C/man2/mprotect.2:53
4404 msgid ""
4405 "If the calling process tries to access memory in a manner that violates the "
4406 "protection, then the kernel generates a B<SIGSEGV> signal for the process."
4407 msgstr ""
4408 "呼び出し元のプロセスがアクセス保護に違反するようなメモリアクセスを 行おうとす"
4409 "ると、カーネルはシグナル B<SIGSEGV> をそのプロセスに対して生成する。"
4410
4411 #. type: Plain text
4412 #: build/C/man2/mprotect.2:58
4413 msgid ""
4414 "I<prot> is either B<PROT_NONE> or a bitwise-or of the other values in the "
4415 "following list:"
4416 msgstr ""
4417 "I<prot> には、 B<PROT_NONE> か、以下のリストの B<PROT_NONE> 以外の値をビット"
4418 "毎の論理和 (bitwize-or) で指定する:"
4419
4420 #. type: Plain text
4421 #: build/C/man2/mprotect.2:61
4422 msgid "The memory cannot be accessed at all."
4423 msgstr "そのメモリには全くアクセスできない。"
4424
4425 #. type: Plain text
4426 #: build/C/man2/mprotect.2:64
4427 msgid "The memory can be read."
4428 msgstr "そのメモリを読み取ることができる。"
4429
4430 #. type: Plain text
4431 #: build/C/man2/mprotect.2:67
4432 msgid "The memory can be modified."
4433 msgstr "そのメモリを変更できる。"
4434
4435 #.  FIXME
4436 #.  Document PROT_GROWSUP and PROT_GROWSDOWN
4437 #. type: Plain text
4438 #: build/C/man2/mprotect.2:72
4439 msgid "The memory can be executed."
4440 msgstr "そのメモリは実行可能である。"
4441
4442 #. type: Plain text
4443 #: build/C/man2/mprotect.2:79
4444 msgid ""
4445 "On success, B<mprotect>()  returns zero.  On error, -1 is returned, and "
4446 "I<errno> is set appropriately."
4447 msgstr ""
4448 "成功した場合、 B<mprotect>()  は 0 を返す。エラーの場合は -1 が返り、 "
4449 "I<errno> が適切に設定される。"
4450
4451 #. type: Plain text
4452 #: build/C/man2/mprotect.2:89
4453 msgid ""
4454 "The memory cannot be given the specified access.  This can happen, for "
4455 "example, if you B<mmap>(2)  a file to which you have read-only access, then "
4456 "ask B<mprotect>()  to mark it B<PROT_WRITE>."
4457 msgstr ""
4458 "指定されたアクセスをメモリに設定することができない。 これは、例えば ファイル"
4459 "を読み取り専用で B<mmap>(2)  しており、その領域に対して B<mprotect>()  を呼び"
4460 "出して B<PROT_WRITE> に設定しようとした場合に発生する。"
4461
4462 #.  Or: both PROT_GROWSUP and PROT_GROWSDOWN were specified in 'prot'.
4463 #. type: Plain text
4464 #: build/C/man2/mprotect.2:94
4465 msgid ""
4466 "I<addr> is not a valid pointer, or not a multiple of the system page size."
4467 msgstr ""
4468 "I<addr> が有効なポインタでないか、 システムのページサイズの倍数でない。"
4469
4470 #. type: Plain text
4471 #: build/C/man2/mprotect.2:97
4472 msgid "Internal kernel structures could not be allocated."
4473 msgstr "カーネル内部の構造体を割り当てることができなかった。"
4474
4475 #. type: Plain text
4476 #: build/C/man2/mprotect.2:107
4477 msgid ""
4478 "Addresses in the range [I<addr>, I<addr>+I<len>-1] are invalid for the "
4479 "address space of the process, or specify one or more pages that are not "
4480 "mapped.  (Before kernel 2.4.19, the error B<EFAULT> was incorrectly produced "
4481 "for these cases.)"
4482 msgstr ""
4483 "[I<addr>, I<addr>+I<len>-1] という範囲のアドレスがプロセスのアドレス空間とし"
4484 "て不正であるか、 その範囲のアドレスがマップされていない 1 つ以上のページを指"
4485 "している (カーネル 2.4.19 より前では、この状況でエラー B<EFAULT> が間違って生"
4486 "成されていた)。"
4487
4488 #.  SVr4 defines an additional error
4489 #.  code EAGAIN. The SVr4 error conditions don't map neatly onto Linux's.
4490 #. type: Plain text
4491 #: build/C/man2/mprotect.2:116
4492 msgid ""
4493 "SVr4, POSIX.1-2001.  POSIX says that the behavior of B<mprotect>()  is "
4494 "unspecified if it is applied to a region of memory that was not obtained via "
4495 "B<mmap>(2)."
4496 msgstr ""
4497 "SVr4, POSIX.1-2001.  POSIX では、 B<mmap>(2)  経由で獲得していないメモリ領域"
4498 "に対して B<mprotect>()  を行った場合の B<mprotect>()  の動作は未定義であると"
4499 "されている。"
4500
4501 #. type: Plain text
4502 #: build/C/man2/mprotect.2:123
4503 msgid ""
4504 "On Linux it is always permissible to call B<mprotect>()  on any address in a "
4505 "process's address space (except for the kernel vsyscall area).  In "
4506 "particular it can be used to change existing code mappings to be writable."
4507 msgstr ""
4508 "Linux では、(カーネル vsyscall 領域以外の)  任意のプロセスアドレス空間に対し"
4509 "て B<mprotect>()  を呼び出すことが、常に許されている。 これは特に既存のコード"
4510 "マッピングを書き込み可能にするために使われる。"
4511
4512 #. type: Plain text
4513 #: build/C/man2/mprotect.2:133
4514 msgid ""
4515 "Whether B<PROT_EXEC> has any effect different from B<PROT_READ> is "
4516 "architecture- and kernel version-dependent.  On some hardware architectures "
4517 "(e.g., i386), B<PROT_WRITE> implies B<PROT_READ>."
4518 msgstr ""
4519 "B<PROT_EXEC> が B<PROT_READ> と異なる影響を持つか否かは、アーキテクチャとカー"
4520 "ネルのバージョンに依存する。 (i386 などの) いくつかのアーキテクチャでは、 "
4521 "B<PROT_WRITE> をセットすると、暗黙のうちに B<PROT_READ> がセットされる。"
4522
4523 #. type: Plain text
4524 #: build/C/man2/mprotect.2:142
4525 msgid ""
4526 "POSIX.1-2001 says that an implementation may permit access other than that "
4527 "specified in I<prot>, but at a minimum can only allow write access if "
4528 "B<PROT_WRITE> has been set, and must not allow any access if B<PROT_NONE> "
4529 "has been set."
4530 msgstr ""
4531 "POSIX.1-2001 では、 I<prot> で指定されていないアクセスを許可する実装を認めて"
4532 "いる。 ただし、最低限、 B<PROT_WRITE> がセットされている場合にのみ書き込みア"
4533 "クセスが許可され、 B<PROT_NONE> がセットされている場合にはアクセスは許可され"
4534 "ない点だけは 満たす必要がある。"
4535
4536 #. type: Plain text
4537 #: build/C/man2/mprotect.2:148
4538 msgid ""
4539 "The program below allocates four pages of memory, makes the third of these "
4540 "pages read-only, and then executes a loop that walks upward through the "
4541 "allocated region modifying bytes."
4542 msgstr ""
4543 "以下のプログラムは、メモリページを 4つ確保し、そのうち 3番目のページを 読み込"
4544 "み専用に設定する。その後で、確保した領域のアドレスの小さい方から 大きな方に向"
4545 "かって順番にバイト値を変更するループを実行する。"
4546
4547 #. type: Plain text
4548 #: build/C/man2/mprotect.2:151
4549 msgid ""
4550 "An example of what we might see when running the program is the following:"
4551 msgstr "プログラムを実行した場合の一例を以下に示す。"
4552
4553 #. type: Plain text
4554 #: build/C/man2/mprotect.2:157
4555 #, no-wrap
4556 msgid ""
4557 "$B< ./a.out>\n"
4558 "Start of region:        0x804c000\n"
4559 "Got SIGSEGV at address: 0x804e000\n"
4560 msgstr ""
4561 "$B< ./a.out>\n"
4562 "Start of region:        0x804c000\n"
4563 "Got SIGSEGV at address: 0x804e000\n"
4564
4565 #. type: Plain text
4566 #: build/C/man2/mprotect.2:169
4567 #, no-wrap
4568 msgid ""
4569 "#include E<lt>unistd.hE<gt>\n"
4570 "#include E<lt>signal.hE<gt>\n"
4571 "#include E<lt>stdio.hE<gt>\n"
4572 "#include E<lt>malloc.hE<gt>\n"
4573 "#include E<lt>stdlib.hE<gt>\n"
4574 "#include E<lt>errno.hE<gt>\n"
4575 "#include E<lt>sys/mman.hE<gt>\n"
4576 msgstr ""
4577 "#include E<lt>unistd.hE<gt>\n"
4578 "#include E<lt>signal.hE<gt>\n"
4579 "#include E<lt>stdio.hE<gt>\n"
4580 "#include E<lt>malloc.hE<gt>\n"
4581 "#include E<lt>stdlib.hE<gt>\n"
4582 "#include E<lt>errno.hE<gt>\n"
4583 "#include E<lt>sys/mman.hE<gt>\n"
4584
4585 #. type: Plain text
4586 #: build/C/man2/mprotect.2:174
4587 #, no-wrap
4588 msgid "char *buffer;\n"
4589 msgstr "char *buffer;\n"
4590
4591 #. type: Plain text
4592 #: build/C/man2/mprotect.2:182
4593 #, no-wrap
4594 msgid ""
4595 "static void\n"
4596 "handler(int sig, siginfo_t *si, void *unused)\n"
4597 "{\n"
4598 "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
4599 "            (long) si-E<gt>si_addr);\n"
4600 "    exit(EXIT_FAILURE);\n"
4601 "}\n"
4602 msgstr ""
4603 "static void\n"
4604 "handler(int sig, siginfo_t *si, void *unused)\n"
4605 "{\n"
4606 "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
4607 "            (long) si-E<gt>si_addr);\n"
4608 "    exit(EXIT_FAILURE);\n"
4609 "}\n"
4610
4611 #. type: Plain text
4612 #: build/C/man2/mprotect.2:189
4613 #, no-wrap
4614 msgid ""
4615 "int\n"
4616 "main(int argc, char *argv[])\n"
4617 "{\n"
4618 "    char *p;\n"
4619 "    int pagesize;\n"
4620 "    struct sigaction sa;\n"
4621 msgstr ""
4622 "int\n"
4623 "main(void)\n"
4624 "{\n"
4625 "    char *p;\n"
4626 "    int pagesize;\n"
4627 "    struct sigaction sa;\n"
4628
4629 #. type: Plain text
4630 #: build/C/man2/mprotect.2:195
4631 #, no-wrap
4632 msgid ""
4633 "    sa.sa_flags = SA_SIGINFO;\n"
4634 "    sigemptyset(&sa.sa_mask);\n"
4635 "    sa.sa_sigaction = handler;\n"
4636 "    if (sigaction(SIGSEGV, &sa, NULL) == -1)\n"
4637 "        handle_error(\"sigaction\");\n"
4638 msgstr ""
4639 "    sa.sa_flags = SA_SIGINFO;\n"
4640 "    sigemptyset(&sa.sa_mask);\n"
4641 "    sa.sa_sigaction = handler;\n"
4642 "    if (sigaction(SIGSEGV, &sa, NULL) == -1)\n"
4643 "        handle_error(\"sigaction\");\n"
4644
4645 #. type: Plain text
4646 #: build/C/man2/mprotect.2:199
4647 #, no-wrap
4648 msgid ""
4649 "    pagesize = sysconf(_SC_PAGE_SIZE);\n"
4650 "    if (pagesize == -1)\n"
4651 "        handle_error(\"sysconf\");\n"
4652 msgstr ""
4653 "    pagesize = sysconf(_SC_PAGE_SIZE);\n"
4654 "    if (pagesize == -1)\n"
4655 "        handle_error(\"sysconf\");\n"
4656
4657 #. type: Plain text
4658 #: build/C/man2/mprotect.2:202
4659 #, no-wrap
4660 msgid ""
4661 "    /* Allocate a buffer aligned on a page boundary;\n"
4662 "       initial protection is PROT_READ | PROT_WRITE */\n"
4663 msgstr ""
4664 "    /* Allocate a buffer aligned on a page boundary;\n"
4665 "       initial protection is PROT_READ | PROT_WRITE */\n"
4666
4667 #. type: Plain text
4668 #: build/C/man2/mprotect.2:206
4669 #, no-wrap
4670 msgid ""
4671 "    buffer = memalign(pagesize, 4 * pagesize);\n"
4672 "    if (buffer == NULL)\n"
4673 "        handle_error(\"memalign\");\n"
4674 msgstr ""
4675 "    buffer = memalign(pagesize, 4 * pagesize);\n"
4676 "    if (buffer == NULL)\n"
4677 "        handle_error(\"memalign\");\n"
4678
4679 #. type: Plain text
4680 #: build/C/man2/mprotect.2:208
4681 #, no-wrap
4682 msgid "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
4683 msgstr "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
4684
4685 #. type: Plain text
4686 #: build/C/man2/mprotect.2:212
4687 #, no-wrap
4688 msgid ""
4689 "    if (mprotect(buffer + pagesize * 2, pagesize,\n"
4690 "                PROT_READ) == -1)\n"
4691 "        handle_error(\"mprotect\");\n"
4692 msgstr ""
4693 "    if (mprotect(buffer + pagesize * 2, pagesize,\n"
4694 "                PROT_READ) == -1)\n"
4695 "        handle_error(\"mprotect\");\n"
4696
4697 #. type: Plain text
4698 #: build/C/man2/mprotect.2:215
4699 #, no-wrap
4700 msgid ""
4701 "    for (p = buffer ; ; )\n"
4702 "        *(p++) = \\(aqa\\(aq;\n"
4703 msgstr ""
4704 "    for (p = buffer ; ; )\n"
4705 "        *(p++) = \\(aqa\\(aq;\n"
4706
4707 #. type: Plain text
4708 #: build/C/man2/mprotect.2:219
4709 #, no-wrap
4710 msgid ""
4711 "    printf(\"Loop completed\\en\");     /* Should never happen */\n"
4712 "    exit(EXIT_SUCCESS);\n"
4713 "}\n"
4714 msgstr ""
4715 "    printf(\"Loop completed\\en\");     /* Should never happen */\n"
4716 "    exit(EXIT_SUCCESS);\n"
4717 "}\n"
4718
4719 #. type: Plain text
4720 #: build/C/man2/mprotect.2:222
4721 msgid "B<mmap>(2), B<sysconf>(3)"
4722 msgstr "B<mmap>(2), B<sysconf>(3)"
4723
4724 #. type: TH
4725 #: build/C/man2/mremap.2:31
4726 #, no-wrap
4727 msgid "MREMAP"
4728 msgstr "MREMAP"
4729
4730 #. type: TH
4731 #: build/C/man2/mremap.2:31
4732 #, no-wrap
4733 msgid "2010-06-10"
4734 msgstr "2010-06-10"
4735
4736 #. type: Plain text
4737 #: build/C/man2/mremap.2:34
4738 msgid "mremap - remap a virtual memory address"
4739 msgstr "mremap - 仮想メモリ・アドレスを再マッピングする"
4740
4741 #. type: Plain text
4742 #: build/C/man2/mremap.2:37
4743 #, no-wrap
4744 msgid "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
4745 msgstr "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
4746
4747 #. type: Plain text
4748 #: build/C/man2/mremap.2:42
4749 #, no-wrap
4750 msgid ""
4751 "B<void *mremap(void *>I<old_address>B<, size_t >I<old_size>B<,>\n"
4752 "B<             size_t >I<new_size>B<, int >I<flags>B<, ... /* void *>I<new_address>B< */);>\n"
4753 msgstr ""
4754 "B<void *mremap(void *>I<old_address>B<, size_t >I<old_size>B<,>\n"
4755 "B<             size_t >I<new_size>B<, int >I<flags>B<, ... /* void *>I<new_address>B< */);>\n"
4756
4757 #. type: Plain text
4758 #: build/C/man2/mremap.2:48
4759 msgid ""
4760 "B<mremap>()  expands (or shrinks) an existing memory mapping, potentially "
4761 "moving it at the same time (controlled by the I<flags> argument and the "
4762 "available virtual address space)."
4763 msgstr ""
4764 "B<mremap>()  は既存のメモリ・マッピングの拡張 (または縮小) を行う。 同時に移"
4765 "動されることもある (I<flags> 引き数と利用可能な仮想アドレス空間によって決ま"
4766 "る)。"
4767
4768 #. type: Plain text
4769 #: build/C/man2/mremap.2:62
4770 msgid ""
4771 "I<old_address> is the old address of the virtual memory block that you want "
4772 "to expand (or shrink).  Note that I<old_address> has to be page aligned.  "
4773 "I<old_size> is the old size of the virtual memory block.  I<new_size> is the "
4774 "requested size of the virtual memory block after the resize.  An optional "
4775 "fifth argument, I<new_address>, may be provided; see the description of "
4776 "B<MREMAP_FIXED> below."
4777 msgstr ""
4778 "I<old_address> は拡張 (または縮小) しようとする仮想メモリ・ブロック の元のア"
4779 "ドレスである。I<old_address> はページ境界に合っていなければ ならない点に注意"
4780 "すること。I<old_size> は元の仮想メモリ・ブロックの サイズである。 "
4781 "I<new_size> は要求する変更後の仮想メモリ・ブロックのサイズである。 5 番目の引"
4782 "き数として I<new_address> を指定することができる。下記の B<MREMAP_FIXED> の説"
4783 "明を参照のこと。"
4784
4785 #. type: Plain text
4786 #: build/C/man2/mremap.2:74
4787 msgid ""
4788 "In Linux the memory is divided into pages.  A user process has (one or)  "
4789 "several linear virtual memory segments.  Each virtual memory segment has one "
4790 "or more mappings to real memory pages (in the page table).  Each virtual "
4791 "memory segment has its own protection (access rights), which may cause a "
4792 "segmentation violation if the memory is accessed incorrectly (e.g., writing "
4793 "to a read-only segment).  Accessing virtual memory outside of the segments "
4794 "will also cause a segmentation violation."
4795 msgstr ""
4796 "Linux ではメモリはページに分割される。ユーザー・プロセスは (一つまたは)  複数"
4797 "のリニアな仮想メモリセグメントを持つ。 それぞれの仮想メモリセグメントは一つ以"
4798 "上の実メモリ・ページ にマッピングされている (マッピング情報はページ・テーブル"
4799 "で管理される)。 仮想メモリセグメントにはセグメント毎の保護 (アクセス権) が設"
4800 "定されており、 メモリが不正にアクセスされた場合 (例えば読み込み専用のセグメン"
4801 "トに 書き込んだ場合)、セグメンテーション侵害 (segmentation violation) を 引き"
4802 "起こす。また、セグメント外の仮想メモリにアクセスした場合にも セグメンテーショ"
4803 "ン侵害が発生する。"
4804
4805 #. type: Plain text
4806 #: build/C/man2/mremap.2:82
4807 msgid ""
4808 "B<mremap>()  uses the Linux page table scheme.  B<mremap>()  changes the "
4809 "mapping between virtual addresses and memory pages.  This can be used to "
4810 "implement a very efficient B<realloc>(3)."
4811 msgstr ""
4812 "B<mremap>()  は Linux のページ・テーブル方式を使用する。 B<mremap>()  は仮想"
4813 "アドレスとメモリ・ページのマッピングを変更する。これは非常に効率的な "
4814 "B<realloc>(3)  を実装するのに使用されている。"
4815
4816 #. type: Plain text
4817 #: build/C/man2/mremap.2:84
4818 msgid "The I<flags> bit-mask argument may be 0, or include the following flag:"
4819 msgstr "I<flags> ビットマスク引数は 0 または以下のフラグを含む:"
4820
4821 #. type: TP
4822 #: build/C/man2/mremap.2:84
4823 #, no-wrap
4824 msgid "B<MREMAP_MAYMOVE>"
4825 msgstr "B<MREMAP_MAYMOVE>"
4826
4827 #. type: Plain text
4828 #: build/C/man2/mremap.2:96
4829 msgid ""
4830 "By default, if there is not sufficient space to expand a mapping at its "
4831 "current location, then B<mremap>()  fails.  If this flag is specified, then "
4832 "the kernel is permitted to relocate the mapping to a new virtual address, if "
4833 "necessary.  If the mapping is relocated, then absolute pointers into the old "
4834 "mapping location become invalid (offsets relative to the starting address of "
4835 "the mapping should be employed)."
4836 msgstr ""
4837 "デフォルトでは、現在の位置にマッピングを拡張するための 十分な空きがなければ "
4838 "B<mremap>()  は失敗する。 このフラグが指定されると、カーネルは必要があれば"
4839 "マッピングを 新しい仮想アドレスに再配置することができる マッピングが再配置さ"
4840 "れると、古いマッピング位置への絶対ポインタは 無効になる (マッピングの開始アド"
4841 "レスからの相対オフセットは有効のままである)。"
4842
4843 #. type: TP
4844 #: build/C/man2/mremap.2:96
4845 #, no-wrap
4846 msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
4847 msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
4848
4849 #. type: Plain text
4850 #: build/C/man2/mremap.2:118
4851 msgid ""
4852 "This flag serves a similar purpose to the B<MAP_FIXED> flag of B<mmap>(2).  "
4853 "If this flag is specified, then B<mremap>()  accepts a fifth argument, "
4854 "I<void *new_address>, which specifies a page-aligned address to which the "
4855 "mapping must be moved.  Any previous mapping at the address range specified "
4856 "by I<new_address> and I<new_size> is unmapped.  If B<MREMAP_FIXED> is "
4857 "specified, then B<MREMAP_MAYMOVE> must also be specified."
4858 msgstr ""
4859 "このフラグは B<mmap>(2)  の B<MAP_FIXED> フラグと似たような目的で用いられ"
4860 "る。 このフラグが指定されると、 B<mremap>()  は 5 番目の引き数 I<void "
4861 "*new_address> を受け取り、この引数はマッピングが移動されるべきアドレスを指定"
4862 "する。 このアドレスはページ境界に合っていなければならない。 I<new_address> "
4863 "と I<new_size> で指定されるアドレス範囲に過去のマッピングがあった場合、 その"
4864 "マッピングはアンマップされる (unmapped)。 B<MREMAP_FIXED> を指定した場合は、 "
4865 "B<MREMAP_MAYMOVE> も指定しなければならない。"
4866
4867 #. type: Plain text
4868 #: build/C/man2/mremap.2:128
4869 msgid ""
4870 "If the memory segment specified by I<old_address> and I<old_size> is locked "
4871 "(using B<mlock>(2)  or similar), then this lock is maintained when the "
4872 "segment is resized and/or relocated.  As a consequence, the amount of memory "
4873 "locked by the process may change."
4874 msgstr ""
4875 "I<old_address> と I<old_size> で指定されるメモリセグメントが (B<mlock>(2)  や"
4876 "同様のもので) ロックされている場合、セグメントのサイズが変わったり 再配置され"
4877 "たりした時にロックも維持される。 その結果、プロセスによってロックされるメモリ"
4878 "の量は変化する。"
4879
4880 #. type: Plain text
4881 #: build/C/man2/mremap.2:136
4882 msgid ""
4883 "On success B<mremap>()  returns a pointer to the new virtual memory area.  "
4884 "On error, the value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>) is returned, "
4885 "and I<errno> is set appropriately."
4886 msgstr ""
4887 "成功した場合は B<mremap>()  は新しい仮想メモリ領域へのポインタを返す。 エラー"
4888 "の場合は B<MAP_FAILED> (すなわち I<(void\\ *)\\ -1>) が返され、 I<errno> が適"
4889 "切に設定される。"
4890
4891 #. type: Plain text
4892 #: build/C/man2/mremap.2:143
4893 msgid ""
4894 "The caller tried to expand a memory segment that is locked, but this was not "
4895 "possible without exceeding the B<RLIMIT_MEMLOCK> resource limit."
4896 msgstr ""
4897 "呼び出し元がロックされているメモリセグメントを拡張しようとしたが、 "
4898 "B<RLIMIT_MEMLOCK> リソース制限を越えずにこれを行うことができない。"
4899
4900 #. type: Plain text
4901 #: build/C/man2/mremap.2:152
4902 msgid ""
4903 "\"Segmentation fault.\" Some address in the range I<old_address> to "
4904 "I<old_address>+I<old_size> is an invalid virtual memory address for this "
4905 "process.  You can also get B<EFAULT> even if there exist mappings that cover "
4906 "the whole address space requested, but those mappings are of different types."
4907 msgstr ""
4908 "「セグメンテーション違反(segmentation fault)」 I<old_address> から "
4909 "I<old_address>+I<old_size> の 範囲のアドレスのどれかがこのプロセスにおいて不"
4910 "正な仮想メモリ・アドレスである。 たとえ要求したアドレス空間全体を含むような"
4911 "マッピングがあったとしても、 それらのマッピングが異なった型ならば B<EFAULT> "
4912 "を受け取るだろう。"
4913
4914 #. type: Plain text
4915 #: build/C/man2/mremap.2:180
4916 msgid ""
4917 "An invalid argument was given.  Possible causes are: I<old_address> was not "
4918 "page aligned; a value other than B<MREMAP_MAYMOVE> or B<MREMAP_FIXED> was "
4919 "specified in I<flags>; I<new_size> was zero; I<new_size> or I<new_address> "
4920 "was invalid; or the new address range specified by I<new_address> and "
4921 "I<new_size> overlapped the old address range specified by I<old_address> and "
4922 "I<old_size>; or B<MREMAP_FIXED> was specified without also specifying "
4923 "B<MREMAP_MAYMOVE>."
4924 msgstr ""
4925 "不正な引き数が与えられた。 可能性のある原因は以下の通りである: たいていは "
4926 "I<old_address> がページ境界に 合ってない; I<flags> に B<MREMAP_MAYMOVE> また"
4927 "は B<MREMAP_FIXED> 以外の値が指定されている; I<new_size> がゼロ; I<new_size> "
4928 "または I<new_address> の値が不正; I<new_address> と I<new_size> で指定される"
4929 "新しいアドレス範囲が I<old_address> と I<old_size> で指定される古いアドレス範"
4930 "囲と重なっている; B<MREMAP_FIXED> が指定されているが B<MREMAP_MAYMOVE> が指定"
4931 "されていない。"
4932
4933 #. type: Plain text
4934 #: build/C/man2/mremap.2:186
4935 msgid ""
4936 "The memory area cannot be expanded at the current virtual address, and the "
4937 "B<MREMAP_MAYMOVE> flag is not set in I<flags>.  Or, there is not enough "
4938 "(virtual) memory available."
4939 msgstr ""
4940 "現在の仮想アドレスではメモリ領域が拡張できず、 B<MREMAP_MAYMOVE> フラグが "
4941 "I<flags> に設定されていない。 または十分な (仮想) メモリが存在しない。"
4942
4943 #.  4.2BSD had a (never actually implemented)
4944 #.  .BR mremap (2)
4945 #.  call with completely different semantics.
4946 #. type: Plain text
4947 #: build/C/man2/mremap.2:192
4948 msgid ""
4949 "This call is Linux-specific, and should not be used in programs intended to "
4950 "be portable."
4951 msgstr ""
4952 "このコールは Linux 特有であり、移植を意図したプログラムで 使用すべきではな"
4953 "い。"
4954
4955 #. type: Plain text
4956 #: build/C/man2/mremap.2:200
4957 msgid ""
4958 "Prior to version 2.4, glibc did not expose the definition of "
4959 "B<MREMAP_FIXED>, and the prototype for B<mremap>()  did not allow for the "
4960 "I<new_address> argument."
4961 msgstr ""
4962 "バージョン 2.4 より前の glibc では、 B<MREMAP_FIXED> の定義は公開されておら"
4963 "ず、 B<mremap>()  のプロトタイプは I<new_address> 引き数を取らなかった。"
4964
4965 #. type: Plain text
4966 #: build/C/man2/mremap.2:209
4967 msgid ""
4968 "B<brk>(2), B<getpagesize>(2), B<getrlimit>(2), B<mlock>(2), B<mmap>(2), "
4969 "B<sbrk>(2), B<malloc>(3), B<realloc>(3)"
4970 msgstr ""
4971 "B<brk>(2), B<getpagesize>(2), B<getrlimit>(2), B<mlock>(2), B<mmap>(2), "
4972 "B<sbrk>(2), B<realloc>(3), B<malloc>(3)"
4973
4974 #. type: Plain text
4975 #: build/C/man2/mremap.2:213
4976 msgid ""
4977 "Your favorite OS text book for more information on paged memory.  (I<Modern "
4978 "Operating Systems> by Andrew S. Tanenbaum, I<Inside Linux> by Randolf "
4979 "Bentson, I<The Design of the UNIX Operating System> by Maurice J. Bach.)"
4980 msgstr ""
4981 "ページ分割されたメモリについてもっと詳しく知りたいならば あなたの好みの OS の\n"
4982 "教科書を参照すること。 (I<Modern Operating Systems> by Andrew S. Tanenbaum,\n"
4983 "I<Inside Linux> by Randolf Bentson, I<The Design of the UNIX Operating\n"
4984 "System> by Maurice J. Bach.)"
4985
4986 #. type: TH
4987 #: build/C/man2/msync.2:25
4988 #, no-wrap
4989 msgid "MSYNC"
4990 msgstr "MSYNC"
4991
4992 #. type: TH
4993 #: build/C/man2/msync.2:25 build/C/man2/remap_file_pages.2:26
4994 #, no-wrap
4995 msgid "2008-04-22"
4996 msgstr "2008-04-22"
4997
4998 #. type: Plain text
4999 #: build/C/man2/msync.2:28
5000 msgid "msync - synchronize a file with a memory map"
5001 msgstr "msync - ファイルをマップしたメモリと同期させる"
5002
5003 #. type: Plain text
5004 #: build/C/man2/msync.2:32
5005 msgid "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
5006 msgstr "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
5007
5008 #. type: Plain text
5009 #: build/C/man2/msync.2:48
5010 msgid ""
5011 "B<msync>()  flushes changes made to the in-core copy of a file that was "
5012 "mapped into memory using B<mmap>(2)  back to disk.  Without use of this call "
5013 "there is no guarantee that changes are written back before B<munmap>(2)  is "
5014 "called.  To be more precise, the part of the file that corresponds to the "
5015 "memory area starting at I<addr> and having length I<length> is updated."
5016 msgstr ""
5017 "B<msync>()  は B<mmap>(2)  を使ってメモリにマップされたファイルの、 メモリ上"
5018 "のコピーになされた変更をディスクに反映させる。 この関数を使用しないと、 "
5019 "B<munmap>(2)  が呼び出されるまで変更が書き戻される保証はない。 より正確には、"
5020 "ファイルのうち I<addr> から始まり長さ I<length> のメモリ領域に対応する部分が"
5021 "更新される。"
5022
5023 #. type: Plain text
5024 #: build/C/man2/msync.2:68
5025 msgid ""
5026 "The I<flags> argument may have the bits B<MS_ASYNC>, B<MS_SYNC>, and "
5027 "B<MS_INVALIDATE> set, but not both B<MS_ASYNC> and B<MS_SYNC>.  B<MS_ASYNC> "
5028 "specifies that an update be scheduled, but the call returns immediately.  "
5029 "B<MS_SYNC> asks for an update and waits for it to complete.  "
5030 "B<MS_INVALIDATE> asks to invalidate other mappings of the same file (so that "
5031 "they can be updated with the fresh values just written)."
5032 msgstr ""
5033 "I<flags> 引数にはビット B<MS_ASYNC>, B<MS_SYNC>, B<MS_INVALIDATE> を設定する"
5034 "ことができるが、 B<MS_ASYNC> と B<MS_SYNC> を同時に指定することはできない。 "
5035 "B<MS_ASYNC> は更新を予定に組み込むことを表し、呼び出しは直ちに返る。 "
5036 "B<MS_SYNC> は更新を要求し、更新が完了するまで待つ。 B<MS_INVALIDATE> は(たっ"
5037 "た今書き込んだ新しい値でマッピングを更新することができるように)  同じファイル"
5038 "に対する他のマッピングを無効にすることを要求する。"
5039
5040 #. type: Plain text
5041 #: build/C/man2/msync.2:73
5042 msgid ""
5043 "On success, zero is returned.  On error, -1 is returned, and I<errno> is set "
5044 "appropriately."
5045 msgstr ""
5046 "成功した場合、 0 が返る。エラーの場合、 -1 が返り、 I<errno> が適切に設定され"
5047 "る。"
5048
5049 #. type: TP
5050 #: build/C/man2/msync.2:74
5051 #, no-wrap
5052 msgid "B<EBUSY>"
5053 msgstr "B<EBUSY>"
5054
5055 #. type: Plain text
5056 #: build/C/man2/msync.2:80
5057 msgid ""
5058 "B<MS_INVALIDATE> was specified in I<flags>, and a memory lock exists for the "
5059 "specified address range."
5060 msgstr ""
5061 "I flags に B<MS_INVALIDATE> が指定されたが、指定されたアドレス範囲にロックが"
5062 "存在する。"
5063
5064 #. type: Plain text
5065 #: build/C/man2/msync.2:93
5066 msgid ""
5067 "I<addr> is not a multiple of PAGESIZE; or any bit other than B<MS_ASYNC> | "
5068 "B<MS_INVALIDATE> | B<MS_SYNC> is set in I<flags>; or both B<MS_SYNC> and "
5069 "B<MS_ASYNC> are set in I<flags>."
5070 msgstr ""
5071 "I<addr> が PAGESIZE の倍数でない。または、 I<flags> に B<MS_ASYNC>、"
5072 "B<MS_INVALIDATE>、B<MS_SYNC> 以外のビットが設定された。 または、 I<flags> に "
5073 "B<MS_SYNC> と B<MS_ASYNC> の両方が設定された。"
5074
5075 #. type: Plain text
5076 #: build/C/man2/msync.2:96
5077 msgid "The indicated memory (or part of it) was not mapped."
5078 msgstr "指定されたメモリ (またはその一部) がマップされていない。"
5079
5080 #. type: Plain text
5081 #: build/C/man2/msync.2:98 build/C/man3/posix_fallocate.3:103
5082 #: build/C/man3/shm_open.3:251 build/C/man7/shm_overview.7:103
5083 msgid "POSIX.1-2001."
5084 msgstr "POSIX.1-2001."
5085
5086 #. type: Plain text
5087 #: build/C/man2/msync.2:105
5088 msgid ""
5089 "This call was introduced in Linux 1.3.21, and then used B<EFAULT> instead of "
5090 "B<ENOMEM>.  In Linux 2.4.19 this was changed to the POSIX value B<ENOMEM>."
5091 msgstr ""
5092 "この関数は Linux 1.3.21 で導入されたが、 B<ENOMEM> ではなく B<EFAULT> が使わ"
5093 "れていた。 これは Linux 2.4.19 で POSIX における値 B<ENOMEM> に変更された。"
5094
5095 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
5096 #.  -1: unavailable, 0: ask using sysconf().
5097 #.  glibc defines them to 1.
5098 #. type: Plain text
5099 #: build/C/man2/msync.2:118
5100 msgid ""
5101 "On POSIX systems on which B<msync>()  is available, both "
5102 "B<_POSIX_MAPPED_FILES> and B<_POSIX_SYNCHRONIZED_IO> are defined in "
5103 "I<E<lt>unistd.hE<gt>> to a value greater than 0.  (See also B<sysconf>(3).)"
5104 msgstr ""
5105 "B<msync>()  が使用可能な POSIX システムでは B<_POSIX_MAPPED_FILES> と "
5106 "B<_POSIX_SYNCHRONIZED_IO> の両方が I<E<lt>unistd.hE<gt>> で 0 より大きい値に"
5107 "定義される。 (B<sysconf>(3)  を参照すること。 )"
5108
5109 #. type: TP
5110 #: build/C/man2/msync.2:120 build/C/man7/shm_overview.7:46
5111 #, no-wrap
5112 msgid "B<mmap>(2)"
5113 msgstr "B<mmap>(2)"
5114
5115 #. type: TH
5116 #: build/C/man3/mtrace.3:23
5117 #, no-wrap
5118 msgid "MTRACE"
5119 msgstr "MTRACE"
5120
5121 #. type: TH
5122 #: build/C/man3/mtrace.3:23
5123 #, no-wrap
5124 msgid "2012-03-22"
5125 msgstr "2012-03-22"
5126
5127 #. type: Plain text
5128 #: build/C/man3/mtrace.3:26
5129 msgid "mtrace, muntrace - malloc tracing"
5130 msgstr "mtrace, muntrace - malloc のトレース"
5131
5132 #. type: Plain text
5133 #: build/C/man3/mtrace.3:28
5134 msgid "B<#include E<lt>mcheck.hE<gt>>"
5135 msgstr "B<#include E<lt>mcheck.hE<gt>>"
5136
5137 #. type: Plain text
5138 #: build/C/man3/mtrace.3:30
5139 msgid "B<void mtrace(void);>"
5140 msgstr "B<void mtrace(void);>"
5141
5142 #. type: Plain text
5143 #: build/C/man3/mtrace.3:32
5144 msgid "B<void muntrace(void);>"
5145 msgstr "B<void muntrace(void);>"
5146
5147 #. type: Plain text
5148 #: build/C/man3/mtrace.3:44
5149 msgid ""
5150 "The B<mtrace>()  function installs hook functions for the memory-allocation "
5151 "functions (B<malloc>(3), B<realloc>(3)  B<memalign>(3), B<free>(3)).  These "
5152 "hook functions record tracing information about memory allocation and "
5153 "deallocation.  The tracing information can be used to discover memory leaks "
5154 "and attempts to free nonallocated memory in a program."
5155 msgstr ""
5156
5157 #. type: Plain text
5158 #: build/C/man3/mtrace.3:55
5159 msgid ""
5160 "The B<muntrace>()  function disables the hook functions installed by "
5161 "B<mtrace>(), so that tracing information is no longer recorded for the "
5162 "memory-allocation functions.  If no hook functions were successfully "
5163 "installed by B<mtrace>(), B<muntrace>()  does nothing."
5164 msgstr ""
5165
5166 #. type: Plain text
5167 #: build/C/man3/mtrace.3:63
5168 msgid ""
5169 "When B<mtrace>(3)  is called, it checks the value of the environment "
5170 "variable B<MALLOC_TRACE>, which should contain the pathname of a file in "
5171 "which the tracing information is to be recorded.  If the pathname is "
5172 "successfully opened, it is truncated to zero length."
5173 msgstr ""
5174
5175 #. type: Plain text
5176 #: build/C/man3/mtrace.3:76
5177 msgid ""
5178 "If B<MALLOC_TRACE> is not set, or the pathname it specifies is invalid or "
5179 "not writable, then no hook functions are installed, and B<mtrace>()  has no "
5180 "effect.  In set-user-ID and set-group-ID programs, B<MALLOC_TRACE> is "
5181 "ignored, and B<mtrace>()  has no effect."
5182 msgstr ""
5183
5184 #. type: Plain text
5185 #: build/C/man3/mtrace.3:84
5186 msgid ""
5187 "In normal usage, B<mtrace>()  is called once at the start of execution of a "
5188 "program, and B<muntrace>()  is never called."
5189 msgstr ""
5190
5191 #. type: Plain text
5192 #: build/C/man3/mtrace.3:94
5193 msgid ""
5194 "The tracing output produced after a call to B<mtrace>()  is textual, but not "
5195 "designed to be human readable.  The GNU C library provides a Perl script, "
5196 "B<mtrace>(1), that interprets the trace log and produces human-readable "
5197 "output.  For best results, the traced program should be compiled with "
5198 "debugging enabled, so that line-number information is recorded in the "
5199 "executable."
5200 msgstr ""
5201
5202 #. type: Plain text
5203 #: build/C/man3/mtrace.3:100
5204 msgid ""
5205 "The tracing performed by B<mtrace>()  incurs a performance penalty (if "
5206 "B<MALLOC_TRACE> points to a valid, writable pathname)."
5207 msgstr ""
5208
5209 #. type: Plain text
5210 #: build/C/man3/mtrace.3:106
5211 msgid ""
5212 "The line-number information produced by B<mtrace>(1)  is not always precise: "
5213 "the line number references may refer to the previous or following (non-"
5214 "blank)  line of the source code."
5215 msgstr ""
5216
5217 #. type: Plain text
5218 #: build/C/man3/mtrace.3:113
5219 msgid ""
5220 "The shell session below demonstrates the use of the B<mtrace>()  function "
5221 "and the B<mtrace>(1)  command in a program that has memory leaks at two "
5222 "different locations.  The demonstration uses the following program:"
5223 msgstr ""
5224
5225 #. type: Plain text
5226 #: build/C/man3/mtrace.3:120
5227 #, no-wrap
5228 msgid ""
5229 "$ B<cat t_mtrace.c>\n"
5230 "#include E<lt>mcheck.hE<gt>\n"
5231 "#include E<lt>stdlib.hE<gt>\n"
5232 "#include E<lt>stdio.hE<gt>\n"
5233 msgstr ""
5234 "$ B<cat t_mtrace.c>\n"
5235 "#include E<lt>mcheck.hE<gt>\n"
5236 "#include E<lt>stdlib.hE<gt>\n"
5237 "#include E<lt>stdio.hE<gt>\n"
5238
5239 #. type: Plain text
5240 #: build/C/man3/mtrace.3:125
5241 #, no-wrap
5242 msgid ""
5243 "int\n"
5244 "main(int argc, char *argv[])\n"
5245 "{\n"
5246 "    int j;\n"
5247 msgstr ""
5248 "int\n"
5249 "main(int argc, char *argv[])\n"
5250 "{\n"
5251 "    int j;\n"
5252
5253 #. type: Plain text
5254 #: build/C/man3/mtrace.3:127
5255 #, no-wrap
5256 msgid "    mtrace();\n"
5257 msgstr "    mtrace();\n"
5258
5259 #. type: Plain text
5260 #: build/C/man3/mtrace.3:130
5261 #, no-wrap
5262 msgid ""
5263 "    for (j = 0; j E<lt> 2; j++)\n"
5264 "        malloc(100);            /* Never freed--a memory leak */\n"
5265 msgstr ""
5266 "    for (j = 0; j E<lt> 2; j++)\n"
5267 "        malloc(100);            /* Never freed--a memory leak */\n"
5268
5269 #. type: Plain text
5270 #: build/C/man3/mtrace.3:134
5271 #, no-wrap
5272 msgid ""
5273 "    calloc(16, 16);             /* Never freed--a memory leak */\n"
5274 "    exit(EXIT_SUCCESS);\n"
5275 "}\n"
5276 msgstr ""
5277 "    calloc(16, 16);             /* Never freed--a memory leak */\n"
5278 "    exit(EXIT_SUCCESS);\n"
5279 "}\n"
5280
5281 #. type: Plain text
5282 #: build/C/man3/mtrace.3:140
5283 msgid ""
5284 "When we run the program as follows, we see that B<mtrace>()  diagnosed "
5285 "memory leaks at two different locations in the program:"
5286 msgstr ""
5287
5288 #. type: Plain text
5289 #: build/C/man3/mtrace.3:153
5290 #, no-wrap
5291 msgid ""
5292 "$ B<cc -g t_mtrace.c -o t_mtrace>\n"
5293 "$ B<export MALLOC_TRACE=/tmp/t>\n"
5294 "$ B<./t_mtrace>\n"
5295 "$ B<mtrace ./t_mtrace $MALLOC_TRACE>\n"
5296 "Memory not freed:\n"
5297 "-----------------\n"
5298 "   Address     Size     Caller\n"
5299 "0x084c9378     0x64  at /home/cecilia/t_mtrace.c:12\n"
5300 "0x084c93e0     0x64  at /home/cecilia/t_mtrace.c:12\n"
5301 "0x084c9448    0x100  at /home/cecilia/t_mtrace.c:16\n"
5302 msgstr ""
5303 "$ B<cc -g t_mtrace.c -o t_mtrace>\n"
5304 "$ B<export MALLOC_TRACE=/tmp/t>\n"
5305 "$ B<./t_mtrace>\n"
5306 "$ B<mtrace ./t_mtrace $MALLOC_TRACE>\n"
5307 "Memory not freed:\n"
5308 "-----------------\n"
5309 "   Address     Size     Caller\n"
5310 "0x084c9378     0x64  at /home/cecilia/t_mtrace.c:12\n"
5311 "0x084c93e0     0x64  at /home/cecilia/t_mtrace.c:12\n"
5312 "0x084c9448    0x100  at /home/cecilia/t_mtrace.c:16\n"
5313
5314 #. type: Plain text
5315 #: build/C/man3/mtrace.3:165
5316 msgid ""
5317 "The first two messages about unfreed memory correspond to the two B<malloc>"
5318 "(3)  calls inside the I<for> loop.  The final message corresponds to the "
5319 "call to B<calloc>(3)  (which in turn calls B<malloc>(3))."
5320 msgstr ""
5321
5322 #. type: Plain text
5323 #: build/C/man3/mtrace.3:168
5324 msgid "B<mtrace>(1), B<malloc>(3), B<malloc_hook>(3)"
5325 msgstr "B<mtrace>(1), B<malloc>(3), B<malloc_hook>(3)"
5326
5327 #. type: TH
5328 #: build/C/man2/posix_fadvise.2:27
5329 #, no-wrap
5330 msgid "POSIX_FADVISE"
5331 msgstr "POSIX_FADVISE"
5332
5333 #. type: TH
5334 #: build/C/man2/posix_fadvise.2:27 build/C/man2/sync_file_range.2:30
5335 #, no-wrap
5336 msgid "2010-10-09"
5337 msgstr "2010-10-09"
5338
5339 #. type: Plain text
5340 #: build/C/man2/posix_fadvise.2:30
5341 msgid "posix_fadvise - predeclare an access pattern for file data"
5342 msgstr "posix_fadvise - ファイルデータのアクセスパターンをあらかじめ宣言する"
5343
5344 #. type: Plain text
5345 #: build/C/man2/posix_fadvise.2:33 build/C/man3/posix_fallocate.3:29
5346 #, no-wrap
5347 msgid "B<#include E<lt>fcntl.hE<gt>>\n"
5348 msgstr "B<#include E<lt>fcntl.hE<gt>>\n"
5349
5350 #. type: Plain text
5351 #: build/C/man2/posix_fadvise.2:36
5352 #, no-wrap
5353 msgid "B<int posix_fadvise(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<, int >I<advice>B<);>\n"
5354 msgstr "B<int posix_fadvise(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<, int >I<advice>B<);>\n"
5355
5356 #. type: Plain text
5357 #: build/C/man2/posix_fadvise.2:45
5358 msgid "B<posix_fadvise>():"
5359 msgstr "B<posix_fadvise>():"
5360
5361 #. type: Plain text
5362 #: build/C/man2/posix_fadvise.2:47 build/C/man3/posix_fallocate.3:42
5363 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
5364 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
5365
5366 #. type: Plain text
5367 #: build/C/man2/posix_fadvise.2:55
5368 msgid ""
5369 "Programs can use B<posix_fadvise>()  to announce an intention to access file "
5370 "data in a specific pattern in the future, thus allowing the kernel to "
5371 "perform appropriate optimizations."
5372 msgstr ""
5373 "プログラムは、将来特定のパターンでファイルデータに アクセスする意思を伝えるた"
5374 "めに B<posix_fadvise>()  を使うことができる。 これにより、カーネルが適切な最"
5375 "適化を実行することが可能になる。"
5376
5377 #. type: Plain text
5378 #: build/C/man2/posix_fadvise.2:62
5379 msgid ""
5380 "The I<advice> applies to a (not necessarily existent) region starting at "
5381 "I<offset> and extending for I<len> bytes (or until the end of the file if "
5382 "I<len> is 0) within the file referred to by I<fd>.  The I<advice> is not "
5383 "binding; it merely constitutes an expectation on behalf of the application."
5384 msgstr ""
5385 "I<advice> は I<fd> が参照しているファイルの I<offset> から始まる I<len> バイ\n"
5386 "トの範囲内 (I<len> が 0 の場合はファイルの終りまで) の (必ずしも存在しない)\n"
5387 "領域に適用される。 I<advice> は義務づけではない。 I<advice> は単にアプリケー\n"
5388 "ションのために可能性を構成するだけである。"
5389
5390 #. type: Plain text
5391 #: build/C/man2/posix_fadvise.2:64
5392 msgid "Permissible values for I<advice> include:"
5393 msgstr "I<advice> に許される値には、以下のものが含まれる:"
5394
5395 #. type: TP
5396 #: build/C/man2/posix_fadvise.2:64
5397 #, no-wrap
5398 msgid "B<POSIX_FADV_NORMAL>"
5399 msgstr "B<POSIX_FADV_NORMAL>"
5400
5401 #. type: Plain text
5402 #: build/C/man2/posix_fadvise.2:70
5403 msgid ""
5404 "Indicates that the application has no advice to give about its access "
5405 "pattern for the specified data.  If no advice is given for an open file, "
5406 "this is the default assumption."
5407 msgstr ""
5408 "指定されたデータのアクセスパターンを指示するアドバイスを アプリケーションが何"
5409 "も持っていないことを示す。 オープンされたファイルにアドバイスが指定されない場"
5410 "合、 これがデフォルトで仮定される。"
5411
5412 #. type: TP
5413 #: build/C/man2/posix_fadvise.2:70
5414 #, no-wrap
5415 msgid "B<POSIX_FADV_SEQUENTIAL>"
5416 msgstr "B<POSIX_FADV_SEQUENTIAL>"
5417
5418 #. type: Plain text
5419 #: build/C/man2/posix_fadvise.2:74
5420 msgid ""
5421 "The application expects to access the specified data sequentially (with "
5422 "lower offsets read before higher ones)."
5423 msgstr ""
5424 "アプリケーションは指定されたデータがシーケンシャルに (大きなオフセットの前に"
5425 "小さなオフセットのデータを読むように)  アクセスされることを期待する。"
5426
5427 #. type: TP
5428 #: build/C/man2/posix_fadvise.2:74
5429 #, no-wrap
5430 msgid "B<POSIX_FADV_RANDOM>"
5431 msgstr "B<POSIX_FADV_RANDOM>"
5432
5433 #. type: Plain text
5434 #: build/C/man2/posix_fadvise.2:77
5435 msgid "The specified data will be accessed in random order."
5436 msgstr "指定されたデータがランダムな順番でアクセスされる。"
5437
5438 #. type: TP
5439 #: build/C/man2/posix_fadvise.2:77
5440 #, no-wrap
5441 msgid "B<POSIX_FADV_NOREUSE>"
5442 msgstr "B<POSIX_FADV_NOREUSE>"
5443
5444 #. type: Plain text
5445 #: build/C/man2/posix_fadvise.2:80
5446 msgid "The specified data will be accessed only once."
5447 msgstr "指定されたデータは 1 度しかアクセスされない。"
5448
5449 #. type: TP
5450 #: build/C/man2/posix_fadvise.2:80
5451 #, no-wrap
5452 msgid "B<POSIX_FADV_WILLNEED>"
5453 msgstr "B<POSIX_FADV_WILLNEED>"
5454
5455 #. type: Plain text
5456 #: build/C/man2/posix_fadvise.2:83
5457 msgid "The specified data will be accessed in the near future."
5458 msgstr "指定されたデータは近い将来アクセスされる。"
5459
5460 #. type: TP
5461 #: build/C/man2/posix_fadvise.2:83
5462 #, no-wrap
5463 msgid "B<POSIX_FADV_DONTNEED>"
5464 msgstr "B<POSIX_FADV_DONTNEED>"
5465
5466 #. type: Plain text
5467 #: build/C/man2/posix_fadvise.2:86
5468 msgid "The specified data will not be accessed in the near future."
5469 msgstr "指定されたデータは近い将来アクセスされない。"
5470
5471 #. type: Plain text
5472 #: build/C/man2/posix_fadvise.2:89
5473 msgid "On success, zero is returned.  On error, an error number is returned."
5474 msgstr "成功した場合は 0 が返される。 失敗した場合はエラー番号が返される。"
5475
5476 #. type: Plain text
5477 #: build/C/man2/posix_fadvise.2:93
5478 msgid "The I<fd> argument was not a valid file descriptor."
5479 msgstr "I<fd> 引き数が有効なファイルディスクリプタでない。"
5480
5481 #. type: Plain text
5482 #: build/C/man2/posix_fadvise.2:96
5483 msgid "An invalid value was specified for I<advice>."
5484 msgstr "無効な値が I<advice> に指定された。"
5485
5486 #. type: Plain text
5487 #: build/C/man2/posix_fadvise.2:103
5488 msgid ""
5489 "The specified file descriptor refers to a pipe or FIFO.  (Linux actually "
5490 "returns B<EINVAL> in this case.)"
5491 msgstr ""
5492 "指定されたファイルディスクリプタがパイプまたは FIFO を参照している (この場"
5493 "合、Linux は実際には B<EINVAL> を返す)。"
5494
5495 #.  of fadvise64_64()
5496 #. type: Plain text
5497 #: build/C/man2/posix_fadvise.2:111
5498 msgid ""
5499 "Kernel support first appeared in Linux 2.5.60; the underlying system call is "
5500 "called B<fadvise64>().  Library support has been provided since glibc "
5501 "version 2.2, via the wrapper function B<posix_fadvise>()."
5502 msgstr ""
5503 "カーネルによるサポートは Linux 2.5.60 で最初に登場し、\n"
5504 "対応するシステムコールは B<fadvise64>() という名前である。\n"
5505 "ライブラリによるサポートは glibc バージョン 2.2 以降で提供されており、\n"
5506 "ラッパー関数は B<posix_fadvise>() という名前である。"
5507
5508 #. type: Plain text
5509 #: build/C/man2/posix_fadvise.2:120
5510 msgid ""
5511 "POSIX.1-2001.  Note that the type of the I<len> argument was changed from "
5512 "I<size_t> to I<off_t> in POSIX.1-2003 TC1."
5513 msgstr ""
5514 "POSIX.1-2001.  I<len> 引き数の型が POSIX.1-2003 TC1 において I<size_t> から "
5515 "I<off_t> に変更された点に注意すること。"
5516
5517 #. type: Plain text
5518 #: build/C/man2/posix_fadvise.2:126
5519 msgid ""
5520 "Under Linux, B<POSIX_FADV_NORMAL> sets the readahead window to the default "
5521 "size for the backing device; B<POSIX_FADV_SEQUENTIAL> doubles this size, and "
5522 "B<POSIX_FADV_RANDOM> disables file readahead entirely.  These changes affect "
5523 "the entire file, not just the specified region (but other open file handles "
5524 "to the same file are unaffected)."
5525 msgstr ""
5526 "Linux では、B<POSIX_FADV_NORMAL> はバッキングデバイスの デフォルトサイズに先"
5527 "読み (readahead) ウインドウを設定する。 B<POSIX_FADV_SEQUENTIAL> はこのサイズ"
5528 "を 2 倍し、 B<POSIX_FADV_RANDOM> は先読みを全く無効にする。 これらの変更は"
5529 "ファイル全体に影響し、指定された領域のみに影響するわけではない (しかし同じ"
5530 "ファイルに対する他のオープンファイルハンドルは影響を受けない)。"
5531
5532 #. type: Plain text
5533 #: build/C/man2/posix_fadvise.2:133
5534 msgid ""
5535 "B<POSIX_FADV_WILLNEED> initiates a nonblocking read of the specified region "
5536 "into the page cache.  The amount of data read may be decreased by the kernel "
5537 "depending on virtual memory load.  (A few megabytes will usually be fully "
5538 "satisfied, and more is rarely useful.)"
5539 msgstr ""
5540 "B<POSIX_FADV_WILLNEED> は、 ページキャッシュに指定領域のブロックされない読み"
5541 "込みを開始する。 読み込まれるデータの総量は、 仮想メモリの負荷に依ってカーネ"
5542 "ルが減らすかもしれない (数メガバイトであれば通常は全く十分であり、 それより多"
5543 "くてもめったに役に立たない)。"
5544
5545 #. type: Plain text
5546 #: build/C/man2/posix_fadvise.2:137
5547 msgid ""
5548 "In kernels before 2.6.18, B<POSIX_FADV_NOREUSE> had the same semantics as "
5549 "B<POSIX_FADV_WILLNEED>.  This was probably a bug; since kernel 2.6.18, this "
5550 "flag is a no-op."
5551 msgstr ""
5552 "2.6.18 より前のカーネルでは、B<POSIX_FADV_NOREUSE> は B<POSIX_FADV_WILLNEED> "
5553 "と同じ意味であった。 これは多分バグであった。 カーネル 2.6.18 以降では、この"
5554 "フラグは何も行わない。"
5555
5556 #. type: Plain text
5557 #: build/C/man2/posix_fadvise.2:145
5558 msgid ""
5559 "B<POSIX_FADV_DONTNEED> attempts to free cached pages associated with the "
5560 "specified region.  This is useful, for example, while streaming large "
5561 "files.  A program may periodically request the kernel to free cached data "
5562 "that has already been used, so that more useful cached pages are not "
5563 "discarded instead."
5564 msgstr ""
5565 "B<POSIX_FADV_DONTNEED> は指定された領域に関連付けられた キャッシュページを解"
5566 "放しようとする。 例えば、これは大きなファイルをストリーミングするときに役立"
5567 "つ。 プログラムは、使用済みのキャッシュされたデータを解放するように、 定期的"
5568 "にカーネルに要求するかもしれない。 そうすることにより、さらに有効なキャッシュ"
5569 "されたページが、 代わりに破棄されることはない。"
5570
5571 #. type: Plain text
5572 #: build/C/man2/posix_fadvise.2:153
5573 msgid ""
5574 "Pages that have not yet been written out will be unaffected, so if the "
5575 "application wishes to guarantee that pages will be released, it should call "
5576 "B<fsync>(2)  or B<fdatasync>(2)  first."
5577 msgstr ""
5578 "まだ書き出されていないページは影響を受けないので、 そのページの解放が保証され"
5579 "ることをアプリケーションが望んでいるなら、 最初に B<fsync>(2)  または "
5580 "B<fdatasync>(2)  を呼ぶべきである。"
5581
5582 #. type: SS
5583 #: build/C/man2/posix_fadvise.2:153
5584 #, no-wrap
5585 msgid "arm_fadvise()"
5586 msgstr "arm_fadvise()"
5587
5588 #. type: Plain text
5589 #: build/C/man2/posix_fadvise.2:165
5590 msgid ""
5591 "The ARM architecture needs 64-bit arguments to be aligned in a suitable pair "
5592 "of registers.  On this architecture, the call signature of B<posix_fadvise>"
5593 "()  is flawed, since it forces a register to be wasted as padding between "
5594 "the I<fd> and I<len> arguments.  Therefore, since Linux 2.6.14, ARM defines "
5595 "a different system call that orders the arguments suitably:"
5596 msgstr ""
5597
5598 #. type: Plain text
5599 #: build/C/man2/posix_fadvise.2:170
5600 #, no-wrap
5601 msgid ""
5602 "B<long arm_fadvise64_64(int >I<fd>B<, int >I<advice>B<,>\n"
5603 "B<                      loff_t >I<offset>B<, loff_t >I<len>B<);>\n"
5604 msgstr ""
5605 "B<long arm_fadvise64_64(int >I<fd>B<, int >I<advice>B<,>\n"
5606 "B<                      loff_t >I<offset>B<, loff_t >I<len>B<);>\n"
5607
5608 #.  No ARM support in glibc.
5609 #. type: Plain text
5610 #: build/C/man2/posix_fadvise.2:177
5611 msgid ""
5612 "The behavior of this system call is otherwise exactly the same as "
5613 "B<posix_fadvise>().  No library support is provided for this system call in "
5614 "glibc."
5615 msgstr ""
5616
5617 #. type: Plain text
5618 #: build/C/man2/posix_fadvise.2:182
5619 msgid ""
5620 "In kernels before 2.6.6, if I<len> was specified as 0, then this was "
5621 "interpreted literally as \"zero bytes\", rather than as meaning \"all bytes "
5622 "through to the end of the file\"."
5623 msgstr ""
5624 "2.6.6 より前のカーネルでは、 I<len> に 0 が指定された場合、 「ファイルの終り"
5625 "までの全てのバイト」という意味ではなく、 文字通り「0 バイト」として解釈されて"
5626 "いた。"
5627
5628 #. type: Plain text
5629 #: build/C/man2/posix_fadvise.2:186
5630 msgid ""
5631 "B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3), "
5632 "B<posix_madvise>(3)"
5633 msgstr ""
5634 "B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3),\n"
5635 "B<posix_madvise>(3)"
5636
5637 #. type: TH
5638 #: build/C/man3/posix_fallocate.3:23
5639 #, no-wrap
5640 msgid "POSIX_FALLOCATE"
5641 msgstr "POSIX_FALLOCATE"
5642
5643 #. type: TH
5644 #: build/C/man3/posix_fallocate.3:23
5645 #, no-wrap
5646 msgid "2010-09-20"
5647 msgstr "2010-09-20"
5648
5649 #. type: Plain text
5650 #: build/C/man3/posix_fallocate.3:26
5651 msgid "posix_fallocate - allocate file space"
5652 msgstr "posix_fallocate - ファイルのスペースを確保する"
5653
5654 #. type: Plain text
5655 #: build/C/man3/posix_fallocate.3:31
5656 #, no-wrap
5657 msgid "B<int posix_fallocate(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
5658 msgstr "B<int posix_fallocate(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
5659
5660 #. type: Plain text
5661 #: build/C/man3/posix_fallocate.3:40
5662 msgid "B<posix_fallocate>():"
5663 msgstr "B<posix_fallocate>():"
5664
5665 #. type: Plain text
5666 #: build/C/man3/posix_fallocate.3:59
5667 msgid ""
5668 "The function B<posix_fallocate>()  ensures that disk space is allocated for "
5669 "the file referred to by the descriptor I<fd> for the bytes in the range "
5670 "starting at I<offset> and continuing for I<len> bytes.  After a successful "
5671 "call to B<posix_fallocate>(), subsequent writes to bytes in the specified "
5672 "range are guaranteed not to fail because of lack of disk space."
5673 msgstr ""
5674 "関数 B<posix_fallocate>()  は、ディスクリプタ I<fd> で参照されるファイルに対"
5675 "して、ディスクスペースを確実に確保する。 ディスクスペースは I<offset> から始"
5676 "まる I<len> バイトの範囲のバイトである。 B<posix_fallocate>()  の呼び出しが成"
5677 "功した後、指定された範囲のバイトに対する書き込みは、 ディスクスペースの不足で"
5678 "失敗しないことが保証される。"
5679
5680 #. type: Plain text
5681 #: build/C/man3/posix_fallocate.3:64
5682 msgid ""
5683 "If the size of the file is less than I<offset>+I<len>, then the file is "
5684 "increased to this size; otherwise the file size is left unchanged."
5685 msgstr ""
5686 "ファイルのサイズが I<offset>+I<len> より小さい場合、ファイルはこのサイズにな"
5687 "るように拡大される。 それ以外の場合、ファイルサイズは変わらない。"
5688
5689 #. type: Plain text
5690 #: build/C/man3/posix_fallocate.3:70
5691 msgid ""
5692 "B<posix_fallocate>()  returns zero on success, or an error number on "
5693 "failure.  Note that I<errno> is not set."
5694 msgstr ""
5695 "B<posix_fallocate>()  は成功した場合、0 を返す。 失敗した場合、エラー番号を返"
5696 "す。 I<errno> が設定されない点に注意すること。"
5697
5698 #. type: Plain text
5699 #: build/C/man3/posix_fallocate.3:79
5700 msgid "I<offset+len> exceeds the maximum file size."
5701 msgstr "I<offset+len> が最大ファイルサイズを超えている。"
5702
5703 #. type: Plain text
5704 #: build/C/man3/posix_fallocate.3:89
5705 msgid "I<fd> does not refer to a regular file."
5706 msgstr "I<fd> が通常のファイルとして参照されていない。"
5707
5708 #. type: Plain text
5709 #: build/C/man3/posix_fallocate.3:98
5710 msgid "I<fd> refers to a pipe."
5711 msgstr "I<fd> がパイプを参照している。"
5712
5713 #. type: Plain text
5714 #: build/C/man3/posix_fallocate.3:101
5715 msgid "B<posix_fallocate>()  is available since glibc 2.1.94."
5716 msgstr "B<posix_fallocate>()  は glibc 2.1.94 以降で利用可能である。"
5717
5718 #. type: Plain text
5719 #: build/C/man3/posix_fallocate.3:126
5720 msgid ""
5721 "POSIX.1-2008 says that an implementation I<shall> give the B<EINVAL> error "
5722 "if I<len> was 0, or I<offset> was less than 0.  POSIX.1-2001 says that an "
5723 "implementation I<shall> give the B<EINVAL> error if I<len> is less than 0, "
5724 "or I<offset> was less than 0, and I<may> give the error if I<len> equals "
5725 "zero."
5726 msgstr ""
5727 "POSIX.1-2008 では、 I<len> が 0 の場合、もしくは I<offset> が 0 未満の場合、 "
5728 "B<EINVAL> エラーを返すものとされている。 POSIX.1-2001 では、 I<len> が 0 未満"
5729 "の場合、もしくは I<offset> が 0 未満の場合、 B<EINVAL> エラーを返すものとされ"
5730 "ている。また、 I<len> が 0 の場合、 B<EINVAL> エラーを返してもよいとされてい"
5731 "る。"
5732
5733 #. type: Plain text
5734 #: build/C/man3/posix_fallocate.3:129
5735 msgid "B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
5736 msgstr "B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
5737
5738 #. type: TH
5739 #: build/C/man3/posix_memalign.3:28
5740 #, no-wrap
5741 msgid "POSIX_MEMALIGN"
5742 msgstr "POSIX_MEMALIGN"
5743
5744 #. type: TH
5745 #: build/C/man3/posix_memalign.3:28
5746 #, no-wrap
5747 msgid "2012-03-23"
5748 msgstr "2012-03-23"
5749
5750 #. type: Plain text
5751 #: build/C/man3/posix_memalign.3:31
5752 msgid ""
5753 "posix_memalign, aligned_alloc, memalign, valloc, pvalloc - Allocate aligned "
5754 "memory"
5755 msgstr ""
5756 "posix_memalign, aligned_alloc, memalign, valloc, pvalloc - アラインメント\n"
5757 "されたメモリの割り当てを行う"
5758
5759 #. type: Plain text
5760 #: build/C/man3/posix_memalign.3:34 build/C/man3/malloc_get_state.3:29
5761 #, no-wrap
5762 msgid "B<#include E<lt>stdlib.hE<gt>>\n"
5763 msgstr "B<#include E<lt>stdlib.hE<gt>>\n"
5764
5765 #. type: Plain text
5766 #: build/C/man3/posix_memalign.3:38
5767 #, no-wrap
5768 msgid ""
5769 "B<int posix_memalign(void **>I<memptr>B<, size_t >I<alignment>B<, size_t >I<size>B<);>\n"
5770 "B<void *aligned_alloc(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
5771 "B<void *valloc(size_t >I<size>B<);>\n"
5772 msgstr ""
5773 "B<int posix_memalign(void **>I<memptr>B<, size_t >I<alignment>B<, size_t >I<size>B<);>\n"
5774 "B<void *aligned_alloc(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
5775 "B<void *valloc(size_t >I<size>B<);>\n"
5776
5777 #. type: Plain text
5778 #: build/C/man3/posix_memalign.3:43
5779 #, no-wrap
5780 msgid ""
5781 "B<void *memalign(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
5782 "B<void *pvalloc(size_t >I<size>B<);>\n"
5783 msgstr ""
5784 "B<void *memalign(size_t >I<alignment>B<, size_t >I<size>B<);>\n"
5785 "B<void *pvalloc(size_t >I<size>B<);>\n"
5786
5787 #. type: Plain text
5788 #: build/C/man3/posix_memalign.3:53
5789 msgid ""
5790 "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
5791 "E<gt>=\\ 600"
5792 msgstr ""
5793 "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
5794 "E<gt>=\\ 600"
5795
5796 #. type: Plain text
5797 #: build/C/man3/posix_memalign.3:56
5798 msgid "B<aligned_alloc>(): _ISOC11_SOURCE"
5799 msgstr "B<aligned_alloc>(): _ISOC11_SOURCE"
5800
5801 #. type: Plain text
5802 #: build/C/man3/posix_memalign.3:58
5803 msgid "B<valloc>():"
5804 msgstr "B<valloc>():"
5805
5806 #. type: TP
5807 #: build/C/man3/posix_memalign.3:61
5808 #, no-wrap
5809 msgid "Since glibc 2.12:"
5810 msgstr "glibc 2.12 以降:"
5811
5812 #. type: Plain text
5813 #: build/C/man3/posix_memalign.3:68
5814 #, no-wrap
5815 msgid ""
5816 "_BSD_SOURCE ||\n"
5817 "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
5818 "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
5819 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
5820 msgstr ""
5821 "_BSD_SOURCE ||\n"
5822 "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
5823 "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
5824 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
5825
5826 #. type: TP
5827 #: build/C/man3/posix_memalign.3:70
5828 #, no-wrap
5829 msgid "Before glibc 2.12:"
5830 msgstr "glibc 2.12 より前:"
5831
5832 #. type: Plain text
5833 #: build/C/man3/posix_memalign.3:74
5834 msgid ""
5835 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
5836 "_XOPEN_SOURCE_EXTENDED"
5837 msgstr ""
5838 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
5839 "_XOPEN_SOURCE_EXTENDED"
5840
5841 #. type: Plain text
5842 #: build/C/man3/posix_memalign.3:81
5843 msgid ""
5844 "(The (nonstandard) header file I<E<lt>malloc.hE<gt>> also exposes the "
5845 "declaration of B<valloc>(); no feature test macros are required.)"
5846 msgstr ""
5847 "((非標準の) ヘッダファイル I<E<lt>malloc.hE<gt>> も\n"
5848 "B<valloc>() の宣言も公開する。機能検査マクロは不要である。"
5849
5850 #.  glibc does this:
5851 #. type: Plain text
5852 #: build/C/man3/posix_memalign.3:102
5853 msgid ""
5854 "The function B<posix_memalign>()  allocates I<size> bytes and places the "
5855 "address of the allocated memory in I<*memptr>.  The address of the allocated "
5856 "memory will be a multiple of I<alignment>, which must be a power of two and "
5857 "a multiple of I<sizeof(void *)>.  If I<size> is 0, then B<posix_memalign>()  "
5858 "returns either NULL, or a unique pointer value that can later be "
5859 "successfully passed to B<free>(3)."
5860 msgstr ""
5861 "関数 B<posix_memalign>()  は、 I<size> バイトのメモリを割り当て、割り当てられ"
5862 "たメモリのアドレスを I<*memptr> に設定する。 割り当てられたメモリのアドレス"
5863 "は I<alignment> の倍数になっているはずである。 I<alignment> は 2 のべき乗で、"
5864 "かつ I<sizeof(void *)> の倍数でなければならない。 I<size> が 0 の場合、 "
5865 "B<posix_memalign>()  は NULL か一意なポインタ値を返す。 このポインタ値は、後"
5866 "で B<free>(3)  に問題なく渡すことができる。"
5867
5868 #.  The behavior of memalign() for size==0 is as for posix_memalign()
5869 #.  but no standards govern this.
5870 #. type: Plain text
5871 #: build/C/man3/posix_memalign.3:113
5872 msgid ""
5873 "The obsolete function B<memalign>()  allocates I<size> bytes and returns a "
5874 "pointer to the allocated memory.  The memory address will be a multiple of "
5875 "I<alignment>, which must be a power of two."
5876 msgstr ""
5877 "廃止された関数である B<memalign>() は、 I<size> バイトのメモリを割り当て、\n"
5878 "割り当てられたメモリへのポインタを返す。 メモリのアドレスは I<alignment> \n"
5879 "の倍数になっているはずである。 I<alignment> は 2 のべき乗でなければならない。"
5880
5881 #. type: Plain text
5882 #: build/C/man3/posix_memalign.3:122
5883 msgid ""
5884 "The function B<aligned_alloc>()  is the same as B<memalign>(), except for "
5885 "the added restriction that I<size> should be a multiple of I<alignment>."
5886 msgstr ""
5887 "関数 B<aligned_alloc>() は B<memalign>() と同じだが、I<size> が I<alignment>\n"
5888 "の倍数でなければならないという追加の制限がある点が異なる。"
5889
5890 #. type: Plain text
5891 #: build/C/man3/posix_memalign.3:132
5892 msgid ""
5893 "The obsolete function B<valloc>()  allocates I<size> bytes and returns a "
5894 "pointer to the allocated memory.  The memory address will be a multiple of "
5895 "the page size.  It is equivalent to I<memalign(sysconf(_SC_PAGESIZE),size)>."
5896 msgstr ""
5897 "廃止された関数である B<valloc>()  は I<size> バイトのメモリを割り当て、割り当"
5898 "てられたメモリへのポインタを返す。 メモリのアドレスはページサイズの倍数になっ"
5899 "ているはずである。 これは I<memalign(sysconf(_SC_PAGESIZE),size)> と等価であ"
5900 "る。"
5901
5902 #. type: Plain text
5903 #: build/C/man3/posix_memalign.3:139
5904 msgid ""
5905 "The obsolete function B<pvalloc>()  is similar to B<valloc>(), but rounds "
5906 "the size of the allocation up to the next multiple of the system page size."
5907 msgstr ""
5908 "廃止された関数 B<pvalloc>() は B<valloc>() と同様だが、\n"
5909 "割り当てられるサイズがシステムのページサイズの倍数に切り上げられる。"
5910
5911 #. type: Plain text
5912 #: build/C/man3/posix_memalign.3:141
5913 msgid "For all of these functions, the memory is not zeroed."
5914 msgstr "これらの関数はいずれもメモリのゼロクリアを行わない。"
5915
5916 #. type: Plain text
5917 #: build/C/man3/posix_memalign.3:148
5918 msgid ""
5919 "B<aligned_alloc>(), B<memalign>(), B<valloc>(), and B<pvalloc>()  return a "
5920 "pointer to the allocated memory, or NULL if the request fails."
5921 msgstr ""
5922 "B<aligned_alloc>(), B<memalign>(), B<valloc>(), B<pvalloc>() は割り当てられた\n"
5923 "メモリへのポインタを返す。 割り当てに失敗した場合は NULL を返す。"
5924
5925 #. type: Plain text
5926 #: build/C/man3/posix_memalign.3:155
5927 msgid ""
5928 "B<posix_memalign>()  returns zero on success, or one of the error values "
5929 "listed in the next section on failure.  Note that I<errno> is not set."
5930 msgstr ""
5931 "B<posix_memalign>()  は成功した場合は 0 を返し、 失敗した場合は次のセクション"
5932 "に記載されたエラー値のいずれかを返す。 I<errno> はセットされないことに注意す"
5933 "ること。"
5934
5935 #. type: Plain text
5936 #: build/C/man3/posix_memalign.3:162
5937 msgid ""
5938 "The I<alignment> argument was not a power of two, or was not a multiple of "
5939 "I<sizeof(void *)>."
5940 msgstr ""
5941 "I<alignment> 引き数が 2 のべき乗でなかったか、 I<sizeof(void *)> の倍数でな"
5942 "かった。"
5943
5944 #. type: Plain text
5945 #: build/C/man3/posix_memalign.3:165
5946 msgid "There was insufficient memory to fulfill the allocation request."
5947 msgstr "割り当て要求を満たすのに十分なメモリがなかった。"
5948
5949 #. type: Plain text
5950 #: build/C/man3/posix_memalign.3:172
5951 msgid ""
5952 "The functions B<memalign>(), B<valloc>(), and B<pvalloc>()  have been "
5953 "available in all Linux libc libraries."
5954 msgstr ""
5955 "関数 B<memalign>(), B<valloc>(), B<pvalloc>() は\n"
5956 "すべての Linux libc ライブラリで使用可能である。"
5957
5958 #. type: Plain text
5959 #: build/C/man3/posix_memalign.3:176
5960 msgid "The function B<aligned_alloc>()  was added to glibc in version 2.16."
5961 msgstr "関数 B<aligned_alloc>() は glibc バージョン 2.16 で追加された。"
5962
5963 #. type: Plain text
5964 #: build/C/man3/posix_memalign.3:180
5965 msgid "The function B<posix_memalign>()  is available since glibc 2.1.91."
5966 msgstr "関数 B<posix_fallocate>() は glibc 2.1.91 以降で利用可能である。"
5967
5968 #. type: Plain text
5969 #: build/C/man3/posix_memalign.3:187
5970 msgid ""
5971 "The function B<valloc>()  appeared in 3.0BSD.  It is documented as being "
5972 "obsolete in 4.3BSD, and as legacy in SUSv2.  It does not appear in "
5973 "POSIX.1-2001."
5974 msgstr ""
5975 "関数 B<valloc>() は 3.0BSD で登場した。4.3BSD では廃止されたと記載されており、\n"
5976 "SUSv2 では過去の名残だと記載されている。 POSIX.1-2001 には存在しない。"
5977
5978 #. type: Plain text
5979 #: build/C/man3/posix_memalign.3:191
5980 msgid "The function B<pvalloc>()  is a GNU extension."
5981 msgstr "関数 B<pvalloc>() は GNU による拡張である。"
5982
5983 #. type: Plain text
5984 #: build/C/man3/posix_memalign.3:195
5985 msgid "The function B<memalign>()  appears in SunOS 4.1.3 but not in 4.4BSD."
5986 msgstr "関数 B<memalign>() は SunOS 4.1.3 で登場したが、4.4BSD にはない。"
5987
5988 #. type: Plain text
5989 #: build/C/man3/posix_memalign.3:199
5990 msgid "The function B<posix_memalign>()  comes from POSIX.1d."
5991 msgstr "関数 B<posix_memalign>() は POSIX.1d に由来する。"
5992
5993 #. type: Plain text
5994 #: build/C/man3/posix_memalign.3:204
5995 msgid "The function I<aligned_alloc ()> is specified in the C11 standard."
5996 msgstr "関数 I<aligned_alloc ()> は C11 標準で規定されている。"
5997
5998 #. type: SS
5999 #: build/C/man3/posix_memalign.3:204
6000 #, no-wrap
6001 msgid "Headers"
6002 msgstr "ヘッダ"
6003
6004 #. type: Plain text
6005 #: build/C/man3/posix_memalign.3:208
6006 msgid ""
6007 "Everybody agrees that B<posix_memalign>()  is declared in I<E<lt>stdlib."
6008 "hE<gt>>."
6009 msgstr ""
6010 "B<posix_memalign>()  の宣言を I<E<lt>stdlib.hE<gt>> で行うことに関しては、 皆"
6011 "の意見が一致している。"
6012
6013 #. type: Plain text
6014 #: build/C/man3/posix_memalign.3:212
6015 msgid ""
6016 "On some systems B<memalign>()  is declared in I<E<lt>stdlib.hE<gt>> instead "
6017 "of I<E<lt>malloc.hE<gt>>."
6018 msgstr ""
6019 "いくつかのシステムでは、 B<memalign>()  は I<E<lt>malloc.hE<gt>> ではなく "
6020 "I<E<lt>stdlib.hE<gt>> で宣言されている。"
6021
6022 #. type: Plain text
6023 #: build/C/man3/posix_memalign.3:219
6024 msgid ""
6025 "According to SUSv2, B<valloc>()  is declared in I<E<lt>stdlib.hE<gt>>.  "
6026 "Libc4,5 and glibc declare it in I<E<lt>malloc.hE<gt>>, and also in "
6027 "I<E<lt>stdlib.hE<gt>> if suitable feature test macros are defined (see "
6028 "above)."
6029 msgstr ""
6030 "SUSv2 によると、 B<valloc>() は I<E<lt>stdlib.hE<gt>> で宣言される。 libc4,5\n"
6031 "や glibc では I<E<lt>malloc.hE<gt>> で宣言されており、 さらに適切な機能検査\n"
6032 "マクロが定義された場合には I<E<lt>stdlib.hE<gt>> でも宣言される(上記を参照)。"
6033
6034 #. type: Plain text
6035 #: build/C/man3/posix_memalign.3:228
6036 msgid ""
6037 "On many systems there are alignment restrictions, for example, on buffers "
6038 "used for direct block device I/O.  POSIX specifies the I<pathconf(path,"
6039 "_PC_REC_XFER_ALIGN)> call that tells what alignment is needed.  Now one can "
6040 "use B<posix_memalign>()  to satisfy this requirement."
6041 msgstr ""
6042 "多くのシステムでは、アラインメントに関して制限がある。例えば、 ブロックデバイ"
6043 "スに対するダイレクト I/O に使用するバッファには アラインメントに関する制限が"
6044 "ある。 POSIX では、どんなアラインメントが必要かを知るために I<pathconf(path,"
6045 "_PC_REC_XFER_ALIGN)> コールを規定している。ここで B<posix_memalign>()  を使う"
6046 "と、この必要条件を満たすことができる。"
6047
6048 #. type: Plain text
6049 #: build/C/man3/posix_memalign.3:237
6050 msgid ""
6051 "B<posix_memalign>()  verifies that I<alignment> matches the requirements "
6052 "detailed above.  B<memalign>()  may not check that the I<alignment> argument "
6053 "is correct."
6054 msgstr ""
6055 "B<posix_memalign>() は I<alignment> が上で詳細に述べた必要条件を満たすか\n"
6056 "どうかを確かめる。 B<memalign>() は I<alignment> 引き数が正しいかどうかの\n"
6057 "確認を行わないかもしれない。"
6058
6059 #.  Other systems allow passing the result of
6060 #.  .IR valloc ()
6061 #.  to
6062 #.  .IR free (3),
6063 #.  but not to
6064 #.  .IR realloc (3).
6065 #. type: Plain text
6066 #: build/C/man3/posix_memalign.3:265
6067 msgid ""
6068 "POSIX requires that memory obtained from B<posix_memalign>()  can be freed "
6069 "using B<free>(3).  Some systems provide no way to reclaim memory allocated "
6070 "with B<memalign>()  or B<valloc>()  (because one can only pass to B<free>"
6071 "(3)  a pointer gotten from B<malloc>(3), while, for example, B<memalign>()  "
6072 "would call B<malloc>(3)  and then align the obtained value).  The glibc "
6073 "implementation allows memory obtained from any of these these functions to "
6074 "be reclaimed with B<free>(3)."
6075 msgstr ""
6076 "POSIX では B<posix_memalign>() によって獲得したメモリは B<free>(3) を使って\n"
6077 "解放することができる必要がある。 いくつかのシステムでは B<memalign>() や\n"
6078 "B<valloc>() で割り当てられたメモリを再利用する手段が提供されていない。\n"
6079 "(なぜなら B<free>(3) に渡すことができるのは B<malloc>(3) から受け取った\n"
6080 "ポインタだけだが、 例えば B<memalign>() は B<malloc>(3) を呼び出し、\n"
6081 "得た値をアラインメントしてしまうからである) glibc の実装では、 ここに述べた\n"
6082 "関数のいずれで獲得したメモリも B<free>(3) で再利用することができる。"
6083
6084 #. type: Plain text
6085 #: build/C/man3/posix_memalign.3:270
6086 msgid ""
6087 "The glibc B<malloc>(3)  always returns 8-byte aligned memory addresses, so "
6088 "these functions are only needed if you require larger alignment values."
6089 msgstr ""
6090 "glibc の B<malloc>(3) は常に 8 バイトにアラインメントされたメモリアドレスを\n"
6091 "返すので、ここで述べた関数が必要になるのは 8 バイトよりも大きなアラインメント\n"
6092 "が必要な場合だけである。"
6093
6094 #. type: Plain text
6095 #: build/C/man3/posix_memalign.3:274
6096 msgid "B<brk>(2), B<getpagesize>(2), B<free>(3), B<malloc>(3)"
6097 msgstr "B<brk>(2), B<getpagesize>(2), B<free>(3), B<malloc>(3)"
6098
6099 #. type: TH
6100 #: build/C/man2/readahead.2:28
6101 #, no-wrap
6102 msgid "READAHEAD"
6103 msgstr "READAHEAD"
6104
6105 #. type: TH
6106 #: build/C/man2/readahead.2:28 build/C/man7/shm_overview.7:27
6107 #, no-wrap
6108 msgid "2010-09-10"
6109 msgstr "2010-09-10"
6110
6111 #. type: Plain text
6112 #: build/C/man2/readahead.2:31
6113 msgid "readahead - perform file readahead into page cache"
6114 msgstr "readahead - 前もってファイルをページ・キャッシュに読み込む"
6115
6116 #. type: Plain text
6117 #: build/C/man2/readahead.2:37
6118 #, no-wrap
6119 msgid "B<ssize_t readahead(int >I<fd>B<, off64_t >I<offset>B<, size_t >I<count>B<);>\n"
6120 msgstr "B<ssize_t readahead(int >I<fd>B<, off64_t >I<offset>B<, size_t >I<count>B<);>\n"
6121
6122 #. type: Plain text
6123 #: build/C/man2/readahead.2:65
6124 msgid ""
6125 "B<readahead>()  populates the page cache with data from a file so that "
6126 "subsequent reads from that file will not block on disk I/O.  The I<fd> "
6127 "argument is a file descriptor identifying the file which is to be read.  The "
6128 "I<offset> argument specifies the starting point from which data is to be "
6129 "read and I<count> specifies the number of bytes to be read.  I/O is "
6130 "performed in whole pages, so that I<offset> is effectively rounded down to a "
6131 "page boundary and bytes are read up to the next page boundary greater than "
6132 "or equal to I<(offset+count)>.  B<readahead>()  does not read beyond the end "
6133 "of the file.  B<readahead>()  blocks until the specified data has been "
6134 "read.  The current file offset of the open file referred to by I<fd> is left "
6135 "unchanged."
6136 msgstr ""
6137 "B<readahead>()  は、この後の同じファイルからのデータ読み込み時にディスク I/O "
6138 "で 動作が停止 (block) しないように、前もってファイルの内容を ページ・キャッ"
6139 "シュに読み込む。 I<fd> 引き数は読み込みを行うファイルを識別するファイル・ディ"
6140 "スクリプタである。 I<offset> 引き数はデータの読み込み開始位置を指定し、 "
6141 "I<count> は読み込むデータのバイト数を指定する。 ディスク I/O はページ単位で実"
6142 "行されるので、 実際には I<offset> はページ境界に切り下げられ、読み込みバイト"
6143 "数は I<(offset+count)> より小さくない次のページ境界まで切り上げられる。 "
6144 "B<readahead>()  はファイルの末尾を越えた範囲まで読み出しを行うことはない。ま"
6145 "た、 B<readahead>()  は指定したデータの読み込みが終わるまで停止 (block) す"
6146 "る。 I<fd> で参照されたオープン済のファイルのファイルオフセットの現在値は 変"
6147 "更されない。"
6148
6149 #. type: Plain text
6150 #: build/C/man2/readahead.2:71
6151 msgid ""
6152 "On success, B<readahead>()  returns 0; on failure, -1 is returned, with "
6153 "I<errno> set to indicate the cause of the error."
6154 msgstr ""
6155 "B<readahead>()  は成功すると 0 を返す。失敗した場合 -1 を返し、 I<errno> にエ"
6156 "ラーの原因を示す値を設定する。"
6157
6158 #. type: Plain text
6159 #: build/C/man2/readahead.2:76
6160 msgid "I<fd> is not a valid file descriptor or is not open for reading."
6161 msgstr ""
6162 "I<fd> が有効なファイル・ディスクリプタでない、または 読み込み用にオープンされ"
6163 "ていない。"
6164
6165 #. type: Plain text
6166 #: build/C/man2/readahead.2:82
6167 msgid ""
6168 "I<fd> does not refer to a file type to which B<readahead>()  can be applied."
6169 msgstr ""
6170 "I<fd> が参照しているファイルが、 B<readahead>()  を行うことができないタイプの"
6171 "ファイルであった。"
6172
6173 #. type: Plain text
6174 #: build/C/man2/readahead.2:87
6175 msgid ""
6176 "The B<readahead>()  system call appeared in Linux 2.4.13; glibc support has "
6177 "been provided since version 2.3."
6178 msgstr ""
6179 "B<readahead>()  システムコールは Linux 2.4.13 で登場した。 glibc でのサポート"
6180 "は glibc バージョン 2.3 以降で行われている。"
6181
6182 #. type: Plain text
6183 #: build/C/man2/readahead.2:92
6184 msgid ""
6185 "The B<readahead>()  system call is Linux-specific, and its use should be "
6186 "avoided in portable applications."
6187 msgstr ""
6188 "B<readahead>()  システムコールは Linux 固有であり、移植を考慮したプログラムで"
6189 "は 使用を避けるべきである。"
6190
6191 #. type: Plain text
6192 #: build/C/man2/readahead.2:97
6193 msgid "B<lseek>(2), B<madvise>(2), B<mmap>(2), B<posix_fadvise>(2), B<read>(2)"
6194 msgstr ""
6195 "B<lseek>(2), B<madvise>(2), B<mmap>(2), B<posix_fadvise>(2), B<read>(2)"
6196
6197 #. type: TH
6198 #: build/C/man2/remap_file_pages.2:26
6199 #, no-wrap
6200 msgid "REMAP_FILE_PAGES"
6201 msgstr "REMAP_FILE_PAGES"
6202
6203 #. type: Plain text
6204 #: build/C/man2/remap_file_pages.2:29
6205 msgid "remap_file_pages - create a nonlinear file mapping"
6206 msgstr "remap_file_pages - 非線形ファイルマッピングを作成する。"
6207
6208 #. type: Plain text
6209 #: build/C/man2/remap_file_pages.2:33
6210 #, no-wrap
6211 msgid ""
6212 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
6213 "B<#include E<lt>sys/mman.hE<gt>>\n"
6214 msgstr ""
6215 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
6216 "B<#include E<lt>sys/mman.hE<gt>>\n"
6217
6218 #. type: Plain text
6219 #: build/C/man2/remap_file_pages.2:36
6220 #, no-wrap
6221 msgid ""
6222 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
6223 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
6224 msgstr ""
6225 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
6226 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
6227
6228 #. type: Plain text
6229 #: build/C/man2/remap_file_pages.2:49
6230 msgid ""
6231 "The B<remap_file_pages>()  system call is used to create a nonlinear "
6232 "mapping, that is, a mapping in which the pages of the file are mapped into a "
6233 "nonsequential order in memory.  The advantage of using B<remap_file_pages>"
6234 "()  over using repeated calls to B<mmap>(2)  is that the former approach "
6235 "does not require the kernel to create additional VMA (Virtual Memory Area) "
6236 "data structures."
6237 msgstr ""
6238 "B<remap_file_pages>()  システムコールは非線形なマッピング、 つまりファイルの"
6239 "ページがメモリ上で連続しない順番でマップされる マッピングを作成するために使わ"
6240 "れる。 B<remap_file_pages>()  を使う方が B<mmap>(2)  を繰り返して使うより優れ"
6241 "ている点は、 前者の方法ではカーネルが VMA (Virtual Memory Area, 仮想メモリ領"
6242 "域)  データ構造体を追加で作成する必要がないことである。"
6243
6244 #. type: Plain text
6245 #: build/C/man2/remap_file_pages.2:51
6246 msgid "To create a nonlinear mapping we perform the following steps:"
6247 msgstr "非線形マッピングを作成するためには、 以下のようなステップを実行する:"
6248
6249 #. type: TP
6250 #: build/C/man2/remap_file_pages.2:51
6251 #, no-wrap
6252 msgid "1."
6253 msgstr "1."
6254
6255 #. type: Plain text
6256 #: build/C/man2/remap_file_pages.2:59
6257 msgid ""
6258 "Use B<mmap>(2)  to create a mapping (which is initially linear).  This "
6259 "mapping must be created with the B<MAP_SHARED> flag."
6260 msgstr ""
6261 "B<mmap>(2)  を使い、マッピングを作成する (このマッピングは最初は線形であ"
6262 "る)。 このマッピングは B<MAP_SHARED> フラグを指定して作成されなければならな"
6263 "い。"
6264
6265 #. type: TP
6266 #: build/C/man2/remap_file_pages.2:59
6267 #, no-wrap
6268 msgid "2."
6269 msgstr "2."
6270
6271 #. type: Plain text
6272 #: build/C/man2/remap_file_pages.2:67
6273 msgid ""
6274 "Use one or more calls to B<remap_file_pages>()  to rearrange the "
6275 "correspondence between the pages of the mapping and the pages of the file.  "
6276 "It is possible to map the same page of a file into multiple locations within "
6277 "the mapped region."
6278 msgstr ""
6279 "B<remap_file_pages>()  を 1 回以上呼び出して、 マッピングのページとファイルの"
6280 "ページの対応関係を再構成する。 ファイルの同じページをマッピング領域の複数の場"
6281 "所に マップすることが可能である。"
6282
6283 #. type: Plain text
6284 #: build/C/man2/remap_file_pages.2:78
6285 msgid ""
6286 "The I<pgoff> and I<size> arguments specify the region of the file that is to "
6287 "be relocated within the mapping: I<pgoff> is a file offset in units of the "
6288 "system page size; I<size> is the length of the region in bytes."
6289 msgstr ""
6290 "I<pgoff> と I<size> 引き数は、マッピング内で再配置されるファイルの領域を指定"
6291 "する。 I<pgoff> はファイルオフセットであり、単位はシステムのページサイズであ"
6292 "る。 I<size> は領域の長さであり、単位はバイトである。"
6293
6294 #. type: Plain text
6295 #: build/C/man2/remap_file_pages.2:96
6296 msgid ""
6297 "The I<addr> argument serves two purposes.  First, it identifies the mapping "
6298 "whose pages we want to rearrange.  Thus, I<addr> must be an address that "
6299 "falls within a region previously mapped by a call to B<mmap>(2).  Second, "
6300 "I<addr> specifies the address at which the file pages identified by I<pgoff> "
6301 "and I<size> will be placed."
6302 msgstr ""
6303 "I<addr> 引き数は 2 つの目的で使われる。 第 1 の目的は、この引き数によって再編"
6304 "成したいページの マッピングを識別することである。 よって I<addr> は B<mmap>"
6305 "(2)  の呼び出しで過去にマップされた領域内のアドレスでなければならない。 第 2 "
6306 "の目的は、 I<pgoff> と I<size> で識別されるファイルページが置かれる予定のアド"
6307 "レスを、 I<addr> によって指定することである。"
6308
6309 #.  This rounding is weird, and not consistent with the treatment of
6310 #.  the analogous arguments for munmap()/mprotect() and for mlock().
6311 #.  MTK, 14 Sep 2005
6312 #. type: Plain text
6313 #: build/C/man2/remap_file_pages.2:110
6314 msgid ""
6315 "The values specified in I<addr> and I<size> should be multiples of the "
6316 "system page size.  If they are not, then the kernel rounds I<both> values "
6317 "I<down> to the nearest multiple of the page size."
6318 msgstr ""
6319 "I<addr> と I<size> に指定する値は、システムのページサイズの倍数とすべきであ"
6320 "る。 それ以外の場合、カーネルは「両方」の値を 最も近いページサイズの倍数へ"
6321 "「切り下げる」。"
6322
6323 #. type: Plain text
6324 #: build/C/man2/remap_file_pages.2:114
6325 msgid "The I<prot> argument must be specified as 0."
6326 msgstr "I<prot> 引き数は 0 に指定されなければならない。"
6327
6328 #. type: Plain text
6329 #: build/C/man2/remap_file_pages.2:122
6330 msgid ""
6331 "The I<flags> argument has the same meaning as for B<mmap>(2), but all flags "
6332 "other than B<MAP_NONBLOCK> are ignored."
6333 msgstr ""
6334 "I<flags> 引き数は B<mmap>(2)  のものと同じ意味であるが、 B<MAP_NONBLOCK> 以外"
6335 "の全てのフラグは無視される。"
6336
6337 #. type: Plain text
6338 #: build/C/man2/remap_file_pages.2:129
6339 msgid ""
6340 "On success, B<remap_file_pages>()  returns 0.  On error, -1 is returned, and "
6341 "I<errno> is set appropriately."
6342 msgstr ""
6343 "成功した場合、 B<remap_file_pages>()  は 0 を返す。 エラーの場合、-1 が返さ"
6344 "れ、 I<errno> が適切に設定される。"
6345
6346 #. type: Plain text
6347 #: build/C/man2/remap_file_pages.2:137
6348 msgid ""
6349 "I<addr> does not refer to a valid mapping created with the B<MAP_SHARED> "
6350 "flag."
6351 msgstr ""
6352 "I<addr> が B<MAP_SHARED> フラグを指定して作成された有効なマッピングを参照して"
6353 "いない。"
6354
6355 #.  And possibly others from vma->vm_ops->populate()
6356 #. type: Plain text
6357 #: build/C/man2/remap_file_pages.2:146
6358 msgid "I<addr>, I<size>, I<prot>, or I<pgoff> is invalid."
6359 msgstr "I<addr>, I<size>, I<prot>, I<pgoff> のいずれかが不正である。"
6360
6361 #. type: Plain text
6362 #: build/C/man2/remap_file_pages.2:151
6363 msgid ""
6364 "The B<remap_file_pages>()  system call appeared in Linux 2.5.46; glibc "
6365 "support was added in version 2.3.3."
6366 msgstr ""
6367 "B<remap_file_pages>()  システムコールは Linux 2.5.46 で登場した。 glibc での"
6368 "サポートは glibc バージョン 2.3.3 で追加された。"
6369
6370 #. type: Plain text
6371 #: build/C/man2/remap_file_pages.2:155
6372 msgid "The B<remap_file_pages>()  system call is Linux-specific."
6373 msgstr "B<remap_file_pages>()  システムコールは Linux 固有のものである。"
6374
6375 #. type: Plain text
6376 #: build/C/man2/remap_file_pages.2:161
6377 msgid ""
6378 "B<getpagesize>(2), B<mmap>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), "
6379 "B<msync>(2)"
6380 msgstr ""
6381 "B<getpagesize>(2), B<mmap>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), "
6382 "B<msync>(2)"
6383
6384 #. type: TH
6385 #: build/C/man3/shm_open.3:26
6386 #, no-wrap
6387 msgid "SHM_OPEN"
6388 msgstr "SHM_OPEN"
6389
6390 #. type: TH
6391 #: build/C/man3/shm_open.3:26
6392 #, no-wrap
6393 msgid "2009-02-25"
6394 msgstr "2009-02-25"
6395
6396 #. type: Plain text
6397 #: build/C/man3/shm_open.3:29
6398 msgid ""
6399 "shm_open, shm_unlink - Create/open or unlink POSIX shared memory objects"
6400 msgstr ""
6401 "shm_open, shm_unlink - POSIX 共有メモリ・オブジェクトの作成/オープン、 削除を"
6402 "行う"
6403
6404 #. type: Plain text
6405 #: build/C/man3/shm_open.3:33
6406 msgid "B<#include E<lt>sys/stat.hE<gt>> /* For mode constants */"
6407 msgstr "B<#include E<lt>sys/stat.hE<gt>> /* mode 定数用 */"
6408
6409 #. type: Plain text
6410 #: build/C/man3/shm_open.3:35
6411 msgid "B<#include E<lt>fcntl.hE<gt>> /* For O_* constants */"
6412 msgstr "B<#include E<lt>fcntl.hE<gt>> /* O_* 定数の定義用 */"
6413
6414 #. type: Plain text
6415 #: build/C/man3/shm_open.3:37
6416 msgid ""
6417 "B<int shm_open(const char *>I<name>B<, int >I<oflag>B<, mode_t >I<mode>B<);>"
6418 msgstr ""
6419 "B<void * shm_open(const char *>I<name>B<, int >I<oflag>B<, mode_t "
6420 ">I<mode>B<);>"
6421
6422 #. type: Plain text
6423 #: build/C/man3/shm_open.3:39
6424 msgid "B<int shm_unlink(const char *>I<name>B<);>"
6425 msgstr "B<int shm_unlink(const char *>I<name>B<);>"
6426
6427 #. type: Plain text
6428 #: build/C/man3/shm_open.3:41
6429 msgid "Link with I<-lrt>."
6430 msgstr "I<-lrt> でリンクする。"
6431
6432 #. type: Plain text
6433 #: build/C/man3/shm_open.3:53
6434 msgid ""
6435 "B<shm_open>()  creates and opens a new, or opens an existing, POSIX shared "
6436 "memory object.  A POSIX shared memory object is in effect a handle which can "
6437 "be used by unrelated processes to B<mmap>(2)  the same region of shared "
6438 "memory.  The B<shm_unlink>()  function performs the converse operation, "
6439 "removing an object previously created by B<shm_open>()."
6440 msgstr ""
6441 "B<shm_open>()  は、POSIX 共有メモリ・オブジェクトを新規に作成/オープンした"
6442 "り、 すでに存在するオブジェクトをオープンしたりする。 POSIX 共有メモリ・オブ"
6443 "ジェクトは、実際には、関係のないプロセスが 共有メモリの同じ領域を B<mmap>"
6444 "(2)  するために使用することができる手段である。 B<shm_unlink>()  は、逆の操"
6445 "作、つまり以前に B<shm_open>()  で作成されたオブジェクトの削除を行う。"
6446
6447 #.  glibc allows the initial slash to be omitted, and makes
6448 #.  multiple initial slashes equivalent to a single slash.
6449 #.  This differs from the implementation of POSIX message queues.
6450 #.  glibc allows subdirectory components in the name, in which
6451 #.  case the subdirectory must exist under /dev/shm, and allow the
6452 #.  required permissions if a user wants to create a shared memory
6453 #.  object in that subdirectory.
6454 #. type: Plain text
6455 #: build/C/man3/shm_open.3:74
6456 msgid ""
6457 "The operation of B<shm_open>()  is analogous to that of B<open>(2).  I<name> "
6458 "specifies the shared memory object to be created or opened.  For portable "
6459 "use, a shared memory object should be identified by a name of the form I</"
6460 "somename>; that is, a null-terminated string of up to B<NAME_MAX> (i.e., "
6461 "255) characters consisting of an initial slash, followed by one or more "
6462 "characters, none of which are slashes."
6463 msgstr ""
6464 "B<shm_open>()  の動作は B<open>(2)  とよく似ている。 I<name> で作成したりオー"
6465 "プンしたりする共有メモリ・オブジェクトを指定する。 移植性を持たせるためには、"
6466 "共有メモリ・オブジェクトは I</somename> という形式の名前で識別し、 その名前"
6467 "は、最大で B<NAME_MAX> (すなわち 255) 文字の NULL 終端された文字列で、 スラッ"
6468 "シュで始まり、スラッシュ以外の文字が 1 文字以上続く形式 にすべきである。"
6469
6470 #. type: Plain text
6471 #: build/C/man3/shm_open.3:81
6472 msgid ""
6473 "I<oflag> is a bit mask created by ORing together exactly one of B<O_RDONLY> "
6474 "or B<O_RDWR> and any of the other flags listed here:"
6475 msgstr ""
6476 "I<oflag> はビットマスクで、 B<O_RDONLY> と B<O_RDWR> のいずれか一方と、以下に"
6477 "述べる他のフラグの論理和をとったもの を指定する。"
6478
6479 #. type: TP
6480 #: build/C/man3/shm_open.3:81
6481 #, no-wrap
6482 msgid "B<O_RDONLY>"
6483 msgstr "B<O_RDONLY>"
6484
6485 #. type: Plain text
6486 #: build/C/man3/shm_open.3:87
6487 msgid ""
6488 "Open the object for read access.  A shared memory object opened in this way "
6489 "can only be B<mmap>(2)ed for read (B<PROT_READ>) access."
6490 msgstr ""
6491 "読み出しアクセス用にオブジェクトをオープンする。 このフラグを指定してオープン"
6492 "された共有メモリ・オブジェクトは、 読み出し (B<PROT_READ>) アクセスでのみ "
6493 "B<mmap>(2)  することができる。"
6494
6495 #. type: TP
6496 #: build/C/man3/shm_open.3:87
6497 #, no-wrap
6498 msgid "B<O_RDWR>"
6499 msgstr "B<O_RDWR>"
6500
6501 #. type: Plain text
6502 #: build/C/man3/shm_open.3:90
6503 msgid "Open the object for read-write access."
6504 msgstr "読み書きアクセス用にオブジェクトをオープンする。"
6505
6506 #. type: TP
6507 #: build/C/man3/shm_open.3:90
6508 #, no-wrap
6509 msgid "B<O_CREAT>"
6510 msgstr "B<O_CREAT>"
6511
6512 #.  In truth it is actually the file system IDs on Linux, but these
6513 #.  are nearly always the same as the effective IDs.  (MTK, Jul 05)
6514 #. type: Plain text
6515 #: build/C/man3/shm_open.3:110
6516 msgid ""
6517 "Create the shared memory object if it does not exist.  The user and group "
6518 "ownership of the object are taken from the corresponding effective IDs of "
6519 "the calling process, and the object's permission bits are set according to "
6520 "the low-order 9 bits of I<mode>, except that those bits set in the process "
6521 "file mode creation mask (see B<umask>(2))  are cleared for the new object.  "
6522 "A set of macro constants which can be used to define I<mode> is listed in "
6523 "B<open>(2).  (Symbolic definitions of these constants can be obtained by "
6524 "including I<E<lt>sys/stat.hE<gt>>.)"
6525 msgstr ""
6526 "存在しない場合、共有メモリ・オブジェクトを作成する。 オブジェクトのユーザとグ"
6527 "ループの所有権は、 呼び出し元プロセスの対応する実効 ID が使われ、 オブジェク"
6528 "トの許可ビットは I<mode> の下位 9 ビットに基づいて設定される。ただし、 ファイ"
6529 "ルモード作成マスク (B<umask>(2)  参照) に設定されている値は、新規オブジェクト"
6530 "に関してはクリアされる。 I<mode> を定義するために使用できるマクロ定数(群)は "
6531 "B<open>(2)  に記載されている (これらの定数のシンボル定義は I<E<lt>sys/stat."
6532 "hE<gt>> のインクルードにより得られる)。"
6533
6534 #. type: Plain text
6535 #: build/C/man3/shm_open.3:116
6536 msgid ""
6537 "A new shared memory object initially has zero length\\(emthe size of the "
6538 "object can be set using B<ftruncate>(2).  The newly allocated bytes of a "
6539 "shared memory object are automatically initialized to 0."
6540 msgstr ""
6541 "新規に作成された共有メモリ・オブジェクトは長さ 0 で初期化される。 オブジェク"
6542 "トの大きさは B<ftruncate>(2)  を使って設定できる。 共有メモリ・オブジェクトと"
6543 "して新規に確保されたバイトは自動的に 0 に初期化される。"
6544
6545 #. type: TP
6546 #: build/C/man3/shm_open.3:116
6547 #, no-wrap
6548 msgid "B<O_EXCL>"
6549 msgstr "B<O_EXCL>"
6550
6551 #. type: Plain text
6552 #: build/C/man3/shm_open.3:125
6553 msgid ""
6554 "If B<O_CREAT> was also specified, and a shared memory object with the given "
6555 "I<name> already exists, return an error.  The check for the existence of the "
6556 "object, and its creation if it does not exist, are performed atomically."
6557 msgstr ""
6558 "B<O_CREAT> が一緒に指定されており、 I<name> で指定された共有メモリ・オブジェ"
6559 "クトが既に存在した場合、 エラーを返す。 オブジェクトの存在確認と、存在しな"
6560 "かった場合のオブジェクト作成は、 必ず一連の操作として実行される (performed "
6561 "atomically)。"
6562
6563 #. type: TP
6564 #: build/C/man3/shm_open.3:125
6565 #, no-wrap
6566 msgid "B<O_TRUNC>"
6567 msgstr "B<O_TRUNC>"
6568
6569 #. type: Plain text
6570 #: build/C/man3/shm_open.3:128
6571 msgid "If the shared memory object already exists, truncate it to zero bytes."
6572 msgstr ""
6573 "共有メモリ・オブジェクトがすでに存在した場合、 そのオブジェクトを 0 バイトに"
6574 "切り詰める。"
6575
6576 #. type: Plain text
6577 #: build/C/man3/shm_open.3:131
6578 msgid ""
6579 "Definitions of these flag values can be obtained by including I<E<lt>fcntl."
6580 "hE<gt>>."
6581 msgstr ""
6582 "これらのフラグ値の定義は I<E<lt>fcntl.hE<gt>> のインクルードにより得られる。"
6583
6584 #. type: Plain text
6585 #: build/C/man3/shm_open.3:142
6586 msgid ""
6587 "On successful completion B<shm_open>()  returns a new file descriptor "
6588 "referring to the shared memory object.  This file descriptor is guaranteed "
6589 "to be the lowest-numbered file descriptor not previously opened within the "
6590 "process.  The B<FD_CLOEXEC> flag (see B<fcntl>(2))  is set for the file "
6591 "descriptor."
6592 msgstr ""
6593 "成功して完了した場合、 B<shm_open>()  は共有メモリ・オブジェクトを参照する新"
6594 "しいファイル・ディスクリプタを返す。 このファイル・ディスクリプタは、そのプロ"
6595 "セス内で過去にオープンされていない ファイル・ディスクリプタの中で最も小さな数"
6596 "になることが保証される。 B<FD_CLOEXEC> フラグ (B<fcntl>(2)  を参照) が、この"
6597 "ファイル・ディスクリプタに設定される。"
6598
6599 #. type: Plain text
6600 #: build/C/man3/shm_open.3:151
6601 msgid ""
6602 "The file descriptor is normally used in subsequent calls to B<ftruncate>(2)  "
6603 "(for a newly created object) and B<mmap>(2).  After a call to B<mmap>(2)  "
6604 "the file descriptor may be closed without affecting the memory mapping."
6605 msgstr ""
6606 "通常、これらのファイル・ディスクリプタは、この後続けて実行される B<ftruncate>"
6607 "(2)  (新規に作成されたオブジェクトの場合のみ) と B<mmap>(2)  の呼び出しに使用"
6608 "される。 B<mmap>(2)  を呼び出した後は、ファイル・ディスクリプタをクローズして"
6609 "もよく、 クローズしてもメモリ・マッピングに影響を与えることはない。"
6610
6611 #. type: Plain text
6612 #: build/C/man3/shm_open.3:169
6613 msgid ""
6614 "The operation of B<shm_unlink>()  is analogous to B<unlink>(2): it removes a "
6615 "shared memory object name, and, once all processes have unmapped the object, "
6616 "de-allocates and destroys the contents of the associated memory region.  "
6617 "After a successful B<shm_unlink>(), attempts to B<shm_open>()  an object "
6618 "with the same I<name> will fail (unless B<O_CREAT> was specified, in which "
6619 "case a new, distinct object is created)."
6620 msgstr ""
6621 "B<shm_unlink>()  の動作は B<unlink>(2)  とよく似ている: 共有メモリ・オブジェ"
6622 "クト名を削除し、すべてのプロセスが処理対象の オブジェクトをアンマップした時点"
6623 "でオブジェクトの割り当てを解除し、 対応するメモリ領域の内容を破棄する。 "
6624 "B<shm_unlink>()  が成功した後で、同じ I<name> を持つオブジェクトに対して "
6625 "B<shm_open>()  を行うと、 (B<O_CREAT> が指定されていない場合) 失敗する。 "
6626 "(B<O_CREAT> が指定されている場合、新しく別のオブジェクトが作成される)。"
6627
6628 #. type: Plain text
6629 #: build/C/man3/shm_open.3:178
6630 msgid ""
6631 "On success, B<shm_open>()  returns a nonnegative file descriptor.  On "
6632 "failure, B<shm_open>()  returns -1.  B<shm_unlink>()  returns 0 on success, "
6633 "or -1 on error."
6634 msgstr ""
6635 "成功した場合、 B<shm_open>()  は非負のファイル・ディスクリプタを返す。 失敗し"
6636 "た場合、 B<shm_open>()  は -1 を返す。 B<shm_unlink>()  は、成功した場合 0 "
6637 "を、エラーが起こった場合 -1 を返す。"
6638
6639 #. type: Plain text
6640 #: build/C/man3/shm_open.3:185
6641 msgid ""
6642 "On failure, I<errno> is set to indicate the cause of the error.  Values "
6643 "which may appear in I<errno> include the following:"
6644 msgstr ""
6645 "失敗した場合、エラーの原因を示すため I<errno> が設定される。 I<errno> に設定"
6646 "される値は以下の通りである:"
6647
6648 #. type: Plain text
6649 #: build/C/man3/shm_open.3:190
6650 msgid "Permission to B<shm_unlink>()  the shared memory object was denied."
6651 msgstr "共有メモリオブジェクトを B<shm_unlink>()  する権限がなかった。"
6652
6653 #. type: Plain text
6654 #: build/C/man3/shm_open.3:200
6655 msgid ""
6656 "Permission was denied to B<shm_open>()  I<name> in the specified I<mode>, or "
6657 "B<O_TRUNC> was specified and the caller does not have write permission on "
6658 "the object."
6659 msgstr ""
6660 "指定された I<mode> で I<name> を B<shm_open>()  する権限がなかった。もしく"
6661 "は、 B<O_TRUNC> が指定されたが、呼び出し元にはそのオブジェクトに対する書き込"
6662 "み権限が なかった。"
6663
6664 #. type: TP
6665 #: build/C/man3/shm_open.3:200 build/C/man2/shmget.2:192
6666 #, no-wrap
6667 msgid "B<EEXIST>"
6668 msgstr "B<EEXIST>"
6669
6670 #. type: Plain text
6671 #: build/C/man3/shm_open.3:211
6672 msgid ""
6673 "Both B<O_CREAT> and B<O_EXCL> were specified to B<shm_open>()  and the "
6674 "shared memory object specified by I<name> already exists."
6675 msgstr ""
6676 "B<O_CREAT> と B<O_EXCL> の両方が B<shm_open>()  に指定されたが、 I<name> で指"
6677 "定された共有メモリ・オブジェクトが既に存在した。"
6678
6679 #. type: Plain text
6680 #: build/C/man3/shm_open.3:218
6681 msgid "The I<name> argument to B<shm_open>()  was invalid."
6682 msgstr "B<shm_open>()  に与えられた I<name> 引き数が不正であった。"
6683
6684 #. type: TP
6685 #: build/C/man3/shm_open.3:218
6686 #, no-wrap
6687 msgid "B<EMFILE>"
6688 msgstr "B<EMFILE>"
6689
6690 #. type: Plain text
6691 #: build/C/man3/shm_open.3:221
6692 msgid "The process already has the maximum number of files open."
6693 msgstr "プロセスがオープン可能なファイル数の上限にすでに達していた。"
6694
6695 #. type: TP
6696 #: build/C/man3/shm_open.3:221
6697 #, no-wrap
6698 msgid "B<ENAMETOOLONG>"
6699 msgstr "B<ENAMETOOLONG>"
6700
6701 #. type: Plain text
6702 #: build/C/man3/shm_open.3:227
6703 msgid "The length of I<name> exceeds B<PATH_MAX>."
6704 msgstr "I<name> の長さが B<PATH_MAX> を越えている。"
6705
6706 #. type: Plain text
6707 #: build/C/man3/shm_open.3:231
6708 msgid ""
6709 "The limit on the total number of files open on the system has been reached."
6710 msgstr "ファイルシステムでオープンできるファイル数の上限に達した。"
6711
6712 #. type: TP
6713 #: build/C/man3/shm_open.3:231 build/C/man3/shm_open.3:240
6714 #: build/C/man2/shmget.2:206
6715 #, no-wrap
6716 msgid "B<ENOENT>"
6717 msgstr "B<ENOENT>"
6718
6719 #. type: Plain text
6720 #: build/C/man3/shm_open.3:240
6721 msgid ""
6722 "An attempt was made to B<shm_open>()  a I<name> that did not exist, and "
6723 "B<O_CREAT> was not specified."
6724 msgstr ""
6725 "存在していない I<name> のオブジェクトを B<shm_open>()  しようとしたが、 "
6726 "B<O_CREAT> が指定されていなかった。"
6727
6728 #. type: Plain text
6729 #: build/C/man3/shm_open.3:247
6730 msgid ""
6731 "An attempt was to made to B<shm_unlink>()  a I<name> that does not exist."
6732 msgstr "存在しない I<name> のオブジェクトを B<shm_unlink>()  しようとした。"
6733
6734 #. type: Plain text
6735 #: build/C/man3/shm_open.3:249
6736 msgid "These functions are provided in glibc 2.2 and later."
6737 msgstr "これらの関数は glibc 2.2 以降で提供されている。"
6738
6739 #. type: Plain text
6740 #: build/C/man3/shm_open.3:255
6741 msgid ""
6742 "POSIX.1-2001 says that the group ownership of a newly created shared memory "
6743 "object is set to either the calling process's effective group ID or \"a "
6744 "system default group ID\"."
6745 msgstr ""
6746 "POSIX.1-2001 には、新規に作成される共有メモリオブジェクトのグループ所有権"
6747 "は、 呼び出し元プロセスの実効グループ ID か 「システムのデフォルトのグループ "
6748 "ID」 のどちらかに設定される、と書かれている。"
6749
6750 #. type: Plain text
6751 #: build/C/man3/shm_open.3:264
6752 msgid ""
6753 "POSIX leaves the behavior of the combination of B<O_RDONLY> and B<O_TRUNC> "
6754 "unspecified.  On Linux, this will successfully truncate an existing shared "
6755 "memory object\\(emthis may not be so on other UNIX systems."
6756 msgstr ""
6757 "POSIX は B<O_RDONLY> と B<O_TRUNC> が一緒に指定された場合の動作を未定義にして"
6758 "いる。Linux では、 既存の共有メモリ・オブジェクトに対する切り詰め (truncate) "
6759 "は成功する。 しかし、他の UNIX システムでも同じであるとは限らない。"
6760
6761 #. type: Plain text
6762 #: build/C/man3/shm_open.3:269
6763 msgid ""
6764 "The POSIX shared memory object implementation on Linux 2.4 makes use of a "
6765 "dedicated file system, which is normally mounted under I</dev/shm>."
6766 msgstr ""
6767 "Linux 2.4 における POSIX 共有メモリ・オブジェクトの実装は 専用のファイルシス"
6768 "テムを使用する。そのファイルシステムは通常 I</dev/shm> にマウントされる。"
6769
6770 #. type: Plain text
6771 #: build/C/man3/shm_open.3:279
6772 msgid ""
6773 "B<close>(2), B<fchmod>(2), B<fchown>(2), B<fcntl>(2), B<fstat>(2), "
6774 "B<ftruncate>(2), B<mmap>(2), B<open>(2), B<umask>(2), B<shm_overview>(7)"
6775 msgstr ""
6776 "B<close>(2), B<fchmod>(2), B<fchown>(2), B<fcntl>(2), B<fstat>(2), "
6777 "B<ftruncate>(2), B<mmap>(2), B<open>(2), B<umask>(2), B<shm_overview>(7)"
6778
6779 #. type: TH
6780 #: build/C/man7/shm_overview.7:27
6781 #, no-wrap
6782 msgid "SHM_OVERVIEW"
6783 msgstr "SHM_OVERVIEW"
6784
6785 #. type: Plain text
6786 #: build/C/man7/shm_overview.7:30
6787 msgid "shm_overview - Overview of POSIX shared memory"
6788 msgstr "shm_overview - POSIX 共有メモリの概要"
6789
6790 #. type: Plain text
6791 #: build/C/man7/shm_overview.7:33
6792 msgid ""
6793 "The POSIX shared memory API allows processes to communicate information by "
6794 "sharing a region of memory."
6795 msgstr ""
6796 "POSIX 共有メモリ API を使用すると、メモリのある領域を共有して、 プロセス間で"
6797 "情報をやり取りすることができる。"
6798
6799 #. type: Plain text
6800 #: build/C/man7/shm_overview.7:35
6801 msgid "The interfaces employed in the API are:"
6802 msgstr "この API では以下のインターフェースが採用されている。"
6803
6804 #. type: TP
6805 #: build/C/man7/shm_overview.7:35
6806 #, no-wrap
6807 msgid "B<shm_open>(3)"
6808 msgstr "B<shm_open>(3)"
6809
6810 #. type: Plain text
6811 #: build/C/man7/shm_overview.7:42
6812 msgid ""
6813 "Create and open a new object, or open an existing object.  This is analogous "
6814 "to B<open>(2).  The call returns a file descriptor for use by the other "
6815 "interfaces listed below."
6816 msgstr ""
6817 "新しいオブジェクトを生成しオープンする、もしくは 既存のオブジェクトをオープン"
6818 "する。これは B<open>(2)  と同じである。下記にある他のインターフェースで使用す"
6819 "る ファイルディスクリプタを返す。"
6820
6821 #. type: TP
6822 #: build/C/man7/shm_overview.7:42
6823 #, no-wrap
6824 msgid "B<ftruncate>(2)"
6825 msgstr "B<ftruncate>(2)"
6826
6827 #. type: Plain text
6828 #: build/C/man7/shm_overview.7:46
6829 msgid ""
6830 "Set the size of the shared memory object.  (A newly created shared memory "
6831 "object has a length of zero.)"
6832 msgstr "共有メモリオブジェクトの大きさを設定する。"
6833
6834 #. type: Plain text
6835 #: build/C/man7/shm_overview.7:50
6836 msgid ""
6837 "Map the shared memory object into the virtual address space of the calling "
6838 "process."
6839 msgstr ""
6840 "呼び出したプロセスの仮想アドレス空間に共有メモリオブジェクトを マップする。"
6841
6842 #. type: TP
6843 #: build/C/man7/shm_overview.7:50
6844 #, no-wrap
6845 msgid "B<munmap>(2)"
6846 msgstr "B<munmap>(2)"
6847
6848 #. type: Plain text
6849 #: build/C/man7/shm_overview.7:54
6850 msgid ""
6851 "Unmap the shared memory object from the virtual address space of the calling "
6852 "process."
6853 msgstr ""
6854 "呼び出したプロセスの仮想アドレス空間から 共有メモリオブジェクトをアンマップす"
6855 "る。"
6856
6857 #. type: TP
6858 #: build/C/man7/shm_overview.7:54
6859 #, no-wrap
6860 msgid "B<shm_unlink>(3)"
6861 msgstr "B<shm_unlink>(3)"
6862
6863 #. type: Plain text
6864 #: build/C/man7/shm_overview.7:57
6865 msgid "Remove a shared memory object name."
6866 msgstr "共有メモリオブジェクト名を削除する。"
6867
6868 #. type: TP
6869 #: build/C/man7/shm_overview.7:57
6870 #, no-wrap
6871 msgid "B<close>(2)"
6872 msgstr "B<close>(2)"
6873
6874 #. type: Plain text
6875 #: build/C/man7/shm_overview.7:62
6876 msgid ""
6877 "Close the file descriptor allocated by B<shm_open>(3)  when it is no longer "
6878 "needed."
6879 msgstr ""
6880 "B<shm_open>(3)  で割り当てられたファイルディスクリプタが不要になった際に、 そ"
6881 "のファイルディスクリプタをクローズする。"
6882
6883 #. type: TP
6884 #: build/C/man7/shm_overview.7:62
6885 #, no-wrap
6886 msgid "B<fstat>(2)"
6887 msgstr "B<fstat>(2)"
6888
6889 #. type: Plain text
6890 #: build/C/man7/shm_overview.7:76
6891 msgid ""
6892 "Obtain a I<stat> structure that describes the shared memory object.  Among "
6893 "the information returned by this call are the object's size (I<st_size>), "
6894 "permissions (I<st_mode>), owner (I<st_uid>), and group (I<st_gid>)."
6895 msgstr ""
6896 "その共有メモリオブジェクトについての情報が入った I<stat> 構造体を取得する。 "
6897 "このシステムコールが返す情報には、オブジェクトのサイズ (I<st_size>)、 許可属"
6898 "性 (I<st_mode>)、 所有者 (I<st_uid>)、 グループ (I<st_gid>)  がある。"
6899
6900 #. type: TP
6901 #: build/C/man7/shm_overview.7:76
6902 #, no-wrap
6903 msgid "B<fchown>(2)"
6904 msgstr "B<fchown>(2)"
6905
6906 #. type: Plain text
6907 #: build/C/man7/shm_overview.7:79
6908 msgid "To change the ownership of a shared memory object."
6909 msgstr "共有メモリオブジェクトの所有権を変更する。"
6910
6911 #. type: TP
6912 #: build/C/man7/shm_overview.7:79
6913 #, no-wrap
6914 msgid "B<fchmod>(2)"
6915 msgstr "B<fchmod>(2)"
6916
6917 #. type: Plain text
6918 #: build/C/man7/shm_overview.7:82
6919 msgid "To change the permissions of a shared memory object."
6920 msgstr "共有メモリオブジェクトの許可属性を変更する。"
6921
6922 #. type: SS
6923 #: build/C/man7/shm_overview.7:82
6924 #, no-wrap
6925 msgid "Versions"
6926 msgstr "Versions"
6927
6928 #. type: Plain text
6929 #: build/C/man7/shm_overview.7:84
6930 msgid "POSIX shared memory is supported since Linux 2.4 and glibc 2.2."
6931 msgstr "POSIX 共有メモリは Linux 2.4 と glibc 2.2 以降でサポートされている。"
6932
6933 #. type: SS
6934 #: build/C/man7/shm_overview.7:84
6935 #, no-wrap
6936 msgid "Persistence"
6937 msgstr "持続性"
6938
6939 #. type: Plain text
6940 #: build/C/man7/shm_overview.7:89
6941 msgid ""
6942 "POSIX shared memory objects have kernel persistence: a shared memory object "
6943 "will exist until the system is shut down, or until all processes have "
6944 "unmapped the object and it has been deleted with B<shm_unlink>(3)"
6945 msgstr ""
6946 "POSIX 共有メモリオブジェクトはカーネル内で保持される。 共有メモリオブジェクト"
6947 "は、システムがシャットダウンされるか、 全てのプロセスがそのオブジェクトをアン"
6948 "マップし、 B<shm_unlink>(3)  で削除されるまで、存在し続ける。"
6949
6950 #. type: SS
6951 #: build/C/man7/shm_overview.7:89
6952 #, no-wrap
6953 msgid "Linking"
6954 msgstr "リンク"
6955
6956 #. type: Plain text
6957 #: build/C/man7/shm_overview.7:94
6958 msgid ""
6959 "Programs using the POSIX shared memory API must be compiled with I<cc -lrt> "
6960 "to link against the real-time library, I<librt>."
6961 msgstr ""
6962 "POSIX 共有メモリ API を使用したプログラムは I<cc -lrt> でコンパイルし、リアル"
6963 "タイムライブラリ I<librt> とリンクしなければならない。"
6964
6965 #. type: SS
6966 #: build/C/man7/shm_overview.7:94
6967 #, no-wrap
6968 msgid "Accessing shared memory objects via the file system"
6969 msgstr "ファイルシステム経由での共有メモリオブジェクトへのアクセス"
6970
6971 #. type: Plain text
6972 #: build/C/man7/shm_overview.7:101
6973 msgid ""
6974 "On Linux, shared memory objects are created in a (I<tmpfs>)  virtual file "
6975 "system, normally mounted under I</dev/shm>.  Since kernel 2.6.19, Linux "
6976 "supports the use of access control lists (ACLs)  to control the permissions "
6977 "of objects in the virtual file system."
6978 msgstr ""
6979 "Linux では、共有メモリオブジェクトは通常 I</dev/shm> 以下にマウントされる仮想"
6980 "ファイルシステム (I<tmpfs>)  内に作成される。 カーネル 2.6.19 以降の Linux で"
6981 "は、 仮想ファイルシステム内のオブジェクトの許可属性の制御に、 アクセス制御リ"
6982 "スト (ACL; access control lists) を使うことができる。"
6983
6984 #. type: Plain text
6985 #: build/C/man7/shm_overview.7:106
6986 msgid ""
6987 "Typically, processes must synchronize their access to a shared memory "
6988 "object, using, for example, POSIX semaphores."
6989 msgstr ""
6990 "通常は、共有メモリオブジェクトにアクセスするプロセスは、 POSIX セマフォなどを"
6991 "使ってプロセス間で同期をとらなければならない。"
6992
6993 #. type: Plain text
6994 #: build/C/man7/shm_overview.7:114
6995 msgid ""
6996 "System V shared memory (B<shmget>(2), B<shmop>(2), etc.) is an older shared "
6997 "memory API.  POSIX shared memory provides a simpler, and better designed "
6998 "interface; on the other hand POSIX shared memory is somewhat less widely "
6999 "available (especially on older systems) than System V shared memory."
7000 msgstr ""
7001 "System V 共有メモリ (B<shmget>(2), B<shmop>(2)  など) は古い共有メモリ API で"
7002 "ある。 POSIX 共有メモリは、より簡単で、うまく設計されたインタフェースを提供し"
7003 "ている。 一方で、POSIX 共有メモリは System V 共有メモリと比べると 利用できる"
7004 "システムが少ない (特に、古いシステムでは少ない)。"
7005
7006 #. type: Plain text
7007 #: build/C/man7/shm_overview.7:126
7008 msgid ""
7009 "B<fchmod>(2), B<fchown>(2), B<fstat>(2), B<ftruncate>(2), B<mmap>(2), "
7010 "B<mprotect>(2), B<munmap>(2), B<shmget>(2), B<shmop>(2), B<shm_open>(3), "
7011 "B<shm_unlink>(3), B<sem_overview>(7)"
7012 msgstr ""
7013 "B<fchmod>(2), B<fchown>(2), B<fstat>(2), B<ftruncate>(2), B<mmap>(2), "
7014 "B<mprotect>(2), B<munmap>(2), B<shmget>(2), B<shmop>(2), B<shm_open>(3), "
7015 "B<shm_unlink>(3), B<sem_overview>(7)"
7016
7017 #. type: TH
7018 #: build/C/man2/shmctl.2:43
7019 #, no-wrap
7020 msgid "SHMCTL"
7021 msgstr "SHMCTL"
7022
7023 #. type: TH
7024 #: build/C/man2/shmctl.2:43
7025 #, no-wrap
7026 msgid "2008-08-07"
7027 msgstr "2008-08-07"
7028
7029 #. type: Plain text
7030 #: build/C/man2/shmctl.2:46
7031 msgid "shmctl - shared memory control"
7032 msgstr "shmctl - 共有メモリ (shared memory) を制御する"
7033
7034 #. type: Plain text
7035 #: build/C/man2/shmctl.2:49 build/C/man2/shmget.2:42
7036 msgid "B<#include E<lt>sys/ipc.hE<gt>>"
7037 msgstr "B<#include E<lt>sys/ipc.hE<gt>>"
7038
7039 #. type: Plain text
7040 #: build/C/man2/shmctl.2:51 build/C/man2/shmget.2:44
7041 msgid "B<#include E<lt>sys/shm.hE<gt>>"
7042 msgstr "B<#include E<lt>sys/shm.hE<gt>>"
7043
7044 #. type: Plain text
7045 #: build/C/man2/shmctl.2:53
7046 msgid ""
7047 "B<int shmctl(int >I<shmid>B<, int >I<cmd>B<, struct shmid_ds *>I<buf>B<);>"
7048 msgstr ""
7049 "B<int shmctl(int >I<shmid>B<, int >I<cmd>B<, struct shmid_ds *>I<buf>B<);>"
7050
7051 #. type: Plain text
7052 #: build/C/man2/shmctl.2:60
7053 msgid ""
7054 "B<shmctl>()  performs the control operation specified by I<cmd> on the "
7055 "shared memory segment whose identifier is given in I<shmid>."
7056 msgstr ""
7057 "B<shmctl>()  は、識別子が I<shmid> の共有メモリ・セグメントに対して I<cmd> で"
7058 "指示した制御命令を実行する。"
7059
7060 #. type: Plain text
7061 #: build/C/man2/shmctl.2:65
7062 msgid ""
7063 "The I<buf> argument is a pointer to a I<shmid_ds> structure, defined in "
7064 "I<E<lt>sys/shm.hE<gt>> as follows:"
7065 msgstr ""
7066 "I<buf> 引き数は、 I<shmid_ds> 構造体へのポインタである。 この構造体は "
7067 "I<E<lt>sys/shm.hE<gt>> で以下のように定義されている"
7068
7069 #. type: Plain text
7070 #: build/C/man2/shmctl.2:79
7071 #, no-wrap
7072 msgid ""
7073 "struct shmid_ds {\n"
7074 "    struct ipc_perm shm_perm;    /* Ownership and permissions */\n"
7075 "    size_t          shm_segsz;   /* Size of segment (bytes) */\n"
7076 "    time_t          shm_atime;   /* Last attach time */\n"
7077 "    time_t          shm_dtime;   /* Last detach time */\n"
7078 "    time_t          shm_ctime;   /* Last change time */\n"
7079 "    pid_t           shm_cpid;    /* PID of creator */\n"
7080 "    pid_t           shm_lpid;    /* PID of last shmat(2)/shmdt(2) */\n"
7081 "    shmatt_t        shm_nattch;  /* No. of current attaches */\n"
7082 "    ...\n"
7083 "};\n"
7084 msgstr ""
7085 "struct shmid_ds {\n"
7086 "    struct ipc_perm shm_perm;    /* 所有権と許可 */\n"
7087 "    size_t          shm_segsz;   /* セグメントのサイズ (バイト) */\n"
7088 "    time_t          shm_atime;   /* 最後の付加 (attach) の時刻 */\n"
7089 "    time_t          shm_dtime;   /* 最後の分離 (detach) の時刻 */\n"
7090 "    time_t          shm_ctime;   /* 最後に変更が行われた時刻 */\n"
7091 "    pid_t           shm_cpid;    /* 作成者 (creator) の PID */\n"
7092 "    pid_t           shm_lpid;    /* 最後の shmat(2)/shmdt(2) の PID */\n"
7093 "    shmatt_t        shm_nattch;  /* 現在付加されている数 */\n"
7094 "    ...\n"
7095 "};\n"
7096
7097 #. type: Plain text
7098 #: build/C/man2/shmctl.2:87
7099 msgid ""
7100 "The I<ipc_perm> structure is defined in I<E<lt>sys/ipc.hE<gt>> as follows "
7101 "(the highlighted fields are settable using B<IPC_SET>):"
7102 msgstr ""
7103 "I<ipc_perm> 構造体は I<E<lt>sys/ipc.hE<gt>> で以下のように定義されている (強"
7104 "調されたフィールドは B<IPC_SET> を使って設定可能である):"
7105
7106 #. type: Plain text
7107 #: build/C/man2/shmctl.2:100
7108 #, no-wrap
7109 msgid ""
7110 "struct ipc_perm {\n"
7111 "    key_t          __key;    /* Key supplied to shmget(2) */\n"
7112 "    uid_t          B<uid>;      /* Effective UID of owner */\n"
7113 "    gid_t          B<gid>;      /* Effective GID of owner */\n"
7114 "    uid_t          cuid;     /* Effective UID of creator */\n"
7115 "    gid_t          cgid;     /* Effective GID of creator */\n"
7116 "    unsigned short B<mode>;     /* B<Permissions> + SHM_DEST and\n"
7117 "                                SHM_LOCKED flags */\n"
7118 "    unsigned short __seq;    /* Sequence number */\n"
7119 "};\n"
7120 msgstr ""
7121 "struct ipc_perm {\n"
7122 "    key_t          __key;    /* shmget(2) に与えられるキー */\n"
7123 "    uid_t          B<uid>;      /* 所有者の実効 UID */\n"
7124 "    gid_t          B<gid>;      /* 所有者の実効 GID */\n"
7125 "    uid_t          cuid;     /* 作成者の実効 UID */\n"
7126 "    gid_t          cgid;     /* 作成者の実効 GID */\n"
7127 "    unsigned short B<mode>;     /* B<許可> + SHM_DEST と\n"
7128 "                                SHM_LOCKED フラグ */\n"
7129 "    unsigned short __seq;    /* シーケンス番号 */\n"
7130 "};\n"
7131
7132 #. type: Plain text
7133 #: build/C/man2/shmctl.2:106
7134 msgid "Valid values for I<cmd> are:"
7135 msgstr "I<cmd> として有効な値は以下の通り:"
7136
7137 #. type: TP
7138 #: build/C/man2/shmctl.2:107
7139 #, no-wrap
7140 msgid "B<IPC_STAT>"
7141 msgstr "B<IPC_STAT>"
7142
7143 #. type: Plain text
7144 #: build/C/man2/shmctl.2:116
7145 msgid ""
7146 "Copy information from the kernel data structure associated with I<shmid> "
7147 "into the I<shmid_ds> structure pointed to by I<buf>.  The caller must have "
7148 "read permission on the shared memory segment."
7149 msgstr ""
7150 "I<shmid> に関連づけられたカーネルデータ構造体の情報を I<buf> で指された "
7151 "I<shmid_ds> 構造体にコピーする。 呼び出し元は共有メモリ・セグメントに対する "
7152 "読み込み許可を持たなければならない。"
7153
7154 #. type: TP
7155 #: build/C/man2/shmctl.2:116
7156 #, no-wrap
7157 msgid "B<IPC_SET>"
7158 msgstr "B<IPC_SET>"
7159
7160 #. type: Plain text
7161 #: build/C/man2/shmctl.2:134
7162 msgid ""
7163 "Write the values of some members of the I<shmid_ds> structure pointed to by "
7164 "I<buf> to the kernel data structure associated with this shared memory "
7165 "segment, updating also its I<shm_ctime> member.  The following fields can be "
7166 "changed: I<shm_perm.uid>, I<shm_perm.gid>, and (the least significant 9 bits "
7167 "of) I<shm_perm.mode>.  The effective UID of the calling process must match "
7168 "the owner (I<shm_perm.uid>)  or creator (I<shm_perm.cuid>)  of the shared "
7169 "memory segment, or the caller must be privileged."
7170 msgstr ""
7171 "I<buf> によって指される I<shmid_ds> 構造体のいくつかのメンバーの値を、 この共"
7172 "有メモリ・セグメントに関連づけられたカーネルデータ構造体に書き込み、 "
7173 "I<shm_ctime> メンバーも更新する。 以下のフィールドは変更できる。 I<shm_perm."
7174 "uid>, I<shm_perm.gid>, I<shm_perm.mode> (の最下位 9 ビット)。 呼び出したプロ"
7175 "セスの実効 UID が所有者 (I<shm_perm.uid>)  または作成者 (I<shm_perm.cuid>)  "
7176 "と一致するか、呼び出し元が特権を持たなければならない。"
7177
7178 #. type: TP
7179 #: build/C/man2/shmctl.2:134
7180 #, no-wrap
7181 msgid "B<IPC_RMID>"
7182 msgstr "B<IPC_RMID>"
7183
7184 #. type: Plain text
7185 #: build/C/man2/shmctl.2:151
7186 msgid ""
7187 "Mark the segment to be destroyed.  The segment will only actually be "
7188 "destroyed after the last process detaches it (i.e., when the I<shm_nattch> "
7189 "member of the associated structure I<shmid_ds> is zero).  The caller must be "
7190 "the owner or creator, or be privileged.  If a segment has been marked for "
7191 "destruction, then the (nonstandard)  B<SHM_DEST> flag of the I<shm_perm."
7192 "mode> field in the associated data structure retrieved by B<IPC_STAT> will "
7193 "be set."
7194 msgstr ""
7195 "セグメントに破棄済みのマークを付ける。 セグメントは、実際には最後プロセスがセ"
7196 "グメントを分離した (関連する I<shmid_ds> 構造体の I<shm_nattch> メンバーが 0 "
7197 "になった) 後でのみ破棄される。 呼び出し元は所有者か作成者であるか、特権を持た"
7198 "なければならない。 セグメントに破棄のマークが付けられると、 関連するデータ構"
7199 "造体において I<shm_perm.mode> フィールドの (標準ではない)  B<SHM_DEST> フラグ"
7200 "が設定される。 このデータ構造体は B<IPC_STAT> で取得される。"
7201
7202 #. type: Plain text
7203 #: build/C/man2/shmctl.2:154
7204 msgid ""
7205 "The caller I<must> ensure that a segment is eventually destroyed; otherwise "
7206 "its pages that were faulted in will remain in memory or swap."
7207 msgstr ""
7208 "呼び出し元は最終的にはセグメントを忘れずに破棄I<しなければならない>。 そうで"
7209 "なれば、フォールト (fault) されたページは メモリかスワップ (swap) に残り続け"
7210 "る。"
7211
7212 #. type: TP
7213 #: build/C/man2/shmctl.2:154
7214 #, no-wrap
7215 msgid "B<IPC_INFO> (Linux-specific)"
7216 msgstr "B<IPC_INFO> (Linux 固有)"
7217
7218 #. type: Plain text
7219 #: build/C/man2/shmctl.2:167
7220 msgid ""
7221 "Returns information about system-wide shared memory limits and parameters in "
7222 "the structure pointed to by I<buf>.  This structure is of type I<shminfo> "
7223 "(thus, a cast is required), defined in I<E<lt>sys/shm.hE<gt>> if the "
7224 "B<_GNU_SOURCE> feature test macro is defined:"
7225 msgstr ""
7226 "システム全体での共有メモリの制限とパラメータに関する情報を、 I<buf> が指す構"
7227 "造体に入れて返す。 この構造体は I<shminfo> 型である (そのためキャストが必要で"
7228 "ある)。 I<shminfo> は B<_GNU_SOURCE> 機能検査マクロが定義された場合に "
7229 "I<E<lt>sys/shm.hE<gt>> で以下のように定義される:"
7230
7231 #. type: Plain text
7232 #: build/C/man2/shmctl.2:181
7233 #, no-wrap
7234 msgid ""
7235 "struct  shminfo {\n"
7236 "    unsigned long shmmax; /* Maximum segment size */\n"
7237 "    unsigned long shmmin; /* Minimum segment size;\n"
7238 "                             always 1 */\n"
7239 "    unsigned long shmmni; /* Maximum number of segments */\n"
7240 "    unsigned long shmseg; /* Maximum number of segments\n"
7241 "                             that a process can attach;\n"
7242 "                             unused within kernel */\n"
7243 "    unsigned long shmall; /* Maximum number of pages of\n"
7244 "                             shared memory, system-wide */\n"
7245 "};\n"
7246 msgstr ""
7247 "struct  shminfo {\n"
7248 "    unsigned long shmmax; /* 最大セグメントサイズ */\n"
7249 "    unsigned long shmmin; /* 最小セグメントサイズ。\n"
7250 "                             常に 1 */\n"
7251 "    unsigned long shmmni; /* 最大セグメント数 */\n"
7252 "    unsigned long shmseg; /* プロセスが付加できる\n"
7253 "                             セグメントの最大数。\n"
7254 "                             カーネル内では未使用 */\n"
7255 "    unsigned long shmall; /* 共有メモリの最大ページ数。\n"
7256 "                             システム全体での値 */\n"
7257 "};\n"
7258
7259 #. type: Plain text
7260 #: build/C/man2/shmctl.2:194
7261 msgid ""
7262 "The I<shmmni>, I<shmmax>, and I<shmall> settings can be changed via I</proc> "
7263 "files of the same name; see B<proc>(5)  for details."
7264 msgstr ""
7265 "設定 I<shmmni>, I<shmmax>, I<shmall> は I</proc> にある同じ名前のファイル経由"
7266 "で変更可能である。 詳しくは B<proc>(5)  を参照。"
7267
7268 #. type: TP
7269 #: build/C/man2/shmctl.2:194
7270 #, no-wrap
7271 msgid "B<SHM_INFO> (Linux-specific)"
7272 msgstr "B<SHM_INFO> (Linux 固有)"
7273
7274 #. type: Plain text
7275 #: build/C/man2/shmctl.2:205
7276 msgid ""
7277 "Returns a I<shm_info> structure whose fields contain information about "
7278 "system resources consumed by shared memory.  This structure is defined in "
7279 "I<E<lt>sys/shm.hE<gt>> if the B<_GNU_SOURCE> feature test macro is defined:"
7280 msgstr ""
7281 "共有メモリが消費しているシステム資源に関する情報を 格納した I<shm_info> 構造"
7282 "体を返す。 この構造体は、 B<_GNU_SOURCE> 機能検査マクロが定義された場合に "
7283 "I<E<lt>sys/shm.hE<gt>> で以下のように定義される:"
7284
7285 #. type: Plain text
7286 #: build/C/man2/shmctl.2:222
7287 #, no-wrap
7288 msgid ""
7289 "struct shm_info {\n"
7290 "    int           used_ids; /* # of currently existing\n"
7291 "                               segments */\n"
7292 "    unsigned long shm_tot;  /* Total number of shared\n"
7293 "                               memory pages */\n"
7294 "    unsigned long shm_rss;  /* # of resident shared\n"
7295 "                               memory pages */\n"
7296 "    unsigned long shm_swp;  /* # of swapped shared\n"
7297 "                               memory pages */\n"
7298 "    unsigned long swap_attempts;\n"
7299 "                            /* Unused since Linux 2.4 */\n"
7300 "    unsigned long swap_successes;\n"
7301 "                            /* Unused since Linux 2.4 */\n"
7302 "};\n"
7303 msgstr ""
7304 "struct shm_info {\n"
7305 "    int           used_ids; /* 現在存在するセグメント数 */\n"
7306 "    unsigned long shm_tot;  /* 共有メモリのページ総数 */\n"
7307 "    unsigned long shm_rss;  /* メモリ上にある (スワップされて\n"
7308 "                               いない) 共有メモリページ数 */\n"
7309 "    unsigned long shm_swp;  /* スワップされている共有メモリ\n"
7310 "                               ページ数 */\n"
7311 "    unsigned long swap_attempts;\n"
7312 "                            /* Linux 2.4 以降では未使用 */\n"
7313 "    unsigned long swap_successes;\n"
7314 "                            /* Linux 2.4 以降では未使用 */\n"
7315 "};\n"
7316
7317 #. type: TP
7318 #: build/C/man2/shmctl.2:224
7319 #, no-wrap
7320 msgid "B<SHM_STAT> (Linux-specific)"
7321 msgstr "B<SHM_STAT> (Linux 固有)"
7322
7323 #. type: Plain text
7324 #: build/C/man2/shmctl.2:235
7325 msgid ""
7326 "Returns a I<shmid_ds> structure as for B<IPC_STAT>.  However, the I<shmid> "
7327 "argument is not a segment identifier, but instead an index into the kernel's "
7328 "internal array that maintains information about all shared memory segments "
7329 "on the system."
7330 msgstr ""
7331 "B<IPC_STAT> と同じく I<shmid_ds> 構造体を返す。 但し、 I<shmid> 引き数は、セ"
7332 "グメント識別子ではなく、システム上の全ての共有メモリ セグメントに関する情報を"
7333 "管理するカーネルの内部配列へのインデックス である。"
7334
7335 #. type: Plain text
7336 #: build/C/man2/shmctl.2:238
7337 msgid ""
7338 "The caller can prevent or allow swapping of a shared memory segment with the "
7339 "following I<cmd> values:"
7340 msgstr ""
7341 "呼び出し元は、I<cmd> に以下の値を指定することで、共有メモリ・セグメントが ス"
7342 "ワップされることを防止したり、許可したりできる:"
7343
7344 #. type: TP
7345 #: build/C/man2/shmctl.2:239
7346 #, no-wrap
7347 msgid "B<SHM_LOCK> (Linux-specific)"
7348 msgstr "B<SHM_LOCK> (Linux 固有)"
7349
7350 #. type: Plain text
7351 #: build/C/man2/shmctl.2:251
7352 msgid ""
7353 "Prevent swapping of the shared memory segment.  The caller must fault in any "
7354 "pages that are required to be present after locking is enabled.  If a "
7355 "segment has been locked, then the (nonstandard)  B<SHM_LOCKED> flag of the "
7356 "I<shm_perm.mode> field in the associated data structure retrieved by "
7357 "B<IPC_STAT> will be set."
7358 msgstr ""
7359 "共有メモリ・セグメントをスワップすることを防止する。 ロックが有効になった後、"
7360 "呼び出し元は、 存在することが要求された全てのページをフォールトさせなければな"
7361 "らない。 セグメントがロックされると、 関連するデータ構造体において "
7362 "I<shm_perm.mode> フィールドの (標準的ではない)  B<SHM_LOCKED> フラグが設定さ"
7363 "れる。 このデータ構造体は B<IPC_STAT> で取得される。"
7364
7365 #. type: TP
7366 #: build/C/man2/shmctl.2:251
7367 #, no-wrap
7368 msgid "B<SHM_UNLOCK> (Linux-specific)"
7369 msgstr "B<SHM_UNLOCK> (Linux 固有)"
7370
7371 #. type: Plain text
7372 #: build/C/man2/shmctl.2:254
7373 msgid "Unlock the segment, allowing it to be swapped out."
7374 msgstr "セグメントのロックを解除し、スワップ・アウトすることを可能にする。"
7375
7376 #.  There was some weirdness in 2.6.9: SHM_LOCK and SHM_UNLOCK could
7377 #.  be applied to a segment, regardless of ownership of the segment.
7378 #.  This was a botch-up in the move to RLIMIT_MEMLOCK, and was fixed
7379 #.  in 2.6.10.  MTK, May 2005
7380 #. type: Plain text
7381 #: build/C/man2/shmctl.2:272
7382 msgid ""
7383 "In kernels before 2.6.10, only a privileged process could employ B<SHM_LOCK> "
7384 "and B<SHM_UNLOCK>.  Since kernel 2.6.10, an unprivileged process can employ "
7385 "these operations if its effective UID matches the owner or creator UID of "
7386 "the segment, and (for B<SHM_LOCK>)  the amount of memory to be locked falls "
7387 "within the B<RLIMIT_MEMLOCK> resource limit (see B<setrlimit>(2))."
7388 msgstr ""
7389 "2.6.10 より前のカーネルでは、特権プロセスだけが B<SHM_LOCK> と B<SHM_UNLOCK> "
7390 "を利用することができた。 2.6.10 以降のカーネルでは、非特権プロセスであっても"
7391 "次の条件を満たせば これらの操作を利用することができる。その条件とは、プロセス"
7392 "の実効 UID がそのセグメントの所有者もしくは作成者の UID と一致し、 "
7393 "(B<SHM_LOCK> の場合には) ロックするメモリの合計が B<RLIMIT_MEMLOCK> リソース"
7394 "上限 (B<setrlimit>(2)  参照) の範囲内に入っていることである。"
7395
7396 #. type: Plain text
7397 #: build/C/man2/shmctl.2:290
7398 msgid ""
7399 "A successful B<IPC_INFO> or B<SHM_INFO> operation returns the index of the "
7400 "highest used entry in the kernel's internal array recording information "
7401 "about all shared memory segments.  (This information can be used with "
7402 "repeated B<SHM_STAT> operations to obtain information about all shared "
7403 "memory segments on the system.)  A successful B<SHM_STAT> operation returns "
7404 "the identifier of the shared memory segment whose index was given in "
7405 "I<shmid>.  Other operations return 0 on success."
7406 msgstr ""
7407 "B<IPC_INFO> と B<SHM_INFO> 操作は、成功すると、全ての共有メモリセグメントに関"
7408 "する情報を 管理しているカーネルの内部配列の使用中エントリのインデックスの う"
7409 "ち最大値を返す (この情報は、システムの全ての共有メモリセグメントに関する情報"
7410 "を 取得するために、 B<SHM_STAT> 操作を繰り返し実行する際に使用できる)。 "
7411 "B<SHM_STAT> 操作は、成功すると、 I<shmid> で指定されたインデックスを持つ共有"
7412 "メモリセグメントの識別子を返す。 他の操作は、成功の場合 0 を返す。"
7413
7414 #. type: Plain text
7415 #: build/C/man2/shmctl.2:294
7416 msgid "On error, -1 is returned, and I<errno> is set appropriately."
7417 msgstr "エラーの場合は -1 を返し、 I<errno> を適切に設定する。"
7418
7419 #. type: Plain text
7420 #: build/C/man2/shmctl.2:303
7421 msgid ""
7422 "B<IPC_STAT> or B<SHM_STAT> is requested and I<shm_perm.mode> does not allow "
7423 "read access for I<shmid>, and the calling process does not have the "
7424 "B<CAP_IPC_OWNER> capability."
7425 msgstr ""
7426 "B<IPC_STAT> または B<SHM_STAT> が要求され、 I<shm_perm.mode> が I<shmid> への"
7427 "読み込みアクセスを許しておらず、 かつ呼び出したプロセスが B<CAP_IPC_OWNER> "
7428 "ケーパビリティ (capability) を持っていない。"
7429
7430 #. type: Plain text
7431 #: build/C/man2/shmctl.2:314
7432 msgid ""
7433 "The argument I<cmd> has value B<IPC_SET> or B<IPC_STAT> but the address "
7434 "pointed to by I<buf> isn't accessible."
7435 msgstr ""
7436 "I<cmd> 引き数に B<IPC_SET> か B<IPC_STAT> が指定されたが I<buf> で指されてい"
7437 "るアドレスにアクセスできない。"
7438
7439 #. type: TP
7440 #: build/C/man2/shmctl.2:314
7441 #, no-wrap
7442 msgid "B<EIDRM>"
7443 msgstr "B<EIDRM>"
7444
7445 #. type: Plain text
7446 #: build/C/man2/shmctl.2:317
7447 msgid "I<shmid> points to a removed identifier."
7448 msgstr "I<shmid> が削除 (remove) された識別子 (identifier) を指している。"
7449
7450 #. type: Plain text
7451 #: build/C/man2/shmctl.2:326
7452 msgid ""
7453 "I<shmid> is not a valid identifier, or I<cmd> is not a valid command.  Or: "
7454 "for a B<SHM_STAT> operation, the index value specified in I<shmid> referred "
7455 "to an array slot that is currently unused."
7456 msgstr ""
7457 "I<shmid> が有効な識別子でないか、 I<cmd> が有効なコマンドでない。 もしくは、 "
7458 "B<SHM_STAT> 操作の場合に、 I<shmid> で指定されたインデックス値が現在未使用の"
7459 "配列のスロットを参照していた。"
7460
7461 #. type: Plain text
7462 #: build/C/man2/shmctl.2:337
7463 msgid ""
7464 "(In kernels since 2.6.9), B<SHM_LOCK> was specified and the size of the to-"
7465 "be-locked segment would mean that the total bytes in locked shared memory "
7466 "segments would exceed the limit for the real user ID of the calling "
7467 "process.  This limit is defined by the B<RLIMIT_MEMLOCK> soft resource limit "
7468 "(see B<setrlimit>(2))."
7469 msgstr ""
7470 "(2.6.9 以降のカーネルにおいて)  B<SHM_LOCK> が指定され、 ロックされる予定のセ"
7471 "グメントのサイズ (ロックされる共有メモリ・セグメントの合計バイト数) が、 呼び"
7472 "出したプロセスの実ユーザー ID についての制限を超えた。 この制限は "
7473 "B<RLIMIT_MEMLOCK> ソフト資源制限で定義される (B<setrlimit>(2)  を参照)。"
7474
7475 #. type: TP
7476 #: build/C/man2/shmctl.2:337
7477 #, no-wrap
7478 msgid "B<EOVERFLOW>"
7479 msgstr "B<EOVERFLOW>"
7480
7481 #. type: Plain text
7482 #: build/C/man2/shmctl.2:342
7483 msgid ""
7484 "B<IPC_STAT> is attempted, and the GID or UID value is too large to be stored "
7485 "in the structure pointed to by I<buf>."
7486 msgstr ""
7487 "B<IPC_STAT> が試みられ、GID や UID の値が I<buf> で指示される構造体に格納する"
7488 "には大き過ぎる。"
7489
7490 #. type: Plain text
7491 #: build/C/man2/shmctl.2:354
7492 msgid ""
7493 "B<IPC_SET> or B<IPC_RMID> is attempted, and the effective user ID of the "
7494 "calling process is not that of the creator (found in I<shm_perm.cuid>), or "
7495 "the owner (found in I<shm_perm.uid>), and the process was not privileged "
7496 "(Linux: did not have the B<CAP_SYS_ADMIN> capability)."
7497 msgstr ""
7498 "B<IPC_SET> か B<IPC_RMID> が試みられ、 呼び出したプロセスの実効ユーザー ID が"
7499 "作成者 (I<shm_perm.cuid>)  でも所有者 (I<shm_perm.uid>)  でもなく、プロセスが"
7500 "特権を持たない (Linux では B<CAP_SYS_ADMIN> ケーパビリティを持たない)。"
7501
7502 #. type: Plain text
7503 #: build/C/man2/shmctl.2:366
7504 msgid ""
7505 "Or (in kernels before 2.6.9), B<SHM_LOCK> or B<SHM_UNLOCK> was specified, "
7506 "but the process was not privileged (Linux: did not have the B<CAP_IPC_LOCK> "
7507 "capability).  (Since Linux 2.6.9, this error can also occur if the "
7508 "B<RLIMIT_MEMLOCK> is 0 and the caller is not privileged.)"
7509 msgstr ""
7510 "または (2.6.9 より前のカーネルで)  B<SHM_LOCK> または B<SHM_UNLOCK> が指定さ"
7511 "れているが、プロセスが特権を持たない (Linux では B<CAP_IPC_LOCK> ケーパビリ"
7512 "ティを持たない)。 (Linux 2.6.9 以降では、 B<RLIMIT_MEMLOCK> が 0 で呼び出し元"
7513 "が特権を持たない場合にも、このエラーが起こる。)"
7514
7515 #.  SVr4 documents an additional error condition EMFILE.
7516 #. type: Plain text
7517 #: build/C/man2/shmctl.2:371 build/C/man2/shmget.2:232
7518 #: build/C/man2/shmop.2:229
7519 msgid "SVr4, POSIX.1-2001."
7520 msgstr "SVr4, POSIX.1-2001."
7521
7522 #. type: Plain text
7523 #: build/C/man2/shmctl.2:382
7524 msgid ""
7525 "The B<IPC_INFO>, B<SHM_STAT> and B<SHM_INFO> operations are used by the "
7526 "B<ipcs>(1)  program to provide information on allocated resources.  In the "
7527 "future these may modified or moved to a /proc file system interface."
7528 msgstr ""
7529 "B<IPC_INFO>, B<SHM_STAT>, B<SHM_INFO> 操作は、 B<ipcs>(1)  プログラムで割り当"
7530 "て済の資源に関する情報を提供するために 使用されている。将来、これらの操作は変"
7531 "更されたり、 /proc ファイルシステムのインタフェースに移動されるかもしれない。"
7532
7533 #. type: Plain text
7534 #: build/C/man2/shmctl.2:390
7535 msgid ""
7536 "Linux permits a process to attach (B<shmat>(2))  a shared memory segment "
7537 "that has already been marked for deletion using I<shmctl(IPC_RMID)>.  This "
7538 "feature is not available on other UNIX implementations; portable "
7539 "applications should avoid relying on it."
7540 msgstr ""
7541 "Linux では、 I<shmctl(IPC_RMID)> を使ってすでに削除マークがつけられている共有"
7542 "メモリ・セグメントを あるプロセスが付加 (attach)  (B<shmat>(2))  することを許"
7543 "可している。 この機能は他の UNIX の実装では利用できない。 移植性を考慮したア"
7544 "プリケーションではこれに依存しないようにすべきである。"
7545
7546 #. type: Plain text
7547 #: build/C/man2/shmctl.2:403
7548 msgid ""
7549 "Various fields in a I<struct shmid_ds> were typed as I<short> under Linux "
7550 "2.2 and have become I<long> under Linux 2.4.  To take advantage of this, a "
7551 "recompilation under glibc-2.1.91 or later should suffice.  (The kernel "
7552 "distinguishes old and new calls by an B<IPC_64> flag in I<cmd>.)"
7553 msgstr ""
7554 "I<構造体 shmid_ds> 内の多くのフィールドは、 Linux 2.2 では I<short> 型だった"
7555 "が、Linux 2.4 では I<long> 型になった。 この利点を生かすには、glibc-2.1.91 以"
7556 "降の環境下で 再コンパイルすれば十分である。 カーネルは新しい形式の呼び出しと"
7557 "古い形式の呼び出しを I<cmd> 内の B<IPC_64> フラグで区別する。"
7558
7559 #. type: Plain text
7560 #: build/C/man2/shmctl.2:409
7561 msgid ""
7562 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
7563 "B<svipc>(7)"
7564 msgstr ""
7565 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
7566 "B<shm_overview>(7), B<svipc>(7)"
7567
7568 #. type: TH
7569 #: build/C/man2/shmget.2:36
7570 #, no-wrap
7571 msgid "SHMGET"
7572 msgstr "SHMGET"
7573
7574 #. type: TH
7575 #: build/C/man2/shmget.2:36
7576 #, no-wrap
7577 msgid "2006-05-02"
7578 msgstr "2006-05-02"
7579
7580 #. type: Plain text
7581 #: build/C/man2/shmget.2:39
7582 msgid "shmget - allocates a shared memory segment"
7583 msgstr "shmget - 共有メモリ・セグメントを割り当てる"
7584
7585 #. type: Plain text
7586 #: build/C/man2/shmget.2:46
7587 msgid "B<int shmget(key_t >I<key>B<, size_t >I<size>B<, int >I<shmflg>B<);>"
7588 msgstr "B<int shmget(key_t >I<key>B<, size_t >I<size>B<, int >I<shmflg>B<);>"
7589
7590 #. type: Plain text
7591 #: build/C/man2/shmget.2:70
7592 msgid ""
7593 "B<shmget>()  returns the identifier of the shared memory segment associated "
7594 "with the value of the argument I<key>.  A new shared memory segment, with "
7595 "size equal to the value of I<size> rounded up to a multiple of B<PAGE_SIZE>, "
7596 "is created if I<key> has the value B<IPC_PRIVATE> or I<key> isn't "
7597 "B<IPC_PRIVATE>, no shared memory segment corresponding to I<key> exists, and "
7598 "B<IPC_CREAT> is specified in I<shmflg>."
7599 msgstr ""
7600 "B<shmget>()  は I<key> 引き数に対応する共有メモリ・セグメントの識別子を返"
7601 "す。 I<key> の値が B<IPC_PRIVATE> の場合、もしくは I<key> に対応する共有メモ"
7602 "リ・セグメントが存在せず、 I<shmflg> に B<IPC_CREAT> が指定されていた場合、 "
7603 "新しい共有メモリ・セグメントを作成する。 作成される共有メモリ・セグメント"
7604 "は、 I<size> 引き数の値を B<PAGE_SIZE> の倍数へと切り上げた (round up) 大きさ"
7605 "となる。"
7606
7607 #. type: Plain text
7608 #: build/C/man2/shmget.2:89
7609 msgid ""
7610 "If I<shmflg> specifies both B<IPC_CREAT> and B<IPC_EXCL> and a shared memory "
7611 "segment already exists for I<key>, then B<shmget>()  fails with I<errno> set "
7612 "to B<EEXIST>.  (This is analogous to the effect of the combination B<O_CREAT "
7613 "| O_EXCL> for B<open>(2).)"
7614 msgstr ""
7615 "I<shmflg> に B<IPC_CREAT> と B<IPC_EXCL> の両方が指定された場合、 I<key> に対"
7616 "応する共有メモリ・セグメントが既に存在すると、 B<shmget>()  は失敗し、 "
7617 "I<errno> に B<EEXIST> が設定される (これは B<open>(2)  に B<O_CREAT | "
7618 "O_EXCL> を指定した場合の動作と同じである)。"
7619
7620 #. type: Plain text
7621 #: build/C/man2/shmget.2:93
7622 msgid "The value I<shmflg> is composed of:"
7623 msgstr "I<shmflg> は以下の内容から構成される:"
7624
7625 #. type: TP
7626 #: build/C/man2/shmget.2:93
7627 #, no-wrap
7628 msgid "B<IPC_CREAT>"
7629 msgstr "B<IPC_CREAT>"
7630
7631 #. type: Plain text
7632 #: build/C/man2/shmget.2:100
7633 msgid ""
7634 "to create a new segment.  If this flag is not used, then B<shmget>()  will "
7635 "find the segment associated with I<key> and check to see if the user has "
7636 "permission to access the segment."
7637 msgstr ""
7638 "新しいセグメントを作成する。このフラグが指定されなかった場合、 B<shmget>()  "
7639 "は I<key> に対応するセグメントを探し、 ユーザがそのセグメントにアクセスする許"
7640 "可があるかどうかをチェックする。"
7641
7642 #. type: TP
7643 #: build/C/man2/shmget.2:100
7644 #, no-wrap
7645 msgid "B<IPC_EXCL>"
7646 msgstr "B<IPC_EXCL>"
7647
7648 #. type: Plain text
7649 #: build/C/man2/shmget.2:103
7650 msgid "used with B<IPC_CREAT> to ensure failure if the segment already exists."
7651 msgstr ""
7652 "B<IPC_CREAT> と共に使用し、セグメントが既に存在した場合には 失敗することを保"
7653 "証する。"
7654
7655 #. type: TP
7656 #: build/C/man2/shmget.2:103
7657 #, no-wrap
7658 msgid "I<mode_flags>"
7659 msgstr "I<mode_flags>"
7660
7661 #. type: Plain text
7662 #: build/C/man2/shmget.2:113
7663 msgid ""
7664 "(least significant 9 bits)  specifying the permissions granted to the owner, "
7665 "group, and world.  These bits have the same format, and the same meaning, as "
7666 "the I<mode> argument of B<open>(2).  Presently, the execute permissions are "
7667 "not used by the system."
7668 msgstr ""
7669 "(下位 9 ビット)  所有者、グループ、他人 (world) への許可を指定する。 これらの"
7670 "ビットは B<open>(2)  の I<mode> 引き数と同じ形式で同じ意味を持つ。 今のとこ"
7671 "ろ、システムは実行 (execute) 許可を参照しない。"
7672
7673 #. type: TP
7674 #: build/C/man2/shmget.2:113
7675 #, no-wrap
7676 msgid "B<SHM_HUGETLB> (since Linux 2.6)"
7677 msgstr "B<SHM_HUGETLB> (Linux 2.6 以降)"
7678
7679 #. type: Plain text
7680 #: build/C/man2/shmget.2:119
7681 msgid ""
7682 "Allocate the segment using \"huge pages.\" See the kernel source file "
7683 "I<Documentation/vm/hugetlbpage.txt> for further information."
7684 msgstr ""
7685 "\"ヒュージページ (huge page)\" を使うセグメントを割り当てる。 詳細な情報は、"
7686 "カーネル・ソースのファイル I<Documentation/vm/hugetlbpage.txt> を参照。"
7687
7688 #. type: TP
7689 #: build/C/man2/shmget.2:119
7690 #, no-wrap
7691 msgid "B<SHM_NORESERVE> (since Linux 2.6.15)"
7692 msgstr "B<SHM_NORESERVE> (Linux 2.6.15 以降)"
7693
7694 #.  As at 2.6.17-rc2, this flag has no effect if SHM_HUGETLB was also
7695 #.  specified.
7696 #. type: Plain text
7697 #: build/C/man2/shmget.2:138
7698 msgid ""
7699 "This flag serves the same purpose as the B<mmap>(2)  B<MAP_NORESERVE> flag.  "
7700 "Do not reserve swap space for this segment.  When swap space is reserved, "
7701 "one has the guarantee that it is possible to modify the segment.  When swap "
7702 "space is not reserved one might get B<SIGSEGV> upon a write if no physical "
7703 "memory is available.  See also the discussion of the file I</proc/sys/vm/"
7704 "overcommit_memory> in B<proc>(5)."
7705 msgstr ""
7706 "このフラグは、 B<mmap>(2)  の B<MAP_NORESERVE> フラグと同じ役割を果たす。 こ"
7707 "のセグメントに対するスワップ空間の予約を行わない。 スワップ空間を予約した場合"
7708 "は、そのセグメントの変更が必ず成功することが 保証される。スワップ空間の予約を"
7709 "行わなかった場合は、物理メモリに空きが ないと書き込み時に B<SIGSEGV> を受け取"
7710 "る可能性がある。 B<proc>(5)  にある I</proc/sys/vm/overcommit_memory> ファイ"
7711 "ルに関する議論も参照のこと。"
7712
7713 #. type: Plain text
7714 #: build/C/man2/shmget.2:146
7715 msgid ""
7716 "When a new shared memory segment is created, its contents are initialized to "
7717 "zero values, and its associated data structure, I<shmid_ds> (see B<shmctl>"
7718 "(2)), is initialized as follows:"
7719 msgstr ""
7720 "共有メモリ・セグメントが新たに作成される際、 共有メモリ・セグメントの内容は "
7721 "0 で初期化され、 関連情報を保持するデータ構造体 I<shmid_ds> は以下のように初"
7722 "期化される。"
7723
7724 #. type: Plain text
7725 #: build/C/man2/shmget.2:151
7726 msgid ""
7727 "I<shm_perm.cuid> and I<shm_perm.uid> are set to the effective user ID of the "
7728 "calling process."
7729 msgstr ""
7730 "I<shm_perm.cuid> と I<shm_perm.uid> に呼び出し元プロセスの実効 (effective) "
7731 "ユーザーID を設定する。"
7732
7733 #. type: Plain text
7734 #: build/C/man2/shmget.2:156
7735 msgid ""
7736 "I<shm_perm.cgid> and I<shm_perm.gid> are set to the effective group ID of "
7737 "the calling process."
7738 msgstr ""
7739 "I<shm_perm.cgid> と I<shm_perm.gid> に呼び出し元プロセスの実効グループID を設"
7740 "定する。"
7741
7742 #. type: Plain text
7743 #: build/C/man2/shmget.2:161
7744 msgid ""
7745 "The least significant 9 bits of I<shm_perm.mode> are set to the least "
7746 "significant 9 bit of I<shmflg>."
7747 msgstr ""
7748 "I<shm_perm.mode> の下位 9 ビットに I<shmflg> の下位 9 ビットを設定する。"
7749
7750 #. type: Plain text
7751 #: build/C/man2/shmget.2:165
7752 msgid "I<shm_segsz> is set to the value of I<size>."
7753 msgstr "I<shm_segsz> に I<size> の値を設定する。"
7754
7755 #. type: Plain text
7756 #: build/C/man2/shmget.2:172
7757 msgid "I<shm_lpid>, I<shm_nattch>, I<shm_atime> and I<shm_dtime> are set to 0."
7758 msgstr ""
7759 "I<shm_lpid>, I<shm_nattch>, I<shm_atime>, I<shm_dtime> に 0 を設定する。"
7760
7761 #. type: Plain text
7762 #: build/C/man2/shmget.2:175
7763 msgid "I<shm_ctime> is set to the current time."
7764 msgstr "I<shm_ctime> に現在の時刻を設定する。"
7765
7766 #. type: Plain text
7767 #: build/C/man2/shmget.2:178
7768 msgid ""
7769 "If the shared memory segment already exists, the permissions are verified, "
7770 "and a check is made to see if it is marked for destruction."
7771 msgstr ""
7772 "共有メモリ・セグメントが既に存在する場合、アクセス許可の検査と、 破壊 "
7773 "(destruction) マークがつけられていないかのチェックが行われる。"
7774
7775 #. type: Plain text
7776 #: build/C/man2/shmget.2:182
7777 msgid ""
7778 "A valid segment identifier, I<shmid>, is returned on success, -1 on error."
7779 msgstr ""
7780 "成功した場合、有効なセグメント識別子 I<shmid> が返される。エラーの場合、 -1 "
7781 "が返される。"
7782
7783 #. type: Plain text
7784 #: build/C/man2/shmget.2:186
7785 msgid "On failure, I<errno> is set to one of the following:"
7786 msgstr "失敗した場合は I<errno> が以下のどれかに設定される:"
7787
7788 #. type: Plain text
7789 #: build/C/man2/shmget.2:192
7790 msgid ""
7791 "The user does not have permission to access the shared memory segment, and "
7792 "does not have the B<CAP_IPC_OWNER> capability."
7793 msgstr ""
7794 "ユーザーはその共有メモリ・セグメントへのアクセス許可を持たず、 "
7795 "B<CAP_IPC_OWNER> ケーパビリティも持っていない。"
7796
7797 #. type: Plain text
7798 #: build/C/man2/shmget.2:196
7799 msgid "B<IPC_CREAT | IPC_EXCL> was specified and the segment exists."
7800 msgstr ""
7801 "B<IPC_CREAT | IPC_EXCL> が指定されていたが、そのセグメントが既に存在する。"
7802
7803 #. type: Plain text
7804 #: build/C/man2/shmget.2:202
7805 msgid ""
7806 "A new segment was to be created and I<size> E<lt> B<SHMMIN> or I<size> E<gt> "
7807 "B<SHMMAX>, or no new segment was to be created, a segment with given key "
7808 "existed, but I<size> is greater than the size of that segment."
7809 msgstr ""
7810 "新しいセグメントを作成しようとした際に I<size> E<lt> B<SHMMIN> または "
7811 "I<size> E<gt> B<SHMMAX> であった。 もしくは、指定されたキーに対応するセグメン"
7812 "トが既に存在して、新しい セグメントを作成しようとはしなかったが、I<size> が存"
7813 "在するセグメントの サイズよりも大きかった。"
7814
7815 #. type: Plain text
7816 #: build/C/man2/shmget.2:211
7817 msgid ""
7818 "No segment exists for the given I<key>, and B<IPC_CREAT> was not specified."
7819 msgstr ""
7820 "指定された I<key> に対応するセグメントが存在せず、 B<IPC_CREAT> も指定されて"
7821 "いなかった。"
7822
7823 #. type: Plain text
7824 #: build/C/man2/shmget.2:214
7825 msgid "No memory could be allocated for segment overhead."
7826 msgstr "セグメントの管理情報 (overhead) に割り当てるメモリがなかった。"
7827
7828 #. type: Plain text
7829 #: build/C/man2/shmget.2:222
7830 msgid ""
7831 "All possible shared memory IDs have been taken (B<SHMMNI>), or allocating a "
7832 "segment of the requested I<size> would cause the system to exceed the system-"
7833 "wide limit on shared memory (B<SHMALL>)."
7834 msgstr ""
7835 "システム全体の共有メモリ・セグメント数の制限 (B<SHMMNI>)  に達した、または要"
7836 "求された I<size> のセグメントの割り当てが システム全体の共有メモリサイズの制"
7837 "限 (B<SHMALL>)  を超過した。"
7838
7839 #. type: Plain text
7840 #: build/C/man2/shmget.2:229
7841 msgid ""
7842 "The B<SHM_HUGETLB> flag was specified, but the caller was not privileged "
7843 "(did not have the B<CAP_IPC_LOCK> capability)."
7844 msgstr ""
7845 "B<SHM_HUGETLB> フラグが指定されたが、呼び出し元には権限がなかった "
7846 "(B<CAP_IPC_LOCK> ケーパビリティを持っていなかった)。"
7847
7848 #. type: Plain text
7849 #: build/C/man2/shmget.2:235
7850 msgid "B<SHM_HUGETLB> is a nonportable Linux extension."
7851 msgstr "B<SHM_HUGETLB> は Linux での拡張であり、移植性はない。"
7852
7853 #. type: Plain text
7854 #: build/C/man2/shmget.2:245
7855 msgid ""
7856 "B<IPC_PRIVATE> isn't a flag field but a I<key_t> type.  If this special "
7857 "value is used for I<key>, the system call ignores everything but the least "
7858 "significant 9 bits of I<shmflg> and creates a new shared memory segment (on "
7859 "success)."
7860 msgstr ""
7861 "B<IPC_PRIVATE> はフラグではなく I<key_t> 型である。 この特別な値が I<key> に"
7862 "使用された場合は、 B<shmget>()  は I<shmflg> の下位 9 ビットを除いた全てを無"
7863 "視し、 (成功すれば) 新しい共有メモリ・セグメントを作成する。"
7864
7865 #. type: Plain text
7866 #: build/C/man2/shmget.2:249
7867 msgid ""
7868 "The following limits on shared memory segment resources affect the B<shmget>"
7869 "()  call:"
7870 msgstr ""
7871 "B<shmget>()  コールに影響する共有メモリ・セグメント資源の制限は以下の通りであ"
7872 "る:"
7873
7874 #. type: TP
7875 #: build/C/man2/shmget.2:249
7876 #, no-wrap
7877 msgid "B<SHMALL>"
7878 msgstr "B<SHMALL>"
7879
7880 #. type: Plain text
7881 #: build/C/man2/shmget.2:254
7882 msgid ""
7883 "System wide maximum of shared memory pages (on Linux, this limit can be read "
7884 "and modified via I</proc/sys/kernel/shmall>)."
7885 msgstr ""
7886 "システム全体の共有メモリ・ページの最大数 (Linux では、この上限値は I</proc/"
7887 "sys/kernel/shmall> 経由で参照したり、変更したりできる)。"
7888
7889 #. type: TP
7890 #: build/C/man2/shmget.2:254
7891 #, no-wrap
7892 msgid "B<SHMMAX>"
7893 msgstr "B<SHMMAX>"
7894
7895 #. type: Plain text
7896 #: build/C/man2/shmget.2:259
7897 msgid ""
7898 "Maximum size in bytes for a shared memory segment: policy dependent (on "
7899 "Linux, this limit can be read and modified via I</proc/sys/kernel/shmmax>)."
7900 msgstr ""
7901 "共有メモリ・セグメントのバイト単位の大きさの上限: 方針依存 (Linux では、この"
7902 "上限値は I</proc/sys/kernel/shmmax> 経由で参照したり、変更したりできる)。"
7903
7904 #. type: TP
7905 #: build/C/man2/shmget.2:259
7906 #, no-wrap
7907 msgid "B<SHMMIN>"
7908 msgstr "B<SHMMIN>"
7909
7910 #. type: Plain text
7911 #: build/C/man2/shmget.2:265
7912 msgid ""
7913 "Minimum size in bytes for a shared memory segment: implementation dependent "
7914 "(currently 1 byte, though B<PAGE_SIZE> is the effective minimum size)."
7915 msgstr ""
7916 "共有メモリ・セグメントのバイト単位の大きさの下限: 実装依存 (現在は 1 バイトだ"
7917 "が、実質的な最小サイズは B<PAGE_SIZE> である)。"
7918
7919 #. type: TP
7920 #: build/C/man2/shmget.2:265
7921 #, no-wrap
7922 msgid "B<SHMMNI>"
7923 msgstr "B<SHMMNI>"
7924
7925 #.  Kernels between 2.4.x and 2.6.8 had an off-by-one error that meant
7926 #.  that we could create one more segment than SHMMNI -- MTK
7927 #.  This /proc file is not available in Linux 2.2 and earlier -- MTK
7928 #. type: Plain text
7929 #: build/C/man2/shmget.2:274
7930 msgid ""
7931 "System wide maximum number of shared memory segments: implementation "
7932 "dependent (currently 4096, was 128 before Linux 2.3.99; on Linux, this limit "
7933 "can be read and modified via I</proc/sys/kernel/shmmni>)."
7934 msgstr ""
7935 "システム全体の共有メモリーの数の上限: 実装依存 (現在は 4096。Linux 2.3.99 よ"
7936 "り前では 128。 Linux では、この上限値は I</proc/sys/kernel/shmmni> 経由で参照"
7937 "したり、変更したりできる)。"
7938
7939 #. type: Plain text
7940 #: build/C/man2/shmget.2:278
7941 msgid ""
7942 "The implementation has no specific limits for the per-process maximum number "
7943 "of shared memory segments (B<SHMSEG>)."
7944 msgstr ""
7945 "プロセス当りの共有メモリ・セグメントの個数の最大値 (B<SHMSEG>)  に関する実装"
7946 "上の制限はない。"
7947
7948 #. type: Plain text
7949 #: build/C/man2/shmget.2:284
7950 msgid ""
7951 "Until version 2.3.30 Linux would return B<EIDRM> for a B<shmget>()  on a "
7952 "shared memory segment scheduled for deletion."
7953 msgstr ""
7954 "バージョン 2.3.30 までは、Linux は 削除が予定されている共有メモリ・セグメント"
7955 "に対して B<shmget>()  が行われると B<EIDRM> を返していた。"
7956
7957 #. type: Plain text
7958 #: build/C/man2/shmget.2:290
7959 msgid ""
7960 "The name choice B<IPC_PRIVATE> was perhaps unfortunate, B<IPC_NEW> would "
7961 "more clearly show its function."
7962 msgstr ""
7963 "B<IPC_PRIVATE> という名前を選んだのはおそらく失敗であろう。 B<IPC_NEW> の方が"
7964 "より明確にその機能を表しているだろう。"
7965
7966 #. type: Plain text
7967 #: build/C/man2/shmget.2:297
7968 msgid ""
7969 "B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), "
7970 "B<shm_overview>(7), B<svipc>(7)"
7971 msgstr ""
7972 "B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), "
7973 "B<shm_overview>(7), B<svipc>(7)"
7974
7975 #. type: TH
7976 #: build/C/man2/shmop.2:39
7977 #, no-wrap
7978 msgid "SHMOP"
7979 msgstr "SHMOP"
7980
7981 #. type: TH
7982 #: build/C/man2/shmop.2:39
7983 #, no-wrap
7984 msgid "2008-06-03"
7985 msgstr "2008-06-03"
7986
7987 #. type: Plain text
7988 #: build/C/man2/shmop.2:42
7989 msgid "shmat, shmdt - shared memory operations"
7990 msgstr "shmat, shmdt - 共有メモリ (shared memory) の操作"
7991
7992 #. type: Plain text
7993 #: build/C/man2/shmop.2:46
7994 #, no-wrap
7995 msgid ""
7996 "B<#include E<lt>sys/types.hE<gt>>\n"
7997 "B<#include E<lt>sys/shm.hE<gt>>\n"
7998 msgstr ""
7999 "B<#include E<lt>sys/types.hE<gt>>\n"
8000 "B<#include E<lt>sys/shm.hE<gt>>\n"
8001
8002 #. type: Plain text
8003 #: build/C/man2/shmop.2:48
8004 #, no-wrap
8005 msgid "B<void *shmat(int >I<shmid>B<, const void *>I<shmaddr>B<, int >I<shmflg>B<);>\n"
8006 msgstr "B<void *shmat(int >I<shmid>B<, const void *>I<shmaddr>B<, int >I<shmflg>B<);>\n"
8007
8008 #. type: Plain text
8009 #: build/C/man2/shmop.2:50
8010 #, no-wrap
8011 msgid "B<int shmdt(const void *>I<shmaddr>B<);>\n"
8012 msgstr "B<int shmdt(const void *>I<shmaddr>B<);>\n"
8013
8014 #. type: Plain text
8015 #: build/C/man2/shmop.2:59
8016 msgid ""
8017 "B<shmat>()  attaches the shared memory segment identified by I<shmid> to the "
8018 "address space of the calling process.  The attaching address is specified by "
8019 "I<shmaddr> with one of the following criteria:"
8020 msgstr ""
8021 "B<shmat>()  は I<shmid> で指定された共有メモリ・セグメント (shared memory "
8022 "segment) を コールしたプロセスのアドレス空間に付加 (attach) する。 付加するア"
8023 "ドレスは I<shmaddr> に以下のどれかの形式で指定する:"
8024
8025 #. type: Plain text
8026 #: build/C/man2/shmop.2:65
8027 msgid ""
8028 "If I<shmaddr> is NULL, the system chooses a suitable (unused) address at "
8029 "which to attach the segment."
8030 msgstr ""
8031 "I<shmaddr> が NULL ならば、システムはセグメントを付加するための 適切な (使用"
8032 "されていない) アドレスを選択する。"
8033
8034 #. type: Plain text
8035 #: build/C/man2/shmop.2:80
8036 msgid ""
8037 "If I<shmaddr> isn't NULL and B<SHM_RND> is specified in I<shmflg>, the "
8038 "attach occurs at the address equal to I<shmaddr> rounded down to the nearest "
8039 "multiple of B<SHMLBA>.  Otherwise I<shmaddr> must be a page-aligned address "
8040 "at which the attach occurs."
8041 msgstr ""
8042 "I<shmaddr> が NULL でなく B<SHM_RND> が I<shmflg> に指定されている場合は、 "
8043 "I<shmaddr> を B<SHMLBA> の倍数へと切り捨てた (rounding down) のと等しいアドレ"
8044 "スへ付加する。 その他の場合は I<shmaddr> は付加を行なうアドレスで、ページ境界"
8045 "を指している必要がある。"
8046
8047 #. type: Plain text
8048 #: build/C/man2/shmop.2:90
8049 msgid ""
8050 "If B<SHM_RDONLY> is specified in I<shmflg>, the segment is attached for "
8051 "reading and the process must have read permission for the segment.  "
8052 "Otherwise the segment is attached for read and write and the process must "
8053 "have read and write permission for the segment.  There is no notion of a "
8054 "write-only shared memory segment."
8055 msgstr ""
8056 "B<SHM_RDONLY> が I<shmflg> に指定されていた場合は、 セグメントは読み込み専用"
8057 "に付加され、プロセスはそのセグメントへの 読み込み許可を持たなければならな"
8058 "い。 そうでなければそのセグメントは読み込みと書き込みのために付加され、 プロ"
8059 "セスはそのセグメントに読み込みと書き込みの許可を持つ必要がある。 書き込み専用"
8060 "の共有メモリ・セグメントという概念は存在しない。"
8061
8062 #. type: Plain text
8063 #: build/C/man2/shmop.2:105
8064 msgid ""
8065 "The (Linux-specific)  B<SHM_REMAP> flag may be specified in I<shmflg> to "
8066 "indicate that the mapping of the segment should replace any existing mapping "
8067 "in the range starting at I<shmaddr> and continuing for the size of the "
8068 "segment.  (Normally an B<EINVAL> error would result if a mapping already "
8069 "exists in this address range.)  In this case, I<shmaddr> must not be NULL."
8070 msgstr ""
8071 "(Linux 特有の)  B<SHM_REMAP> フラグが I<shmflg> に指定された場合は、 セグメン"
8072 "トのマッピングを既存のマッピングに置き換える。 マッピングの範囲は、 "
8073 "I<shmaddr> から始まりセグメントのサイズ分だけある (通常 B<EINVAL> エラーは、"
8074 "このアドレス範囲にマッピングが既に存在するために起る)。 このフラグを指定する"
8075 "場合は、 I<shmaddr> が NULL であってはならない。"
8076
8077 #. type: Plain text
8078 #: build/C/man2/shmop.2:112
8079 msgid ""
8080 "The B<brk>(2)  value of the calling process is not altered by the attach.  "
8081 "The segment will automatically be detached at process exit.  The same "
8082 "segment may be attached as a read and as a read-write one, and more than "
8083 "once, in the process's address space."
8084 msgstr ""
8085 "呼び出したプロセスの B<brk>(2)  の値は付加によって変化しない。 そのセグメント"
8086 "はプロセスが終了 (exit) したら自動的に分離 (detach) される。 同じセグメントを"
8087 "プロセスのアドレス空間に、読み込み専用および読み書き両用 として付加でき、また"
8088 "複数回付加することもできる。"
8089
8090 #. type: Plain text
8091 #: build/C/man2/shmop.2:120
8092 msgid ""
8093 "A successful B<shmat>()  call updates the members of the I<shmid_ds> "
8094 "structure (see B<shmctl>(2))  associated with the shared memory segment as "
8095 "follows:"
8096 msgstr ""
8097 "成功した B<shmat>()  コールは共有メモリ・セグメントに関連する I<shmid_ds> 構"
8098 "造体 (B<shmctl>(2)  を参照) のメンバーを以下のように更新する:"
8099
8100 #. type: Plain text
8101 #: build/C/man2/shmop.2:123
8102 msgid "I<shm_atime> is set to the current time."
8103 msgstr "I<shm_atime> には現在の時刻を設定する。"
8104
8105 #. type: Plain text
8106 #: build/C/man2/shmop.2:126 build/C/man2/shmop.2:152
8107 msgid "I<shm_lpid> is set to the process-ID of the calling process."
8108 msgstr "I<shm_lpid> には呼び出したプロセスのプロセス ID が設定される。"
8109
8110 #. type: Plain text
8111 #: build/C/man2/shmop.2:129
8112 msgid "I<shm_nattch> is incremented by one."
8113 msgstr "I<shm_nattch> を 1 増加させる。"
8114
8115 #. type: Plain text
8116 #: build/C/man2/shmop.2:140
8117 msgid ""
8118 "B<shmdt>()  detaches the shared memory segment located at the address "
8119 "specified by I<shmaddr> from the address space of the calling process.  The "
8120 "to-be-detached segment must be currently attached with I<shmaddr> equal to "
8121 "the value returned by the attaching B<shmat>()  call."
8122 msgstr ""
8123 "B<shmdt>()  は呼び出したプロセスのアドレス空間から I<shmaddr> で指定されたア"
8124 "ドレスに配置された共有メモリ・セグメントを分離 (detach) する。 分離する共有メ"
8125 "モリ・セグメントは、現在 I<shmaddr> に付加されているものでなければならない。 "
8126 "I<shmaddr> は、それを付加した時に B<shmat>()  が返した値に等しくなければなら"
8127 "ない。"
8128
8129 #. type: Plain text
8130 #: build/C/man2/shmop.2:146
8131 msgid ""
8132 "On a successful B<shmdt>()  call the system updates the members of the "
8133 "I<shmid_ds> structure associated with the shared memory segment as follows:"
8134 msgstr ""
8135 "成功した B<shmdt>()  コールはその共有メモリ・セグメントに関連する "
8136 "I<shmid_ds> 構造体のメンバーを以下のように更新する:"
8137
8138 #. type: Plain text
8139 #: build/C/man2/shmop.2:149
8140 msgid "I<shm_dtime> is set to the current time."
8141 msgstr "I<shm_dtime> には現在の時刻が設定される。"
8142
8143 #. type: Plain text
8144 #: build/C/man2/shmop.2:157
8145 msgid ""
8146 "I<shm_nattch> is decremented by one.  If it becomes 0 and the segment is "
8147 "marked for deletion, the segment is deleted."
8148 msgstr ""
8149 "I<shm_nattch> を 1 減少させる。 もし 0 になり、削除マークがあった場合は その"
8150 "セグメントは削除される。"
8151
8152 #. type: Plain text
8153 #: build/C/man2/shmop.2:161
8154 msgid ""
8155 "After a B<fork>(2)  the child inherits the attached shared memory segments."
8156 msgstr ""
8157 "B<fork>(2)  した後、子プロセスは付加された共有メモリ・セグメントを継承する。"
8158
8159 #. type: Plain text
8160 #: build/C/man2/shmop.2:165
8161 msgid ""
8162 "After an B<execve>(2)  all attached shared memory segments are detached from "
8163 "the process."
8164 msgstr ""
8165 "B<exec>(2)  した後、全ての付加された共有メモリ・セグメントはプロセスから分離"
8166 "される。"
8167
8168 #. type: Plain text
8169 #: build/C/man2/shmop.2:169
8170 msgid ""
8171 "Upon B<_exit>(2)  all attached shared memory segments are detached from the "
8172 "process."
8173 msgstr ""
8174 "B<exit>(2)  において、全ての付加された共有メモリ・セグメントはプロセスから分"
8175 "離される。"
8176
8177 #. type: Plain text
8178 #: build/C/man2/shmop.2:177
8179 msgid ""
8180 "On success B<shmat>()  returns the address of the attached shared memory "
8181 "segment; on error I<(void\\ *)\\ -1> is returned, and I<errno> is set to "
8182 "indicate the cause of the error."
8183 msgstr ""
8184 "B<shmat>()  は、成功した場合、 付加された共有メモリ・セグメントのアドレスを返"
8185 "す。 エラーの場合、 I<(void\\ *)\\ -1> を返し、 I<errno> にエラーの原因を示す"
8186 "値を設定する。"
8187
8188 #. type: Plain text
8189 #: build/C/man2/shmop.2:183
8190 msgid ""
8191 "On success B<shmdt>()  returns 0; on error -1 is returned, and I<errno> is "
8192 "set to indicate the cause of the error."
8193 msgstr ""
8194 "B<shmdt>()  は、成功すると 0 を返す。 エラーの場合、-1 を返し、 I<errno> にエ"
8195 "ラーの原因を示す値を設定する。"
8196
8197 #. type: Plain text
8198 #: build/C/man2/shmop.2:189
8199 msgid "When B<shmat>()  fails, I<errno> is set to one of the following:"
8200 msgstr ""
8201 "B<shmat>()  が失敗した場合、 I<errno> に以下の値のどれかを設定して返す:"
8202
8203 #. type: Plain text
8204 #: build/C/man2/shmop.2:195
8205 msgid ""
8206 "The calling process does not have the required permissions for the requested "
8207 "attach type, and does not have the B<CAP_IPC_OWNER> capability."
8208 msgstr ""
8209 "呼び出したプロセスに要求された種類の付加に必要な許可がなく、 "
8210 "B<CAP_IPC_OWNER> ケーパビリティ (capability) がない。"
8211
8212 #. type: Plain text
8213 #: build/C/man2/shmop.2:209
8214 msgid ""
8215 "Invalid I<shmid> value, unaligned (i.e., not page-aligned and B<SHM_RND> was "
8216 "not specified) or invalid I<shmaddr> value, or can't attach segment at "
8217 "I<shmaddr>, or B<SHM_REMAP> was specified and I<shmaddr> was NULL."
8218 msgstr ""
8219 "I<shmid> の値が不正である。 I<shmaddr> の値が境界違反 (unaligned) (つまり、"
8220 "ページ境界に合っておらず、 B<SHM_RND> が指定されていない) または が不正であ"
8221 "る。 I<shmaddr> へのセグメントの付加に失敗した。 または B<SHM_REMAP> が指定さ"
8222 "れているが、 I<shmaddr> が NULL であった。"
8223
8224 #. type: Plain text
8225 #: build/C/man2/shmop.2:212
8226 msgid "Could not allocate memory for the descriptor or for the page tables."
8227 msgstr ""
8228 "ディスクリプター (descriptor) やページ・テーブルのためのメモリを 割り当てるこ"
8229 "とができない。"
8230
8231 #. type: Plain text
8232 #: build/C/man2/shmop.2:218
8233 msgid "When B<shmdt>()  fails, I<errno> is set as follows:"
8234 msgstr "B<shmdt>()  が失敗した場合、 B<EINVAL> は以下のようにセットされる:"
8235
8236 #.  The following since 2.6.17-rc1:
8237 #. type: Plain text
8238 #: build/C/man2/shmop.2:226
8239 msgid ""
8240 "There is no shared memory segment attached at I<shmaddr>; or, I<shmaddr> is "
8241 "not aligned on a page boundary."
8242 msgstr ""
8243 "I<shmaddr> に付加された共有メモリ・セグメントが存在しない。 もしくは、 "
8244 "I<shmaddr> がページ境界に合っていない。"
8245
8246 #. type: Plain text
8247 #: build/C/man2/shmop.2:245
8248 msgid ""
8249 "In SVID 3 (or perhaps earlier)  the type of the I<shmaddr> argument was "
8250 "changed from I<char *> into I<const void *>, and the returned type of "
8251 "B<shmat>()  from I<char *> into I<void *>.  (Linux libc4 and libc5 have the "
8252 "I<char *> prototypes; glibc2 has I<void *>.)"
8253 msgstr ""
8254 "SVID 3 で (たぶんそれより前だと思うが)  I<shmaddr> 引き数の型は I<char *> か"
8255 "ら I<const void *> に、I<shmat>() の返り値の型は I<char *> から I<void *> に"
8256 "変更された (Linux では libc4 と libc5 のプロトタイプは I<char *> であり、"
8257 "glibc2 のプロトタイプは I<void *> である)。"
8258
8259 #. type: Plain text
8260 #: build/C/man2/shmop.2:257
8261 msgid ""
8262 "Using B<shmat>()  with I<shmaddr> equal to NULL is the preferred, portable "
8263 "way of attaching a shared memory segment.  Be aware that the shared memory "
8264 "segment attached in this way may be attached at different addresses in "
8265 "different processes.  Therefore, any pointers maintained within the shared "
8266 "memory must be made relative (typically to the starting address of the "
8267 "segment), rather than absolute."
8268 msgstr ""
8269 "共有メモリセグメントを付加する場合の移植性の高い方法としては、 I<shmaddr> を "
8270 "NULL にして B<shmat>()  を使用するのがよい。 このような方法で付加される共有メ"
8271 "モリセグメントは、 プロセスが異なれば別のアドレスに付加される、という点に注意"
8272 "すること。 よって共有メモリ内で管理されるポインタは、 絶対アドレスではなく、 "
8273 "(一般的にはセグメントの開始アドレスからの)  相対アドレスで作成するべきであ"
8274 "る。"
8275
8276 #. type: Plain text
8277 #: build/C/man2/shmop.2:262
8278 msgid ""
8279 "On Linux, it is possible to attach a shared memory segment even if it is "
8280 "already marked to be deleted.  However, POSIX.1-2001 does not specify this "
8281 "behavior and many other implementations do not support it."
8282 msgstr ""
8283 "Linux では共有メモリセグメントに既に削除マークが付けられていても、 その共有メ"
8284 "モリセグメントを付加することができる。 しかし POSIX.1-2001 ではこのような動作"
8285 "を指定しておらず、 他の多くの実装もこれをサポートしていない。"
8286
8287 #. type: Plain text
8288 #: build/C/man2/shmop.2:265
8289 msgid "The following system parameter affects B<shmat>():"
8290 msgstr "以下のシステム・パラメーターは、 B<shmat>()  に影響する:"
8291
8292 #.  FIXME A good explanation of the rationale for the existence
8293 #.  of SHMLBA would be useful here
8294 #. type: TP
8295 #: build/C/man2/shmop.2:265
8296 #, no-wrap
8297 msgid "B<SHMLBA>"
8298 msgstr "B<SHMLBA>"
8299
8300 #.  FIXME That last sentence isn't true for all Linux
8301 #.  architectures (i.e., SHMLBA != PAGE_SIZE for some architectures)
8302 #.  -- MTK, Nov 04
8303 #. type: Plain text
8304 #: build/C/man2/shmop.2:278
8305 msgid ""
8306 "Segment low boundary address multiple.  Must be page aligned.  For the "
8307 "current implementation the B<SHMLBA> value is B<PAGE_SIZE>."
8308 msgstr ""
8309 "セグメントの境界アドレスの最小倍数。ページ境界に合ってなければならない。 現在"
8310 "の実装では B<SHMLBA> の値は B<PAGE_SIZE> である。"
8311
8312 #. type: Plain text
8313 #: build/C/man2/shmop.2:282
8314 msgid ""
8315 "The implementation places no intrinsic limit on the per-process maximum "
8316 "number of shared memory segments (B<SHMSEG>)."
8317 msgstr ""
8318 "現在の実装では、プロセスごとの 共有メモリ・セグメントの最大数 (B<SHMSEG>)  に"
8319 "関する実装依存の制限はない。"
8320
8321 #. type: Plain text
8322 #: build/C/man2/shmop.2:289
8323 msgid ""
8324 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
8325 "B<shm_overview>(7), B<svipc>(7)"
8326 msgstr ""
8327 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
8328 "B<shm_overview>(7), B<svipc>(7)"
8329
8330 #. type: TH
8331 #: build/C/man2/subpage_prot.2:28
8332 #, no-wrap
8333 msgid "SUBPAGE_PROT"
8334 msgstr "SUBPAGE_PROT"
8335
8336 #. type: TH
8337 #: build/C/man2/subpage_prot.2:28
8338 #, no-wrap
8339 msgid "2010-10-30"
8340 msgstr "2010-10-30"
8341
8342 #. type: Plain text
8343 #: build/C/man2/subpage_prot.2:31
8344 msgid "subpage_prot - define a subpage protection for an address range"
8345 msgstr "subpage_prot - define a subpage protection for an address range"
8346
8347 #. type: Plain text
8348 #: build/C/man2/subpage_prot.2:35
8349 #, no-wrap
8350 msgid ""
8351 "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
8352 "B<                  uint32_t *>I<map>B<);>\n"
8353 msgstr ""
8354 "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
8355 "B<                  uint32_t *>I<map>B<);>\n"
8356
8357 #. type: Plain text
8358 #: build/C/man2/subpage_prot.2:42
8359 msgid ""
8360 "The PowerPC-specific B<subpage_prot>()  system call provides the facility to "
8361 "control the access permissions on individual 4kB subpages on systems "
8362 "configured with a page size of 64kB."
8363 msgstr ""
8364 "The PowerPC-specific B<subpage_prot>()  system call provides the facility to "
8365 "control the access permissions on individual 4kB subpages on systems "
8366 "configured with a page size of 64kB."
8367
8368 #. type: Plain text
8369 #: build/C/man2/subpage_prot.2:49
8370 msgid ""
8371 "The protection map is applied to the memory pages in the region starting at "
8372 "I<addr> and continuing for I<len> bytes.  Both of these arguments must be "
8373 "aligned to a 64-kB boundary."
8374 msgstr ""
8375 "The protection map is applied to the memory pages in the region starting at "
8376 "I<addr> and continuing for I<len> bytes.  Both of these arguments must be "
8377 "aligned to a 64-kB boundary."
8378
8379 #. type: Plain text
8380 #: build/C/man2/subpage_prot.2:61
8381 msgid ""
8382 "The protection map is specified in the buffer pointed to by I<map>.  The map "
8383 "has 2 bits per 4kB subpage; thus each 32-bit word specifies the protections "
8384 "of 16 4kB subpages inside a 64kB page (so, the number of 32-bit words "
8385 "pointed to by I<map> should equate to the number of 64-kB pages specified by "
8386 "I<len>).  Each 2-bit field in the protection map is either 0 to allow any "
8387 "access, 1 to prevent writes, or 2 or 3 to prevent all accesses."
8388 msgstr ""
8389 "The protection map is specified in the buffer pointed to by I<map>.  The map "
8390 "has 2 bits per 4kB subpage; thus each 32-bit word specifies the protections "
8391 "of 16 4kB subpages inside a 64kB page (so, the number of 32-bit words "
8392 "pointed to by I<map> should equate to the number of 64-kB pages specified by "
8393 "I<len>).  Each 2-bit field in the protection map is either 0 to allow any "
8394 "access, 1 to prevent writes, or 2 or 3 to prevent all accesses."
8395
8396 #. type: Plain text
8397 #: build/C/man2/subpage_prot.2:66
8398 msgid ""
8399 "On success, B<subpage_prot>()  returns 0.  Otherwise, one of the error codes "
8400 "specified below is returned."
8401 msgstr ""
8402 "On success, B<subpage_prot>()  returns 0.  Otherwise, one of the error codes "
8403 "specified below is returned."
8404
8405 #. type: Plain text
8406 #: build/C/man2/subpage_prot.2:72
8407 msgid "The buffer referred to by I<map> is not accessible."
8408 msgstr "The buffer referred to by I<map> is not accessible."
8409
8410 #. type: Plain text
8411 #: build/C/man2/subpage_prot.2:82
8412 msgid ""
8413 "The I<addr> or I<len> arguments are incorrect.  Both of these arguments must "
8414 "be aligned to a multiple of the system page size, and they must not refer to "
8415 "a region outside of the address space of the process or to a region that "
8416 "consists of huge pages."
8417 msgstr ""
8418 "The I<addr> or I<len> arguments are incorrect.  Both of these arguments must "
8419 "be aligned to a multiple of the system page size, and they must not refer to "
8420 "a region outside of the address space of the process or to a region that "
8421 "consists of huge pages."
8422
8423 #. type: Plain text
8424 #: build/C/man2/subpage_prot.2:85 build/C/man2/sync_file_range.2:166
8425 msgid "Out of memory."
8426 msgstr "メモリ不足である。"
8427
8428 #. type: Plain text
8429 #: build/C/man2/subpage_prot.2:91
8430 msgid ""
8431 "This system call is provided on the PowerPC architecture since Linux "
8432 "2.6.25.  The system call is provided only if the kernel is configured with "
8433 "B<CONFIG_PPC_64K_PAGES>.  No library support is provided."
8434 msgstr ""
8435 "This system call is provided on the PowerPC architecture since Linux "
8436 "2.6.25.  The system call is provided only if the kernel is configured with "
8437 "B<CONFIG_PPC_64K_PAGES>.  No library support is provided."
8438
8439 #. type: Plain text
8440 #: build/C/man2/subpage_prot.2:98
8441 msgid ""
8442 "Normal page protections (at the 64-kB page level) also apply; the subpage "
8443 "protection mechanism is an additional constraint, so putting 0 in a 2-bit "
8444 "field won't allow writes to a page that is otherwise write-protected."
8445 msgstr ""
8446 "Normal page protections (at the 64-kB page level) also apply; the subpage "
8447 "protection mechanism is an additional constraint, so putting 0 in a 2-bit "
8448 "field won't allow writes to a page that is otherwise write-protected."
8449
8450 #. type: SS
8451 #: build/C/man2/subpage_prot.2:98
8452 #, no-wrap
8453 msgid "Rationale"
8454 msgstr "Rationale"
8455
8456 #.  In the initial implementation, it was the case that:
8457 #.      In fact the whole process is switched to use 4k hardware pages when the
8458 #.      subpage_prot system call is used, but this could be improved in future
8459 #.      to switch only the affected segments.
8460 #.  But Paul Mackerass says (Oct 2010): I'm pretty sure we now only switch
8461 #.  the affected segment, not the whole process.
8462 #. type: Plain text
8463 #: build/C/man2/subpage_prot.2:120
8464 msgid ""
8465 "This system call is provided to assist writing emulators that operate using "
8466 "64-kB pages on PowerPC systems.  When emulating systems such as x86, which "
8467 "uses a smaller page size, the emulator can no longer use the memory-"
8468 "management unit (MMU)  and normal system calls for controlling page "
8469 "protections.  (The emulator could emulate the MMU by checking and possibly "
8470 "remapping the address for each memory access in software, but that is "
8471 "slow.)  The idea is that the emulator supplies an array of protection masks "
8472 "to apply to a specified range of virtual addresses.  These masks are applied "
8473 "at the level where hardware page-table entries (PTEs)  are inserted into the "
8474 "hardware page table based on the Linux PTEs, so the Linux PTEs are not "
8475 "affected.  Implicit in this is that the regions of the address space that "
8476 "are protected are switched to use 4-kB hardware pages rather than 64-kB "
8477 "hardware pages (on machines with hardware 64-kB page support)."
8478 msgstr ""
8479 "This system call is provided to assist writing emulators that operate using "
8480 "64-kB pages on PowerPC systems.  When emulating systems such as x86, which "
8481 "uses a smaller page size, the emulator can no longer use the memory-"
8482 "management unit (MMU)  and normal system calls for controlling page "
8483 "protections.  (The emulator could emulate the MMU by checking and possibly "
8484 "remapping the address for each memory access in software, but that is "
8485 "slow.)  The idea is that the emulator supplies an array of protection masks "
8486 "to apply to a specified range of virtual addresses.  These masks are applied "
8487 "at the level where hardware page-table entries (PTEs)  are inserted into the "
8488 "hardware page table based on the Linux PTEs, so the Linux PTEs are not "
8489 "affected.  Implicit in this is that the regions of the address space that "
8490 "are protected are switched to use 4-kB hardware pages rather than 64-kB "
8491 "hardware pages (on machines with hardware 64-kB page support)."
8492
8493 #. type: Plain text
8494 #: build/C/man2/subpage_prot.2:123
8495 msgid "B<mprotect>(2), B<syscall>(2);"
8496 msgstr "B<mprotect>(2), B<syscall>(2);"
8497
8498 #. type: Plain text
8499 #: build/C/man2/subpage_prot.2:125
8500 msgid "the kernel source file I<Documentation/vm/hugetlbpage.txt>."
8501 msgstr "the kernel source file I<Documentation/vm/hugetlbpage.txt>."
8502
8503 #. type: TH
8504 #: build/C/man2/sync_file_range.2:30
8505 #, no-wrap
8506 msgid "SYNC_FILE_RANGE"
8507 msgstr "SYNC_FILE_RANGE"
8508
8509 #. type: Plain text
8510 #: build/C/man2/sync_file_range.2:33
8511 msgid "sync_file_range - sync a file segment with disk"
8512 msgstr "sync_file_range - ファイルセグメントをディスクと同期する"
8513
8514 #. type: Plain text
8515 #: build/C/man2/sync_file_range.2:37
8516 #, no-wrap
8517 msgid ""
8518 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
8519 "B<#include E<lt>fcntl.hE<gt>>\n"
8520 msgstr ""
8521 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
8522 "B<#include E<lt>fcntl.hE<gt>>\n"
8523
8524 #. type: Plain text
8525 #: build/C/man2/sync_file_range.2:40
8526 #, no-wrap
8527 msgid ""
8528 "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
8529 "B<                    unsigned int >I<flags>B<);>\n"
8530 msgstr ""
8531 "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
8532 "B<                    unsigned int >I<flags>B<);>\n"
8533
8534 #. type: Plain text
8535 #: build/C/man2/sync_file_range.2:47
8536 msgid ""
8537 "B<sync_file_range>()  permits fine control when synchronizing the open file "
8538 "referred to by the file descriptor I<fd> with disk."
8539 msgstr ""
8540 "B<sync_file_range>()  を使うと、ファイルディスクリプタ I<fd> で参照されるオー"
8541 "プンされたファイルのディスクとの同期に関して、 きめ細かな制御が可能となる。"
8542
8543 #. type: Plain text
8544 #: build/C/man2/sync_file_range.2:61
8545 msgid ""
8546 "I<offset> is the starting byte of the file range to be synchronized.  "
8547 "I<nbytes> specifies the length of the range to be synchronized, in bytes; if "
8548 "I<nbytes> is zero, then all bytes from I<offset> through to the end of file "
8549 "are synchronized.  Synchronization is in units of the system page size: "
8550 "I<offset> is rounded down to a page boundary; I<(offset+nbytes-1)> is "
8551 "rounded up to a page boundary."
8552 msgstr ""
8553 "I<offset> は、同期を行うファイルの領域の開始バイトである。 I<nbytes> には同期"
8554 "を行う領域の長さをバイト単位で指定する。 I<nbytes> が 0 の場合は、 I<offset> "
8555 "からファイル末尾までの全バイトを同期する。 同期はシステムのページサイズの単位"
8556 "で行われる。 I<offset> はページ境界にあわせて切り下げられ、 I<(offset"
8557 "+nbytes-1)> はページ境界にあわせて切り上げられる。"
8558
8559 #. type: Plain text
8560 #: build/C/man2/sync_file_range.2:65
8561 msgid "The I<flags> bit-mask argument can include any of the following values:"
8562 msgstr "ビットマスク引き数 I<flags> には以下の値を指定することができる:"
8563
8564 #. type: TP
8565 #: build/C/man2/sync_file_range.2:65
8566 #, no-wrap
8567 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE>"
8568 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE>"
8569
8570 #. type: Plain text
8571 #: build/C/man2/sync_file_range.2:70
8572 msgid ""
8573 "Wait upon write-out of all pages in the specified range that have already "
8574 "been submitted to the device driver for write-out before performing any "
8575 "write."
8576 msgstr ""
8577 "何らかの書き込みを行う前に、指定された領域のページで 書き出しを行うようにデバ"
8578 "イスドライバにすでに要求が発行されている ページの書き出しが全て完了するのを待"
8579 "つ。"
8580
8581 #. type: TP
8582 #: build/C/man2/sync_file_range.2:70 build/C/man2/sync_file_range.2:120
8583 #, no-wrap
8584 msgid "B<SYNC_FILE_RANGE_WRITE>"
8585 msgstr "B<SYNC_FILE_RANGE_WRITE>"
8586
8587 #. type: Plain text
8588 #: build/C/man2/sync_file_range.2:76
8589 msgid ""
8590 "Initiate write-out of all dirty pages in the specified range which are not "
8591 "presently submitted write-out.  Note that even this may block if you attempt "
8592 "to write more than request queue size."
8593 msgstr ""
8594 "指定された領域のページで、書き出し要求が発行されていない 全ての dirty (キャッ"
8595 "シュだけが変更されている) ページの 書き出しを開始する。 リクエストキューの大"
8596 "きさより多く書き込もうとした場合には、 この処理は停止 (block) する可能性があ"
8597 "る点に注意すること。"
8598
8599 #. type: TP
8600 #: build/C/man2/sync_file_range.2:76
8601 #, no-wrap
8602 msgid "B<SYNC_FILE_RANGE_WAIT_AFTER>"
8603 msgstr "B<SYNC_FILE_RANGE_WAIT_AFTER>"
8604
8605 #. type: Plain text
8606 #: build/C/man2/sync_file_range.2:80
8607 msgid ""
8608 "Wait upon write-out of all pages in the range after performing any write."
8609 msgstr ""
8610 "何らかの書き込み後に、指定された領域の全てのページの 書き出しが行われるのを待"
8611 "つ。"
8612
8613 #. type: Plain text
8614 #: build/C/man2/sync_file_range.2:84
8615 msgid "Specifying I<flags> as 0 is permitted, as a no-op."
8616 msgstr "I<flags> に 0 を指定した場合、何もしないことを表す。"
8617
8618 #. type: SS
8619 #: build/C/man2/sync_file_range.2:84
8620 #, no-wrap
8621 msgid "Warning"
8622 msgstr "警告"
8623
8624 #. type: Plain text
8625 #: build/C/man2/sync_file_range.2:100
8626 msgid ""
8627 "This system call is extremely dangerous and should not be used in portable "
8628 "programs.  None of these operations writes out the file's metadata.  "
8629 "Therefore, unless the application is strictly performing overwrites of "
8630 "already-instantiated disk blocks, there are no guarantees that the data will "
8631 "be available after a crash.  There is no user interface to know if a write "
8632 "is purely an overwrite.  On file systems using copy-on-write semantics (e."
8633 "g., I<btrfs>)  an overwrite of existing allocated blocks is impossible.  "
8634 "When writing into preallocated space, many file systems also require calls "
8635 "into the block allocator, which this system call does not sync out to disk.  "
8636 "This system call does not flush disk write caches and thus does not provide "
8637 "any data integrity on systems with volatile disk write caches."
8638 msgstr ""
8639 "このシステムコールは非常に危険であり、 移植性が必要なプログラムで使用すべきで"
8640 "はない。 これらの操作ではどれもファイルのメタデータの書き出しを行わない。 し"
8641 "たがって、アプリケーションにより作成済みのディスクブロックの 上書きの実行が確"
8642 "実に行われない限り、クラッシュの後でもデータが 利用できる保証はない。 書き込"
8643 "みが上書きだけであるかを知るためのユーザインタフェースは存在しない。 "
8644 "(I<btrfs> などの) copy-on-write 動作を使ったファイルシステムでは、 既存の割り"
8645 "当て済みのブロックに対する上書き自体ができない。 前もって割り当てられた領域に"
8646 "書き込みを行う場合、 多くのファイルシステムでは block allocator への書き込み"
8647 "も必要となるが、 このシステムコールは block allocator のディスクへの同期を行"
8648 "わない。 このシステムコールはディスク書き込みキャッシュのフラッシュを 行わな"
8649 "いので、揮発性のディスク書き込みキャッシュを使ったシステムでは このシステム"
8650 "コールではデータの一貫性を確保できないことになる。"
8651
8652 #. type: SS
8653 #: build/C/man2/sync_file_range.2:100
8654 #, no-wrap
8655 msgid "Some details"
8656 msgstr "詳細"
8657
8658 #. type: Plain text
8659 #: build/C/man2/sync_file_range.2:108
8660 msgid ""
8661 "B<SYNC_FILE_RANGE_WAIT_BEFORE> and B<SYNC_FILE_RANGE_WAIT_AFTER> will detect "
8662 "any I/O errors or B<ENOSPC> conditions and will return these to the caller."
8663 msgstr ""
8664 "B<SYNC_FILE_RANGE_WAIT_BEFORE> と B<SYNC_FILE_RANGE_WAIT_AFTER> は I/O エラー"
8665 "や B<ENOSPC> 状態を検出し、呼び出し元にこれらの情報を返す。"
8666
8667 #. type: Plain text
8668 #: build/C/man2/sync_file_range.2:112
8669 msgid "Useful combinations of the I<flags> bits are:"
8670 msgstr "I<flags> の役に立つビットの組み合わせを以下に示す:"
8671
8672 #. type: TP
8673 #: build/C/man2/sync_file_range.2:112
8674 #, no-wrap
8675 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE>"
8676 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE>"
8677
8678 #. type: Plain text
8679 #: build/C/man2/sync_file_range.2:120
8680 msgid ""
8681 "Ensures that all pages in the specified range which were dirty when "
8682 "B<sync_file_range>()  was called are placed under write-out.  This is a "
8683 "start-write-for-data-integrity operation."
8684 msgstr ""
8685 "指定された範囲内のページで、 B<sync_file_range>()  が呼び出された際に dirty "
8686 "であった全てのページが、 確実に書き出し対象となるようにする。 これは、start-"
8687 "write-for-data-integrity 操作 (データ完全性確保のための書き込み開始の操作) で"
8688 "ある。"
8689
8690 #. type: Plain text
8691 #: build/C/man2/sync_file_range.2:127
8692 msgid ""
8693 "Start write-out of all dirty pages in the specified range which are not "
8694 "presently under write-out.  This is an asynchronous flush-to-disk "
8695 "operation.  This is not suitable for data integrity operations."
8696 msgstr ""
8697 "指定された範囲内のページで、現在書き出し中でない全ての dirty ページの 書き出"
8698 "しを開始する。これは非同期のディスクへのフラッシュ (flush-to-disk)  操作であ"
8699 "る。データ完全性確保が必要な操作としては適切ではない。"
8700
8701 #. type: TP
8702 #: build/C/man2/sync_file_range.2:127
8703 #, no-wrap
8704 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE> (or B<SYNC_FILE_RANGE_WAIT_AFTER>)"
8705 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE> (or B<SYNC_FILE_RANGE_WAIT_AFTER>)"
8706
8707 #. type: Plain text
8708 #: build/C/man2/sync_file_range.2:134
8709 msgid ""
8710 "Wait for completion of write-out of all pages in the specified range.  This "
8711 "can be used after an earlier B<SYNC_FILE_RANGE_WAIT_BEFORE | "
8712 "SYNC_FILE_RANGE_WRITE> operation to wait for completion of that operation, "
8713 "and obtain its result."
8714 msgstr ""
8715 "指定された範囲内の全てのページの書き出しの完了を待つ。 このフラグは、前に行わ"
8716 "れた操作 B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE> の後に使用で"
8717 "き、この操作の完了を待ち、結果を取得することができる。"
8718
8719 #. type: TP
8720 #: build/C/man2/sync_file_range.2:134
8721 #, no-wrap
8722 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE | SYNC_FILE_RANGE_WAIT_AFTER>"
8723 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE | SYNC_FILE_RANGE_WAIT_AFTER>"
8724
8725 #. type: Plain text
8726 #: build/C/man2/sync_file_range.2:141
8727 msgid ""
8728 "This is a write-for-data-integrity operation that will ensure that all pages "
8729 "in the specified range which were dirty when B<sync_file_range>()  was "
8730 "called are committed to disk."
8731 msgstr ""
8732 "これは write-for-data-integrity 操作 (データ完全性確保のための書き込み) であ"
8733 "り、指定された範囲内の、 B<sync_file_range>()  が呼ばれた時点で dirty な全て"
8734 "のページが ディスクに格納されることが保証される。"
8735
8736 #. type: Plain text
8737 #: build/C/man2/sync_file_range.2:147
8738 msgid ""
8739 "On success, B<sync_file_range>()  returns 0; on failure -1 is returned and "
8740 "I<errno> is set to indicate the error."
8741 msgstr ""
8742 "成功の場合、 B<sync_file_range>()  は 0 を返す。失敗の場合、-1 を返し、 "
8743 "I<error> にエラーを示す値を設定する。"
8744
8745 #. type: Plain text
8746 #: build/C/man2/sync_file_range.2:152
8747 msgid "I<fd> is not a valid file descriptor."
8748 msgstr "I<fd> が有効なファイルディスクリプタではない。"
8749
8750 #. type: Plain text
8751 #: build/C/man2/sync_file_range.2:160
8752 msgid ""
8753 "I<flags> specifies an invalid bit; or I<offset> or I<nbytes> is invalid."
8754 msgstr ""
8755 "I<flags> に不正なビットが指定されている。または I<offset> か I<nbytes> が不正"
8756 "である。"
8757
8758 #. type: Plain text
8759 #: build/C/man2/sync_file_range.2:163
8760 msgid "I/O error."
8761 msgstr "I/O エラー。"
8762
8763 #. type: Plain text
8764 #: build/C/man2/sync_file_range.2:169
8765 msgid "Out of disk space."
8766 msgstr "ディスク領域不足である。"
8767
8768 #.  FIXME . (bug?) Actually, how can 'fd' refer to a symbolic link (S_ISLNK)?
8769 #.  (In userspace at least) it isn't possible to obtain a file descriptor
8770 #.  for a symbolic link.
8771 #. type: Plain text
8772 #: build/C/man2/sync_file_range.2:177
8773 msgid ""
8774 "I<fd> refers to something other than a regular file, a block device, a "
8775 "directory, or a symbolic link."
8776 msgstr ""
8777 "I<fd> が、通常のファイル、ブロックデバイス、ディレクトリ、シンボリックリンク "
8778 "以外のものを指している。"
8779
8780 #. type: Plain text
8781 #: build/C/man2/sync_file_range.2:180
8782 msgid "B<sync_file_range>()  appeared on Linux in kernel 2.6.17."
8783 msgstr "B<sync_file_range>()  はカーネル 2.6.17 で Linux に登場した。"
8784
8785 #. type: Plain text
8786 #: build/C/man2/sync_file_range.2:183
8787 msgid ""
8788 "This system call is Linux-specific, and should be avoided in portable "
8789 "programs."
8790 msgstr ""
8791 "このシステムコールは Linux 独自であり、 移植性が必要なプログラムでは使用を避"
8792 "けるべきである。"
8793
8794 #.  See kernel commit edd5cd4a9424f22b0fa08bef5e299d41befd5622
8795 #. type: Plain text
8796 #: build/C/man2/sync_file_range.2:196
8797 msgid ""
8798 "Some architectures (e.g., PowerPC, ARM)  need 64-bit arguments to be aligned "
8799 "in a suitable pair of registers.  On such architectures, the call signature "
8800 "of B<sync_file_range>()  is flawed, since it forces a register to be wasted "
8801 "as padding between the I<fd> and I<offset> arguments.  Therefore, these "
8802 "architectures define a different system call that orders the arguments "
8803 "suitably:"
8804 msgstr ""
8805
8806 #. type: Plain text
8807 #: build/C/man2/sync_file_range.2:201
8808 #, no-wrap
8809 msgid ""
8810 "B<int sync_file_range2(int >I<fd>B<, unsigned int >I<flags>B<,>\n"
8811 "B<                     off64_t >I<offset>B<, off64_t >I<nbytes>B<);>\n"
8812 msgstr ""
8813 "B<int sync_file_range2(int >I<fd>B<, unsigned int >I<flags>B<,>\n"
8814 "B<                     off64_t >I<offset>B<, off64_t >I<nbytes>B<);>\n"
8815
8816 #. type: Plain text
8817 #: build/C/man2/sync_file_range.2:206
8818 msgid ""
8819 "The behavior of this system call is otherwise exactly the same as "
8820 "B<sync_file_range>()."
8821 msgstr ""
8822
8823 #. type: Plain text
8824 #: build/C/man2/sync_file_range.2:217
8825 msgid ""
8826 "A system call with this signature first appeared on the ARM architecture in "
8827 "Linux 2.6.20, with the name B<arm_sync_file_range>().  It was renamed in "
8828 "Linux 2.6.22, when the analogous system call was added for PowerPC.  On "
8829 "architectures where glibc support is provided, glibc transparently wraps "
8830 "B<sync_file_range2>()  under the name B<sync_file_range>()."
8831 msgstr ""
8832
8833 #. type: Plain text
8834 #: build/C/man2/sync_file_range.2:221
8835 msgid "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2)"
8836 msgstr "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2)"
8837
8838 #. type: TH
8839 #: build/C/man3/malloc_get_state.3:23
8840 #, no-wrap
8841 msgid "MALLOC_GET_STATE"
8842 msgstr "MALLOC_GET_STATE"
8843
8844 #. type: TH
8845 #: build/C/man3/malloc_get_state.3:23
8846 #, no-wrap
8847 msgid "2012-03-26"
8848 msgstr "2012-03-26"
8849
8850 #. type: Plain text
8851 #: build/C/man3/malloc_get_state.3:26
8852 msgid ""
8853 "get_malloc_state, set_malloc_state - record and restore state of malloc "
8854 "implementation"
8855 msgstr ""
8856
8857 #. type: Plain text
8858 #: build/C/man3/malloc_get_state.3:31
8859 #, no-wrap
8860 msgid "B<void* malloc_get_state(void);>\n"
8861 msgstr "B<void* malloc_get_state(void);>\n"
8862
8863 #. type: Plain text
8864 #: build/C/man3/malloc_get_state.3:33
8865 #, no-wrap
8866 msgid "B<int malloc_set_state(void *>I<state>B<);>\n"
8867 msgstr "B<int malloc_set_state(void *>I<state>B<);>\n"
8868
8869 #. type: Plain text
8870 #: build/C/man3/malloc_get_state.3:51
8871 msgid ""
8872 "The B<malloc_get_state>()  function records the current state of all "
8873 "B<malloc>(3)  internal bookkeeping variables (but not the actual contents of "
8874 "the heap or the state of B<malloc_hook>(3)  functions pointers).  The state "
8875 "is recorded in a system-dependent opaque data structure dynamically "
8876 "allocated via B<malloc>(3), and a pointer to that data structure is returned "
8877 "as the function result.  (It is the caller's responsibility to B<free>(3)  "
8878 "this memory.)"
8879 msgstr ""
8880
8881 #. type: Plain text
8882 #: build/C/man3/malloc_get_state.3:59
8883 msgid ""
8884 "The B<malloc_set_state>()  function restores the state of all B<malloc>(3)  "
8885 "internal bookkeeping variables to the values recorded in the opaque data "
8886 "structure pointed to by I<state>."
8887 msgstr ""
8888
8889 #. type: Plain text
8890 #: build/C/man3/malloc_get_state.3:66
8891 msgid ""
8892 "On success, B<malloc_get_state>()  returns a pointer to a newly allocated "
8893 "opaque data structure.  On error (for example, memory could not be allocated "
8894 "for the data structure), B<malloc_get_state>()  returns NULL."
8895 msgstr ""
8896
8897 #.  if(ms->magic != MALLOC_STATE_MAGIC) return -1;
8898 #.  /* Must fail if the major version is too high. */
8899 #.  if((ms->version & ~0xffl) > (MALLOC_STATE_VERSION & ~0xffl)) return -2;
8900 #. type: Plain text
8901 #: build/C/man3/malloc_get_state.3:84
8902 msgid ""
8903 "On success, B<malloc_set_state>()  returns 0.  If the implementation detects "
8904 "that I<state> does not point to a correctly formed data structure, "
8905 "B<malloc_set_state>()  returns -1.  If the implementation detects that the "
8906 "version of the data structure referred to by I<state> is a more recent "
8907 "version than this implementation knows about, B<malloc_set_state>()  returns "
8908 "-2."
8909 msgstr ""
8910
8911 #. type: Plain text
8912 #: build/C/man3/malloc_get_state.3:92
8913 msgid ""
8914 "These functions are especially useful when using this B<malloc>(3)  "
8915 "implementation as part of a shared library, and the heap contents are saved/"
8916 "restored via some other method.  This technique is used by the GNU Emacs to "
8917 "implement its \"dumping\" function."
8918 msgstr ""
8919
8920 #.  i.e., calls __malloc_check_init()
8921 #.  i.e., malloc checking is not already in use
8922 #.  and the caller requested malloc checking
8923 #. type: Plain text
8924 #: build/C/man3/malloc_get_state.3:109
8925 msgid ""
8926 "Hook function pointers are never saved or restored by these functions, with "
8927 "two exceptions: if malloc checking (see B<mallopt>(3))  was in use when "
8928 "B<malloc_get_state>()  was called, then B<malloc_set_state>()  resets malloc "
8929 "checking hooks if possible; if malloc checking was not in use in the "
8930 "recorded state, but the caller has requested malloc checking, then the hooks "
8931 "are reset to 0."
8932 msgstr ""
8933
8934 #. type: Plain text
8935 #: build/C/man3/malloc_get_state.3:111
8936 msgid "B<malloc>(3), B<mallopt>(3)"
8937 msgstr "B<malloc>(3), B<mallopt>(3)"
8938
8939 #. type: TH
8940 #: build/C/man3/malloc_trim.3:24
8941 #, no-wrap
8942 msgid "MALLOC_TRIM"
8943 msgstr "MALLOC_TRIM"
8944
8945 #. type: TH
8946 #: build/C/man3/malloc_trim.3:24 build/C/man3/malloc_usable_size.3:23
8947 #, no-wrap
8948 msgid "2012-03-29"
8949 msgstr "2012-03-29"
8950
8951 #. type: Plain text
8952 #: build/C/man3/malloc_trim.3:27
8953 msgid "malloc_trim - release free memory from the top of the heap"
8954 msgstr ""
8955
8956 #. type: Plain text
8957 #: build/C/man3/malloc_trim.3:31
8958 msgid "B<void malloc_trim(size_t >I<pad>B<);>"
8959 msgstr "B<void malloc_trim(size_t >I<pad>B<);>"
8960
8961 #. type: Plain text
8962 #: build/C/man3/malloc_trim.3:38
8963 msgid ""
8964 "The B<malloc_trim>()  function attempts to release free memory at the top of "
8965 "the heap (by calling B<sbrk>(2)  with a suitable argument)."
8966 msgstr ""
8967
8968 #. type: Plain text
8969 #: build/C/man3/malloc_trim.3:49
8970 msgid ""
8971 "The I<pad> argument specifies the amount of free space to leave untrimmed at "
8972 "the top of the heap.  If this argument is 0, only the minimum amount of "
8973 "memory is maintained at the top of the heap (i.e., one page or less).  A "
8974 "nonzero argument can be used to maintain some trailing space at the top of "
8975 "the heap in order to allow future allocations to be made without having to "
8976 "extend the heap with B<sbrk>(2)."
8977 msgstr ""
8978
8979 #. type: Plain text
8980 #: build/C/man3/malloc_trim.3:54
8981 msgid ""
8982 "The B<malloc_trim>()  function returns 1 if memory was actually released "
8983 "back to the system, or 0 if it was not possible to release any memory."
8984 msgstr ""
8985
8986 #.  .SH VERSIONS
8987 #.  Available already in glibc 2.0, possibly earlier
8988 #. type: Plain text
8989 #: build/C/man3/malloc_trim.3:58
8990 msgid "No errors are defined."
8991 msgstr ""
8992
8993 #. type: Plain text
8994 #: build/C/man3/malloc_trim.3:60 build/C/man3/malloc_usable_size.3:48
8995 msgid "This function is a GNU extension."
8996 msgstr "この関数は GNU による拡張である。"
8997
8998 #. type: Plain text
8999 #: build/C/man3/malloc_trim.3:69
9000 msgid ""
9001 "This function is automatically called by B<free>(3)  in certain "
9002 "circumstances; see the discussion of B<M_TOP_PAD> and B<M_TRIM_THRESHOLD> in "
9003 "B<mallopt>(3)."
9004 msgstr ""
9005
9006 #. type: Plain text
9007 #: build/C/man3/malloc_trim.3:72
9008 msgid ""
9009 "This function cannot release free memory located at places other than the "
9010 "top of the heap."
9011 msgstr ""
9012
9013 #.  malloc/malloc.c::mTRIm():
9014 #.      return result | (av == &main_arena ? sYSTRIm (pad, av) : 0);
9015 #. type: Plain text
9016 #: build/C/man3/malloc_trim.3:76
9017 msgid "This function only releases memory in the main arena."
9018 msgstr ""
9019
9020 #. type: Plain text
9021 #: build/C/man3/malloc_trim.3:79
9022 msgid "B<sbrk>(2), B<malloc>(3), B<mallopt>(3)"
9023 msgstr "B<sbrk>(2), B<malloc>(3), B<mallopt>(3)"
9024
9025 #. type: TH
9026 #: build/C/man3/malloc_usable_size.3:23
9027 #, no-wrap
9028 msgid "MALLOC_USABLE_SIZE"
9029 msgstr "MALLOC_USABLE_SIZE"
9030
9031 #. type: Plain text
9032 #: build/C/man3/malloc_usable_size.3:26
9033 msgid "malloc_usable_size - obtain size of block of memory allocated from heap"
9034 msgstr ""
9035
9036 #. type: Plain text
9037 #: build/C/man3/malloc_usable_size.3:30
9038 msgid "B<size_t malloc_usable_size (void *>I<ptr>B<);>"
9039 msgstr "B<size_t malloc_usable_size (void *>I<ptr>B<);>"
9040
9041 #. type: Plain text
9042 #: build/C/man3/malloc_usable_size.3:38
9043 msgid ""
9044 "The B<malloc_usable_size>()  function returns the number of usable bytes in "
9045 "the block pointed to by I<ptr>, a pointer to a block of memory allocated by "
9046 "B<malloc>(3)  or a related function."
9047 msgstr ""
9048
9049 #. type: Plain text
9050 #: build/C/man3/malloc_usable_size.3:46
9051 msgid ""
9052 "B<malloc_usable_size>()  returns the number of usable bytes in the block of "
9053 "allocated memory pointed to by I<ptr>.  If I<ptr> is NULL, 0 is returned."
9054 msgstr ""
9055
9056 #. type: Plain text
9057 #: build/C/man3/malloc_usable_size.3:58
9058 msgid ""
9059 "The value returned by B<malloc_usable_size>()  may be greater than the "
9060 "requested size of the allocation because of alignment and minimum size "
9061 "constraints.  Although the excess bytes can be overwritten by the "
9062 "application without ill effects, this is not good programming practice: the "
9063 "number of excess bytes in an allocation depends on the underlying "
9064 "implementation."
9065 msgstr ""
9066
9067 #. type: Plain text
9068 #: build/C/man3/malloc_usable_size.3:60
9069 msgid "The main use of this function is for debugging and introspection."
9070 msgstr ""
9071
9072 #. type: Plain text
9073 #: build/C/man3/malloc_usable_size.3:61
9074 msgid "B<malloc>(3)"
9075 msgstr "B<malloc>(3)"
9076
9077 #~ msgid "COLOPHON"
9078 #~ msgstr "この文書について"
9079
9080 #~ msgid ""
9081 #~ "This page is part of release 3.38 of the Linux I<man-pages> project.  A "
9082 #~ "description of the project, and information about reporting bugs, can be "
9083 #~ "found at http://www.kernel.org/doc/man-pages/."
9084 #~ msgstr ""
9085 #~ "この man ページは Linux I<man-pages> プロジェクトのリリース 3.38 の一部である。\n"
9086 #~ "プロジェクトの説明とバグ報告に関する情報は\n"
9087 #~ "http://www.kernel.org/doc/man-pages/ に書かれている。"
9088
9089 #~ msgid ""
9090 #~ "The function B<mtrace>()  installs handlers for B<malloc>(3), B<realloc>"
9091 #~ "(3)  and B<free>(3).  The function B<muntrace>()  disables these handlers."
9092 #~ msgstr ""
9093 #~ "関数 B<mtrace>()  は、 B<malloc>(3), B<realloc>(3), B<free>(3)  のハンドラ"
9094 #~ "を組み込む。 関数 B<muntrace>()  はこれらのハンドラを解除する。"
9095
9096 #~ msgid ""
9097 #~ "The environment variable B<MALLOC_TRACE> defines a file where B<mtrace>"
9098 #~ "()  writes its output.  This file must be writable to the user or "
9099 #~ "B<mtrace>()  will do nothing.  If the file is not empty it will be "
9100 #~ "truncated."
9101 #~ msgstr ""
9102 #~ "環境変数 B<MALLOC_TRACE> は B<mtrace>()  が出力を書き出すファイルを指定す"
9103 #~ "る。 ユーザが書き込み権限を持つファイルを指定しなければならない。 書き込み"
9104 #~ "権限がない場合、 B<mtrace>()  は何もしない。 ファイルが空でない場合、ファ"
9105 #~ "イルの元の内容を上書きする。"
9106
9107 #~ msgid "These are GNU extensions."
9108 #~ msgstr "この関数は GNU 拡張である。"
9109
9110 #~ msgid ""
9111 #~ "The output of B<mtrace>()  will be ASCII but not in a friendly format.  "
9112 #~ "So glibc comes with a perl-script called mtrace to make sense of it."
9113 #~ msgstr ""
9114 #~ "B<mtrace>()  の出力は ASCII 形式だが、人が読みやすいフォーマットではな"
9115 #~ "い。 そこで、glibc には mtrace 出力を分かりやすい形式に変換する perl スク"
9116 #~ "リプトが付属している。"
9117
9118 #~ msgid ""
9119 #~ "This flag allocates and initializes to zero the disk space within the "
9120 #~ "range specified by I<offset> and I<len>.  After a successful call, "
9121 #~ "subsequent writes into this range are guaranteed not to fail because of "
9122 #~ "lack of disk space.  Preallocating zeroed blocks beyond the end of the "
9123 #~ "file is useful for optimizing append workloads.  Preallocating blocks "
9124 #~ "does not change the file size (as reported by B<stat>(2))  even if it is "
9125 #~ "less than I<offset>+I<len>."
9126 #~ msgstr ""
9127 #~ "このフラグは、 I<offset> と I<len> で指定された領域のディスク空間を割り当"
9128 #~ "て、その空間を 0 で初期化する。 呼び出しが成功すると、それに続いてこの領域"
9129 #~ "への書き込みが行われるが、 ディスク空間の不足による書き込み失敗が発生しな"
9130 #~ "いことが保証される。 ファイル末尾より後ろの領域について 0 で埋めたブロック"
9131 #~ "を前もって 割り当てておくことは、追記 (append) の作業負荷を最適化するのに "
9132 #~ "有用である。 ファイルサイズが I<offset>+I<len> よりも小さい場合であって"
9133 #~ "も、ブロックの前もっての割り当てにより (B<stat>(2)  が返す) ファイルサイズ"
9134 #~ "は変更されることはない。"
9135
9136 #, fuzzy
9137 #~| msgid "The buffer referred to by I<map> is not accessible."
9138 #~ msgid ""
9139 #~ "The file referred to by I<fd> is marked immutable (see B<chattr>(1))."
9140 #~ msgstr "The buffer referred to by I<map> is not accessible."
9141
9142 #~ msgid ""
9143 #~ "(Linux 2.6.9 and later) the caller was not privileged (B<CAP_IPC_LOCK>)  "
9144 #~ "and its B<RLIMIT_MEMLOCK> soft resource limit was 0."
9145 #~ msgstr ""
9146 #~ "(Linux 2.6.9 以降) 呼び出し元は特権 (B<CAP_IPC_LOCK>)  を持たず、ソフト資"
9147 #~ "源制限 B<RLIMIT_MEMLOCK> が 0 である。"
9148
9149 #~ msgid ""
9150 #~ "(Linux 2.6.8 and earlier)  The calling process has insufficient privilege "
9151 #~ "to call B<munlockall>().  Under Linux the B<CAP_IPC_LOCK> capability is "
9152 #~ "required."
9153 #~ msgstr ""
9154 #~ "(Linux 2.6.8 以前)  呼び出し元プロセスが B<munlockall>()  を呼び出すのに必"
9155 #~ "要な特権を所有していなかった。 Linux では、 B<CAP_IPC_LOCK> ケーパビリティ"
9156 #~ "が必要である。"
9157
9158 #~ msgid ""
9159 #~ "B<#define _XOPEN_SOURCE 600>\n"
9160 #~ "B<#include E<lt>fcntl.hE<gt>>\n"
9161 #~ msgstr ""
9162 #~ "B<#define _XOPEN_SOURCE 600>\n"
9163 #~ "B<#include E<lt>fcntl.hE<gt>>\n"
9164
9165 #~ msgid ""
9166 #~ "B<posix_fadvise>()  appeared in kernel 2.5.60.  Glibc support has been "
9167 #~ "provided since version 2.2."
9168 #~ msgstr ""
9169 #~ "B<posix_fadvise>()  はカーネル 2.5.60 で登場した。 glibc でのサポートは "
9170 #~ "glibc バージョン 2.2 以降で行われている。"
9171
9172 #~ msgid ""
9173 #~ "B<#define _GNU_SOURCE>\n"
9174 #~ "B<#include E<lt>fcntl.hE<gt>>\n"
9175 #~ msgstr ""
9176 #~ "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
9177 #~ "B<#include E<lt>fcntl.hE<gt>>\n"