/* @(#) dspSPARC.il Version 1.1 (4/21/92). copyright Venue & Fuji Xerox */ /* @(#) dispSPARC.il Version 2.7 (7/25/90). copyright Xerox & Fuji Xerox */ /* change _name_scan for name table expanding '90/07/13 by osamu */ /* Name table Expanded version */ /* _name_scan2(entry, limit, names) inner loop of FVAR %o0 entry even pointer to name table entry %o1 limit oct_byte pointer beyond last name %o2 names 32 bit (actually 24bit) atom number %o4 low contents of entry /**/ .inline _name_scan2,12 !(entry, limit, names) returns first+4 or 0 loop: cmp %o0,%o1 !loop: if(entry> 1 */ .inline _op_lrsh1,4 srl %o0,16,%o2 cmp %o2,0xE bne lrsh1_err srl %o0,11,%o0 sethi %hi(0x00090000),%o1 !E0000 xor 70000 or %o0,%o1,%o0 .end .inline _op_llsh8,4 srl %o0,8,%o2 ! (arg0>>8)==0xE00? cmp %o2,0xE00 bne llsh8_err sll %o0,8,%o0 sethi %hi(0xE0E0000),%o1 !E0000 xor E000000 xor %o0,%o1,%o0 .end .inline _op_llsh1,4 srl %o0,15,%o2 ! (arg0>>15)==0x1C cmp %o2,0x1C bne llsh1_err sll %o0,1,%o0 sethi %hi(0x00120000),%o1 !E0000 xor 1C0000 xor %o0,%o1,%o0 .end /* *************************************************************** GREATERP OPCODE VERSIONS *************************************************************** */ .inline _op_greaterp,8 srl %o1,17,%o2 ! \ cmp %o2,7 ! > smallp(arg1) ? bne greaterp_err ! / sll %o0,15,%o2 ! preserve arg0 srl %o0,17,%o0 ! return NIL cmp %o2,7 ! > smallp(arg0) ? bne greaterp_err ! / cmp %o2,%o1 ! arg0 - arg1 ?? bg,a 9f ! if greater, return T or %o0,76,%o0 9: .end /* *************************************************************** POINTER OPCODE VERSIONS *************************************************************** */ .inline _addbase,8 srl %o1,17,%o2 ! \ cmp %o2,7 ! > smallp(arg1) ? bne addbase_err ! / sll %o1,15,%o1 sra %o1,15,%o1 add %o1,%o0,%o0 sethi %hi(0xFFFFFF),%o1 !is this necessary ?? and %o0,%o1,%o0 .end .inline _loloc,4 sll %o0,16,%o0 srl %o0,16,%o0 sethi %hi(0xE0000),%o1 or %o0,%o1,%o0 .end .inline _hiloc,4 srl %o0,16,%o0 sethi %hi(0xE0000),%o1 or %o0,%o1,%o0 .end /* this really doesn't need to check */ .inline _vag2,8 sll %o0,16,%o0 sll %o1,16,%o1 srl %o1,16,%o1 or %o0,%o1,%o0 .end /* *************************************************************** TYPE OPCODE VERSIONS *************************************************************** */ /* TYPE INLINE OPCODES */ .inline _listp,4 movl a7@+,d0 movl d0,d1 lsrl #8,d1 andl #0xFFFE,d1 movl _MDStypetbl,a0 movw a0@(0,d1:l:1),d1 andw #0x7FF,d1 cmpw #5,d1 jeq _xwzq5 clrl d0 _xwzq5: .end .inline _fast_op_listp,0 movl d7,d1 lsrl #8,d1 andl #0xFFFE,d1 movl _MDStypetbl,a0 movw a0@(0,d1:l:1),d1 andw #0x7FF,d1 cmpw #5,d1 jeq _xwzq6 clrl d7 _xwzq6: .end .inline _ntypex,4 movl a7@+,d1 lsrl #8,d1 andl #0xFFFE,d1 movl _MDStypetbl,a0 movl #0x000E0000,d0 movw a0@(0,d1:l:1),d0 andw #0x7FF,d0 .end .inline _fast_op_ntypex,0 lsrl #8,d7 andl #0xFFFE,d7 movl _MDStypetbl,a0 movw a0@(0,d7:l:1),d7 andw #0x7FF,d0 orl #0x000E0000,d7 .end .inline _typep,8 movl a7@+,d1 movl a7@+,d2 movl d1,d0 lsrl #8,d1 andl #0xFFFE,d1 movl _MDStypetbl,a0 movw a0@(0,d1:l:1),d1 andw #0x7FF,d1 cmpl d2,d1 beq 115$ moveq #0,d0 115$: .end .inline _fast_op_typep,0 movl d7,d0 lsrl #8,d0 andl #0xFFFE,d0 movl _MDStypetbl,a0 movw a0@(0,d0:l:1),d0 andw #0x7FF,d0 moveq #0,d1 movb a5@(1),d1 cmpw d1,d0 beq 115$ moveq #0,d7 115$: .end /* TYPE INLINE FUNCTIONS */ .inline _GetTypeNumber,4 movl a7@+,d1 asrl #8,d1 andl #0xFFFE,d1 movl _MDStypetbl,a0 moveq #00,d0 movw a0@(0,d1:l:1),d0 andw #0x7FF,d0 .end .inline _GetTypeEntry,4 movl a7@+,d1 asrl #8,d1 andl #0xFFFE,d1 movl _MDStypetbl,a0 movw a0@(0,d1:l:1),d0 .end |.inline _min,8 | cmp %o0,%o1 | ble,a $10 | mov %o1,%o0 |$10 |.end |.inline _max,8 | cmp %o0,%o1 | bge,a $10 | mov %o1,%o0 |$10 |.end