Pristine Ack-5.5
[Ack-5.5.git] / mach / i386 / libsys / libmon_s.a
1 eÿexit.c\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0$\0exit(n)
2 {
3         _cleanup();
4         _exit(n);
5 }
6 cleanup.c\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\ f\0_cleanup() { }
7 astty.c\0.c\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0N\0stty(fildes, arg)
8         char *arg;
9 {
10         return ioctl(fildes, ('t' << 8) | 9, arg);
11 }
12 gtty.c\0.c\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0N\0gtty(fildes, arg)
13         char *arg;
14 {
15         return ioctl(fildes, ('t' << 8) | 8, arg);
16 }
17 dup.c\0\0.c\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0%\0int
18 dup(d)
19 {
20         return __xdup(d, 0);
21 }
22 rdup2.c\0.c\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0B\0int
23 dup2(oldd, newd)
24 {
25         oldd |= 64;
26         return __xdup(oldd, newd);
27 }
28 execl.c\0c\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0n\0int
29 execl(name,args)
30         char *name;
31         int args;
32 {
33         extern char **environ;
34
35         return execve(name,&args,environ);
36 }
37 execle.c\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0w\0int
38 execle(name,args)
39         char *name;
40         char *args;
41 {
42         char **p = &args;
43         while (*p++) ;
44
45         return execve(name,&args,*p);
46 }
47 \0execv.c\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0o\0int
48 execv(name,args)
49         char *name;
50         char **args;
51 {
52         extern char **environ;
53         return execve(name,args,environ);
54 }
55 ,pipe.c\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\84\0long _xpipe();
56
57 int
58 pipe(f)
59         int f[2];
60 {
61         long x;
62
63         x = _xpipe();
64         if (x == -1) return -1;
65         f[0] = x;
66         f[1] = x >> 16;
67         return 0;
68 }
69 profil.c\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\87\0char *_syspc;
70
71 profil(buff, bufsiz, offset, scale)
72         char *buff;
73         int (*offset)();
74 {
75         _xprofil(buff, bufsiz, offset, scale, &_syspc);
76 }
77 \0stime.c\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0,\0stime(p)
78         long *p;
79 {
80         return _xstime(*p);
81 }
82 time.c\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0[\0long _xtime();
83
84 long
85 time(p)
86         long *p;
87 {
88         long l = _xtime();
89         if (p) *p = l;
90
91         return l;
92 }
93 iwait.c\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\7f\0long _xwait();
94
95 wait(p)
96         int *p;
97 {
98         long l = _xwait();
99
100         if (l == -1) return -1;
101         if (p) *p = (l >> 16);
102         return l & 0xffff;
103 }
104 sxwait.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0£\0.sect .text; .sect .rom; .sect .data; .sect .bss
105 .define __xwait
106 .sect .text
107 __xwait:
108         mov     ax,7
109         callf   0x7:0x0
110         jb      1f
111         shl     dx,0x10
112         or      eax,edx
113         ret
114 1:
115         jmp     cerror
116 \0xpipe.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0¥\0.sect .text; .sect .rom; .sect .data; .sect .bss
117 .define __xpipe
118 .sect .text
119 __xpipe:
120         mov     ax,42
121         callf   0x7:0x0
122         jae     1f
123         jmp     cerror
124 1:
125         shl     dx,0x10
126         or      eax,edx
127         ret
128 \0xprofil.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0q\0.sect .text; .sect .rom; .sect .data; .sect .bss
129 .define __xprofil
130 .sect .text
131 __xprofil:
132         mov     ax,44
133         jmp     syscal
134 jxstime.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
135 .define __xstime
136 .sect .text
137 __xstime:
138         mov     ax,25
139         jmp     sysx
140 cxtime.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
141 .define __xtime
142 .sect .text
143 __xtime:
144         mov     ax,13
145         jmp     syscal
146 caccess.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
147 .define _access
148 .sect .text
149 _access:
150         mov     ax,33
151         jmp     sysx
152 lacct.s\0s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0g\0.sect .text; .sect .rom; .sect .data; .sect .bss
153 .define _acct
154 .sect .text
155 _acct:
156         mov     ax,51
157         jmp     sysx
158 yalarm.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
159 .define _alarm
160 .sect .text
161 _alarm:
162         mov     ax,27
163         jmp     syscal
164 lbrk.s\0s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0¯\0.sect .text; .sect .rom; .sect .data; .sect .bss
165 .define _brk
166 .sect .text
167 _brk:
168         mov     ax,17
169         callf   0x7:0x0
170         jb      1f
171         mov     ax,4(sp)
172         mov     (.limhp),ax
173         xor     ax,ax
174         ret
175 1:
176         jmp     cerror
177 \0chdir.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
178 .define _chdir
179 .sect .text
180 _chdir:
181         mov     ax,12
182         jmp     sysx
183
184 chmod.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
185 .define _chmod
186 .sect .text
187 _chmod:
188         mov     ax,15
189         jmp     sysx
190
191 chown.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
192 .define _chown
193 .sect .text
194 _chown:
195         mov     ax,16
196         jmp     sysx
197
198 chroot.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
199 .define _chroot
200 .sect .text
201 _chroot:
202         mov     ax,61
203         jmp     sysx
204 jclose.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0h\0.sect .text; .sect .rom; .sect .data; .sect .bss
205 .define _close
206 .sect .text
207 _close:
208         mov     ax,6
209         jmp     sysx
210 creat.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0j\0.sect .text; .sect .rom; .sect .data; .sect .bss
211 .define _creat
212 .sect .text
213 _creat:
214         mov     ax,8
215         jmp     syscal
216 execve.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0|\0.sect .text; .sect .rom; .sect .data; .sect .bss
217 .define _execve
218 .sect .text
219 _execve:
220         mov     ax,59
221         callf   0x7:0x0
222         jmp     cerror
223 fcntl.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
224 .define _fcntl
225 .sect .text
226 _fcntl:
227         mov     ax,62
228         jmp     syscal
229 :fork.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0æ\0.sect .text; .sect .rom; .sect .data; .sect .bss
230 .define _fork, _par_uid
231 .sect .bss
232 .comm   _par_uid, 4
233 .sect .text
234 _fork:
235         mov     ax,2
236         callf   0x7:0x0
237         jb      1f
238         and     dx,dx
239         jne     2f
240         ret
241 1:
242         jmp     cerror
243 2:
244         mov     (_par_uid),ax
245         xor     ax,ax
246         ret
247 fstat.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
248 .define _fstat
249 .sect .text
250 _fstat:
251         mov     ax,28
252         jmp     sysx
253 cftime.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
254 .define _ftime
255 .sect .text
256 _ftime:
257         mov     ax,2856
258         jmp     syscal
259 tgetegid.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\99\0.sect .text; .sect .rom; .sect .data; .sect .bss
260 .define _getegid
261 .sect .text
262 _getegid:
263         mov     ax,47
264         callf   0x7:0x0
265         jb      1f
266         xchg    dx,ax
267         ret
268 1:
269         jmp     cerror
270         geteuid.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\99\0.sect .text; .sect .rom; .sect .data; .sect .bss
271 .define _geteuid
272 .sect .text
273 _geteuid:
274         mov     ax,24
275         callf   0x7:0x0
276         jb      1f
277         xchg    dx,ax
278         ret
279 1:
280         jmp     cerror
281         getgid.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
282 .define _getgid
283 .sect .text
284 _getgid:
285         mov     ax,47
286         jmp     syscal
287 :getpgrp.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\91\0.sect .text; .sect .rom; .sect .data; .sect .bss
288 .define _getpgrp
289 .sect .text
290 _getpgrp:
291         xor     ax,ax
292         push    ax
293         mov     ax,39
294         call    syscal
295         pop     bx
296         ret
297         getpid.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
298 .define _getpid
299 .sect .text
300 _getpid:
301         mov     ax,20
302         jmp     syscal
303 mgetppid.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\99\0.sect .text; .sect .rom; .sect .data; .sect .bss
304 .define _getppid
305 .sect .text
306 _getppid:
307         mov     ax,20
308         callf   0x7:0x0
309         jb      1f
310         xchg    dx,ax
311         ret
312 1:
313         jmp     cerror
314         getuid.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
315 .define _getuid
316 .sect .text
317 _getuid:
318         mov     ax,24
319         jmp     syscal
320 :ioctl.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
321 .define _ioctl
322 .sect .text
323 _ioctl:
324         mov     ax,54
325         jmp     syscal
326 lkill.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0g\0.sect .text; .sect .rom; .sect .data; .sect .bss
327 .define _kill
328 .sect .text
329 _kill:
330         mov     ax,37
331         jmp     sysx
332 clink.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0f\0.sect .text; .sect .rom; .sect .data; .sect .bss
333 .define _link
334 .sect .text
335 _link:
336         mov     ax,9
337         jmp     sysx
338 lseek.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
339 .define _lseek
340 .sect .text
341 _lseek:
342         mov     ax,19
343         jmp     syscal
344 lmknod.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
345 .define _mknod
346 .sect .text
347 _mknod:
348         mov     ax,14
349         jmp     sysx
350 lmount.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
351 .define _mount
352 .sect .text
353 _mount:
354         mov     ax,21
355         jmp     sysx
356 lnice.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
357 .define _nice
358 .sect .text
359 _nice:
360         mov     ax,34
361         jmp     syscal
362 lopen.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0h\0.sect .text; .sect .rom; .sect .data; .sect .bss
363 .define _open
364 .sect .text
365 _open:
366         mov     ax,5
367         jmp     syscal
368 pause.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
369 .define _pause
370 .sect .text
371 _pause:
372         mov     ax,29
373         jmp     syscal
374 lread.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0h\0.sect .text; .sect .rom; .sect .data; .sect .bss
375 .define _read
376 .sect .text
377 _read:
378         mov     ax,3
379         jmp     syscal
380 sbrk.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0=\ 1.sect .text; .sect .rom; .sect .data; .sect .bss
381 .define _sbrk
382 .sect .text
383 _sbrk:
384         push    bp
385         mov     bp,sp
386         mov     ax,8(bp)
387         or      ax,ax
388         jne     1f
389         mov     ax,(.limhp)
390         pop     bp
391         ret
392 1:
393         mov     bx,(.limhp)
394         add     ax,bx
395         push    ax
396         call    _brk
397         or      ax,ax
398         jne     1f
399         pop     ax
400         mov     (.limhp),ax
401         mov     ax,bx
402         pop     bp
403         ret
404 1:
405         pop     ax
406         mov     ax,-1
407         pop     bp
408         ret
409 \0setgid.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
410 .define _setgid
411 .sect .text
412 _setgid:
413         mov     ax,46
414         jmp     sysx
415 asetuid.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
416 .define _setuid
417 .sect .text
418 _setuid:
419         mov     ax,23
420         jmp     sysx
421 asignal.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\96\ 1.sect .text; .sect .rom; .sect .data; .sect .bss
422 .define _signal
423 .sect .text
424 _signal:
425         call    sig1
426         mov     ax,48
427         mov     dx,ctch
428         callf   0x7:0x0
429         jb      4f
430         ret
431 sig1:
432         mov     ax,8(sp)
433         cmp     ax,20
434         jae     1f
435         mov     dx,table(ax*4)
436         mov     (prev),dx
437         mov     dx,12(sp)
438         mov     table(ax*4),dx
439         ret
440 1:
441         pop     ax
442         mov     ax,0x16
443 4:
444         mov     (_errno),ax
445         mov     ax,-1
446         cdq
447         ret
448
449 ctch:
450         add     sp,4
451         callf   0xf:0x0
452
453 .sect .bss
454 table:
455         .space 40
456 prev:
457         .space 4
458
459 stat.s\0s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0g\0.sect .text; .sect .rom; .sect .data; .sect .bss
460 .define _stat
461 .sect .text
462 _stat:
463         mov     ax,18
464         jmp     sysx
465 xsync.s\0s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
466 .define _sync
467 .sect .text
468 _sync:
469         mov     ax,36
470         jmp     syscal
471 4sys.s\0\0s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\ 3\ 1.sect .text; .sect .rom; .sect .data; .sect .bss
472 .define sysx, syscal, cerror, _errno
473
474 .sect .bss
475         .comm   _errno, 4
476
477 .sect .text
478
479 syscal:
480         callf   0x7:0x0
481         jb      cerror
482         ret
483
484 sysx:
485         callf   0x7:0x0
486         jb      cerror
487         xor     ax,ax
488         ret
489 cerror:
490         mov     (_errno),ax
491         mov     ax,-1
492         ret
493
494 etimes.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
495 .define _times
496 .sect .text
497 _times:
498         mov     ax,43
499         jmp     syscal
500 rulimit.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
501 .define _ulimit
502 .sect .text
503 _ulimit:
504         mov     ax,63
505         jmp     syscal
506 numask.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
507 .define _umask
508 .sect .text
509 _umask:
510         mov     ax,60
511         jmp     syscal
512 lumount.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
513 .define _umount
514 .sect .text
515 _umount:
516         mov     ax,22
517         jmp     sysx
518 luname.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
519 .define _uname
520 .sect .text
521 _uname:
522         mov     ax,57
523         jmp     syscal
524 lunlink.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
525 .define _unlink
526 .sect .text
527 _unlink:
528         mov     ax,10
529         jmp     sysx
530 lutime.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
531 .define _utime
532 .sect .text
533 _utime:
534         mov     ax,30
535         jmp     sysx
536 xwrite.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0j\0.sect .text; .sect .rom; .sect .data; .sect .bss
537 .define _write
538 .sect .text
539 _write:
540         mov     ax,4
541         jmp     syscal
542 xdup.s\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
543 .define ___xdup
544 .sect .text
545 ___xdup:
546         mov     ax,41
547         jmp     syscal
548 n_alarm.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
549 .define __alarm
550 .sect .text
551 __alarm:
552         mov     ax,27
553         jmp     syscal
554 n_brk.s\0s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0±\0.sect .text; .sect .rom; .sect .data; .sect .bss
555 .define __brk
556 .sect .text
557 __brk:
558         mov     ax,17
559         callf   0x7:0x0
560         jb      1f
561         mov     ax,4(sp)
562         mov     (.limhp),ax
563         xor     ax,ax
564         ret
565 1:
566         jmp     cerror
567 a_close.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0j\0.sect .text; .sect .rom; .sect .data; .sect .bss
568 .define __close
569 .sect .text
570 __close:
571         mov     ax,6
572         jmp     sysx
573 _creat.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0l\0.sect .text; .sect .rom; .sect .data; .sect .bss
574 .define __creat
575 .sect .text
576 __creat:
577         mov     ax,8
578         jmp     syscal
579 _dup.c\0s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0&\0int
580 _dup(d)
581 {
582         return __xdup(d, 0);
583 }
584 _dup2.c\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0C\0int
585 _dup2(oldd, newd)
586 {
587         oldd |= 64;
588         return __xdup(oldd, newd);
589 }
590 e_execl.c\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0p\0int
591 _execl(name,args)
592         char *name;
593         int args;
594 {
595         extern char **environ;
596
597         return _execve(name,&args,environ);
598 }
599 _execve.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0~\0.sect .text; .sect .rom; .sect .data; .sect .bss
600 .define __execve
601 .sect .text
602 __execve:
603         mov     ax,59
604         callf   0x7:0x0
605         jmp     cerror
606 _exit.s\0s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0y\0.sect .text; .sect .rom; .sect .data; .sect .bss
607 .define __exit
608 .sect .text
609 __exit:
610         mov     ax,1
611         callf   0x7:0x0
612         jmp     cerror
613 r_fork.s\0s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0®\0.sect .text; .sect .rom; .sect .data; .sect .bss
614 .define __fork
615 .sect .text
616 __fork:
617         mov     ax,2
618         callf   0x7:0x0
619         jb      1f
620         and     dx,dx
621         jne     2f
622         ret
623 1:
624         jmp     cerror
625 2:
626         xor     ax,ax
627         ret
628 _fstat.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0k\0.sect .text; .sect .rom; .sect .data; .sect .bss
629 .define __fstat
630 .sect .text
631 __fstat:
632         mov     ax,28
633         jmp     sysx
634 0_ftime.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0o\0.sect .text; .sect .rom; .sect .data; .sect .bss
635 .define __ftime
636 .sect .text
637 __ftime:
638         mov     ax,2856
639         jmp     syscal
640 b_getpid.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0o\0.sect .text; .sect .rom; .sect .data; .sect .bss
641 .define __getpid
642 .sect .text
643 __getpid:
644         mov     ax,20
645         jmp     syscal
646 b_gtty.c\0s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0P\0_gtty(fildes, arg)
647         char *arg;
648 {
649         return _ioctl(fildes, ('t' << 8) | 8, arg);
650 }
651 _ioctl.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
652 .define __ioctl
653 .sect .text
654 __ioctl:
655         mov     ax,54
656         jmp     syscal
657 l_kill.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0i\0.sect .text; .sect .rom; .sect .data; .sect .bss
658 .define __kill
659 .sect .text
660 __kill:
661         mov     ax,37
662         jmp     sysx
663 c_link.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0h\0.sect .text; .sect .rom; .sect .data; .sect .bss
664 .define __link
665 .sect .text
666 __link:
667         mov     ax,9
668         jmp     sysx
669 _lseek.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
670 .define __lseek
671 .sect .text
672 __lseek:
673         mov     ax,19
674         jmp     syscal
675 l_open.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0j\0.sect .text; .sect .rom; .sect .data; .sect .bss
676 .define __open
677 .sect .text
678 __open:
679         mov     ax,5
680         jmp     syscal
681 _pause.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
682 .define __pause
683 .sect .text
684 __pause:
685         mov     ax,29
686         jmp     syscal
687 l_pipe.c\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\85\0long _xpipe();
688
689 int
690 _pipe(f)
691         int f[2];
692 {
693         long x;
694
695         x = _xpipe();
696         if (x == -1) return -1;
697         f[0] = x;
698         f[1] = x >> 16;
699         return 0;
700 }
701 f_read.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0j\0.sect .text; .sect .rom; .sect .data; .sect .bss
702 .define __read
703 .sect .text
704 __read:
705         mov     ax,3
706         jmp     syscal
707 _sbrk.s\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0?\ 1.sect .text; .sect .rom; .sect .data; .sect .bss
708 .define __sbrk
709 .sect .text
710 __sbrk:
711         push    bp
712         mov     bp,sp
713         mov     ax,8(bp)
714         or      ax,ax
715         jne     1f
716         mov     ax,(.limhp)
717         pop     bp
718         ret
719 1:
720         mov     bx,(.limhp)
721         add     ax,bx
722         push    ax
723         call    _brk
724         or      ax,ax
725         jne     1f
726         pop     ax
727         mov     (.limhp),ax
728         mov     ax,bx
729         pop     bp
730         ret
731 1:
732         pop     ax
733         mov     ax,-1
734         pop     bp
735         ret
736 d_unlink.s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0m\0.sect .text; .sect .rom; .sect .data; .sect .bss
737 .define __unlink
738 .sect .text
739 __unlink:
740         mov     ax,10
741         jmp     sysx
742 a_wait.c\0s\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0\80\0long _xwait();
743
744 _wait(p)
745         int *p;
746 {
747         long l = _xwait();
748
749         if (l == -1) return -1;
750         if (p) *p = (l >> 16);
751         return l & 0xffff;
752 }
753 _write.s\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤\ 1\0\0l\0.sect .text; .sect .rom; .sect .data; .sect .bss
754 .define __write
755 .sect .text
756 __write:
757         mov     ax,4
758         jmp     syscal