converted to ACK assembler format

This commit is contained in:
ceriel 1987-05-14 17:45:41 +00:00
parent 680e0c347c
commit 7abf78f452
81 changed files with 553 additions and 504 deletions

View file

@ -10,7 +10,7 @@ cmp: all
-../../compare libmon_o.a tail_mon -../../compare libmon_o.a tail_mon
libmon_o.a: libmon_s.a libmon_o.a: libmon_s.a
ASAR=ar ; export ASAR ;\ ASAR=aal ; export ASAR ;\
march . libmon_o.a march . libmon_o.a
clean: clean:

View file

@ -1,5 +1,5 @@
#include "sys.h" #include "sys.h"
.globl __exit .define __exit
__exit: __exit:
mov 2(sp),r0 mov 2(sp),r0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _access .define _access
.globl _errno .extern _errno
_access: _access:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
clr r0 clr r0
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys access; ..; .. sys access
.data2 0, 0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _acct .define _acct
.globl _errno .extern _errno
_acct: _acct:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0, _errno mov r0, _errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys acct; .. sys acct
.data2 0

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _alarm .define _alarm
.globl _errno .extern _errno
_alarm: _alarm:
mov 2(sp),r0 mov 2(sp),r0
sys alarm sys alarm
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _chdir .define _chdir
.globl _errno .extern _errno
_chdir: _chdir:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys chdir; .. sys chdir
.data2 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _chmod .define _chmod
.globl _errno .extern _errno
_chmod: _chmod:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys chmod; ..; .. sys chmod
.data2 0, 0

View file

@ -1,19 +1,20 @@
#include "sys.h" #include "sys.h"
.globl _chown .define _chown
.globl _errno .extern _errno
_chown: _chown:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys chown; ..; ..; .. sys chown
.data2 0, 0, 0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _chroot .define _chroot
.globl _errno .extern _errno
_chroot: _chroot:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys chroot; .. sys chroot
.data2 0

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _close .define _close
.globl _errno .extern _errno
_close: _close:
mov 2(sp),r0 mov 2(sp),r0
sys close sys close
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,4 +1,4 @@
if pdp -O -P -c -I../../../h -I. $1 1>&2 if pdp -O -c -I../../../h -I. $1 1>&2
then echo `basename $1 $2`.o then echo `basename $1 $2`.o
else exit 1 else exit 1
fi fi

View file

@ -1,16 +1,17 @@
#include "sys.h" #include "sys.h"
.globl _creat .define _creat
.globl _errno .extern _errno
_creat: _creat:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys creat; ..; .. sys creat
.data2 0, 0

View file

@ -1,7 +1,7 @@
#include "sys.h" #include "sys.h"
.globl _dup .define _dup
.globl _dup2 .define _dup2
.globl _errno .extern _errno
_dup2: _dup2:
mov 2(sp),r0 mov 2(sp),r0
@ -13,7 +13,7 @@ _dup:
1: 1:
mov 4(sp),r1 mov 4(sp),r1
sys dup sys dup
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:

View file

@ -1,3 +1,4 @@
.globl _errno .sect .text ; .sect .rom; .sect .data; .sect .bss
.bss .define _errno
_errno: .=.+2 .sect .bss
_errno: .space 2

View file

@ -1,7 +1,7 @@
#include "sys.h" #include "sys.h"
.globl _execl .define _execl
.globl _environ .extern _environ
.globl _errno .extern _errno
_execl: _execl:
mov 2(sp),0f+2 mov 2(sp),0f+2
@ -9,10 +9,11 @@ _execl:
add $4,r0 add $4,r0
mov r0,0f+4 mov r0,0f+4
mov _environ,0f+6 mov _environ,0f+6
sys indir; 0f sys indir; .data2 0f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
.data .sect .data
0: 0:
sys exece; ..; ..; .. sys exece
.data2 0, 0, 0

View file

@ -1,6 +1,6 @@
#include "sys.h" #include "sys.h"
.globl _execle .define _execle
.globl _errno .extern _errno
_execle: _execle:
mov 2(sp),0f+2 mov 2(sp),0f+2
@ -11,10 +11,11 @@ _execle:
tst (r0)+ tst (r0)+
bne 1b bne 1b
mov (r0),0f+6 mov (r0),0f+6
sys indir; 0f sys indir; .data2 0f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
.data .sect .data
0: 0:
sys exece; ..; ..; .. sys exece
.data2 0, 0, 0

