OSDN Git Service

(split) LDP: Update POT and ja.po to LDP v3.37.
[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-03-22 04:26+0900\n"
10 "PO-Revision-Date: 2012-03-22 00:22+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/man2/mlock.2:27 build/C/man2/mmap.2:40 build/C/man2/mmap2.2:29
34 #: build/C/man2/mprotect.2:32 build/C/man2/mremap.2:31 build/C/man2/msync.2:25
35 #: build/C/man2/posix_fadvise.2:27 build/C/man2/readahead.2:28
36 #: build/C/man2/remap_file_pages.2:26 build/C/man3/shm_open.3:26
37 #: build/C/man7/shm_overview.7:27 build/C/man2/shmctl.2:43
38 #: 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 #, no-wrap
41 msgid "Linux"
42 msgstr "Linux"
43
44 #. type: TH
45 #: build/C/man2/alloc_hugepages.2:25 build/C/man3/alloca.3:41
46 #: build/C/man2/cacheflush.2:24 build/C/man2/fallocate.2:8
47 #: build/C/man2/madvise.2:35 build/C/man3/malloc_hook.3:6
48 #: build/C/man2/mlock.2:27 build/C/man2/mmap.2:40 build/C/man2/mmap2.2:29
49 #: build/C/man2/mprotect.2:32 build/C/man2/mremap.2:31 build/C/man2/msync.2:25
50 #: build/C/man3/mtrace.3:4 build/C/man2/posix_fadvise.2:27
51 #: build/C/man3/posix_fallocate.3:23 build/C/man3/posix_memalign.3:26
52 #: build/C/man2/readahead.2:28 build/C/man2/remap_file_pages.2:26
53 #: build/C/man3/shm_open.3:26 build/C/man7/shm_overview.7:27
54 #: build/C/man2/shmctl.2:43 build/C/man2/shmget.2:36 build/C/man2/shmop.2:39
55 #: build/C/man2/subpage_prot.2:28 build/C/man2/sync_file_range.2:30
56 #, no-wrap
57 msgid "Linux Programmer's Manual"
58 msgstr "Linux Programmer's Manual"
59
60 #. type: SH
61 #: build/C/man2/alloc_hugepages.2:26 build/C/man3/alloca.3:42
62 #: build/C/man2/cacheflush.2:25 build/C/man2/fallocate.2:9
63 #: build/C/man2/madvise.2:36 build/C/man3/malloc_hook.3:7
64 #: build/C/man2/mlock.2:28 build/C/man2/mmap.2:41 build/C/man2/mmap2.2:30
65 #: build/C/man2/mprotect.2:33 build/C/man2/mremap.2:32 build/C/man2/msync.2:26
66 #: build/C/man3/mtrace.3:5 build/C/man2/posix_fadvise.2:28
67 #: build/C/man3/posix_fallocate.3:24 build/C/man3/posix_memalign.3:27
68 #: build/C/man2/readahead.2:29 build/C/man2/remap_file_pages.2:27
69 #: build/C/man3/shm_open.3:27 build/C/man7/shm_overview.7:28
70 #: build/C/man2/shmctl.2:44 build/C/man2/shmget.2:37 build/C/man2/shmop.2:40
71 #: build/C/man2/subpage_prot.2:29 build/C/man2/sync_file_range.2:31
72 #, no-wrap
73 msgid "NAME"
74 msgstr "名前"
75
76 #. type: Plain text
77 #: build/C/man2/alloc_hugepages.2:28
78 msgid "alloc_hugepages, free_hugepages - allocate or free huge pages"
79 msgstr ""
80 "alloc_hugepages, free_hugepages - 大きなサイズのページの割り当てと解放を行う"
81
82 #. type: SH
83 #: build/C/man2/alloc_hugepages.2:28 build/C/man3/alloca.3:44
84 #: build/C/man2/cacheflush.2:27 build/C/man2/fallocate.2:11
85 #: build/C/man2/madvise.2:38 build/C/man3/malloc_hook.3:11
86 #: build/C/man2/mlock.2:30 build/C/man2/mmap.2:43 build/C/man2/mmap2.2:32
87 #: build/C/man2/mprotect.2:35 build/C/man2/mremap.2:34 build/C/man2/msync.2:28
88 #: build/C/man3/mtrace.3:7 build/C/man2/posix_fadvise.2:30
89 #: build/C/man3/posix_fallocate.3:26 build/C/man3/posix_memalign.3:29
90 #: build/C/man2/readahead.2:31 build/C/man2/remap_file_pages.2:29
91 #: build/C/man3/shm_open.3:29 build/C/man2/shmctl.2:46
92 #: build/C/man2/shmget.2:39 build/C/man2/shmop.2:42
93 #: build/C/man2/subpage_prot.2:31 build/C/man2/sync_file_range.2:33
94 #, no-wrap
95 msgid "SYNOPSIS"
96 msgstr "書式"
97
98 #.  asmlinkage unsigned long sys_alloc_hugepages(int key, unsigned long addr,
99 #.  unsigned long len, int prot, int flag);
100 #. type: Plain text
101 #: build/C/man2/alloc_hugepages.2:34
102 #, no-wrap
103 msgid ""
104 "B<void *alloc_hugepages(int >I<key>B<, void *>I<addr>B<, size_t >I<len>B<,>\n"
105 "B<                      int >I<prot>B<, int >I<flag>B<);>\n"
106 msgstr ""
107 "B<void *alloc_hugepages(int >I<key>B<, void *>I<addr>B<, size_t >I<len>B<,>\n"
108 "B<                      int >I<prot>B<, int >I<flag>B<);>\n"
109
110 #.  asmlinkage int sys_free_hugepages(unsigned long addr);
111 #. type: Plain text
112 #: build/C/man2/alloc_hugepages.2:37
113 #, no-wrap
114 msgid "B<int free_hugepages(void *>I<addr>B<);>\n"
115 msgstr "B<int free_hugepages(void *>I<addr>B<);>\n"
116
117 #. type: SH
118 #: build/C/man2/alloc_hugepages.2:38 build/C/man3/alloca.3:48
119 #: build/C/man2/cacheflush.2:33 build/C/man2/fallocate.2:19
120 #: build/C/man2/madvise.2:50 build/C/man3/malloc_hook.3:29
121 #: build/C/man2/mlock.2:40 build/C/man2/mmap.2:52 build/C/man2/mmap2.2:39
122 #: build/C/man2/mprotect.2:41 build/C/man2/mremap.2:43 build/C/man2/msync.2:32
123 #: build/C/man3/mtrace.3:13 build/C/man2/posix_fadvise.2:49
124 #: build/C/man3/posix_fallocate.3:44 build/C/man3/posix_memalign.3:70
125 #: build/C/man2/readahead.2:38 build/C/man2/remap_file_pages.2:37
126 #: build/C/man3/shm_open.3:41 build/C/man7/shm_overview.7:30
127 #: build/C/man2/shmctl.2:54 build/C/man2/shmget.2:47 build/C/man2/shmop.2:51
128 #: build/C/man2/subpage_prot.2:36 build/C/man2/sync_file_range.2:41
129 #, no-wrap
130 msgid "DESCRIPTION"
131 msgstr "説明"
132
133 #. type: Plain text
134 #: build/C/man2/alloc_hugepages.2:49
135 msgid ""
136 "The system calls B<alloc_hugepages>()  and B<free_hugepages>()  were "
137 "introduced in Linux 2.5.36 and removed again in 2.5.54.  They existed only "
138 "on i386 and ia64 (when built with B<CONFIG_HUGETLB_PAGE>).  In Linux 2.4.20 "
139 "the syscall numbers exist, but the calls fail with the error B<ENOSYS>."
140 msgstr ""
141 "システムコール B<alloc_hugepages>()  と B<free_hugepages>()  は Linux 2.5.36 "
142 "で導入され、2.5.54 で再び削除された。 これらのシステムコールは i386 と ia64 "
143 "のみで (かつ B<CONFIG_HUGETLB_PAGE> を指定してビルドされた場合に) 存在する。 "
144 "Linux 2.4.20 では syscall 番号が存在するが、 呼び出すとエラー B<ENOSYS> で失"
145 "敗する。"
146
147 #. type: Plain text
148 #: build/C/man2/alloc_hugepages.2:57
149 msgid ""
150 "On i386 the memory management hardware knows about ordinary pages (4 KiB)  "
151 "and huge pages (2 or 4 MiB).  Similarly ia64 knows about huge pages of "
152 "several sizes.  These system calls serve to map huge pages into the "
153 "process's memory or to free them again.  Huge pages are locked into memory, "
154 "and are not swapped."
155 msgstr ""
156 "i386 では、メモリ管理ハードウェアは通常のページ (4 KiB) と 大きなサイズのペー"
157 "ジ (以下、ヒュージページ; 2MiB または 4 MiB) を 扱うことができる。 同様に、"
158 "ia64 もいくつかのサイズのヒュージページを扱うことができる。 これらのシステム"
159 "コールは、ヒュージページをプロセスのメモリにマップしたり、 再び解放したりす"
160 "る。 ヒュージページはメモリ内にロックされ、スワップされない。"
161
162 #. type: Plain text
163 #: build/C/man2/alloc_hugepages.2:66
164 msgid ""
165 "The I<key> argument is an identifier.  When zero the pages are private, and "
166 "not inherited by children.  When positive the pages are shared with other "
167 "applications using the same I<key>, and inherited by child processes."
168 msgstr ""
169 "I<key> 引き数は識別子である。 0 の場合、ページは非公開になり、子プロセスに継"
170 "承されない。 正の場合、ページは同じ I<key> を使う他のアプリケーションと共有さ"
171 "れ、子プロセスに継承される。"
172
173 #. type: Plain text
174 #: build/C/man2/alloc_hugepages.2:81
175 msgid ""
176 "The I<addr> argument of B<free_hugepages>()  tells which page is being "
177 "freed: it was the return value of a call to B<alloc_hugepages>().  (The "
178 "memory is first actually freed when all users have released it.)  The "
179 "I<addr> argument of B<alloc_hugepages>()  is a hint, that the kernel may or "
180 "may not follow.  Addresses must be properly aligned."
181 msgstr ""
182 "B<free_hugepages>()  の I<addr> 引き数は、どのページを解放するかを指定する: "
183 "I<addr> は B<alloc_hugepages>()  の呼び出しの返り値である (全てのユーザがメモ"
184 "リを解放したときに、 そのメモリは初めて実際に解放される)。 B<alloc_hugepages>"
185 "()  の I<addr> 引き数はヒントであり、カーネルはそれに従うかもしれないし、 従"
186 "わないかもしれない。 アドレスは正しく配置されなければならない。"
187
188 #. type: Plain text
189 #: build/C/man2/alloc_hugepages.2:86
190 msgid ""
191 "The I<len> argument is the length of the required segment.  It must be a "
192 "multiple of the huge page size."
193 msgstr ""
194 "I<len> 引き数は要求されたセグメントの長さである。 これはヒュージページのサイ"
195 "ズの倍数にしなければならない。"
196
197 #. type: Plain text
198 #: build/C/man2/alloc_hugepages.2:94
199 msgid ""
200 "The I<prot> argument specifies the memory protection of the segment.  It is "
201 "one of B<PROT_READ>, B<PROT_WRITE>, B<PROT_EXEC>."
202 msgstr ""
203 "I<prot> 引き数はセグメントのメモリ保護を指定する。 これは B<PROT_READ>, "
204 "B<PROT_WRITE>, B<PROT_EXEC> のいずれかである。"
205
206 #. type: Plain text
207 #: build/C/man2/alloc_hugepages.2:109
208 msgid ""
209 "The I<flag> argument is ignored, unless I<key> is positive.  In that case, "
210 "if I<flag> is B<IPC_CREAT>, then a new huge page segment is created when "
211 "none with the given key existed.  If this flag is not set, then B<ENOENT> is "
212 "returned when no segment with the given key exists."
213 msgstr ""
214 "I<key> が正でない限り、 I<flag> 引き数は無視される。 I<key> が正で、かつ "
215 "I<flag> が B<IPC_CREAT> であり、かつ指定された I<key> で (セグメントが) 何も"
216 "存在しない場合、 新しいヒュージページセグメントが作成される。 I<flag> が設定"
217 "されておらず、かつ指定された I<key> のセグメントが存在しない場合、 B<ENOENT> "
218 "が返される。"
219
220 #. type: SH
221 #: build/C/man2/alloc_hugepages.2:109 build/C/man3/alloca.3:58
222 #: build/C/man2/cacheflush.2:52 build/C/man2/fallocate.2:109
223 #: build/C/man2/madvise.2:250 build/C/man2/mlock.2:117 build/C/man2/mmap.2:373
224 #: build/C/man2/mmap2.2:50 build/C/man2/mprotect.2:72
225 #: build/C/man2/mremap.2:128 build/C/man2/msync.2:68
226 #: build/C/man2/posix_fadvise.2:86 build/C/man3/posix_fallocate.3:64
227 #: build/C/man3/posix_memalign.3:111 build/C/man2/readahead.2:65
228 #: build/C/man2/remap_file_pages.2:122 build/C/man3/shm_open.3:169
229 #: build/C/man2/shmctl.2:272 build/C/man2/shmget.2:178
230 #: build/C/man2/shmop.2:169 build/C/man2/subpage_prot.2:61
231 #: build/C/man2/sync_file_range.2:141
232 #, no-wrap
233 msgid "RETURN VALUE"
234 msgstr "返り値"
235
236 #. type: Plain text
237 #: build/C/man2/alloc_hugepages.2:118
238 msgid ""
239 "On success, B<alloc_hugepages>()  returns the allocated virtual address, and "
240 "B<free_hugepages>()  returns zero.  On error, -1 is returned, and I<errno> "
241 "is set appropriately."
242 msgstr ""
243 "成功した場合、 B<alloc_hugepages>()  は割り当てられた仮想アドレスを返し、 "
244 "B<free_hugepages>()  は 0 を返す。 失敗した場合、-1 を返し、 I<errno> が適切"
245 "に設定される。"
246
247 #. type: SH
248 #: build/C/man2/alloc_hugepages.2:118 build/C/man2/cacheflush.2:58
249 #: build/C/man2/fallocate.2:112 build/C/man2/madvise.2:257
250 #: build/C/man2/mlock.2:123 build/C/man2/mmap.2:390 build/C/man2/mmap2.2:57
251 #: build/C/man2/mprotect.2:79 build/C/man2/mremap.2:136
252 #: build/C/man2/msync.2:73 build/C/man2/posix_fadvise.2:89
253 #: build/C/man3/posix_fallocate.3:70 build/C/man3/posix_memalign.3:123
254 #: build/C/man2/readahead.2:71 build/C/man2/remap_file_pages.2:129
255 #: build/C/man3/shm_open.3:178 build/C/man2/shmctl.2:294
256 #: build/C/man2/shmget.2:182 build/C/man2/shmop.2:183
257 #: build/C/man2/subpage_prot.2:66 build/C/man2/sync_file_range.2:147
258 #, no-wrap
259 msgid "ERRORS"
260 msgstr "エラー"
261
262 #. type: TP
263 #: build/C/man2/alloc_hugepages.2:119 build/C/man2/fallocate.2:151
264 #, no-wrap
265 msgid "B<ENOSYS>"
266 msgstr "B<ENOSYS>"
267
268 #. type: Plain text
269 #: build/C/man2/alloc_hugepages.2:122
270 msgid "The system call is not supported on this kernel."
271 msgstr "このシステムコールはカーネルでサポートされていない。"
272
273 #. type: SH
274 #: build/C/man2/alloc_hugepages.2:122
275 #, no-wrap
276 msgid "FILES"
277 msgstr "ファイル"
278
279 #. type: Plain text
280 #: build/C/man2/alloc_hugepages.2:126
281 msgid ""
282 "I</proc/sys/vm/nr_hugepages> Number of configured hugetlb pages.  This can "
283 "be read and written."
284 msgstr ""
285 "I</proc/sys/vm/nr_hugepages> 設定された hugetlb ページの数。 このファイルは読"
286 "み書きできる。"
287
288 #. type: Plain text
289 #: build/C/man2/alloc_hugepages.2:130
290 msgid ""
291 "I</proc/meminfo> Gives info on the number of configured hugetlb pages and on "
292 "their size in the three variables HugePages_Total, HugePages_Free, "
293 "Hugepagesize."
294 msgstr ""
295 "I</proc/meminfo> 設定された hugetlb ページの数と、 3 つの変数 "
296 "HugePages_Total, HugePages_Free, Hugepagesize の サイズについての情報を提供す"
297 "る。"
298
299 #. type: SH
300 #: build/C/man2/alloc_hugepages.2:130 build/C/man3/alloca.3:63
301 #: build/C/man2/cacheflush.2:74 build/C/man2/fallocate.2:186
302 #: build/C/man2/madvise.2:307 build/C/man3/malloc_hook.3:76
303 #: build/C/man2/mlock.2:187 build/C/man2/mmap.2:483 build/C/man2/mmap2.2:73
304 #: build/C/man2/mprotect.2:107 build/C/man2/mremap.2:186
305 #: build/C/man2/msync.2:96 build/C/man3/mtrace.3:34
306 #: build/C/man2/posix_fadvise.2:111 build/C/man3/posix_fallocate.3:101
307 #: build/C/man3/posix_memalign.3:142 build/C/man2/readahead.2:87
308 #: build/C/man2/remap_file_pages.2:151 build/C/man3/shm_open.3:249
309 #: build/C/man7/shm_overview.7:101 build/C/man2/shmctl.2:366
310 #: build/C/man2/shmget.2:229 build/C/man2/shmop.2:226
311 #: build/C/man2/subpage_prot.2:91 build/C/man2/sync_file_range.2:180
312 #, no-wrap
313 msgid "CONFORMING TO"
314 msgstr "準拠"
315
316 #. type: Plain text
317 #: build/C/man2/alloc_hugepages.2:133
318 msgid ""
319 "These calls are specific to Linux on Intel processors, and should not be "
320 "used in programs intended to be portable."
321 msgstr ""
322 "このシステムコールは Intel プロセッサ上の Linux に固有のものであり、 移植性が"
323 "必要なプログラムで使うべきでない。"
324
325 #. type: SH
326 #: build/C/man2/alloc_hugepages.2:133 build/C/man3/alloca.3:71
327 #: build/C/man2/madvise.2:328 build/C/man3/malloc_hook.3:78
328 #: build/C/man2/mlock.2:214 build/C/man2/mmap.2:501 build/C/man2/mmap2.2:75
329 #: build/C/man2/mprotect.2:116 build/C/man2/mremap.2:192
330 #: build/C/man3/mtrace.3:36 build/C/man2/posix_fadvise.2:120
331 #: build/C/man3/posix_memalign.3:179 build/C/man3/shm_open.3:255
332 #: build/C/man7/shm_overview.7:103 build/C/man2/shmctl.2:371
333 #: build/C/man2/shmget.2:235 build/C/man2/shmop.2:245
334 #: build/C/man2/subpage_prot.2:93 build/C/man2/sync_file_range.2:183
335 #, no-wrap
336 msgid "NOTES"
337 msgstr "注意"
338
339 #. type: Plain text
340 #: build/C/man2/alloc_hugepages.2:141
341 msgid ""
342 "These system calls are gone; they existed only in Linux 2.5.36 through to "
343 "2.5.54.  Now the hugetlbfs file system can be used instead.  Memory backed "
344 "by huge pages (if the CPU supports them) is obtained by using B<mmap>(2)  to "
345 "map files in this virtual file system."
346 msgstr ""
347 "これらのシステムコールはなくなった。 これらは Linux 2.5.36 から 2.5.54 にのみ"
348 "存在する。 代わりに今は hugetlbfs ファイルシステムを使うことができる。 (CPU "
349 "がサポートしている場合) ヒュージページを持つメモリは、 B<mmap>(2)  を使ってこ"
350 "の仮想ファイルシステムでファイルをマップすることで取得できる。"
351
352 #. type: Plain text
353 #: build/C/man2/alloc_hugepages.2:145
354 msgid ""
355 "The maximal number of huge pages can be specified using the B<hugepages=> "
356 "boot parameter."
357 msgstr ""
358 "ヒュージページの最大数は、 B<hugepages=> 起動パラメータを使って指定できる。"
359
360 #. type: SH
361 #: build/C/man2/alloc_hugepages.2:150 build/C/man3/alloca.3:153
362 #: build/C/man2/cacheflush.2:88 build/C/man2/fallocate.2:193
363 #: build/C/man2/madvise.2:360 build/C/man3/malloc_hook.3:138
364 #: build/C/man2/mlock.2:337 build/C/man2/mmap.2:667 build/C/man2/mmap2.2:94
365 #: build/C/man2/mprotect.2:223 build/C/man2/mremap.2:214
366 #: build/C/man2/msync.2:122 build/C/man3/mtrace.3:44
367 #: build/C/man2/posix_fadvise.2:188 build/C/man3/posix_fallocate.3:130
368 #: build/C/man3/posix_memalign.3:235 build/C/man2/readahead.2:98
369 #: build/C/man2/remap_file_pages.2:162 build/C/man3/shm_open.3:280
370 #: build/C/man7/shm_overview.7:127 build/C/man2/shmctl.2:410
371 #: build/C/man2/shmget.2:298 build/C/man2/shmop.2:290
372 #: build/C/man2/subpage_prot.2:126 build/C/man2/sync_file_range.2:222
373 #, no-wrap
374 msgid "COLOPHON"
375 msgstr ""
376
377 #. type: Plain text
378 #: build/C/man2/alloc_hugepages.2:157 build/C/man3/alloca.3:160
379 #: build/C/man2/cacheflush.2:95 build/C/man2/fallocate.2:200
380 #: build/C/man2/madvise.2:367 build/C/man3/malloc_hook.3:145
381 #: build/C/man2/mlock.2:344 build/C/man2/mmap.2:674 build/C/man2/mmap2.2:101
382 #: build/C/man2/mprotect.2:230 build/C/man2/mremap.2:221
383 #: build/C/man2/msync.2:129 build/C/man3/mtrace.3:51
384 #: build/C/man2/posix_fadvise.2:195 build/C/man3/posix_fallocate.3:137
385 #: build/C/man3/posix_memalign.3:242 build/C/man2/readahead.2:105
386 #: build/C/man2/remap_file_pages.2:169 build/C/man3/shm_open.3:287
387 #: build/C/man7/shm_overview.7:134 build/C/man2/shmctl.2:417
388 #: build/C/man2/shmget.2:305 build/C/man2/shmop.2:297
389 #: build/C/man2/subpage_prot.2:133 build/C/man2/sync_file_range.2:229
390 msgid ""
391 "This page is part of release 3.37 of the Linux I<man-pages> project.  A "
392 "description of the project, and information about reporting bugs, can be "
393 "found at http://www.kernel.org/doc/man-pages/."
394 msgstr ""
395
396 #. type: TH
397 #: build/C/man3/alloca.3:41
398 #, no-wrap
399 msgid "ALLOCA"
400 msgstr "ALLOCA"
401
402 #. type: TH
403 #: build/C/man3/alloca.3:41
404 #, no-wrap
405 msgid "2008-01-24"
406 msgstr "2008-01-24"
407
408 #. type: TH
409 #: build/C/man3/alloca.3:41 build/C/man3/malloc_hook.3:6
410 #: build/C/man3/mtrace.3:4 build/C/man3/posix_fallocate.3:23
411 #: build/C/man3/posix_memalign.3:26
412 #, no-wrap
413 msgid "GNU"
414 msgstr "GNU"
415
416 #. type: Plain text
417 #: build/C/man3/alloca.3:44
418 msgid "alloca - allocate memory that is automatically freed"
419 msgstr "alloca - 自動的に解放されるメモリを割り当てる"
420
421 #. type: Plain text
422 #: build/C/man3/alloca.3:46
423 msgid "B<#include E<lt>alloca.hE<gt>>"
424 msgstr "B<#include E<lt>alloca.hE<gt>>"
425
426 #. type: Plain text
427 #: build/C/man3/alloca.3:48
428 msgid "B<void *alloca(size_t >I<size>B<);>"
429 msgstr "B<void *alloca(size_t >I<size>B<);>"
430
431 #. type: Plain text
432 #: build/C/man3/alloca.3:58
433 msgid ""
434 "The B<alloca>()  function allocates I<size> bytes of space in the stack "
435 "frame of the caller.  This temporary space is automatically freed when the "
436 "function that called B<alloca>()  returns to its caller."
437 msgstr ""
438 "B<alloca>()  関数は、 I<size> バイトの領域を呼出元のスタック・フレームに割り"
439 "付ける。 この一時的な領域は、 B<alloca>()  を呼び出した関数が呼出元に返るとき"
440 "に自動的に解放される。"
441
442 #. type: Plain text
443 #: build/C/man3/alloca.3:63
444 msgid ""
445 "The B<alloca>()  function returns a pointer to the beginning of the "
446 "allocated space.  If the allocation causes stack overflow, program behavior "
447 "is undefined."
448 msgstr ""
449 "B<alloca>()  関数は、割り付けた領域の始まりを指すポインタを返す。 割り付けに"
450 "よってスタックオーバーフローが起った場合の プログラムの動作は定義されていな"
451 "い。"
452
453 #. type: Plain text
454 #: build/C/man3/alloca.3:65
455 msgid "This function is not in POSIX.1-2001."
456 msgstr "この関数は POSIX.1-2001 にはない。"
457
458 #. type: Plain text
459 #: build/C/man3/alloca.3:71
460 msgid ""
461 "There is evidence that the B<alloca>()  function appeared in 32V, PWB, "
462 "PWB.2, 3BSD, and 4BSD.  There is a man page for it in 4.3BSD.  Linux uses "
463 "the GNU version."
464 msgstr ""
465 "32V, PWB, PWB.2, 3BSD, 4BSD に B<alloca>()  関数が登場した証拠がある。 "
466 "4.3BSD には、マニュアルページがある。 Linux は、GNU 版を使っている。 この関数"
467 "は POSIX.1-2001 にはない。"
468
469 #. type: Plain text
470 #: build/C/man3/alloca.3:86
471 msgid ""
472 "The B<alloca>()  function is machine- and compiler-dependent.  For certain "
473 "applications, its use can improve efficiency compared to the use of B<malloc>"
474 "(3)  plus B<free>(3).  In certain cases, it can also simplify memory "
475 "deallocation in applications that use B<longjmp>(3)  or B<siglongjmp>(3).  "
476 "Otherwise, its use is discouraged."
477 msgstr ""
478 "B<alloca>()  関数は、機種とコンパイラに依存する。 特定のアプリケーションで"
479 "は、この関数を使うと B<malloc>(3)  と B<free>(3)  を組み合わせて使った場合に"
480 "比べて効率を改善することができる。 特定の場合では、この関数を使うことで、 "
481 "B<longjmp>(3)  や B<siglongjmp>(3)  を使うアプリケーションでのメモリの開放を"
482 "簡単にすることができる。 それ以外の場合では、この関数の使用は推奨されない。"
483
484 #. type: Plain text
485 #: build/C/man3/alloca.3:95
486 msgid ""
487 "Because the space allocated by B<alloca>()  is allocated within the stack "
488 "frame, that space is automatically freed if the function return is jumped "
489 "over by a call to B<longjmp>(3)  or B<siglongjmp>(3)."
490 msgstr ""
491 "B<alloca>()  により割り当てられる空間はスタックフレームから割り当てらるの"
492 "で、 関数の戻り先が B<longjmp>(3)  や B<siglongjmp>(3)  の呼び出しによりジャ"
493 "ンプした場合には、 割り当てられた空間は自動的に解放される。"
494
495 #. type: Plain text
496 #: build/C/man3/alloca.3:100
497 msgid "Do not attempt to B<free>(3)  space allocated by B<alloca>()!"
498 msgstr ""
499 "B<alloca>()  で割り当てられた空間を B<free>(3)  しようとすることのないよう"
500 "に!"
501
502 #. type: SS
503 #: build/C/man3/alloca.3:100
504 #, no-wrap
505 msgid "Notes on the GNU Version"
506 msgstr "GNU 版についての注意"
507
508 #. type: Plain text
509 #: build/C/man3/alloca.3:122
510 msgid ""
511 "Normally, B<gcc>(1)  translates calls to B<alloca>()  with inlined code.  "
512 "This is not done when either the I<-ansi>, I<-std=c89>, I<-std=c99>, or the "
513 "I<-fno-builtin> option is given (and the header I<E<lt>alloca.hE<gt>> is not "
514 "included).  But beware! By default the glibc version of I<E<lt>stdlib."
515 "hE<gt>> includes I<E<lt>alloca.hE<gt>> and that contains the line:"
516 msgstr ""
517 "通常 B<gcc>(1)  は B<alloca>()  の呼び出しをインラインコードに変換する。 I<-"
518 "ansi>, I<-std=c89>, I<-std=c99>, I<-fno-builtin> のいずれかのオプションが指定"
519 "された場合、この変換は行われない (また I<E<lt>alloca.hE<gt>> のインクルードも"
520 "行われない)。 だだし、デフォルトでは glibc 版の I<E<lt>stdlib.hE<gt>> は "
521 "I<E<lt>alloca.hE<gt>> をインクルードしており、これには以下の行が含まれている"
522 "ので注意すること。"
523
524 #. type: Plain text
525 #: build/C/man3/alloca.3:125
526 #, no-wrap
527 msgid "    #define alloca(size)   __builtin_alloca (size)\n"
528 msgstr "    #define alloca(size)   __builtin_alloca (size)\n"
529
530 #. type: Plain text
531 #: build/C/man3/alloca.3:128
532 msgid "with messy consequences if one has a private version of this function."
533 msgstr "独自版の __builtin_alloca (size) 関数があると厄介な結果になる。"
534
535 #. type: Plain text
536 #: build/C/man3/alloca.3:132
537 msgid ""
538 "The fact that the code is inlined means that it is impossible to take the "
539 "address of this function, or to change its behavior by linking with a "
540 "different library."
541 msgstr ""
542 "このコードはインライン化されているので、 この関数のアドレスを取得したり、 他"
543 "のライブラリをリンクして動作を変更することはできない。"
544
545 #. type: Plain text
546 #: build/C/man3/alloca.3:136
547 msgid ""
548 "The inlined code often consists of a single instruction adjusting the stack "
549 "pointer, and does not check for stack overflow.  Thus, there is no NULL "
550 "error return."
551 msgstr ""
552 "通常このインラインコードはスタックポインタを移動する 1 つの命令 "
553 "(instruction) から構成されており、 スタックオーバーフローをチェックしない。 "
554 "よって NULL エラーが返されることはない。"
555
556 #. type: SH
557 #: build/C/man3/alloca.3:136 build/C/man2/cacheflush.2:81
558 #: build/C/man2/mlock.2:305 build/C/man2/mmap.2:540
559 #: build/C/man2/posix_fadvise.2:177 build/C/man2/shmget.2:284
560 #, no-wrap
561 msgid "BUGS"
562 msgstr "バグ"
563
564 #. type: Plain text
565 #: build/C/man3/alloca.3:141
566 msgid ""
567 "There is no error indication if the stack frame cannot be extended.  "
568 "(However, after a failed allocation, the program is likely to receive a "
569 "B<SIGSEGV> signal if it attempts to access the unallocated space.)"
570 msgstr ""
571 "スタックフレームが拡張できなかった場合、エラー通知は行われない。 (しかしなが"
572 "ら、割り当てに失敗した後で、プログラムが割り当てられなかった 空間にアクセスし"
573 "ようとした場合に B<SIGSEGV> シグナルを受信することだろう。)"
574
575 #. type: Plain text
576 #: build/C/man3/alloca.3:149
577 msgid ""
578 "On many systems B<alloca>()  cannot be used inside the list of arguments of "
579 "a function call, because the stack space reserved by B<alloca>()  would "
580 "appear on the stack in the middle of the space for the function arguments."
581 msgstr ""
582 "多くのシステムにおいて、関数コールの引き数のリスト内では B<alloca>()  が使え"
583 "ない。 これは、 B<alloca>()  によって予約されるスタック領域が、 関数引き数に"
584 "使われるスタック領域の中に現れてしまうためである。"
585
586 #. type: SH
587 #: build/C/man3/alloca.3:149 build/C/man2/fallocate.2:189
588 #: build/C/man2/madvise.2:353 build/C/man3/malloc_hook.3:133
589 #: build/C/man2/mlock.2:330 build/C/man2/mmap.2:649 build/C/man2/mmap2.2:88
590 #: build/C/man2/mprotect.2:220 build/C/man2/mremap.2:200
591 #: build/C/man2/msync.2:118 build/C/man3/mtrace.3:41
592 #: build/C/man2/posix_fadvise.2:182 build/C/man3/posix_fallocate.3:126
593 #: build/C/man3/posix_memalign.3:230 build/C/man2/readahead.2:92
594 #: build/C/man2/remap_file_pages.2:155 build/C/man3/shm_open.3:269
595 #: build/C/man7/shm_overview.7:114 build/C/man2/shmctl.2:403
596 #: build/C/man2/shmget.2:290 build/C/man2/shmop.2:282
597 #: build/C/man2/subpage_prot.2:120 build/C/man2/sync_file_range.2:217
598 #, no-wrap
599 msgid "SEE ALSO"
600 msgstr "関連項目"
601
602 #. type: Plain text
603 #: build/C/man3/alloca.3:153
604 msgid "B<brk>(2), B<longjmp>(3), B<malloc>(3)"
605 msgstr "B<brk>(2), B<longjmp>(3), B<malloc>(3)"
606
607 #. type: TH
608 #: build/C/man2/cacheflush.2:24
609 #, no-wrap
610 msgid "CACHEFLUSH"
611 msgstr "CACHEFLUSH"
612
613 #. type: TH
614 #: build/C/man2/cacheflush.2:24
615 #, no-wrap
616 msgid "2007-05-26"
617 msgstr "2007-05-26"
618
619 #. type: Plain text
620 #: build/C/man2/cacheflush.2:27
621 msgid "cacheflush - flush contents of instruction and/or data cache"
622 msgstr "cacheflush - 命令キャッシュやデータキャッシュの内容をフラッシュする"
623
624 #. type: Plain text
625 #: build/C/man2/cacheflush.2:30
626 #, no-wrap
627 msgid "B<#include E<lt>asm/cachectl.hE<gt>>\n"
628 msgstr "B<#include E<lt>asm/cachectl.hE<gt>>\n"
629
630 #. type: Plain text
631 #: build/C/man2/cacheflush.2:32
632 #, no-wrap
633 msgid "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
634 msgstr "B<int cacheflush(char *>I<addr>B<, int >I<nbytes>B<, int >I<cache>B<);>\n"
635
636 #. type: Plain text
637 #: build/C/man2/cacheflush.2:42
638 msgid ""
639 "B<cacheflush>()  flushes the contents of the indicated cache(s) for the user "
640 "addresses in the range I<addr> to I<(addr+nbytes-1)>.  I<cache> may be one "
641 "of:"
642 msgstr ""
643 "B<cacheflush>()  は I<addr> から I<(addr+nbytes-1)> の範囲のユーザアドレスに"
644 "対応する 指定されたキャッシュをフラッシュする。 I<cache> には以下のいずれかを"
645 "指定する:"
646
647 #. type: TP
648 #: build/C/man2/cacheflush.2:42
649 #, no-wrap
650 msgid "B<ICACHE>"
651 msgstr "B<ICACHE>"
652
653 #. type: Plain text
654 #: build/C/man2/cacheflush.2:45
655 msgid "Flush the instruction cache."
656 msgstr "命令 (instruction) キャッシュをフラッシュする。"
657
658 #. type: TP
659 #: build/C/man2/cacheflush.2:45
660 #, no-wrap
661 msgid "B<DCACHE>"
662 msgstr "B<DCACHE>"
663
664 #. type: Plain text
665 #: build/C/man2/cacheflush.2:48
666 msgid "Write back to memory and invalidate the affected valid cache lines."
667 msgstr "変更があったキャッシュラインをメモリに書き戻し、無効にする。"
668
669 #. type: TP
670 #: build/C/man2/cacheflush.2:48
671 #, no-wrap
672 msgid "B<BCACHE>"
673 msgstr "B<BCACHE>"
674
675 #. type: Plain text
676 #: build/C/man2/cacheflush.2:52
677 msgid "Same as B<(ICACHE|DCACHE)>."
678 msgstr "B<(ICACHE|DCACHE)> と同じ。"
679
680 #. type: Plain text
681 #: build/C/man2/cacheflush.2:58
682 msgid ""
683 "B<cacheflush>()  returns 0 on success or -1 on error.  If errors are "
684 "detected, I<errno> will indicate the error."
685 msgstr ""
686 "B<cacheflush>()  は成功した場合は 0 を、失敗した場合は -1 を返す。エラーが検"
687 "出された場合は I<errno> にエラーが指示される。"
688
689 #. type: TP
690 #: build/C/man2/cacheflush.2:59 build/C/man2/mmap2.2:58
691 #: build/C/man2/mremap.2:143 build/C/man2/shmctl.2:303
692 #: build/C/man2/subpage_prot.2:67
693 #, no-wrap
694 msgid "B<EFAULT>"
695 msgstr "B<EFAULT>"
696
697 #. type: Plain text
698 #: build/C/man2/cacheflush.2:66
699 msgid ""
700 "Some or all of the address range I<addr> to I<(addr+nbytes-1)> is not "
701 "accessible."
702 msgstr ""
703 "I<addr> から I<(addr+nbytes-1)> の範囲のアドレスの全てまたは一部が アクセス可"
704 "能ではない。"
705
706 #. type: TP
707 #: build/C/man2/cacheflush.2:66 build/C/man2/fallocate.2:124
708 #: build/C/man2/madvise.2:264 build/C/man2/mlock.2:158
709 #: build/C/man2/mlock.2:165 build/C/man2/mlock.2:177 build/C/man2/mmap.2:421
710 #: build/C/man2/mmap.2:429 build/C/man2/mmap.2:434 build/C/man2/mmap2.2:61
711 #: build/C/man2/mprotect.2:89 build/C/man2/mremap.2:152
712 #: build/C/man2/msync.2:80 build/C/man2/posix_fadvise.2:93
713 #: build/C/man3/posix_fallocate.3:79 build/C/man3/posix_memalign.3:124
714 #: build/C/man2/readahead.2:76 build/C/man2/remap_file_pages.2:130
715 #: build/C/man2/remap_file_pages.2:137 build/C/man3/shm_open.3:211
716 #: build/C/man2/shmctl.2:317 build/C/man2/shmget.2:196
717 #: build/C/man2/shmop.2:195 build/C/man2/shmop.2:218
718 #: build/C/man2/subpage_prot.2:72 build/C/man2/sync_file_range.2:152
719 #, no-wrap
720 msgid "B<EINVAL>"
721 msgstr "B<EINVAL>"
722
723 #. type: Plain text
724 #: build/C/man2/cacheflush.2:74
725 msgid "I<cache> is not one of B<ICACHE>, B<DCACHE>, or B<BCACHE>."
726 msgstr "I<cache> パラメータが B<ICACHE>, B<DCACHE>, B<BCACHE> のどれでもない。"
727
728 #.  FIXME This system call was only on MIPS back in 1.2 days, but
729 #.  by now it is on a number of other architectures (but not i386).
730 #.  Investigate the details and update this page.
731 #.  Irix 6.5 appears to have a cacheflush() syscall -- mtk
732 #. type: Plain text
733 #: build/C/man2/cacheflush.2:81
734 msgid ""
735 "This Linux-specific system call is only available on MIPS-based systems.  It "
736 "should not be used in programs intended to be portable."
737 msgstr ""
738 "この Linux 特有のシステムコールは MIPS ベースのシステムでのみ有効である。 移"
739 "植を意図したプログラムで使用すべきではない。"
740
741 #. type: Plain text
742 #: build/C/man2/cacheflush.2:88
743 msgid ""
744 "The current implementation ignores the I<addr> and I<nbytes> arguments.  "
745 "Therefore, the whole cache is always flushed."
746 msgstr ""
747 "現在の実装では、引き数 I<addr> と I<nbytes> は無視される。そのため、 常に全て"
748 "のキャッシュがフラッシュされる。"
749
750 #. type: TH
751 #: build/C/man2/fallocate.2:8
752 #, no-wrap
753 msgid "FALLOCATE"
754 msgstr "FALLOCATE"
755
756 #. type: TH
757 #: build/C/man2/fallocate.2:8
758 #, fuzzy, no-wrap
759 #| msgid "2009-02-25"
760 msgid "2012-02-27"
761 msgstr "2009-02-25"
762
763 #. type: Plain text
764 #: build/C/man2/fallocate.2:11
765 msgid "fallocate - manipulate file space"
766 msgstr "fallocate - ファイル空間の操作"
767
768 #. type: Plain text
769 #: build/C/man2/fallocate.2:15 build/C/man2/readahead.2:35
770 #, no-wrap
771 msgid ""
772 "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
773 "B<#include E<lt>fcntl.hE<gt>>\n"
774 msgstr ""
775 "B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
776 "B<#include E<lt>fcntl.hE<gt>>\n"
777
778 #. type: Plain text
779 #: build/C/man2/fallocate.2:18
780 #, no-wrap
781 msgid "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
782 msgstr "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
783
784 #. type: Plain text
785 #: build/C/man2/fallocate.2:24
786 #, fuzzy
787 #| msgid ""
788 #| "This is a nonportable, Linux-specific system call.  For the portable, "
789 #| "POSIX.1-specified method of ensuring that space is allocated for a file, "
790 #| "see B<posix_fallocate>()."
791 msgid ""
792 "This is a nonportable, Linux-specific system call.  For the portable, "
793 "POSIX.1-specified method of ensuring that space is allocated for a file, see "
794 "B<posix_fallocate>(3)."
795 msgstr ""
796 "このシステムコールは、移植性のない、Linux 固有のシステムコールである。 移植性"
797 "が必要な場合は、ファイルに対してディスク空間を確実に確保するために、 POSIX.1 "
798 "で規定された方法である B<posix_fallocate>(3)  を使うこと。"
799
800 #. type: Plain text
801 #: build/C/man2/fallocate.2:34
802 msgid ""
803 "B<fallocate>()  allows the caller to directly manipulate the allocated disk "
804 "space for the file referred to by I<fd> for the byte range starting at "
805 "I<offset> and continuing for I<len> bytes."
806 msgstr ""
807 "B<fallocate>()  を使うと、 I<fd> が参照するファイルに割り当てられたディスク空"
808 "間を直接操作できる。 操作対象は、 I<offset> から始まる長さ I<len> バイトの領"
809 "域である。"
810
811 #. type: Plain text
812 #: build/C/man2/fallocate.2:39
813 #, fuzzy
814 #| msgid ""
815 #| "The I<mode> argument determines the operation to be performed on the "
816 #| "given range.  Currently only one flag is supported for I<mode>:"
817 msgid ""
818 "The I<mode> argument determines the operation to be performed on the given "
819 "range.  Details of the supported operations are given in the subsections "
820 "below."
821 msgstr ""
822 "I<mode> 引き数は、指定された領域に対して実行する操作を指定する。 現在のとこ"
823 "ろ、 I<mode> に指定できるフラグは以下の一つだけである。"
824
825 #. type: SS
826 #: build/C/man2/fallocate.2:39
827 #, fuzzy, no-wrap
828 #| msgid "Out of disk space."
829 msgid "Allocating disk space"
830 msgstr "ディスク領域不足である。"
831
832 #. type: Plain text
833 #: build/C/man2/fallocate.2:58
834 #, fuzzy
835 #| msgid ""
836 #| "If B<FALLOC_FL_KEEP_SIZE> flag is not specified in I<mode>, the default "
837 #| "behavior is almost same as when this flag is specified.  The only "
838 #| "difference is that on success, the file size will be changed if I<offset "
839 #| "+ len> is greater than the file size.  This default behavior closely "
840 #| "resembles the behavior of the B<posix_fallocate>(3)  library function, "
841 #| "and is intended as a method of optimally implementing that function."
842 msgid ""
843 "The default operation (i.e., I<mode> is zero) of B<fallocate>()  allocates "
844 "and initializes to zero the disk space within the range specified by "
845 "I<offset> and I<len>.  The file size (as reported by B<stat>(2))  will be "
846 "changed if I<offset + len> is greater than the file size.  This default "
847 "behavior closely resembles the behavior of the B<posix_fallocate>(3)  "
848 "library function, and is intended as a method of optimally implementing that "
849 "function."
850 msgstr ""
851 "B<FALLOC_FL_KEEP_SIZE> フラグが I<mode> に指定されなかった場合、デフォルトの"
852 "動作は B<FALLOC_FL_KEEP_SIZE> フラグが指定された場合とほとんど同じとなる。 唯"
853 "一の違いは、 I<offset + len> がファイルサイズよりも大きかった場合、呼び出しが"
854 "成功すると ファイルサイズが変更される点である。 このデフォルトの動作は、ライ"
855 "ブラリ関数 B<posix_fallocate>(3)  の動作と非常に似ている。これは "
856 "B<posix_fallocate>(3)  を最適に実装する手段を提供することを目的としているから"
857 "である。"
858
859 #. type: Plain text
860 #: build/C/man2/fallocate.2:64
861 msgid ""
862 "After a successful call, subsequent writes into the range specified by "
863 "I<offset> and I<len> are guaranteed not to fail because of lack of disk "
864 "space."
865 msgstr ""
866
867 #. type: Plain text
868 #: build/C/man2/fallocate.2:75
869 #, fuzzy
870 #| msgid ""
871 #| "If B<FALLOC_FL_KEEP_SIZE> flag is not specified in I<mode>, the default "
872 #| "behavior is almost same as when this flag is specified.  The only "
873 #| "difference is that on success, the file size will be changed if I<offset "
874 #| "+ len> is greater than the file size.  This default behavior closely "
875 #| "resembles the behavior of the B<posix_fallocate>(3)  library function, "
876 #| "and is intended as a method of optimally implementing that function."
877 msgid ""
878 "If the B<FALLOC_FL_KEEP_SIZE> flag is specified in I<mode>, the behavior of "
879 "the call is similar, but the file size will not be changed even if I<offset "
880 "+ len> is greater than the file size.  Preallocating zeroed blocks beyond "
881 "the end of the file in this manner is useful for optimizing append workloads."
882 msgstr ""
883 "B<FALLOC_FL_KEEP_SIZE> フラグが I<mode> に指定されなかった場合、デフォルトの"
884 "動作は B<FALLOC_FL_KEEP_SIZE> フラグが指定された場合とほとんど同じとなる。 唯"
885 "一の違いは、 I<offset + len> がファイルサイズよりも大きかった場合、呼び出しが"
886 "成功すると ファイルサイズが変更される点である。 このデフォルトの動作は、ライ"
887 "ブラリ関数 B<posix_fallocate>(3)  の動作と非常に似ている。これは "
888 "B<posix_fallocate>(3)  を最適に実装する手段を提供することを目的としているから"
889 "である。"
890
891 #. type: Plain text
892 #: build/C/man2/fallocate.2:79
893 #, fuzzy
894 #| msgid ""
895 #| "Because allocation is done in block size chunks, B<fallocate>()  may "
896 #| "allocate a larger range than that which was specified."
897 msgid ""
898 "Because allocation is done in block size chunks, B<fallocate>()  may "
899 "allocate a larger range of disk space than was specified."
900 msgstr ""
901 "割り当てはブロックサイズ単位で行われるため、 B<fallocate>()  は指定されたより"
902 "も大きな領域を割り当てることがある。"
903
904 #. type: SS
905 #: build/C/man2/fallocate.2:79
906 #, fuzzy, no-wrap
907 #| msgid "fallocate - manipulate file space"
908 msgid "Deallocating file space"
909 msgstr "fallocate - ファイル空間の操作"
910
911 #. type: Plain text
912 #: build/C/man2/fallocate.2:94
913 msgid ""
914 "Specifying the B<FALLOC_FL_PUNCH_HOLE> flag (available since Linux 2.6.38) "
915 "in I<mode> deallocates space (i.e., creates a hole)  in the byte range "
916 "starting at I<offset> and continuing for I<len> bytes.  Within the specified "
917 "range, partial file system blocks are zeroed, and whole file system blocks "
918 "are removed from the file.  After a successful call, subsequent reads from "
919 "this range will return zeroes."
920 msgstr ""
921
922 #. type: Plain text
923 #: build/C/man2/fallocate.2:105
924 msgid ""
925 "The B<FALLOC_FL_PUNCH_HOLE> flag must be ORed with B<FALLOC_FL_KEEP_SIZE> in "
926 "I<mode>; in other words, even when punching off the end of the file, the "
927 "file size (as reported by B<stat>(2))  does not change."
928 msgstr ""
929
930 #. type: Plain text
931 #: build/C/man2/fallocate.2:109
932 msgid ""
933 "Not all file systems support B<FALLOC_FL_PUNCH_HOLE>; if a file system "
934 "doesn't support the operation, an error is returned."
935 msgstr ""
936
937 #. type: Plain text
938 #: build/C/man2/fallocate.2:112
939 msgid "B<fallocate>()  returns zero on success, and -1 on failure."
940 msgstr "B<fallocate>()  は成功すると 0 を返し、エラーの場合は -1 を返す。"
941
942 #. type: TP
943 #: build/C/man2/fallocate.2:113 build/C/man2/madvise.2:261
944 #: build/C/man2/mmap.2:415 build/C/man2/posix_fadvise.2:90
945 #: build/C/man3/posix_fallocate.3:71 build/C/man2/readahead.2:72
946 #: build/C/man2/sync_file_range.2:148
947 #, no-wrap
948 msgid "B<EBADF>"
949 msgstr "B<EBADF>"
950
951 #. type: Plain text
952 #: build/C/man2/fallocate.2:117 build/C/man3/posix_fallocate.3:75
953 msgid "I<fd> is not a valid file descriptor, or is not opened for writing."
954 msgstr ""
955 "I<fd> が有効なファイルディスクリプタでないか、 書き込み用としてオープンされて"
956 "いない。"
957
958 #. type: TP
959 #: build/C/man2/fallocate.2:117 build/C/man3/posix_fallocate.3:75
960 #, no-wrap
961 msgid "B<EFBIG>"
962 msgstr "B<EFBIG>"
963
964 #. type: Plain text
965 #: build/C/man2/fallocate.2:121
966 msgid "I<offset>+I<len> exceeds the maximum file size."
967 msgstr "I<offset + len> がファイルサイズの最大値よりも大きい。"
968
969 #. type: TP
970 #: build/C/man2/fallocate.2:121
971 #, no-wrap
972 msgid "B<EINTR>"
973 msgstr "B<EINTR>"
974
975 #. type: Plain text
976 #: build/C/man2/fallocate.2:124
977 msgid "A signal was caught during execution."
978 msgstr "実行中にシグナルが捕捉された。"
979
980 #. type: Plain text
981 #: build/C/man2/fallocate.2:136 build/C/man3/posix_fallocate.3:85
982 msgid "I<offset> was less than 0, or I<len> was less than or equal to 0."
983 msgstr "I<offset> が 0 未満だったか、 I<len> が 0 以下だった。"
984
985 #. type: TP
986 #: build/C/man2/fallocate.2:136 build/C/man2/madvise.2:292
987 #: build/C/man2/sync_file_range.2:160
988 #, no-wrap
989 msgid "B<EIO>"
990 msgstr "B<EIO>"
991
992 #. type: Plain text
993 #: build/C/man2/fallocate.2:139
994 msgid "An I/O error occurred while reading from or writing to a file system."
995 msgstr "ファイルシステムとの読み書き中に入出力エラーが発生した。"
996
997 #. type: TP
998 #: build/C/man2/fallocate.2:139 build/C/man2/mmap.2:450
999 #: build/C/man3/posix_fallocate.3:85
1000 #, no-wrap
1001 msgid "B<ENODEV>"
1002 msgstr "B<ENODEV>"
1003
1004 #. type: Plain text
1005 #: build/C/man2/fallocate.2:146
1006 msgid ""
1007 "I<fd> does not refer to a regular file or a directory.  (If I<fd> is a pipe "
1008 "or FIFO, a different error results.)"
1009 msgstr ""
1010 "I<fd> が通常のファイルかディレクトリを参照していない (I<fd> がパイプや FIFO "
1011 "を参照している場合、別のエラーが発生する)。"
1012
1013 #. type: TP
1014 #: build/C/man2/fallocate.2:146 build/C/man3/posix_fallocate.3:89
1015 #: build/C/man2/shmget.2:214 build/C/man2/sync_file_range.2:166
1016 #, no-wrap
1017 msgid "B<ENOSPC>"
1018 msgstr "B<ENOSPC>"
1019
1020 #. type: Plain text
1021 #: build/C/man2/fallocate.2:151 build/C/man3/posix_fallocate.3:94
1022 msgid ""
1023 "There is not enough space left on the device containing the file referred to "
1024 "by I<fd>."
1025 msgstr "I<fd> が参照するファイルを含むデバイスに十分な空き領域がない。"
1026
1027 #. type: Plain text
1028 #: build/C/man2/fallocate.2:156
1029 msgid ""
1030 "The file system containing the file referred to by I<fd> does not support "
1031 "this operation."
1032 msgstr ""
1033 "I<fd> が参照するファイルを含むファイルシステムが 指定された操作をサポートして"
1034 "いない。"
1035
1036 #. type: TP
1037 #: build/C/man2/fallocate.2:156
1038 #, no-wrap
1039 msgid "B<EOPNOTSUPP>"
1040 msgstr "B<EOPNOTSUPP>"
1041
1042 #. type: Plain text
1043 #: build/C/man2/fallocate.2:162
1044 msgid ""
1045 "The I<mode> is not supported by the file system containing the file referred "
1046 "to by I<fd>."
1047 msgstr ""
1048 "I<fd> が参照するファイルを含むファイルシステムが I<mode> をサポートしていな"
1049 "い。"
1050
1051 #. type: TP
1052 #: build/C/man2/fallocate.2:162 build/C/man2/mlock.2:144
1053 #: build/C/man2/mlock.2:183 build/C/man2/mmap.2:458 build/C/man2/shmctl.2:342
1054 #: build/C/man2/shmget.2:222
1055 #, no-wrap
1056 msgid "B<EPERM>"
1057 msgstr "B<EPERM>"
1058
1059 #. type: Plain text
1060 #: build/C/man2/fallocate.2:178
1061 msgid ""
1062 "The file referred to by I<fd> is marked immutable (see B<chattr>(1)).  Or: "
1063 "I<mode> specifies B<FALLOC_FL_PUNCH_HOLE> and the file referred to by I<fd> "
1064 "is marked append-only (see B<chattr>(1))."
1065 msgstr ""
1066
1067 #. type: TP
1068 #: build/C/man2/fallocate.2:178 build/C/man2/posix_fadvise.2:96
1069 #: build/C/man3/posix_fallocate.3:94 build/C/man2/sync_file_range.2:169
1070 #, no-wrap
1071 msgid "B<ESPIPE>"
1072 msgstr "B<ESPIPE>"
1073
1074 #. type: Plain text
1075 #: build/C/man2/fallocate.2:182
1076 #, fuzzy
1077 #| msgid "I<fd> refers to a pipe."
1078 msgid "I<fd> refers to a pipe or FIFO."
1079 msgstr "I<fd> がパイプを参照している。"
1080
1081 #. type: SH
1082 #: build/C/man2/fallocate.2:182 build/C/man2/mmap2.2:70
1083 #: build/C/man2/posix_fadvise.2:103 build/C/man3/posix_fallocate.3:98
1084 #: build/C/man3/posix_memalign.3:133 build/C/man2/readahead.2:82
1085 #: build/C/man2/remap_file_pages.2:146 build/C/man3/shm_open.3:247
1086 #: build/C/man2/subpage_prot.2:85 build/C/man2/sync_file_range.2:177
1087 #, no-wrap
1088 msgid "VERSIONS"
1089 msgstr "バージョン"
1090
1091 #. type: Plain text
1092 #: build/C/man2/fallocate.2:186
1093 msgid ""
1094 "B<fallocate>()  is available on Linux since kernel 2.6.23.  Support is "
1095 "provided by glibc since version 2.10."
1096 msgstr ""
1097 "B<fallocate>()  はカーネル 2.6.23 以降の Linux で利用可能である。 glibc での"
1098 "対応はバージョン 3.10 以降で行われている。"
1099
1100 #. type: Plain text
1101 #: build/C/man2/fallocate.2:189
1102 msgid "B<fallocate>()  is Linux-specific."
1103 msgstr "B<fallocate>()  は Linux 固有である。"
1104
1105 #. type: Plain text
1106 #: build/C/man2/fallocate.2:193
1107 msgid "B<ftruncate>(2), B<posix_fadvise>(3), B<posix_fallocate>(3)"
1108 msgstr "B<ftruncate>(2), B<posix_fadvise>(3), B<posix_fallocate>(3)"
1109
1110 #. type: TH
1111 #: build/C/man2/madvise.2:35
1112 #, no-wrap
1113 msgid "MADVISE"
1114 msgstr "MADVISE"
1115
1116 #. type: TH
1117 #: build/C/man2/madvise.2:35
1118 #, fuzzy, no-wrap
1119 #| msgid "2011-09-08"
1120 msgid "2011-09-18"
1121 msgstr "2011-09-08"
1122
1123 #. type: Plain text
1124 #: build/C/man2/madvise.2:38
1125 msgid "madvise - give advice about use of memory"
1126 msgstr "madvise - メモリ利用に関するアドバイスを与える"
1127
1128 #. type: Plain text
1129 #: build/C/man2/madvise.2:40 build/C/man2/msync.2:30
1130 #: build/C/man3/shm_open.3:31
1131 msgid "B<#include E<lt>sys/mman.hE<gt>>"
1132 msgstr "B<#include E<lt>sys/mman.hE<gt>>"
1133
1134 #. type: Plain text
1135 #: build/C/man2/madvise.2:42
1136 msgid ""
1137 "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
1138 msgstr ""
1139 "B<int madvise(void *>I<addr>B<, size_t >I<length>B<, int >I<advice>B<);>"
1140
1141 #. type: Plain text
1142 #: build/C/man2/madvise.2:46 build/C/man2/posix_fadvise.2:42
1143 #: build/C/man3/posix_fallocate.3:37 build/C/man3/posix_memalign.3:44
1144 msgid ""
1145 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
1146 msgstr "glibc 向けの機能検査マクロの要件 (B<feature_test_macros>(7)  参照):"
1147
1148 #. type: Plain text
1149 #: build/C/man2/madvise.2:50
1150 msgid "B<madvise>(): _BSD_SOURCE"
1151 msgstr "B<madvise>(): _BSD_SOURCE"
1152
1153 #. type: Plain text
1154 #: build/C/man2/madvise.2:68
1155 msgid ""
1156 "The B<madvise>()  system call advises the kernel about how to handle paging "
1157 "input/output in the address range beginning at address I<addr> and with size "
1158 "I<length> bytes.  It allows an application to tell the kernel how it expects "
1159 "to use some mapped or shared memory areas, so that the kernel can choose "
1160 "appropriate read-ahead and caching techniques.  This call does not influence "
1161 "the semantics of the application (except in the case of B<MADV_DONTNEED>), "
1162 "but may influence its performance.  The kernel is free to ignore the advice."
1163 msgstr ""
1164 "B<madvise>()  システムコールは、アドレス I<addr> からはじまる I<length> バイ"
1165 "トのメモリブロックのページング入出力をどう扱えば良いか、 カーネルにアドバイス"
1166 "する。 これを用いると、 アプリケーションからカーネルに、 マップされたメモリや"
1167 "共有メモリをどのように扱ってほしいか伝えることができ、 カーネルはそれに応じて"
1168 "先読みやキャッシュなどの適切な手法を選択できる。 このコールはアプリケーション"
1169 "の動作そのものには影響しない (B<MADV_DONTNEED> の場合は別) が、 性能には影響"
1170 "しうる。 なおこのアドバイスを受け入れるかどうかはカーネルに任される。"
1171
1172 #. type: Plain text
1173 #: build/C/man2/madvise.2:72
1174 msgid "The advice is indicated in the I<advice> argument which can be"
1175 msgstr ""
1176 "アドバイスは引き数 I<advice> によって与える。以下のいずれかを指定できる。"
1177
1178 #. type: TP
1179 #: build/C/man2/madvise.2:72
1180 #, no-wrap
1181 msgid "B<MADV_NORMAL>"
1182 msgstr "B<MADV_NORMAL>"
1183
1184 #. type: Plain text
1185 #: build/C/man2/madvise.2:76
1186 msgid "No special treatment.  This is the default."
1187 msgstr "特別な扱いは行わない。これがデフォルトである。"
1188
1189 #. type: TP
1190 #: build/C/man2/madvise.2:76
1191 #, no-wrap
1192 msgid "B<MADV_RANDOM>"
1193 msgstr "B<MADV_RANDOM>"
1194
1195 #. type: Plain text
1196 #: build/C/man2/madvise.2:80
1197 msgid ""
1198 "Expect page references in random order.  (Hence, read ahead may be less "
1199 "useful than normally.)"
1200 msgstr ""
1201 "ページ参照はランダムな順序で行われそうだ。 (したがって、先読みはあまり効果が"
1202 "なさそうだ。)"
1203
1204 #. type: TP
1205 #: build/C/man2/madvise.2:80
1206 #, no-wrap
1207 msgid "B<MADV_SEQUENTIAL>"
1208 msgstr "B<MADV_SEQUENTIAL>"
1209
1210 #. type: Plain text
1211 #: build/C/man2/madvise.2:85
1212 msgid ""
1213 "Expect page references in sequential order.  (Hence, pages in the given "
1214 "range can be aggressively read ahead, and may be freed soon after they are "
1215 "accessed.)"
1216 msgstr ""
1217 "ページ参照はシーケンシャルな順序で行われそうだ。 (したがって与えた範囲のペー"
1218 "ジは積極的に先読みしておくと良いだろう。 またアクセスが終わったら速やかに解放"
1219 "して良い。)"
1220
1221 #. type: TP
1222 #: build/C/man2/madvise.2:85
1223 #, no-wrap
1224 msgid "B<MADV_WILLNEED>"
1225 msgstr "B<MADV_WILLNEED>"
1226
1227 #. type: Plain text
1228 #: build/C/man2/madvise.2:89
1229 msgid ""
1230 "Expect access in the near future.  (Hence, it might be a good idea to read "
1231 "some pages ahead.)"
1232 msgstr ""
1233 "近い将来にアクセスされそうだ。 (したがってこれらのページを今のうちに先読みし"
1234 "ておくといいだろう。)"
1235
1236 #. type: TP
1237 #: build/C/man2/madvise.2:89
1238 #, no-wrap
1239 msgid "B<MADV_DONTNEED>"
1240 msgstr "B<MADV_DONTNEED>"
1241
1242 #. type: Plain text
1243 #: build/C/man2/madvise.2:100
1244 msgid ""
1245 "Do not expect access in the near future.  (For the time being, the "
1246 "application is finished with the given range, so the kernel can free "
1247 "resources associated with it.)  Subsequent accesses of pages in this range "
1248 "will succeed, but will result either in reloading of the memory contents "
1249 "from the underlying mapped file (see B<mmap>(2))  or zero-fill-on-demand "
1250 "pages for mappings without an underlying file."
1251 msgstr ""
1252 "しばらくアクセスはなさそうだ。 (現時点でアプリケーションは与えた範囲の処理を"
1253 "終えている。 したがってカーネルはこれに関連するリソースを解放して良い。)  こ"
1254 "れ以降この範囲のページへのアクセスがあると、 成功はするが、メモリの内容をマッ"
1255 "プ元のファイルからロードし直すことになる (B<mmap>(2)  を見よ) か、 または元"
1256 "ファイルがないマップページでは アクセスがあったときに 0 埋めが行われることに"
1257 "なる。"
1258
1259 #. type: TP
1260 #: build/C/man2/madvise.2:100
1261 #, no-wrap
1262 msgid "B<MADV_REMOVE> (Since Linux 2.6.16)"
1263 msgstr "B<MADV_REMOVE> (Linux 2.6.16 以降)"
1264
1265 #.  2.6.18-rc5
1266 #.  Databases want to use this feature to drop a section of their
1267 #.  bufferpool (shared memory segments) - without writing back to
1268 #.  disk/swap space.  This feature is also useful for supporting
1269 #.  hot-plug memory on UML.
1270 #. type: Plain text
1271 #: build/C/man2/madvise.2:113
1272 msgid ""
1273 "Free up a given range of pages and its associated backing store.  Currently, "
1274 "only shmfs/tmpfs supports this; other file systems return with the error "
1275 "B<ENOSYS>."
1276 msgstr ""
1277 "指定された範囲のページと関連するバッキングストアを解放する。 現在のところ、 "
1278 "shmfs/tmpfs だけがこれに対応している。 他のファイルシステムでは B<ENOSYS> が"
1279 "返される。"
1280
1281 #. type: TP
1282 #: build/C/man2/madvise.2:113
1283 #, no-wrap
1284 msgid "B<MADV_DONTFORK> (Since Linux 2.6.16)"
1285 msgstr "B<MADV_DONTFORK> (Linux 2.6.16 以降)"
1286
1287 #.  See http://lwn.net/Articles/171941/
1288 #.  [PATCH] madvise MADV_DONTFORK/MADV_DOFORK
1289 #.  Currently, copy-on-write may change the physical address of
1290 #.  a page even if the user requested that the page is pinned in
1291 #.  memory (either by mlock or by get_user_pages).  This happens
1292 #.  if the process forks meanwhile, and the parent writes to that
1293 #.  page.  As a result, the page is orphaned: in case of
1294 #.  get_user_pages, the application will never see any data hardware
1295 #.  DMA's into this page after the COW.  In case of mlock'd memory,
1296 #.  the parent is not getting the realtime/security benefits of mlock.
1297 #.  In particular, this affects the Infiniband modules which do DMA from
1298 #.  and into user pages all the time.
1299 #.  This patch adds madvise options to control whether memory range is
1300 #.  inherited across fork. Useful e.g. for when hardware is doing DMA
1301 #.  from/into these pages.  Could also be useful to an application
1302 #.  wanting to speed up its forks by cutting large areas out of
1303 #.  consideration.
1304 #.  SEE ALSO: http://lwn.net/Articles/171941/
1305 #.  "Tweaks to madvise() and posix_fadvise()", 14 Feb 2006
1306 #. type: Plain text
1307 #: build/C/man2/madvise.2:144
1308 msgid ""
1309 "Do not make the pages in this range available to the child after a B<fork>"
1310 "(2).  This is useful to prevent copy-on-write semantics from changing the "
1311 "physical location of a page(s) if the parent writes to it after a B<fork>"
1312 "(2).  (Such page relocations cause problems for hardware that DMAs into the "
1313 "page(s).)"
1314 msgstr ""
1315 "B<fork>(2)  が行われた後、指定された範囲のページを子プロセスが利用できないよ"
1316 "うにする。 この機能は、書き込み時コピー (copy-on-write) 方式で、 B<fork>(2)  "
1317 "の後で親プロセスがページに書き込みを行った場合に ページの物理位置が変化しない"
1318 "ようにするのに有効である (ページの再配置はハードウェアがそのページに DMA 転送"
1319 "を行うような場合に 問題を起こすことがある)。"
1320
1321 #. type: TP
1322 #: build/C/man2/madvise.2:144
1323 #, no-wrap
1324 msgid "B<MADV_DOFORK> (Since Linux 2.6.16)"
1325 msgstr "B<MADV_DOFORK> (Linux 2.6.16 以降)"
1326
1327 #. type: Plain text
1328 #: build/C/man2/madvise.2:150
1329 msgid ""
1330 "Undo the effect of B<MADV_DONTFORK>, restoring the default behavior, whereby "
1331 "a mapping is inherited across B<fork>(2)."
1332 msgstr ""
1333 "B<MADV_DONTFORK> の影響を取り消し、デフォルトの動作に戻す。 つまり、 B<fork>"
1334 "(2)  の前後でマッピングは継承されるようになる。"
1335
1336 #. type: TP
1337 #: build/C/man2/madvise.2:150
1338 #, fuzzy, no-wrap
1339 #| msgid "B<MADV_DOFORK> (Since Linux 2.6.16)"
1340 msgid "B<MADV_HWPOISON> (Since Linux 2.6.32)"
1341 msgstr "B<MADV_DOFORK> (Linux 2.6.16 以降)"
1342
1343 #. type: Plain text
1344 #: build/C/man2/madvise.2:162
1345 msgid ""
1346 "Poison a page and handle it like a hardware memory corruption.  This "
1347 "operation is only available for privileged (B<CAP_SYS_ADMIN>)  processes.  "
1348 "This operation may result in the calling process receiving a B<SIGBUS> and "
1349 "the page being unmapped.  This feature is intended for testing of memory "
1350 "error-handling code; it is only available if the kernel was configured with "
1351 "B<CONFIG_MEMORY_FAILURE>."
1352 msgstr ""
1353
1354 #. type: TP
1355 #: build/C/man2/madvise.2:162
1356 #, fuzzy, no-wrap
1357 #| msgid "B<MADV_DOFORK> (Since Linux 2.6.16)"
1358 msgid "B<MADV_SOFT_OFFLINE> (Since Linux 2.6.33)"
1359 msgstr "B<MADV_DOFORK> (Linux 2.6.16 以降)"
1360
1361 #. type: Plain text
1362 #: build/C/man2/madvise.2:180
1363 msgid ""
1364 "Soft offline the pages in the range specified by I<addr> and I<length>.  The "
1365 "memory of each page in the specified range is preserved (i.e., when next "
1366 "accessed, the same content will be visible, but in a new physical page "
1367 "frame), and the original page is offlined (i.e., no longer used, and taken "
1368 "out of normal memory management).  The effect of the B<MADV_SOFT_OFFLINE> "
1369 "operation is invisible to (i.e., does not change the semantics of)  the "
1370 "calling process.  This feature is intended for testing of memory error-"
1371 "handling code; it is only available if the kernel was configured with "
1372 "B<CONFIG_MEMORY_FAILURE>."
1373 msgstr ""
1374
1375 #. type: TP
1376 #: build/C/man2/madvise.2:180
1377 #, fuzzy, no-wrap
1378 #| msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
1379 msgid "B<MADV_MERGEABLE> (since Linux 2.6.32)"
1380 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
1381
1382 #. type: Plain text
1383 #: build/C/man2/madvise.2:205
1384 msgid ""
1385 "Enable Kernel Samepage Merging (KSM) for the pages in the range specified by "
1386 "I<addr> and I<length>.  The kernel regularly scans those areas of user "
1387 "memory that have been marked as mergeable, looking for pages with identical "
1388 "content.  These are replaced by a single write-protected page (which is "
1389 "automatically copied if a process later wants to update the content of the "
1390 "page).  KSM only merges private anonymous pages (see B<mmap>(2)).  The KSM "
1391 "feature is intended for applications that generate many instances of the "
1392 "same data (e.g., virtualization systems such as KVM).  It can consume a lot "
1393 "of processing power; use with care.  See the kernel source file "
1394 "I<Documentation/vm/ksm.txt> for more details.  The B<MADV_MERGEABLE> and "
1395 "B<MADV_UNMERGEABLE> operations are only available if the kernel was "
1396 "configured with B<CONFIG_KSM>."
1397 msgstr ""
1398
1399 #. type: TP
1400 #: build/C/man2/madvise.2:205
1401 #, fuzzy, no-wrap
1402 #| msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
1403 msgid "B<MADV_UNMERGEABLE> (since Linux 2.6.32)"
1404 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
1405
1406 #. type: Plain text
1407 #: build/C/man2/madvise.2:214
1408 msgid ""
1409 "Undo the effect of an earlier B<MADV_MERGEABLE> operation on the specified "
1410 "address range; KSM unmerges whatever pages it had merged in the address "
1411 "range specified by I<addr> and I<length>."
1412 msgstr ""
1413
1414 #. type: TP
1415 #: build/C/man2/madvise.2:214
1416 #, fuzzy, no-wrap
1417 #| msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
1418 msgid "B<MADV_HUGEPAGE> (since Linux 2.6.38)"
1419 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
1420
1421 #.  http://lwn.net/Articles/358904/
1422 #.  https://lwn.net/Articles/423584/
1423 #. type: Plain text
1424 #: build/C/man2/madvise.2:243
1425 msgid ""
1426 "Enables Transparent Huge Pages (THP) for pages in the range specified by "
1427 "I<addr> and I<length>.  Currently, Transparent Huge Pages only work with "
1428 "private anonymous pages (see B<mmap>(2)).  The kernel will regularly scan "
1429 "the areas marked as huge page candidates to replace them with huge pages.  "
1430 "The kernel will also allocate huge pages directly when the region is "
1431 "naturally aligned to the huge page size (see B<posix_memalign>(2)).  This "
1432 "feature is primarily aimed at applications that use large mappings of data "
1433 "and access large regions of that memory at a time (e.g. virtualization "
1434 "systems such as QEMU).  It can very easily waste memory (e.g. a 2MB mapping "
1435 "that only ever accesses 1 byte will result in 2MB of wired memory instead of "
1436 "one 4KB page).  See the kernel source file I<Documentation/vm/transhuge.txt> "
1437 "for more details.  The B<MADV_HUGEPAGE> and B<MADV_NOHUGEPAGE> operations "
1438 "are only available if the kernel was configured with "
1439 "B<CONFIG_TRANSPARENT_HUGEPAGE>."
1440 msgstr ""
1441
1442 #. type: TP
1443 #: build/C/man2/madvise.2:243
1444 #, fuzzy, no-wrap
1445 #| msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
1446 msgid "B<MADV_NOHUGEPAGE> (since Linux 2.6.38)"
1447 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
1448
1449 #. type: Plain text
1450 #: build/C/man2/madvise.2:250
1451 msgid ""
1452 "Ensures that memory in the address range specified by I<addr> and I<length> "
1453 "will not be collapsed into huge pages."
1454 msgstr ""
1455
1456 #. type: Plain text
1457 #: build/C/man2/madvise.2:257
1458 msgid ""
1459 "On success B<madvise>()  returns zero.  On error, it returns -1 and I<errno> "
1460 "is set appropriately."
1461 msgstr ""
1462 "B<madvise>()  は成功すると 0 を返す。 エラーが起こると -1 を返し、 I<errno> "
1463 "を適切な値に設定する。"
1464
1465 #. type: TP
1466 #: build/C/man2/madvise.2:258 build/C/man2/mlock.2:155 build/C/man2/mmap.2:411
1467 #: build/C/man2/mremap.2:137
1468 #, no-wrap
1469 msgid "B<EAGAIN>"
1470 msgstr "B<EAGAIN>"
1471
1472 #. type: Plain text
1473 #: build/C/man2/madvise.2:261
1474 msgid "A kernel resource was temporarily unavailable."
1475 msgstr "何らかのカーネルリソースが一時的に利用できなかった。"
1476
1477 #. type: Plain text
1478 #: build/C/man2/madvise.2:264
1479 msgid "The map exists, but the area maps something that isn't a file."
1480 msgstr "指定したマップは存在するが、ファイルではないところをマップしている。"
1481
1482 #. type: Plain text
1483 #: build/C/man2/madvise.2:267
1484 msgid "This error can occur for the following reasons:"
1485 msgstr ""
1486
1487 #. type: IP
1488 #: build/C/man2/madvise.2:268 build/C/man2/madvise.2:274
1489 #: build/C/man2/madvise.2:277 build/C/man2/madvise.2:280
1490 #: build/C/man2/madvise.2:283
1491 #, no-wrap
1492 msgid "*"
1493 msgstr ""
1494
1495 #.  .I len
1496 #.  is zero,
1497 #. type: Plain text
1498 #: build/C/man2/madvise.2:274
1499 #, fuzzy
1500 #| msgid "I<len> was negative."
1501 msgid "The value I<len> is negative."
1502 msgstr "I<len> が負の数である。"
1503
1504 #. type: Plain text
1505 #: build/C/man2/madvise.2:277
1506 msgid "I<addr> is not page-aligned."
1507 msgstr ""
1508
1509 #. type: Plain text
1510 #: build/C/man2/madvise.2:280
1511 #, fuzzy
1512 #| msgid "I<fd> is not a valid file descriptor."
1513 msgid "I<advice> is not a valid value"
1514 msgstr "I<fd> が有効なファイルディスクリプタではない。"
1515
1516 #. type: Plain text
1517 #: build/C/man2/madvise.2:283
1518 #, fuzzy
1519 #| msgid ""
1520 #| "The value I<len> is negative, I<addr> is not page-aligned, I<advice> is "
1521 #| "not a valid value, or the application is attempting to release locked or "
1522 #| "shared pages (with B<MADV_DONTNEED>)."
1523 msgid ""
1524 "The application is attempting to release locked or shared pages (with "
1525 "B<MADV_DONTNEED>)."
1526 msgstr ""
1527 "I<len> の値が負、 I<addr> がページ境界でない、 I<advice> が正しい値でない、 "
1528 "アプリケーションがロックされたページや共有ページを (B<MADV_DONTNEED> で) 解放"
1529 "しようとしている、など。"
1530
1531 #. type: Plain text
1532 #: build/C/man2/madvise.2:291
1533 msgid ""
1534 "B<MADV_MERGEABLE> or B<MADV_UNMERGEABLE> was specified in I<advice>, but the "
1535 "kernel was not configured with B<CONFIG_KSM>."
1536 msgstr ""
1537
1538 #. type: Plain text
1539 #: build/C/man2/madvise.2:298
1540 msgid ""
1541 "(for B<MADV_WILLNEED>)  Paging in this area would exceed the process's "
1542 "maximum resident set size."
1543 msgstr ""
1544 "(B<MADV_WILLNEED> の場合) この範囲のページングを行うと、 プロセスの RSS "
1545 "(resident set size) の最大値を越えてしまう。"
1546
1547 #. type: TP
1548 #: build/C/man2/madvise.2:298 build/C/man2/madvise.2:303
1549 #: build/C/man2/mlock.2:124 build/C/man2/mlock.2:132 build/C/man2/mlock.2:170
1550 #: build/C/man2/mmap.2:454 build/C/man2/mprotect.2:94
1551 #: build/C/man2/mprotect.2:97 build/C/man2/mremap.2:180
1552 #: build/C/man2/msync.2:93 build/C/man3/posix_memalign.3:130
1553 #: build/C/man2/shmctl.2:326 build/C/man2/shmget.2:211
1554 #: build/C/man2/shmop.2:209 build/C/man2/subpage_prot.2:82
1555 #: build/C/man2/sync_file_range.2:163
1556 #, no-wrap
1557 msgid "B<ENOMEM>"
1558 msgstr "B<ENOMEM>"
1559
1560 #. type: Plain text
1561 #: build/C/man2/madvise.2:303
1562 msgid "(for B<MADV_WILLNEED>)  Not enough memory: paging in failed."
1563 msgstr "(B<MADV_WILLNEED> の場合) メモリが足りず、ページングに失敗した。"
1564
1565 #. type: Plain text
1566 #: build/C/man2/madvise.2:307
1567 msgid ""
1568 "Addresses in the specified range are not currently mapped, or are outside "
1569 "the address space of the process."
1570 msgstr ""
1571 "指定した範囲のアドレスが、現在マップされていない。 あるいはプロセスのアドレス"
1572 "空間の内部にない。"
1573
1574 #.  FIXME . Write a posix_fadvise(3) page.
1575 #. type: Plain text
1576 #: build/C/man2/madvise.2:319
1577 msgid ""
1578 "POSIX.1b.  POSIX.1-2001 describes B<posix_madvise>(3)  with constants "
1579 "B<POSIX_MADV_NORMAL>, etc., with a behavior close to that described here.  "
1580 "There is a similar B<posix_fadvise>(2)  for file access."
1581 msgstr ""
1582 "POSIX.1b.  POSIX.1-2001 では、 B<posix_madvise>(3)  を B<POSIX_MADV_NORMAL> "
1583 "などの定数とともに記述していた (それぞれの振る舞いはここで述べたものに近"
1584 "い)。 ファイルアクセスに対しても B<posix_fadvise>(2)  という類似の関数が存在"
1585 "する。"
1586
1587 #. type: Plain text
1588 #: build/C/man2/madvise.2:328
1589 #, fuzzy
1590 #| msgid ""
1591 #| "B<MADV_REMOVE>, B<MADV_DONTFORK>, and B<MADV_DOFORK> are Linux-specific."
1592 msgid ""
1593 "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK>, B<MADV_HWPOISON>, "
1594 "B<MADV_MERGEABLE>, and B<MADV_UNMERGEABLE> are Linux-specific."
1595 msgstr "B<MADV_REMOVE>, B<MADV_DONTFORK>, B<MADV_DOFORK> は Linux 固有である。"
1596
1597 #. type: SS
1598 #: build/C/man2/madvise.2:329 build/C/man2/mlock.2:268
1599 #: build/C/man2/shmget.2:278
1600 #, no-wrap
1601 msgid "Linux Notes"
1602 msgstr "Linux での注意"
1603
1604 #. type: Plain text
1605 #: build/C/man2/madvise.2:337
1606 msgid ""
1607 "The current Linux implementation (2.4.0) views this system call more as a "
1608 "command than as advice and hence may return an error when it cannot do what "
1609 "it usually would do in response to this advice.  (See the ERRORS description "
1610 "above.)  This is nonstandard behavior."
1611 msgstr ""
1612 "現在の Linux の実装 (2.4.0) では、 このシステムコールをアドバイスというよりは"
1613 "命令と見ている。 したがってこのアドバイスに対して通常行われる動作が不可能な場"
1614 "合は、 エラーを返すことがある (上記の エラー の記述を参照)。 この振舞いは標準"
1615 "とは異なる。"
1616
1617 #.  .SH HISTORY
1618 #.  The
1619 #.  .BR madvise ()
1620 #.  function first appeared in 4.4BSD.
1621 #. type: Plain text
1622 #: build/C/man2/madvise.2:353
1623 msgid ""
1624 "The Linux implementation requires that the address I<addr> be page-aligned, "
1625 "and allows I<length> to be zero.  If there are some parts of the specified "
1626 "address range that are not mapped, the Linux version of B<madvise>()  "
1627 "ignores them and applies the call to the rest (but returns B<ENOMEM> from "
1628 "the system call, as it should)."
1629 msgstr ""
1630 "Linux の実装では I<addr> のアドレスはページ境界の値でなければならない。また "
1631 "I<length> は 0 であっても構わない。 また Linux 版の B<madvise>()  では、指定"
1632 "されたアドレス範囲にマップされていない部分があると、 これらを無視して残りの部"
1633 "分にアドバイスを適用する (しかしシステムコールに対してはちゃんと B<ENOMEM> を"
1634 "返す)。"
1635
1636 #. type: Plain text
1637 #: build/C/man2/madvise.2:360
1638 msgid ""
1639 "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
1640 "B<munmap>(2)"
1641 msgstr ""
1642 "B<getrlimit>(2), B<mincore>(2), B<mmap>(2), B<mprotect>(2), B<msync>(2), "
1643 "B<munmap>(2)"
1644
1645 #. type: TH
1646 #: build/C/man3/malloc_hook.3:6
1647 #, no-wrap
1648 msgid "MALLOC_HOOK"
1649 msgstr "MALLOC_HOOK"
1650
1651 #. type: TH
1652 #: build/C/man3/malloc_hook.3:6
1653 #, fuzzy, no-wrap
1654 #| msgid "2010-10-30"
1655 msgid "2010-10-13"
1656 msgstr "2010-10-30"
1657
1658 #. type: Plain text
1659 #: build/C/man3/malloc_hook.3:11
1660 msgid ""
1661 "__malloc_hook, __malloc_initialize_hook, __memalign_hook, __free_hook, "
1662 "__realloc_hook, __after_morecore_hook - malloc debugging variables"
1663 msgstr ""
1664 "__malloc_hook, __malloc_initialize_hook, __memalign_hook, __free_hook, "
1665 "__realloc_hook, __after_morecore_hook - malloc デバッグ用の変数"
1666
1667 #. type: Plain text
1668 #: build/C/man3/malloc_hook.3:14 build/C/man3/posix_memalign.3:36
1669 #, no-wrap
1670 msgid "B<#include E<lt>malloc.hE<gt>>\n"
1671 msgstr "B<#include E<lt>malloc.hE<gt>>\n"
1672
1673 #. type: Plain text
1674 #: build/C/man3/malloc_hook.3:16
1675 #, no-wrap
1676 msgid "B<void *(*__malloc_hook)(size_t >I<size>B<, const void *>I<caller>B<);>\n"
1677 msgstr "B<void *(*__malloc_hook)(size_t >I<size>B<, const void *>I<caller>B<);>\n"
1678
1679 #. type: Plain text
1680 #: build/C/man3/malloc_hook.3:19
1681 #, no-wrap
1682 msgid "B<void *(*__realloc_hook)(void *>I<ptr>B<, size_t >I<size>B<, const void *>I<caller>B<);>\n"
1683 msgstr "B<void *(*__realloc_hook)(void *>I<ptr>B<, size_t >I<size>B<, const void *>I<caller>B<);>\n"
1684
1685 #. type: Plain text
1686 #: build/C/man3/malloc_hook.3:22
1687 #, no-wrap
1688 msgid ""
1689 "B<void *(*__memalign_hook)(size_t >I<alignment>B<, size_t >I<size>B<,>\n"
1690 "B<                         const void *>I<caller>B<);>\n"
1691 msgstr ""
1692 "B<void *(*__memalign_hook)(size_t >I<alignment>B<, size_t >I<size>B<,>\n"
1693 "B<                         const void *>I<caller>B<);>\n"
1694
1695 #. type: Plain text
1696 #: build/C/man3/malloc_hook.3:24
1697 #, no-wrap
1698 msgid "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
1699 msgstr "B<void (*__free_hook)(void *>I<ptr>B<, const void *>I<caller>B<);>\n"
1700
1701 #. type: Plain text
1702 #: build/C/man3/malloc_hook.3:26
1703 #, no-wrap
1704 msgid "B<void (*__malloc_initialize_hook)(void);>\n"
1705 msgstr "B<void (*__malloc_initialize_hook)(void);>\n"
1706
1707 #. type: Plain text
1708 #: build/C/man3/malloc_hook.3:28
1709 #, no-wrap
1710 msgid "B<void (*__after_morecore_hook)(void);>\n"
1711 msgstr "B<void (*__after_morecore_hook)(void);>\n"
1712
1713 #. type: Plain text
1714 #: build/C/man3/malloc_hook.3:39
1715 msgid ""
1716 "The GNU C library lets you modify the behavior of B<malloc>(3), B<realloc>"
1717 "(3), and B<free>(3)  by specifying appropriate hook functions.  You can use "
1718 "these hooks to help you debug programs that use dynamic memory allocation, "
1719 "for example."
1720 msgstr ""
1721 "GNU C ライブラリでは、適切なフック関数 (hook function) を指定することで "
1722 "B<malloc>(3), B<realloc>(3), B<free>(3)  の動作を変更することができる。例え"
1723 "ば、動的にメモリ割り当てを行う プログラムのデバッグにこれらのフックを使うこと"
1724 "ができる。"
1725
1726 #. type: Plain text
1727 #: build/C/man3/malloc_hook.3:46
1728 msgid ""
1729 "The variable B<__malloc_initialize_hook> points at a function that is called "
1730 "once when the malloc implementation is initialized.  This is a weak "
1731 "variable, so it can be overridden in the application with a definition like "
1732 "the following:"
1733 msgstr ""
1734 "変数 B<__malloc_initialize_hook> は malloc の実装が初期化される際に一度だけ呼"
1735 "ばれる関数へのポインタである。 この変数は書き換え可能 (weak) であり、アプリ"
1736 "ケーション内で 以下のような定義で上書きできる:"
1737
1738 #. type: Plain text
1739 #: build/C/man3/malloc_hook.3:49
1740 #, no-wrap
1741 msgid "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
1742 msgstr "    void (*__malloc_initialize_hook)(void) = my_init_hook;\n"
1743
1744 #. type: Plain text
1745 #: build/C/man3/malloc_hook.3:54
1746 msgid ""
1747 "Now the function I<my_init_hook>()  can do the initialization of all hooks."
1748 msgstr ""
1749 "なお、関数 I<my_init_hook>()  で全てのフックの初期化をすることができる。"
1750
1751 #. type: Plain text
1752 #: build/C/man3/malloc_hook.3:70
1753 msgid ""
1754 "The four functions pointed to by B<__malloc_hook>, B<__realloc_hook>, "
1755 "B<__memalign_hook>, B<__free_hook> have a prototype like the functions "
1756 "B<malloc>(3), B<realloc>(3), B<memalign>(3), B<free>(3), respectively, "
1757 "except that they have a final argument I<caller> that gives the address of "
1758 "the caller of B<malloc>(3), etc."
1759 msgstr ""
1760 "B<__malloc_hook>, B<__realloc_hook>, B<__memalign_hook>, B<__free_hook> で指"
1761 "される 4 つの関数は、各々 B<malloc>(3), B<realloc>(3), B<memalign>(3), "
1762 "B<free>(3)  とよく似たプロトタイプを持っているが、 一番最後の引き数 "
1763 "I<caller> をとる点が異なる。 引き数 I<caller> には、 B<malloc>(3)  などの呼び"
1764 "出し元 (caller) のアドレスが格納される。"
1765
1766 #. type: Plain text
1767 #: build/C/man3/malloc_hook.3:76
1768 msgid ""
1769 "The variable B<__after_morecore_hook> points at a function that is called "
1770 "each time after B<sbrk>(2)  was asked for more memory."
1771 msgstr ""
1772 "変数 B<__after_morecore_hook> は、領域の追加要求があり B<sbrk>(2)  が呼ばれた"
1773 "後で毎回呼び出される関数へのポインタである。"
1774
1775 #. type: Plain text
1776 #: build/C/man3/malloc_hook.3:78
1777 msgid "These functions are GNU extensions."
1778 msgstr "これらの関数は GNU による拡張である。"
1779
1780 #.  https://bugzilla.redhat.com/show_bug.cgi?id=450187
1781 #.  http://sourceware.org/bugzilla/show_bug.cgi?id=9957
1782 #. type: Plain text
1783 #: build/C/man3/malloc_hook.3:85
1784 msgid ""
1785 "The use of these hook functions is not safe in multithreaded programs, and "
1786 "they are now deprecated.  Programmers should instead preempt calls to the "
1787 "relevant functions by defining and exporting functions such as \"malloc\" "
1788 "and \"free\"."
1789 msgstr ""
1790
1791 #. type: SH
1792 #: build/C/man3/malloc_hook.3:85 build/C/man2/mmap.2:567
1793 #: build/C/man2/mprotect.2:142
1794 #, no-wrap
1795 msgid "EXAMPLE"
1796 msgstr "例"
1797
1798 #. type: Plain text
1799 #: build/C/man3/malloc_hook.3:87
1800 msgid "Here is a short example of how to use these variables."
1801 msgstr "これらの変数の使い方の簡単な例を以下に示す。"
1802
1803 #. type: Plain text
1804 #: build/C/man3/malloc_hook.3:91
1805 #, no-wrap
1806 msgid ""
1807 "#include E<lt>stdio.hE<gt>\n"
1808 "#include E<lt>malloc.hE<gt>\n"
1809 msgstr ""
1810 "#include E<lt>stdio.hE<gt>\n"
1811 "#include E<lt>malloc.hE<gt>\n"
1812
1813 #. type: Plain text
1814 #: build/C/man3/malloc_hook.3:95
1815 #, no-wrap
1816 msgid ""
1817 "/* Prototypes for our hooks.  */\n"
1818 "static void my_init_hook(void);\n"
1819 "static void *my_malloc_hook(size_t, const void *);\n"
1820 msgstr ""
1821 "/* 使おうとするフックのプロトタイプ宣言 */\n"
1822 "static void my_init_hook(void);\n"
1823 "static void *my_malloc_hook(size_t, const void *);\n"
1824
1825 #. type: Plain text
1826 #: build/C/man3/malloc_hook.3:98
1827 #, no-wrap
1828 msgid ""
1829 "/* Variables to save original hooks. */\n"
1830 "static void *(*old_malloc_hook)(size_t, const void *);\n"
1831 msgstr ""
1832 "/* 元々のフックを保存するための変数 */\n"
1833 "static void *(*old_malloc_hook)(size_t, const void *);\n"
1834
1835 #. type: Plain text
1836 #: build/C/man3/malloc_hook.3:101
1837 #, no-wrap
1838 msgid ""
1839 "/* Override initializing hook from the C library. */\n"
1840 "void (*__malloc_initialize_hook) (void) = my_init_hook;\n"
1841 msgstr ""
1842 "/* C ライブラリから呼ばれる初期化フックを上書きする */\n"
1843 "void (*__malloc_initialize_hook) (void) = my_init_hook;\n"
1844
1845 #. type: Plain text
1846 #: build/C/man3/malloc_hook.3:108
1847 #, no-wrap
1848 msgid ""
1849 "static void\n"
1850 "my_init_hook(void)\n"
1851 "{\n"
1852 "    old_malloc_hook = __malloc_hook;\n"
1853 "    __malloc_hook = my_malloc_hook;\n"
1854 "}\n"
1855 msgstr ""
1856 "static void\n"
1857 "my_init_hook(void)\n"
1858 "{\n"
1859 "    old_malloc_hook = __malloc_hook;\n"
1860 "    __malloc_hook = my_malloc_hook;\n"
1861 "}\n"
1862
1863 #. type: Plain text
1864 #: build/C/man3/malloc_hook.3:113
1865 #, no-wrap
1866 msgid ""
1867 "static void *\n"
1868 "my_malloc_hook(size_t size, const void *caller)\n"
1869 "{\n"
1870 "    void *result;\n"
1871 msgstr ""
1872 "static void *\n"
1873 "my_malloc_hook(size_t size, const void *caller)\n"
1874 "{\n"
1875 "    void *result;\n"
1876
1877 #. type: Plain text
1878 #: build/C/man3/malloc_hook.3:116
1879 #, no-wrap
1880 msgid ""
1881 "    /* Restore all old hooks */\n"
1882 "    __malloc_hook = old_malloc_hook;\n"
1883 msgstr ""
1884 "    /* 元々のフックを全て戻す */\n"
1885 "    __malloc_hook = old_malloc_hook;\n"
1886
1887 #. type: Plain text
1888 #: build/C/man3/malloc_hook.3:119
1889 #, no-wrap
1890 msgid ""
1891 "    /* Call recursively */\n"
1892 "    result = malloc(size);\n"
1893 msgstr ""
1894 "    /* malloc の再帰的呼び出し */\n"
1895 "    result = malloc(size);\n"
1896
1897 #. type: Plain text
1898 #: build/C/man3/malloc_hook.3:122
1899 #, no-wrap
1900 msgid ""
1901 "    /* Save underlying hooks */\n"
1902 "    old_malloc_hook = __malloc_hook;\n"
1903 msgstr ""
1904 "    /* 現在設定されているフック (underlying hook) を保存する */\n"
1905 "    old_malloc_hook = __malloc_hook;\n"
1906
1907 #. type: Plain text
1908 #: build/C/man3/malloc_hook.3:126
1909 #, no-wrap
1910 msgid ""
1911 "    /* printf() might call malloc(), so protect it too. */\n"
1912 "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
1913 "            (unsigned int) size, caller, result);\n"
1914 msgstr ""
1915 "    /* printf() は malloc() を呼び出す可能性があるので\n"
1916 "        ここでもガードを行う (元々のフックのままにしておく) */\n"
1917 "    printf(\"malloc(%u) called from %p returns %p\\en\",\n"
1918 "            (unsigned int) size, caller, result);\n"
1919
1920 #. type: Plain text
1921 #: build/C/man3/malloc_hook.3:129
1922 #, no-wrap
1923 msgid ""
1924 "    /* Restore our own hooks */\n"
1925 "    __malloc_hook = my_malloc_hook;\n"
1926 msgstr ""
1927 "    /* ユーザが使おうとするフックを再設定する */\n"
1928 "    __malloc_hook = my_malloc_hook;\n"
1929
1930 #. type: Plain text
1931 #: build/C/man3/malloc_hook.3:132
1932 #, no-wrap
1933 msgid ""
1934 "    return result;\n"
1935 "}\n"
1936 msgstr ""
1937 "    return result;\n"
1938 "}\n"
1939
1940 #. type: Plain text
1941 #: build/C/man3/malloc_hook.3:138
1942 msgid "B<mallinfo>(3), B<malloc>(3), B<mcheck>(3), B<mtrace>(3)"
1943 msgstr "B<mallinfo>(3), B<malloc>(3), B<mcheck>(3), B<mtrace>(3)"
1944
1945 #. type: TH
1946 #: build/C/man2/mlock.2:27
1947 #, no-wrap
1948 msgid "MLOCK"
1949 msgstr "MLOCK"
1950
1951 #. type: TH
1952 #: build/C/man2/mlock.2:27
1953 #, fuzzy, no-wrap
1954 #| msgid "2011-09-08"
1955 msgid "2011-09-14"
1956 msgstr "2011-09-08"
1957
1958 #. type: Plain text
1959 #: build/C/man2/mlock.2:30
1960 msgid "mlock, munlock, mlockall, munlockall - lock and unlock memory"
1961 msgstr "mlock - メモリのロックとロック解除を行う"
1962
1963 #. type: Plain text
1964 #: build/C/man2/mlock.2:33 build/C/man2/mmap.2:46 build/C/man2/mmap2.2:35
1965 #: build/C/man2/mprotect.2:38 build/C/man2/mremap.2:39
1966 #, no-wrap
1967 msgid "B<#include E<lt>sys/mman.hE<gt>>\n"
1968 msgstr "B<#include E<lt>sys/mman.hE<gt>>\n"
1969
1970 #. type: Plain text
1971 #: build/C/man2/mlock.2:36
1972 #, no-wrap
1973 msgid ""
1974 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
1975 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
1976 msgstr ""
1977 "B<int mlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
1978 "B<int munlock(const void *>I<addr>B<, size_t >I<len>B<);>\n"
1979
1980 #. type: Plain text
1981 #: build/C/man2/mlock.2:39
1982 #, no-wrap
1983 msgid ""
1984 "B<int mlockall(int >I<flags>B<);>\n"
1985 "B<int munlockall(void);>\n"
1986 msgstr ""
1987 "B<int mlockall(int >I<flags>B<);>\n"
1988 "B<int munlockall(void);>\n"
1989
1990 #. type: Plain text
1991 #: build/C/man2/mlock.2:55
1992 msgid ""
1993 "B<mlock>()  and B<mlockall>()  respectively lock part or all of the calling "
1994 "process's virtual address space into RAM, preventing that memory from being "
1995 "paged to the swap area.  B<munlock>()  and B<munlockall>()  perform the "
1996 "converse operation, respectively unlocking part or all of the calling "
1997 "process's virtual address space, so that pages in the specified virtual "
1998 "address range may once more to be swapped out if required by the kernel "
1999 "memory manager.  Memory locking and unlocking are performed in units of "
2000 "whole pages."
2001 msgstr ""
2002 "B<mlock>()  と B<mlockall>()  はそれぞれ、呼び出し元プロセスの仮想アドレス空"
2003 "間の一部または全部を RAM 上にロックし、メモリがスワップエリアにページングされ"
2004 "るのを防ぐ。 B<munlock>()  と B<munlockall>()  は逆の操作で、それぞれ呼び出し"
2005 "元プロセスの仮想アドレス空間の一部または全部を ロック解除する。つまり、指定さ"
2006 "れた仮想アドレス範囲のページは カーネルメモリマネージャーから要求されればス"
2007 "ワップアウトするようになる。 メモリのロックとロック解除はページ単位で行われ"
2008 "る。"
2009
2010 #. type: SS
2011 #: build/C/man2/mlock.2:55
2012 #, no-wrap
2013 msgid "mlock() and munlock()"
2014 msgstr "mlock() と munlock()"
2015
2016 #. type: Plain text
2017 #: build/C/man2/mlock.2:65
2018 msgid ""
2019 "B<mlock>()  locks pages in the address range starting at I<addr> and "
2020 "continuing for I<len> bytes.  All pages that contain a part of the specified "
2021 "address range are guaranteed to be resident in RAM when the call returns "
2022 "successfully; the pages are guaranteed to stay in RAM until later unlocked."
2023 msgstr ""
2024 "B<mlock>()  は I<addr> から始まる長さ I<len> バイトのアドレス範囲のページを"
2025 "ロックする。 呼び出しが成功した場合には、 指定されたアドレス範囲を含む全ての"
2026 "ページは RAM に残り続けることが保証される。 これらのページは後でロック解除さ"
2027 "れるまで RAM に残り続けることが保証される。"
2028
2029 #. type: Plain text
2030 #: build/C/man2/mlock.2:74
2031 msgid ""
2032 "B<munlock>()  unlocks pages in the address range starting at I<addr> and "
2033 "continuing for I<len> bytes.  After this call, all pages that contain a part "
2034 "of the specified memory range can be moved to external swap space again by "
2035 "the kernel."
2036 msgstr ""
2037 "B<munlock>()  は、 I<addr> から始まる長さ I<len> バイトのアドレス範囲のページ"
2038 "のロックを解除する。 この呼び出しを行った後は、カーネルが、指定されたメモリ範"
2039 "囲を含む 全てのページを外部のスワップ空間に移動できるようになる。"
2040
2041 #. type: SS
2042 #: build/C/man2/mlock.2:74
2043 #, no-wrap
2044 msgid "mlockall() and munlockall()"
2045 msgstr "mlockall() と munlockall()"
2046
2047 #. type: Plain text
2048 #: build/C/man2/mlock.2:84
2049 msgid ""
2050 "B<mlockall>()  locks all pages mapped into the address space of the calling "
2051 "process.  This includes the pages of the code, data and stack segment, as "
2052 "well as shared libraries, user space kernel data, shared memory, and memory-"
2053 "mapped files.  All mapped pages are guaranteed to be resident in RAM when "
2054 "the call returns successfully; the pages are guaranteed to stay in RAM until "
2055 "later unlocked."
2056 msgstr ""
2057 "B<mlockall>()  は呼び出し元プロセスのアドレス空間にマップされている全てのペー"
2058 "ジを ロックする。これにはコード、データ、スタックの 各セグメント、共有ライブ"
2059 "ラリ、カーネルのユーザー空間データ、 共有メモリ、メモリ・マップされたファイル"
2060 "が含まれる。 システム・コールが成功した場合には全てのマップされたページは "
2061 "RAM に 残ることを保証される。 これらのページは後でロック解除されるまで RAM に"
2062 "残り続けることが保証される。"
2063
2064 #. type: Plain text
2065 #: build/C/man2/mlock.2:89
2066 msgid ""
2067 "The I<flags> argument is constructed as the bitwise OR of one or more of the "
2068 "following constants:"
2069 msgstr "I<flags> 引数は以下の内容の一つまたは複数のビット OR から構成される:"
2070
2071 #. type: TP
2072 #: build/C/man2/mlock.2:89
2073 #, no-wrap
2074 msgid "B<MCL_CURRENT>"
2075 msgstr "B<MCL_CURRENT>"
2076
2077 #. type: Plain text
2078 #: build/C/man2/mlock.2:93
2079 msgid ""
2080 "Lock all pages which are currently mapped into the address space of the "
2081 "process."
2082 msgstr ""
2083 "現在、プロセスのアドレス空間にマップされている全てのページをロックする。"
2084
2085 #. type: TP
2086 #: build/C/man2/mlock.2:93
2087 #, no-wrap
2088 msgid "B<MCL_FUTURE>"
2089 msgstr "B<MCL_FUTURE>"
2090
2091 #. type: Plain text
2092 #: build/C/man2/mlock.2:100
2093 msgid ""
2094 "Lock all pages which will become mapped into the address space of the "
2095 "process in the future.  These could be for instance new pages required by a "
2096 "growing heap and stack as well as new memory mapped files or shared memory "
2097 "regions."
2098 msgstr ""
2099 "将来、プロセスのアドレス空間にマップされる全てのページをロックする。 例えば、"
2100 "ヒープ (heap) やスタックの成長により新しく必要になったページだけで なく、新し"
2101 "くメモリマップされたファイルや共有メモリ領域もロックされる。"
2102
2103 #. type: Plain text
2104 #: build/C/man2/mlock.2:113
2105 msgid ""
2106 "If B<MCL_FUTURE> has been specified, then a later system call (e.g., B<mmap>"
2107 "(2), B<sbrk>(2), B<malloc>(3)), may fail if it would cause the number of "
2108 "locked bytes to exceed the permitted maximum (see below).  In the same "
2109 "circumstances, stack growth may likewise fail: the kernel will deny stack "
2110 "expansion and deliver a B<SIGSEGV> signal to the process."
2111 msgstr ""
2112 "B<MCL_FUTURE> が指定されていると、以後のシステムコール (例えば、 B<mmap>(2), "
2113 "B<sbrk>(2), B<malloc>(3))  は、ロックするバイト数が許可された最大値 (下記参"
2114 "照) を超えた場合に 失敗する可能性がある。 同様に、スタックの成長も失敗する可"
2115 "能性がある。 その場合、カーネルはスタックの拡張を拒否し、 B<SIGSEGV> をプロセ"
2116 "スに送る。"
2117
2118 #. type: Plain text
2119 #: build/C/man2/mlock.2:117
2120 msgid ""
2121 "B<munlockall>()  unlocks all pages mapped into the address space of the "
2122 "calling process."
2123 msgstr ""
2124 "B<munlockall>()  は、呼び出し元プロセスのアドレス空間にマッピングされている "
2125 "全てのページをロック解除する。"
2126
2127 #. type: Plain text
2128 #: build/C/man2/mlock.2:123
2129 msgid ""
2130 "On success these system calls return 0.  On error, -1 is returned, I<errno> "
2131 "is set appropriately, and no changes are made to any locks in the address "
2132 "space of the process."
2133 msgstr ""
2134 "成功した場合は、これらのシステムコールはゼロを返す。 エラーの場合は -1 が返さ"
2135 "れ、 I<errno> が適切に設定され、プロセスのアドレス空間におけるロックは変更さ"
2136 "れない。"
2137
2138 #. type: Plain text
2139 #: build/C/man2/mlock.2:132
2140 msgid ""
2141 "(Linux 2.6.9 and later) the caller had a nonzero B<RLIMIT_MEMLOCK> soft "
2142 "resource limit, but tried to lock more memory than the limit permitted.  "
2143 "This limit is not enforced if the process is privileged (B<CAP_IPC_LOCK>)."
2144 msgstr ""
2145 "(Linux 2.6.9 以降) 呼び出し元は非ゼロの ソフト資源制限 B<RLIMIT_MEMLOCK> を持"
2146 "つが、制限が許可している以上のメモリをロックしようとした。 この制限は、プロセ"
2147 "スが特権 (B<CAP_IPC_LOCK>)  を持っている場合は適用されない。"
2148
2149 #.  In the case of mlock(), this check is somewhat buggy: it doesn't
2150 #.  take into account whether the to-be-locked range overlaps with
2151 #.  already locked pages.  Thus, suppose we allocate
2152 #.  (num_physpages / 4 + 1) of memory, and lock those pages once using
2153 #.  mlock(), and then lock the *same* page range a second time.
2154 #.  In the case, the second mlock() call will fail, since the check
2155 #.  calculates that the process is trying to lock (num_physpages / 2 + 2)
2156 #.  pages, which of course is not true.  (MTK, Nov 04, kernel 2.4.28)
2157 #. type: Plain text
2158 #: build/C/man2/mlock.2:144
2159 msgid ""
2160 "(Linux 2.4 and earlier) the calling process tried to lock more than half of "
2161 "RAM."
2162 msgstr ""
2163 "(Linux 2.4 以前) 呼び出し元プロセスが RAM の半分以上をロックしようとした。"
2164
2165 #. SVr4 documents an additional EAGAIN error code.
2166 #. type: Plain text
2167 #: build/C/man2/mlock.2:150
2168 msgid ""
2169 "The caller is not privileged, but needs privilege (B<CAP_IPC_LOCK>)  to "
2170 "perform the requested operation."
2171 msgstr ""
2172
2173 #. type: Plain text
2174 #: build/C/man2/mlock.2:155
2175 msgid "For B<mlock>()  and B<munlock>():"
2176 msgstr "B<mlock>()  と B<munlock>()  用として:"
2177
2178 #. type: Plain text
2179 #: build/C/man2/mlock.2:158
2180 msgid "Some or all of the specified address range could not be locked."
2181 msgstr "指定されたアドレス範囲の一部または全てをロックすることができなかった。"
2182
2183 #. type: Plain text
2184 #: build/C/man2/mlock.2:165
2185 msgid ""
2186 "The result of the addition I<start>+I<len> was less than I<start> (e.g., the "
2187 "addition may have resulted in an overflow)."
2188 msgstr ""
2189
2190 #. type: Plain text
2191 #: build/C/man2/mlock.2:170
2192 msgid "(Not on Linux)  I<addr> was not a multiple of the page size."
2193 msgstr ""
2194 "(Linux ではこの意味で使われない)  I<addr> がページサイズの倍数ではない。"
2195
2196 #. type: Plain text
2197 #: build/C/man2/mlock.2:174
2198 msgid ""
2199 "Some of the specified address range does not correspond to mapped pages in "
2200 "the address space of the process."
2201 msgstr ""
2202 "指定されたアドレス範囲がプロセスのアドレス空間にマップされたページと 一致しな"
2203 "い。"
2204
2205 #. type: Plain text
2206 #: build/C/man2/mlock.2:177
2207 msgid "For B<mlockall>():"
2208 msgstr "B<mlockall>()  用として:"
2209
2210 #. type: Plain text
2211 #: build/C/man2/mlock.2:180
2212 msgid "Unknown I<flags> were specified."
2213 msgstr "未知の I<flags> が指定された。"
2214
2215 #. type: Plain text
2216 #: build/C/man2/mlock.2:183
2217 msgid "For B<munlockall>():"
2218 msgstr "B<munlockall>()  用として:"
2219
2220 #. type: Plain text
2221 #: build/C/man2/mlock.2:187
2222 msgid ""
2223 "(Linux 2.6.8 and earlier) The caller was not privileged (B<CAP_IPC_LOCK>)."
2224 msgstr ""
2225 "(Linux 2.6.8 以前) 呼び出し元が権限 (B<CAP_IPC_LOCK>)  を持っていない。"
2226
2227 #. type: Plain text
2228 #: build/C/man2/mlock.2:189
2229 msgid "POSIX.1-2001, SVr4."
2230 msgstr "POSIX.1-2001, SVr4."
2231
2232 #. type: SH
2233 #: build/C/man2/mlock.2:189 build/C/man2/mmap.2:487 build/C/man2/msync.2:105
2234 #, no-wrap
2235 msgid "AVAILABILITY"
2236 msgstr "可用性"
2237
2238 #. type: Plain text
2239 #: build/C/man2/mlock.2:201
2240 msgid ""
2241 "On POSIX systems on which B<mlock>()  and B<munlock>()  are available, "
2242 "B<_POSIX_MEMLOCK_RANGE> is defined in I<E<lt>unistd.hE<gt>> and the number "
2243 "of bytes in a page can be determined from the constant B<PAGESIZE> (if "
2244 "defined) in I<E<lt>limits.hE<gt>> or by calling I<sysconf(_SC_PAGESIZE)>."
2245 msgstr ""
2246 "B<mlock>()  と B<munlock>()  が使用可能な POSIX システムでは "
2247 "B<_POSIX_MEMLOCK_RANGE> が I<E<lt>unistd.hE<gt>> で定義されている。 また、"
2248 "ページあたりのバイト数は、 I<E<lt>limits.hE<gt>> で定義される定数 "
2249 "B<PAGESIZE> から (定義されている場合)、もしくは I<sysconf(_SC_PAGESIZE)> を呼"
2250 "び出すことで決定できる。"
2251
2252 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
2253 #.  -1: unavailable, 0: ask using sysconf().
2254 #.  glibc defines it to 1.
2255 #. type: Plain text
2256 #: build/C/man2/mlock.2:214
2257 msgid ""
2258 "On POSIX systems on which B<mlockall>()  and B<munlockall>()  are available, "
2259 "B<_POSIX_MEMLOCK> is defined in I<E<lt>unistd.hE<gt>> to a value greater "
2260 "than 0.  (See also B<sysconf>(3).)"
2261 msgstr ""
2262 "B<mlockall>()  と B<munlockall>()  が利用可能な POSIX システムでは、 "
2263 "B<_POSIX_MEMLOCK> は I<E<lt>unistd.hE<gt>> で 0 より大きい値に定義されている "
2264 "(B<sysconf>(3)  も参照のこと)。"
2265
2266 #. type: Plain text
2267 #: build/C/man2/mlock.2:232
2268 msgid ""
2269 "Memory locking has two main applications: real-time algorithms and high-"
2270 "security data processing.  Real-time applications require deterministic "
2271 "timing, and, like scheduling, paging is one major cause of unexpected "
2272 "program execution delays.  Real-time applications will usually also switch "
2273 "to a real-time scheduler with B<sched_setscheduler>(2).  Cryptographic "
2274 "security software often handles critical bytes like passwords or secret keys "
2275 "as data structures.  As a result of paging, these secrets could be "
2276 "transferred onto a persistent swap store medium, where they might be "
2277 "accessible to the enemy long after the security software has erased the "
2278 "secrets in RAM and terminated.  (But be aware that the suspend mode on "
2279 "laptops and some desktop computers will save a copy of the system's RAM to "
2280 "disk, regardless of memory locks.)"
2281 msgstr ""
2282 "メモリのロックの用途としては主に二つある: リアルタイム アルゴリズムと高いセ"
2283 "キュリティの必要なデータ処理である。リアルタイムの アプリケーションは決定的な"
2284 "タイミングやスケジューリングを必要とするが、 ページングは予期しないプログラム"
2285 "の実行遅延をもたらす主要な要因となる。 リアルタイムのアプリケーションはたいて"
2286 "いは B<sched_setscheduler>(2)  でリアルタイムスケジューラに変更される。 暗号"
2287 "やセキュリティのソフトウェアはしばしばパスワードや秘密鍵のデータの ような重要"
2288 "なバイト列を扱う。ページングの結果、これらの秘密が スワップ用の固定媒体に転送"
2289 "されるかもしれない。そして、セキュリティ・ ソフトウェアが RAM 上の秘密を削除"
2290 "して終了したずっと後になっても、 このスワップされたデータには敵がアクセスでき"
2291 "る可能性がある (しかし、ラップトップといくつかのデスクトップコンピュータの サ"
2292 "スペンドモードはシステムの RAM の内容をメモリのロックに関わらず ディスクに保"
2293 "存することに注意)。"
2294
2295 #. type: Plain text
2296 #: build/C/man2/mlock.2:245
2297 msgid ""
2298 "Real-time processes that are using B<mlockall>()  to prevent delays on page "
2299 "faults should reserve enough locked stack pages before entering the time-"
2300 "critical section, so that no page fault can be caused by function calls.  "
2301 "This can be achieved by calling a function that allocates a sufficiently "
2302 "large automatic variable (an array) and writes to the memory occupied by "
2303 "this array in order to touch these stack pages.  This way, enough pages will "
2304 "be mapped for the stack and can be locked into RAM.  The dummy writes ensure "
2305 "that not even copy-on-write page faults can occur in the critical section."
2306 msgstr ""
2307 "リアルタイムプロセスが B<mlockall>()  を使ってページフォールトによる遅延を防"
2308 "ごうとする場合、 関数呼び出しによってページフォールトが発生しないように、 時"
2309 "間制限の厳しい部分 (time-critical section) に入る前に 十分な量のロックされた"
2310 "スタックを確保しておく必要がある。 これを実現するには、十分な大きさの自動変"
2311 "数 (の配列) を確保し、 これらのスタック用のページがメモリ上に確保されるように"
2312 "この配列に 書き込みを行う関数を用意し、これを呼び出せばよい。こうすること"
2313 "で、 十分な量のページがスタックにマッピングされ、RAM にロックされる。 ダミー"
2314 "の書き込みを行うことによって、 時間制限の厳しい部分 (critical section) 内では"
2315 "書き込み時コピーによる ページフォールトさえも発生しないことが保証される。"
2316
2317 #. type: Plain text
2318 #: build/C/man2/mlock.2:251
2319 msgid ""
2320 "Memory locks are not inherited by a child created via B<fork>(2)  and are "
2321 "automatically removed (unlocked) during an B<execve>(2)  or when the process "
2322 "terminates."
2323 msgstr ""
2324 "メモリロックは B<fork>(2)  で作成された子プロセスには継承されず、 B<execve>"
2325 "(2)  が呼ばれたり、プロセスが終了した場合は 自動的に削除される (ロック解除さ"
2326 "れる)。"
2327
2328 #. type: Plain text
2329 #: build/C/man2/mlock.2:255
2330 msgid ""
2331 "The memory lock on an address range is automatically removed if the address "
2332 "range is unmapped via B<munmap>(2)."
2333 msgstr ""
2334 "あるアドレス範囲に対するメモリロックは、そのアドレス範囲が B<munmap>(2)  に"
2335 "よってアンマップされた場合は削除される。"
2336
2337 #. type: Plain text
2338 #: build/C/man2/mlock.2:268
2339 msgid ""
2340 "Memory locks do not stack, that is, pages which have been locked several "
2341 "times by calls to B<mlock>()  or B<mlockall>()  will be unlocked by a single "
2342 "call to B<munlock>()  for the corresponding range or by B<munlockall>().  "
2343 "Pages which are mapped to several locations or by several processes stay "
2344 "locked into RAM as long as they are locked at least at one location or by at "
2345 "least one process."
2346 msgstr ""
2347 "メモリのロックは累積しない。 すなわち複数回 B<mlock>()  や B<mlockall>()  を"
2348 "呼び出してロックされたページでも、 対応する範囲に対して B<munlock>()  を 1 回"
2349 "呼び出したり B<munlockall>()  を呼び出したりするだけでロック解除される。 複数"
2350 "の場所や複数のプロセスにマップされているページは、少なくとも一つの場所、 一つ"
2351 "のプロセスでロックされている限りは RAM に残り続ける。"
2352
2353 #. type: Plain text
2354 #: build/C/man2/mlock.2:279
2355 msgid ""
2356 "Under Linux, B<mlock>()  and B<munlock>()  automatically round I<addr> down "
2357 "to the nearest page boundary.  However, POSIX.1-2001 allows an "
2358 "implementation to require that I<addr> is page aligned, so portable "
2359 "applications should ensure this."
2360 msgstr ""
2361 "Linux では、 B<mlock>()  と B<munlock>()  は自動的に I<addr> を端数切り捨てに"
2362 "より一番近いページ境界へと丸める。 しかし POSIX.1-2001 は I<addr> がページ境"
2363 "界に合っていることを要求する実装も許している。 そのため移植性を意図したアプリ"
2364 "ケーションではきちんと境界に合わせた方が良い。"
2365
2366 #. type: Plain text
2367 #: build/C/man2/mlock.2:292
2368 msgid ""
2369 "The I<VmLck> field of the Linux-specific I</proc/PID/status> file shows how "
2370 "many kilobytes of memory the process with ID I<PID> has locked using B<mlock>"
2371 "(), B<mlockall>(), and B<mmap>(2)  B<MAP_LOCKED>."
2372 msgstr ""
2373
2374 #. type: SS
2375 #: build/C/man2/mlock.2:292
2376 #, no-wrap
2377 msgid "Limits and permissions"
2378 msgstr "制限と権限"
2379
2380 #. type: Plain text
2381 #: build/C/man2/mlock.2:299
2382 msgid ""
2383 "In Linux 2.6.8 and earlier, a process must be privileged (B<CAP_IPC_LOCK>)  "
2384 "in order to lock memory and the B<RLIMIT_MEMLOCK> soft resource limit "
2385 "defines a limit on how much memory the process may lock."
2386 msgstr ""
2387 "Linux 2.6.8 以前では、メモリをロックするためには特権 (B<CAP_IPC_LOCK>)  が必"
2388 "要で、 ソフト資源制限 B<RLIMIT_MEMLOCK> はプロセスがどれだけのメモリをロック"
2389 "できるかの制限を定義する。"
2390
2391 #. type: Plain text
2392 #: build/C/man2/mlock.2:305
2393 msgid ""
2394 "Since Linux 2.6.9, no limits are placed on the amount of memory that a "
2395 "privileged process can lock and the B<RLIMIT_MEMLOCK> soft resource limit "
2396 "instead defines a limit on how much memory an unprivileged process may lock."
2397 msgstr ""
2398 "Linux 2.6.9 以降では、特権を持つプロセスがロックできるメモリ量は無制限とな"
2399 "り、 代わりにソフト資源制限 B<RLIMIT_MEMLOCK> は特権を持たないプロセスがロッ"
2400 "クできるメモリ量の制限を定義する。"
2401
2402 #. type: Plain text
2403 #: build/C/man2/mlock.2:313
2404 msgid ""
2405 "In the 2.4 series Linux kernels up to and including 2.4.17, a bug caused the "
2406 "B<mlockall>()  B<MCL_FUTURE> flag to be inherited across a B<fork>(2).  This "
2407 "was rectified in kernel 2.4.18."
2408 msgstr ""
2409 "2.4.17 までの 2.4 シリーズの Linux カーネルには、 B<mlockall>()  "
2410 "B<MCL_FUTURE> フラグが B<fork>(2)  で継承されると言うバグがある。 これはカー"
2411 "ネル 2.4.18 で修正された。"
2412
2413 #.  See the following LKML thread:
2414 #.  http://marc.theaimsgroup.com/?l=linux-kernel&m=113801392825023&w=2
2415 #.  "Rationale for RLIMIT_MEMLOCK"
2416 #.  23 Jan 2006
2417 #. type: Plain text
2418 #: build/C/man2/mlock.2:330
2419 msgid ""
2420 "Since kernel 2.6.9, if a privileged process calls I<mlockall(MCL_FUTURE)> "
2421 "and later drops privileges (loses the B<CAP_IPC_LOCK> capability by, for "
2422 "example, setting its effective UID to a nonzero value), then subsequent "
2423 "memory allocations (e.g., B<mmap>(2), B<brk>(2))  will fail if the "
2424 "B<RLIMIT_MEMLOCK> resource limit is encountered."
2425 msgstr ""
2426 "カーネル 2.6.9 以降では、特権を持ったプロセスが I<mlockall(MCL_FUTURE)> を呼"
2427 "び出した後で、特権をなくした場合 (例えば、 実効 UID を 0 以外の値に変更するな"
2428 "どにより、 B<CAP_IPC_LOCK> ケーパビリティを失った場合)、リソース上限 "
2429 "B<RLIMIT_MEMLOCK> に達すると、それ以降のメモリ割り当て (例えば B<mmap>(2), "
2430 "B<brk>(2))  は失敗する。"
2431
2432 #. type: Plain text
2433 #: build/C/man2/mlock.2:337
2434 #, fuzzy
2435 #| msgid ""
2436 #| "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<capabilities>"
2437 #| "(7)"
2438 msgid ""
2439 "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<proc>(5), "
2440 "B<capabilities>(7)"
2441 msgstr ""
2442 "B<mmap>(2), B<setrlimit>(2), B<shmctl>(2), B<sysconf>(3), B<capabilities>(7)"
2443
2444 #. type: TH
2445 #: build/C/man2/mmap.2:40
2446 #, no-wrap
2447 msgid "MMAP"
2448 msgstr "MMAP"
2449
2450 #. type: TH
2451 #: build/C/man2/mmap.2:40
2452 #, fuzzy, no-wrap
2453 #| msgid "2010-06-10"
2454 msgid "2010-06-20"
2455 msgstr "2010-06-10"
2456
2457 #. type: Plain text
2458 #: build/C/man2/mmap.2:43
2459 msgid "mmap, munmap - map or unmap files or devices into memory"
2460 msgstr "mmap, munmap - ファイルやデバイスをメモリにマップ/アンマップする"
2461
2462 #. type: Plain text
2463 #: build/C/man2/mmap.2:51
2464 #, no-wrap
2465 msgid ""
2466 "B<void *mmap(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<, int >I<flags>B<,>\n"
2467 "B<           int >I<fd>B<, off_t >I<offset>B<);>\n"
2468 "B<int munmap(void *>I<addr>B<, size_t >I<length>B<);>\n"
2469 msgstr ""
2470 "B<void *mmap(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<, int >I<flags>B<,>\n"
2471 "B<           int >I<fd>B<, off_t >I<offset>B<);>\n"
2472 "B<int munmap(void *>I<addr>B<, size_t >I<length>B<);>\n"
2473
2474 #. type: Plain text
2475 #: build/C/man2/mmap.2:61
2476 msgid ""
2477 "B<mmap>()  creates a new mapping in the virtual address space of the calling "
2478 "process.  The starting address for the new mapping is specified in I<addr>.  "
2479 "The I<length> argument specifies the length of the mapping."
2480 msgstr ""
2481 "B<mmap>()  は、新しいマッピングを呼び出し元プロセスの仮想アドレス空間に作成す"
2482 "る。 新しいマッピングの開始アドレスは I<addr> で指定される。マッピングの長さ"
2483 "は I<length> 引き数で指定される。"
2484
2485 #.  Before Linux 2.6.24, the address was rounded up to the next page
2486 #.  boundary; since 2.6.24, it is rounded down!
2487 #. type: Plain text
2488 #: build/C/man2/mmap.2:75
2489 msgid ""
2490 "If I<addr> is NULL, then the kernel chooses the address at which to create "
2491 "the mapping; this is the most portable method of creating a new mapping.  If "
2492 "I<addr> is not NULL, then the kernel takes it as a hint about where to place "
2493 "the mapping; on Linux, the mapping will be created at a nearby page "
2494 "boundary.  The address of the new mapping is returned as the result of the "
2495 "call."
2496 msgstr ""
2497 "I<addr> が NULL の場合、カーネルがマッピングを作成するアドレスを選択する。 こ"
2498 "の方法は最も移植性のある新しいマッピングの作成方法である。 I<addr> が NULL で"
2499 "ない場合、カーネルはマッピングをどこに配置するかのヒントとして I<addr> を使用"
2500 "する。Linux では、マッピングはすぐ近くのページ境界に作成される。 新しいマッピ"
2501 "ングのアドレスは、呼び出しの返り値として返される。"
2502
2503 #. type: Plain text
2504 #: build/C/man2/mmap.2:87
2505 msgid ""
2506 "The contents of a file mapping (as opposed to an anonymous mapping; see "
2507 "B<MAP_ANONYMOUS> below), are initialized using I<length> bytes starting at "
2508 "offset I<offset> in the file (or other object) referred to by the file "
2509 "descriptor I<fd>.  I<offset> must be a multiple of the page size as returned "
2510 "by I<sysconf(_SC_PAGE_SIZE)>."
2511 msgstr ""
2512 "ファイルマッピングの内容は、 ファイルディスクリプタ I<fd> で参照されるファイ"
2513 "ル (もしくは他のオブジェクト) のオフセット I<offset> から開始される "
2514 "I<length> バイトのデータで初期化される (ファイルマッピングは無名マッピングの"
2515 "反対語である。 B<MAP_ANONYMOUS> を参照)。 I<offset> は I<sysconf"
2516 "(_SC_PAGE_SIZE)> が返すページサイズの倍数でなければならない。"
2517
2518 #. type: Plain text
2519 #: build/C/man2/mmap.2:95
2520 msgid ""
2521 "The I<prot> argument describes the desired memory protection of the mapping "
2522 "(and must not conflict with the open mode of the file).  It is either "
2523 "B<PROT_NONE> or the bitwise OR of one or more of the following flags:"
2524 msgstr ""
2525 "引き数 I<prot> には、マッピングのメモリ保護をどのように行なうかを指定する "
2526 "(ファイルのオープンモードと矛盾してはいけない)。 I<prot> には、 B<PROT_NONE> "
2527 "か、以下のフラグをひとつ以上ビット毎の論理和 (OR) をとったものを 指定できる。"
2528
2529 #. type: TP
2530 #: build/C/man2/mmap.2:95 build/C/man2/mprotect.2:67
2531 #, no-wrap
2532 msgid "B<PROT_EXEC>"
2533 msgstr "B<PROT_EXEC>"
2534
2535 #. type: Plain text
2536 #: build/C/man2/mmap.2:98
2537 msgid "Pages may be executed."
2538 msgstr "ページは実行可能である。"
2539
2540 #. type: TP
2541 #: build/C/man2/mmap.2:98 build/C/man2/mprotect.2:61
2542 #, no-wrap
2543 msgid "B<PROT_READ>"
2544 msgstr "B<PROT_READ>"
2545
2546 #. type: Plain text
2547 #: build/C/man2/mmap.2:101
2548 msgid "Pages may be read."
2549 msgstr "ページは読み込み可能である。"
2550
2551 #. type: TP
2552 #: build/C/man2/mmap.2:101 build/C/man2/mprotect.2:64
2553 #, no-wrap
2554 msgid "B<PROT_WRITE>"
2555 msgstr "B<PROT_WRITE>"
2556
2557 #. type: Plain text
2558 #: build/C/man2/mmap.2:104
2559 msgid "Pages may be written."
2560 msgstr "ページに書き込み可能である。"
2561
2562 #. type: TP
2563 #: build/C/man2/mmap.2:104 build/C/man2/mprotect.2:58
2564 #, no-wrap
2565 msgid "B<PROT_NONE>"
2566 msgstr "B<PROT_NONE>"
2567
2568 #. type: Plain text
2569 #: build/C/man2/mmap.2:107
2570 msgid "Pages may not be accessed."
2571 msgstr "ページにはアクセスできない。"
2572
2573 #. type: Plain text
2574 #: build/C/man2/mmap.2:116
2575 msgid ""
2576 "The I<flags> argument determines whether updates to the mapping are visible "
2577 "to other processes mapping the same region, and whether updates are carried "
2578 "through to the underlying file.  This behavior is determined by including "
2579 "exactly one of the following values in I<flags>:"
2580 msgstr ""
2581 "I<flags> 引き数により、マッピングに対する更新が同じ領域をマッピングしている "
2582 "他のプロセスに見えるか、更新がマッピング元のファイルを通じて 伝えられるか、が"
2583 "決定される。この動作は、以下の値のいずれか一つだけ (複数は指定できない) を "
2584 "I<flags> に含めることで指定する。"
2585
2586 #. type: TP
2587 #: build/C/man2/mmap.2:116
2588 #, no-wrap
2589 msgid "B<MAP_SHARED>"
2590 msgstr "B<MAP_SHARED>"
2591
2592 #. type: Plain text
2593 #: build/C/man2/mmap.2:126
2594 msgid ""
2595 "Share this mapping.  Updates to the mapping are visible to other processes "
2596 "that map this file, and are carried through to the underlying file.  The "
2597 "file may not actually be updated until B<msync>(2)  or B<munmap>()  is "
2598 "called."
2599 msgstr ""
2600 "このマッピングを共有する。 マッピングに対する更新はこのファイルをマッピングし"
2601 "ている他のプロセス から見える。更新はマッピング元のファイルを通じて伝えられ"
2602 "る。 ただし、ファイルの実際の更新は B<msync>(2)  または B<munmap>()  が呼ばれ"
2603 "るまで行われないこともある。"
2604
2605 #. type: TP
2606 #: build/C/man2/mmap.2:126
2607 #, no-wrap
2608 msgid "B<MAP_PRIVATE>"
2609 msgstr "B<MAP_PRIVATE>"
2610
2611 #. type: Plain text
2612 #: build/C/man2/mmap.2:135
2613 msgid ""
2614 "Create a private copy-on-write mapping.  Updates to the mapping are not "
2615 "visible to other processes mapping the same file, and are not carried "
2616 "through to the underlying file.  It is unspecified whether changes made to "
2617 "the file after the B<mmap>()  call are visible in the mapped region."
2618 msgstr ""
2619 "プライベートな copy-on-write (書き込み時コピー) マップを生成する。 マッピング"
2620 "に対する更新は同じファイルをマッピングしている他のプロセス には見えず、更新が"
2621 "マッピング元のファイルを通じて伝えられることもない。 B<mmap>()  の呼び出し後"
2622 "にマッピング元のファイルに対して行われた変更が、 マップ領域に反映されるかどう"
2623 "かは規定されていない。"
2624
2625 #. type: Plain text
2626 #: build/C/man2/mmap.2:137
2627 msgid "Both of these flags are described in POSIX.1-2001."
2628 msgstr "上記の二つのフラグは POSIX.1-2001 で規定されている。"
2629
2630 #. type: Plain text
2631 #: build/C/man2/mmap.2:140
2632 msgid ""
2633 "In addition, zero or more of the following values can be ORed in I<flags>:"
2634 msgstr ""
2635 "さらに、以下の値のうち 0 個以上をビット毎の論理和 (OR) で I<flags> に指定する"
2636 "ことができる。"
2637
2638 #. type: TP
2639 #: build/C/man2/mmap.2:140
2640 #, no-wrap
2641 msgid "B<MAP_32BIT> (since Linux 2.4.20, 2.6)"
2642 msgstr "B<MAP_32BIT> (Linux 2.4.20, 2.6 以降)"
2643
2644 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
2645 #. type: Plain text
2646 #: build/C/man2/mmap.2:156
2647 msgid ""
2648 "Put the mapping into the first 2 Gigabytes of the process address space.  "
2649 "This flag is only supported on x86-64, for 64-bit programs.  It was added to "
2650 "allow thread stacks to be allocated somewhere in the first 2GB of memory, so "
2651 "as to improve context-switch performance on some early 64-bit processors.  "
2652 "Modern x86-64 processors no longer have this performance problem, so use of "
2653 "this flag is not required on those systems.  The B<MAP_32BIT> flag is "
2654 "ignored when B<MAP_FIXED> is set."
2655 msgstr ""
2656 "マッピングをプロセスのアドレス空間の先頭 2 ギガバイト以内に配置する。 このフ"
2657 "ラグがサポートされているのは x86-64 アーキテクチャ上の 64 ビットプログラムの"
2658 "みである。 このフラグが追加されたのは、スレッドのスタックをメモリの先頭 2GB "
2659 "以内の どこかに割り当てることで、初期のいくつかの 64 ビットプロセッサにおけ"
2660 "る コンテキストスイッチの性能問題を改善するためである。 最近の x86-64 プロ"
2661 "セッサではこの性能問題はもはや存在せず、 そのようなシステムではこのフラグを使"
2662 "用する必要はない。 B<MAP_FIXED> がセットされている場合は、 B<MAP_32BIT> フラ"
2663 "グは無視される。"
2664
2665 #. type: TP
2666 #: build/C/man2/mmap.2:156
2667 #, no-wrap
2668 msgid "B<MAP_ANON>"
2669 msgstr "B<MAP_ANON>"
2670
2671 #. type: Plain text
2672 #: build/C/man2/mmap.2:161
2673 msgid "Synonym for B<MAP_ANONYMOUS>.  Deprecated."
2674 msgstr "B<MAP_ANONYMOUS> の同義語。非推奨。"
2675
2676 #. type: TP
2677 #: build/C/man2/mmap.2:161
2678 #, no-wrap
2679 msgid "B<MAP_ANONYMOUS>"
2680 msgstr "B<MAP_ANONYMOUS>"
2681
2682 #. type: Plain text
2683 #: build/C/man2/mmap.2:183
2684 msgid ""
2685 "The mapping is not backed by any file; its contents are initialized to "
2686 "zero.  The I<fd> and I<offset> arguments are ignored; however, some "
2687 "implementations require I<fd> to be -1 if B<MAP_ANONYMOUS> (or B<MAP_ANON>)  "
2688 "is specified, and portable applications should ensure this.  The use of "
2689 "B<MAP_ANONYMOUS> in conjunction with B<MAP_SHARED> is only supported on "
2690 "Linux since kernel 2.4."
2691 msgstr ""
2692 "マッピングはどのファイルとも関連付けされない。 マッピングの内容は 0 で初期化"
2693 "される。 引き数 I<fd> と I<offset> は無視される。 ただし、実装によっては "
2694 "B<MAP_ANONYMOUS> (もしくは B<MAP_ANON>)  が指定された場合、 I<fd> を -1 にす"
2695 "る必要があり、 移植性が必要なアプリケーションでは必ず I<fd> を -1 にすべきで"
2696 "ある。 B<MAP_ANONYMOUS> と B<MAP_SHARED> を組み合わせての利用は カーネル 2.4 "
2697 "以降の Linux でのみサポートされている。"
2698
2699 #. type: TP
2700 #: build/C/man2/mmap.2:183
2701 #, no-wrap
2702 msgid "B<MAP_DENYWRITE>"
2703 msgstr "B<MAP_DENYWRITE>"
2704
2705 #.  Introduced in 1.1.36, removed in 1.3.24.
2706 #. type: Plain text
2707 #: build/C/man2/mmap.2:191
2708 msgid ""
2709 "This flag is ignored.  (Long ago, it signaled that attempts to write to the "
2710 "underlying file should fail with B<ETXTBUSY>.  But this was a source of "
2711 "denial-of-service attacks.)"
2712 msgstr ""
2713 "このフラグは無視される (ずっと前は、マップ元のファイルへの書き込みを行おうと"
2714 "すると、エラー B<ETXTBUSY> で失敗するようにシグナルが設定されていたが、これ"
2715 "は denial-of-service (サービス拒否) 攻撃の原因となった)。"
2716
2717 #. type: TP
2718 #: build/C/man2/mmap.2:191
2719 #, no-wrap
2720 msgid "B<MAP_EXECUTABLE>"
2721 msgstr "B<MAP_EXECUTABLE>"
2722
2723 #.  Introduced in 1.1.38, removed in 1.3.24. Flag tested in proc_follow_link.
2724 #.  (Long ago, it signaled that the underlying file is an executable.
2725 #.  However, that information was not really used anywhere.)
2726 #.  Linus talked about DOS related to MAP_EXECUTABLE, but he was thinking of
2727 #.  MAP_DENYWRITE?
2728 #. type: Plain text
2729 #: build/C/man2/mmap.2:199
2730 msgid "This flag is ignored."
2731 msgstr "このフラグは無視される。"
2732
2733 #. type: TP
2734 #: build/C/man2/mmap.2:199
2735 #, no-wrap
2736 msgid "B<MAP_FILE>"
2737 msgstr "B<MAP_FILE>"
2738
2739 #.  On some systems, this was required as the opposite of
2740 #.  MAP_ANONYMOUS -- mtk, 1 May 2007
2741 #. type: Plain text
2742 #: build/C/man2/mmap.2:205
2743 msgid "Compatibility flag.  Ignored."
2744 msgstr "互換性のためのフラグ。無視される。"
2745
2746 #. type: TP
2747 #: build/C/man2/mmap.2:205
2748 #, no-wrap
2749 msgid "B<MAP_FIXED>"
2750 msgstr "B<MAP_FIXED>"
2751
2752 #. type: Plain text
2753 #: build/C/man2/mmap.2:223
2754 msgid ""
2755 "Don't interpret I<addr> as a hint: place the mapping at exactly that "
2756 "address.  I<addr> must be a multiple of the page size.  If the memory region "
2757 "specified by I<addr> and I<len> overlaps pages of any existing mapping(s), "
2758 "then the overlapped part of the existing mapping(s) will be discarded.  If "
2759 "the specified address cannot be used, B<mmap>()  will fail.  Because "
2760 "requiring a fixed address for a mapping is less portable, the use of this "
2761 "option is discouraged."
2762 msgstr ""
2763 "I<addr> をアドレスのヒントとして使用するのではなく、 I<addr> で指定されたアド"
2764 "レスをそのまま使用してマッピングを配置する。 I<addr> はページサイズの倍数でな"
2765 "ければならない。 I<addr> と I<len> で指定されたメモリ領域が既存のマッピングの"
2766 "ページと重なる場合、 既存のマッピングの重なった部分は捨てられる。 もし指定さ"
2767 "れたアドレスが使用できない場合、 B<mmap>()  は失敗する。 マッピングに対して固"
2768 "定アドレスを要求するのは移植性の面で劣るので、 このオプションは使用しないこと"
2769 "を推奨する。"
2770
2771 #. type: TP
2772 #: build/C/man2/mmap.2:223
2773 #, no-wrap
2774 msgid "B<MAP_GROWSDOWN>"
2775 msgstr "B<MAP_GROWSDOWN>"
2776
2777 #. type: Plain text
2778 #: build/C/man2/mmap.2:228
2779 #, fuzzy
2780 #| msgid ""
2781 #| "Used for stacks.  Indicates to the kernel virtual memory system that the "
2782 #| "mapping should extend downwards in memory."
2783 msgid ""
2784 "Used for stacks.  Indicates to the kernel virtual memory system that the "
2785 "mapping should extend downward in memory."
2786 msgstr ""
2787 "スタック用に使用される。マッピングをメモリ内で逆向きに行うことを カーネル仮想"
2788 "メモリシステムに指示する。 (訳注:マッピングは通常はメモリ・アドレスが増加す"
2789 "る向きに行うが、 このオプションを指定すると逆向きにマッピングを行う)"
2790
2791 #. type: TP
2792 #: build/C/man2/mmap.2:228
2793 #, no-wrap
2794 msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
2795 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
2796
2797 #. type: Plain text
2798 #: build/C/man2/mmap.2:234
2799 msgid ""
2800 "Allocate the mapping using \"huge pages.\" See the kernel source file "
2801 "I<Documentation/vm/hugetlbpage.txt> for further information."
2802 msgstr ""
2803 "\"huge page\" を使ってマッピングを割り当てる。 詳しい情報は、カーネル・ソース"
2804 "の I<Documentation/vm/hugetlbpage.txt> を参照。"
2805
2806 #. type: TP
2807 #: build/C/man2/mmap.2:234
2808 #, no-wrap
2809 msgid "B<MAP_LOCKED> (since Linux 2.5.37)"
2810 msgstr "B<MAP_LOCKED> (Linux 2.5.37 以降)"
2811
2812 #.  If set, the mapped pages will not be swapped out.
2813 #. type: Plain text
2814 #: build/C/man2/mmap.2:240
2815 msgid ""
2816 "Lock the pages of the mapped region into memory in the manner of B<mlock>"
2817 "(2).  This flag is ignored in older kernels."
2818 msgstr ""
2819 "マップされた領域のページを B<mlock>(2)  の方法でメモリ内にロックする。 それ以"
2820 "前のカーネルでは、このフラグは無視される。"
2821
2822 #. type: TP
2823 #: build/C/man2/mmap.2:240
2824 #, no-wrap
2825 msgid "B<MAP_NONBLOCK> (since Linux 2.5.46)"
2826 msgstr "B<MAP_NONBLOCK> (Linux 2.5.46 以降)"
2827
2828 #. type: Plain text
2829 #: build/C/man2/mmap.2:255
2830 msgid ""
2831 "Only meaningful in conjunction with B<MAP_POPULATE>.  Don't perform read-"
2832 "ahead: only create page tables entries for pages that are already present in "
2833 "RAM.  Since Linux 2.6.23, this flag causes B<MAP_POPULATE> to do nothing.  "
2834 "One day the combination of B<MAP_POPULATE> and B<MAP_NONBLOCK> may be "
2835 "reimplemented."
2836 msgstr ""
2837 "B<MAP_POPULATE> と組み合わせた場合のみ意味を持つ。 read-ahead (前もって読み込"
2838 "むこと) を実行しない。 単に、すでに RAM 上に存在するページに対して ページテー"
2839 "ブルエントリを作成するだけである。 Linux 2.6.23 以降では、このフラグは "
2840 "B<MAP_POPULATE> に何の影響も与えない。 いつか B<MAP_POPULATE> と "
2841 "B<MAP_NONBLOCK> を組み合わせた場合の動作は実装し直されるかもしれない。"
2842
2843 #. type: TP
2844 #: build/C/man2/mmap.2:255
2845 #, no-wrap
2846 msgid "B<MAP_NORESERVE>"
2847 msgstr "B<MAP_NORESERVE>"
2848
2849 #. type: Plain text
2850 #: build/C/man2/mmap.2:270
2851 msgid ""
2852 "Do not reserve swap space for this mapping.  When swap space is reserved, "
2853 "one has the guarantee that it is possible to modify the mapping.  When swap "
2854 "space is not reserved one might get B<SIGSEGV> upon a write if no physical "
2855 "memory is available.  See also the discussion of the file I</proc/sys/vm/"
2856 "overcommit_memory> in B<proc>(5).  In kernels before 2.6, this flag only had "
2857 "effect for private writable mappings."
2858 msgstr ""
2859 "このマッピングに対するスワップ空間の予約を行わない。 スワップ空間を予約した場"
2860 "合は、このマッピングの変更が必ず可能なことが 保証される。予約を行わなかった場"
2861 "合、物理メモリに空きがないと 書き込み時に B<SIGSEGV> エラーを受け取ることがあ"
2862 "る。 B<proc>(5)  の I</proc/sys/vm/overcommit_memory> ファイルについての議論"
2863 "も参照。 バージョン 2.6 より前のカーネルでは、このフラグは書き込み可能な プラ"
2864 "イベート・マッピングについてのみ効果があった。"
2865
2866 #. type: TP
2867 #: build/C/man2/mmap.2:270
2868 #, no-wrap
2869 msgid "B<MAP_POPULATE> (since Linux 2.5.46)"
2870 msgstr "B<MAP_POPULATE> (Linux 2.5.46 以降)"
2871
2872 #. type: Plain text
2873 #: build/C/man2/mmap.2:277
2874 msgid ""
2875 "Populate (prefault) page tables for a mapping.  For a file mapping, this "
2876 "causes read-ahead on the file.  Later accesses to the mapping will not be "
2877 "blocked by page faults.  B<MAP_POPULATE> is only supported for private "
2878 "mappings since Linux 2.6.23."
2879 msgstr ""
2880 "マッピング用のページテーブルを配置 (populate) する ファイルマッピングの場合に"
2881 "は、これによりファイルが先読み (read-ahead)  が行われる。この以後は、マッピン"
2882 "グに対するアクセスがページフォールトで ブロックされることがなくなる。 "
2883 "B<MAP_POPULATE> は Linux 2.6.23 以降でプライベート・マッピングについてのみ サ"
2884 "ポートされている。"
2885
2886 #. type: TP
2887 #: build/C/man2/mmap.2:277
2888 #, no-wrap
2889 msgid "B<MAP_STACK> (since Linux 2.6.27)"
2890 msgstr "B<MAP_STACK> (Linux 2.6.27 以降)"
2891
2892 #.  See http://lwn.net/Articles/294642 "Tangled up in threads", 19 Aug 08
2893 #.  commit cd98a04a59e2f94fa64d5bf1e26498d27427d5e7
2894 #.  http://thread.gmane.org/gmane.linux.kernel/720412
2895 #.  "pthread_create() slow for many threads; also time to revisit 64b
2896 #.   context switch optimization?"
2897 #. type: Plain text
2898 #: build/C/man2/mmap.2:290
2899 msgid ""
2900 "Allocate the mapping at an address suitable for a process or thread stack.  "
2901 "This flag is currently a no-op, but is used in the glibc threading "
2902 "implementation so that if some architectures require special treatment for "
2903 "stack allocations, support can later be transparently implemented for glibc."
2904 msgstr ""
2905 "プロセスやスレッドのスタックに適したアドレスにマッピングを割り当てる。 現在の"
2906 "ところ、このフラグは何もしないが、 glibc のスレッド実装では使用されている。 "
2907 "これは、いくつかのアーキテクチャではスタックの割り当てに関して特別な扱い が必"
2908 "要な場合に、glibc にそのサポートを後で透過的に実装できるようにする ためであ"
2909 "る。"
2910
2911 #. type: TP
2912 #: build/C/man2/mmap.2:290
2913 #, fuzzy, no-wrap
2914 #| msgid "B<MAP_HUGETLB> (since Linux 2.6.32)"
2915 msgid "B<MAP_UNINITIALIZED> (since Linux 2.6.33)"
2916 msgstr "B<MAP_HUGETLB> (Linux 2.6.32 以降)"
2917
2918 #. type: Plain text
2919 #: build/C/man2/mmap.2:300
2920 msgid ""
2921 "Don't clear anonymous pages.  This flag is intended to improve performance "
2922 "on embedded devices.  This flag is only honored if the kernel was configured "
2923 "with the B<CONFIG_MMAP_ALLOW_UNINITIALIZED> option.  Because of the security "
2924 "implications, that option is normally enabled only on embedded devices (i."
2925 "e., devices where one has complete control of the contents of user memory)."
2926 msgstr ""
2927
2928 #. type: Plain text
2929 #: build/C/man2/mmap.2:308
2930 msgid ""
2931 "Of the above flags, only B<MAP_FIXED> is specified in POSIX.1-2001.  "
2932 "However, most systems also support B<MAP_ANONYMOUS> (or its synonym "
2933 "B<MAP_ANON>)."
2934 msgstr ""
2935 "上記のフラグの中では、 B<MAP_FIXED> だけが POSIX.1-2001 で規定されている。 し"
2936 "かしながら、ほとんどのシステムで B<MAP_ANONYMOUS> (またはその同義語である "
2937 "B<MAP_ANON>)  もサポートされている。"
2938
2939 #. type: Plain text
2940 #: build/C/man2/mmap.2:315
2941 msgid ""
2942 "Some systems document the additional flags B<MAP_AUTOGROW>, "
2943 "B<MAP_AUTORESRV>, B<MAP_COPY>, and B<MAP_LOCAL>."
2944 msgstr ""
2945 "いくつかのシステムでは、上記以外にフラグとして B<MAP_AUTOGROW>, "
2946 "B<MAP_AUTORESRV>, B<MAP_COPY>, B<MAP_LOCAL> が規定されている。"
2947
2948 #. type: Plain text
2949 #: build/C/man2/mmap.2:321
2950 msgid ""
2951 "Memory mapped by B<mmap>()  is preserved across B<fork>(2), with the same "
2952 "attributes."
2953 msgstr ""
2954 "B<mmap>()  によってマップされたメモリの属性は B<fork>(2)  の際に継承される。"
2955
2956 #. type: Plain text
2957 #: build/C/man2/mmap.2:329
2958 msgid ""
2959 "A file is mapped in multiples of the page size.  For a file that is not a "
2960 "multiple of the page size, the remaining memory is zeroed when mapped, and "
2961 "writes to that region are not written out to the file.  The effect of "
2962 "changing the size of the underlying file of a mapping on the pages that "
2963 "correspond to added or removed regions of the file is unspecified."
2964 msgstr ""
2965 "ファイルはページサイズの整数倍の領域にマップされる。サイズがページサイズの 整"
2966 "数倍でないファイルの場合、マップ時に残りの領域は 0 で埋められ、この領域へ 書"
2967 "きこみを行ってもファイルに書き出されることはない。マッピングを行った元 ファイ"
2968 "ルのサイズを変更した場合、元ファイルの追加されたり削除された領域に対応 する"
2969 "マップされたページに対してどのような影響があるかは規定されていない。"
2970
2971 #. type: SS
2972 #: build/C/man2/mmap.2:329
2973 #, no-wrap
2974 msgid "munmap()"
2975 msgstr "munmap()"
2976
2977 #. type: Plain text
2978 #: build/C/man2/mmap.2:339
2979 msgid ""
2980 "The B<munmap>()  system call deletes the mappings for the specified address "
2981 "range, and causes further references to addresses within the range to "
2982 "generate invalid memory references.  The region is also automatically "
2983 "unmapped when the process is terminated.  On the other hand, closing the "
2984 "file descriptor does not unmap the region."
2985 msgstr ""
2986 "システムコール B<munmap>()  は指定されたアドレス範囲のマップを消去し、 これ以"
2987 "降のその範囲内へのメモリ参照は不正となる。 この領域は、プロセスが終了したとき"
2988 "にも自動的にアンマップされる。 一方、ファイル記述子をクローズしても、この領域"
2989 "はアンマップされない。"
2990
2991 #. type: Plain text
2992 #: build/C/man2/mmap.2:349
2993 msgid ""
2994 "The address I<addr> must be a multiple of the page size.  All pages "
2995 "containing a part of the indicated range are unmapped, and subsequent "
2996 "references to these pages will generate B<SIGSEGV>.  It is not an error if "
2997 "the indicated range does not contain any mapped pages."
2998 msgstr ""
2999 "I<addr> アドレスはページサイズの整数倍でなければならない。指定された範囲の一"
3000 "部分を 含む全てのページはアンマップされ、これ以降にこれらのページへの参照があ"
3001 "ると B<SIGSEGV> が発生する。 指定した範囲内にマップされたページが一つも含まれ"
3002 "ていない場合でも エラーにならない。"
3003
3004 #. type: SS
3005 #: build/C/man2/mmap.2:349
3006 #, no-wrap
3007 msgid "Timestamps changes for file-backed mappings"
3008 msgstr "ファイルと関連付けられたマッピングに対するタイムスタンプの更新"
3009
3010 #. type: Plain text
3011 #: build/C/man2/mmap.2:356
3012 msgid ""
3013 "For file-backed mappings, the I<st_atime> field for the mapped file may be "
3014 "updated at any time between the B<mmap>()  and the corresponding unmapping; "
3015 "the first reference to a mapped page will update the field if it has not "
3016 "been already."
3017 msgstr ""
3018 "ファイルと関連付けられたマッピングの場合、マッピングされたファイルの "
3019 "I<st_atime> フィールドは、 B<mmap>()  されてからアンマップ (unmap) されるまで"
3020 "の間に更新されることがある。 それまでに更新が行われていなければ、マップされた"
3021 "ページへの最初の参照があった 際に更新される。"
3022
3023 #. type: Plain text
3024 #: build/C/man2/mmap.2:373
3025 msgid ""
3026 "The I<st_ctime> and I<st_mtime> field for a file mapped with B<PROT_WRITE> "
3027 "and B<MAP_SHARED> will be updated after a write to the mapped region, and "
3028 "before a subsequent B<msync>(2)  with the B<MS_SYNC> or B<MS_ASYNC> flag, if "
3029 "one occurs."
3030 msgstr ""
3031 "B<PROT_WRITE> と B<MAP_SHARED> の両方を指定してマップされたファイルの場合、書"
3032 "き込みがあると、 I<st_ctime> と I<st_mtime> の両フィールドは、マップされた領"
3033 "域への書き込みより後で、 B<MS_SYNC> または B<MS_ASYNC> フラグを指定して "
3034 "B<msync>(2)  が呼ばれる前までに更新される。"
3035
3036 #. type: Plain text
3037 #: build/C/man2/mmap.2:390
3038 msgid ""
3039 "On success, B<mmap>()  returns a pointer to the mapped area.  On error, the "
3040 "value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>)  is returned, and I<errno> "
3041 "is set appropriately.  On success, B<munmap>()  returns 0, on failure -1, "
3042 "and I<errno> is set (probably to B<EINVAL>)."
3043 msgstr ""
3044 "B<mmap>()  は成功するとマップされた領域へのポインタを返す。 失敗すると値 "
3045 "B<MAP_FAILED> (つまり I<(void\\ *)\\ -1>)  を返し、 I<errno> がエラーの内容に"
3046 "したがってセットされる。 B<munmap>()  は成功すると 0 を返す。失敗すると -1 を"
3047 "返し、 I<errno> がセットされる (多くの場合 B<EINVAL> になるだろう)。"
3048
3049 #. type: TP
3050 #: build/C/man2/mmap.2:391 build/C/man2/mprotect.2:80
3051 #: build/C/man3/shm_open.3:185 build/C/man3/shm_open.3:190
3052 #: build/C/man2/shmctl.2:295 build/C/man2/shmget.2:186
3053 #: build/C/man2/shmop.2:189
3054 #, no-wrap
3055 msgid "B<EACCES>"
3056 msgstr "B<EACCES>"
3057
3058 #. type: Plain text
3059 #: build/C/man2/mmap.2:411
3060 msgid ""
3061 "A file descriptor refers to a non-regular file.  Or B<MAP_PRIVATE> was "
3062 "requested, but I<fd> is not open for reading.  Or B<MAP_SHARED> was "
3063 "requested and B<PROT_WRITE> is set, but I<fd> is not open in read/write "
3064 "(B<O_RDWR>)  mode.  Or B<PROT_WRITE> is set, but the file is append-only."
3065 msgstr ""
3066 "以下のいずれかの場合。 ファイル記述子の参照先が通常のファイルではない (non-"
3067 "regular file) 。 B<MAP_PRIVATE> を要求したが I<fd> は読み込み用にオープンされ"
3068 "ていない。 B<MAP_SHARED> を要求して B<PROT_WRITE> をセットしたが I<fd> は読み"
3069 "書きモード (B<O_RDWR>)  でオープンされていない、 B<PROT_WRITE> をセットした"
3070 "が、ファイルは追加 (append) 専用である。"
3071
3072 #. type: Plain text
3073 #: build/C/man2/mmap.2:415
3074 msgid ""
3075 "The file has been locked, or too much memory has been locked (see "
3076 "B<setrlimit>(2))."
3077 msgstr ""
3078 "ファイルがロックされている。またはロックされているメモリが多すぎる "
3079 "(B<setrlimit>(2)  を参照)。"
3080
3081 #. type: Plain text
3082 #: build/C/man2/mmap.2:421
3083 msgid ""
3084 "I<fd> is not a valid file descriptor (and B<MAP_ANONYMOUS> was not set)."
3085 msgstr ""
3086 "I<fd> が有効なファイル記述子 (file descriptor) ではない (かつ "
3087 "B<MAP_ANONYMOUS> がセットされていない)。"
3088
3089 #. type: Plain text
3090 #: build/C/man2/mmap.2:429
3091 msgid ""
3092 "We don't like I<addr>, I<length>, or I<offset> (e.g., they are too large, or "
3093 "not aligned on a page boundary)."
3094 msgstr ""
3095 "I<addr> か I<length> か I<offset> が適切でない (例えば、大きすぎるとか、ペー"
3096 "ジ境界にアラインメントされていない)。"
3097
3098 #. type: Plain text
3099 #: build/C/man2/mmap.2:434
3100 msgid "(since Linux 2.6.12)  I<length> was 0."
3101 msgstr "(Linux 2.6.12 以降)  I<length> が 0 であった。"
3102
3103 #. type: Plain text
3104 #: build/C/man2/mmap.2:442
3105 msgid ""
3106 "I<flags> contained neither B<MAP_PRIVATE> or B<MAP_SHARED>, or contained "
3107 "both of these values."
3108 msgstr ""
3109 "I<flags> に B<MAP_PRIVATE> と B<MAP_SHARED> のどちらも含まれていなかった、も"
3110 "しくは その両方が含まれていた。"
3111
3112 #. type: TP
3113 #: build/C/man2/mmap.2:442 build/C/man3/shm_open.3:227
3114 #: build/C/man2/shmget.2:202
3115 #, no-wrap
3116 msgid "B<ENFILE>"
3117 msgstr "B<ENFILE>"
3118
3119 #.  [2.6.7] shmem_zero_setup()-->shmem_file_setup()-->get_empty_filp()
3120 #. type: Plain text
3121 #: build/C/man2/mmap.2:450 build/C/man2/shmget.2:206
3122 msgid "The system limit on the total number of open files has been reached."
3123 msgstr "システム全体でオープンされているファイルの総数が上限に達した。"
3124
3125 #. type: Plain text
3126 #: build/C/man2/mmap.2:454
3127 msgid ""
3128 "The underlying file system of the specified file does not support memory "
3129 "mapping."
3130 msgstr ""
3131 "指定されたファイルが置かれているファイルシステムがメモリマッピングをサポート "
3132 "していない。"
3133
3134 #. type: Plain text
3135 #: build/C/man2/mmap.2:458
3136 msgid ""
3137 "No memory is available, or the process's maximum number of mappings would "
3138 "have been exceeded."
3139 msgstr ""
3140 "メモリに空きがない、または処理中のプロセスのマッピング数が最大数を超過した。"
3141
3142 #.  (Since 2.4.25 / 2.6.0.)
3143 #. type: Plain text
3144 #: build/C/man2/mmap.2:467
3145 msgid ""
3146 "The I<prot> argument asks for B<PROT_EXEC> but the mapped area belongs to a "
3147 "file on a file system that was mounted no-exec."
3148 msgstr ""
3149 "I<prot> 引き数は B<PROT_EXEC> を行うように指定されているが、 no-exec でマウン"
3150 "トされたファイルシステム上のファイルに マップ領域が対応している。"
3151
3152 #. type: TP
3153 #: build/C/man2/mmap.2:467
3154 #, no-wrap
3155 msgid "B<ETXTBSY>"
3156 msgstr "B<ETXTBSY>"
3157
3158 #. type: Plain text
3159 #: build/C/man2/mmap.2:473
3160 msgid ""
3161 "B<MAP_DENYWRITE> was set but the object specified by I<fd> is open for "
3162 "writing."
3163 msgstr ""
3164 "B<MAP_DENYWRITE> がセットされているが I<fd> で指定されているオブジェクトは書"
3165 "き込み用に開かれている。"
3166
3167 #. type: Plain text
3168 #: build/C/man2/mmap.2:475
3169 msgid "Use of a mapped region can result in these signals:"
3170 msgstr "マップ領域を利用する際に、以下のシグナルが発生することがある:"
3171
3172 #. type: TP
3173 #: build/C/man2/mmap.2:475
3174 #, no-wrap
3175 msgid "B<SIGSEGV>"
3176 msgstr "B<SIGSEGV>"
3177
3178 #. type: Plain text
3179 #: build/C/man2/mmap.2:478
3180 msgid "Attempted write into a region mapped as read-only."
3181 msgstr "読み込み専用で mmap された領域へ書き込みを行おうとした。"
3182
3183 #. type: TP
3184 #: build/C/man2/mmap.2:478
3185 #, no-wrap
3186 msgid "B<SIGBUS>"
3187 msgstr "B<SIGBUS>"
3188
3189 #. type: Plain text
3190 #: build/C/man2/mmap.2:483
3191 msgid ""
3192 "Attempted access to a portion of the buffer that does not correspond to the "
3193 "file (for example, beyond the end of the file, including the case where "
3194 "another process has truncated the file)."
3195 msgstr ""
3196 "バッファのうち、ファイルに関連づけられていない部分 (例えばファイル末尾を越え"
3197 "た部分など。これには 他のプロセスがファイルを切り詰めた場合なども含まれる)  "
3198 "にアクセスしようとした。"
3199
3200 #.  SVr4 documents additional error codes ENXIO and ENODEV.
3201 #.  SUSv2 documents additional error codes EMFILE and EOVERFLOW.
3202 #. type: Plain text
3203 #: build/C/man2/mmap.2:487
3204 msgid "SVr4, 4.4BSD, POSIX.1-2001."
3205 msgstr "SVr4, 4.4BSD, POSIX.1-2001."
3206
3207 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
3208 #.  -1: unavailable, 0: ask using sysconf().
3209 #.  glibc defines it to 1.
3210 #. type: Plain text
3211 #: build/C/man2/mmap.2:501
3212 msgid ""
3213 "On POSIX systems on which B<mmap>(), B<msync>(2)  and B<munmap>()  are "
3214 "available, B<_POSIX_MAPPED_FILES> is defined in I<E<lt>unistd.hE<gt>> to a "
3215 "value greater than 0.  (See also B<sysconf>(3).)"
3216 msgstr ""
3217 "B<mmap>(), B<msync>(2)  B<munmap>()  が利用可能な POSIX システムでは、 "
3218 "B<_POSIX_MAPPED_FILES> は E<lt>unistd.hE<gt> で 0 より大きな値に定義される "
3219 "(B<sysconf>(3)  も参照のこと)。"
3220
3221 #.  Since around glibc 2.1/2.2, depending on the platform.
3222 #. type: Plain text
3223 #: build/C/man2/mmap.2:512
3224 msgid ""
3225 "Since kernel 2.4, this system call has been superseded by B<mmap2>(2).  "
3226 "Nowadays, the glibc B<mmap>()  wrapper function invokes B<mmap2>(2)  with a "
3227 "suitably adjusted value for I<offset>."
3228 msgstr ""
3229 "カーネル 2.4 以降、このシステムコールは B<mmap2>(2)  に取って代わられた。 現"
3230 "在では、 glibc の B<mmap>()  のラッパー関数は I<offset> を適切に調整してから "
3231 "B<mmap2>(2)  を起動する。"
3232
3233 #. type: Plain text
3234 #: build/C/man2/mmap.2:525
3235 msgid ""
3236 "On some hardware architectures (e.g., i386), B<PROT_WRITE> implies "
3237 "B<PROT_READ>.  It is architecture dependent whether B<PROT_READ> implies "
3238 "B<PROT_EXEC> or not.  Portable programs should always set B<PROT_EXEC> if "
3239 "they intend to execute code in the new mapping."
3240 msgstr ""
3241 "(i386 などの) いくつかのアーキテクチャでは、 B<PROT_WRITE> をセットすると、暗"
3242 "黙のうちに B<PROT_READ> がセットされる。 B<PROT_READ> をセットした際に暗黙の"
3243 "うちに B<PROT_EXEC> がセットされるかどうかは、アーキテクチャ依存である。 移植"
3244 "性を考慮したプログラムでは、 新規にマップした領域でコードを実行したい場合は、"
3245 "常に B<PROT_EXEC> をセットすべきである。"
3246
3247 #. type: Plain text
3248 #: build/C/man2/mmap.2:540
3249 msgid ""
3250 "The portable way to create a mapping is to specify I<addr> as 0 (NULL), and "
3251 "omit B<MAP_FIXED> from I<flags>.  In this case, the system chooses the "
3252 "address for the mapping; the address is chosen so as not to conflict with "
3253 "any existing mapping, and will not be 0.  If the B<MAP_FIXED> flag is "
3254 "specified, and I<addr> is 0 (NULL), then the mapped address will be 0 (NULL)."
3255 msgstr ""
3256 "マッピングを作成する移植性のある方法は、 I<addr> に 0 (NULL) を指定し、 "
3257 "I<flags> から B<MAP_FIXED> を外すことである。 この場合、システムがマッピング"
3258 "用のアドレスの選択を行う。 アドレスは既存のマッピングと衝突しないように、 か"
3259 "つ 0 にならないように選択される。 B<MAP_FIXED> フラグが指定され、かつ "
3260 "I<addr> が 0 (NULL)  の場合には、マップされるアドレスが 0 (NULL) になる。"
3261
3262 #. type: Plain text
3263 #: build/C/man2/mmap.2:545
3264 msgid ""
3265 "On Linux there are no guarantees like those suggested above under "
3266 "B<MAP_NORESERVE>.  By default, any process can be killed at any moment when "
3267 "the system runs out of memory."
3268 msgstr ""
3269 "Linux においては、上記の B<MAP_NORESERVE> で述べられているような保証はない。 "
3270 "デフォルトでは、システムがメモリを使い切った場合には、 どのプロセスがいつ強制"
3271 "終了されるか分からないからである。"
3272
3273 #. type: Plain text
3274 #: build/C/man2/mmap.2:552
3275 msgid ""
3276 "In kernels before 2.6.7, the B<MAP_POPULATE> flag only has effect if I<prot> "
3277 "is specified as B<PROT_NONE>."
3278 msgstr ""
3279 "2.6.7 より前のカーネルでは、 I<prot> に B<PROT_NONE> が指定された場合にの"
3280 "み、 B<MAP_POPULATE> フラグが効力を持つ。"
3281
3282 #. type: Plain text
3283 #: build/C/man2/mmap.2:567
3284 msgid ""
3285 "SUSv3 specifies that B<mmap>()  should fail if I<length> is 0.  However, in "
3286 "kernels before 2.6.12, B<mmap>()  succeeded in this case: no mapping was "
3287 "created and the call returned I<addr>.  Since kernel 2.6.12, B<mmap>()  "
3288 "fails with the error B<EINVAL> for this case."
3289 msgstr ""
3290 "SUSv3 では、 I<length> が 0 の場合、 B<mmap>()  は失敗すると規定されている。"
3291 "しかしながら、2.6.12 より前のカーネルでは、 この場合に B<mmap>()  は成功して"
3292 "いた (マッピングは作成されず、 I<addr> が返されていた)。 カーネル 2.6.12 以降"
3293 "では、 B<mmap>()  はエラー B<EINVAL> で失敗する。"
3294
3295 #. type: Plain text
3296 #: build/C/man2/mmap.2:579
3297 msgid ""
3298 "The following program prints part of the file specified in its first command-"
3299 "line argument to standard output.  The range of bytes to be printed is "
3300 "specified via offset and length values in the second and third command-line "
3301 "arguments.  The program creates a memory mapping of the required pages of "
3302 "the file and then uses B<write>(2)  to output the desired bytes."
3303 msgstr ""
3304 "以下のプログラムは、一番目のコマンドライン引き数で指定された ファイルの一部を"
3305 "標準出力に表示する。 表示する範囲は、二番目、三番目のコマンドライン引き数で渡"
3306 "される オフセットと長さで指定される。 このプログラムは、指定されたファイルの"
3307 "必要なページのメモリ・ マッピングを作成し、 B<write>(2)  を使って所望のバイト"
3308 "を出力する。"
3309
3310 #. type: Plain text
3311 #: build/C/man2/mmap.2:587
3312 #, no-wrap
3313 msgid ""
3314 "#include E<lt>sys/mman.hE<gt>\n"
3315 "#include E<lt>sys/stat.hE<gt>\n"
3316 "#include E<lt>fcntl.hE<gt>\n"
3317 "#include E<lt>stdio.hE<gt>\n"
3318 "#include E<lt>stdlib.hE<gt>\n"
3319 "#include E<lt>unistd.hE<gt>\n"
3320 msgstr ""
3321 "#include E<lt>sys/mman.hE<gt>\n"
3322 "#include E<lt>sys/stat.hE<gt>\n"
3323 "#include E<lt>fcntl.hE<gt>\n"
3324 "#include E<lt>stdio.hE<gt>\n"
3325 "#include E<lt>stdlib.hE<gt>\n"
3326 "#include E<lt>unistd.hE<gt>\n"
3327
3328 #. type: Plain text
3329 #: build/C/man2/mmap.2:590 build/C/man2/mprotect.2:172
3330 #, no-wrap
3331 msgid ""
3332 "#define handle_error(msg) \\e\n"
3333 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
3334 msgstr ""
3335 "#define handle_error(msg) \\e\n"
3336 "    do { perror(msg); exit(EXIT_FAILURE); } while (0)\n"
3337
3338 #. type: Plain text
3339 #: build/C/man2/mmap.2:600
3340 #, no-wrap
3341 msgid ""
3342 "int\n"
3343 "main(int argc, char *argv[])\n"
3344 "{\n"
3345 "    char *addr;\n"
3346 "    int fd;\n"
3347 "    struct stat sb;\n"
3348 "    off_t offset, pa_offset;\n"
3349 "    size_t length;\n"
3350 "    ssize_t s;\n"
3351 msgstr ""
3352 "int\n"
3353 "main(int argc, char *argv[])\n"
3354 "{\n"
3355 "    char *addr;\n"
3356 "    int fd;\n"
3357 "    struct stat sb;\n"
3358 "    off_t offset, pa_offset;\n"
3359 "    size_t length;\n"
3360 "    ssize_t s;\n"
3361
3362 #. type: Plain text
3363 #: build/C/man2/mmap.2:605
3364 #, no-wrap
3365 msgid ""
3366 "    if (argc E<lt> 3 || argc E<gt> 4) {\n"
3367 "        fprintf(stderr, \"%s file offset [length]\\en\", argv[0]);\n"
3368 "        exit(EXIT_FAILURE);\n"
3369 "    }\n"
3370 msgstr ""
3371 "    if (argc E<lt> 3 || argc E<gt> 4) {\n"
3372 "        fprintf(stderr, \"%s file offset [length]\\en\", argv[0]);\n"
3373 "        exit(EXIT_FAILURE);\n"
3374 "    }\n"
3375
3376 #. type: Plain text
3377 #: build/C/man2/mmap.2:609
3378 #, no-wrap
3379 msgid ""
3380 "    fd = open(argv[1], O_RDONLY);\n"
3381 "    if (fd == -1)\n"
3382 "        handle_error(\"open\");\n"
3383 msgstr ""
3384 "    fd = open(argv[1], O_RDONLY);\n"
3385 "    if (fd == -1)\n"
3386 "        handle_error(\"open\");\n"
3387
3388 #. type: Plain text
3389 #: build/C/man2/mmap.2:612
3390 #, no-wrap
3391 msgid ""
3392 "    if (fstat(fd, &sb) == -1)           /* To obtain file size */\n"
3393 "        handle_error(\"fstat\");\n"
3394 msgstr ""
3395 "    if (fstat(fd, &sb) == -1)           /* To obtain file size */\n"
3396 "        handle_error(\"fstat\");\n"
3397
3398 #. type: Plain text
3399 #: build/C/man2/mmap.2:616
3400 #, no-wrap
3401 msgid ""
3402 "    offset = atoi(argv[2]);\n"
3403 "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
3404 "        /* offset for mmap() must be page aligned */\n"
3405 msgstr ""
3406 "    offset = atoi(argv[2]);\n"
3407 "    pa_offset = offset & ~(sysconf(_SC_PAGE_SIZE) - 1);\n"
3408 "        /* offset for mmap() must be page aligned */\n"
3409
3410 #. type: Plain text
3411 #: build/C/man2/mmap.2:621
3412 #, no-wrap
3413 msgid ""
3414 "    if (offset E<gt>= sb.st_size) {\n"
3415 "        fprintf(stderr, \"offset is past end of file\\en\");\n"
3416 "        exit(EXIT_FAILURE);\n"
3417 "    }\n"
3418 msgstr ""
3419 "    if (offset E<gt>= sb.st_size) {\n"
3420 "        fprintf(stderr, \"offset is past end of file\\en\");\n"
3421 "        exit(EXIT_FAILURE);\n"
3422 "    }\n"
3423
3424 #. type: Plain text
3425 #: build/C/man2/mmap.2:627
3426 #, no-wrap
3427 msgid ""
3428 "    if (argc == 4) {\n"
3429 "        length = atoi(argv[3]);\n"
3430 "        if (offset + length E<gt> sb.st_size)\n"
3431 "            length = sb.st_size - offset;\n"
3432 "                /* Can\\(aqt display bytes past end of file */\n"
3433 msgstr ""
3434 "    if (argc == 4) {\n"
3435 "        length = atoi(argv[3]);\n"
3436 "        if (offset + length E<gt> sb.st_size)\n"
3437 "            length = sb.st_size - offset;\n"
3438 "                /* Can\\(aqt display bytes past end of file */\n"
3439
3440 #. type: Plain text
3441 #: build/C/man2/mmap.2:631
3442 #, no-wrap
3443 msgid ""
3444 "    } else {    /* No length arg ==E<gt> display to end of file */\n"
3445 "        length = sb.st_size - offset;\n"
3446 "    }\n"
3447 msgstr ""
3448 "    } else {    /* No length arg ==E<gt> display to end of file */\n"
3449 "        length = sb.st_size - offset;\n"
3450 "    }\n"
3451
3452 #. type: Plain text
3453 #: build/C/man2/mmap.2:636
3454 #, no-wrap
3455 msgid ""
3456 "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
3457 "                MAP_PRIVATE, fd, pa_offset);\n"
3458 "    if (addr == MAP_FAILED)\n"
3459 "        handle_error(\"mmap\");\n"
3460 msgstr ""
3461 "    addr = mmap(NULL, length + offset - pa_offset, PROT_READ,\n"
3462 "                MAP_PRIVATE, fd, pa_offset);\n"
3463 "    if (addr == MAP_FAILED)\n"
3464 "        handle_error(\"mmap\");\n"
3465
3466 #. type: Plain text
3467 #: build/C/man2/mmap.2:641
3468 #, no-wrap
3469 msgid ""
3470 "    s = write(STDOUT_FILENO, addr + offset - pa_offset, length);\n"
3471 "    if (s != length) {\n"
3472 "        if (s == -1)\n"
3473 "            handle_error(\"write\");\n"
3474 msgstr ""
3475 "    s = write(STDOUT_FILENO, addr + offset - pa_offset, length);\n"
3476 "    if (s != length) {\n"
3477 "        if (s == -1)\n"
3478 "            handle_error(\"write\");\n"
3479
3480 #. type: Plain text
3481 #: build/C/man2/mmap.2:645
3482 #, no-wrap
3483 msgid ""
3484 "        fprintf(stderr, \"partial write\");\n"
3485 "        exit(EXIT_FAILURE);\n"
3486 "    }\n"
3487 msgstr ""
3488 "        fprintf(stderr, \"partial write\");\n"
3489 "        exit(EXIT_FAILURE);\n"
3490 "    }\n"
3491
3492 #. type: Plain text
3493 #: build/C/man2/mmap.2:648
3494 #, fuzzy, no-wrap
3495 #| msgid ""
3496 #| "    exit(EXIT_SUCCESS);\n"
3497 #| "} /* main */\n"
3498 msgid ""
3499 "    exit(EXIT_SUCCESS);\n"
3500 "}\n"
3501 msgstr ""
3502 "    exit(EXIT_SUCCESS);\n"
3503 "} /* main */\n"
3504
3505 #. type: Plain text
3506 #: build/C/man2/mmap.2:662
3507 msgid ""
3508 "B<getpagesize>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), "
3509 "B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>"
3510 "(2), B<shm_open>(3), B<shm_overview>(7)"
3511 msgstr ""
3512 "B<getpagesize>(2), B<mincore>(2), B<mlock>(2), B<mmap2>(2), B<mprotect>(2), "
3513 "B<mremap>(2), B<msync>(2), B<remap_file_pages>(2), B<setrlimit>(2), B<shmat>"
3514 "(2), B<shm_open>(3), B<shm_overview>(7)"
3515
3516 #. type: Plain text
3517 #: build/C/man2/mmap.2:667 build/C/man2/msync.2:122
3518 msgid "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
3519 msgstr "B.O. Gallmeister, POSIX.4, O'Reilly, pp. 128-129 and 389-391."
3520
3521 #. type: TH
3522 #: build/C/man2/mmap2.2:29
3523 #, no-wrap
3524 msgid "MMAP2"
3525 msgstr "MMAP2"
3526
3527 #. type: TH
3528 #: build/C/man2/mmap2.2:29 build/C/man2/msync.2:25
3529 #: build/C/man2/remap_file_pages.2:26
3530 #, no-wrap
3531 msgid "2008-04-22"
3532 msgstr "2008-04-22"
3533
3534 #. type: Plain text
3535 #: build/C/man2/mmap2.2:32
3536 msgid "mmap2 - map files or devices into memory"
3537 msgstr "mmap2 - ファイルやデバイスをメモリにマップする"
3538
3539 #. type: Plain text
3540 #: build/C/man2/mmap2.2:38
3541 #, no-wrap
3542 msgid ""
3543 "B<void *mmap2(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<,>\n"
3544 "B<             int >I<flags>B<, int >I<fd>B<, off_t >I<pgoffset>B<);>\n"
3545 msgstr ""
3546 "B<void *mmap2(void *>I<addr>B<, size_t >I<length>B<, int >I<prot>B<,>\n"
3547 "B<            int >I<flags>B<, int >I<fd>B<, off_t >I<pgoffset>B<);>\n"
3548
3549 #. type: Plain text
3550 #: build/C/man2/mmap2.2:50
3551 msgid ""
3552 "The B<mmap2>()  system call operates in exactly the same way as B<mmap>(2), "
3553 "except that the final argument specifies the offset into the file in 4096-"
3554 "byte units (instead of bytes, as is done by B<mmap>(2)).  This enables "
3555 "applications that use a 32-bit I<off_t> to map large files (up to 2^44 "
3556 "bytes)."
3557 msgstr ""
3558 "B<mmap2>()  システムコールは B<mmap>(2)  と全く同じように動作する。 ただし最"
3559 "後の引き数には、ファイルのオフセットを (B<mmap>(2)  が行っている、バイト単位"
3560 "ではなく)  4096 バイトを単位として指定する。 これにより、32 ビットの "
3561 "I<off_t> を使うアプリケーションで (2^44 バイトまでの)  大きなファイルをマップ"
3562 "できるようになる。"
3563
3564 #. type: Plain text
3565 #: build/C/man2/mmap2.2:57
3566 msgid ""
3567 "On success, B<mmap2>()  returns a pointer to the mapped area.  On error -1 "
3568 "is returned and I<errno> is set appropriately."
3569 msgstr ""
3570 "成功した場合、 B<mmap2>()  はマップされた領域へのポインタを返す。 エラーの場"
3571 "合は -1 が返されて、 I<errno> が適切に設定される。"
3572
3573 #. type: Plain text
3574 #: build/C/man2/mmap2.2:61
3575 msgid "Problem with getting the data from userspace."
3576 msgstr "ユーザ空間からデータを取得するときに問題があった。"
3577
3578 #. type: Plain text
3579 #: build/C/man2/mmap2.2:66
3580 msgid ""
3581 "(Various platforms where the page size is not 4096 bytes.)  I<offset * 4096> "
3582 "is not a multiple of the system page size."
3583 msgstr ""
3584 "(ページサイズが 4096 バイトでないプラットフォームにおいて)  I<offset * 4096> "
3585 "がシステムのページサイズの倍数ではない。"
3586
3587 #. type: Plain text
3588 #: build/C/man2/mmap2.2:70
3589 msgid "B<mmap2>()  can return any of the same errors as B<mmap>(2)."
3590 msgstr "B<mmap2>()  は B<mmap>(2)  と同じエラーを返すことができる。"
3591
3592 #. type: Plain text
3593 #: build/C/man2/mmap2.2:73
3594 msgid "B<mmap2>()  is available since Linux 2.3.31."
3595 msgstr "B<mmap2>()  は、Linux 2.3.31 以降で使用可能である。"
3596
3597 #. type: Plain text
3598 #: build/C/man2/mmap2.2:75 build/C/man2/subpage_prot.2:93
3599 msgid "This system call is Linux-specific."
3600 msgstr "このシステムコールは Linux 独自である。"
3601
3602 #. type: Plain text
3603 #: build/C/man2/mmap2.2:81
3604 msgid ""
3605 "Nowadays, the glibc B<mmap>()  wrapper function invokes this system call "
3606 "rather than the B<mmap>(2)  system call."
3607 msgstr ""
3608 "現在では、glibc の B<mmap>()  のラッパー関数は、 B<mmap>(2)  システムコールで"
3609 "はなく、このシステムコール (B<mmap2>(2))  を起動する。"
3610
3611 #.  ia64 can have page sizes ranging from 4kB to 64kB.
3612 #.  On cris, it looks like the unit might also be the page size,
3613 #.  which is 8192 bytes. -- mtk, June 2007
3614 #. type: Plain text
3615 #: build/C/man2/mmap2.2:88
3616 msgid ""
3617 "On ia64, the unit for I<offset> is actually the system page size, rather "
3618 "than 4096 bytes."
3619 msgstr ""
3620 "ia64 では、 I<offset> の単位は、実際にはシステムのページサイズであり、 4096 "
3621 "バイトではない。"
3622
3623 #. type: Plain text
3624 #: build/C/man2/mmap2.2:94
3625 msgid ""
3626 "B<getpagesize>(2), B<mmap>(2), B<mremap>(2), B<msync>(2), B<shm_open>(3)"
3627 msgstr ""
3628 "B<getpagesize>(2), B<mmap>(2), B<mremap>(2), B<msync>(2), B<shm_open>(3)"
3629
3630 #. type: TH
3631 #: build/C/man2/mprotect.2:32
3632 #, no-wrap
3633 msgid "MPROTECT"
3634 msgstr "MPROTECT"
3635
3636 #. type: TH
3637 #: build/C/man2/mprotect.2:32
3638 #, no-wrap
3639 msgid "2011-09-08"
3640 msgstr "2011-09-08"
3641
3642 #. type: Plain text
3643 #: build/C/man2/mprotect.2:35
3644 msgid "mprotect - set protection on a region of memory"
3645 msgstr "mprotect - メモリ領域の保護を設定する"
3646
3647 #. type: Plain text
3648 #: build/C/man2/mprotect.2:40
3649 #, no-wrap
3650 msgid "B<int mprotect(const void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
3651 msgstr "B<int mprotect(const void *>I<addr>B<, size_t >I<len>B<, int >I<prot>B<);>\n"
3652
3653 #. type: Plain text
3654 #: build/C/man2/mprotect.2:48
3655 msgid ""
3656 "B<mprotect>()  changes protection for the calling process's memory page(s)  "
3657 "containing any part of the address range in the interval [I<addr>,\\ I<addr>"
3658 "+I<len>-1].  I<addr> must be aligned to a page boundary."
3659 msgstr ""
3660 "B<mprotect>()  は、区間 [I<addr>,\\ I<addr>+I<len>-1] のアドレス範囲を含む 呼"
3661 "び出し元のプロセスのメモリページのアクセス保護を変更する。 I<addr> はページ境"
3662 "界に一致していなければならない。"
3663
3664 #. type: Plain text
3665 #: build/C/man2/mprotect.2:53
3666 msgid ""
3667 "If the calling process tries to access memory in a manner that violates the "
3668 "protection, then the kernel generates a B<SIGSEGV> signal for the process."
3669 msgstr ""
3670 "呼び出し元のプロセスがアクセス保護に違反するようなメモリアクセスを 行おうとす"
3671 "ると、カーネルはシグナル B<SIGSEGV> をそのプロセスに対して生成する。"
3672
3673 #. type: Plain text
3674 #: build/C/man2/mprotect.2:58
3675 msgid ""
3676 "I<prot> is either B<PROT_NONE> or a bitwise-or of the other values in the "
3677 "following list:"
3678 msgstr ""
3679 "I<prot> には、 B<PROT_NONE> か、以下のリストの B<PROT_NONE> 以外の値をビット"
3680 "毎の論理和 (bitwize-or) で指定する:"
3681
3682 #. type: Plain text
3683 #: build/C/man2/mprotect.2:61
3684 msgid "The memory cannot be accessed at all."
3685 msgstr "そのメモリには全くアクセスできない。"
3686
3687 #. type: Plain text
3688 #: build/C/man2/mprotect.2:64
3689 msgid "The memory can be read."
3690 msgstr "そのメモリを読み取ることができる。"
3691
3692 #. type: Plain text
3693 #: build/C/man2/mprotect.2:67
3694 msgid "The memory can be modified."
3695 msgstr "そのメモリを変更できる。"
3696
3697 #.  FIXME
3698 #.  Document PROT_GROWSUP and PROT_GROWSDOWN
3699 #. type: Plain text
3700 #: build/C/man2/mprotect.2:72
3701 msgid "The memory can be executed."
3702 msgstr "そのメモリは実行可能である。"
3703
3704 #. type: Plain text
3705 #: build/C/man2/mprotect.2:79
3706 msgid ""
3707 "On success, B<mprotect>()  returns zero.  On error, -1 is returned, and "
3708 "I<errno> is set appropriately."
3709 msgstr ""
3710 "成功した場合、 B<mprotect>()  は 0 を返す。エラーの場合は -1 が返り、 "
3711 "I<errno> が適切に設定される。"
3712
3713 #. type: Plain text
3714 #: build/C/man2/mprotect.2:89
3715 msgid ""
3716 "The memory cannot be given the specified access.  This can happen, for "
3717 "example, if you B<mmap>(2)  a file to which you have read-only access, then "
3718 "ask B<mprotect>()  to mark it B<PROT_WRITE>."
3719 msgstr ""
3720 "指定されたアクセスをメモリに設定することができない。 これは、例えば ファイル"
3721 "を読み取り専用で B<mmap>(2)  しており、その領域に対して B<mprotect>()  を呼び"
3722 "出して B<PROT_WRITE> に設定しようとした場合に発生する。"
3723
3724 #.  Or: both PROT_GROWSUP and PROT_GROWSDOWN were specified in 'prot'.
3725 #. type: Plain text
3726 #: build/C/man2/mprotect.2:94
3727 msgid ""
3728 "I<addr> is not a valid pointer, or not a multiple of the system page size."
3729 msgstr ""
3730 "I<addr> が有効なポインタでないか、 システムのページサイズの倍数でない。"
3731
3732 #. type: Plain text
3733 #: build/C/man2/mprotect.2:97
3734 msgid "Internal kernel structures could not be allocated."
3735 msgstr "カーネル内部の構造体を割り当てることができなかった。"
3736
3737 #. type: Plain text
3738 #: build/C/man2/mprotect.2:107
3739 msgid ""
3740 "Addresses in the range [I<addr>, I<addr>+I<len>-1] are invalid for the "
3741 "address space of the process, or specify one or more pages that are not "
3742 "mapped.  (Before kernel 2.4.19, the error B<EFAULT> was incorrectly produced "
3743 "for these cases.)"
3744 msgstr ""
3745 "[I<addr>, I<addr>+I<len>-1] という範囲のアドレスがプロセスのアドレス空間とし"
3746 "て不正であるか、 その範囲のアドレスがマップされていない 1 つ以上のページを指"
3747 "している (カーネル 2.4.19 より前では、この状況でエラー B<EFAULT> が間違って生"
3748 "成されていた)。"
3749
3750 #.  SVr4 defines an additional error
3751 #.  code EAGAIN. The SVr4 error conditions don't map neatly onto Linux's.
3752 #. type: Plain text
3753 #: build/C/man2/mprotect.2:116
3754 msgid ""
3755 "SVr4, POSIX.1-2001.  POSIX says that the behavior of B<mprotect>()  is "
3756 "unspecified if it is applied to a region of memory that was not obtained via "
3757 "B<mmap>(2)."
3758 msgstr ""
3759 "SVr4, POSIX.1-2001.  POSIX では、 B<mmap>(2)  経由で獲得していないメモリ領域"
3760 "に対して B<mprotect>()  を行った場合の B<mprotect>()  の動作は未定義であると"
3761 "されている。"
3762
3763 #. type: Plain text
3764 #: build/C/man2/mprotect.2:123
3765 msgid ""
3766 "On Linux it is always permissible to call B<mprotect>()  on any address in a "
3767 "process's address space (except for the kernel vsyscall area).  In "
3768 "particular it can be used to change existing code mappings to be writable."
3769 msgstr ""
3770 "Linux では、(カーネル vsyscall 領域以外の)  任意のプロセスアドレス空間に対し"
3771 "て B<mprotect>()  を呼び出すことが、常に許されている。 これは特に既存のコード"
3772 "マッピングを書き込み可能にするために使われる。"
3773
3774 #. type: Plain text
3775 #: build/C/man2/mprotect.2:133
3776 msgid ""
3777 "Whether B<PROT_EXEC> has any effect different from B<PROT_READ> is "
3778 "architecture- and kernel version-dependent.  On some hardware architectures "
3779 "(e.g., i386), B<PROT_WRITE> implies B<PROT_READ>."
3780 msgstr ""
3781 "B<PROT_EXEC> が B<PROT_READ> と異なる影響を持つか否かは、アーキテクチャとカー"
3782 "ネルのバージョンに依存する。 (i386 などの) いくつかのアーキテクチャでは、 "
3783 "B<PROT_WRITE> をセットすると、暗黙のうちに B<PROT_READ> がセットされる。"
3784
3785 #. type: Plain text
3786 #: build/C/man2/mprotect.2:142
3787 msgid ""
3788 "POSIX.1-2001 says that an implementation may permit access other than that "
3789 "specified in I<prot>, but at a minimum can only allow write access if "
3790 "B<PROT_WRITE> has been set, and must not allow any access if B<PROT_NONE> "
3791 "has been set."
3792 msgstr ""
3793 "POSIX.1-2001 では、 I<prot> で指定されていないアクセスを許可する実装を認めて"
3794 "いる。 ただし、最低限、 B<PROT_WRITE> がセットされている場合にのみ書き込みア"
3795 "クセスが許可され、 B<PROT_NONE> がセットされている場合にはアクセスは許可され"
3796 "ない点だけは 満たす必要がある。"
3797
3798 #. type: Plain text
3799 #: build/C/man2/mprotect.2:148
3800 msgid ""
3801 "The program below allocates four pages of memory, makes the third of these "
3802 "pages read-only, and then executes a loop that walks upward through the "
3803 "allocated region modifying bytes."
3804 msgstr ""
3805 "以下のプログラムは、メモリページを 4つ確保し、そのうち 3番目のページを 読み込"
3806 "み専用に設定する。その後で、確保した領域のアドレスの小さい方から 大きな方に向"
3807 "かって順番にバイト値を変更するループを実行する。"
3808
3809 #. type: Plain text
3810 #: build/C/man2/mprotect.2:151
3811 msgid ""
3812 "An example of what we might see when running the program is the following:"
3813 msgstr "プログラムを実行した場合の一例を以下に示す。"
3814
3815 #. type: Plain text
3816 #: build/C/man2/mprotect.2:157
3817 #, no-wrap
3818 msgid ""
3819 "$B< ./a.out>\n"
3820 "Start of region:        0x804c000\n"
3821 "Got SIGSEGV at address: 0x804e000\n"
3822 msgstr ""
3823 "$B< ./a.out>\n"
3824 "Start of region:        0x804c000\n"
3825 "Got SIGSEGV at address: 0x804e000\n"
3826
3827 #. type: SS
3828 #: build/C/man2/mprotect.2:159
3829 #, no-wrap
3830 msgid "Program source"
3831 msgstr "プログラムのソース"
3832
3833 #. type: Plain text
3834 #: build/C/man2/mprotect.2:169
3835 #, no-wrap
3836 msgid ""
3837 "#include E<lt>unistd.hE<gt>\n"
3838 "#include E<lt>signal.hE<gt>\n"
3839 "#include E<lt>stdio.hE<gt>\n"
3840 "#include E<lt>malloc.hE<gt>\n"
3841 "#include E<lt>stdlib.hE<gt>\n"
3842 "#include E<lt>errno.hE<gt>\n"
3843 "#include E<lt>sys/mman.hE<gt>\n"
3844 msgstr ""
3845 "#include E<lt>unistd.hE<gt>\n"
3846 "#include E<lt>signal.hE<gt>\n"
3847 "#include E<lt>stdio.hE<gt>\n"
3848 "#include E<lt>malloc.hE<gt>\n"
3849 "#include E<lt>stdlib.hE<gt>\n"
3850 "#include E<lt>errno.hE<gt>\n"
3851 "#include E<lt>sys/mman.hE<gt>\n"
3852
3853 #. type: Plain text
3854 #: build/C/man2/mprotect.2:174
3855 #, no-wrap
3856 msgid "char *buffer;\n"
3857 msgstr "char *buffer;\n"
3858
3859 #. type: Plain text
3860 #: build/C/man2/mprotect.2:182
3861 #, no-wrap
3862 msgid ""
3863 "static void\n"
3864 "handler(int sig, siginfo_t *si, void *unused)\n"
3865 "{\n"
3866 "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
3867 "            (long) si-E<gt>si_addr);\n"
3868 "    exit(EXIT_FAILURE);\n"
3869 "}\n"
3870 msgstr ""
3871 "static void\n"
3872 "handler(int sig, siginfo_t *si, void *unused)\n"
3873 "{\n"
3874 "    printf(\"Got SIGSEGV at address: 0x%lx\\en\",\n"
3875 "            (long) si-E<gt>si_addr);\n"
3876 "    exit(EXIT_FAILURE);\n"
3877 "}\n"
3878
3879 #. type: Plain text
3880 #: build/C/man2/mprotect.2:189
3881 #, no-wrap
3882 msgid ""
3883 "int\n"
3884 "main(int argc, char *argv[])\n"
3885 "{\n"
3886 "    char *p;\n"
3887 "    int pagesize;\n"
3888 "    struct sigaction sa;\n"
3889 msgstr ""
3890 "int\n"
3891 "main(void)\n"
3892 "{\n"
3893 "    char *p;\n"
3894 "    int pagesize;\n"
3895 "    struct sigaction sa;\n"
3896
3897 #. type: Plain text
3898 #: build/C/man2/mprotect.2:195
3899 #, no-wrap
3900 msgid ""
3901 "    sa.sa_flags = SA_SIGINFO;\n"
3902 "    sigemptyset(&sa.sa_mask);\n"
3903 "    sa.sa_sigaction = handler;\n"
3904 "    if (sigaction(SIGSEGV, &sa, NULL) == -1)\n"
3905 "        handle_error(\"sigaction\");\n"
3906 msgstr ""
3907 "    sa.sa_flags = SA_SIGINFO;\n"
3908 "    sigemptyset(&sa.sa_mask);\n"
3909 "    sa.sa_sigaction = handler;\n"
3910 "    if (sigaction(SIGSEGV, &sa, NULL) == -1)\n"
3911 "        handle_error(\"sigaction\");\n"
3912
3913 #. type: Plain text
3914 #: build/C/man2/mprotect.2:199
3915 #, no-wrap
3916 msgid ""
3917 "    pagesize = sysconf(_SC_PAGE_SIZE);\n"
3918 "    if (pagesize == -1)\n"
3919 "        handle_error(\"sysconf\");\n"
3920 msgstr ""
3921 "    pagesize = sysconf(_SC_PAGE_SIZE);\n"
3922 "    if (pagesize == -1)\n"
3923 "        handle_error(\"sysconf\");\n"
3924
3925 #. type: Plain text
3926 #: build/C/man2/mprotect.2:202
3927 #, no-wrap
3928 msgid ""
3929 "    /* Allocate a buffer aligned on a page boundary;\n"
3930 "       initial protection is PROT_READ | PROT_WRITE */\n"
3931 msgstr ""
3932 "    /* Allocate a buffer aligned on a page boundary;\n"
3933 "       initial protection is PROT_READ | PROT_WRITE */\n"
3934
3935 #. type: Plain text
3936 #: build/C/man2/mprotect.2:206
3937 #, no-wrap
3938 msgid ""
3939 "    buffer = memalign(pagesize, 4 * pagesize);\n"
3940 "    if (buffer == NULL)\n"
3941 "        handle_error(\"memalign\");\n"
3942 msgstr ""
3943 "    buffer = memalign(pagesize, 4 * pagesize);\n"
3944 "    if (buffer == NULL)\n"
3945 "        handle_error(\"memalign\");\n"
3946
3947 #. type: Plain text
3948 #: build/C/man2/mprotect.2:208
3949 #, no-wrap
3950 msgid "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
3951 msgstr "    printf(\"Start of region:        0x%lx\\en\", (long) buffer);\n"
3952
3953 #. type: Plain text
3954 #: build/C/man2/mprotect.2:212
3955 #, no-wrap
3956 msgid ""
3957 "    if (mprotect(buffer + pagesize * 2, pagesize,\n"
3958 "                PROT_READ) == -1)\n"
3959 "        handle_error(\"mprotect\");\n"
3960 msgstr ""
3961 "    if (mprotect(buffer + pagesize * 2, pagesize,\n"
3962 "                PROT_READ) == -1)\n"
3963 "        handle_error(\"mprotect\");\n"
3964
3965 #. type: Plain text
3966 #: build/C/man2/mprotect.2:215
3967 #, no-wrap
3968 msgid ""
3969 "    for (p = buffer ; ; )\n"
3970 "        *(p++) = \\(aqa\\(aq;\n"
3971 msgstr ""
3972 "    for (p = buffer ; ; )\n"
3973 "        *(p++) = \\(aqa\\(aq;\n"
3974
3975 #. type: Plain text
3976 #: build/C/man2/mprotect.2:219
3977 #, no-wrap
3978 msgid ""
3979 "    printf(\"Loop completed\\en\");     /* Should never happen */\n"
3980 "    exit(EXIT_SUCCESS);\n"
3981 "}\n"
3982 msgstr ""
3983 "    printf(\"Loop completed\\en\");     /* Should never happen */\n"
3984 "    exit(EXIT_SUCCESS);\n"
3985 "}\n"
3986
3987 #. type: Plain text
3988 #: build/C/man2/mprotect.2:223
3989 msgid "B<mmap>(2), B<sysconf>(3)"
3990 msgstr "B<mmap>(2), B<sysconf>(3)"
3991
3992 #. type: TH
3993 #: build/C/man2/mremap.2:31
3994 #, no-wrap
3995 msgid "MREMAP"
3996 msgstr "MREMAP"
3997
3998 #. type: TH
3999 #: build/C/man2/mremap.2:31
4000 #, no-wrap
4001 msgid "2010-06-10"
4002 msgstr "2010-06-10"
4003
4004 #. type: Plain text
4005 #: build/C/man2/mremap.2:34
4006 msgid "mremap - remap a virtual memory address"
4007 msgstr "mremap - 仮想メモリ・アドレスを再マッピングする"
4008
4009 #. type: Plain text
4010 #: build/C/man2/mremap.2:37
4011 #, no-wrap
4012 msgid "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
4013 msgstr "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
4014
4015 #. type: Plain text
4016 #: build/C/man2/mremap.2:42
4017 #, no-wrap
4018 msgid ""
4019 "B<void *mremap(void *>I<old_address>B<, size_t >I<old_size>B<,>\n"
4020 "B<             size_t >I<new_size>B<, int >I<flags>B<, ... /* void *>I<new_address>B< */);>\n"
4021 msgstr ""
4022 "B<void *mremap(void *>I<old_address>B<, size_t >I<old_size>B<,>\n"
4023 "B<             size_t >I<new_size>B<, int >I<flags>B<, ... /* void *>I<new_address>B< */);>\n"
4024
4025 #. type: Plain text
4026 #: build/C/man2/mremap.2:48
4027 msgid ""
4028 "B<mremap>()  expands (or shrinks) an existing memory mapping, potentially "
4029 "moving it at the same time (controlled by the I<flags> argument and the "
4030 "available virtual address space)."
4031 msgstr ""
4032 "B<mremap>()  は既存のメモリ・マッピングの拡張 (または縮小) を行う。 同時に移"
4033 "動されることもある (I<flags> 引き数と利用可能な仮想アドレス空間によって決ま"
4034 "る)。"
4035
4036 #. type: Plain text
4037 #: build/C/man2/mremap.2:62
4038 msgid ""
4039 "I<old_address> is the old address of the virtual memory block that you want "
4040 "to expand (or shrink).  Note that I<old_address> has to be page aligned.  "
4041 "I<old_size> is the old size of the virtual memory block.  I<new_size> is the "
4042 "requested size of the virtual memory block after the resize.  An optional "
4043 "fifth argument, I<new_address>, may be provided; see the description of "
4044 "B<MREMAP_FIXED> below."
4045 msgstr ""
4046 "I<old_address> は拡張 (または縮小) しようとする仮想メモリ・ブロック の元のア"
4047 "ドレスである。I<old_address> はページ境界に合っていなければ ならない点に注意"
4048 "すること。I<old_size> は元の仮想メモリ・ブロックの サイズである。 "
4049 "I<new_size> は要求する変更後の仮想メモリ・ブロックのサイズである。 5 番目の引"
4050 "き数として I<new_address> を指定することができる。下記の B<MREMAP_FIXED> の説"
4051 "明を参照のこと。"
4052
4053 #. type: Plain text
4054 #: build/C/man2/mremap.2:74
4055 msgid ""
4056 "In Linux the memory is divided into pages.  A user process has (one or)  "
4057 "several linear virtual memory segments.  Each virtual memory segment has one "
4058 "or more mappings to real memory pages (in the page table).  Each virtual "
4059 "memory segment has its own protection (access rights), which may cause a "
4060 "segmentation violation if the memory is accessed incorrectly (e.g., writing "
4061 "to a read-only segment).  Accessing virtual memory outside of the segments "
4062 "will also cause a segmentation violation."
4063 msgstr ""
4064 "Linux ではメモリはページに分割される。ユーザー・プロセスは (一つまたは)  複数"
4065 "のリニアな仮想メモリセグメントを持つ。 それぞれの仮想メモリセグメントは一つ以"
4066 "上の実メモリ・ページ にマッピングされている (マッピング情報はページ・テーブル"
4067 "で管理される)。 仮想メモリセグメントにはセグメント毎の保護 (アクセス権) が設"
4068 "定されており、 メモリが不正にアクセスされた場合 (例えば読み込み専用のセグメン"
4069 "トに 書き込んだ場合)、セグメンテーション侵害 (segmentation violation) を 引き"
4070 "起こす。また、セグメント外の仮想メモリにアクセスした場合にも セグメンテーショ"
4071 "ン侵害が発生する。"
4072
4073 #. type: Plain text
4074 #: build/C/man2/mremap.2:82
4075 msgid ""
4076 "B<mremap>()  uses the Linux page table scheme.  B<mremap>()  changes the "
4077 "mapping between virtual addresses and memory pages.  This can be used to "
4078 "implement a very efficient B<realloc>(3)."
4079 msgstr ""
4080 "B<mremap>()  は Linux のページ・テーブル方式を使用する。 B<mremap>()  は仮想"
4081 "アドレスとメモリ・ページのマッピングを変更する。これは非常に効率的な "
4082 "B<realloc>(3)  を実装するのに使用されている。"
4083
4084 #. type: Plain text
4085 #: build/C/man2/mremap.2:84
4086 msgid "The I<flags> bit-mask argument may be 0, or include the following flag:"
4087 msgstr "I<flags> ビットマスク引数は 0 または以下のフラグを含む:"
4088
4089 #. type: TP
4090 #: build/C/man2/mremap.2:84
4091 #, no-wrap
4092 msgid "B<MREMAP_MAYMOVE>"
4093 msgstr "B<MREMAP_MAYMOVE>"
4094
4095 #. type: Plain text
4096 #: build/C/man2/mremap.2:96
4097 msgid ""
4098 "By default, if there is not sufficient space to expand a mapping at its "
4099 "current location, then B<mremap>()  fails.  If this flag is specified, then "
4100 "the kernel is permitted to relocate the mapping to a new virtual address, if "
4101 "necessary.  If the mapping is relocated, then absolute pointers into the old "
4102 "mapping location become invalid (offsets relative to the starting address of "
4103 "the mapping should be employed)."
4104 msgstr ""
4105 "デフォルトでは、現在の位置にマッピングを拡張するための 十分な空きがなければ "
4106 "B<mremap>()  は失敗する。 このフラグが指定されると、カーネルは必要があれば"
4107 "マッピングを 新しい仮想アドレスに再配置することができる マッピングが再配置さ"
4108 "れると、古いマッピング位置への絶対ポインタは 無効になる (マッピングの開始アド"
4109 "レスからの相対オフセットは有効のままである)。"
4110
4111 #. type: TP
4112 #: build/C/man2/mremap.2:96
4113 #, no-wrap
4114 msgid "B<MREMAP_FIXED> (since Linux 2.3.31)"
4115 msgstr "B<MREMAP_FIXED> (Linux 2.3.31 以降)"
4116
4117 #. type: Plain text
4118 #: build/C/man2/mremap.2:118
4119 msgid ""
4120 "This flag serves a similar purpose to the B<MAP_FIXED> flag of B<mmap>(2).  "
4121 "If this flag is specified, then B<mremap>()  accepts a fifth argument, "
4122 "I<void *new_address>, which specifies a page-aligned address to which the "
4123 "mapping must be moved.  Any previous mapping at the address range specified "
4124 "by I<new_address> and I<new_size> is unmapped.  If B<MREMAP_FIXED> is "
4125 "specified, then B<MREMAP_MAYMOVE> must also be specified."
4126 msgstr ""
4127 "このフラグは B<mmap>(2)  の B<MAP_FIXED> フラグと似たような目的で用いられ"
4128 "る。 このフラグが指定されると、 B<mremap>()  は 5 番目の引き数 I<void "
4129 "*new_address> を受け取り、この引数はマッピングが移動されるべきアドレスを指定"
4130 "する。 このアドレスはページ境界に合っていなければならない。 I<new_address> "
4131 "と I<new_size> で指定されるアドレス範囲に過去のマッピングがあった場合、 その"
4132 "マッピングはアンマップされる (unmapped)。 B<MREMAP_FIXED> を指定した場合は、 "
4133 "B<MREMAP_MAYMOVE> も指定しなければならない。"
4134
4135 #. type: Plain text
4136 #: build/C/man2/mremap.2:128
4137 msgid ""
4138 "If the memory segment specified by I<old_address> and I<old_size> is locked "
4139 "(using B<mlock>(2)  or similar), then this lock is maintained when the "
4140 "segment is resized and/or relocated.  As a consequence, the amount of memory "
4141 "locked by the process may change."
4142 msgstr ""
4143 "I<old_address> と I<old_size> で指定されるメモリセグメントが (B<mlock>(2)  や"
4144 "同様のもので) ロックされている場合、セグメントのサイズが変わったり 再配置され"
4145 "たりした時にロックも維持される。 その結果、プロセスによってロックされるメモリ"
4146 "の量は変化する。"
4147
4148 #. type: Plain text
4149 #: build/C/man2/mremap.2:136
4150 msgid ""
4151 "On success B<mremap>()  returns a pointer to the new virtual memory area.  "
4152 "On error, the value B<MAP_FAILED> (that is, I<(void\\ *)\\ -1>) is returned, "
4153 "and I<errno> is set appropriately."
4154 msgstr ""
4155 "成功した場合は B<mremap>()  は新しい仮想メモリ領域へのポインタを返す。 エラー"
4156 "の場合は B<MAP_FAILED> (すなわち I<(void\\ *)\\ -1>) が返され、 I<errno> が適"
4157 "切に設定される。"
4158
4159 #. type: Plain text
4160 #: build/C/man2/mremap.2:143
4161 msgid ""
4162 "The caller tried to expand a memory segment that is locked, but this was not "
4163 "possible without exceeding the B<RLIMIT_MEMLOCK> resource limit."
4164 msgstr ""
4165 "呼び出し元がロックされているメモリセグメントを拡張しようとしたが、 "
4166 "B<RLIMIT_MEMLOCK> リソース制限を越えずにこれを行うことができない。"
4167
4168 #. type: Plain text
4169 #: build/C/man2/mremap.2:152
4170 msgid ""
4171 "\"Segmentation fault.\" Some address in the range I<old_address> to "
4172 "I<old_address>+I<old_size> is an invalid virtual memory address for this "
4173 "process.  You can also get B<EFAULT> even if there exist mappings that cover "
4174 "the whole address space requested, but those mappings are of different types."
4175 msgstr ""
4176 "「セグメンテーション違反(segmentation fault)」 I<old_address> から "
4177 "I<old_address>+I<old_size> の 範囲のアドレスのどれかがこのプロセスにおいて不"
4178 "正な仮想メモリ・アドレスである。 たとえ要求したアドレス空間全体を含むような"
4179 "マッピングがあったとしても、 それらのマッピングが異なった型ならば B<EFAULT> "
4180 "を受け取るだろう。"
4181
4182 #. type: Plain text
4183 #: build/C/man2/mremap.2:180
4184 msgid ""
4185 "An invalid argument was given.  Possible causes are: I<old_address> was not "
4186 "page aligned; a value other than B<MREMAP_MAYMOVE> or B<MREMAP_FIXED> was "
4187 "specified in I<flags>; I<new_size> was zero; I<new_size> or I<new_address> "
4188 "was invalid; or the new address range specified by I<new_address> and "
4189 "I<new_size> overlapped the old address range specified by I<old_address> and "
4190 "I<old_size>; or B<MREMAP_FIXED> was specified without also specifying "
4191 "B<MREMAP_MAYMOVE>."
4192 msgstr ""
4193 "不正な引き数が与えられた。 可能性のある原因は以下の通りである: たいていは "
4194 "I<old_address> がページ境界に 合ってない; I<flags> に B<MREMAP_MAYMOVE> また"
4195 "は B<MREMAP_FIXED> 以外の値が指定されている; I<new_size> がゼロ; I<new_size> "
4196 "または I<new_address> の値が不正; I<new_address> と I<new_size> で指定される"
4197 "新しいアドレス範囲が I<old_address> と I<old_size> で指定される古いアドレス範"
4198 "囲と重なっている; B<MREMAP_FIXED> が指定されているが B<MREMAP_MAYMOVE> が指定"
4199 "されていない。"
4200
4201 #. type: Plain text
4202 #: build/C/man2/mremap.2:186
4203 msgid ""
4204 "The memory area cannot be expanded at the current virtual address, and the "
4205 "B<MREMAP_MAYMOVE> flag is not set in I<flags>.  Or, there is not enough "
4206 "(virtual) memory available."
4207 msgstr ""
4208 "現在の仮想アドレスではメモリ領域が拡張できず、 B<MREMAP_MAYMOVE> フラグが "
4209 "I<flags> に設定されていない。 または十分な (仮想) メモリが存在しない。"
4210
4211 #.  4.2BSD had a (never actually implemented)
4212 #.  .BR mremap (2)
4213 #.  call with completely different semantics.
4214 #. type: Plain text
4215 #: build/C/man2/mremap.2:192
4216 msgid ""
4217 "This call is Linux-specific, and should not be used in programs intended to "
4218 "be portable."
4219 msgstr ""
4220 "このコールは Linux 特有であり、移植を意図したプログラムで 使用すべきではな"
4221 "い。"
4222
4223 #. type: Plain text
4224 #: build/C/man2/mremap.2:200
4225 msgid ""
4226 "Prior to version 2.4, glibc did not expose the definition of "
4227 "B<MREMAP_FIXED>, and the prototype for B<mremap>()  did not allow for the "
4228 "I<new_address> argument."
4229 msgstr ""
4230 "バージョン 2.4 より前の glibc では、 B<MREMAP_FIXED> の定義は公開されておら"
4231 "ず、 B<mremap>()  のプロトタイプは I<new_address> 引き数を取らなかった。"
4232
4233 #. type: Plain text
4234 #: build/C/man2/mremap.2:209
4235 msgid ""
4236 "B<brk>(2), B<getpagesize>(2), B<getrlimit>(2), B<mlock>(2), B<mmap>(2), "
4237 "B<sbrk>(2), B<malloc>(3), B<realloc>(3)"
4238 msgstr ""
4239 "B<brk>(2), B<getpagesize>(2), B<getrlimit>(2), B<mlock>(2), B<mmap>(2), "
4240 "B<sbrk>(2), B<realloc>(3), B<malloc>(3)"
4241
4242 #. type: Plain text
4243 #: build/C/man2/mremap.2:214
4244 #, fuzzy
4245 #| msgid ""
4246 #| "Your favorite OS text book for more information on paged memory.  "
4247 #| "(I<Modern Operating Systems> by Andrew S. Tannenbaum, I<Inside Linux> by "
4248 #| "Randolf Bentson, I<The Design of the UNIX Operating System> by Maurice J. "
4249 #| "Bach.)"
4250 msgid ""
4251 "Your favorite OS text book for more information on paged memory.  (I<Modern "
4252 "Operating Systems> by Andrew S. Tanenbaum, I<Inside Linux> by Randolf "
4253 "Bentson, I<The Design of the UNIX Operating System> by Maurice J. Bach.)"
4254 msgstr ""
4255 "ページ分割されたメモリについてもっと詳しく知りたいならば あなたの好みの OS の"
4256 "教科書を参照すること。 (I<Modern Operating Systems> by Andrew S. Tannenbaum, "
4257 "I<Inside Linux> by Randolf Bentson, I<The Design of the UNIX Operating "
4258 "System> by Maurice J. Bach.)"
4259
4260 #. type: TH
4261 #: build/C/man2/msync.2:25
4262 #, no-wrap
4263 msgid "MSYNC"
4264 msgstr "MSYNC"
4265
4266 #. type: Plain text
4267 #: build/C/man2/msync.2:28
4268 msgid "msync - synchronize a file with a memory map"
4269 msgstr "msync - ファイルをマップしたメモリと同期させる"
4270
4271 #. type: Plain text
4272 #: build/C/man2/msync.2:32
4273 msgid "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
4274 msgstr "B<int msync(void *>I<addr>B<, size_t >I<length>B<, int >I<flags>B<);>"
4275
4276 #. type: Plain text
4277 #: build/C/man2/msync.2:48
4278 msgid ""
4279 "B<msync>()  flushes changes made to the in-core copy of a file that was "
4280 "mapped into memory using B<mmap>(2)  back to disk.  Without use of this call "
4281 "there is no guarantee that changes are written back before B<munmap>(2)  is "
4282 "called.  To be more precise, the part of the file that corresponds to the "
4283 "memory area starting at I<addr> and having length I<length> is updated."
4284 msgstr ""
4285 "B<msync>()  は B<mmap>(2)  を使ってメモリにマップされたファイルの、 メモリ上"
4286 "のコピーになされた変更をディスクに反映させる。 この関数を使用しないと、 "
4287 "B<munmap>(2)  が呼び出されるまで変更が書き戻される保証はない。 より正確には、"
4288 "ファイルのうち I<addr> から始まり長さ I<length> のメモリ領域に対応する部分が"
4289 "更新される。"
4290
4291 #. type: Plain text
4292 #: build/C/man2/msync.2:68
4293 msgid ""
4294 "The I<flags> argument may have the bits B<MS_ASYNC>, B<MS_SYNC>, and "
4295 "B<MS_INVALIDATE> set, but not both B<MS_ASYNC> and B<MS_SYNC>.  B<MS_ASYNC> "
4296 "specifies that an update be scheduled, but the call returns immediately.  "
4297 "B<MS_SYNC> asks for an update and waits for it to complete.  "
4298 "B<MS_INVALIDATE> asks to invalidate other mappings of the same file (so that "
4299 "they can be updated with the fresh values just written)."
4300 msgstr ""
4301 "I<flags> 引数にはビット B<MS_ASYNC>, B<MS_SYNC>, B<MS_INVALIDATE> を設定する"
4302 "ことができるが、 B<MS_ASYNC> と B<MS_SYNC> を同時に指定することはできない。 "
4303 "B<MS_ASYNC> は更新を予定に組み込むことを表し、呼び出しは直ちに返る。 "
4304 "B<MS_SYNC> は更新を要求し、更新が完了するまで待つ。 B<MS_INVALIDATE> は(たっ"
4305 "た今書き込んだ新しい値でマッピングを更新することができるように)  同じファイル"
4306 "に対する他のマッピングを無効にすることを要求する。"
4307
4308 #. type: Plain text
4309 #: build/C/man2/msync.2:73
4310 msgid ""
4311 "On success, zero is returned.  On error, -1 is returned, and I<errno> is set "
4312 "appropriately."
4313 msgstr ""
4314 "成功した場合、 0 が返る。エラーの場合、 -1 が返り、 I<errno> が適切に設定され"
4315 "る。"
4316
4317 #. type: TP
4318 #: build/C/man2/msync.2:74
4319 #, no-wrap
4320 msgid "B<EBUSY>"
4321 msgstr "B<EBUSY>"
4322
4323 #. type: Plain text
4324 #: build/C/man2/msync.2:80
4325 msgid ""
4326 "B<MS_INVALIDATE> was specified in I<flags>, and a memory lock exists for the "
4327 "specified address range."
4328 msgstr ""
4329 "I flags に B<MS_INVALIDATE> が指定されたが、指定されたアドレス範囲にロックが"
4330 "存在する。"
4331
4332 #. type: Plain text
4333 #: build/C/man2/msync.2:93
4334 msgid ""
4335 "I<addr> is not a multiple of PAGESIZE; or any bit other than B<MS_ASYNC> | "
4336 "B<MS_INVALIDATE> | B<MS_SYNC> is set in I<flags>; or both B<MS_SYNC> and "
4337 "B<MS_ASYNC> are set in I<flags>."
4338 msgstr ""
4339 "I<addr> が PAGESIZE の倍数でない。または、 I<flags> に B<MS_ASYNC>、"
4340 "B<MS_INVALIDATE>、B<MS_SYNC> 以外のビットが設定された。 または、 I<flags> に "
4341 "B<MS_SYNC> と B<MS_ASYNC> の両方が設定された。"
4342
4343 #. type: Plain text
4344 #: build/C/man2/msync.2:96
4345 msgid "The indicated memory (or part of it) was not mapped."
4346 msgstr "指定されたメモリ (またはその一部) がマップされていない。"
4347
4348 #. type: Plain text
4349 #: build/C/man2/msync.2:98 build/C/man3/posix_fallocate.3:103
4350 #: build/C/man3/shm_open.3:251 build/C/man7/shm_overview.7:103
4351 msgid "POSIX.1-2001."
4352 msgstr "POSIX.1-2001."
4353
4354 #. type: Plain text
4355 #: build/C/man2/msync.2:105
4356 msgid ""
4357 "This call was introduced in Linux 1.3.21, and then used B<EFAULT> instead of "
4358 "B<ENOMEM>.  In Linux 2.4.19 this was changed to the POSIX value B<ENOMEM>."
4359 msgstr ""
4360 "この関数は Linux 1.3.21 で導入されたが、 B<ENOMEM> ではなく B<EFAULT> が使わ"
4361 "れていた。 これは Linux 2.4.19 で POSIX における値 B<ENOMEM> に変更された。"
4362
4363 #.  POSIX.1-2001: It shall be defined to -1 or 0 or 200112L.
4364 #.  -1: unavailable, 0: ask using sysconf().
4365 #.  glibc defines them to 1.
4366 #. type: Plain text
4367 #: build/C/man2/msync.2:118
4368 msgid ""
4369 "On POSIX systems on which B<msync>()  is available, both "
4370 "B<_POSIX_MAPPED_FILES> and B<_POSIX_SYNCHRONIZED_IO> are defined in "
4371 "I<E<lt>unistd.hE<gt>> to a value greater than 0.  (See also B<sysconf>(3).)"
4372 msgstr ""
4373 "B<msync>()  が使用可能な POSIX システムでは B<_POSIX_MAPPED_FILES> と "
4374 "B<_POSIX_SYNCHRONIZED_IO> の両方が I<E<lt>unistd.hE<gt>> で 0 より大きい値に"
4375 "定義される。 (B<sysconf>(3)  を参照すること。 )"
4376
4377 #. type: TP
4378 #: build/C/man2/msync.2:120 build/C/man7/shm_overview.7:46
4379 #, no-wrap
4380 msgid "B<mmap>(2)"
4381 msgstr "B<mmap>(2)"
4382
4383 #. type: TH
4384 #: build/C/man3/mtrace.3:4
4385 #, no-wrap
4386 msgid "MTRACE"
4387 msgstr "MTRACE"
4388
4389 #. type: TH
4390 #: build/C/man3/mtrace.3:4
4391 #, no-wrap
4392 msgid "2002-07-20"
4393 msgstr "2002-07-20"
4394
4395 #. type: Plain text
4396 #: build/C/man3/mtrace.3:7
4397 msgid "mtrace, muntrace - malloc debugging"
4398 msgstr "mtrace, muntrace - malloc debugging"
4399
4400 #. type: Plain text
4401 #: build/C/man3/mtrace.3:9
4402 msgid "B<#include E<lt>mcheck.hE<gt>>"
4403 msgstr "B<#include E<lt>mcheck.hE<gt>>"
4404
4405 #. type: Plain text
4406 #: build/C/man3/mtrace.3:11
4407 msgid "B<void mtrace(void);>"
4408 msgstr "B<void mtrace(void);>"
4409
4410 #. type: Plain text
4411 #: build/C/man3/mtrace.3:13
4412 msgid "B<void muntrace(void);>"
4413 msgstr "B<void muntrace(void);>"
4414
4415 #. type: Plain text
4416 #: build/C/man3/mtrace.3:24
4417 msgid ""
4418 "The function B<mtrace>()  installs handlers for B<malloc>(3), B<realloc>(3)  "
4419 "and B<free>(3).  The function B<muntrace>()  disables these handlers."
4420 msgstr ""
4421 "関数 B<mtrace>()  は、 B<malloc>(3), B<realloc>(3), B<free>(3)  のハンドラを"
4422 "組み込む。 関数 B<muntrace>()  はこれらのハンドラを解除する。"
4423
4424 #. type: Plain text
4425 #: build/C/man3/mtrace.3:34
4426 msgid ""
4427 "The environment variable B<MALLOC_TRACE> defines a file where B<mtrace>()  "
4428 "writes its output.  This file must be writable to the user or B<mtrace>()  "
4429 "will do nothing.  If the file is not empty it will be truncated."
4430 msgstr ""
4431 "環境変数 B<MALLOC_TRACE> は B<mtrace>()  が出力を書き出すファイルを指定す"
4432 "る。 ユーザが書き込み権限を持つファイルを指定しなければならない。 書き込み権"
4433 "限がない場合、 B<mtrace>()  は何もしない。 ファイルが空でない場合、ファイルの"
4434 "元の内容を上書きする。"
4435
4436 #. type: Plain text
4437 #: build/C/man3/mtrace.3:36
4438 msgid "These are GNU extensions."
4439 msgstr "この関数は GNU 拡張である。"
4440
4441 #. type: Plain text
4442 #: build/C/man3/mtrace.3:41
4443 msgid ""
4444 "The output of B<mtrace>()  will be ASCII but not in a friendly format.  So "
4445 "glibc comes with a perl-script called mtrace to make sense of it."
4446 msgstr ""
4447 "B<mtrace>()  の出力は ASCII 形式だが、人が読みやすいフォーマットではない。 そ"
4448 "こで、glibc には mtrace 出力を分かりやすい形式に変換する perl スクリプトが付"
4449 "属している。"
4450
4451 #. type: Plain text
4452 #: build/C/man3/mtrace.3:44
4453 msgid "B<malloc>(3), B<malloc_hook>(3)"
4454 msgstr "B<malloc>(3), B<malloc_hook>(3)"
4455
4456 #. type: TH
4457 #: build/C/man2/posix_fadvise.2:27
4458 #, no-wrap
4459 msgid "POSIX_FADVISE"
4460 msgstr "POSIX_FADVISE"
4461
4462 #. type: TH
4463 #: build/C/man2/posix_fadvise.2:27 build/C/man2/sync_file_range.2:30
4464 #, fuzzy, no-wrap
4465 #| msgid "2010-10-30"
4466 msgid "2010-10-09"
4467 msgstr "2010-10-30"
4468
4469 #. type: Plain text
4470 #: build/C/man2/posix_fadvise.2:30
4471 msgid "posix_fadvise - predeclare an access pattern for file data"
4472 msgstr "posix_fadvise - ファイルデータのアクセスパターンをあらかじめ宣言する"
4473
4474 #. type: Plain text
4475 #: build/C/man2/posix_fadvise.2:33 build/C/man3/posix_fallocate.3:29
4476 #, no-wrap
4477 msgid "B<#include E<lt>fcntl.hE<gt>>\n"
4478 msgstr "B<#include E<lt>fcntl.hE<gt>>\n"
4479
4480 #. type: Plain text
4481 #: build/C/man2/posix_fadvise.2:36
4482 #, no-wrap
4483 msgid "B<int posix_fadvise(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<, int >I<advice>B<);>\n"
4484 msgstr "B<int posix_fadvise(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<, int >I<advice>B<);>\n"
4485
4486 #. type: Plain text
4487 #: build/C/man2/posix_fadvise.2:45
4488 #, fuzzy
4489 #| msgid "B<posix_fallocate>():"
4490 msgid "B<posix_fadvise>():"
4491 msgstr "B<posix_fallocate>():"
4492
4493 #. type: Plain text
4494 #: build/C/man2/posix_fadvise.2:47 build/C/man3/posix_fallocate.3:42
4495 msgid "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
4496 msgstr "_XOPEN_SOURCE\\ E<gt>=\\ 600 || _POSIX_C_SOURCE\\ E<gt>=\\ 200112L"
4497
4498 #. type: Plain text
4499 #: build/C/man2/posix_fadvise.2:55
4500 msgid ""
4501 "Programs can use B<posix_fadvise>()  to announce an intention to access file "
4502 "data in a specific pattern in the future, thus allowing the kernel to "
4503 "perform appropriate optimizations."
4504 msgstr ""
4505 "プログラムは、将来特定のパターンでファイルデータに アクセスする意思を伝えるた"
4506 "めに B<posix_fadvise>()  を使うことができる。 これにより、カーネルが適切な最"
4507 "適化を実行することが可能になる。"
4508
4509 #. type: Plain text
4510 #: build/C/man2/posix_fadvise.2:62
4511 #, fuzzy
4512 #| msgid ""
4513 #| "The I<advice> applies to a (not necessarily existent) region starting at "
4514 #| "I<offset> and extending for I<len> bytes (or until the end of the file if "
4515 #| "I<len> is 0) within the file referred to by I<fd>.  The advice is not "
4516 #| "binding; it merely constitutes an expectation on behalf of the "
4517 #| "application."
4518 msgid ""
4519 "The I<advice> applies to a (not necessarily existent) region starting at "
4520 "I<offset> and extending for I<len> bytes (or until the end of the file if "
4521 "I<len> is 0) within the file referred to by I<fd>.  The I<advice> is not "
4522 "binding; it merely constitutes an expectation on behalf of the application."
4523 msgstr ""
4524 "I<advice> は I<fd> が参照しているファイルの I<offset> から始まる I<len> バイ"
4525 "トの範囲内 (I<len> が 0 の場合はファイルの終りまで) の (必ずしも存在しない) "
4526 "領域に適用される。 アドバイスは義務づけではない。 アドバイスは単にアプリケー"
4527 "ションのために可能性を構成するだけである。"
4528
4529 #. type: Plain text
4530 #: build/C/man2/posix_fadvise.2:64
4531 msgid "Permissible values for I<advice> include:"
4532 msgstr "I<advice> に許される値には、以下のものが含まれる:"
4533
4534 #. type: TP
4535 #: build/C/man2/posix_fadvise.2:64
4536 #, no-wrap
4537 msgid "B<POSIX_FADV_NORMAL>"
4538 msgstr "B<POSIX_FADV_NORMAL>"
4539
4540 #. type: Plain text
4541 #: build/C/man2/posix_fadvise.2:70
4542 msgid ""
4543 "Indicates that the application has no advice to give about its access "
4544 "pattern for the specified data.  If no advice is given for an open file, "
4545 "this is the default assumption."
4546 msgstr ""
4547 "指定されたデータのアクセスパターンを指示するアドバイスを アプリケーションが何"
4548 "も持っていないことを示す。 オープンされたファイルにアドバイスが指定されない場"
4549 "合、 これがデフォルトで仮定される。"
4550
4551 #. type: TP
4552 #: build/C/man2/posix_fadvise.2:70
4553 #, no-wrap
4554 msgid "B<POSIX_FADV_SEQUENTIAL>"
4555 msgstr "B<POSIX_FADV_SEQUENTIAL>"
4556
4557 #. type: Plain text
4558 #: build/C/man2/posix_fadvise.2:74
4559 msgid ""
4560 "The application expects to access the specified data sequentially (with "
4561 "lower offsets read before higher ones)."
4562 msgstr ""
4563 "アプリケーションは指定されたデータがシーケンシャルに (大きなオフセットの前に"
4564 "小さなオフセットのデータを読むように)  アクセスされることを期待する。"
4565
4566 #. type: TP
4567 #: build/C/man2/posix_fadvise.2:74
4568 #, no-wrap
4569 msgid "B<POSIX_FADV_RANDOM>"
4570 msgstr "B<POSIX_FADV_RANDOM>"
4571
4572 #. type: Plain text
4573 #: build/C/man2/posix_fadvise.2:77
4574 msgid "The specified data will be accessed in random order."
4575 msgstr "指定されたデータがランダムな順番でアクセスされる。"
4576
4577 #. type: TP
4578 #: build/C/man2/posix_fadvise.2:77
4579 #, no-wrap
4580 msgid "B<POSIX_FADV_NOREUSE>"
4581 msgstr "B<POSIX_FADV_NOREUSE>"
4582
4583 #. type: Plain text
4584 #: build/C/man2/posix_fadvise.2:80
4585 msgid "The specified data will be accessed only once."
4586 msgstr "指定されたデータは 1 度しかアクセスされない。"
4587
4588 #. type: TP
4589 #: build/C/man2/posix_fadvise.2:80
4590 #, no-wrap
4591 msgid "B<POSIX_FADV_WILLNEED>"
4592 msgstr "B<POSIX_FADV_WILLNEED>"
4593
4594 #. type: Plain text
4595 #: build/C/man2/posix_fadvise.2:83
4596 msgid "The specified data will be accessed in the near future."
4597 msgstr "指定されたデータは近い将来アクセスされる。"
4598
4599 #. type: TP
4600 #: build/C/man2/posix_fadvise.2:83
4601 #, no-wrap
4602 msgid "B<POSIX_FADV_DONTNEED>"
4603 msgstr "B<POSIX_FADV_DONTNEED>"
4604
4605 #. type: Plain text
4606 #: build/C/man2/posix_fadvise.2:86
4607 msgid "The specified data will not be accessed in the near future."
4608 msgstr "指定されたデータは近い将来アクセスされない。"
4609
4610 #. type: Plain text
4611 #: build/C/man2/posix_fadvise.2:89
4612 msgid "On success, zero is returned.  On error, an error number is returned."
4613 msgstr "成功した場合は 0 が返される。 失敗した場合はエラー番号が返される。"
4614
4615 #. type: Plain text
4616 #: build/C/man2/posix_fadvise.2:93
4617 msgid "The I<fd> argument was not a valid file descriptor."
4618 msgstr "I<fd> 引き数が有効なファイルディスクリプタでない。"
4619
4620 #. type: Plain text
4621 #: build/C/man2/posix_fadvise.2:96
4622 msgid "An invalid value was specified for I<advice>."
4623 msgstr "無効な値が I<advice> に指定された。"
4624
4625 #. type: Plain text
4626 #: build/C/man2/posix_fadvise.2:103
4627 msgid ""
4628 "The specified file descriptor refers to a pipe or FIFO.  (Linux actually "
4629 "returns B<EINVAL> in this case.)"
4630 msgstr ""
4631 "指定されたファイルディスクリプタがパイプまたは FIFO を参照している (この場"
4632 "合、Linux は実際には B<EINVAL> を返す)。"
4633
4634 #.  of fadvise64_64()
4635 #. type: Plain text
4636 #: build/C/man2/posix_fadvise.2:111
4637 msgid ""
4638 "Kernel support first appeared in Linux 2.5.60; the underlying system call is "
4639 "called B<fadvise64>().  Library support has been provided since glibc "
4640 "version 2.2, via the wrapper function B<posix_fadvise>()."
4641 msgstr ""
4642
4643 #. type: Plain text
4644 #: build/C/man2/posix_fadvise.2:120
4645 msgid ""
4646 "POSIX.1-2001.  Note that the type of the I<len> argument was changed from "
4647 "I<size_t> to I<off_t> in POSIX.1-2003 TC1."
4648 msgstr ""
4649 "POSIX.1-2001.  I<len> 引き数の型が POSIX.1-2003 TC1 において I<size_t> から "
4650 "I<off_t> に変更された点に注意すること。"
4651
4652 #. type: Plain text
4653 #: build/C/man2/posix_fadvise.2:126
4654 msgid ""
4655 "Under Linux, B<POSIX_FADV_NORMAL> sets the readahead window to the default "
4656 "size for the backing device; B<POSIX_FADV_SEQUENTIAL> doubles this size, and "
4657 "B<POSIX_FADV_RANDOM> disables file readahead entirely.  These changes affect "
4658 "the entire file, not just the specified region (but other open file handles "
4659 "to the same file are unaffected)."
4660 msgstr ""
4661 "Linux では、B<POSIX_FADV_NORMAL> はバッキングデバイスの デフォルトサイズに先"
4662 "読み (readahead) ウインドウを設定する。 B<POSIX_FADV_SEQUENTIAL> はこのサイズ"
4663 "を 2 倍し、 B<POSIX_FADV_RANDOM> は先読みを全く無効にする。 これらの変更は"
4664 "ファイル全体に影響し、指定された領域のみに影響するわけではない (しかし同じ"
4665 "ファイルに対する他のオープンファイルハンドルは影響を受けない)。"
4666
4667 #. type: Plain text
4668 #: build/C/man2/posix_fadvise.2:133
4669 msgid ""
4670 "B<POSIX_FADV_WILLNEED> initiates a nonblocking read of the specified region "
4671 "into the page cache.  The amount of data read may be decreased by the kernel "
4672 "depending on virtual memory load.  (A few megabytes will usually be fully "
4673 "satisfied, and more is rarely useful.)"
4674 msgstr ""
4675 "B<POSIX_FADV_WILLNEED> は、 ページキャッシュに指定領域のブロックされない読み"
4676 "込みを開始する。 読み込まれるデータの総量は、 仮想メモリの負荷に依ってカーネ"
4677 "ルが減らすかもしれない (数メガバイトであれば通常は全く十分であり、 それより多"
4678 "くてもめったに役に立たない)。"
4679
4680 #. type: Plain text
4681 #: build/C/man2/posix_fadvise.2:137
4682 msgid ""
4683 "In kernels before 2.6.18, B<POSIX_FADV_NOREUSE> had the same semantics as "
4684 "B<POSIX_FADV_WILLNEED>.  This was probably a bug; since kernel 2.6.18, this "
4685 "flag is a no-op."
4686 msgstr ""
4687 "2.6.18 より前のカーネルでは、B<POSIX_FADV_NOREUSE> は B<POSIX_FADV_WILLNEED> "
4688 "と同じ意味であった。 これは多分バグであった。 カーネル 2.6.18 以降では、この"
4689 "フラグは何も行わない。"
4690
4691 #. type: Plain text
4692 #: build/C/man2/posix_fadvise.2:145
4693 msgid ""
4694 "B<POSIX_FADV_DONTNEED> attempts to free cached pages associated with the "
4695 "specified region.  This is useful, for example, while streaming large "
4696 "files.  A program may periodically request the kernel to free cached data "
4697 "that has already been used, so that more useful cached pages are not "
4698 "discarded instead."
4699 msgstr ""
4700 "B<POSIX_FADV_DONTNEED> は指定された領域に関連付けられた キャッシュページを解"
4701 "放しようとする。 例えば、これは大きなファイルをストリーミングするときに役立"
4702 "つ。 プログラムは、使用済みのキャッシュされたデータを解放するように、 定期的"
4703 "にカーネルに要求するかもしれない。 そうすることにより、さらに有効なキャッシュ"
4704 "されたページが、 代わりに破棄されることはない。"
4705
4706 #. type: Plain text
4707 #: build/C/man2/posix_fadvise.2:153
4708 msgid ""
4709 "Pages that have not yet been written out will be unaffected, so if the "
4710 "application wishes to guarantee that pages will be released, it should call "
4711 "B<fsync>(2)  or B<fdatasync>(2)  first."
4712 msgstr ""
4713 "まだ書き出されていないページは影響を受けないので、 そのページの解放が保証され"
4714 "ることをアプリケーションが望んでいるなら、 最初に B<fsync>(2)  または "
4715 "B<fdatasync>(2)  を呼ぶべきである。"
4716
4717 #. type: SS
4718 #: build/C/man2/posix_fadvise.2:153
4719 #, no-wrap
4720 msgid "arm_fadvise()"
4721 msgstr ""
4722
4723 #. type: Plain text
4724 #: build/C/man2/posix_fadvise.2:165
4725 msgid ""
4726 "The ARM architecture needs 64-bit arguments to be aligned in a suitable pair "
4727 "of registers.  On this architecture, the call signature of B<posix_fadvise>"
4728 "()  is flawed, since it forces a register to be wasted as padding between "
4729 "the I<fd> and I<len> arguments.  Therefore, since Linux 2.6.14, ARM defines "
4730 "a different system call that orders the arguments suitably:"
4731 msgstr ""
4732
4733 #. type: Plain text
4734 #: build/C/man2/posix_fadvise.2:170
4735 #, fuzzy, no-wrap
4736 #| msgid "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
4737 msgid ""
4738 "B<long arm_fadvise64_64(int >I<fd>B<, int >I<advice>B<,>\n"
4739 "B<                      loff_t >I<offset>B<, loff_t >I<len>B<);>\n"
4740 msgstr "B<int fallocate(int >I<fd>B<, int >I<mode>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
4741
4742 #.  No ARM support in glibc.
4743 #. type: Plain text
4744 #: build/C/man2/posix_fadvise.2:177
4745 msgid ""
4746 "The behavior of this system call is otherwise exactly the same as "
4747 "B<posix_fadvise>().  No library support is provided for this system call in "
4748 "glibc."
4749 msgstr ""
4750
4751 #. type: Plain text
4752 #: build/C/man2/posix_fadvise.2:182
4753 msgid ""
4754 "In kernels before 2.6.6, if I<len> was specified as 0, then this was "
4755 "interpreted literally as \"zero bytes\", rather than as meaning \"all bytes "
4756 "through to the end of the file\"."
4757 msgstr ""
4758 "2.6.6 より前のカーネルでは、 I<len> に 0 が指定された場合、 「ファイルの終り"
4759 "までの全てのバイト」という意味ではなく、 文字通り「0 バイト」として解釈されて"
4760 "いた。"
4761
4762 #.  FIXME . Write a posix_fadvise(3) page.
4763 #. type: Plain text
4764 #: build/C/man2/posix_fadvise.2:188
4765 #, fuzzy
4766 #| msgid ""
4767 #| "B<readahead>(2), B<posix_fallocate>(3), B<posix_madvise>(3), "
4768 #| "B<feature_test_macros>(7)"
4769 msgid ""
4770 "B<readahead>(2), B<sync_file_range>(2), B<posix_fallocate>(3), "
4771 "B<posix_madvise>(3)"
4772 msgstr "B<readahead>(2), B<posix_fallocate>(3), B<posix_madvise>(3)"
4773
4774 #. type: TH
4775 #: build/C/man3/posix_fallocate.3:23
4776 #, no-wrap
4777 msgid "POSIX_FALLOCATE"
4778 msgstr "POSIX_FALLOCATE"
4779
4780 #. type: TH
4781 #: build/C/man3/posix_fallocate.3:23 build/C/man3/posix_memalign.3:26
4782 #, no-wrap
4783 msgid "2010-09-20"
4784 msgstr "2010-09-20"
4785
4786 #. type: Plain text
4787 #: build/C/man3/posix_fallocate.3:26
4788 msgid "posix_fallocate - allocate file space"
4789 msgstr "posix_fallocate - ファイルのスペースを確保する"
4790
4791 #. type: Plain text
4792 #: build/C/man3/posix_fallocate.3:31
4793 #, no-wrap
4794 msgid "B<int posix_fallocate(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
4795 msgstr "B<int posix_fallocate(int >I<fd>B<, off_t >I<offset>B<, off_t >I<len>B<);>\n"
4796
4797 #. type: Plain text
4798 #: build/C/man3/posix_fallocate.3:40
4799 msgid "B<posix_fallocate>():"
4800 msgstr "B<posix_fallocate>():"
4801
4802 #. type: Plain text
4803 #: build/C/man3/posix_fallocate.3:59
4804 msgid ""
4805 "The function B<posix_fallocate>()  ensures that disk space is allocated for "
4806 "the file referred to by the descriptor I<fd> for the bytes in the range "
4807 "starting at I<offset> and continuing for I<len> bytes.  After a successful "
4808 "call to B<posix_fallocate>(), subsequent writes to bytes in the specified "
4809 "range are guaranteed not to fail because of lack of disk space."
4810 msgstr ""
4811 "関数 B<posix_fallocate>()  は、ディスクリプタ I<fd> で参照されるファイルに対"
4812 "して、ディスクスペースを確実に確保する。 ディスクスペースは I<offset> から始"
4813 "まる I<len> バイトの範囲のバイトである。 B<posix_fallocate>()  の呼び出しが成"
4814 "功した後、指定された範囲のバイトに対する書き込みは、 ディスクスペースの不足で"
4815 "失敗しないことが保証される。"
4816
4817 #. type: Plain text
4818 #: build/C/man3/posix_fallocate.3:64
4819 msgid ""
4820 "If the size of the file is less than I<offset>+I<len>, then the file is "
4821 "increased to this size; otherwise the file size is left unchanged."
4822 msgstr ""
4823 "ファイルのサイズが I<offset>+I<len> より小さい場合、ファイルはこのサイズにな"
4824 "るように拡大される。 それ以外の場合、ファイルサイズは変わらない。"
4825
4826 #. type: Plain text
4827 #: build/C/man3/posix_fallocate.3:70
4828 msgid ""
4829 "B<posix_fallocate>()  returns zero on success, or an error number on "
4830 "failure.  Note that I<errno> is not set."
4831 msgstr ""
4832 "B<posix_fallocate>()  は成功した場合、0 を返す。 失敗した場合、エラー番号を返"
4833 "す。 I<errno> が設定されない点に注意すること。"
4834
4835 #. type: Plain text
4836 #: build/C/man3/posix_fallocate.3:79
4837 msgid "I<offset+len> exceeds the maximum file size."
4838 msgstr "I<offset+len> が最大ファイルサイズを超えている。"
4839
4840 #. type: Plain text
4841 #: build/C/man3/posix_fallocate.3:89
4842 msgid "I<fd> does not refer to a regular file."
4843 msgstr "I<fd> が通常のファイルとして参照されていない。"
4844
4845 #. type: Plain text
4846 #: build/C/man3/posix_fallocate.3:98
4847 msgid "I<fd> refers to a pipe."
4848 msgstr "I<fd> がパイプを参照している。"
4849
4850 #. type: Plain text
4851 #: build/C/man3/posix_fallocate.3:101
4852 msgid "B<posix_fallocate>()  is available since glibc 2.1.94."
4853 msgstr "B<posix_fallocate>()  は glibc 2.1.94 以降で利用可能である。"
4854
4855 #. type: Plain text
4856 #: build/C/man3/posix_fallocate.3:126
4857 msgid ""
4858 "POSIX.1-2008 says that an implementation I<shall> give the B<EINVAL> error "
4859 "if I<len> was 0, or I<offset> was less than 0.  POSIX.1-2001 says that an "
4860 "implementation I<shall> give the B<EINVAL> error if I<len> is less than 0, "
4861 "or I<offset> was less than 0, and I<may> give the error if I<len> equals "
4862 "zero."
4863 msgstr ""
4864 "POSIX.1-2008 では、 I<len> が 0 の場合、もしくは I<offset> が 0 未満の場合、 "
4865 "B<EINVAL> エラーを返すものとされている。 POSIX.1-2001 では、 I<len> が 0 未満"
4866 "の場合、もしくは I<offset> が 0 未満の場合、 B<EINVAL> エラーを返すものとされ"
4867 "ている。また、 I<len> が 0 の場合、 B<EINVAL> エラーを返してもよいとされてい"
4868 "る。"
4869
4870 #. type: Plain text
4871 #: build/C/man3/posix_fallocate.3:130
4872 msgid "B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
4873 msgstr "B<fallocate>(2), B<lseek>(2), B<posix_fadvise>(2)"
4874
4875 #. type: TH
4876 #: build/C/man3/posix_memalign.3:26
4877 #, no-wrap
4878 msgid "POSIX_MEMALIGN"
4879 msgstr "POSIX_MEMALIGN"
4880
4881 #. type: Plain text
4882 #: build/C/man3/posix_memalign.3:29
4883 msgid "posix_memalign, memalign, valloc - Allocate aligned memory"
4884 msgstr ""
4885 "posix_memalign, memalign, valloc - アラインメントされたメモリの割り当てを行う"
4886
4887 #. type: Plain text
4888 #: build/C/man3/posix_memalign.3:32
4889 #, no-wrap
4890 msgid "B<#include E<lt>stdlib.hE<gt>>\n"
4891 msgstr "B<#include E<lt>stdlib.hE<gt>>\n"
4892
4893 #. type: Plain text
4894 #: build/C/man3/posix_memalign.3:34
4895 #, no-wrap
4896 msgid "B<int posix_memalign(void **>I<memptr>B<, size_t >I<alignment>B<, size_t >I<size>B<);>\n"
4897 msgstr "B<int posix_memalign(void **>I<memptr>B<, size_t >I<alignment>B<, size_t >I<size>B<);>\n"
4898
4899 #. type: Plain text
4900 #: build/C/man3/posix_memalign.3:39
4901 #, no-wrap
4902 msgid ""
4903 "B<void *valloc(size_t >I<size>B<);>\n"
4904 "B<void *memalign(size_t >I<boundary>B<, size_t >I<size>B<);>\n"
4905 msgstr ""
4906 "B<void *valloc(size_t >I<size>B<);>\n"
4907 "B<void *memalign(size_t >I<boundary>B<, size_t >I<size>B<);>\n"
4908
4909 #. type: Plain text
4910 #: build/C/man3/posix_memalign.3:49
4911 msgid ""
4912 "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
4913 "E<gt>=\\ 600"
4914 msgstr ""
4915 "B<posix_memalign>(): _POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ "
4916 "E<gt>=\\ 600"
4917
4918 #. type: Plain text
4919 #: build/C/man3/posix_memalign.3:51
4920 msgid "B<valloc>():"
4921 msgstr "B<valloc>():"
4922
4923 #. type: TP
4924 #: build/C/man3/posix_memalign.3:54
4925 #, no-wrap
4926 msgid "Since glibc 2.12:"
4927 msgstr "glibc 2.12 以降:"
4928
4929 #. type: Plain text
4930 #: build/C/man3/posix_memalign.3:61
4931 #, no-wrap
4932 msgid ""
4933 "_BSD_SOURCE ||\n"
4934 "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
4935 "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
4936 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
4937 msgstr ""
4938 "_BSD_SOURCE ||\n"
4939 "    (_XOPEN_SOURCE\\ E<gt>=\\ 500 ||\n"
4940 "        _XOPEN_SOURCE\\ &&\\ _XOPEN_SOURCE_EXTENDED) &&\n"
4941 "    !(_POSIX_C_SOURCE\\ E<gt>=\\ 200112L || _XOPEN_SOURCE\\ E<gt>=\\ 600)\n"
4942
4943 #. type: TP
4944 #: build/C/man3/posix_memalign.3:63
4945 #, no-wrap
4946 msgid "Before glibc 2.12:"
4947 msgstr "glibc 2.12 より前:"
4948
4949 #. type: Plain text
4950 #: build/C/man3/posix_memalign.3:67
4951 msgid ""
4952 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
4953 "_XOPEN_SOURCE_EXTENDED"
4954 msgstr ""
4955 "_BSD_SOURCE || _XOPEN_SOURCE\\ E<gt>=\\ 500 || _XOPEN_SOURCE\\ &&\\ "
4956 "_XOPEN_SOURCE_EXTENDED"
4957
4958 #.  glibc does this:
4959 #. type: Plain text
4960 #: build/C/man3/posix_memalign.3:89
4961 msgid ""
4962 "The function B<posix_memalign>()  allocates I<size> bytes and places the "
4963 "address of the allocated memory in I<*memptr>.  The address of the allocated "
4964 "memory will be a multiple of I<alignment>, which must be a power of two and "
4965 "a multiple of I<sizeof(void *)>.  If I<size> is 0, then B<posix_memalign>()  "
4966 "returns either NULL, or a unique pointer value that can later be "
4967 "successfully passed to B<free>(3)."
4968 msgstr ""
4969 "関数 B<posix_memalign>()  は、 I<size> バイトのメモリを割り当て、割り当てられ"
4970 "たメモリのアドレスを I<*memptr> に設定する。 割り当てられたメモリのアドレス"
4971 "は I<alignment> の倍数になっているはずである。 I<alignment> は 2 のべき乗で、"
4972 "かつ I<sizeof(void *)> の倍数でなければならない。 I<size> が 0 の場合、 "
4973 "B<posix_memalign>()  は NULL か一意なポインタ値を返す。 このポインタ値は、後"
4974 "で B<free>(3)  に問題なく渡すことができる。"
4975
4976 #.  The behavior of memalign() for size==0 is as for posix_memalign()
4977 #.  but no standards govern this.
4978 #. type: Plain text
4979 #: build/C/man3/posix_memalign.3:100
4980 msgid ""
4981 "The obsolete function B<memalign>()  allocates I<size> bytes and returns a "
4982 "pointer to the allocated memory.  The memory address will be a multiple of "
4983 "I<boundary>, which must be a power of two."
4984 msgstr ""
4985 "廃止された関数である B<memalign>()  は、 I<size> バイトのメモリを割り当て、割"
4986 "り当てられたメモリへのポインタを返す。 メモリのアドレスは I<boundary> の倍数"
4987 "になっているはずである。 I<boundary> は 2 のべき乗でなければならない。"
4988
4989 #. type: Plain text
4990 #: build/C/man3/posix_memalign.3:109
4991 msgid ""
4992 "The obsolete function B<valloc>()  allocates I<size> bytes and returns a "
4993 "pointer to the allocated memory.  The memory address will be a multiple of "
4994 "the page size.  It is equivalent to I<memalign(sysconf(_SC_PAGESIZE),size)>."
4995 msgstr ""
4996 "廃止された関数である B<valloc>()  は I<size> バイトのメモリを割り当て、割り当"
4997 "てられたメモリへのポインタを返す。 メモリのアドレスはページサイズの倍数になっ"
4998 "ているはずである。 これは I<memalign(sysconf(_SC_PAGESIZE),size)> と等価であ"
4999 "る。"
5000
5001 #. type: Plain text
5002 #: build/C/man3/posix_memalign.3:111
5003 msgid "For all three routines, the memory is not zeroed."
5004 msgstr "3 つの関数はいずれもメモリのゼロクリアを行わない。"
5005
5006 #. type: Plain text
5007 #: build/C/man3/posix_memalign.3:116
5008 msgid ""
5009 "B<memalign>()  and B<valloc>()  return the pointer to the allocated memory, "
5010 "or NULL if the request fails."
5011 msgstr ""
5012 "B<memalign>()  と B<valloc>()  は割り当てられたメモリへのポインタを返す。 割"
5013 "り当てに失敗した場合は NULL を返す。"
5014
5015 #. type: Plain text
5016 #: build/C/man3/posix_memalign.3:123
5017 msgid ""
5018 "B<posix_memalign>()  returns zero on success, or one of the error values "
5019 "listed in the next section on failure.  Note that I<errno> is not set."
5020 msgstr ""
5021 "B<posix_memalign>()  は成功した場合は 0 を返し、 失敗した場合は次のセクション"
5022 "に記載されたエラー値のいずれかを返す。 I<errno> はセットされないことに注意す"
5023 "ること。"
5024
5025 #. type: Plain text
5026 #: build/C/man3/posix_memalign.3:130
5027 msgid ""
5028 "The I<alignment> argument was not a power of two, or was not a multiple of "
5029 "I<sizeof(void *)>."
5030 msgstr ""
5031 "I<alignment> 引き数が 2 のべき乗でなかったか、 I<sizeof(void *)> の倍数でな"
5032 "かった。"
5033
5034 #. type: Plain text
5035 #: build/C/man3/posix_memalign.3:133
5036 msgid "There was insufficient memory to fulfill the allocation request."
5037 msgstr "割り当て要求を満たすのに十分なメモリがなかった。"
5038
5039 #. type: Plain text
5040 #: build/C/man3/posix_memalign.3:142
5041 msgid ""
5042 "The functions B<memalign>()  and B<valloc>()  have been available in all "
5043 "Linux libc libraries.  The function B<posix_memalign>()  is available since "
5044 "glibc 2.1.91."
5045 msgstr ""
5046 "B<memalign>()  と B<valloc>()  はすべての Linux libc ライブラリで使用可能であ"
5047 "る。 B<posix_memalign>()  は glibc 2.1.91 以降で使用可能である。"
5048
5049 #. type: Plain text
5050 #: build/C/man3/posix_memalign.3:155
5051 msgid ""
5052 "The function B<valloc>()  appeared in 3.0BSD.  It is documented as being "
5053 "obsolete in 4.3BSD, and as legacy in SUSv2.  It does not appear in "
5054 "POSIX.1-2001.  The function B<memalign>()  appears in SunOS 4.1.3 but not in "
5055 "4.4BSD.  The function B<posix_memalign>()  comes from POSIX.1d."
5056 msgstr ""
5057 "関数 B<valloc>()  は 3.0BSD で登場した。4.3BSD では廃止されたと記載されてお"
5058 "り、 SUSv2 では過去の名残だと記載されている。 POSIX.1-2001 にはもはや存在しな"
5059 "い。 関数 B<memalign>()  は SunOS 4.1.3 で登場したが、4.4BSD にはない。 関数 "
5060 "B<posix_memalign>()  は POSIX.1d に由来する。"
5061
5062 #. type: SS
5063 #: build/C/man3/posix_memalign.3:155
5064 #, no-wrap
5065 msgid "Headers"
5066 msgstr "ヘッダ"
5067
5068 #. type: Plain text
5069 #: build/C/man3/posix_memalign.3:159
5070 msgid ""
5071 "Everybody agrees that B<posix_memalign>()  is declared in I<E<lt>stdlib."
5072 "hE<gt>>."
5073 msgstr ""
5074 "B<posix_memalign>()  の宣言を I<E<lt>stdlib.hE<gt>> で行うことに関しては、 皆"
5075 "の意見が一致している。"
5076
5077 #. type: Plain text
5078 #: build/C/man3/posix_memalign.3:163
5079 msgid ""
5080 "On some systems B<memalign>()  is declared in I<E<lt>stdlib.hE<gt>> instead "
5081 "of I<E<lt>malloc.hE<gt>>."
5082 msgstr ""
5083 "いくつかのシステムでは、 B<memalign>()  は I<E<lt>malloc.hE<gt>> ではなく "
5084 "I<E<lt>stdlib.hE<gt>> で宣言されている。"
5085
5086 #. type: Plain text
5087 #: build/C/man3/posix_memalign.3:179
5088 msgid ""
5089 "According to SUSv2, B<valloc>()  is declared in I<E<lt>stdlib.hE<gt>>.  "
5090 "Libc4,5 and glibc declare it in I<E<lt>malloc.hE<gt>> and perhaps also in "
5091 "I<E<lt>stdlib.hE<gt>> (namely, if B<_GNU_SOURCE> is defined, or "
5092 "B<_BSD_SOURCE> is defined, or, for glibc, if B<_XOPEN_SOURCE_EXTENDED> is "
5093 "defined, or, equivalently, B<_XOPEN_SOURCE> is defined to a value not less "
5094 "than 500)."
5095 msgstr ""
5096 "SUSv2 によると、 B<valloc>()  は I<E<lt>stdlib.hE<gt>> で宣言される。 "
5097 "libc4,5 や glibc では I<E<lt>malloc.hE<gt>> で宣言されており、 さらに "
5098 "I<E<lt>stdlib.hE<gt>> でも宣言されることもある (具体的には以下のいずれかの場"
5099 "合: B<_GNU_SOURCE> が定義されている、 B<_BSD_SOURCE> が定義されている、 "
5100 "glibc で B<_XOPEN_SOURCE_EXTENDED> が定義されている、 glibc で "
5101 "B<_XOPEN_SOURCE> が 500 より小さくない値に定義されている)。"
5102
5103 #. type: Plain text
5104 #: build/C/man3/posix_memalign.3:188
5105 msgid ""
5106 "On many systems there are alignment restrictions, for example, on buffers "
5107 "used for direct block device I/O.  POSIX specifies the I<pathconf(path,"
5108 "_PC_REC_XFER_ALIGN)> call that tells what alignment is needed.  Now one can "
5109 "use B<posix_memalign>()  to satisfy this requirement."
5110 msgstr ""
5111 "多くのシステムでは、アラインメントに関して制限がある。例えば、 ブロックデバイ"
5112 "スに対するダイレクト I/O に使用するバッファには アラインメントに関する制限が"
5113 "ある。 POSIX では、どんなアラインメントが必要かを知るために I<pathconf(path,"
5114 "_PC_REC_XFER_ALIGN)> コールを規定している。ここで B<posix_memalign>()  を使う"
5115 "と、この必要条件を満たすことができる。"
5116
5117 #. type: Plain text
5118 #: build/C/man3/posix_memalign.3:197
5119 msgid ""
5120 "B<posix_memalign>()  verifies that I<alignment> matches the requirements "
5121 "detailed above.  B<memalign>()  may not check that the I<boundary> argument "
5122 "is correct."
5123 msgstr ""
5124 "B<posix_memalign>()  は I<alignment> が上で詳細に述べた必要条件を満たすかどう"
5125 "かを確かめる。 B<memalign>()  は I<boundary> 引き数が正しいかどうかの確認を行"
5126 "わないかもしれない。"
5127
5128 #.  Other systems allow passing the result of
5129 #.  .IR valloc ()
5130 #.  to
5131 #.  .IR free (3),
5132 #.  but not to
5133 #.  .IR realloc (3).
5134 #. type: Plain text
5135 #: build/C/man3/posix_memalign.3:225
5136 msgid ""
5137 "POSIX requires that memory obtained from B<posix_memalign>()  can be freed "
5138 "using B<free>(3).  Some systems provide no way to reclaim memory allocated "
5139 "with B<memalign>()  or B<valloc>()  (because one can only pass to B<free>"
5140 "(3)  a pointer gotten from B<malloc>(3), while, for example, B<memalign>()  "
5141 "would call B<malloc>(3)  and then align the obtained value).  The glibc "
5142 "implementation allows memory obtained from any of these three routines to be "
5143 "reclaimed with B<free>(3)."
5144 msgstr ""
5145 "POSIX では B<posix_memalign>()  によって獲得したメモリは B<free>(3)  を使って"
5146 "解放することができる必要がある。 いくつかのシステムでは B<memalign>()  や "
5147 "B<valloc>()  で割り当てられたメモリを再利用する手段が提供されていない。 (なぜ"
5148 "なら B<free>(3)  に渡すことができるのは B<malloc>(3)  から受け取ったポインタ"
5149 "だけだが、 例えば B<memalign>()  は B<malloc>(3)  を呼び出し、得た値をアライ"
5150 "ンメントしてしまうからである)  glibc の実装では、 ここに述べた 3 つの関数のい"
5151 "ずれで獲得したメモリも B<free>(3)  で再利用することができる。"
5152
5153 #. type: Plain text
5154 #: build/C/man3/posix_memalign.3:230
5155 msgid ""
5156 "The glibc B<malloc>(3)  always returns 8-byte aligned memory addresses, so "
5157 "these routines are only needed if you require larger alignment values."
5158 msgstr ""
5159 "glibc の B<malloc>(3)  は常に 8 バイトにアラインメントされたメモリアドレスを"
5160 "返すので、 ここで述べた関数が必要になるのは 8 バイトよりも大きなアラインメン"
5161 "トが必要な場合だけである。"
5162
5163 #. type: Plain text
5164 #: build/C/man3/posix_memalign.3:235
5165 msgid "B<brk>(2), B<getpagesize>(2), B<free>(3), B<malloc>(3)"
5166 msgstr "B<brk>(2), B<getpagesize>(2), B<free>(3), B<malloc>(3)"
5167
5168 #. type: TH
5169 #: build/C/man2/readahead.2:28
5170 #, no-wrap
5171 msgid "READAHEAD"
5172 msgstr "READAHEAD"
5173
5174 #. type: TH
5175 #: build/C/man2/readahead.2:28 build/C/man7/shm_overview.7:27
5176 #, no-wrap
5177 msgid "2010-09-10"
5178 msgstr "2010-09-10"
5179
5180 #. type: Plain text
5181 #: build/C/man2/readahead.2:31
5182 msgid "readahead - perform file readahead into page cache"
5183 msgstr "readahead - 前もってファイルをページ・キャッシュに読み込む"
5184
5185 #. type: Plain text
5186 #: build/C/man2/readahead.2:37
5187 #, no-wrap
5188 msgid "B<ssize_t readahead(int >I<fd>B<, off64_t >I<offset>B<, size_t >I<count>B<);>\n"
5189 msgstr "B<ssize_t readahead(int >I<fd>B<, off64_t >I<offset>B<, size_t >I<count>B<);>\n"
5190
5191 #. type: Plain text
5192 #: build/C/man2/readahead.2:65
5193 msgid ""
5194 "B<readahead>()  populates the page cache with data from a file so that "
5195 "subsequent reads from that file will not block on disk I/O.  The I<fd> "
5196 "argument is a file descriptor identifying the file which is to be read.  The "
5197 "I<offset> argument specifies the starting point from which data is to be "
5198 "read and I<count> specifies the number of bytes to be read.  I/O is "
5199 "performed in whole pages, so that I<offset> is effectively rounded down to a "
5200 "page boundary and bytes are read up to the next page boundary greater than "
5201 "or equal to I<(offset+count)>.  B<readahead>()  does not read beyond the end "
5202 "of the file.  B<readahead>()  blocks until the specified data has been "
5203 "read.  The current file offset of the open file referred to by I<fd> is left "
5204 "unchanged."
5205 msgstr ""
5206 "B<readahead>()  は、この後の同じファイルからのデータ読み込み時にディスク I/O "
5207 "で 動作が停止 (block) しないように、前もってファイルの内容を ページ・キャッ"
5208 "シュに読み込む。 I<fd> 引き数は読み込みを行うファイルを識別するファイル・ディ"
5209 "スクリプタである。 I<offset> 引き数はデータの読み込み開始位置を指定し、 "
5210 "I<count> は読み込むデータのバイト数を指定する。 ディスク I/O はページ単位で実"
5211 "行されるので、 実際には I<offset> はページ境界に切り下げられ、読み込みバイト"
5212 "数は I<(offset+count)> より小さくない次のページ境界まで切り上げられる。 "
5213 "B<readahead>()  はファイルの末尾を越えた範囲まで読み出しを行うことはない。ま"
5214 "た、 B<readahead>()  は指定したデータの読み込みが終わるまで停止 (block) す"
5215 "る。 I<fd> で参照されたオープン済のファイルのファイルオフセットの現在値は 変"
5216 "更されない。"
5217
5218 #. type: Plain text
5219 #: build/C/man2/readahead.2:71
5220 msgid ""
5221 "On success, B<readahead>()  returns 0; on failure, -1 is returned, with "
5222 "I<errno> set to indicate the cause of the error."
5223 msgstr ""
5224 "B<readahead>()  は成功すると 0 を返す。失敗した場合 -1 を返し、 I<errno> にエ"
5225 "ラーの原因を示す値を設定する。"
5226
5227 #. type: Plain text
5228 #: build/C/man2/readahead.2:76
5229 msgid "I<fd> is not a valid file descriptor or is not open for reading."
5230 msgstr ""
5231 "I<fd> が有効なファイル・ディスクリプタでない、または 読み込み用にオープンされ"
5232 "ていない。"
5233
5234 #. type: Plain text
5235 #: build/C/man2/readahead.2:82
5236 msgid ""
5237 "I<fd> does not refer to a file type to which B<readahead>()  can be applied."
5238 msgstr ""
5239 "I<fd> が参照しているファイルが、 B<readahead>()  を行うことができないタイプの"
5240 "ファイルであった。"
5241
5242 #. type: Plain text
5243 #: build/C/man2/readahead.2:87
5244 msgid ""
5245 "The B<readahead>()  system call appeared in Linux 2.4.13; glibc support has "
5246 "been provided since version 2.3."
5247 msgstr ""
5248 "B<readahead>()  システムコールは Linux 2.4.13 で登場した。 glibc でのサポート"
5249 "は glibc バージョン 2.3 以降で行われている。"
5250
5251 #. type: Plain text
5252 #: build/C/man2/readahead.2:92
5253 msgid ""
5254 "The B<readahead>()  system call is Linux-specific, and its use should be "
5255 "avoided in portable applications."
5256 msgstr ""
5257 "B<readahead>()  システムコールは Linux 固有であり、移植を考慮したプログラムで"
5258 "は 使用を避けるべきである。"
5259
5260 #. type: Plain text
5261 #: build/C/man2/readahead.2:98
5262 msgid "B<lseek>(2), B<madvise>(2), B<mmap>(2), B<posix_fadvise>(2), B<read>(2)"
5263 msgstr ""
5264 "B<lseek>(2), B<madvise>(2), B<mmap>(2), B<posix_fadvise>(2), B<read>(2)"
5265
5266 #. type: TH
5267 #: build/C/man2/remap_file_pages.2:26
5268 #, no-wrap
5269 msgid "REMAP_FILE_PAGES"
5270 msgstr "REMAP_FILE_PAGES"
5271
5272 #. type: Plain text
5273 #: build/C/man2/remap_file_pages.2:29
5274 msgid "remap_file_pages - create a nonlinear file mapping"
5275 msgstr "remap_file_pages - 非線形ファイルマッピングを作成する。"
5276
5277 #. type: Plain text
5278 #: build/C/man2/remap_file_pages.2:33
5279 #, no-wrap
5280 msgid ""
5281 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
5282 "B<#include E<lt>sys/mman.hE<gt>>\n"
5283 msgstr ""
5284 "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
5285 "B<#include E<lt>sys/mman.hE<gt>>\n"
5286
5287 #. type: Plain text
5288 #: build/C/man2/remap_file_pages.2:36
5289 #, no-wrap
5290 msgid ""
5291 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
5292 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
5293 msgstr ""
5294 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
5295 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
5296
5297 #. type: Plain text
5298 #: build/C/man2/remap_file_pages.2:49
5299 msgid ""
5300 "The B<remap_file_pages>()  system call is used to create a nonlinear "
5301 "mapping, that is, a mapping in which the pages of the file are mapped into a "
5302 "nonsequential order in memory.  The advantage of using B<remap_file_pages>"
5303 "()  over using repeated calls to B<mmap>(2)  is that the former approach "
5304 "does not require the kernel to create additional VMA (Virtual Memory Area) "
5305 "data structures."
5306 msgstr ""
5307 "B<remap_file_pages>()  システムコールは非線形なマッピング、 つまりファイルの"
5308 "ページがメモリ上で連続しない順番でマップされる マッピングを作成するために使わ"
5309 "れる。 B<remap_file_pages>()  を使う方が B<mmap>(2)  を繰り返して使うより優れ"
5310 "ている点は、 前者の方法ではカーネルが VMA (Virtual Memory Area, 仮想メモリ領"
5311 "域)  データ構造体を追加で作成する必要がないことである。"
5312
5313 #. type: Plain text
5314 #: build/C/man2/remap_file_pages.2:51
5315 msgid "To create a nonlinear mapping we perform the following steps:"
5316 msgstr "非線形マッピングを作成するためには、 以下のようなステップを実行する:"
5317
5318 #. type: TP
5319 #: build/C/man2/remap_file_pages.2:51
5320 #, no-wrap
5321 msgid "1."
5322 msgstr "1."
5323
5324 #. type: Plain text
5325 #: build/C/man2/remap_file_pages.2:59
5326 msgid ""
5327 "Use B<mmap>(2)  to create a mapping (which is initially linear).  This "
5328 "mapping must be created with the B<MAP_SHARED> flag."
5329 msgstr ""
5330 "B<mmap>(2)  を使い、マッピングを作成する (このマッピングは最初は線形であ"
5331 "る)。 このマッピングは B<MAP_SHARED> フラグを指定して作成されなければならな"
5332 "い。"
5333
5334 #. type: TP
5335 #: build/C/man2/remap_file_pages.2:59
5336 #, no-wrap
5337 msgid "2."
5338 msgstr "2."
5339
5340 #. type: Plain text
5341 #: build/C/man2/remap_file_pages.2:67
5342 msgid ""
5343 "Use one or more calls to B<remap_file_pages>()  to rearrange the "
5344 "correspondence between the pages of the mapping and the pages of the file.  "
5345 "It is possible to map the same page of a file into multiple locations within "
5346 "the mapped region."
5347 msgstr ""
5348 "B<remap_file_pages>()  を 1 回以上呼び出して、 マッピングのページとファイルの"
5349 "ページの対応関係を再構成する。 ファイルの同じページをマッピング領域の複数の場"
5350 "所に マップすることが可能である。"
5351
5352 #. type: Plain text
5353 #: build/C/man2/remap_file_pages.2:78
5354 msgid ""
5355 "The I<pgoff> and I<size> arguments specify the region of the file that is to "
5356 "be relocated within the mapping: I<pgoff> is a file offset in units of the "
5357 "system page size; I<size> is the length of the region in bytes."
5358 msgstr ""
5359 "I<pgoff> と I<size> 引き数は、マッピング内で再配置されるファイルの領域を指定"
5360 "する。 I<pgoff> はファイルオフセットであり、単位はシステムのページサイズであ"
5361 "る。 I<size> は領域の長さであり、単位はバイトである。"
5362
5363 #. type: Plain text
5364 #: build/C/man2/remap_file_pages.2:96
5365 msgid ""
5366 "The I<addr> argument serves two purposes.  First, it identifies the mapping "
5367 "whose pages we want to rearrange.  Thus, I<addr> must be an address that "
5368 "falls within a region previously mapped by a call to B<mmap>(2).  Second, "
5369 "I<addr> specifies the address at which the file pages identified by I<pgoff> "
5370 "and I<size> will be placed."
5371 msgstr ""
5372 "I<addr> 引き数は 2 つの目的で使われる。 第 1 の目的は、この引き数によって再編"
5373 "成したいページの マッピングを識別することである。 よって I<addr> は B<mmap>"
5374 "(2)  の呼び出しで過去にマップされた領域内のアドレスでなければならない。 第 2 "
5375 "の目的は、 I<pgoff> と I<size> で識別されるファイルページが置かれる予定のアド"
5376 "レスを、 I<addr> によって指定することである。"
5377
5378 #.  This rounding is weird, and not consistent with the treatment of
5379 #.  the analogous arguments for munmap()/mprotect() and for mlock().
5380 #.  MTK, 14 Sep 2005
5381 #. type: Plain text
5382 #: build/C/man2/remap_file_pages.2:110
5383 msgid ""
5384 "The values specified in I<addr> and I<size> should be multiples of the "
5385 "system page size.  If they are not, then the kernel rounds I<both> values "
5386 "I<down> to the nearest multiple of the page size."
5387 msgstr ""
5388 "I<addr> と I<size> に指定する値は、システムのページサイズの倍数とすべきであ"
5389 "る。 それ以外の場合、カーネルは「両方」の値を 最も近いページサイズの倍数へ"
5390 "「切り下げる」。"
5391
5392 #. type: Plain text
5393 #: build/C/man2/remap_file_pages.2:114
5394 msgid "The I<prot> argument must be specified as 0."
5395 msgstr "I<prot> 引き数は 0 に指定されなければならない。"
5396
5397 #. type: Plain text
5398 #: build/C/man2/remap_file_pages.2:122
5399 msgid ""
5400 "The I<flags> argument has the same meaning as for B<mmap>(2), but all flags "
5401 "other than B<MAP_NONBLOCK> are ignored."
5402 msgstr ""
5403 "I<flags> 引き数は B<mmap>(2)  のものと同じ意味であるが、 B<MAP_NONBLOCK> 以外"
5404 "の全てのフラグは無視される。"
5405
5406 #. type: Plain text
5407 #: build/C/man2/remap_file_pages.2:129
5408 msgid ""
5409 "On success, B<remap_file_pages>()  returns 0.  On error, -1 is returned, and "
5410 "I<errno> is set appropriately."
5411 msgstr ""
5412 "成功した場合、 B<remap_file_pages>()  は 0 を返す。 エラーの場合、-1 が返さ"
5413 "れ、 I<errno> が適切に設定される。"
5414
5415 #. type: Plain text
5416 #: build/C/man2/remap_file_pages.2:137
5417 msgid ""
5418 "I<addr> does not refer to a valid mapping created with the B<MAP_SHARED> "
5419 "flag."
5420 msgstr ""
5421 "I<addr> が B<MAP_SHARED> フラグを指定して作成された有効なマッピングを参照して"
5422 "いない。"
5423
5424 #.  And possibly others from vma->vm_ops->populate()
5425 #. type: Plain text
5426 #: build/C/man2/remap_file_pages.2:146
5427 msgid "I<addr>, I<size>, I<prot>, or I<pgoff> is invalid."
5428 msgstr "I<addr>, I<size>, I<prot>, I<pgoff> のいずれかが不正である。"
5429
5430 #. type: Plain text
5431 #: build/C/man2/remap_file_pages.2:151
5432 msgid ""
5433 "The B<remap_file_pages>()  system call appeared in Linux 2.5.46; glibc "
5434 "support was added in version 2.3.3."
5435 msgstr ""
5436 "B<remap_file_pages>()  システムコールは Linux 2.5.46 で登場した。 glibc での"
5437 "サポートは glibc バージョン 2.3.3 で追加された。"
5438
5439 #. type: Plain text
5440 #: build/C/man2/remap_file_pages.2:155
5441 msgid "The B<remap_file_pages>()  system call is Linux-specific."
5442 msgstr "B<remap_file_pages>()  システムコールは Linux 固有のものである。"
5443
5444 #. type: Plain text
5445 #: build/C/man2/remap_file_pages.2:162
5446 msgid ""
5447 "B<getpagesize>(2), B<mmap>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), "
5448 "B<msync>(2)"
5449 msgstr ""
5450 "B<getpagesize>(2), B<mmap>(2), B<mmap2>(2), B<mprotect>(2), B<mremap>(2), "
5451 "B<msync>(2)"
5452
5453 #. type: TH
5454 #: build/C/man3/shm_open.3:26
5455 #, no-wrap
5456 msgid "SHM_OPEN"
5457 msgstr "SHM_OPEN"
5458
5459 #. type: TH
5460 #: build/C/man3/shm_open.3:26
5461 #, no-wrap
5462 msgid "2009-02-25"
5463 msgstr "2009-02-25"
5464
5465 #. type: Plain text
5466 #: build/C/man3/shm_open.3:29
5467 msgid ""
5468 "shm_open, shm_unlink - Create/open or unlink POSIX shared memory objects"
5469 msgstr ""
5470 "shm_open, shm_unlink - POSIX 共有メモリ・オブジェクトの作成/オープン、 削除を"
5471 "行う"
5472
5473 #. type: Plain text
5474 #: build/C/man3/shm_open.3:33
5475 msgid "B<#include E<lt>sys/stat.hE<gt>> /* For mode constants */"
5476 msgstr "B<#include E<lt>sys/stat.hE<gt>> /* mode 定数用 */"
5477
5478 #. type: Plain text
5479 #: build/C/man3/shm_open.3:35
5480 msgid "B<#include E<lt>fcntl.hE<gt>> /* For O_* constants */"
5481 msgstr "B<#include E<lt>fcntl.hE<gt>> /* O_* 定数の定義用 */"
5482
5483 #. type: Plain text
5484 #: build/C/man3/shm_open.3:37
5485 msgid ""
5486 "B<int shm_open(const char *>I<name>B<, int >I<oflag>B<, mode_t >I<mode>B<);>"
5487 msgstr ""
5488 "B<void * shm_open(const char *>I<name>B<, int >I<oflag>B<, mode_t "
5489 ">I<mode>B<);>"
5490
5491 #. type: Plain text
5492 #: build/C/man3/shm_open.3:39
5493 msgid "B<int shm_unlink(const char *>I<name>B<);>"
5494 msgstr "B<int shm_unlink(const char *>I<name>B<);>"
5495
5496 #. type: Plain text
5497 #: build/C/man3/shm_open.3:41
5498 msgid "Link with I<-lrt>."
5499 msgstr "I<-lrt> でリンクする。"
5500
5501 #. type: Plain text
5502 #: build/C/man3/shm_open.3:53
5503 msgid ""
5504 "B<shm_open>()  creates and opens a new, or opens an existing, POSIX shared "
5505 "memory object.  A POSIX shared memory object is in effect a handle which can "
5506 "be used by unrelated processes to B<mmap>(2)  the same region of shared "
5507 "memory.  The B<shm_unlink>()  function performs the converse operation, "
5508 "removing an object previously created by B<shm_open>()."
5509 msgstr ""
5510 "B<shm_open>()  は、POSIX 共有メモリ・オブジェクトを新規に作成/オープンした"
5511 "り、 すでに存在するオブジェクトをオープンしたりする。 POSIX 共有メモリ・オブ"
5512 "ジェクトは、実際には、関係のないプロセスが 共有メモリの同じ領域を B<mmap>"
5513 "(2)  するために使用することができる手段である。 B<shm_unlink>()  は、逆の操"
5514 "作、つまり以前に B<shm_open>()  で作成されたオブジェクトの削除を行う。"
5515
5516 #.  glibc allows the initial slash to be omitted, and makes
5517 #.  multiple initial slashes equivalent to a single slash.
5518 #.  This differs from the implementation of POSIX message queues.
5519 #.  glibc allows subdirectory components in the name, in which
5520 #.  case the subdirectory must exist under /dev/shm, and allow the
5521 #.  required permissions if a user wants to create a shared memory
5522 #.  object in that subdirectory.
5523 #. type: Plain text
5524 #: build/C/man3/shm_open.3:74
5525 msgid ""
5526 "The operation of B<shm_open>()  is analogous to that of B<open>(2).  I<name> "
5527 "specifies the shared memory object to be created or opened.  For portable "
5528 "use, a shared memory object should be identified by a name of the form I</"
5529 "somename>; that is, a null-terminated string of up to B<NAME_MAX> (i.e., "
5530 "255) characters consisting of an initial slash, followed by one or more "
5531 "characters, none of which are slashes."
5532 msgstr ""
5533 "B<shm_open>()  の動作は B<open>(2)  とよく似ている。 I<name> で作成したりオー"
5534 "プンしたりする共有メモリ・オブジェクトを指定する。 移植性を持たせるためには、"
5535 "共有メモリ・オブジェクトは I</somename> という形式の名前で識別し、 その名前"
5536 "は、最大で B<NAME_MAX> (すなわち 255) 文字の NULL 終端された文字列で、 スラッ"
5537 "シュで始まり、スラッシュ以外の文字が 1 文字以上続く形式 にすべきである。"
5538
5539 #. type: Plain text
5540 #: build/C/man3/shm_open.3:81
5541 msgid ""
5542 "I<oflag> is a bit mask created by ORing together exactly one of B<O_RDONLY> "
5543 "or B<O_RDWR> and any of the other flags listed here:"
5544 msgstr ""
5545 "I<oflag> はビットマスクで、 B<O_RDONLY> と B<O_RDWR> のいずれか一方と、以下に"
5546 "述べる他のフラグの論理和をとったもの を指定する。"
5547
5548 #. type: TP
5549 #: build/C/man3/shm_open.3:81
5550 #, no-wrap
5551 msgid "B<O_RDONLY>"
5552 msgstr "B<O_RDONLY>"
5553
5554 #. type: Plain text
5555 #: build/C/man3/shm_open.3:87
5556 msgid ""
5557 "Open the object for read access.  A shared memory object opened in this way "
5558 "can only be B<mmap>(2)ed for read (B<PROT_READ>) access."
5559 msgstr ""
5560 "読み出しアクセス用にオブジェクトをオープンする。 このフラグを指定してオープン"
5561 "された共有メモリ・オブジェクトは、 読み出し (B<PROT_READ>) アクセスでのみ "
5562 "B<mmap>(2)  することができる。"
5563
5564 #. type: TP
5565 #: build/C/man3/shm_open.3:87
5566 #, no-wrap
5567 msgid "B<O_RDWR>"
5568 msgstr "B<O_RDWR>"
5569
5570 #. type: Plain text
5571 #: build/C/man3/shm_open.3:90
5572 msgid "Open the object for read-write access."
5573 msgstr "読み書きアクセス用にオブジェクトをオープンする。"
5574
5575 #. type: TP
5576 #: build/C/man3/shm_open.3:90
5577 #, no-wrap
5578 msgid "B<O_CREAT>"
5579 msgstr "B<O_CREAT>"
5580
5581 #.  In truth it is actually the file system IDs on Linux, but these
5582 #.  are nearly always the same as the effective IDs.  (MTK, Jul 05)
5583 #. type: Plain text
5584 #: build/C/man3/shm_open.3:110
5585 msgid ""
5586 "Create the shared memory object if it does not exist.  The user and group "
5587 "ownership of the object are taken from the corresponding effective IDs of "
5588 "the calling process, and the object's permission bits are set according to "
5589 "the low-order 9 bits of I<mode>, except that those bits set in the process "
5590 "file mode creation mask (see B<umask>(2))  are cleared for the new object.  "
5591 "A set of macro constants which can be used to define I<mode> is listed in "
5592 "B<open>(2).  (Symbolic definitions of these constants can be obtained by "
5593 "including I<E<lt>sys/stat.hE<gt>>.)"
5594 msgstr ""
5595 "存在しない場合、共有メモリ・オブジェクトを作成する。 オブジェクトのユーザとグ"
5596 "ループの所有権は、 呼び出し元プロセスの対応する実効 ID が使われ、 オブジェク"
5597 "トの許可ビットは I<mode> の下位 9 ビットに基づいて設定される。ただし、 ファイ"
5598 "ルモード作成マスク (B<umask>(2)  参照) に設定されている値は、新規オブジェクト"
5599 "に関してはクリアされる。 I<mode> を定義するために使用できるマクロ定数(群)は "
5600 "B<open>(2)  に記載されている (これらの定数のシンボル定義は I<E<lt>sys/stat."
5601 "hE<gt>> のインクルードにより得られる)。"
5602
5603 #. type: Plain text
5604 #: build/C/man3/shm_open.3:116
5605 msgid ""
5606 "A new shared memory object initially has zero length\\(emthe size of the "
5607 "object can be set using B<ftruncate>(2).  The newly allocated bytes of a "
5608 "shared memory object are automatically initialized to 0."
5609 msgstr ""
5610 "新規に作成された共有メモリ・オブジェクトは長さ 0 で初期化される。 オブジェク"
5611 "トの大きさは B<ftruncate>(2)  を使って設定できる。 共有メモリ・オブジェクトと"
5612 "して新規に確保されたバイトは自動的に 0 に初期化される。"
5613
5614 #. type: TP
5615 #: build/C/man3/shm_open.3:116
5616 #, no-wrap
5617 msgid "B<O_EXCL>"
5618 msgstr "B<O_EXCL>"
5619
5620 #. type: Plain text
5621 #: build/C/man3/shm_open.3:125
5622 msgid ""
5623 "If B<O_CREAT> was also specified, and a shared memory object with the given "
5624 "I<name> already exists, return an error.  The check for the existence of the "
5625 "object, and its creation if it does not exist, are performed atomically."
5626 msgstr ""
5627 "B<O_CREAT> が一緒に指定されており、 I<name> で指定された共有メモリ・オブジェ"
5628 "クトが既に存在した場合、 エラーを返す。 オブジェクトの存在確認と、存在しな"
5629 "かった場合のオブジェクト作成は、 必ず一連の操作として実行される (performed "
5630 "atomically)。"
5631
5632 #. type: TP
5633 #: build/C/man3/shm_open.3:125
5634 #, no-wrap
5635 msgid "B<O_TRUNC>"
5636 msgstr "B<O_TRUNC>"
5637
5638 #. type: Plain text
5639 #: build/C/man3/shm_open.3:128
5640 msgid "If the shared memory object already exists, truncate it to zero bytes."
5641 msgstr ""
5642 "共有メモリ・オブジェクトがすでに存在した場合、 そのオブジェクトを 0 バイトに"
5643 "切り詰める。"
5644
5645 #. type: Plain text
5646 #: build/C/man3/shm_open.3:131
5647 msgid ""
5648 "Definitions of these flag values can be obtained by including I<E<lt>fcntl."
5649 "hE<gt>>."
5650 msgstr ""
5651 "これらのフラグ値の定義は I<E<lt>fcntl.hE<gt>> のインクルードにより得られる。"
5652
5653 #. type: Plain text
5654 #: build/C/man3/shm_open.3:142
5655 msgid ""
5656 "On successful completion B<shm_open>()  returns a new file descriptor "
5657 "referring to the shared memory object.  This file descriptor is guaranteed "
5658 "to be the lowest-numbered file descriptor not previously opened within the "
5659 "process.  The B<FD_CLOEXEC> flag (see B<fcntl>(2))  is set for the file "
5660 "descriptor."
5661 msgstr ""
5662 "成功して完了した場合、 B<shm_open>()  は共有メモリ・オブジェクトを参照する新"
5663 "しいファイル・ディスクリプタを返す。 このファイル・ディスクリプタは、そのプロ"
5664 "セス内で過去にオープンされていない ファイル・ディスクリプタの中で最も小さな数"
5665 "になることが保証される。 B<FD_CLOEXEC> フラグ (B<fcntl>(2)  を参照) が、この"
5666 "ファイル・ディスクリプタに設定される。"
5667
5668 #. type: Plain text
5669 #: build/C/man3/shm_open.3:151
5670 msgid ""
5671 "The file descriptor is normally used in subsequent calls to B<ftruncate>(2)  "
5672 "(for a newly created object) and B<mmap>(2).  After a call to B<mmap>(2)  "
5673 "the file descriptor may be closed without affecting the memory mapping."
5674 msgstr ""
5675 "通常、これらのファイル・ディスクリプタは、この後続けて実行される B<ftruncate>"
5676 "(2)  (新規に作成されたオブジェクトの場合のみ) と B<mmap>(2)  の呼び出しに使用"
5677 "される。 B<mmap>(2)  を呼び出した後は、ファイル・ディスクリプタをクローズして"
5678 "もよく、 クローズしてもメモリ・マッピングに影響を与えることはない。"
5679
5680 #. type: Plain text
5681 #: build/C/man3/shm_open.3:169
5682 msgid ""
5683 "The operation of B<shm_unlink>()  is analogous to B<unlink>(2): it removes a "
5684 "shared memory object name, and, once all processes have unmapped the object, "
5685 "de-allocates and destroys the contents of the associated memory region.  "
5686 "After a successful B<shm_unlink>(), attempts to B<shm_open>()  an object "
5687 "with the same I<name> will fail (unless B<O_CREAT> was specified, in which "
5688 "case a new, distinct object is created)."
5689 msgstr ""
5690 "B<shm_unlink>()  の動作は B<unlink>(2)  とよく似ている: 共有メモリ・オブジェ"
5691 "クト名を削除し、すべてのプロセスが処理対象の オブジェクトをアンマップした時点"
5692 "でオブジェクトの割り当てを解除し、 対応するメモリ領域の内容を破棄する。 "
5693 "B<shm_unlink>()  が成功した後で、同じ I<name> を持つオブジェクトに対して "
5694 "B<shm_open>()  を行うと、 (B<O_CREAT> が指定されていない場合) 失敗する。 "
5695 "(B<O_CREAT> が指定されている場合、新しく別のオブジェクトが作成される)。"
5696
5697 #. type: Plain text
5698 #: build/C/man3/shm_open.3:178
5699 msgid ""
5700 "On success, B<shm_open>()  returns a nonnegative file descriptor.  On "
5701 "failure, B<shm_open>()  returns -1.  B<shm_unlink>()  returns 0 on success, "
5702 "or -1 on error."
5703 msgstr ""
5704 "成功した場合、 B<shm_open>()  は非負のファイル・ディスクリプタを返す。 失敗し"
5705 "た場合、 B<shm_open>()  は -1 を返す。 B<shm_unlink>()  は、成功した場合 0 "
5706 "を、エラーが起こった場合 -1 を返す。"
5707
5708 #. type: Plain text
5709 #: build/C/man3/shm_open.3:185
5710 msgid ""
5711 "On failure, I<errno> is set to indicate the cause of the error.  Values "
5712 "which may appear in I<errno> include the following:"
5713 msgstr ""
5714 "失敗した場合、エラーの原因を示すため I<errno> が設定される。 I<errno> に設定"
5715 "される値は以下の通りである:"
5716
5717 #. type: Plain text
5718 #: build/C/man3/shm_open.3:190
5719 msgid "Permission to B<shm_unlink>()  the shared memory object was denied."
5720 msgstr "共有メモリオブジェクトを B<shm_unlink>()  する権限がなかった。"
5721
5722 #. type: Plain text
5723 #: build/C/man3/shm_open.3:200
5724 msgid ""
5725 "Permission was denied to B<shm_open>()  I<name> in the specified I<mode>, or "
5726 "B<O_TRUNC> was specified and the caller does not have write permission on "
5727 "the object."
5728 msgstr ""
5729 "指定された I<mode> で I<name> を B<shm_open>()  する権限がなかった。もしく"
5730 "は、 B<O_TRUNC> が指定されたが、呼び出し元にはそのオブジェクトに対する書き込"
5731 "み権限が なかった。"
5732
5733 #. type: TP
5734 #: build/C/man3/shm_open.3:200 build/C/man2/shmget.2:192
5735 #, no-wrap
5736 msgid "B<EEXIST>"
5737 msgstr "B<EEXIST>"
5738
5739 #. type: Plain text
5740 #: build/C/man3/shm_open.3:211
5741 msgid ""
5742 "Both B<O_CREAT> and B<O_EXCL> were specified to B<shm_open>()  and the "
5743 "shared memory object specified by I<name> already exists."
5744 msgstr ""
5745 "B<O_CREAT> と B<O_EXCL> の両方が B<shm_open>()  に指定されたが、 I<name> で指"
5746 "定された共有メモリ・オブジェクトが既に存在した。"
5747
5748 #. type: Plain text
5749 #: build/C/man3/shm_open.3:218
5750 msgid "The I<name> argument to B<shm_open>()  was invalid."
5751 msgstr "B<shm_open>()  に与えられた I<name> 引き数が不正であった。"
5752
5753 #. type: TP
5754 #: build/C/man3/shm_open.3:218
5755 #, no-wrap
5756 msgid "B<EMFILE>"
5757 msgstr "B<EMFILE>"
5758
5759 #. type: Plain text
5760 #: build/C/man3/shm_open.3:221
5761 msgid "The process already has the maximum number of files open."
5762 msgstr "プロセスがオープン可能なファイル数の上限にすでに達していた。"
5763
5764 #. type: TP
5765 #: build/C/man3/shm_open.3:221
5766 #, no-wrap
5767 msgid "B<ENAMETOOLONG>"
5768 msgstr "B<ENAMETOOLONG>"
5769
5770 #. type: Plain text
5771 #: build/C/man3/shm_open.3:227
5772 msgid "The length of I<name> exceeds B<PATH_MAX>."
5773 msgstr "I<name> の長さが B<PATH_MAX> を越えている。"
5774
5775 #. type: Plain text
5776 #: build/C/man3/shm_open.3:231
5777 msgid ""
5778 "The limit on the total number of files open on the system has been reached."
5779 msgstr "ファイルシステムでオープンできるファイル数の上限に達した。"
5780
5781 #. type: TP
5782 #: build/C/man3/shm_open.3:231 build/C/man3/shm_open.3:240
5783 #: build/C/man2/shmget.2:206
5784 #, no-wrap
5785 msgid "B<ENOENT>"
5786 msgstr "B<ENOENT>"
5787
5788 #. type: Plain text
5789 #: build/C/man3/shm_open.3:240
5790 msgid ""
5791 "An attempt was made to B<shm_open>()  a I<name> that did not exist, and "
5792 "B<O_CREAT> was not specified."
5793 msgstr ""
5794 "存在していない I<name> のオブジェクトを B<shm_open>()  しようとしたが、 "
5795 "B<O_CREAT> が指定されていなかった。"
5796
5797 #. type: Plain text
5798 #: build/C/man3/shm_open.3:247
5799 msgid ""
5800 "An attempt was to made to B<shm_unlink>()  a I<name> that does not exist."
5801 msgstr "存在しない I<name> のオブジェクトを B<shm_unlink>()  しようとした。"
5802
5803 #. type: Plain text
5804 #: build/C/man3/shm_open.3:249
5805 msgid "These functions are provided in glibc 2.2 and later."
5806 msgstr "これらの関数は glibc 2.2 以降で提供されている。"
5807
5808 #. type: Plain text
5809 #: build/C/man3/shm_open.3:255
5810 msgid ""
5811 "POSIX.1-2001 says that the group ownership of a newly created shared memory "
5812 "object is set to either the calling process's effective group ID or \"a "
5813 "system default group ID\"."
5814 msgstr ""
5815 "POSIX.1-2001 には、新規に作成される共有メモリオブジェクトのグループ所有権"
5816 "は、 呼び出し元プロセスの実効グループ ID か 「システムのデフォルトのグループ "
5817 "ID」 のどちらかに設定される、と書かれている。"
5818
5819 #. type: Plain text
5820 #: build/C/man3/shm_open.3:264
5821 msgid ""
5822 "POSIX leaves the behavior of the combination of B<O_RDONLY> and B<O_TRUNC> "
5823 "unspecified.  On Linux, this will successfully truncate an existing shared "
5824 "memory object\\(emthis may not be so on other UNIX systems."
5825 msgstr ""
5826 "POSIX は B<O_RDONLY> と B<O_TRUNC> が一緒に指定された場合の動作を未定義にして"
5827 "いる。Linux では、 既存の共有メモリ・オブジェクトに対する切り詰め (truncate) "
5828 "は成功する。 しかし、他の UNIX システムでも同じであるとは限らない。"
5829
5830 #. type: Plain text
5831 #: build/C/man3/shm_open.3:269
5832 msgid ""
5833 "The POSIX shared memory object implementation on Linux 2.4 makes use of a "
5834 "dedicated file system, which is normally mounted under I</dev/shm>."
5835 msgstr ""
5836 "Linux 2.4 における POSIX 共有メモリ・オブジェクトの実装は 専用のファイルシス"
5837 "テムを使用する。そのファイルシステムは通常 I</dev/shm> にマウントされる。"
5838
5839 #. type: Plain text
5840 #: build/C/man3/shm_open.3:280
5841 msgid ""
5842 "B<close>(2), B<fchmod>(2), B<fchown>(2), B<fcntl>(2), B<fstat>(2), "
5843 "B<ftruncate>(2), B<mmap>(2), B<open>(2), B<umask>(2), B<shm_overview>(7)"
5844 msgstr ""
5845 "B<close>(2), B<fchmod>(2), B<fchown>(2), B<fcntl>(2), B<fstat>(2), "
5846 "B<ftruncate>(2), B<mmap>(2), B<open>(2), B<umask>(2), B<shm_overview>(7)"
5847
5848 #. type: TH
5849 #: build/C/man7/shm_overview.7:27
5850 #, no-wrap
5851 msgid "SHM_OVERVIEW"
5852 msgstr "SHM_OVERVIEW"
5853
5854 #. type: Plain text
5855 #: build/C/man7/shm_overview.7:30
5856 msgid "shm_overview - Overview of POSIX shared memory"
5857 msgstr "shm_overview - POSIX 共有メモリの概要"
5858
5859 #. type: Plain text
5860 #: build/C/man7/shm_overview.7:33
5861 msgid ""
5862 "The POSIX shared memory API allows processes to communicate information by "
5863 "sharing a region of memory."
5864 msgstr ""
5865 "POSIX 共有メモリ API を使用すると、メモリのある領域を共有して、 プロセス間で"
5866 "情報をやり取りすることができる。"
5867
5868 #. type: Plain text
5869 #: build/C/man7/shm_overview.7:35
5870 msgid "The interfaces employed in the API are:"
5871 msgstr "この API では以下のインターフェースが採用されている。"
5872
5873 #. type: TP
5874 #: build/C/man7/shm_overview.7:35
5875 #, no-wrap
5876 msgid "B<shm_open>(3)"
5877 msgstr "B<shm_open>(3)"
5878
5879 #. type: Plain text
5880 #: build/C/man7/shm_overview.7:42
5881 msgid ""
5882 "Create and open a new object, or open an existing object.  This is analogous "
5883 "to B<open>(2).  The call returns a file descriptor for use by the other "
5884 "interfaces listed below."
5885 msgstr ""
5886 "新しいオブジェクトを生成しオープンする、もしくは 既存のオブジェクトをオープン"
5887 "する。これは B<open>(2)  と同じである。下記にある他のインターフェースで使用す"
5888 "る ファイルディスクリプタを返す。"
5889
5890 #. type: TP
5891 #: build/C/man7/shm_overview.7:42
5892 #, no-wrap
5893 msgid "B<ftruncate>(2)"
5894 msgstr "B<ftruncate>(2)"
5895
5896 #. type: Plain text
5897 #: build/C/man7/shm_overview.7:46
5898 msgid ""
5899 "Set the size of the shared memory object.  (A newly created shared memory "
5900 "object has a length of zero.)"
5901 msgstr "共有メモリオブジェクトの大きさを設定する。"
5902
5903 #. type: Plain text
5904 #: build/C/man7/shm_overview.7:50
5905 msgid ""
5906 "Map the shared memory object into the virtual address space of the calling "
5907 "process."
5908 msgstr ""
5909 "呼び出したプロセスの仮想アドレス空間に共有メモリオブジェクトを マップする。"
5910
5911 #. type: TP
5912 #: build/C/man7/shm_overview.7:50
5913 #, no-wrap
5914 msgid "B<munmap>(2)"
5915 msgstr "B<munmap>(2)"
5916
5917 #. type: Plain text
5918 #: build/C/man7/shm_overview.7:54
5919 msgid ""
5920 "Unmap the shared memory object from the virtual address space of the calling "
5921 "process."
5922 msgstr ""
5923 "呼び出したプロセスの仮想アドレス空間から 共有メモリオブジェクトをアンマップす"
5924 "る。"
5925
5926 #. type: TP
5927 #: build/C/man7/shm_overview.7:54
5928 #, no-wrap
5929 msgid "B<shm_unlink>(3)"
5930 msgstr "B<shm_unlink>(3)"
5931
5932 #. type: Plain text
5933 #: build/C/man7/shm_overview.7:57
5934 msgid "Remove a shared memory object name."
5935 msgstr "共有メモリオブジェクト名を削除する。"
5936
5937 #. type: TP
5938 #: build/C/man7/shm_overview.7:57
5939 #, no-wrap
5940 msgid "B<close>(2)"
5941 msgstr "B<close>(2)"
5942
5943 #. type: Plain text
5944 #: build/C/man7/shm_overview.7:62
5945 msgid ""
5946 "Close the file descriptor allocated by B<shm_open>(3)  when it is no longer "
5947 "needed."
5948 msgstr ""
5949 "B<shm_open>(3)  で割り当てられたファイルディスクリプタが不要になった際に、 そ"
5950 "のファイルディスクリプタをクローズする。"
5951
5952 #. type: TP
5953 #: build/C/man7/shm_overview.7:62
5954 #, no-wrap
5955 msgid "B<fstat>(2)"
5956 msgstr "B<fstat>(2)"
5957
5958 #. type: Plain text
5959 #: build/C/man7/shm_overview.7:76
5960 msgid ""
5961 "Obtain a I<stat> structure that describes the shared memory object.  Among "
5962 "the information returned by this call are the object's size (I<st_size>), "
5963 "permissions (I<st_mode>), owner (I<st_uid>), and group (I<st_gid>)."
5964 msgstr ""
5965 "その共有メモリオブジェクトについての情報が入った I<stat> 構造体を取得する。 "
5966 "このシステムコールが返す情報には、オブジェクトのサイズ (I<st_size>)、 許可属"
5967 "性 (I<st_mode>)、 所有者 (I<st_uid>)、 グループ (I<st_gid>)  がある。"
5968
5969 #. type: TP
5970 #: build/C/man7/shm_overview.7:76
5971 #, no-wrap
5972 msgid "B<fchown>(2)"
5973 msgstr "B<fchown>(2)"
5974
5975 #. type: Plain text
5976 #: build/C/man7/shm_overview.7:79
5977 msgid "To change the ownership of a shared memory object."
5978 msgstr "共有メモリオブジェクトの所有権を変更する。"
5979
5980 #. type: TP
5981 #: build/C/man7/shm_overview.7:79
5982 #, no-wrap
5983 msgid "B<fchmod>(2)"
5984 msgstr "B<fchmod>(2)"
5985
5986 #. type: Plain text
5987 #: build/C/man7/shm_overview.7:82
5988 msgid "To change the permissions of a shared memory object."
5989 msgstr "共有メモリオブジェクトの許可属性を変更する。"
5990
5991 #. type: SS
5992 #: build/C/man7/shm_overview.7:82
5993 #, no-wrap
5994 msgid "Versions"
5995 msgstr "Versions"
5996
5997 #. type: Plain text
5998 #: build/C/man7/shm_overview.7:84
5999 msgid "POSIX shared memory is supported since Linux 2.4 and glibc 2.2."
6000 msgstr "POSIX 共有メモリは Linux 2.4 と glibc 2.2 以降でサポートされている。"
6001
6002 #. type: SS
6003 #: build/C/man7/shm_overview.7:84
6004 #, no-wrap
6005 msgid "Persistence"
6006 msgstr "持続性"
6007
6008 #. type: Plain text
6009 #: build/C/man7/shm_overview.7:89
6010 msgid ""
6011 "POSIX shared memory objects have kernel persistence: a shared memory object "
6012 "will exist until the system is shut down, or until all processes have "
6013 "unmapped the object and it has been deleted with B<shm_unlink>(3)"
6014 msgstr ""
6015 "POSIX 共有メモリオブジェクトはカーネル内で保持される。 共有メモリオブジェクト"
6016 "は、システムがシャットダウンされるか、 全てのプロセスがそのオブジェクトをアン"
6017 "マップし、 B<shm_unlink>(3)  で削除されるまで、存在し続ける。"
6018
6019 #. type: SS
6020 #: build/C/man7/shm_overview.7:89
6021 #, no-wrap
6022 msgid "Linking"
6023 msgstr "リンク"
6024
6025 #. type: Plain text
6026 #: build/C/man7/shm_overview.7:94
6027 msgid ""
6028 "Programs using the POSIX shared memory API must be compiled with I<cc -lrt> "
6029 "to link against the real-time library, I<librt>."
6030 msgstr ""
6031 "POSIX 共有メモリ API を使用したプログラムは I<cc -lrt> でコンパイルし、リアル"
6032 "タイムライブラリ I<librt> とリンクしなければならない。"
6033
6034 #. type: SS
6035 #: build/C/man7/shm_overview.7:94
6036 #, no-wrap
6037 msgid "Accessing shared memory objects via the file system"
6038 msgstr "ファイルシステム経由での共有メモリオブジェクトへのアクセス"
6039
6040 #. type: Plain text
6041 #: build/C/man7/shm_overview.7:101
6042 msgid ""
6043 "On Linux, shared memory objects are created in a (I<tmpfs>)  virtual file "
6044 "system, normally mounted under I</dev/shm>.  Since kernel 2.6.19, Linux "
6045 "supports the use of access control lists (ACLs)  to control the permissions "
6046 "of objects in the virtual file system."
6047 msgstr ""
6048 "Linux では、共有メモリオブジェクトは通常 I</dev/shm> 以下にマウントされる仮想"
6049 "ファイルシステム (I<tmpfs>)  内に作成される。 カーネル 2.6.19 以降の Linux で"
6050 "は、 仮想ファイルシステム内のオブジェクトの許可属性の制御に、 アクセス制御リ"
6051 "スト (ACL; access control lists) を使うことができる。"
6052
6053 #. type: Plain text
6054 #: build/C/man7/shm_overview.7:106
6055 msgid ""
6056 "Typically, processes must synchronize their access to a shared memory "
6057 "object, using, for example, POSIX semaphores."
6058 msgstr ""
6059 "通常は、共有メモリオブジェクトにアクセスするプロセスは、 POSIX セマフォなどを"
6060 "使ってプロセス間で同期をとらなければならない。"
6061
6062 #. type: Plain text
6063 #: build/C/man7/shm_overview.7:114
6064 msgid ""
6065 "System V shared memory (B<shmget>(2), B<shmop>(2), etc.) is an older shared "
6066 "memory API.  POSIX shared memory provides a simpler, and better designed "
6067 "interface; on the other hand POSIX shared memory is somewhat less widely "
6068 "available (especially on older systems) than System V shared memory."
6069 msgstr ""
6070 "System V 共有メモリ (B<shmget>(2), B<shmop>(2)  など) は古い共有メモリ API で"
6071 "ある。 POSIX 共有メモリは、より簡単で、うまく設計されたインタフェースを提供し"
6072 "ている。 一方で、POSIX 共有メモリは System V 共有メモリと比べると 利用できる"
6073 "システムが少ない (特に、古いシステムでは少ない)。"
6074
6075 #. type: Plain text
6076 #: build/C/man7/shm_overview.7:127
6077 msgid ""
6078 "B<fchmod>(2), B<fchown>(2), B<fstat>(2), B<ftruncate>(2), B<mmap>(2), "
6079 "B<mprotect>(2), B<munmap>(2), B<shmget>(2), B<shmop>(2), B<shm_open>(3), "
6080 "B<shm_unlink>(3), B<sem_overview>(7)"
6081 msgstr ""
6082 "B<fchmod>(2), B<fchown>(2), B<fstat>(2), B<ftruncate>(2), B<mmap>(2), "
6083 "B<mprotect>(2), B<munmap>(2), B<shmget>(2), B<shmop>(2), B<shm_open>(3), "
6084 "B<shm_unlink>(3), B<sem_overview>(7)"
6085
6086 #. type: TH
6087 #: build/C/man2/shmctl.2:43
6088 #, no-wrap
6089 msgid "SHMCTL"
6090 msgstr "SHMCTL"
6091
6092 #. type: TH
6093 #: build/C/man2/shmctl.2:43
6094 #, no-wrap
6095 msgid "2008-08-07"
6096 msgstr "2008-08-07"
6097
6098 #. type: Plain text
6099 #: build/C/man2/shmctl.2:46
6100 msgid "shmctl - shared memory control"
6101 msgstr "shmctl - 共有メモリ (shared memory) を制御する"
6102
6103 #. type: Plain text
6104 #: build/C/man2/shmctl.2:49 build/C/man2/shmget.2:42
6105 msgid "B<#include E<lt>sys/ipc.hE<gt>>"
6106 msgstr "B<#include E<lt>sys/ipc.hE<gt>>"
6107
6108 #. type: Plain text
6109 #: build/C/man2/shmctl.2:51 build/C/man2/shmget.2:44
6110 msgid "B<#include E<lt>sys/shm.hE<gt>>"
6111 msgstr "B<#include E<lt>sys/shm.hE<gt>>"
6112
6113 #. type: Plain text
6114 #: build/C/man2/shmctl.2:53
6115 msgid ""
6116 "B<int shmctl(int >I<shmid>B<, int >I<cmd>B<, struct shmid_ds *>I<buf>B<);>"
6117 msgstr ""
6118 "B<int shmctl(int >I<shmid>B<, int >I<cmd>B<, struct shmid_ds *>I<buf>B<);>"
6119
6120 #. type: Plain text
6121 #: build/C/man2/shmctl.2:60
6122 msgid ""
6123 "B<shmctl>()  performs the control operation specified by I<cmd> on the "
6124 "shared memory segment whose identifier is given in I<shmid>."
6125 msgstr ""
6126 "B<shmctl>()  は、識別子が I<shmid> の共有メモリ・セグメントに対して I<cmd> で"
6127 "指示した制御命令を実行する。"
6128
6129 #. type: Plain text
6130 #: build/C/man2/shmctl.2:65
6131 msgid ""
6132 "The I<buf> argument is a pointer to a I<shmid_ds> structure, defined in "
6133 "I<E<lt>sys/shm.hE<gt>> as follows:"
6134 msgstr ""
6135 "I<buf> 引き数は、 I<shmid_ds> 構造体へのポインタである。 この構造体は "
6136 "I<E<lt>sys/shm.hE<gt>> で以下のように定義されている"
6137
6138 #. type: Plain text
6139 #: build/C/man2/shmctl.2:79
6140 #, no-wrap
6141 msgid ""
6142 "struct shmid_ds {\n"
6143 "    struct ipc_perm shm_perm;    /* Ownership and permissions */\n"
6144 "    size_t          shm_segsz;   /* Size of segment (bytes) */\n"
6145 "    time_t          shm_atime;   /* Last attach time */\n"
6146 "    time_t          shm_dtime;   /* Last detach time */\n"
6147 "    time_t          shm_ctime;   /* Last change time */\n"
6148 "    pid_t           shm_cpid;    /* PID of creator */\n"
6149 "    pid_t           shm_lpid;    /* PID of last shmat(2)/shmdt(2) */\n"
6150 "    shmatt_t        shm_nattch;  /* No. of current attaches */\n"
6151 "    ...\n"
6152 "};\n"
6153 msgstr ""
6154 "struct shmid_ds {\n"
6155 "    struct ipc_perm shm_perm;    /* 所有権と許可 */\n"
6156 "    size_t          shm_segsz;   /* セグメントのサイズ (バイト) */\n"
6157 "    time_t          shm_atime;   /* 最後の付加 (attach) の時刻 */\n"
6158 "    time_t          shm_dtime;   /* 最後の分離 (detach) の時刻 */\n"
6159 "    time_t          shm_ctime;   /* 最後に変更が行われた時刻 */\n"
6160 "    pid_t           shm_cpid;    /* 作成者 (creator) の PID */\n"
6161 "    pid_t           shm_lpid;    /* 最後の shmat(2)/shmdt(2) の PID */\n"
6162 "    shmatt_t        shm_nattch;  /* 現在付加されている数 */\n"
6163 "    ...\n"
6164 "};\n"
6165
6166 #. type: Plain text
6167 #: build/C/man2/shmctl.2:87
6168 msgid ""
6169 "The I<ipc_perm> structure is defined in I<E<lt>sys/ipc.hE<gt>> as follows "
6170 "(the highlighted fields are settable using B<IPC_SET>):"
6171 msgstr ""
6172 "I<ipc_perm> 構造体は I<E<lt>sys/ipc.hE<gt>> で以下のように定義されている (強"
6173 "調されたフィールドは B<IPC_SET> を使って設定可能である):"
6174
6175 #. type: Plain text
6176 #: build/C/man2/shmctl.2:100
6177 #, no-wrap
6178 msgid ""
6179 "struct ipc_perm {\n"
6180 "    key_t          __key;    /* Key supplied to shmget(2) */\n"
6181 "    uid_t          B<uid>;      /* Effective UID of owner */\n"
6182 "    gid_t          B<gid>;      /* Effective GID of owner */\n"
6183 "    uid_t          cuid;     /* Effective UID of creator */\n"
6184 "    gid_t          cgid;     /* Effective GID of creator */\n"
6185 "    unsigned short B<mode>;     /* B<Permissions> + SHM_DEST and\n"
6186 "                                SHM_LOCKED flags */\n"
6187 "    unsigned short __seq;    /* Sequence number */\n"
6188 "};\n"
6189 msgstr ""
6190 "struct ipc_perm {\n"
6191 "    key_t          __key;    /* shmget(2) に与えられるキー */\n"
6192 "    uid_t          B<uid>;      /* 所有者の実効 UID */\n"
6193 "    gid_t          B<gid>;      /* 所有者の実効 GID */\n"
6194 "    uid_t          cuid;     /* 作成者の実効 UID */\n"
6195 "    gid_t          cgid;     /* 作成者の実効 GID */\n"
6196 "    unsigned short B<mode>;     /* B<許可> + SHM_DEST と\n"
6197 "                                SHM_LOCKED フラグ */\n"
6198 "    unsigned short __seq;    /* シーケンス番号 */\n"
6199 "};\n"
6200
6201 #. type: Plain text
6202 #: build/C/man2/shmctl.2:106
6203 msgid "Valid values for I<cmd> are:"
6204 msgstr "I<cmd> として有効な値は以下の通り:"
6205
6206 #. type: TP
6207 #: build/C/man2/shmctl.2:107
6208 #, no-wrap
6209 msgid "B<IPC_STAT>"
6210 msgstr "B<IPC_STAT>"
6211
6212 #. type: Plain text
6213 #: build/C/man2/shmctl.2:116
6214 msgid ""
6215 "Copy information from the kernel data structure associated with I<shmid> "
6216 "into the I<shmid_ds> structure pointed to by I<buf>.  The caller must have "
6217 "read permission on the shared memory segment."
6218 msgstr ""
6219 "I<shmid> に関連づけられたカーネルデータ構造体の情報を I<buf> で指された "
6220 "I<shmid_ds> 構造体にコピーする。 呼び出し元は共有メモリ・セグメントに対する "
6221 "読み込み許可を持たなければならない。"
6222
6223 #. type: TP
6224 #: build/C/man2/shmctl.2:116
6225 #, no-wrap
6226 msgid "B<IPC_SET>"
6227 msgstr "B<IPC_SET>"
6228
6229 #. type: Plain text
6230 #: build/C/man2/shmctl.2:134
6231 msgid ""
6232 "Write the values of some members of the I<shmid_ds> structure pointed to by "
6233 "I<buf> to the kernel data structure associated with this shared memory "
6234 "segment, updating also its I<shm_ctime> member.  The following fields can be "
6235 "changed: I<shm_perm.uid>, I<shm_perm.gid>, and (the least significant 9 bits "
6236 "of) I<shm_perm.mode>.  The effective UID of the calling process must match "
6237 "the owner (I<shm_perm.uid>)  or creator (I<shm_perm.cuid>)  of the shared "
6238 "memory segment, or the caller must be privileged."
6239 msgstr ""
6240 "I<buf> によって指される I<shmid_ds> 構造体のいくつかのメンバーの値を、 この共"
6241 "有メモリ・セグメントに関連づけられたカーネルデータ構造体に書き込み、 "
6242 "I<shm_ctime> メンバーも更新する。 以下のフィールドは変更できる。 I<shm_perm."
6243 "uid>, I<shm_perm.gid>, I<shm_perm.mode> (の最下位 9 ビット)。 呼び出したプロ"
6244 "セスの実効 UID が所有者 (I<shm_perm.uid>)  または作成者 (I<shm_perm.cuid>)  "
6245 "と一致するか、呼び出し元が特権を持たなければならない。"
6246
6247 #. type: TP
6248 #: build/C/man2/shmctl.2:134
6249 #, no-wrap
6250 msgid "B<IPC_RMID>"
6251 msgstr "B<IPC_RMID>"
6252
6253 #. type: Plain text
6254 #: build/C/man2/shmctl.2:151
6255 msgid ""
6256 "Mark the segment to be destroyed.  The segment will only actually be "
6257 "destroyed after the last process detaches it (i.e., when the I<shm_nattch> "
6258 "member of the associated structure I<shmid_ds> is zero).  The caller must be "
6259 "the owner or creator, or be privileged.  If a segment has been marked for "
6260 "destruction, then the (nonstandard)  B<SHM_DEST> flag of the I<shm_perm."
6261 "mode> field in the associated data structure retrieved by B<IPC_STAT> will "
6262 "be set."
6263 msgstr ""
6264 "セグメントに破棄済みのマークを付ける。 セグメントは、実際には最後プロセスがセ"
6265 "グメントを分離した (関連する I<shmid_ds> 構造体の I<shm_nattch> メンバーが 0 "
6266 "になった) 後でのみ破棄される。 呼び出し元は所有者か作成者であるか、特権を持た"
6267 "なければならない。 セグメントに破棄のマークが付けられると、 関連するデータ構"
6268 "造体において I<shm_perm.mode> フィールドの (標準ではない)  B<SHM_DEST> フラグ"
6269 "が設定される。 このデータ構造体は B<IPC_STAT> で取得される。"
6270
6271 #. type: Plain text
6272 #: build/C/man2/shmctl.2:154
6273 msgid ""
6274 "The caller I<must> ensure that a segment is eventually destroyed; otherwise "
6275 "its pages that were faulted in will remain in memory or swap."
6276 msgstr ""
6277 "呼び出し元は最終的にはセグメントを忘れずに破棄I<しなければならない>。 そうで"
6278 "なれば、フォールト (fault) されたページは メモリかスワップ (swap) に残り続け"
6279 "る。"
6280
6281 #. type: TP
6282 #: build/C/man2/shmctl.2:154
6283 #, no-wrap
6284 msgid "B<IPC_INFO> (Linux-specific)"
6285 msgstr "B<IPC_INFO> (Linux 固有)"
6286
6287 #. type: Plain text
6288 #: build/C/man2/shmctl.2:167
6289 msgid ""
6290 "Returns information about system-wide shared memory limits and parameters in "
6291 "the structure pointed to by I<buf>.  This structure is of type I<shminfo> "
6292 "(thus, a cast is required), defined in I<E<lt>sys/shm.hE<gt>> if the "
6293 "B<_GNU_SOURCE> feature test macro is defined:"
6294 msgstr ""
6295 "システム全体での共有メモリの制限とパラメータに関する情報を、 I<buf> が指す構"
6296 "造体に入れて返す。 この構造体は I<shminfo> 型である (そのためキャストが必要で"
6297 "ある)。 I<shminfo> は B<_GNU_SOURCE> 機能検査マクロが定義された場合に "
6298 "I<E<lt>sys/shm.hE<gt>> で以下のように定義される:"
6299
6300 #. type: Plain text
6301 #: build/C/man2/shmctl.2:181
6302 #, no-wrap
6303 msgid ""
6304 "struct  shminfo {\n"
6305 "    unsigned long shmmax; /* Maximum segment size */\n"
6306 "    unsigned long shmmin; /* Minimum segment size;\n"
6307 "                             always 1 */\n"
6308 "    unsigned long shmmni; /* Maximum number of segments */\n"
6309 "    unsigned long shmseg; /* Maximum number of segments\n"
6310 "                             that a process can attach;\n"
6311 "                             unused within kernel */\n"
6312 "    unsigned long shmall; /* Maximum number of pages of\n"
6313 "                             shared memory, system-wide */\n"
6314 "};\n"
6315 msgstr ""
6316 "struct  shminfo {\n"
6317 "    unsigned long shmmax; /* 最大セグメントサイズ */\n"
6318 "    unsigned long shmmin; /* 最小セグメントサイズ。\n"
6319 "                             常に 1 */\n"
6320 "    unsigned long shmmni; /* 最大セグメント数 */\n"
6321 "    unsigned long shmseg; /* プロセスが付加できる\n"
6322 "                             セグメントの最大数。\n"
6323 "                             カーネル内では未使用 */\n"
6324 "    unsigned long shmall; /* 共有メモリの最大ページ数。\n"
6325 "                             システム全体での値 */\n"
6326 "};\n"
6327
6328 #. type: Plain text
6329 #: build/C/man2/shmctl.2:194
6330 msgid ""
6331 "The I<shmmni>, I<shmmax>, and I<shmall> settings can be changed via I</proc> "
6332 "files of the same name; see B<proc>(5)  for details."
6333 msgstr ""
6334 "設定 I<shmmni>, I<shmmax>, I<shmall> は I</proc> にある同じ名前のファイル経由"
6335 "で変更可能である。 詳しくは B<proc>(5)  を参照。"
6336
6337 #. type: TP
6338 #: build/C/man2/shmctl.2:194
6339 #, no-wrap
6340 msgid "B<SHM_INFO> (Linux-specific)"
6341 msgstr "B<SHM_INFO> (Linux 固有)"
6342
6343 #. type: Plain text
6344 #: build/C/man2/shmctl.2:205
6345 msgid ""
6346 "Returns a I<shm_info> structure whose fields contain information about "
6347 "system resources consumed by shared memory.  This structure is defined in "
6348 "I<E<lt>sys/shm.hE<gt>> if the B<_GNU_SOURCE> feature test macro is defined:"
6349 msgstr ""
6350 "共有メモリが消費しているシステム資源に関する情報を 格納した I<shm_info> 構造"
6351 "体を返す。 この構造体は、 B<_GNU_SOURCE> 機能検査マクロが定義された場合に "
6352 "I<E<lt>sys/shm.hE<gt>> で以下のように定義される:"
6353
6354 #. type: Plain text
6355 #: build/C/man2/shmctl.2:222
6356 #, no-wrap
6357 msgid ""
6358 "struct shm_info {\n"
6359 "    int           used_ids; /* # of currently existing\n"
6360 "                               segments */\n"
6361 "    unsigned long shm_tot;  /* Total number of shared\n"
6362 "                               memory pages */\n"
6363 "    unsigned long shm_rss;  /* # of resident shared\n"
6364 "                               memory pages */\n"
6365 "    unsigned long shm_swp;  /* # of swapped shared\n"
6366 "                               memory pages */\n"
6367 "    unsigned long swap_attempts;\n"
6368 "                            /* Unused since Linux 2.4 */\n"
6369 "    unsigned long swap_successes;\n"
6370 "                            /* Unused since Linux 2.4 */\n"
6371 "};\n"
6372 msgstr ""
6373 "struct shm_info {\n"
6374 "    int           used_ids; /* 現在存在するセグメント数 */\n"
6375 "    unsigned long shm_tot;  /* 共有メモリのページ総数 */\n"
6376 "    unsigned long shm_rss;  /* メモリ上にある (スワップされて\n"
6377 "                               いない) 共有メモリページ数 */\n"
6378 "    unsigned long shm_swp;  /* スワップされている共有メモリ\n"
6379 "                               ページ数 */\n"
6380 "    unsigned long swap_attempts;\n"
6381 "                            /* Linux 2.4 以降では未使用 */\n"
6382 "    unsigned long swap_successes;\n"
6383 "                            /* Linux 2.4 以降では未使用 */\n"
6384 "};\n"
6385
6386 #. type: TP
6387 #: build/C/man2/shmctl.2:224
6388 #, no-wrap
6389 msgid "B<SHM_STAT> (Linux-specific)"
6390 msgstr "B<SHM_STAT> (Linux 固有)"
6391
6392 #. type: Plain text
6393 #: build/C/man2/shmctl.2:235
6394 msgid ""
6395 "Returns a I<shmid_ds> structure as for B<IPC_STAT>.  However, the I<shmid> "
6396 "argument is not a segment identifier, but instead an index into the kernel's "
6397 "internal array that maintains information about all shared memory segments "
6398 "on the system."
6399 msgstr ""
6400 "B<IPC_STAT> と同じく I<shmid_ds> 構造体を返す。 但し、 I<shmid> 引き数は、セ"
6401 "グメント識別子ではなく、システム上の全ての共有メモリ セグメントに関する情報を"
6402 "管理するカーネルの内部配列へのインデックス である。"
6403
6404 #. type: Plain text
6405 #: build/C/man2/shmctl.2:238
6406 msgid ""
6407 "The caller can prevent or allow swapping of a shared memory segment with the "
6408 "following I<cmd> values:"
6409 msgstr ""
6410 "呼び出し元は、I<cmd> に以下の値を指定することで、共有メモリ・セグメントが ス"
6411 "ワップされることを防止したり、許可したりできる:"
6412
6413 #. type: TP
6414 #: build/C/man2/shmctl.2:239
6415 #, no-wrap
6416 msgid "B<SHM_LOCK> (Linux-specific)"
6417 msgstr "B<SHM_LOCK> (Linux 固有)"
6418
6419 #. type: Plain text
6420 #: build/C/man2/shmctl.2:251
6421 msgid ""
6422 "Prevent swapping of the shared memory segment.  The caller must fault in any "
6423 "pages that are required to be present after locking is enabled.  If a "
6424 "segment has been locked, then the (nonstandard)  B<SHM_LOCKED> flag of the "
6425 "I<shm_perm.mode> field in the associated data structure retrieved by "
6426 "B<IPC_STAT> will be set."
6427 msgstr ""
6428 "共有メモリ・セグメントをスワップすることを防止する。 ロックが有効になった後、"
6429 "呼び出し元は、 存在することが要求された全てのページをフォールトさせなければな"
6430 "らない。 セグメントがロックされると、 関連するデータ構造体において "
6431 "I<shm_perm.mode> フィールドの (標準的ではない)  B<SHM_LOCKED> フラグが設定さ"
6432 "れる。 このデータ構造体は B<IPC_STAT> で取得される。"
6433
6434 #. type: TP
6435 #: build/C/man2/shmctl.2:251
6436 #, no-wrap
6437 msgid "B<SHM_UNLOCK> (Linux-specific)"
6438 msgstr "B<SHM_UNLOCK> (Linux 固有)"
6439
6440 #. type: Plain text
6441 #: build/C/man2/shmctl.2:254
6442 msgid "Unlock the segment, allowing it to be swapped out."
6443 msgstr "セグメントのロックを解除し、スワップ・アウトすることを可能にする。"
6444
6445 #.  There was some weirdness in 2.6.9: SHM_LOCK and SHM_UNLOCK could
6446 #.  be applied to a segment, regardless of ownership of the segment.
6447 #.  This was a botch-up in the move to RLIMIT_MEMLOCK, and was fixed
6448 #.  in 2.6.10.  MTK, May 2005
6449 #. type: Plain text
6450 #: build/C/man2/shmctl.2:272
6451 msgid ""
6452 "In kernels before 2.6.10, only a privileged process could employ B<SHM_LOCK> "
6453 "and B<SHM_UNLOCK>.  Since kernel 2.6.10, an unprivileged process can employ "
6454 "these operations if its effective UID matches the owner or creator UID of "
6455 "the segment, and (for B<SHM_LOCK>)  the amount of memory to be locked falls "
6456 "within the B<RLIMIT_MEMLOCK> resource limit (see B<setrlimit>(2))."
6457 msgstr ""
6458 "2.6.10 より前のカーネルでは、特権プロセスだけが B<SHM_LOCK> と B<SHM_UNLOCK> "
6459 "を利用することができた。 2.6.10 以降のカーネルでは、非特権プロセスであっても"
6460 "次の条件を満たせば これらの操作を利用することができる。その条件とは、プロセス"
6461 "の実効 UID がそのセグメントの所有者もしくは作成者の UID と一致し、 "
6462 "(B<SHM_LOCK> の場合には) ロックするメモリの合計が B<RLIMIT_MEMLOCK> リソース"
6463 "上限 (B<setrlimit>(2)  参照) の範囲内に入っていることである。"
6464
6465 #. type: Plain text
6466 #: build/C/man2/shmctl.2:290
6467 msgid ""
6468 "A successful B<IPC_INFO> or B<SHM_INFO> operation returns the index of the "
6469 "highest used entry in the kernel's internal array recording information "
6470 "about all shared memory segments.  (This information can be used with "
6471 "repeated B<SHM_STAT> operations to obtain information about all shared "
6472 "memory segments on the system.)  A successful B<SHM_STAT> operation returns "
6473 "the identifier of the shared memory segment whose index was given in "
6474 "I<shmid>.  Other operations return 0 on success."
6475 msgstr ""
6476 "B<IPC_INFO> と B<SHM_INFO> 操作は、成功すると、全ての共有メモリセグメントに関"
6477 "する情報を 管理しているカーネルの内部配列の使用中エントリのインデックスの う"
6478 "ち最大値を返す (この情報は、システムの全ての共有メモリセグメントに関する情報"
6479 "を 取得するために、 B<SHM_STAT> 操作を繰り返し実行する際に使用できる)。 "
6480 "B<SHM_STAT> 操作は、成功すると、 I<shmid> で指定されたインデックスを持つ共有"
6481 "メモリセグメントの識別子を返す。 他の操作は、成功の場合 0 を返す。"
6482
6483 #. type: Plain text
6484 #: build/C/man2/shmctl.2:294
6485 msgid "On error, -1 is returned, and I<errno> is set appropriately."
6486 msgstr "エラーの場合は -1 を返し、 I<errno> を適切に設定する。"
6487
6488 #. type: Plain text
6489 #: build/C/man2/shmctl.2:303
6490 msgid ""
6491 "B<IPC_STAT> or B<SHM_STAT> is requested and I<shm_perm.mode> does not allow "
6492 "read access for I<shmid>, and the calling process does not have the "
6493 "B<CAP_IPC_OWNER> capability."
6494 msgstr ""
6495 "B<IPC_STAT> または B<SHM_STAT> が要求され、 I<shm_perm.mode> が I<shmid> への"
6496 "読み込みアクセスを許しておらず、 かつ呼び出したプロセスが B<CAP_IPC_OWNER> "
6497 "ケーパビリティ (capability) を持っていない。"
6498
6499 #. type: Plain text
6500 #: build/C/man2/shmctl.2:314
6501 msgid ""
6502 "The argument I<cmd> has value B<IPC_SET> or B<IPC_STAT> but the address "
6503 "pointed to by I<buf> isn't accessible."
6504 msgstr ""
6505 "I<cmd> 引き数に B<IPC_SET> か B<IPC_STAT> が指定されたが I<buf> で指されてい"
6506 "るアドレスにアクセスできない。"
6507
6508 #. type: TP
6509 #: build/C/man2/shmctl.2:314
6510 #, no-wrap
6511 msgid "B<EIDRM>"
6512 msgstr "B<EIDRM>"
6513
6514 #. type: Plain text
6515 #: build/C/man2/shmctl.2:317
6516 msgid "I<shmid> points to a removed identifier."
6517 msgstr "I<shmid> が削除 (remove) された識別子 (identifier) を指している。"
6518
6519 #. type: Plain text
6520 #: build/C/man2/shmctl.2:326
6521 msgid ""
6522 "I<shmid> is not a valid identifier, or I<cmd> is not a valid command.  Or: "
6523 "for a B<SHM_STAT> operation, the index value specified in I<shmid> referred "
6524 "to an array slot that is currently unused."
6525 msgstr ""
6526 "I<shmid> が有効な識別子でないか、 I<cmd> が有効なコマンドでない。 もしくは、 "
6527 "B<SHM_STAT> 操作の場合に、 I<shmid> で指定されたインデックス値が現在未使用の"
6528 "配列のスロットを参照していた。"
6529
6530 #. type: Plain text
6531 #: build/C/man2/shmctl.2:337
6532 msgid ""
6533 "(In kernels since 2.6.9), B<SHM_LOCK> was specified and the size of the to-"
6534 "be-locked segment would mean that the total bytes in locked shared memory "
6535 "segments would exceed the limit for the real user ID of the calling "
6536 "process.  This limit is defined by the B<RLIMIT_MEMLOCK> soft resource limit "
6537 "(see B<setrlimit>(2))."
6538 msgstr ""
6539 "(2.6.9 以降のカーネルにおいて)  B<SHM_LOCK> が指定され、 ロックされる予定のセ"
6540 "グメントのサイズ (ロックされる共有メモリ・セグメントの合計バイト数) が、 呼び"
6541 "出したプロセスの実ユーザー ID についての制限を超えた。 この制限は "
6542 "B<RLIMIT_MEMLOCK> ソフト資源制限で定義される (B<setrlimit>(2)  を参照)。"
6543
6544 #. type: TP
6545 #: build/C/man2/shmctl.2:337
6546 #, no-wrap
6547 msgid "B<EOVERFLOW>"
6548 msgstr "B<EOVERFLOW>"
6549
6550 #. type: Plain text
6551 #: build/C/man2/shmctl.2:342
6552 msgid ""
6553 "B<IPC_STAT> is attempted, and the GID or UID value is too large to be stored "
6554 "in the structure pointed to by I<buf>."
6555 msgstr ""
6556 "B<IPC_STAT> が試みられ、GID や UID の値が I<buf> で指示される構造体に格納する"
6557 "には大き過ぎる。"
6558
6559 #. type: Plain text
6560 #: build/C/man2/shmctl.2:354
6561 msgid ""
6562 "B<IPC_SET> or B<IPC_RMID> is attempted, and the effective user ID of the "
6563 "calling process is not that of the creator (found in I<shm_perm.cuid>), or "
6564 "the owner (found in I<shm_perm.uid>), and the process was not privileged "
6565 "(Linux: did not have the B<CAP_SYS_ADMIN> capability)."
6566 msgstr ""
6567 "B<IPC_SET> か B<IPC_RMID> が試みられ、 呼び出したプロセスの実効ユーザー ID が"
6568 "作成者 (I<shm_perm.cuid>)  でも所有者 (I<shm_perm.uid>)  でもなく、プロセスが"
6569 "特権を持たない (Linux では B<CAP_SYS_ADMIN> ケーパビリティを持たない)。"
6570
6571 #. type: Plain text
6572 #: build/C/man2/shmctl.2:366
6573 msgid ""
6574 "Or (in kernels before 2.6.9), B<SHM_LOCK> or B<SHM_UNLOCK> was specified, "
6575 "but the process was not privileged (Linux: did not have the B<CAP_IPC_LOCK> "
6576 "capability).  (Since Linux 2.6.9, this error can also occur if the "
6577 "B<RLIMIT_MEMLOCK> is 0 and the caller is not privileged.)"
6578 msgstr ""
6579 "または (2.6.9 より前のカーネルで)  B<SHM_LOCK> または B<SHM_UNLOCK> が指定さ"
6580 "れているが、プロセスが特権を持たない (Linux では B<CAP_IPC_LOCK> ケーパビリ"
6581 "ティを持たない)。 (Linux 2.6.9 以降では、 B<RLIMIT_MEMLOCK> が 0 で呼び出し元"
6582 "が特権を持たない場合にも、このエラーが起こる。)"
6583
6584 #.  SVr4 documents an additional error condition EMFILE.
6585 #. type: Plain text
6586 #: build/C/man2/shmctl.2:371 build/C/man2/shmget.2:232
6587 #: build/C/man2/shmop.2:229
6588 msgid "SVr4, POSIX.1-2001."
6589 msgstr "SVr4, POSIX.1-2001."
6590
6591 #. type: Plain text
6592 #: build/C/man2/shmctl.2:382
6593 msgid ""
6594 "The B<IPC_INFO>, B<SHM_STAT> and B<SHM_INFO> operations are used by the "
6595 "B<ipcs>(1)  program to provide information on allocated resources.  In the "
6596 "future these may modified or moved to a /proc file system interface."
6597 msgstr ""
6598 "B<IPC_INFO>, B<SHM_STAT>, B<SHM_INFO> 操作は、 B<ipcs>(1)  プログラムで割り当"
6599 "て済の資源に関する情報を提供するために 使用されている。将来、これらの操作は変"
6600 "更されたり、 /proc ファイルシステムのインタフェースに移動されるかもしれない。"
6601
6602 #. type: Plain text
6603 #: build/C/man2/shmctl.2:390
6604 msgid ""
6605 "Linux permits a process to attach (B<shmat>(2))  a shared memory segment "
6606 "that has already been marked for deletion using I<shmctl(IPC_RMID)>.  This "
6607 "feature is not available on other UNIX implementations; portable "
6608 "applications should avoid relying on it."
6609 msgstr ""
6610 "Linux では、 I<shmctl(IPC_RMID)> を使ってすでに削除マークがつけられている共有"
6611 "メモリ・セグメントを あるプロセスが付加 (attach)  (B<shmat>(2))  することを許"
6612 "可している。 この機能は他の UNIX の実装では利用できない。 移植性を考慮したア"
6613 "プリケーションではこれに依存しないようにすべきである。"
6614
6615 #. type: Plain text
6616 #: build/C/man2/shmctl.2:403
6617 msgid ""
6618 "Various fields in a I<struct shmid_ds> were typed as I<short> under Linux "
6619 "2.2 and have become I<long> under Linux 2.4.  To take advantage of this, a "
6620 "recompilation under glibc-2.1.91 or later should suffice.  (The kernel "
6621 "distinguishes old and new calls by an B<IPC_64> flag in I<cmd>.)"
6622 msgstr ""
6623 "I<構造体 shmid_ds> 内の多くのフィールドは、 Linux 2.2 では I<short> 型だった"
6624 "が、Linux 2.4 では I<long> 型になった。 この利点を生かすには、glibc-2.1.91 以"
6625 "降の環境下で 再コンパイルすれば十分である。 カーネルは新しい形式の呼び出しと"
6626 "古い形式の呼び出しを I<cmd> 内の B<IPC_64> フラグで区別する。"
6627
6628 #. type: Plain text
6629 #: build/C/man2/shmctl.2:410
6630 msgid ""
6631 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
6632 "B<svipc>(7)"
6633 msgstr ""
6634 "B<mlock>(2), B<setrlimit>(2), B<shmget>(2), B<shmop>(2), B<capabilities>(7), "
6635 "B<shm_overview>(7), B<svipc>(7)"
6636
6637 #. type: TH
6638 #: build/C/man2/shmget.2:36
6639 #, no-wrap
6640 msgid "SHMGET"
6641 msgstr "SHMGET"
6642
6643 #. type: TH
6644 #: build/C/man2/shmget.2:36
6645 #, no-wrap
6646 msgid "2006-05-02"
6647 msgstr "2006-05-02"
6648
6649 #. type: Plain text
6650 #: build/C/man2/shmget.2:39
6651 msgid "shmget - allocates a shared memory segment"
6652 msgstr "shmget - 共有メモリ・セグメントを割り当てる"
6653
6654 #. type: Plain text
6655 #: build/C/man2/shmget.2:46
6656 msgid "B<int shmget(key_t >I<key>B<, size_t >I<size>B<, int >I<shmflg>B<);>"
6657 msgstr "B<int shmget(key_t >I<key>B<, size_t >I<size>B<, int >I<shmflg>B<);>"
6658
6659 #. type: Plain text
6660 #: build/C/man2/shmget.2:70
6661 msgid ""
6662 "B<shmget>()  returns the identifier of the shared memory segment associated "
6663 "with the value of the argument I<key>.  A new shared memory segment, with "
6664 "size equal to the value of I<size> rounded up to a multiple of B<PAGE_SIZE>, "
6665 "is created if I<key> has the value B<IPC_PRIVATE> or I<key> isn't "
6666 "B<IPC_PRIVATE>, no shared memory segment corresponding to I<key> exists, and "
6667 "B<IPC_CREAT> is specified in I<shmflg>."
6668 msgstr ""
6669 "B<shmget>()  は I<key> 引き数に対応する共有メモリ・セグメントの識別子を返"
6670 "す。 I<key> の値が B<IPC_PRIVATE> の場合、もしくは I<key> に対応する共有メモ"
6671 "リ・セグメントが存在せず、 I<shmflg> に B<IPC_CREAT> が指定されていた場合、 "
6672 "新しい共有メモリ・セグメントを作成する。 作成される共有メモリ・セグメント"
6673 "は、 I<size> 引き数の値を B<PAGE_SIZE> の倍数へと切り上げた (round up) 大きさ"
6674 "となる。"
6675
6676 #. type: Plain text
6677 #: build/C/man2/shmget.2:89
6678 msgid ""
6679 "If I<shmflg> specifies both B<IPC_CREAT> and B<IPC_EXCL> and a shared memory "
6680 "segment already exists for I<key>, then B<shmget>()  fails with I<errno> set "
6681 "to B<EEXIST>.  (This is analogous to the effect of the combination B<O_CREAT "
6682 "| O_EXCL> for B<open>(2).)"
6683 msgstr ""
6684 "I<shmflg> に B<IPC_CREAT> と B<IPC_EXCL> の両方が指定された場合、 I<key> に対"
6685 "応する共有メモリ・セグメントが既に存在すると、 B<shmget>()  は失敗し、 "
6686 "I<errno> に B<EEXIST> が設定される (これは B<open>(2)  に B<O_CREAT | "
6687 "O_EXCL> を指定した場合の動作と同じである)。"
6688
6689 #. type: Plain text
6690 #: build/C/man2/shmget.2:93
6691 msgid "The value I<shmflg> is composed of:"
6692 msgstr "I<shmflg> は以下の内容から構成される:"
6693
6694 #. type: TP
6695 #: build/C/man2/shmget.2:93
6696 #, no-wrap
6697 msgid "B<IPC_CREAT>"
6698 msgstr "B<IPC_CREAT>"
6699
6700 #. type: Plain text
6701 #: build/C/man2/shmget.2:100
6702 msgid ""
6703 "to create a new segment.  If this flag is not used, then B<shmget>()  will "
6704 "find the segment associated with I<key> and check to see if the user has "
6705 "permission to access the segment."
6706 msgstr ""
6707 "新しいセグメントを作成する。このフラグが指定されなかった場合、 B<shmget>()  "
6708 "は I<key> に対応するセグメントを探し、 ユーザがそのセグメントにアクセスする許"
6709 "可があるかどうかをチェックする。"
6710
6711 #. type: TP
6712 #: build/C/man2/shmget.2:100
6713 #, no-wrap
6714 msgid "B<IPC_EXCL>"
6715 msgstr "B<IPC_EXCL>"
6716
6717 #. type: Plain text
6718 #: build/C/man2/shmget.2:103
6719 msgid "used with B<IPC_CREAT> to ensure failure if the segment already exists."
6720 msgstr ""
6721 "B<IPC_CREAT> と共に使用し、セグメントが既に存在した場合には 失敗することを保"
6722 "証する。"
6723
6724 #. type: TP
6725 #: build/C/man2/shmget.2:103
6726 #, no-wrap
6727 msgid "I<mode_flags>"
6728 msgstr "I<mode_flags>"
6729
6730 #. type: Plain text
6731 #: build/C/man2/shmget.2:113
6732 msgid ""
6733 "(least significant 9 bits)  specifying the permissions granted to the owner, "
6734 "group, and world.  These bits have the same format, and the same meaning, as "
6735 "the I<mode> argument of B<open>(2).  Presently, the execute permissions are "
6736 "not used by the system."
6737 msgstr ""
6738 "(下位 9 ビット)  所有者、グループ、他人 (world) への許可を指定する。 これらの"
6739 "ビットは B<open>(2)  の I<mode> 引き数と同じ形式で同じ意味を持つ。 今のとこ"
6740 "ろ、システムは実行 (execute) 許可を参照しない。"
6741
6742 #. type: TP
6743 #: build/C/man2/shmget.2:113
6744 #, no-wrap
6745 msgid "B<SHM_HUGETLB> (since Linux 2.6)"
6746 msgstr "B<SHM_HUGETLB> (Linux 2.6 以降)"
6747
6748 #. type: Plain text
6749 #: build/C/man2/shmget.2:119
6750 msgid ""
6751 "Allocate the segment using \"huge pages.\" See the kernel source file "
6752 "I<Documentation/vm/hugetlbpage.txt> for further information."
6753 msgstr ""
6754 "\"ヒュージページ (huge page)\" を使うセグメントを割り当てる。 詳細な情報は、"
6755 "カーネル・ソースのファイル I<Documentation/vm/hugetlbpage.txt> を参照。"
6756
6757 #. type: TP
6758 #: build/C/man2/shmget.2:119
6759 #, no-wrap
6760 msgid "B<SHM_NORESERVE> (since Linux 2.6.15)"
6761 msgstr "B<SHM_NORESERVE> (Linux 2.6.15 以降)"
6762
6763 #.  As at 2.6.17-rc2, this flag has no effect if SHM_HUGETLB was also
6764 #.  specified.
6765 #. type: Plain text
6766 #: build/C/man2/shmget.2:138
6767 msgid ""
6768 "This flag serves the same purpose as the B<mmap>(2)  B<MAP_NORESERVE> flag.  "
6769 "Do not reserve swap space for this segment.  When swap space is reserved, "
6770 "one has the guarantee that it is possible to modify the segment.  When swap "
6771 "space is not reserved one might get B<SIGSEGV> upon a write if no physical "
6772 "memory is available.  See also the discussion of the file I</proc/sys/vm/"
6773 "overcommit_memory> in B<proc>(5)."
6774 msgstr ""
6775 "このフラグは、 B<mmap>(2)  の B<MAP_NORESERVE> フラグと同じ役割を果たす。 こ"
6776 "のセグメントに対するスワップ空間の予約を行わない。 スワップ空間を予約した場合"
6777 "は、そのセグメントの変更が必ず成功することが 保証される。スワップ空間の予約を"
6778 "行わなかった場合は、物理メモリに空きが ないと書き込み時に B<SIGSEGV> を受け取"
6779 "る可能性がある。 B<proc>(5)  にある I</proc/sys/vm/overcommit_memory> ファイ"
6780 "ルに関する議論も参照のこと。"
6781
6782 #. type: Plain text
6783 #: build/C/man2/shmget.2:146
6784 msgid ""
6785 "When a new shared memory segment is created, its contents are initialized to "
6786 "zero values, and its associated data structure, I<shmid_ds> (see B<shmctl>"
6787 "(2)), is initialized as follows:"
6788 msgstr ""
6789 "共有メモリ・セグメントが新たに作成される際、 共有メモリ・セグメントの内容は "
6790 "0 で初期化され、 関連情報を保持するデータ構造体 I<shmid_ds> は以下のように初"
6791 "期化される。"
6792
6793 #. type: Plain text
6794 #: build/C/man2/shmget.2:151
6795 msgid ""
6796 "I<shm_perm.cuid> and I<shm_perm.uid> are set to the effective user ID of the "
6797 "calling process."
6798 msgstr ""
6799 "I<shm_perm.cuid> と I<shm_perm.uid> に呼び出し元プロセスの実効 (effective) "
6800 "ユーザーID を設定する。"
6801
6802 #. type: Plain text
6803 #: build/C/man2/shmget.2:156
6804 msgid ""
6805 "I<shm_perm.cgid> and I<shm_perm.gid> are set to the effective group ID of "
6806 "the calling process."
6807 msgstr ""
6808 "I<shm_perm.cgid> と I<shm_perm.gid> に呼び出し元プロセスの実効グループID を設"
6809 "定する。"
6810
6811 #. type: Plain text
6812 #: build/C/man2/shmget.2:161
6813 msgid ""
6814 "The least significant 9 bits of I<shm_perm.mode> are set to the least "
6815 "significant 9 bit of I<shmflg>."
6816 msgstr ""
6817 "I<shm_perm.mode> の下位 9 ビットに I<shmflg> の下位 9 ビットを設定する。"
6818
6819 #. type: Plain text
6820 #: build/C/man2/shmget.2:165
6821 msgid "I<shm_segsz> is set to the value of I<size>."
6822 msgstr "I<shm_segsz> に I<size> の値を設定する。"
6823
6824 #. type: Plain text
6825 #: build/C/man2/shmget.2:172
6826 msgid "I<shm_lpid>, I<shm_nattch>, I<shm_atime> and I<shm_dtime> are set to 0."
6827 msgstr ""
6828 "I<shm_lpid>, I<shm_nattch>, I<shm_atime>, I<shm_dtime> に 0 を設定する。"
6829
6830 #. type: Plain text
6831 #: build/C/man2/shmget.2:175
6832 msgid "I<shm_ctime> is set to the current time."
6833 msgstr "I<shm_ctime> に現在の時刻を設定する。"
6834
6835 #. type: Plain text
6836 #: build/C/man2/shmget.2:178
6837 msgid ""
6838 "If the shared memory segment already exists, the permissions are verified, "
6839 "and a check is made to see if it is marked for destruction."
6840 msgstr ""
6841 "共有メモリ・セグメントが既に存在する場合、アクセス許可の検査と、 破壊 "
6842 "(destruction) マークがつけられていないかのチェックが行われる。"
6843
6844 #. type: Plain text
6845 #: build/C/man2/shmget.2:182
6846 msgid ""
6847 "A valid segment identifier, I<shmid>, is returned on success, -1 on error."
6848 msgstr ""
6849 "成功した場合、有効なセグメント識別子 I<shmid> が返される。エラーの場合、 -1 "
6850 "が返される。"
6851
6852 #. type: Plain text
6853 #: build/C/man2/shmget.2:186
6854 msgid "On failure, I<errno> is set to one of the following:"
6855 msgstr "失敗した場合は I<errno> が以下のどれかに設定される:"
6856
6857 #. type: Plain text
6858 #: build/C/man2/shmget.2:192
6859 msgid ""
6860 "The user does not have permission to access the shared memory segment, and "
6861 "does not have the B<CAP_IPC_OWNER> capability."
6862 msgstr ""
6863 "ユーザーはその共有メモリ・セグメントへのアクセス許可を持たず、 "
6864 "B<CAP_IPC_OWNER> ケーパビリティも持っていない。"
6865
6866 #. type: Plain text
6867 #: build/C/man2/shmget.2:196
6868 msgid "B<IPC_CREAT | IPC_EXCL> was specified and the segment exists."
6869 msgstr ""
6870 "B<IPC_CREAT | IPC_EXCL> が指定されていたが、そのセグメントが既に存在する。"
6871
6872 #. type: Plain text
6873 #: build/C/man2/shmget.2:202
6874 msgid ""
6875 "A new segment was to be created and I<size> E<lt> B<SHMMIN> or I<size> E<gt> "
6876 "B<SHMMAX>, or no new segment was to be created, a segment with given key "
6877 "existed, but I<size> is greater than the size of that segment."
6878 msgstr ""
6879 "新しいセグメントを作成しようとした際に I<size> E<lt> B<SHMMIN> または "
6880 "I<size> E<gt> B<SHMMAX> であった。 もしくは、指定されたキーに対応するセグメン"
6881 "トが既に存在して、新しい セグメントを作成しようとはしなかったが、I<size> が存"
6882 "在するセグメントの サイズよりも大きかった。"
6883
6884 #. type: Plain text
6885 #: build/C/man2/shmget.2:211
6886 msgid ""
6887 "No segment exists for the given I<key>, and B<IPC_CREAT> was not specified."
6888 msgstr ""
6889 "指定された I<key> に対応するセグメントが存在せず、 B<IPC_CREAT> も指定されて"
6890 "いなかった。"
6891
6892 #. type: Plain text
6893 #: build/C/man2/shmget.2:214
6894 msgid "No memory could be allocated for segment overhead."
6895 msgstr "セグメントの管理情報 (overhead) に割り当てるメモリがなかった。"
6896
6897 #. type: Plain text
6898 #: build/C/man2/shmget.2:222
6899 msgid ""
6900 "All possible shared memory IDs have been taken (B<SHMMNI>), or allocating a "
6901 "segment of the requested I<size> would cause the system to exceed the system-"
6902 "wide limit on shared memory (B<SHMALL>)."
6903 msgstr ""
6904 "システム全体の共有メモリ・セグメント数の制限 (B<SHMMNI>)  に達した、または要"
6905 "求された I<size> のセグメントの割り当てが システム全体の共有メモリサイズの制"
6906 "限 (B<SHMALL>)  を超過した。"
6907
6908 #. type: Plain text
6909 #: build/C/man2/shmget.2:229
6910 msgid ""
6911 "The B<SHM_HUGETLB> flag was specified, but the caller was not privileged "
6912 "(did not have the B<CAP_IPC_LOCK> capability)."
6913 msgstr ""
6914 "B<SHM_HUGETLB> フラグが指定されたが、呼び出し元には権限がなかった "
6915 "(B<CAP_IPC_LOCK> ケーパビリティを持っていなかった)。"
6916
6917 #. type: Plain text
6918 #: build/C/man2/shmget.2:235
6919 msgid "B<SHM_HUGETLB> is a nonportable Linux extension."
6920 msgstr "B<SHM_HUGETLB> は Linux での拡張であり、移植性はない。"
6921
6922 #. type: Plain text
6923 #: build/C/man2/shmget.2:245
6924 msgid ""
6925 "B<IPC_PRIVATE> isn't a flag field but a I<key_t> type.  If this special "
6926 "value is used for I<key>, the system call ignores everything but the least "
6927 "significant 9 bits of I<shmflg> and creates a new shared memory segment (on "
6928 "success)."
6929 msgstr ""
6930 "B<IPC_PRIVATE> はフラグではなく I<key_t> 型である。 この特別な値が I<key> に"
6931 "使用された場合は、 B<shmget>()  は I<shmflg> の下位 9 ビットを除いた全てを無"
6932 "視し、 (成功すれば) 新しい共有メモリ・セグメントを作成する。"
6933
6934 #. type: Plain text
6935 #: build/C/man2/shmget.2:249
6936 msgid ""
6937 "The following limits on shared memory segment resources affect the B<shmget>"
6938 "()  call:"
6939 msgstr ""
6940 "B<shmget>()  コールに影響する共有メモリ・セグメント資源の制限は以下の通りであ"
6941 "る:"
6942
6943 #. type: TP
6944 #: build/C/man2/shmget.2:249
6945 #, no-wrap
6946 msgid "B<SHMALL>"
6947 msgstr "B<SHMALL>"
6948
6949 #. type: Plain text
6950 #: build/C/man2/shmget.2:254
6951 msgid ""
6952 "System wide maximum of shared memory pages (on Linux, this limit can be read "
6953 "and modified via I</proc/sys/kernel/shmall>)."
6954 msgstr ""
6955 "システム全体の共有メモリ・ページの最大数 (Linux では、この上限値は I</proc/"
6956 "sys/kernel/shmall> 経由で参照したり、変更したりできる)。"
6957
6958 #. type: TP
6959 #: build/C/man2/shmget.2:254
6960 #, no-wrap
6961 msgid "B<SHMMAX>"
6962 msgstr "B<SHMMAX>"
6963
6964 #. type: Plain text
6965 #: build/C/man2/shmget.2:259
6966 msgid ""
6967 "Maximum size in bytes for a shared memory segment: policy dependent (on "
6968 "Linux, this limit can be read and modified via I</proc/sys/kernel/shmmax>)."
6969 msgstr ""
6970 "共有メモリ・セグメントのバイト単位の大きさの上限: 方針依存 (Linux では、この"
6971 "上限値は I</proc/sys/kernel/shmmax> 経由で参照したり、変更したりできる)。"
6972
6973 #. type: TP
6974 #: build/C/man2/shmget.2:259
6975 #, no-wrap
6976 msgid "B<SHMMIN>"
6977 msgstr "B<SHMMIN>"
6978
6979 #. type: Plain text
6980 #: build/C/man2/shmget.2:265
6981 msgid ""
6982 "Minimum size in bytes for a shared memory segment: implementation dependent "
6983 "(currently 1 byte, though B<PAGE_SIZE> is the effective minimum size)."
6984 msgstr ""
6985 "共有メモリ・セグメントのバイト単位の大きさの下限: 実装依存 (現在は 1 バイトだ"
6986 "が、実質的な最小サイズは B<PAGE_SIZE> である)。"
6987
6988 #. type: TP
6989 #: build/C/man2/shmget.2:265
6990 #, no-wrap
6991 msgid "B<SHMMNI>"
6992 msgstr "B<SHMMNI>"
6993
6994 #.  Kernels between 2.4.x and 2.6.8 had an off-by-one error that meant
6995 #.  that we could create one more segment than SHMMNI -- MTK
6996 #.  This /proc file is not available in Linux 2.2 and earlier -- MTK
6997 #. type: Plain text
6998 #: build/C/man2/shmget.2:274
6999 msgid ""
7000 "System wide maximum number of shared memory segments: implementation "
7001 "dependent (currently 4096, was 128 before Linux 2.3.99; on Linux, this limit "
7002 "can be read and modified via I</proc/sys/kernel/shmmni>)."
7003 msgstr ""
7004 "システム全体の共有メモリーの数の上限: 実装依存 (現在は 4096。Linux 2.3.99 よ"
7005 "り前では 128。 Linux では、この上限値は I</proc/sys/kernel/shmmni> 経由で参照"
7006 "したり、変更したりできる)。"
7007
7008 #. type: Plain text
7009 #: build/C/man2/shmget.2:278
7010 msgid ""
7011 "The implementation has no specific limits for the per-process maximum number "
7012 "of shared memory segments (B<SHMSEG>)."
7013 msgstr ""
7014 "プロセス当りの共有メモリ・セグメントの個数の最大値 (B<SHMSEG>)  に関する実装"
7015 "上の制限はない。"
7016
7017 #. type: Plain text
7018 #: build/C/man2/shmget.2:284
7019 msgid ""
7020 "Until version 2.3.30 Linux would return B<EIDRM> for a B<shmget>()  on a "
7021 "shared memory segment scheduled for deletion."
7022 msgstr ""
7023 "バージョン 2.3.30 までは、Linux は 削除が予定されている共有メモリ・セグメント"
7024 "に対して B<shmget>()  が行われると B<EIDRM> を返していた。"
7025
7026 #. type: Plain text
7027 #: build/C/man2/shmget.2:290
7028 msgid ""
7029 "The name choice B<IPC_PRIVATE> was perhaps unfortunate, B<IPC_NEW> would "
7030 "more clearly show its function."
7031 msgstr ""
7032 "B<IPC_PRIVATE> という名前を選んだのはおそらく失敗であろう。 B<IPC_NEW> の方が"
7033 "より明確にその機能を表しているだろう。"
7034
7035 #. type: Plain text
7036 #: build/C/man2/shmget.2:298
7037 msgid ""
7038 "B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), "
7039 "B<shm_overview>(7), B<svipc>(7)"
7040 msgstr ""
7041 "B<shmat>(2), B<shmctl>(2), B<shmdt>(2), B<ftok>(3), B<capabilities>(7), "
7042 "B<shm_overview>(7), B<svipc>(7)"
7043
7044 #. type: TH
7045 #: build/C/man2/shmop.2:39
7046 #, no-wrap
7047 msgid "SHMOP"
7048 msgstr "SHMOP"
7049
7050 #. type: TH
7051 #: build/C/man2/shmop.2:39
7052 #, no-wrap
7053 msgid "2008-06-03"
7054 msgstr "2008-06-03"
7055
7056 #. type: Plain text
7057 #: build/C/man2/shmop.2:42
7058 msgid "shmat, shmdt - shared memory operations"
7059 msgstr "shmat, shmdt - 共有メモリ (shared memory) の操作"
7060
7061 #. type: Plain text
7062 #: build/C/man2/shmop.2:46
7063 #, no-wrap
7064 msgid ""
7065 "B<#include E<lt>sys/types.hE<gt>>\n"
7066 "B<#include E<lt>sys/shm.hE<gt>>\n"
7067 msgstr ""
7068 "B<#include E<lt>sys/types.hE<gt>>\n"
7069 "B<#include E<lt>sys/shm.hE<gt>>\n"
7070
7071 #. type: Plain text
7072 #: build/C/man2/shmop.2:48
7073 #, no-wrap
7074 msgid "B<void *shmat(int >I<shmid>B<, const void *>I<shmaddr>B<, int >I<shmflg>B<);>\n"
7075 msgstr "B<void *shmat(int >I<shmid>B<, const void *>I<shmaddr>B<, int >I<shmflg>B<);>\n"
7076
7077 #. type: Plain text
7078 #: build/C/man2/shmop.2:50
7079 #, no-wrap
7080 msgid "B<int shmdt(const void *>I<shmaddr>B<);>\n"
7081 msgstr "B<int shmdt(const void *>I<shmaddr>B<);>\n"
7082
7083 #. type: Plain text
7084 #: build/C/man2/shmop.2:59
7085 msgid ""
7086 "B<shmat>()  attaches the shared memory segment identified by I<shmid> to the "
7087 "address space of the calling process.  The attaching address is specified by "
7088 "I<shmaddr> with one of the following criteria:"
7089 msgstr ""
7090 "B<shmat>()  は I<shmid> で指定された共有メモリ・セグメント (shared memory "
7091 "segment) を コールしたプロセスのアドレス空間に付加 (attach) する。 付加するア"
7092 "ドレスは I<shmaddr> に以下のどれかの形式で指定する:"
7093
7094 #. type: Plain text
7095 #: build/C/man2/shmop.2:65
7096 msgid ""
7097 "If I<shmaddr> is NULL, the system chooses a suitable (unused) address at "
7098 "which to attach the segment."
7099 msgstr ""
7100 "I<shmaddr> が NULL ならば、システムはセグメントを付加するための 適切な (使用"
7101 "されていない) アドレスを選択する。"
7102
7103 #. type: Plain text
7104 #: build/C/man2/shmop.2:80
7105 msgid ""
7106 "If I<shmaddr> isn't NULL and B<SHM_RND> is specified in I<shmflg>, the "
7107 "attach occurs at the address equal to I<shmaddr> rounded down to the nearest "
7108 "multiple of B<SHMLBA>.  Otherwise I<shmaddr> must be a page-aligned address "
7109 "at which the attach occurs."
7110 msgstr ""
7111 "I<shmaddr> が NULL でなく B<SHM_RND> が I<shmflg> に指定されている場合は、 "
7112 "I<shmaddr> を B<SHMLBA> の倍数へと切り捨てた (rounding down) のと等しいアドレ"
7113 "スへ付加する。 その他の場合は I<shmaddr> は付加を行なうアドレスで、ページ境界"
7114 "を指している必要がある。"
7115
7116 #. type: Plain text
7117 #: build/C/man2/shmop.2:90
7118 msgid ""
7119 "If B<SHM_RDONLY> is specified in I<shmflg>, the segment is attached for "
7120 "reading and the process must have read permission for the segment.  "
7121 "Otherwise the segment is attached for read and write and the process must "
7122 "have read and write permission for the segment.  There is no notion of a "
7123 "write-only shared memory segment."
7124 msgstr ""
7125 "B<SHM_RDONLY> が I<shmflg> に指定されていた場合は、 セグメントは読み込み専用"
7126 "に付加され、プロセスはそのセグメントへの 読み込み許可を持たなければならな"
7127 "い。 そうでなければそのセグメントは読み込みと書き込みのために付加され、 プロ"
7128 "セスはそのセグメントに読み込みと書き込みの許可を持つ必要がある。 書き込み専用"
7129 "の共有メモリ・セグメントという概念は存在しない。"
7130
7131 #. type: Plain text
7132 #: build/C/man2/shmop.2:105
7133 msgid ""
7134 "The (Linux-specific)  B<SHM_REMAP> flag may be specified in I<shmflg> to "
7135 "indicate that the mapping of the segment should replace any existing mapping "
7136 "in the range starting at I<shmaddr> and continuing for the size of the "
7137 "segment.  (Normally an B<EINVAL> error would result if a mapping already "
7138 "exists in this address range.)  In this case, I<shmaddr> must not be NULL."
7139 msgstr ""
7140 "(Linux 特有の)  B<SHM_REMAP> フラグが I<shmflg> に指定された場合は、 セグメン"
7141 "トのマッピングを既存のマッピングに置き換える。 マッピングの範囲は、 "
7142 "I<shmaddr> から始まりセグメントのサイズ分だけある (通常 B<EINVAL> エラーは、"
7143 "このアドレス範囲にマッピングが既に存在するために起る)。 このフラグを指定する"
7144 "場合は、 I<shmaddr> が NULL であってはならない。"
7145
7146 #. type: Plain text
7147 #: build/C/man2/shmop.2:112
7148 msgid ""
7149 "The B<brk>(2)  value of the calling process is not altered by the attach.  "
7150 "The segment will automatically be detached at process exit.  The same "
7151 "segment may be attached as a read and as a read-write one, and more than "
7152 "once, in the process's address space."
7153 msgstr ""
7154 "呼び出したプロセスの B<brk>(2)  の値は付加によって変化しない。 そのセグメント"
7155 "はプロセスが終了 (exit) したら自動的に分離 (detach) される。 同じセグメントを"
7156 "プロセスのアドレス空間に、読み込み専用および読み書き両用 として付加でき、また"
7157 "複数回付加することもできる。"
7158
7159 #. type: Plain text
7160 #: build/C/man2/shmop.2:120
7161 msgid ""
7162 "A successful B<shmat>()  call updates the members of the I<shmid_ds> "
7163 "structure (see B<shmctl>(2))  associated with the shared memory segment as "
7164 "follows:"
7165 msgstr ""
7166 "成功した B<shmat>()  コールは共有メモリ・セグメントに関連する I<shmid_ds> 構"
7167 "造体 (B<shmctl>(2)  を参照) のメンバーを以下のように更新する:"
7168
7169 #. type: Plain text
7170 #: build/C/man2/shmop.2:123
7171 msgid "I<shm_atime> is set to the current time."
7172 msgstr "I<shm_atime> には現在の時刻を設定する。"
7173
7174 #. type: Plain text
7175 #: build/C/man2/shmop.2:126 build/C/man2/shmop.2:152
7176 msgid "I<shm_lpid> is set to the process-ID of the calling process."
7177 msgstr "I<shm_lpid> には呼び出したプロセスのプロセス ID が設定される。"
7178
7179 #. type: Plain text
7180 #: build/C/man2/shmop.2:129
7181 msgid "I<shm_nattch> is incremented by one."
7182 msgstr "I<shm_nattch> を 1 増加させる。"
7183
7184 #. type: Plain text
7185 #: build/C/man2/shmop.2:140
7186 msgid ""
7187 "B<shmdt>()  detaches the shared memory segment located at the address "
7188 "specified by I<shmaddr> from the address space of the calling process.  The "
7189 "to-be-detached segment must be currently attached with I<shmaddr> equal to "
7190 "the value returned by the attaching B<shmat>()  call."
7191 msgstr ""
7192 "B<shmdt>()  は呼び出したプロセスのアドレス空間から I<shmaddr> で指定されたア"
7193 "ドレスに配置された共有メモリ・セグメントを分離 (detach) する。 分離する共有メ"
7194 "モリ・セグメントは、現在 I<shmaddr> に付加されているものでなければならない。 "
7195 "I<shmaddr> は、それを付加した時に B<shmat>()  が返した値に等しくなければなら"
7196 "ない。"
7197
7198 #. type: Plain text
7199 #: build/C/man2/shmop.2:146
7200 msgid ""
7201 "On a successful B<shmdt>()  call the system updates the members of the "
7202 "I<shmid_ds> structure associated with the shared memory segment as follows:"
7203 msgstr ""
7204 "成功した B<shmdt>()  コールはその共有メモリ・セグメントに関連する "
7205 "I<shmid_ds> 構造体のメンバーを以下のように更新する:"
7206
7207 #. type: Plain text
7208 #: build/C/man2/shmop.2:149
7209 msgid "I<shm_dtime> is set to the current time."
7210 msgstr "I<shm_dtime> には現在の時刻が設定される。"
7211
7212 #. type: Plain text
7213 #: build/C/man2/shmop.2:157
7214 msgid ""
7215 "I<shm_nattch> is decremented by one.  If it becomes 0 and the segment is "
7216 "marked for deletion, the segment is deleted."
7217 msgstr ""
7218 "I<shm_nattch> を 1 減少させる。 もし 0 になり、削除マークがあった場合は その"
7219 "セグメントは削除される。"
7220
7221 #. type: Plain text
7222 #: build/C/man2/shmop.2:161
7223 msgid ""
7224 "After a B<fork>(2)  the child inherits the attached shared memory segments."
7225 msgstr ""
7226 "B<fork>(2)  した後、子プロセスは付加された共有メモリ・セグメントを継承する。"
7227
7228 #. type: Plain text
7229 #: build/C/man2/shmop.2:165
7230 msgid ""
7231 "After an B<execve>(2)  all attached shared memory segments are detached from "
7232 "the process."
7233 msgstr ""
7234 "B<exec>(2)  した後、全ての付加された共有メモリ・セグメントはプロセスから分離"
7235 "される。"
7236
7237 #. type: Plain text
7238 #: build/C/man2/shmop.2:169
7239 msgid ""
7240 "Upon B<_exit>(2)  all attached shared memory segments are detached from the "
7241 "process."
7242 msgstr ""
7243 "B<exit>(2)  において、全ての付加された共有メモリ・セグメントはプロセスから分"
7244 "離される。"
7245
7246 #. type: Plain text
7247 #: build/C/man2/shmop.2:177
7248 msgid ""
7249 "On success B<shmat>()  returns the address of the attached shared memory "
7250 "segment; on error I<(void\\ *)\\ -1> is returned, and I<errno> is set to "
7251 "indicate the cause of the error."
7252 msgstr ""
7253 "B<shmat>()  は、成功した場合、 付加された共有メモリ・セグメントのアドレスを返"
7254 "す。 エラーの場合、 I<(void\\ *)\\ -1> を返し、 I<errno> にエラーの原因を示す"
7255 "値を設定する。"
7256
7257 #. type: Plain text
7258 #: build/C/man2/shmop.2:183
7259 msgid ""
7260 "On success B<shmdt>()  returns 0; on error -1 is returned, and I<errno> is "
7261 "set to indicate the cause of the error."
7262 msgstr ""
7263 "B<shmdt>()  は、成功すると 0 を返す。 エラーの場合、-1 を返し、 I<errno> にエ"
7264 "ラーの原因を示す値を設定する。"
7265
7266 #. type: Plain text
7267 #: build/C/man2/shmop.2:189
7268 msgid "When B<shmat>()  fails, I<errno> is set to one of the following:"
7269 msgstr ""
7270 "B<shmat>()  が失敗した場合、 I<errno> に以下の値のどれかを設定して返す:"
7271
7272 #. type: Plain text
7273 #: build/C/man2/shmop.2:195
7274 msgid ""
7275 "The calling process does not have the required permissions for the requested "
7276 "attach type, and does not have the B<CAP_IPC_OWNER> capability."
7277 msgstr ""
7278 "呼び出したプロセスに要求された種類の付加に必要な許可がなく、 "
7279 "B<CAP_IPC_OWNER> ケーパビリティ (capability) がない。"
7280
7281 #. type: Plain text
7282 #: build/C/man2/shmop.2:209
7283 msgid ""
7284 "Invalid I<shmid> value, unaligned (i.e., not page-aligned and B<SHM_RND> was "
7285 "not specified) or invalid I<shmaddr> value, or can't attach segment at "
7286 "I<shmaddr>, or B<SHM_REMAP> was specified and I<shmaddr> was NULL."
7287 msgstr ""
7288 "I<shmid> の値が不正である。 I<shmaddr> の値が境界違反 (unaligned) (つまり、"
7289 "ページ境界に合っておらず、 B<SHM_RND> が指定されていない) または が不正であ"
7290 "る。 I<shmaddr> へのセグメントの付加に失敗した。 または B<SHM_REMAP> が指定さ"
7291 "れているが、 I<shmaddr> が NULL であった。"
7292
7293 #. type: Plain text
7294 #: build/C/man2/shmop.2:212
7295 msgid "Could not allocate memory for the descriptor or for the page tables."
7296 msgstr ""
7297 "ディスクリプター (descriptor) やページ・テーブルのためのメモリを 割り当てるこ"
7298 "とができない。"
7299
7300 #. type: Plain text
7301 #: build/C/man2/shmop.2:218
7302 msgid "When B<shmdt>()  fails, I<errno> is set as follows:"
7303 msgstr "B<shmdt>()  が失敗した場合、 B<EINVAL> は以下のようにセットされる:"
7304
7305 #.  The following since 2.6.17-rc1:
7306 #. type: Plain text
7307 #: build/C/man2/shmop.2:226
7308 msgid ""
7309 "There is no shared memory segment attached at I<shmaddr>; or, I<shmaddr> is "
7310 "not aligned on a page boundary."
7311 msgstr ""
7312 "I<shmaddr> に付加された共有メモリ・セグメントが存在しない。 もしくは、 "
7313 "I<shmaddr> がページ境界に合っていない。"
7314
7315 #. type: Plain text
7316 #: build/C/man2/shmop.2:245
7317 msgid ""
7318 "In SVID 3 (or perhaps earlier)  the type of the I<shmaddr> argument was "
7319 "changed from I<char *> into I<const void *>, and the returned type of "
7320 "B<shmat>()  from I<char *> into I<void *>.  (Linux libc4 and libc5 have the "
7321 "I<char *> prototypes; glibc2 has I<void *>.)"
7322 msgstr ""
7323 "SVID 3 で (たぶんそれより前だと思うが)  I<shmaddr> 引き数の型は I<char *> か"
7324 "ら I<const void *> に、I<shmat>() の返り値の型は I<char *> から I<void *> に"
7325 "変更された (Linux では libc4 と libc5 のプロトタイプは I<char *> であり、"
7326 "glibc2 のプロトタイプは I<void *> である)。"
7327
7328 #. type: Plain text
7329 #: build/C/man2/shmop.2:257
7330 msgid ""
7331 "Using B<shmat>()  with I<shmaddr> equal to NULL is the preferred, portable "
7332 "way of attaching a shared memory segment.  Be aware that the shared memory "
7333 "segment attached in this way may be attached at different addresses in "
7334 "different processes.  Therefore, any pointers maintained within the shared "
7335 "memory must be made relative (typically to the starting address of the "
7336 "segment), rather than absolute."
7337 msgstr ""
7338 "共有メモリセグメントを付加する場合の移植性の高い方法としては、 I<shmaddr> を "
7339 "NULL にして B<shmat>()  を使用するのがよい。 このような方法で付加される共有メ"
7340 "モリセグメントは、 プロセスが異なれば別のアドレスに付加される、という点に注意"
7341 "すること。 よって共有メモリ内で管理されるポインタは、 絶対アドレスではなく、 "
7342 "(一般的にはセグメントの開始アドレスからの)  相対アドレスで作成するべきであ"
7343 "る。"
7344
7345 #. type: Plain text
7346 #: build/C/man2/shmop.2:262
7347 msgid ""
7348 "On Linux, it is possible to attach a shared memory segment even if it is "
7349 "already marked to be deleted.  However, POSIX.1-2001 does not specify this "
7350 "behavior and many other implementations do not support it."
7351 msgstr ""
7352 "Linux では共有メモリセグメントに既に削除マークが付けられていても、 その共有メ"
7353 "モリセグメントを付加することができる。 しかし POSIX.1-2001 ではこのような動作"
7354 "を指定しておらず、 他の多くの実装もこれをサポートしていない。"
7355
7356 #. type: Plain text
7357 #: build/C/man2/shmop.2:265
7358 msgid "The following system parameter affects B<shmat>():"
7359 msgstr "以下のシステム・パラメーターは、 B<shmat>()  に影響する:"
7360
7361 #.  FIXME A good explanation of the rationale for the existence
7362 #.  of SHMLBA would be useful here
7363 #. type: TP
7364 #: build/C/man2/shmop.2:265
7365 #, no-wrap
7366 msgid "B<SHMLBA>"
7367 msgstr "B<SHMLBA>"
7368
7369 #.  FIXME That last sentence isn't true for all Linux
7370 #.  architectures (i.e., SHMLBA != PAGE_SIZE for some architectures)
7371 #.  -- MTK, Nov 04
7372 #. type: Plain text
7373 #: build/C/man2/shmop.2:278
7374 msgid ""
7375 "Segment low boundary address multiple.  Must be page aligned.  For the "
7376 "current implementation the B<SHMLBA> value is B<PAGE_SIZE>."
7377 msgstr ""
7378 "セグメントの境界アドレスの最小倍数。ページ境界に合ってなければならない。 現在"
7379 "の実装では B<SHMLBA> の値は B<PAGE_SIZE> である。"
7380
7381 #. type: Plain text
7382 #: build/C/man2/shmop.2:282
7383 msgid ""
7384 "The implementation places no intrinsic limit on the per-process maximum "
7385 "number of shared memory segments (B<SHMSEG>)."
7386 msgstr ""
7387 "現在の実装では、プロセスごとの 共有メモリ・セグメントの最大数 (B<SHMSEG>)  に"
7388 "関する実装依存の制限はない。"
7389
7390 #. type: Plain text
7391 #: build/C/man2/shmop.2:290
7392 msgid ""
7393 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
7394 "B<shm_overview>(7), B<svipc>(7)"
7395 msgstr ""
7396 "B<brk>(2), B<mmap>(2), B<shmctl>(2), B<shmget>(2), B<capabilities>(7), "
7397 "B<shm_overview>(7), B<svipc>(7)"
7398
7399 #. type: TH
7400 #: build/C/man2/subpage_prot.2:28
7401 #, no-wrap
7402 msgid "SUBPAGE_PROT"
7403 msgstr "SUBPAGE_PROT"
7404
7405 #. type: TH
7406 #: build/C/man2/subpage_prot.2:28
7407 #, no-wrap
7408 msgid "2010-10-30"
7409 msgstr "2010-10-30"
7410
7411 #. type: Plain text
7412 #: build/C/man2/subpage_prot.2:31
7413 msgid "subpage_prot - define a subpage protection for an address range"
7414 msgstr "subpage_prot - define a subpage protection for an address range"
7415
7416 #. type: Plain text
7417 #: build/C/man2/subpage_prot.2:35
7418 #, no-wrap
7419 msgid ""
7420 "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
7421 "B<                  uint32_t *>I<map>B<);>\n"
7422 msgstr ""
7423 "B<long subpage_prot(unsigned long >I<addr>B<, unsigned long >I<len>B<,>\n"
7424 "B<                  uint32_t *>I<map>B<);>\n"
7425
7426 #. type: Plain text
7427 #: build/C/man2/subpage_prot.2:42
7428 msgid ""
7429 "The PowerPC-specific B<subpage_prot>()  system call provides the facility to "
7430 "control the access permissions on individual 4kB subpages on systems "
7431 "configured with a page size of 64kB."
7432 msgstr ""
7433 "The PowerPC-specific B<subpage_prot>()  system call provides the facility to "
7434 "control the access permissions on individual 4kB subpages on systems "
7435 "configured with a page size of 64kB."
7436
7437 #. type: Plain text
7438 #: build/C/man2/subpage_prot.2:49
7439 msgid ""
7440 "The protection map is applied to the memory pages in the region starting at "
7441 "I<addr> and continuing for I<len> bytes.  Both of these arguments must be "
7442 "aligned to a 64-kB boundary."
7443 msgstr ""
7444 "The protection map is applied to the memory pages in the region starting at "
7445 "I<addr> and continuing for I<len> bytes.  Both of these arguments must be "
7446 "aligned to a 64-kB boundary."
7447
7448 #. type: Plain text
7449 #: build/C/man2/subpage_prot.2:61
7450 msgid ""
7451 "The protection map is specified in the buffer pointed to by I<map>.  The map "
7452 "has 2 bits per 4kB subpage; thus each 32-bit word specifies the protections "
7453 "of 16 4kB subpages inside a 64kB page (so, the number of 32-bit words "
7454 "pointed to by I<map> should equate to the number of 64-kB pages specified by "
7455 "I<len>).  Each 2-bit field in the protection map is either 0 to allow any "
7456 "access, 1 to prevent writes, or 2 or 3 to prevent all accesses."
7457 msgstr ""
7458 "The protection map is specified in the buffer pointed to by I<map>.  The map "
7459 "has 2 bits per 4kB subpage; thus each 32-bit word specifies the protections "
7460 "of 16 4kB subpages inside a 64kB page (so, the number of 32-bit words "
7461 "pointed to by I<map> should equate to the number of 64-kB pages specified by "
7462 "I<len>).  Each 2-bit field in the protection map is either 0 to allow any "
7463 "access, 1 to prevent writes, or 2 or 3 to prevent all accesses."
7464
7465 #. type: Plain text
7466 #: build/C/man2/subpage_prot.2:66
7467 msgid ""
7468 "On success, B<subpage_prot>()  returns 0.  Otherwise, one of the error codes "
7469 "specified below is returned."
7470 msgstr ""
7471 "On success, B<subpage_prot>()  returns 0.  Otherwise, one of the error codes "
7472 "specified below is returned."
7473
7474 #. type: Plain text
7475 #: build/C/man2/subpage_prot.2:72
7476 msgid "The buffer referred to by I<map> is not accessible."
7477 msgstr "The buffer referred to by I<map> is not accessible."
7478
7479 #. type: Plain text
7480 #: build/C/man2/subpage_prot.2:82
7481 msgid ""
7482 "The I<addr> or I<len> arguments are incorrect.  Both of these arguments must "
7483 "be aligned to a multiple of the system page size, and they must not refer to "
7484 "a region outside of the address space of the process or to a region that "
7485 "consists of huge pages."
7486 msgstr ""
7487 "The I<addr> or I<len> arguments are incorrect.  Both of these arguments must "
7488 "be aligned to a multiple of the system page size, and they must not refer to "
7489 "a region outside of the address space of the process or to a region that "
7490 "consists of huge pages."
7491
7492 #. type: Plain text
7493 #: build/C/man2/subpage_prot.2:85 build/C/man2/sync_file_range.2:166
7494 msgid "Out of memory."
7495 msgstr "メモリ不足である。"
7496
7497 #. type: Plain text
7498 #: build/C/man2/subpage_prot.2:91
7499 msgid ""
7500 "This system call is provided on the PowerPC architecture since Linux "
7501 "2.6.25.  The system call is provided only if the kernel is configured with "
7502 "B<CONFIG_PPC_64K_PAGES>.  No library support is provided."
7503 msgstr ""
7504 "This system call is provided on the PowerPC architecture since Linux "
7505 "2.6.25.  The system call is provided only if the kernel is configured with "
7506 "B<CONFIG_PPC_64K_PAGES>.  No library support is provided."
7507
7508 #. type: Plain text
7509 #: build/C/man2/subpage_prot.2:98
7510 msgid ""
7511 "Normal page protections (at the 64-kB page level) also apply; the subpage "
7512 "protection mechanism is an additional constraint, so putting 0 in a 2-bit "
7513 "field won't allow writes to a page that is otherwise write-protected."
7514 msgstr ""
7515 "Normal page protections (at the 64-kB page level) also apply; the subpage "
7516 "protection mechanism is an additional constraint, so putting 0 in a 2-bit "
7517 "field won't allow writes to a page that is otherwise write-protected."
7518
7519 #. type: SS
7520 #: build/C/man2/subpage_prot.2:98
7521 #, no-wrap
7522 msgid "Rationale"
7523 msgstr "Rationale"
7524
7525 #.  In the initial implementation, it was the case that:
7526 #.      In fact the whole process is switched to use 4k hardware pages when the
7527 #.      subpage_prot system call is used, but this could be improved in future
7528 #.      to switch only the affected segments.
7529 #.  But Paul Mackerass says (Oct 2010): I'm pretty sure we now only switch
7530 #.  the affected segment, not the whole process.
7531 #. type: Plain text
7532 #: build/C/man2/subpage_prot.2:120
7533 msgid ""
7534 "This system call is provided to assist writing emulators that operate using "
7535 "64-kB pages on PowerPC systems.  When emulating systems such as x86, which "
7536 "uses a smaller page size, the emulator can no longer use the memory-"
7537 "management unit (MMU)  and normal system calls for controlling page "
7538 "protections.  (The emulator could emulate the MMU by checking and possibly "
7539 "remapping the address for each memory access in software, but that is "
7540 "slow.)  The idea is that the emulator supplies an array of protection masks "
7541 "to apply to a specified range of virtual addresses.  These masks are applied "
7542 "at the level where hardware page-table entries (PTEs)  are inserted into the "
7543 "hardware page table based on the Linux PTEs, so the Linux PTEs are not "
7544 "affected.  Implicit in this is that the regions of the address space that "
7545 "are protected are switched to use 4-kB hardware pages rather than 64-kB "
7546 "hardware pages (on machines with hardware 64-kB page support)."
7547 msgstr ""
7548 "This system call is provided to assist writing emulators that operate using "
7549 "64-kB pages on PowerPC systems.  When emulating systems such as x86, which "
7550 "uses a smaller page size, the emulator can no longer use the memory-"
7551 "management unit (MMU)  and normal system calls for controlling page "
7552 "protections.  (The emulator could emulate the MMU by checking and possibly "
7553 "remapping the address for each memory access in software, but that is "
7554 "slow.)  The idea is that the emulator supplies an array of protection masks "
7555 "to apply to a specified range of virtual addresses.  These masks are applied "
7556 "at the level where hardware page-table entries (PTEs)  are inserted into the "
7557 "hardware page table based on the Linux PTEs, so the Linux PTEs are not "
7558 "affected.  Implicit in this is that the regions of the address space that "
7559 "are protected are switched to use 4-kB hardware pages rather than 64-kB "
7560 "hardware pages (on machines with hardware 64-kB page support)."
7561
7562 #. type: Plain text
7563 #: build/C/man2/subpage_prot.2:123
7564 msgid "B<mprotect>(2), B<syscall>(2);"
7565 msgstr "B<mprotect>(2), B<syscall>(2);"
7566
7567 #. type: Plain text
7568 #: build/C/man2/subpage_prot.2:126
7569 msgid "the kernel source file I<Documentation/vm/hugetlbpage.txt>."
7570 msgstr "the kernel source file I<Documentation/vm/hugetlbpage.txt>."
7571
7572 #. type: TH
7573 #: build/C/man2/sync_file_range.2:30
7574 #, no-wrap
7575 msgid "SYNC_FILE_RANGE"
7576 msgstr "SYNC_FILE_RANGE"
7577
7578 #. type: Plain text
7579 #: build/C/man2/sync_file_range.2:33
7580 msgid "sync_file_range - sync a file segment with disk"
7581 msgstr "sync_file_range - ファイルセグメントをディスクと同期する"
7582
7583 #. type: Plain text
7584 #: build/C/man2/sync_file_range.2:37
7585 #, fuzzy, no-wrap
7586 #| msgid ""
7587 #| "B<#define _GNU_SOURCE>             /* See feature_test_macros(7) */\n"
7588 #| "B<#include E<lt>fcntl.hE<gt>>\n"
7589 msgid ""
7590 "B<#define _GNU_SOURCE>         /* See feature_test_macros(7) */\n"
7591 "B<#include E<lt>fcntl.hE<gt>>\n"
7592 msgstr ""
7593 "B<#define _GNU_SOURCE>             /* feature_test_macros(7) 参照 */\n"
7594 "B<#include E<lt>fcntl.hE<gt>>\n"
7595
7596 #. type: Plain text
7597 #: build/C/man2/sync_file_range.2:40
7598 #, no-wrap
7599 msgid ""
7600 "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
7601 "B<                    unsigned int >I<flags>B<);>\n"
7602 msgstr ""
7603 "B<int sync_file_range(int >I<fd>B<, off64_t >I<offset>B<, off64_t >I<nbytes>B<,>\n"
7604 "B<                    unsigned int >I<flags>B<);>\n"
7605
7606 #. type: Plain text
7607 #: build/C/man2/sync_file_range.2:47
7608 msgid ""
7609 "B<sync_file_range>()  permits fine control when synchronizing the open file "
7610 "referred to by the file descriptor I<fd> with disk."
7611 msgstr ""
7612 "B<sync_file_range>()  を使うと、ファイルディスクリプタ I<fd> で参照されるオー"
7613 "プンされたファイルのディスクとの同期に関して、 きめ細かな制御が可能となる。"
7614
7615 #. type: Plain text
7616 #: build/C/man2/sync_file_range.2:61
7617 msgid ""
7618 "I<offset> is the starting byte of the file range to be synchronized.  "
7619 "I<nbytes> specifies the length of the range to be synchronized, in bytes; if "
7620 "I<nbytes> is zero, then all bytes from I<offset> through to the end of file "
7621 "are synchronized.  Synchronization is in units of the system page size: "
7622 "I<offset> is rounded down to a page boundary; I<(offset+nbytes-1)> is "
7623 "rounded up to a page boundary."
7624 msgstr ""
7625 "I<offset> は、同期を行うファイルの領域の開始バイトである。 I<nbytes> には同期"
7626 "を行う領域の長さをバイト単位で指定する。 I<nbytes> が 0 の場合は、 I<offset> "
7627 "からファイル末尾までの全バイトを同期する。 同期はシステムのページサイズの単位"
7628 "で行われる。 I<offset> はページ境界にあわせて切り下げられ、 I<(offset"
7629 "+nbytes-1)> はページ境界にあわせて切り上げられる。"
7630
7631 #. type: Plain text
7632 #: build/C/man2/sync_file_range.2:65
7633 msgid "The I<flags> bit-mask argument can include any of the following values:"
7634 msgstr "ビットマスク引き数 I<flags> には以下の値を指定することができる:"
7635
7636 #. type: TP
7637 #: build/C/man2/sync_file_range.2:65
7638 #, no-wrap
7639 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE>"
7640 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE>"
7641
7642 #. type: Plain text
7643 #: build/C/man2/sync_file_range.2:70
7644 msgid ""
7645 "Wait upon write-out of all pages in the specified range that have already "
7646 "been submitted to the device driver for write-out before performing any "
7647 "write."
7648 msgstr ""
7649 "何らかの書き込みを行う前に、指定された領域のページで 書き出しを行うようにデバ"
7650 "イスドライバにすでに要求が発行されている ページの書き出しが全て完了するのを待"
7651 "つ。"
7652
7653 #. type: TP
7654 #: build/C/man2/sync_file_range.2:70 build/C/man2/sync_file_range.2:120
7655 #, no-wrap
7656 msgid "B<SYNC_FILE_RANGE_WRITE>"
7657 msgstr "B<SYNC_FILE_RANGE_WRITE>"
7658
7659 #. type: Plain text
7660 #: build/C/man2/sync_file_range.2:76
7661 msgid ""
7662 "Initiate write-out of all dirty pages in the specified range which are not "
7663 "presently submitted write-out.  Note that even this may block if you attempt "
7664 "to write more than request queue size."
7665 msgstr ""
7666 "指定された領域のページで、書き出し要求が発行されていない 全ての dirty (キャッ"
7667 "シュだけが変更されている) ページの 書き出しを開始する。 リクエストキューの大"
7668 "きさより多く書き込もうとした場合には、 この処理は停止 (block) する可能性があ"
7669 "る点に注意すること。"
7670
7671 #. type: TP
7672 #: build/C/man2/sync_file_range.2:76
7673 #, no-wrap
7674 msgid "B<SYNC_FILE_RANGE_WAIT_AFTER>"
7675 msgstr "B<SYNC_FILE_RANGE_WAIT_AFTER>"
7676
7677 #. type: Plain text
7678 #: build/C/man2/sync_file_range.2:80
7679 msgid ""
7680 "Wait upon write-out of all pages in the range after performing any write."
7681 msgstr ""
7682 "何らかの書き込み後に、指定された領域の全てのページの 書き出しが行われるのを待"
7683 "つ。"
7684
7685 #. type: Plain text
7686 #: build/C/man2/sync_file_range.2:84
7687 msgid "Specifying I<flags> as 0 is permitted, as a no-op."
7688 msgstr "I<flags> に 0 を指定した場合、何もしないことを表す。"
7689
7690 #. type: SS
7691 #: build/C/man2/sync_file_range.2:84
7692 #, no-wrap
7693 msgid "Warning"
7694 msgstr "警告"
7695
7696 #. type: Plain text
7697 #: build/C/man2/sync_file_range.2:100
7698 #, fuzzy
7699 #| msgid ""
7700 #| "This system call is extremely dangerous and should not be used in "
7701 #| "portable programs.  None of these operations writes out the file's "
7702 #| "metadata.  Therefore, unless the application is strictly performing "
7703 #| "overwrites of already-instantiated disk blocks, there are no guarantees "
7704 #| "that the data will be available after a crash.  There is no user "
7705 #| "interface to know if a write is purely an overwrite.  On filesystem using "
7706 #| "copy-on-write semantics (e.g., I<btrfs>)  an overwrite of existing "
7707 #| "allocated blocks is impossible.  When writing into preallocated space, "
7708 #| "many filesystems also require calls into the block allocator, which this "
7709 #| "system call does not sync out to disk.  This system call does not flush "
7710 #| "disk write caches and thus does not provide any data integrity on systems "
7711 #| "with volatile disk write caches."
7712 msgid ""
7713 "This system call is extremely dangerous and should not be used in portable "
7714 "programs.  None of these operations writes out the file's metadata.  "
7715 "Therefore, unless the application is strictly performing overwrites of "
7716 "already-instantiated disk blocks, there are no guarantees that the data will "
7717 "be available after a crash.  There is no user interface to know if a write "
7718 "is purely an overwrite.  On file systems using copy-on-write semantics (e."
7719 "g., I<btrfs>)  an overwrite of existing allocated blocks is impossible.  "
7720 "When writing into preallocated space, many file systems also require calls "
7721 "into the block allocator, which this system call does not sync out to disk.  "
7722 "This system call does not flush disk write caches and thus does not provide "
7723 "any data integrity on systems with volatile disk write caches."
7724 msgstr ""
7725 "このシステムコールは非常に危険であり、 移植性が必要なプログラムで使用すべきで"
7726 "はない。 これらの操作ではどれもファイルのメタデータの書き出しを行わない。 し"
7727 "たがって、アプリケーションにより作成済みのディスクブロックの 上書きの実行が確"
7728 "実に行われない限り、クラッシュの後でもデータが 利用できる保証はない。 書き込"
7729 "みが上書きだけであるかを知るためのユーザインタフェースは存在しない。 "
7730 "(I<btrfs> などの) copy-on-write 動作を使ったファイルシステムでは、 既存の割り"
7731 "当て済みのブロックに対する上書き自体ができない。 前もって割り当てられた領域に"
7732 "書き込みを行う場合、 多くのファイルシステムでは block allocator への書き込み"
7733 "も必要となるが、 このシステムコールは block allocator のディスクへの同期を行"
7734 "わない。 このシステムコールはディスク書き込みキャッシュのフラッシュを 行わな"
7735 "いので、揮発性のディスク書き込みキャッシュを使ったシステムでは このシステム"
7736 "コールではデータの一貫性を確保できないことになる。"
7737
7738 #. type: SS
7739 #: build/C/man2/sync_file_range.2:100
7740 #, no-wrap
7741 msgid "Some details"
7742 msgstr "詳細"
7743
7744 #. type: Plain text
7745 #: build/C/man2/sync_file_range.2:108
7746 msgid ""
7747 "B<SYNC_FILE_RANGE_WAIT_BEFORE> and B<SYNC_FILE_RANGE_WAIT_AFTER> will detect "
7748 "any I/O errors or B<ENOSPC> conditions and will return these to the caller."
7749 msgstr ""
7750 "B<SYNC_FILE_RANGE_WAIT_BEFORE> と B<SYNC_FILE_RANGE_WAIT_AFTER> は I/O エラー"
7751 "や B<ENOSPC> 状態を検出し、呼び出し元にこれらの情報を返す。"
7752
7753 #. type: Plain text
7754 #: build/C/man2/sync_file_range.2:112
7755 msgid "Useful combinations of the I<flags> bits are:"
7756 msgstr "I<flags> の役に立つビットの組み合わせを以下に示す:"
7757
7758 #. type: TP
7759 #: build/C/man2/sync_file_range.2:112
7760 #, no-wrap
7761 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE>"
7762 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE>"
7763
7764 #. type: Plain text
7765 #: build/C/man2/sync_file_range.2:120
7766 msgid ""
7767 "Ensures that all pages in the specified range which were dirty when "
7768 "B<sync_file_range>()  was called are placed under write-out.  This is a "
7769 "start-write-for-data-integrity operation."
7770 msgstr ""
7771 "指定された範囲内のページで、 B<sync_file_range>()  が呼び出された際に dirty "
7772 "であった全てのページが、 確実に書き出し対象となるようにする。 これは、start-"
7773 "write-for-data-integrity 操作 (データ完全性確保のための書き込み開始の操作) で"
7774 "ある。"
7775
7776 #. type: Plain text
7777 #: build/C/man2/sync_file_range.2:127
7778 msgid ""
7779 "Start write-out of all dirty pages in the specified range which are not "
7780 "presently under write-out.  This is an asynchronous flush-to-disk "
7781 "operation.  This is not suitable for data integrity operations."
7782 msgstr ""
7783 "指定された範囲内のページで、現在書き出し中でない全ての dirty ページの 書き出"
7784 "しを開始する。これは非同期のディスクへのフラッシュ (flush-to-disk)  操作であ"
7785 "る。データ完全性確保が必要な操作としては適切ではない。"
7786
7787 #. type: TP
7788 #: build/C/man2/sync_file_range.2:127
7789 #, no-wrap
7790 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE> (or B<SYNC_FILE_RANGE_WAIT_AFTER>)"
7791 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE> (or B<SYNC_FILE_RANGE_WAIT_AFTER>)"
7792
7793 #. type: Plain text
7794 #: build/C/man2/sync_file_range.2:134
7795 msgid ""
7796 "Wait for completion of write-out of all pages in the specified range.  This "
7797 "can be used after an earlier B<SYNC_FILE_RANGE_WAIT_BEFORE | "
7798 "SYNC_FILE_RANGE_WRITE> operation to wait for completion of that operation, "
7799 "and obtain its result."
7800 msgstr ""
7801 "指定された範囲内の全てのページの書き出しの完了を待つ。 このフラグは、前に行わ"
7802 "れた操作 B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE> の後に使用で"
7803 "き、この操作の完了を待ち、結果を取得することができる。"
7804
7805 #. type: TP
7806 #: build/C/man2/sync_file_range.2:134
7807 #, no-wrap
7808 msgid "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE | SYNC_FILE_RANGE_WAIT_AFTER>"
7809 msgstr "B<SYNC_FILE_RANGE_WAIT_BEFORE | SYNC_FILE_RANGE_WRITE | SYNC_FILE_RANGE_WAIT_AFTER>"
7810
7811 #. type: Plain text
7812 #: build/C/man2/sync_file_range.2:141
7813 msgid ""
7814 "This is a write-for-data-integrity operation that will ensure that all pages "
7815 "in the specified range which were dirty when B<sync_file_range>()  was "
7816 "called are committed to disk."
7817 msgstr ""
7818 "これは write-for-data-integrity 操作 (データ完全性確保のための書き込み) であ"
7819 "り、指定された範囲内の、 B<sync_file_range>()  が呼ばれた時点で dirty な全て"
7820 "のページが ディスクに格納されることが保証される。"
7821
7822 #. type: Plain text
7823 #: build/C/man2/sync_file_range.2:147
7824 msgid ""
7825 "On success, B<sync_file_range>()  returns 0; on failure -1 is returned and "
7826 "I<errno> is set to indicate the error."
7827 msgstr ""
7828 "成功の場合、 B<sync_file_range>()  は 0 を返す。失敗の場合、-1 を返し、 "
7829 "I<error> にエラーを示す値を設定する。"
7830
7831 #. type: Plain text
7832 #: build/C/man2/sync_file_range.2:152
7833 msgid "I<fd> is not a valid file descriptor."
7834 msgstr "I<fd> が有効なファイルディスクリプタではない。"
7835
7836 #. type: Plain text
7837 #: build/C/man2/sync_file_range.2:160
7838 msgid ""
7839 "I<flags> specifies an invalid bit; or I<offset> or I<nbytes> is invalid."
7840 msgstr ""
7841 "I<flags> に不正なビットが指定されている。または I<offset> か I<nbytes> が不正"
7842 "である。"
7843
7844 #. type: Plain text
7845 #: build/C/man2/sync_file_range.2:163
7846 msgid "I/O error."
7847 msgstr "I/O エラー。"
7848
7849 #. type: Plain text
7850 #: build/C/man2/sync_file_range.2:169
7851 msgid "Out of disk space."
7852 msgstr "ディスク領域不足である。"
7853
7854 #.  FIXME . (bug?) Actually, how can 'fd' refer to a symbolic link (S_ISLNK)?
7855 #.  (In userspace at least) it isn't possible to obtain a file descriptor
7856 #.  for a symbolic link.
7857 #. type: Plain text
7858 #: build/C/man2/sync_file_range.2:177
7859 msgid ""
7860 "I<fd> refers to something other than a regular file, a block device, a "
7861 "directory, or a symbolic link."
7862 msgstr ""
7863 "I<fd> が、通常のファイル、ブロックデバイス、ディレクトリ、シンボリックリンク "
7864 "以外のものを指している。"
7865
7866 #. type: Plain text
7867 #: build/C/man2/sync_file_range.2:180
7868 msgid "B<sync_file_range>()  appeared on Linux in kernel 2.6.17."
7869 msgstr "B<sync_file_range>()  はカーネル 2.6.17 で Linux に登場した。"
7870
7871 #. type: Plain text
7872 #: build/C/man2/sync_file_range.2:183
7873 msgid ""
7874 "This system call is Linux-specific, and should be avoided in portable "
7875 "programs."
7876 msgstr ""
7877 "このシステムコールは Linux 独自であり、 移植性が必要なプログラムでは使用を避"
7878 "けるべきである。"
7879
7880 #.  See kernel commit edd5cd4a9424f22b0fa08bef5e299d41befd5622
7881 #. type: Plain text
7882 #: build/C/man2/sync_file_range.2:196
7883 msgid ""
7884 "Some architectures (e.g., PowerPC, ARM)  need 64-bit arguments to be aligned "
7885 "in a suitable pair of registers.  On such architectures, the call signature "
7886 "of B<sync_file_range>()  is flawed, since it forces a register to be wasted "
7887 "as padding between the I<fd> and I<offset> arguments.  Therefore, these "
7888 "architectures define a different system call that orders the arguments "
7889 "suitably:"
7890 msgstr ""
7891
7892 #. type: Plain text
7893 #: build/C/man2/sync_file_range.2:201
7894 #, fuzzy, no-wrap
7895 #| msgid ""
7896 #| "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
7897 #| "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
7898 msgid ""
7899 "B<int sync_file_range2(int >I<fd>B<, unsigned int >I<flags>B<,>\n"
7900 "B<                     off64_t >I<offset>B<, off64_t >I<nbytes>B<);>\n"
7901 msgstr ""
7902 "B<int remap_file_pages(void *>I<addr>B<, size_t >I<size>B<, int >I<prot>B<,>\n"
7903 "B<                     ssize_t >I<pgoff>B<, int >I<flags>B<);>\n"
7904
7905 #. type: Plain text
7906 #: build/C/man2/sync_file_range.2:206
7907 msgid ""
7908 "The behavior of this system call is otherwise exactly the same as "
7909 "B<sync_file_range>()."
7910 msgstr ""
7911
7912 #. type: Plain text
7913 #: build/C/man2/sync_file_range.2:217
7914 msgid ""
7915 "A system call with this signature first appeared on the ARM architecture in "
7916 "Linux 2.6.20, with the name B<arm_sync_file_range>().  It was renamed in "
7917 "Linux 2.6.22, when the analogous system call was added for PowerPC.  On "
7918 "architectures where glibc support is provided, glibc transparently wraps "
7919 "B<sync_file_range2>()  under the name B<sync_file_range>()."
7920 msgstr ""
7921
7922 #. type: Plain text
7923 #: build/C/man2/sync_file_range.2:222
7924 #, fuzzy
7925 #| msgid ""
7926 #| "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2), "
7927 #| "B<feature_test_macros>(7)"
7928 msgid "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2)"
7929 msgstr "B<fdatasync>(2), B<fsync>(2), B<msync>(2), B<sync>(2)"
7930
7931 #, fuzzy
7932 #~| msgid "2011-09-08"
7933 #~ msgid "2011-09-19"
7934 #~ msgstr "2011-09-08"
7935
7936 #~ msgid "B<FALLOC_FL_KEEP_SIZE>"
7937 #~ msgstr "B<FALLOC_FL_KEEP_SIZE>"
7938
7939 #~ msgid ""
7940 #~ "This flag allocates and initializes to zero the disk space within the "
7941 #~ "range specified by I<offset> and I<len>.  After a successful call, "
7942 #~ "subsequent writes into this range are guaranteed not to fail because of "
7943 #~ "lack of disk space.  Preallocating zeroed blocks beyond the end of the "
7944 #~ "file is useful for optimizing append workloads.  Preallocating blocks "
7945 #~ "does not change the file size (as reported by B<stat>(2))  even if it is "
7946 #~ "less than I<offset>+I<len>."
7947 #~ msgstr ""
7948 #~ "このフラグは、 I<offset> と I<len> で指定された領域のディスク空間を割り当"
7949 #~ "て、その空間を 0 で初期化する。 呼び出しが成功すると、それに続いてこの領域"
7950 #~ "への書き込みが行われるが、 ディスク空間の不足による書き込み失敗が発生しな"
7951 #~ "いことが保証される。 ファイル末尾より後ろの領域について 0 で埋めたブロック"
7952 #~ "を前もって 割り当てておくことは、追記 (append) の作業負荷を最適化するのに "
7953 #~ "有用である。 ファイルサイズが I<offset>+I<len> よりも小さい場合であって"
7954 #~ "も、ブロックの前もっての割り当てにより (B<stat>(2)  が返す) ファイルサイズ"
7955 #~ "は変更されることはない。"
7956
7957 #, fuzzy
7958 #~| msgid "The buffer referred to by I<map> is not accessible."
7959 #~ msgid ""
7960 #~ "The file referred to by I<fd> is marked immutable (see B<chattr>(1))."
7961 #~ msgstr "The buffer referred to by I<map> is not accessible."
7962
7963 #~ msgid "2008-09-25"
7964 #~ msgstr "2008-09-25"
7965
7966 #~ msgid ""
7967 #~ "(Linux 2.6.9 and later) the caller was not privileged (B<CAP_IPC_LOCK>)  "
7968 #~ "and its B<RLIMIT_MEMLOCK> soft resource limit was 0."
7969 #~ msgstr ""
7970 #~ "(Linux 2.6.9 以降) 呼び出し元は特権 (B<CAP_IPC_LOCK>)  を持たず、ソフト資"
7971 #~ "源制限 B<RLIMIT_MEMLOCK> が 0 である。"
7972
7973 #~ msgid ""
7974 #~ "(Linux 2.6.8 and earlier)  The calling process has insufficient privilege "
7975 #~ "to call B<munlockall>().  Under Linux the B<CAP_IPC_LOCK> capability is "
7976 #~ "required."
7977 #~ msgstr ""
7978 #~ "(Linux 2.6.8 以前)  呼び出し元プロセスが B<munlockall>()  を呼び出すのに必"
7979 #~ "要な特権を所有していなかった。 Linux では、 B<CAP_IPC_LOCK> ケーパビリティ"
7980 #~ "が必要である。"
7981
7982 #~ msgid "2009-09-26"
7983 #~ msgstr "2009-09-26"
7984
7985 #~ msgid "2003-02-14"
7986 #~ msgstr "2003-02-14"
7987
7988 #~ msgid ""
7989 #~ "B<#define _XOPEN_SOURCE 600>\n"
7990 #~ "B<#include E<lt>fcntl.hE<gt>>\n"
7991 #~ msgstr ""
7992 #~ "B<#define _XOPEN_SOURCE 600>\n"
7993 #~ "B<#include E<lt>fcntl.hE<gt>>\n"
7994
7995 #~ msgid ""
7996 #~ "B<posix_fadvise>()  appeared in kernel 2.5.60.  Glibc support has been "
7997 #~ "provided since version 2.2."
7998 #~ msgstr ""
7999 #~ "B<posix_fadvise>()  はカーネル 2.5.60 で登場した。 glibc でのサポートは "
8000 #~ "glibc バージョン 2.2 以降で行われている。"
8001
8002 #~ msgid "2010-01-17"
8003 #~ msgstr "2010-01-17"
8004
8005 #~ msgid ""
8006 #~ "B<#define _GNU_SOURCE>\n"
8007 #~ "B<#include E<lt>fcntl.hE<gt>>\n"
8008 #~ msgstr ""
8009 #~ "B<#define _GNU_SOURCE>         /* feature_test_macros(7) 参照 */\n"
8010 #~ "B<#include E<lt>fcntl.hE<gt>>\n"