[TUHS] link() syscall implementation

Random832 random832 at fastmail.com
Sun Nov 15 07:18:13 AEST 2015

Oliver Lehmann <lehmann at ans-netz.de> writes:
>         ldl        rr2,rr8(#4)
>         ldl        rr4,rr2
>         and        r4,#32512
>         ldl        _u+78,rr4

This looks like it could be:
  u.u_dirp.l = uap->linkname;
  u.u_dirp.left &= 0x7f00;

> does the same but  with more instructions and of course not 1:1
> binary "the same" ;)
> wonder why
>   u.u_dirp.l = (caddr_t)(((long)uap->linkname) & 0x7F00FFFF);
> didn't worked.

Well, what code did it generate? Are longs in the same byte order as
pointers (could it have needed to be FFFF7F00)?

More information about the TUHS mailing list