View file

@ -1,16 +1,17 @@
#include "sys.h" #include "sys.h"
.globl _execv, .define _execv
.globl _environ .extern _environ
.globl _errno .extern _errno
_execv: _execv:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov _environ,0f+6 mov _environ,0f+6
sys indir; 0f sys indir; .data2 0f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
.data .sect .data
0: 0:
sys exece; ..; ..; .. sys exece
.data2 0, 0, 0

View file

@ -1,15 +1,16 @@
#include "sys.h" #include "sys.h"
.globl _execve .define _execve
.globl _errno .extern _errno
_execve: _execve:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys indir; 0f sys indir; .data2 0f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
.data .sect .data
0: 0:
sys exece; ..; ..; .. sys exece
.data2 0, 0, 0

View file

@ -1,15 +1,15 @@
#include "sys.h" #include "sys.h"
.globl _fetchi .define _fetchi
.globl _errno .extern _errno
_fetchi: _fetchi:
mov 2(sp),r0 mov 2(sp),r0
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys fetchi sys fetchi

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _fork .define _fork
.globl _errno .extern _errno
_fork: _fork:
sys fork sys fork
br 1f br 1f
bec 2f bcc 2f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
2: 2:

View file

@ -1,10 +1,10 @@
#include "sys.h" #include "sys.h"
.globl _fperr .define _fperr
.globl _errno .extern _errno
_fperr: _fperr:
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
@ -15,6 +15,6 @@ _fperr:
mov r1,(r5) mov r1,(r5)
mov (sp)+,r5 mov (sp)+,r5
rts pc rts pc
.data .sect .data
0: 0:
sys fperr sys fperr

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _fstat .define _fstat
.globl _errno .extern _errno
_fstat: _fstat:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys fstat; .. sys fstat
.data2 0

View file

@ -1,11 +1,12 @@
#include "sys.h" #include "sys.h"
.globl _ftime .define _ftime
_ftime: _ftime:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
rts pc rts pc
.data .sect .data
0: 0:
sys ftime; .. sys ftime
.data2 0

View file

@ -1,6 +1,6 @@
#include "sys.h" #include "sys.h"
.globl _getgid .define _getgid
.globl _getegid .define _getegid
_getgid: _getgid:
sys getgid sys getgid

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _getgrp .define _getgrp
.globl _errno .extern _errno
_getgrp: _getgrp:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys getgrp; .. sys getgrp
.data2 0

View file

@ -1,5 +1,5 @@
#include "sys.h" #include "sys.h"
.globl _getpid .define _getpid
_getpid: _getpid:
sys getpid sys getpid

View file

@ -1,5 +1,5 @@
#include "sys.h" #include "sys.h"
.globl _getppid .define _getppid
_getppid: _getppid:
sys getpid sys getpid

View file

@ -1,6 +1,6 @@
#include "sys.h" #include "sys.h"
.globl _getuid .define _getuid
.globl _geteuid .define _geteuid
_getuid: _getuid:
sys getuid sys getuid

View file

@ -1,17 +1,17 @@
#include "sys.h" #include "sys.h"
.globl _gldav .define _gldav
.globl _errno .extern _errno
_gldav: _gldav:
mov 2(sp),r0 mov 2(sp),r0
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys gldav sys gldav

View file

@ -1,7 +1,6 @@
#include <sgtty.h>
int gtty(fildes,argp) int gtty(fildes,argp)
int fildes ; int fildes ;
struct sgttyb *argp ; char *argp ;
{ {
return ioctl(fildes,TIOCGETP,argp) ; return ioctl(fildes,/*TIOCGETP*/(('t'<<8)|8),argp) ;
} }

View file

@ -1,19 +1,20 @@
#include "sys.h" #include "sys.h"
.globl _ioctl .define _ioctl
.globl _errno .extern _errno
_ioctl: _ioctl:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys ioctl; ..; ..; .. sys ioctl
.data2 0, 0, 0

View file

@ -1,12 +1,12 @@
#include "sys.h" #include "sys.h"
.globl _kill .define _kill
.globl _errno .extern _errno
_kill: _kill:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
@ -14,6 +14,7 @@ _kill:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys kill; .. sys kill
.data2 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _killbkg .define _killbkg
.globl _errno .extern _errno
_killbkg: _killbkg:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys killbkg; ..; .. sys killbkg
.data2 0, 0

