.file "names.c" // PGC Rel 2.0a -opt 2 .text .globl _checkNull .align 8 _checkNull: .a1 = 80 .f1 = 32 addu -(.a1+.f1), sp, sp st.l fp,(.f1-16)(sp) addu (.f1-16), sp, fp st.l r1, 4(fp) // lineno: 0 // lineno: 103 btne 0x0000, r16, .B517 orh h%.S00518, r0, r31 call _printf or l%.S00518, r31, r16 orh h%___iobuf+28, r0, r31 call _fflush or l%___iobuf+28, r31, r16 call _exit adds 666, r0, r16 // lineno: 0 .B517: //.B0000 // lineno: 112 adds .a1+16, fp, r31 ld.l 4(fp), r1 ld.l 0(fp), fp bri r1 mov r31, sp .globl _initNames .align 8 _initNames: // lineno: 0 adds -1, r0, r16 // lineno: 120 orh ha%_init, r0, r31 ld.l l%_init(r31), r29 btne 0x0000, r29, .B524 adds 511, r0, r17 orh h%.BSS+-4, r0, r31 or l%.BSS+-4, r31, r18 bla r16, r17,.B654 pfmul.dd f0, f0, f0 // lineno: 122 .B654: //.M0000 mov r18, r29 .DB.B654654: addu 4, r18, r18 bla r16, r17, .B654 st.l r0, 4(r29) // lineno: 123 .B528: //.B0003 adds 1, r0, r29 .DB.B528528: orh ha%_init, r0, r31 st.l r29, l%_init(r31) // lineno: 0 .B524: //.B0001 // lineno: 126 bri r1 nop .align 8 _addName: .a3 = 80 .f3 = 48 addu -(.a3+.f3), sp, sp st.l fp,(.f3-16)(sp) addu (.f3-16), sp, fp st.l r1, 4(fp) st.l r4, -16(fp) st.l r5, -12(fp) st.l r6, -8(fp) st.l r7, -4(fp) st.l r17, 52(fp) mov r16, r4 mov r18, r5 // lineno: 0 // lineno: 132 orh h%.BSS, r0, r31 or l%.BSS, r31, r28 and 0x01ff, r16, r29 shl 2, r29, r30 ld.l r28(r30), r7 mov r7, r6 btne 0x0000, r7, .B537 call _malloc adds 16, r0, r16 orh h%.S00540, r0, r31 or l%.S00540, r31, r17 call _checkNull mov r16, r7 and 0x01ff, r4, r28 shl 2, r28, r29 orh h%.BSS, r0, r31 or l%.BSS, r31, r30 adds r29, r30, r31 st.l r7, 0(r31) ld.l 52(fp), r18 st.l r4, 4(r7) st.l r18, 12(r7) st.l r5, 8(r7) br .B542 st.l r0, 0(r7) // lineno: 150 .B537: //.B0004 ld.l r0(r6), r28 .DB.B537537: bte 0x0000, r28, .B545 mov r6, r17 // lineno: 152 .B667: //.M0001 ld.l r0(r17), r17 .DB.B667667: ld.l r0(r17), r28 xor 0x0000, r28, r0 bnc.t .DB.B667667 ld.l r0(r17), r17 // lineno: 0 mov r17, r6 // lineno: 153 .B545: //.B0007 adds 16, r0, r16 .DB.B545545: call _malloc nop orh h%.S00547, r0, r31 or l%.S00547, r31, r17 st.l r16, 0(r6) call _checkNull mov r16, r6 ld.l 52(fp), r28 st.l r4, 4(r6) st.l r28, 12(r6) st.l r5, 8(r6) st.l r0, 0(r6) // lineno: 162 .B542: //.B0005 mov r4, r16 .DB.B542542: // lineno: 0 // lineno: 163 ld.l -16(fp), r4 ld.l -12(fp), r5 ld.l -8(fp), r6 ld.l -4(fp), r7 adds .a3+16, fp, r31 ld.l 4(fp), r1 ld.l 0(fp), fp bri r1 mov r31, sp .globl _newName .align 8 _newName: .a4 = 80 .f4 = 48 addu -(.a4+.f4), sp, sp st.l fp,(.f4-16)(sp) addu (.f4-16), sp, fp st.l r1, 4(fp) st.l r4, -16(fp) st.l r16, 48(fp) st.l r17, 52(fp) // lineno: 0 orh h%_allocatedNames, r0, r31 or l%_allocatedNames, r31, r4 // lineno: 169 btne 0x0000, r16, .B552 br .B669 mov r0, r16 // lineno: 172 .B552: //.B0008 ld.l r0(r4), r16 .DB.B552552: ld.l 48(fp), r17 ld.l 52(fp), r18 adds 1, r16, r28 st.l r28, 0(r4) call _addName st.l r16, -4(fp) ld.l -4(fp), r16 // lineno: 0 .B669: //.R0001 // lineno: 178 ld.l -16(fp), r4 adds .a4+16, fp, r31 ld.l 4(fp), r1 ld.l 0(fp), fp bri r1 mov r31, sp .globl _deleteName .align 8 _deleteName: .a5 = 80 .f5 = 48 addu -(.a5+.f5), sp, sp st.l fp,(.f5-16)(sp) addu (.f5-16), sp, fp st.l r1, 4(fp) st.l r4, -24(fp) st.l r5, -20(fp) st.l r6, -16(fp) st.l r7, -12(fp) mov r16, r4 mov r17, r5 // lineno: 0 // lineno: 183 orh h%.BSS, r0, r31 or l%.BSS, r31, r28 and 0x01ff, r16, r29 shl 2, r29, r30 ld.l r28(r30), r6 mov r0, r7 ld.l 4(r6), r17 bte r16, r17, .B563 mov r0, r7 // lineno: 188 .B687: //.M0002 mov r6, r28 .DB.B687687: ld.l r0(r6), r6 mov r28, r7 btne 0x0000, r6, .B565 call _type_to_string mov r5, r16 mov r16, r28 orh h%.S00566, r0, r31 or l%.S00566, r31, r16 mov r4, r17 call _printf mov r28, r18 call _exit adds 666, r0, r16 // lineno: 196 .B565: //.B0012 ld.l 4(r6), r28 .DB.B565565: xor r4, r28, r0 bnc.t .DB.B687687 mov r6, r28 // lineno: 0 // lineno: 198 .B563: //.B0011 adds -1, r0, r28 .DB.B563563: bte r5, r28, .B571 ld.l 8(r6), r29 bte r5, r29, .B573 call _type_to_string mov r29, r16 mov r16, r28 mov r5, r16 call _type_to_string st.l r28, -4(fp) mov r16, r28 orh h%.S00574, r0, r31 or l%.S00574, r31, r16 ld.l -4(fp), r29 mov r4, r17 mov r28, r18 call _printf mov r29, r19 call _exit adds 666, r0, r16 // lineno: 0 .B573: //.B0014 // lineno: 207 .B571: //.B0013 btne 0x0000, r7, .B577 and 0x01ff, r4, r28 shl 2, r28, r29 ld.l r0(r6), r30 orh h%.BSS, r0, r31 or l%.BSS, r31, r17 adds r29, r17, r31 st.l r30, 0(r31) mov r6, r16 orh h%.B579, r0, r1 br _free or l%.B579, r1, r1 // lineno: 212 .B577: //.B0015 ld.l r0(r6), r28 .DB.B577577: mov r6, r16 call _free st.l r28, 0(r7) // lineno: 0 .B579: //.B0016 // lineno: 215 ld.l -24(fp), r4 ld.l -20(fp), r5 ld.l -16(fp), r6 ld.l -12(fp), r7 adds .a5+16, fp, r31 ld.l 4(fp), r1 ld.l 0(fp), fp bri r1 mov r31, sp .globl _nameToAddress .align 8 _nameToAddress: .a6 = 80 .f6 = 48 addu -(.a6+.f6), sp, sp st.l fp,(.f6-16)(sp) addu (.f6-16), sp, fp st.l r1, 4(fp) st.l r4, -24(fp) st.l r5, -20(fp) st.l r6, -16(fp) mov r17, r4 mov r16, r5 // lineno: 0 // lineno: 222 btne 0x0000, r16, .B585 br .B690 mov r0, r16 // lineno: 225 .B585: //.B0017 orh h%.BSS, r0, r31 .DB.B585585: or l%.BSS, r31, r28 and 0x01ff, r16, r29 shl 2, r29, r30 ld.l r28(r30), r6 bte 0x0000, r6, .B587 mov r5, r17 mov r6, r18 // lineno: 226 .B697: //.M0003 ld.l 4(r18), r28 .DB.B697697: btne r17, r28, .B589 // lineno: 0 mov r18, r6 ld.l 8(r18), r28 btne r4, r28, .B591 br .B690 ld.l 12(r18), r16 // lineno: 230 .B591: //.B0021 adds -1, r0, r28 .DB.B591591: btne r4, r28, .B594 br .B690 ld.l 12(r6), r16 // lineno: 237 .B594: //.B0023 ld.l 8(r6), r16 .DB.B594594: ld.l 12(r6), r28 call _type_to_string st.l r28, -4(fp) mov r16, r28 mov r4, r16 call _type_to_string st.l r28, -8(fp) mov r16, r28 orh h%.S00597, r0, r31 or l%.S00597, r31, r16 ld.l -8(fp), r29 mov r5, r17 mov r28, r18 mov r29, r19 ld.l -4(fp), r30 call _printf mov r30, r20 orh h%.S00600, r0, r31 or l%.S00600, r31, r16 orh ha%_allocatedNames, r0, r31 call _printf ld.l l%_allocatedNames(r31), r17 br .B690 mov r0, r16 // lineno: 243 .B589: //.B0020 ld.l r0(r18), r18 .DB.B589589: xor 0x0000, r18, r0 bnc.t .DB.B697697 ld.l 4(r18), r28 // lineno: 0 mov r18, r6 // lineno: 244 .B587: //.B0019 mov r0, r16 .DB.B587587: // lineno: 0 .B690: //.R0002 // lineno: 245 ld.l -24(fp), r4 ld.l -20(fp), r5 ld.l -16(fp), r6 adds .a6+16, fp, r31 ld.l 4(fp), r1 ld.l 0(fp), fp bri r1 mov r31, sp .globl _addressToName .align 8 _addressToName: .a7 = 80 .f7 = 48 addu -(.a7+.f7), sp, sp st.l fp,(.f7-16)(sp) addu (.f7-16), sp, fp st.l r1, 4(fp) st.l r4, -24(fp) st.l r5, -20(fp) st.l r6, -16(fp) st.l r7, -12(fp) st.l r8, -8(fp) st.l r16, 48(fp) mov r17, r4 // lineno: 0 // lineno: 252 mov r0, r7 mov r0, r7 ld.l 48(fp), r6 orh h%.BSS, r0, r31 or l%.BSS, r31, r8 // lineno: 253 .B714: //.M0005 ld.l r0(r8), r5 .DB.B714714: bte 0x0000, r5, .B611 // lineno: 256 .B707: //.M0004 ld.l 12(r5), r28 .DB.B707707: btne r6, r28, .B613 adds -1, r0, r29 btne r4, r29, .B615 // lineno: 0 // lineno: 0 br .B704 ld.l 4(r5), r16 // lineno: 259 .B615: //.B0030 ld.l 8(r5), r28 .DB.B615615: btne r4, r28, .B617 // lineno: 0 // lineno: 0 br .B704 ld.l 4(r5), r16 // lineno: 263 .B617: //.B0032 orh h%.S00619, r0, r31 .DB.B617617: or l%.S00619, r31, r16 ld.l 4(r5), r18 call _printf mov r6, r17 // lineno: 265 .B613: //.B0029 ld.l r0(r5), r5 .DB.B613613: xor 0x0000, r5, r0 bnc.t .DB.B707707 ld.l 12(r5), r28 // lineno: 0 // lineno: 266 .B611: //.B0028 adds 1, r7, r7 .DB.B611611: addu 4, r8, r8 adds -512, r7, r0 bc.t .DB.B714714 ld.l r0(r8), r5 // lineno: 0 mov r0, r16 // lineno: 0 .B704: //.R0003 // lineno: 269 ld.l -24(fp), r4 ld.l -20(fp), r5 ld.l -16(fp), r6 ld.l -12(fp), r7 ld.l -8(fp), r8 adds .a7+16, fp, r31 ld.l 4(fp), r1 ld.l 0(fp), fp bri r1 mov r31, sp .globl _check_name .align 8 _check_name: // lineno: 0 // lineno: 274 adds 0, r16, r0 bc .B623 orh ha%_allocatedNames, r0, r31 ld.l l%_allocatedNames(r31), r29 subs r29, r16, r0 bc .B623 br .B624 mov r0, r17 // lineno: 0 .B623: //.B0034 adds 1, r0, r17 .DB.B623623: // lineno: 275 .B624: //.B0035 mov r17, r16 .DB.B624624: // lineno: 0 // lineno: 0 bri r1 nop .data .align 1 .S00518: // // "NULL pointer in %s\n" .byte 0x4e,0x55,0x4c,0x4c,0x20,0x70,0x6f,0x69,0x6e,0x74,0x65 .byte 0x72,0x20,0x69,0x6e,0x20,0x25,0x73,0x0a,0x00 .S00540: // // "createName" .byte 0x63,0x72,0x65,0x61,0x74,0x65,0x4e,0x61,0x6d,0x65,0x00 .S00547: // // "createName" .byte 0x63,0x72,0x65,0x61,0x74,0x65,0x4e,0x61,0x6d,0x65,0x00 .S00566: // // "Name 0x%x (%s) not found\n" .byte 0x4e,0x61,0x6d,0x65,0x20,0x30,0x78,0x25,0x78,0x20,0x28 .byte 0x25,0x73,0x29,0x20,0x6e,0x6f,0x74,0x20,0x66,0x6f,0x75 .byte 0x6e,0x64,0x0a,0x00 .S00574: // // "deleteName: name 0x%x wrong type, expected %s found %s\n" .byte 0x64,0x65,0x6c,0x65,0x74,0x65,0x4e,0x61,0x6d,0x65,0x3a .byte 0x20,0x6e,0x61,0x6d,0x65,0x20,0x30,0x78,0x25,0x78,0x20 .byte 0x77,0x72,0x6f,0x6e,0x67,0x20,0x74,0x79,0x70,0x65,0x2c .byte 0x20,0x65,0x78,0x70,0x65,0x63,0x74,0x65,0x64,0x20,0x25 .byte 0x73,0x20,0x66,0x6f,0x75,0x6e,0x64,0x20,0x25,0x73,0x0a .byte 0x00 .S00597: // // "nameToAddress: name 0x%x wrong type, expected %s found %s address 0x%x\n" .byte 0x6e,0x61,0x6d,0x65,0x54,0x6f,0x41,0x64,0x64,0x72,0x65 .byte 0x73,0x73,0x3a,0x20,0x6e,0x61,0x6d,0x65,0x20,0x30,0x78 .byte 0x25,0x78,0x20,0x77,0x72,0x6f,0x6e,0x67,0x20,0x74,0x79 .byte 0x70,0x65,0x2c,0x20,0x65,0x78,0x70,0x65,0x63,0x74,0x65 .byte 0x64,0x20,0x25,0x73,0x20,0x66,0x6f,0x75,0x6e,0x64,0x20 .byte 0x25,0x73,0x20,0x61,0x64,0x64,0x72,0x65,0x73,0x73,0x20 .byte 0x30,0x78,0x25,0x78,0x0a,0x00 .S00600: // // "allocatedNames = %d\n" .byte 0x61,0x6c,0x6c,0x6f,0x63,0x61,0x74,0x65,0x64,0x4e,0x61 .byte 0x6d,0x65,0x73,0x20,0x3d,0x20,0x25,0x64,0x0a,0x00 .S00619: // // "found item 0x%x name 0x%x, wrong type\n" .byte 0x66,0x6f,0x75,0x6e,0x64,0x20,0x69,0x74,0x65,0x6d,0x20 .byte 0x30,0x78,0x25,0x78,0x20,0x6e,0x61,0x6d,0x65,0x20,0x30 .byte 0x78,0x25,0x78,0x2c,0x20,0x77,0x72,0x6f,0x6e,0x67,0x20 .byte 0x74,0x79,0x70,0x65,0x0a,0x00 .data .align 4 _init: //init .long 0 .globl _allocatedNames _allocatedNames: //allocatedNames .long 1 .lcomm .BSS,2048 //yellowPages +0 .extern _free .extern _type_to_string .extern _malloc .extern _exit .extern _fflush .extern _printf