View file

@ -1,12 +1,12 @@
#include "sys.h" #include "sys.h"
.globl _killpg .define _killpg
.globl _errno .extern _errno
_killpg: _killpg:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
@ -14,6 +14,7 @@ _killpg:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys killpg; ..; .. sys killpg
.data2 0, 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _link .define _link
.globl _errno .extern _errno
_link: _link:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys link; ..; .. sys link
.data2 0, 0

View file

@ -1,15 +1,16 @@
#include "sys.h" #include "sys.h"
.globl _lock .define _lock
.globl _errno .extern _errno
_lock: _lock:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys lock; .. sys lock
.data2 0

View file

@ -1,19 +1,20 @@
#include "sys.h" #include "sys.h"
.globl _login .define _login
.globl _errno .extern _errno
_login: _login:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys login; ..; ..; ..; sys login
.data2 0, 0, 0

View file

@ -1,19 +1,20 @@
#include "sys.h" #include "sys.h"
.globl _lseek .define _lseek
.globl _errno .extern _errno
_lseek: _lseek:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
mov 6(sp),0f+4 mov 6(sp),0f+4
mov 10(sp),0f+6 mov 010(sp),0f+6
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov $-1,r1 mov $-1,r1
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys lseek; ..; ..; .. sys lseek
.data2 0, 0, 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _lstat .define _lstat
.globl _errno .extern _errno
_lstat: _lstat:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys lstat; ..; .. sys lstat
.data2 0, 0

View file

@ -1,19 +1,20 @@
#include "sys.h" #include "sys.h"
.globl _mknod .define _mknod
.globl _errno .extern _errno
_mknod: _mknod:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys mknod; ..; ..; .. sys mknod
.data2 0, 0, 0

View file

@ -1,19 +1,20 @@
#include "sys.h" #include "sys.h"
.globl _mount .define _mount
.globl _errno .extern _errno
_mount: _mount:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys mount; ..; ..; .. sys mount
.data2 0, 0, 0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _mpxcall .define _mpxcall
.globl _errno .extern _errno
_mpxcall: _mpxcall:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys mpx; ..; .. sys mpx
.data2 0, 0

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _nice .define _nice
.globl _errno .extern _errno
_nice: _nice:
mov 2(sp),r0 mov 2(sp),r0
sys nice sys nice
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,9 +1,9 @@
#include "sys.h" #include "sys.h"
.globl _nostk .define _nostk
_nostk: _nostk:
sys local; 0f sys local; .data2 0f
rts pc rts pc
.data .sect .data
0: 0:
sys nostk sys nostk

View file

@ -1,16 +1,17 @@
#include "sys.h" #include "sys.h"
.globl _open .define _open
.globl _errno .extern _errno
_open: _open:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys open; ..; .. sys open
.data2 0, 0

View file

@ -1,5 +1,5 @@
#include "sys.h" #include "sys.h"
.globl _pause .define _pause
_pause: _pause:
sys pause sys pause

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _phys .define _phys
.globl _errno .extern _errno
_phys: _phys:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys phys; ..; ..; .. sys phys
.data2 0, 0, 0

View file

@ -1,10 +1,10 @@
#include "sys.h" #include "sys.h"
.globl _pipe .define _pipe
.globl _errno .extern _errno
_pipe: _pipe:
sys pipe sys pipe
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,13 +1,14 @@
#include "sys.h" #include "sys.h"
.globl _profil .define _profil
_profil: _profil:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
mov 10(sp),0f+10 mov 010(sp),0f+010
sys indir; 0f sys indir; .data2 0f
rts pc rts pc
.data .sect .data
0: 0:
sys profil; ..; ..; ..; .. sys profil
.data2 0, 0, 0, 0

View file

@ -1,20 +1,21 @@
#include "sys.h" #include "sys.h"
.globl _ptrace .define _ptrace
.globl _errno .extern _errno
_ptrace: _ptrace:
mov 2(sp),0f+6 mov 2(sp),0f+6
mov 4(sp),0f+2 mov 4(sp),0f+2
mov 6(sp),0f+4 mov 6(sp),0f+4
mov 10(sp),r0 mov 010(sp),r0
clr _errno clr _errno
sys indir; 9f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys ptrace; ..; ..; .. sys ptrace
.data2 0, 0, 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _qfstat .define _qfstat
.globl _errno .extern _errno
_qfstat: _qfstat:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys qfstat; .. sys qfstat
.data2 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _qstat .define _qstat
.globl _errno .extern _errno
_qstat: _qstat:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys qstat; ..; .. sys qstat
.data2 0, 0

View file

@ -1,21 +1,22 @@
#include "sys.h" #include "sys.h"
.globl _quota .define _quota
.globl _errno .extern _errno
_quota: _quota:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
mov 10(sp),0f+10 mov 010(sp),0f+010
mov 12(sp),0f+12 mov 012(sp),0f+012
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys quota; ..; ..; ..; ..; .. sys quota
.data2 0, 0, 0, 0, 0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _read .define _read
.globl _errno .extern _errno
_read: _read:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
mov 6(sp),0f+4 mov 6(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys read; ..; .. sys read
.data2 0, 0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _readlink .define _readlink
.globl _errno .extern _errno
_readlink: _readlink:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
mov 6(sp),0f+4 mov 6(sp),0f+4
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys readlink; ..; .. sys readlink
.data2 0, 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _reboot .define _reboot
.globl _errno .extern _errno
_reboot: _reboot:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys reboot; ..; .. sys reboot
.data2 0, 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _renice .define _renice
.globl _errno .extern _errno
_renice: _renice:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys renice; ..; .. sys renice
.data2 0, 0

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _rtp .define _rtp
.globl _errno .extern _errno
_rtp: _rtp:
mov 2(sp),r0 mov 2(sp),r0
sys rtp sys rtp
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,16 +1,16 @@
#include "sys.h" #include "sys.h"
.globl _sbrk .define _sbrk
.globl _brk .define _brk
.globl _end .extern _end
.globl _errno .extern _errno
_sbrk: _sbrk:
mov 2(sp),0f+2 mov 2(sp),0f+2
beq 1f beq 1f
add xxx,0f+2 add xxx,0f+2
bcs 2f bcs 2f
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
2: 2:
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
@ -22,8 +22,8 @@ _sbrk:
_brk: _brk:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
@ -32,7 +32,8 @@ _brk:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys break; .. sys break
xxx: _end .data2 0
xxx: .data2 _end

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _setgid .define _setgid
.globl _errno .extern _errno
_setgid: _setgid:
mov 2(sp),r0 mov 2(sp),r0
sys setgid sys setgid
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _setgrp .define _setgrp
.globl _errno .extern _errno
_setgrp: _setgrp:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys setgrp; .. sys setgrp
.data2 0

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _setuid .define _setuid
.globl _errno .extern _errno
_setuid: _setuid:
mov 2(sp),r0 mov 2(sp),r0
sys setuid sys setuid
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,31 +1,30 @@
#include <errno.h>
#include "sys.h" #include "sys.h"
rtt = 6 EINVAL = 026
.globl _signal .define _signal
.globl _errno .extern _errno
NSIGNALS = 0 NSIGNALS = 024
tvect: tvect:
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
jsr r0,1f; NSIGNALS=NSIGNALS+1 jsr r0,1f
1: 1:
mov r1,-(sp) mov r1,-(sp)
@ -64,8 +63,8 @@ _signal:
add $tvect,r1 add $tvect,r1
mov r1,0f+4 mov r1,0f+4
1: 1:
sys indir; 0f sys indir; .data2 0f
bes 3f bcs 3f
bit $1,r0 bit $1,r0
beq 1f beq 1f
mov r0,(sp) mov r0,(sp)
@ -74,15 +73,16 @@ _signal:
mov (sp)+,r5 mov (sp)+,r5
rts pc rts pc
2: 2:
mov $EINVAL.,r0 mov $EINVAL,r0
3: 3:
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
mov (sp)+,r5 mov (sp)+,r5
rts pc rts pc
.data .sect .data
0: 0:
sys signal; ..; .. sys signal
.bss .data2 0, 0
dvect: .=.+[NSIGNALS*2] .sect .bss
dvect: .space [NSIGNALS*2]

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _stat .define _stat
.globl _errno .extern _errno
_stat: _stat:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys stat; ..; .. sys stat
.data2 0, 0

View file

@ -1,13 +1,13 @@
#include "sys.h" #include "sys.h"
.globl _stime .define _stime
.globl _errno .extern _errno
_stime: _stime:
mov 2(sp),r1 mov 2(sp),r1
mov (r1)+,r0 mov (r1)+,r0
mov (r1),r1 mov (r1),r1
sys stime sys stime
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,7 +1,6 @@
#include <sgtty.h>
int stty(fildes,argp) int stty(fildes,argp)
int fildes ; int fildes ;
struct sgttyb *argp ; char *argp;
{ {
return ioctl(fildes,TIOCSETP,argp) ; return ioctl(fildes,/*TIOCSETP*/(('t'<<8)|9),argp) ;
} }

View file

@ -1,15 +1,15 @@
#include "sys.h" #include "sys.h"
.globl _submit .define _submit
.globl _errno .extern _errno
_submit: _submit:
mov 2(sp),r0 mov 2(sp),r0
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys submit sys submit

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _symlink .define _symlink
.globl _errno .extern _errno
_symlink: _symlink:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys symlink; .. sys symlink
.data2 0

View file

@ -1,5 +1,5 @@
#include "sys.h" #include "sys.h"
.globl _sync .define _sync
_sync: _sync:
sys sync sys sync

View file

@ -3,100 +3,102 @@
* (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands. * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
* See the copyright notice in the ACK home directory, in the file "Copyright". * See the copyright notice in the ACK home directory, in the file "Copyright".
*/ */
#define indir 0. #define indir 0
#define exit 1. #define exit 1
#define fork 2. #define fork 2
#define read 3. #define read 3
#define write 4. #define write 4
#define open 5. #define open 5
#define close 6. #define close 6
#define wait 7. #define wait 7
#define creat 8. #define creat 010
#define link 9. #define link 011
#define unlink 10. #define unlink 012
#define exec 11. #define exec 013
#define chdir 12. #define chdir 014
#define time 13. #define time 015
#define mknod 14. #define mknod 016
#define chmod 15. #define chmod 017
#define chown 16. #define chown 020
#define break 17. #define break 021
#define stat 18. #define stat 022
#define lseek 19. #define lseek 023
#define getpid 20. #define getpid 024
#define mount 21. #define mount 025
#define umount 22. #define umount 026
#define setuid 23. #define setuid 027
#define getuid 24. #define getuid 030
#define stime 25. #define stime 031
#define ptrace 26. #define ptrace 032
#define alarm 27. #define alarm 033
#define fstat 28. #define fstat 034
#define pause 29. #define pause 035
#define utime 30. #define utime 036
#define smdate 30. #define smdate 036
#define stty 31. #define stty 037
#define gtty 32. #define gtty 040
#define access 33. #define access 041
#define nice 34. #define nice 042
#define sleep 35. #define sleep 043
#define ftime 35. #define ftime 043
#define sync 36. #define sync 044
#define kill 37. #define kill 045
#define csw 38. #define csw 046
#define setpgrp 39. #define setpgrp 047
#define dup 41. #define dup 051
#define pipe 42. #define pipe 052
#define times 43. #define times 053
#define profil 44. #define profil 054
#define getgrp 45. #define getgrp 055
#define setgid 46. #define setgid 056
#define getgid 47. #define getgid 057
#define signal 48. #define signal 060
#define rtp 49. #define rtp 061
#define setgrp 50. #define setgrp 062
#define acct 51. #define acct 063
#define phys 52. #define phys 064
#define lock 53. #define lock 065
#define ioctl 54. #define ioctl 066
#define reboot 55. #define reboot 067
#define mpx 56. #define mpx 070
#define vfork 57. #define vfork 071
#define setinf 59. #define setinf 073
#define exece 59. #define exece 073
#define local 58. #define local 072
#define umask 60. #define umask 074
#define getinf 60. #define getinf 074
#define chroot 61. #define chroot 075
#define login 1. #define login 01
#define lstat 2. #define lstat 02
#define submit 3. #define submit 03
#define nostk 4. #define nostk 04
#define killbkg 5. #define killbkg 05
#define killpg 6. #define killpg 06
#define renice 7. #define renice 07
#define fetchi 8. #define fetchi 010
#define ucall 9. #define ucall 011
#define quota 10. #define quota 012
#define qfstat 11. #define qfstat 013
#define qstat 12. #define qstat 014
#define gldav 14. #define gldav 016
#define fperr 15. #define fperr 017
#define vhangup 16. #define vhangup 020
#define symlink 29. #define symlink 035
#define readlink 30. #define readlink 036
#define select 18. #define select 022
#define gethost 19. #define gethost 023
#define sethost 20. #define sethost 024
#define socket 21. #define socket 025
#define connect 22. #define connect 026
#define accept 23. #define accept 027
#define send 24. #define send 030
#define receive 25. #define receive 031
#define socketa 26. #define socketa 032
#define setreuid 27. #define setreuid 033
#define setregid 28. #define setregid 034
#define gethstid 31. #define gethstid 037
#define sethstid 32. #define sethstid 040
.sect .text; .sect .rom; .sect .data; .sect .bss; .sect .text

View file

@ -1,5 +1,5 @@
#include "sys.h" #include "sys.h"
.globl _time .define _time
_time: _time:
sys time sys time

View file

@ -1,10 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _times .define _times
_times: _times:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
rts pc rts pc
.data .sect .data
0: 0:
sys times; .. sys times
.data2 0

View file

@ -1,13 +1,14 @@
#include "sys.h" #include "sys.h"
.globl _ucall .define _ucall
_ucall: _ucall:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
mov 6(sp),0f+6 mov 6(sp),0f+6
mov 10(sp),0f+10 mov 010(sp),0f+010
sys local; 0f sys local; .data2 0f
rts pc rts pc
.data .sect .data
0: 0:
sys ucall; ..; ..; ..; .. sys ucall
.data2 0, 0, 0, 0

View file

@ -1,15 +1,16 @@
#include "sys.h" #include "sys.h"
.globl _umask .define _umask
.globl _errno .extern _errno
_umask: _umask:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys umask; .. sys umask
.data2 0

View file

@ -1,11 +1,11 @@
#include "sys.h" #include "sys.h"
.globl _umount .define _umount
.globl _errno .extern _errno
_umount: _umount:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
@ -13,6 +13,7 @@ _umount:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys umount; .. sys umount
.data2 0

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _unlink .define _unlink
.globl _errno .extern _errno
_unlink: _unlink:
mov 2(sp),0f+2 mov 2(sp),0f+2
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys unlink; .. sys unlink
.data2 0

View file

@ -1,18 +1,19 @@
#include "sys.h" #include "sys.h"
.globl _utime .define _utime
.globl _errno .extern _errno
_utime: _utime:
mov 2(sp),0f+2 mov 2(sp),0f+2
mov 4(sp),0f+4 mov 4(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc
1: 1:
clr r0 clr r0
rts pc rts pc
.data .sect .data
0: 0:
sys utime; ..; .. sys utime
.data2 0, 0

View file

@ -1,18 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _vfork .define _vfork
.globl _errno .extern _errno
_vfork: _vfork:
mov (sp)+,r1 mov (sp)+,r1
sys vfork sys vfork
br 1f br 1f
bec 2f bcc 2f
3: mov r0,_errno 3: mov r0,_errno
mov $-1,r0 mov $-1,r0
jmp (r1) jmp (r1)
1: / child, or vfork systemcall does not exist 1: ! child, or vfork systemcall does not exist
bes 3b bcs 3b
clr r0 clr r0
2: 2:
jmp (r1) jmp (r1)

View file

@ -1,14 +1,14 @@
#include "sys.h" #include "sys.h"
.globl _vhangup .define _vhangup
.globl _errno .extern _errno
_vhangup: _vhangup:
sys local; 0f sys local; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys vhangup sys vhangup

View file

@ -1,10 +1,10 @@
#include "sys.h" #include "sys.h"
.globl _wait .define _wait
.globl _errno .extern _errno
_wait: _wait:
sys wait sys wait
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
rts pc rts pc

View file

@ -1,17 +1,18 @@
#include "sys.h" #include "sys.h"
.globl _write .define _write
.globl _errno .extern _errno
_write: _write:
mov 2(sp),r0 mov 2(sp),r0
mov 4(sp),0f+2 mov 4(sp),0f+2
mov 6(sp),0f+4 mov 6(sp),0f+4
sys indir; 0f sys indir; .data2 0f
bec 1f bcc 1f
mov r0,_errno mov r0,_errno
mov $-1,r0 mov $-1,r0
1: 1:
rts pc rts pc
.data .sect .data
0: 0:
sys write; ..; .. sys write
.data2 0, 0