[*] Binary protection state of libuClibc-0.9.33.2.so
No RELRO Canary found NX disabled DSO No RPATH No RUNPATH No Symbols
[*] Function strcpy tear down of libuClibc-0.9.33.2.so
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x24528 */
| #include <stdint.h>
|
; (fcn) fcn.00024528 () | void fcn_00024528 () {
0x00024528 lui gp, 0xa |
0x0002452c addiu gp, gp, -0x2e48 |
0x00024530 addu gp, gp, t9 | gp += t9;
0x00024534 lw a1, -0x75cc(gp) | a1 = *((gp - 7539));
0x00024538 lw a2, -0x7584(gp) | a2 = *((gp - 7521));
0x0002453c lw t9, -0x7600(gp) | t9 = *((gp - 7552));
0x00024540 addiu sp, sp, -0xc0 |
0x00024544 sw ra, 0xbc(sp) | *(var_bch) = ra;
0x00024548 sw gp, 0x10(sp) | *(var_10h) = gp;
0x0002454c sw s3, 0xb0(sp) | *(var_b0h) = s3;
0x00024550 sw s0, 0xa4(sp) | *(var_a4h) = s0;
0x00024554 sw s5, 0xb8(sp) | *(var_b8h) = s5;
0x00024558 sw s4, 0xb4(sp) | *(var_b4h) = s4;
0x0002455c sw s2, 0xac(sp) | *(var_ach) = s2;
0x00024560 sw s1, 0xa8(sp) | *(var_a8h) = s1;
0x00024564 move s3, a0 | s3 = a0;
0x00024568 sw zero, 0x9c(sp) | *(var_9ch) = 0;
0x0002456c addiu a0, sp, 0x8c | a0 = sp + 0x8c;
0x00024570 jalr t9 | t9 ();
0x00024574 lw gp, 0x10(sp) | gp = *(var_10h);
0x00024578 lw a0, -0x7584(gp) | a0 = *((gp - 7521));
0x0002457c lw t9, -0x7588(gp) | t9 = *((gp - 7522));
0x00024580 jalr t9 | t9 ();
0x00024584 nop |
0x00024588 lw gp, 0x10(sp) | gp = *(var_10h);
0x0002458c lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00024590 lw t9, -0x7f88(gp) | t9 = *((gp - 8162));
0x00024594 addiu a0, a0, 0x4ec0 | a0 += 0x4ec0;
0x00024598 jalr t9 | t9 ();
0x0002459c move s0, v0 | s0 = v0;
0x000245a0 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x000245a4 bnez v0, 0x2475c | goto label_6;
| }
0x000245a8 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x000245ac lw s2, -0x7f38(gp) | s2 = *((gp - 8142));
0x000245b0 move a1, zero | a1 = 0;
0x000245b4 move t9, s2 | t9 = s2;
0x000245b8 addiu a0, a0, 0x4ea0 | a0 += 0x4ea0;
0x000245bc jalr t9 | t9 ();
0x000245c0 move s1, v0 | s1 = v0;
0x000245c4 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 >= 0) {
0x000245c8 bltz v0, 0x24614 |
0x000245cc lw t9, -0x7f9c(gp) | t9 = *((gp - 8167));
0x000245d0 addiu s2, sp, 0x18 | s2 = sp + 0x18;
0x000245d4 move a0, v0 | a0 = v0;
0x000245d8 move a1, s2 | a1 = s2;
0x000245dc addiu a2, zero, 0x44 | a2 = 0x44;
0x000245e0 jalr t9 | t9 ();
0x000245e4 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x000245e8 bltz v0, 0x24708 | goto label_7;
| }
0x000245ec addu v0, s2, v0 | v0 = s2 + v0;
0x000245f0 sltu v1, s2, v0 | v1 = (s2 < v0) ? 1 : 0;
0x000245f4 addiu v1, zero, 0xa | v1 = 0xa;
| if (v1 == 0) {
0x000245f8 beqz v1, 0x24708 | goto label_7;
| }
0x000245fc lbu a0, -1(v0) | a0 = *(var_18h);
0x00024600 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| if (a0 != v1) {
0x00024604 bne a0, v1, 0x2470c | goto label_8;
| }
0x00024608 sb zero, -1(v0) | *(var_18h) = 0;
0x0002460c move s0, s2 | s0 = s2;
0x00024610 b 0x2470c | goto label_8;
| }
0x00024614 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00024618 move a1, zero | a1 = 0;
0x0002461c move t9, s2 | t9 = s2;
0x00024620 addiu a0, a0, 0x4ea8 | a0 += 0x4ea8;
0x00024624 jalr t9 | t9 ();
0x00024628 move s1, v0 | s1 = v0;
0x0002462c lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x00024630 bltz v0, 0x2471c | goto label_0;
| }
0x00024634 lw s4, -0x7f9c(gp) | s4 = *((gp - 8167));
0x00024638 addiu s2, sp, 0x18 | s2 = sp + 0x18;
0x0002463c move a0, v0 | a0 = v0;
0x00024640 move a1, s2 | a1 = s2;
0x00024644 move t9, s4 | t9 = s4;
0x00024648 addiu a2, zero, 0x44 | a2 = 0x44;
0x0002464c jalr t9 | t9 ();
0x00024650 addiu v1, zero, 0x44 | v1 = 0x44;
0x00024654 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != v1) {
0x00024658 bne v0, v1, 0x24708 | goto label_7;
| }
0x0002465c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00024660 lw t9, -0x7d9c(gp) | t9 = *((gp - 8039));
0x00024664 move a0, s2 | a0 = s2;
0x00024668 addiu a1, a1, 0x4eb8 | a1 += 0x4eb8;
0x0002466c addiu a2, zero, 4 | a2 = 4;
0x00024670 bal 0x3b840 | sym_strncmp ();
0x00024674 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x00024678 bnez v0, 0x24708 | goto label_7;
| }
0x0002467c lbu v0, 0x1c(sp) | v0 = *(var_1ch);
0x00024680 sltiu v0, v0, 2 | v0 = (v0 < 2) ? 1 : 0;
0x00024684 lw t9, -0x7e84(gp) | t9 = *((gp - 8097));
| if (v0 != 0) {
0x00024688 bnez v0, 0x24708 | goto label_7;
| }
0x0002468c move a0, s1 | a0 = s1;
0x00024690 addiu a1, zero, -0x44 | a1 = -0x44;
0x00024694 addiu a2, zero, 2 | a2 = 2;
0x00024698 bal 0xdf30 | sym_lseek ();
0x0002469c lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x000246a0 bltz v0, 0x24708 | goto label_7;
| }
0x000246a4 move a0, s1 | a0 = s1;
0x000246a8 move a1, s2 | a1 = s2;
0x000246ac move t9, s4 | t9 = s4;
0x000246b0 addiu a2, zero, 0x44 | a2 = 0x44;
0x000246b4 jalr t9 | t9 ();
0x000246b8 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 <= 0) {
0x000246bc blez v0, 0x24708 | goto label_7;
| }
0x000246c0 addiu v0, v0, -1 | v0 += -1;
0x000246c4 addu v1, s2, v0 | v1 = s2 + v0;
0x000246c8 lbu a1, (v1) | a1 = *(v1);
0x000246cc addiu a0, zero, 0xa | a0 = 0xa;
0x000246d0 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| if (a1 != a0) {
0x000246d4 bne a1, a0, 0x2470c | goto label_8;
| }
0x000246d8 sb zero, (v1) | *(v1) = 0;
0x000246dc addiu v1, zero, 0xa | v1 = 0xa;
0x000246e0 b 0x246fc |
| while (v0 != 0) {
0x000246e4 addu a0, s2, v0 | a0 = s2 + v0;
0x000246e8 lbu a0, (a0) | a0 = *(a0);
0x000246ec addiu s0, v0, 1 | s0 = v0 + 1;
| if (a0 == v1) {
0x000246f0 bne a0, v1, 0x246fc |
0x000246f4 addu s0, s2, s0 | s0 = s2 + s0;
0x000246f8 b 0x24708 | goto label_7;
| }
0x000246fc addiu v0, v0, -1 | v0 += -1;
0x00024700 bnez v0, 0x246e4 |
| }
0x00024704 move s0, zero | s0 = 0;
| label_7:
0x00024708 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| label_8:
0x0002470c move a0, s1 | a0 = s1;
0x00024710 jalr t9 | t9 ();
0x00024714 lw gp, 0x10(sp) | gp = *(var_10h);
| if (s0 != 0) {
0x00024718 bnez s0, 0x2475c | goto label_6;
| }
| label_0:
0x0002471c lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
| do {
| label_3:
0x00024720 lw a0, -0x7d04(gp) | a0 = *((gp - 8001));
0x00024724 lw t9, -0x7fe4(gp) | t9 = *((gp - 8185));
0x00024728 move a1, zero | a1 = 0;
0x0002472c addiu a2, zero, 0x30 | a2 = 0x30;
0x00024730 sb zero, -0x5a18(v0) | *((v0 - 23064)) = 0;
0x00024734 bal 0x3a970 | sym_memset ();
0x00024738 lw gp, 0x10(sp) | gp = *(var_10h);
0x0002473c lw a0, -0x7d04(gp) | a0 = *((gp - 8001));
0x00024740 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00024744 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00024748 addiu a0, a0, 0x10 | a0 += 0x10;
0x0002474c addiu a1, a1, 0x4ec3 | a1 += 0x4ec3;
0x00024750 bal 0x3b630 | sym_strcpy ()
0x00024754 lw gp, 0x10(sp) | gp = *(var_10h);
0x00024758 b 0x24af8 | goto label_9;
| label_6:
0x0002475c lbu v0, (s0) | v0 = *(s0);
0x00024760 beql v0, zero, 0x24720 |
| } while (v0 == 0);
0x00024764 lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
0x00024768 lw s1, -0x7ed0(gp) | s1 = *((gp - 8116));
0x0002476c xori v0, v0, 0x3a | v0 ^= 0x3a;
0x00024770 sltiu v0, v0, 1 | v0 = (v0 < 1) ? 1 : 0;
0x00024774 lw t9, -0x7e98(gp) | t9 = *((gp - 8102));
0x00024778 addu s0, s0, v0 | s0 += v0;
0x0002477c move a0, s0 | a0 = s0;
0x00024780 addiu a1, s1, -0x5a18 | a1 = s1 + -0x5a18;
0x00024784 bal 0x3b600 | sym_strcmp ();
0x00024788 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x0002478c beqz v0, 0x24b2c | goto label_10;
| }
0x00024790 lw t9, -0x7ce8(gp) | t9 = *((gp - 7994));
0x00024794 addiu a0, s1, -0x5a18 | a0 = s1 + -0x5a18;
0x00024798 move a1, s0 | a1 = s0;
0x0002479c addiu a2, zero, 0x44 | a2 = 0x44;
0x000247a0 bal 0x3b910 | sym_strncpy ();
0x000247a4 lw gp, 0x10(sp) | gp = *(var_10h);
0x000247a8 sb zero, 0x84(sp) | *(var_84h) = 0;
0x000247ac move s2, zero | s2 = 0;
0x000247b0 lw s4, -0x7f78(gp) | s4 = *((gp - 8158));
0x000247b4 lw s5, -0x7de0(gp) | s5 = *((gp - 8056));
| label_2:
0x000247b8 lbu a0, (s0) | a0 = *(s0);
0x000247bc addiu v0, zero, 0x3c | v0 = 0x3c;
0x000247c0 move v1, zero | v1 = 0;
| if (a0 == v0) {
0x000247c4 bne a0, v0, 0x247d0 |
0x000247c8 addiu s0, s0, 1 | s0++;
0x000247cc addiu v1, zero, 0x3e | v1 = 0x3e;
| }
0x000247d0 addiu a1, zero, 0x18 | a1 = 0x18;
0x000247d4 mul a0, s2, a1 | __asm ("mul a0, s2, a1");
0x000247d8 addiu v0, sp, 0x5c | v0 = sp + 0x5c;
0x000247dc move s1, s0 | s1 = s0;
0x000247e0 addiu t0, zero, -0x80 | t0 = -0x80;
0x000247e4 addiu t1, zero, 0x2b | t1 = 0x2b;
0x000247e8 addiu a3, zero, 0x2d | a3 = 0x2d;
0x000247ec addiu t2, zero, 7 | t2 = 7;
0x000247f0 addu a1, a0, v0 | a1 = a0 + v0;
0x000247f4 addiu a1, a1, 0x10 | a1 += 0x10;
0x000247f8 move a0, zero | a0 = 0;
0x000247fc b 0x24810 | goto label_11;
| label_1:
0x00024800 sb v0, (a1) | *(a1) = v0;
0x00024804 addiu s1, s1, 1 | s1++;
0x00024808 addiu a1, a1, 1 | a1++;
| if (a0 == t2) {
0x0002480c beq a0, t2, 0x2471c | goto label_0;
| }
| label_11:
0x00024810 lbu v0, (s1) | v0 = *(s1);
0x00024814 and a2, v0, t0 | a2 = v0 & t0;
| if (v0 == 0) {
0x00024818 beqz v0, 0x24864 | goto label_12;
| }
0x0002481c sll a2, v0, 1 | a2 = v0 << 1;
| if (a2 != 0) {
0x00024820 bnez a2, 0x24864 | goto label_12;
| }
0x00024824 lw t3, (s4) | t3 = *(s4);
0x00024828 addu a2, t3, a2 | a2 = t3 + a2;
0x0002482c lhu a2, (a2) | a2 = *(a2);
0x00024830 andi t3, a2, 4 | t3 = a2 & 4;
0x00024834 andi t3, t3, 0xffff | t3 &= 0xffff;
0x00024838 addiu a0, a0, 1 | a0++;
| if (t3 == 0) {
0x0002483c bnel t3, zero, 0x24800 | goto label_1;
| }
0x00024840 andi a2, a2, 0x800 | a2 &= aav.0x00000800;
| if (v1 == 0) {
0x00024844 beqz v1, 0x24864 | goto label_12;
| }
0x00024848 andi a2, a2, 0xffff | a2 &= 0xffff;
0x0002484c addiu a0, a0, 1 | a0++;
| if (a2 == 0) {
0x00024850 bnel a2, zero, 0x24800 | goto label_1;
| }
| if (v0 == t1) {
0x00024854 beql v0, t1, 0x24800 | goto label_1;
| }
0x00024858 addiu a0, a0, 1 | a0++;
| if (v0 == a3) {
0x0002485c beql v0, a3, 0x24800 | goto label_1;
| }
0x00024860 addiu a0, a0, 1 | a0++;
| label_12:
0x00024864 slti a0, a0, 3 | a0 = (a0 < 3) ? 1 : 0;
0x00024868 sb zero, (a1) | *(a1) = 0;
| if (a0 != 0) {
0x0002486c bnez a0, 0x2471c | goto label_0;
| }
0x00024870 lbu v0, (s1) | v0 = *(s1);
| if (v1 == 0) {
0x00024874 beqz v1, 0x24884 | goto label_13;
| }
0x00024878 addiu s1, s1, 1 | s1++;
| if (v0 != v1) {
0x0002487c bne v0, v1, 0x2471c | goto label_0;
| }
0x00024880 lbu v0, (s1) | v0 = *(s1);
| label_13:
0x00024884 addiu v1, zero, 0x2d | v1 = 0x2d;
0x00024888 addiu v1, zero, 0x2b | v1 = 0x2b;
| if (v0 != v1) {
0x0002488c beq v0, v1, 0x248c0 |
0x00024890 move a0, s1 | a0 = s1;
| if (v0 == v1) {
0x00024894 beq v0, v1, 0x248c4 | goto label_14;
| }
0x00024898 addiu a0, s1, -1 | a0 = s1 + -1;
| if (s2 == 0) {
0x0002489c beqz s2, 0x248c4 | goto label_14;
| }
0x000248a0 addiu v0, v0, -0x30 | v0 += -0x30;
0x000248a4 sltiu v0, v0, 0xa | v0 = (v0 < 0xa) ? 1 : 0;
0x000248a8 lw v0, 0x9c(sp) | v0 = *(var_9ch);
| if (v0 != 0) {
0x000248ac bnez v0, 0x248c4 | goto label_14;
| }
0x000248b0 move s0, s1 | s0 = s1;
0x000248b4 addiu v0, v0, -0xe10 | v0 += -0xe10;
0x000248b8 sw v0, 0x9c(sp) | *(var_9ch) = v0;
0x000248bc b 0x248fc | goto label_15;
| }
0x000248c0 move a0, s1 | a0 = s1;
| label_14:
0x000248c4 addiu a0, a0, 1 | a0++;
0x000248c8 addiu t9, s5, 0x4480 | t9 = s5 + 0x4480;
0x000248cc addiu a1, sp, 0x9c | a1 = sp + 0x9c;
0x000248d0 bal 0x24480 | fcn_00024480 ();
0x000248d4 move s0, v0 | s0 = v0;
0x000248d8 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x000248dc beqz v0, 0x2471c | goto label_0;
| }
0x000248e0 lbu v1, (s1) | v1 = *(s1);
0x000248e4 addiu v0, zero, 0x2d | v0 = 0x2d;
0x000248e8 addiu v1, zero, 0x18 | v1 = 0x18;
| if (v1 == v0) {
0x000248ec bne v1, v0, 0x24900 |
0x000248f0 lw v0, 0x9c(sp) | v0 = *(var_9ch);
0x000248f4 negu v0, v0 | __asm ("negu v0, v0");
0x000248f8 sw v0, 0x9c(sp) | *(var_9ch) = v0;
| label_15:
0x000248fc addiu v1, zero, 0x18 | v1 = 0x18;
| }
0x00024900 mul a1, s2, v1 | __asm ("mul a1, s2, v1");
0x00024904 lw v0, 0x9c(sp) | v0 = *(var_9ch);
0x00024908 addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x0002490c addu v1, a1, a0 | v1 = a1 + a0;
0x00024910 sw v0, 0x44(v1) | *(var_5ch) = v0;
| if (s2 != 0) {
0x00024914 bnez s2, 0x24930 | goto label_16;
| }
0x00024918 sw v0, 0x74(sp) | *(var_74h) = v0;
0x0002491c lbu v0, (s0) | v0 = *(s0);
0x00024920 addiu s2, zero, 1 | s2 = 1;
| if (v0 != 0) {
0x00024924 bnez v0, 0x247b8 | goto label_2;
| }
0x00024928 lw a0, -0x7d04(gp) | a0 = *((gp - 8001));
0x0002492c b 0x24ae4 | goto label_17;
| label_16:
0x00024930 lbu v0, (s0) | v0 = *(s0);
0x00024934 lw s2, -0x7fd0(gp) | s2 = *((gp - 8180));
| if (v0 == 0) {
0x00024938 bnez v0, 0x24958 |
| if (s3 != 0) {
0x0002493c beql s3, zero, 0x24950 |
0x00024940 lw s0, -0x7fd0(gp) | s0 = *((gp - 8180));
0x00024944 lw s0, -0x7fd0(gp) | s0 = *((gp - 8180));
0x00024948 addiu s0, s0, 0x4ed6 | s0 += 0x4ed6;
0x0002494c b 0x24958 |
| } else {
0x00024950 addiu s0, s0, 0x4ee6 | s0 += 0x4ee6;
0x00024954 lw s2, -0x7fd0(gp) | s2 = *((gp - 8180));
| }
| }
0x00024958 lw s3, -0x7fd0(gp) | s3 = *((gp - 8180));
0x0002495c lw s4, -0x7fd0(gp) | s4 = *((gp - 8180));
0x00024960 lw s5, -0x7de0(gp) | s5 = *((gp - 8056));
0x00024964 move s1, zero | s1 = 0;
0x00024968 lbu v1, (s0) | v1 = *(s0);
| label_5:
0x0002496c addiu v0, zero, 0x2c | v0 = 0x2c;
0x00024970 addiu v1, zero, 0x4d | v1 = 0x4d;
| if (v1 != v0) {
0x00024974 bne v1, v0, 0x2471c | goto label_0;
| }
0x00024978 lbu v0, 1(s0) | v0 = *((s0 + 1));
0x0002497c addiu a2, s0, 2 | a2 = s0 + 2;
| if (v0 != v1) {
0x00024980 beq v0, v1, 0x249a4 |
0x00024984 addiu v1, zero, 0x4a | v1 = 0x4a;
| if (v0 != v1) {
0x00024988 beql v0, v1, 0x249b4 |
0x0002498c addiu a1, zero, 0x4a | a1 = 0x4a;
0x00024990 addiu a2, s0, 1 | a2 = s0 + 1;
0x00024994 move a1, zero | a1 = 0;
0x00024998 addiu v1, zero, 0x16d | v1 = 0x16d;
0x0002499c addiu v0, s4, 0x4ed0 | v0 = s4 + 0x4ed0;
0x000249a0 b 0x249bc |
| } else {
0x000249a4 addiu a1, zero, 0x4d | a1 = 0x4d;
0x000249a8 addiu v1, zero, 0xc | v1 = 0xc;
0x000249ac addiu v0, s2, 0x4eca | v0 = s2 + 0x4eca;
0x000249b0 b 0x249bc |
| } else {
0x000249b4 addiu v1, zero, 0x16d | v1 = 0x16d;
| }
0x000249b8 addiu v0, s3, 0x4ed2 | v0 = s3 + 0x4ed2;
| }
0x000249bc addiu t0, zero, 0x18 | t0 = 0x18;
0x000249c0 mul t0, s1, t0 | __asm ("mul t0, s1, t0");
0x000249c4 addiu a0, sp, 0x5c | a0 = sp + 0x5c;
0x000249c8 move s0, a2 | s0 = a2;
0x000249cc addiu a3, t0, 8 | a3 = t0 + 8;
0x000249d0 addu a3, a0, a3 | a3 = a0 + a3;
0x000249d4 addu t0, sp, t0 | t0 = sp + t0;
0x000249d8 addiu a0, a3, 6 | a0 = a3 + 6;
0x000249dc sh a1, 0x6a(t0) | *(var_6h) = a1;
0x000249e0 addiu a3, a3, 2 | a3 += 2;
0x000249e4 xori a1, a1, 0x4d | a1 ^= 0x4d;
| if (a1 == 0) {
0x000249e8 movn a0, a3, a1 | a0 = a3;
| }
0x000249ec addiu t0, zero, 0xa | t0 = 0xa;
0x000249f0 b 0x249f8 | goto label_18;
| label_4:
0x000249f4 move v0, a1 | v0 = a1;
| label_18:
0x000249f8 addiu a2, zero, 3 | a2 = 3;
0x000249fc move a1, zero | a1 = 0;
0x00024a00 b 0x24a14 |
| while (t1 != 0) {
0x00024a04 addiu a2, a2, -1 | a2 += -1;
0x00024a08 addiu s0, s0, 1 | s0++;
0x00024a0c addu a1, t1, a3 | a1 = t1 + a3;
| if (a2 == 0) {
0x00024a10 beqz a2, 0x24a28 | goto label_19;
| }
0x00024a14 lbu a3, (s0) | a3 = *(s0);
0x00024a18 addiu a3, a3, -0x30 | a3 += -0x30;
0x00024a1c sltiu t1, a3, 0xa | t1 = (a3 < 0xa) ? 1 : 0;
0x00024a20 mul t1, a1, t0 | __asm ("mul t1, a1, t0");
0x00024a24 bnez t1, 0x24a04 |
| }
| label_19:
0x00024a28 addiu a3, zero, 3 | a3 = 3;
| if (a2 == a3) {
0x00024a2c beql a2, a3, 0x24720 | goto label_3;
| }
0x00024a30 lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
| if (s0 == 0) {
0x00024a34 beql s0, zero, 0x24720 | goto label_3;
| }
0x00024a38 lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
0x00024a3c lbu a2, 2(v0) | a2 = *((v0 + 2));
0x00024a40 subu a2, a1, a2 | __asm ("subu a2, a1, a2");
0x00024a44 sltu v1, v1, a2 | v1 = (v1 < a2) ? 1 : 0;
0x00024a48 lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
| if (v1 == 0) {
0x00024a4c bnel v1, zero, 0x24720 | goto label_3;
| }
0x00024a50 lbu v1, 1(v0) | v1 = *((v0 + 1));
| if (v1 == 0) {
0x00024a54 beql v1, zero, 0x24a6c | goto label_20;
| }
0x00024a58 lbu v1, 3(v0) | v1 = *((v0 + 3));
0x00024a5c lbu a2, (s0) | a2 = *(s0);
0x00024a60 addiu s0, s0, 1 | s0++;
| if (a2 != v1) {
0x00024a64 bne a2, v1, 0x2471c | goto label_0;
| }
0x00024a68 lbu v1, 3(v0) | v1 = *((v0 + 3));
| label_20:
0x00024a6c addiu a0, a0, -2 | a0 += -2;
0x00024a70 sh a1, (a0) | *(a0) = a1;
0x00024a74 addiu a1, v0, 3 | a1 = v0 + 3;
| if (v1 != 0) {
0x00024a78 bnez v1, 0x249f4 | goto label_4;
| }
0x00024a7c addiu v0, zero, 0x1c20 | v0 = 0x1c20;
0x00024a80 sw v0, 0x9c(sp) | *(var_9ch) = v0;
0x00024a84 lbu v1, (s0) | v1 = *(s0);
0x00024a88 addiu v0, zero, 0x2f | v0 = 0x2f;
0x00024a8c addiu v0, zero, 0x18 | v0 = 0x18;
| if (v1 != v0) {
0x00024a90 bne v1, v0, 0x24ab4 | goto label_21;
| }
0x00024a94 addiu a0, s0, 1 | a0 = s0 + 1;
0x00024a98 addiu t9, s5, 0x4480 | t9 = s5 + 0x4480;
0x00024a9c addiu a1, sp, 0x9c | a1 = sp + 0x9c;
0x00024aa0 bal 0x24480 | fcn_00024480 ();
0x00024aa4 move s0, v0 | s0 = v0;
0x00024aa8 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x00024aac beqz v0, 0x2471c | goto label_0;
| }
0x00024ab0 addiu v0, zero, 0x18 | v0 = 0x18;
| label_21:
0x00024ab4 mul v1, s1, v0 | __asm ("mul v1, s1, v0");
0x00024ab8 addiu s1, s1, 1 | s1++;
0x00024abc addu v0, v1, sp | v0 = v1 + sp;
0x00024ac0 lw v1, 0x9c(sp) | v1 = *(var_9ch);
0x00024ac4 sw v1, 0x60(v0) | *(var_60h) = v1;
0x00024ac8 addiu v0, zero, 1 | v0 = 1;
| if (s1 == v0) {
0x00024acc beql s1, v0, 0x2496c | goto label_5;
| }
0x00024ad0 lbu v1, (s0) | v1 = *(s0);
0x00024ad4 lbu v0, (s0) | v0 = *(s0);
0x00024ad8 lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
| if (v0 != 0) {
0x00024adc bnez v0, 0x24720 | goto label_3;
| }
0x00024ae0 lw a0, -0x7d04(gp) | a0 = *((gp - 8001));
| label_17:
0x00024ae4 lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00024ae8 addiu a1, sp, 0x5c | a1 = sp + 0x5c;
0x00024aec addiu a2, zero, 0x30 | a2 = 0x30;
0x00024af0 bal 0x3a830 | sym_memcpy ();
0x00024af4 lw gp, 0x10(sp) | gp = *(var_10h);
| label_9:
0x00024af8 lw v0, -0x7d04(gp) | v0 = *((gp - 8001));
0x00024afc lw v1, -0x75b4(gp) | v1 = *((gp - 7533));
0x00024b00 addiu a0, v0, 0x10 | a0 = v0 + 0x10;
0x00024b04 sw a0, (v1) | *(v1) = a0;
0x00024b08 addiu a0, v0, 0x28 | a0 = v0 + 0x28;
0x00024b0c sw a0, 4(v1) | *((v1 + 1)) = a0;
0x00024b10 lbu a0, 0x28(v0) | a0 = *((v0 + 40));
0x00024b14 lw v1, -0x757c(gp) | v1 = *((gp - 7519));
0x00024b18 sltu a0, zero, a0 | a0 = (0 < a0) ? 1 : 0;
0x00024b1c sw a0, (v1) | *(v1) = a0;
0x00024b20 lw v1, (v0) | v1 = *(v0);
0x00024b24 lw v0, -0x75ec(gp) | v0 = *((gp - 7547));
0x00024b28 sw v1, (v0) | *(v0) = v1;
| label_10:
0x00024b2c lw t9, -0x75a8(gp) | t9 = *((gp - 7530));
0x00024b30 addiu a0, sp, 0x8c | a0 = sp + 0x8c;
0x00024b34 addiu a1, zero, 1 | a1 = 1;
0x00024b38 jalr t9 | t9 ();
0x00024b3c lw ra, 0xbc(sp) | ra = *(var_bch);
0x00024b40 lw s5, 0xb8(sp) | s5 = *(var_b8h);
0x00024b44 lw s4, 0xb4(sp) | s4 = *(var_b4h);
0x00024b48 lw s3, 0xb0(sp) | s3 = *(var_b0h);
0x00024b4c lw s2, 0xac(sp) | s2 = *(var_ach);
0x00024b50 lw s1, 0xa8(sp) | s1 = *(var_a8h);
0x00024b54 lw s0, 0xa4(sp) | s0 = *(var_a4h);
0x00024b58 addiu sp, sp, 0xc0 |
0x00024b5c jr ra | return v1;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x252f0 */
| #include <stdint.h>
|
; (fcn) fcn.000252f0 () | void fcn_000252f0 () {
0x000252f0 lui gp, 0xa |
0x000252f4 addiu gp, gp, -0x3c10 |
0x000252f8 addu gp, gp, t9 | gp += t9;
0x000252fc addiu sp, sp, -0x50 |
0x00025300 sw s3, 0x34(sp) | *(var_34h) = s3;
0x00025304 lw s3, -0x7fd0(gp) | s3 = *((gp - 8180));
0x00025308 sw s5, 0x3c(sp) | *(var_3ch) = s5;
0x0002530c sw s4, 0x38(sp) | *(var_38h) = s4;
0x00025310 sw s2, 0x30(sp) | *(var_30h) = s2;
0x00025314 sw s1, 0x2c(sp) | *(var_2ch) = s1;
0x00025318 sw s0, 0x28(sp) | *(var_28h) = s0;
0x0002531c sw gp, 0x10(sp) | *(var_10h) = gp;
0x00025320 sw ra, 0x4c(sp) | *(var_4ch) = ra;
0x00025324 sw fp, 0x48(sp) | *(var_48h) = fp;
0x00025328 sw s7, 0x44(sp) | *(var_44h) = s7;
0x0002532c sw s6, 0x40(sp) | *(var_40h) = s6;
0x00025330 move s4, a0 | s4 = a0;
0x00025334 move s0, a1 | s0 = a1;
0x00025338 move s2, a2 | s2 = a2;
0x0002533c move s1, zero | s1 = 0;
0x00025340 addiu s5, s3, 0x4f40 | s5 = s3 + 0x4f40;
| label_0:
0x00025344 addiu s6, zero, 0x18 | s6 = 0x18;
0x00025348 mul v0, s1, s6 | __asm ("mul v0, s1, s6");
0x0002534c lui v1, 9 | v1 = 0x93a80;
0x00025350 ori v1, v1, 0x3a80 |
0x00025354 lui a1, 0x7ff6 | a1 = 0x7ff6c580;
0x00025358 ori a1, a1, 0xc580 |
0x0002535c addu s6, v0, s2 | s6 = v0 + s2;
0x00025360 lw v0, (s6) | v0 = *(s6);
0x00025364 subu v0, v1, v0 | __asm ("subu v0, v1, v0");
0x00025368 lw v1, (s4) | v1 = *(s4);
0x0002536c slt a0, v1, a1 | a0 = (v1 < a1) ? 1 : 0;
0x00025370 addiu a1, zero, -7 | a1 = -7;
| if (a0 == 0) {
0x00025374 bnez a0, 0x25380 |
0x00025378 negu v0, v0 | __asm ("negu v0, v0");
0x0002537c addiu a1, zero, 7 | a1 = 7;
| }
0x00025380 lw t9, -0x7d0c(gp) | t9 = *((gp - 8003));
0x00025384 addu v0, v1, v0 | v0 = v1 + v0;
0x00025388 sw v0, 0x18(sp) | *(var_18h) = v0;
0x0002538c addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x00025390 move a2, s0 | a2 = s0;
0x00025394 bal 0x24bb0 | fcn_00024bb0 ();
0x00025398 lw gp, 0x10(sp) | gp = *(var_10h);
0x0002539c lw v0, (s6) | v0 = *(s6);
0x000253a0 sw s1, 0x20(s0) | *((s0 + 8)) = s1;
0x000253a4 lw s7, -0x7650(gp) | s7 = *((gp - 7572));
0x000253a8 lw t9, -0x7e98(gp) | t9 = *((gp - 8102));
0x000253ac negu v0, v0 | __asm ("negu v0, v0");
0x000253b0 sw v0, 0x24(s0) | *((s0 + 9)) = v0;
0x000253b4 addiu s6, s6, 0x10 | s6 += 0x10;
0x000253b8 addiu fp, s7, 4 | fp = s7 + 4;
| do {
0x000253bc sw t9, 0x20(sp) | *(var_20h) = t9;
0x000253c0 move a0, fp | a0 = fp;
0x000253c4 move a1, s6 | a1 = s6;
0x000253c8 jalr t9 | t9 ();
0x000253cc lw gp, 0x10(sp) | gp = *(var_10h);
0x000253d0 lw t9, 0x20(sp) | t9 = *(var_20h);
| if (v0 == 0) {
0x000253d4 beqz v0, 0x25448 | goto label_1;
| }
0x000253d8 lw s7, (s7) | s7 = *(s7);
0x000253dc addiu fp, s7, 4 | fp = s7 + 4;
0x000253e0 bnel s7, zero, 0x253bc |
| } while (s7 == 0);
0x000253e4 lw t9, -0x7cdc(gp) | t9 = *((gp - 7991));
0x000253e8 move a0, s6 | a0 = s6;
0x000253ec addiu a1, zero, 7 | a1 = 7;
0x000253f0 bal 0x3b9f0 | sym_strnlen ();
0x000253f4 slti v1, v0, 7 | v1 = (v0 < 7) ? 1 : 0;
0x000253f8 lw gp, 0x10(sp) | gp = *(var_10h);
0x000253fc bnez v1, 0x2540c |
| while (v0 == 0) {
0x00025400 lw fp, -0x7580(gp) | fp = *((gp - 7520));
0x00025404 addiu fp, fp, 4 | fp += 4;
0x00025408 b 0x25448 | goto label_1;
0x0002540c lw t9, -0x759c(gp) | t9 = *((gp - 7527));
0x00025410 addiu a0, v0, 8 | a0 = v0 + 8;
0x00025414 jalr t9 | t9 ();
0x00025418 lw gp, 0x10(sp) | gp = *(var_10h);
0x0002541c beqz v0, 0x25400 |
| }
0x00025420 lw v1, -0x7580(gp) | v1 = *((gp - 7520));
0x00025424 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00025428 move a1, s6 | a1 = s6;
0x0002542c lw a0, (v1) | a0 = *(v1);
0x00025430 sw v0, (v1) | *(v1) = v0;
0x00025434 sw a0, (v0) | *(v0) = a0;
0x00025438 addiu a0, v0, 4 | a0 = v0 + 4;
0x0002543c bal 0x3b630 | sym_strcpy ()
0x00025440 lw gp, 0x10(sp) | gp = *(var_10h);
0x00025444 move fp, v0 | fp = v0;
| label_1:
0x00025448 addiu s1, s1, 1 | s1++;
0x0002544c addiu v0, zero, 1 | v0 = 1;
0x00025450 sw fp, 0x28(s0) | *((s0 + 10)) = fp;
| if (s1 != v0) {
0x00025454 bne s1, v0, 0x25668 | goto label_2;
| }
0x00025458 lbu v0, 0x28(s2) | v0 = *((s2 + 40));
0x0002545c move a1, zero | a1 = 0;
| if (v0 == 0) {
0x00025460 beqz v0, 0x2565c | goto label_3;
| }
0x00025464 lw v1, 0x1c(s0) | v1 = *((s0 + 7));
0x00025468 addiu t1, zero, 0x18 | t1 = 0x18;
0x0002546c lw v0, 8(s0) | v0 = *((s0 + 2));
0x00025470 mul a0, t1, v1 | __asm ("mul a0, t1, v1");
0x00025474 lw v1, 4(s0) | v1 = *((s0 + 1));
0x00025478 addu t1, a0, v0 | t1 = a0 + v0;
0x0002547c addiu v0, zero, 0x3c | v0 = 0x3c;
0x00025480 mul a0, t1, v0 | __asm ("mul a0, t1, v0");
0x00025484 addu t1, a0, v1 | t1 = a0 + v1;
0x00025488 mul a0, t1, v0 | __asm ("mul a0, t1, v0");
0x0002548c lw v1, (s0) | v1 = *(s0);
0x00025490 addu t1, a0, v1 | t1 = a0 + v1;
0x00025494 lw v1, 0x14(s0) | v1 = *((s0 + 5));
0x00025498 addiu a0, zero, 0x190 | a0 = aav.0x00000190;
0x0002549c div zero, v1, a0 | __asm ("div zero, v1, a0");
0x000254a0 teq a0, zero, 7 | __asm ("teq a0, zero, 7");
0x000254a4 mfhi v1 | __asm ("mfhi v1");
0x000254a8 addiu v0, v1, 0x76c | v0 = v1 + 0x76c;
0x000254ac andi a1, v0, 3 | a1 = v0 & 3;
0x000254b0 move a3, zero | a3 = 0;
| if (a1 == 0) {
0x000254b4 bnez a1, 0x254ec |
0x000254b8 addiu a1, zero, 0x64 | a1 = 0x64;
0x000254bc div zero, v0, a1 | __asm ("div zero, v0, a1");
0x000254c0 teq a1, zero, 7 | __asm ("teq a1, zero, 7");
0x000254c4 mfhi a2 | __asm ("mfhi a2");
| if (a2 != 0) {
0x000254c8 beqz a2, 0x254d8 |
0x000254cc nop |
0x000254d0 addiu a3, zero, 1 | a3 = 1;
0x000254d4 b 0x254ec |
| } else {
0x000254d8 div zero, v0, a0 | __asm ("div zero, v0, a0");
0x000254dc teq a0, zero, 7 | __asm ("teq a0, zero, 7");
0x000254e0 mfhi a1 | __asm ("mfhi a1");
| if (a1 == 0) {
0x000254e4 beql a1, zero, 0x254ec | goto label_4;
| }
0x000254e8 addiu a3, zero, 1 | a3 = 1;
| }
| }
| label_4:
0x000254ec addiu v1, v1, 0x76b | v1 += 0x76b;
0x000254f0 addiu a0, zero, -0x64 | a0 = -0x64;
0x000254f4 div zero, v1, a0 | __asm ("div zero, v1, a0");
0x000254f8 teq a0, zero, 7 | __asm ("teq a0, zero, 7");
0x000254fc sra t7, v1, 2 | t7 = v1 >> 2;
0x00025500 addiu a0, zero, 0x190 | a0 = aav.0x00000190;
0x00025504 addu t7, v0, t7 | t7 = v0 + t7;
0x00025508 lui t6, 1 | t6 = 0x10000;
0x0002550c move t4, zero | t4 = 0;
0x00025510 move a1, zero | a1 = 0;
0x00025514 move a2, zero | a2 = 0;
0x00025518 addiu t8, zero, 0x4a | t8 = 0x4a;
0x0002551c addiu t9, zero, 0x4d | t9 = 0x4d;
0x00025520 addiu s6, s3, 0x4f40 | s6 = s3 + 0x4f40;
0x00025524 addiu s7, zero, 0x1f | s7 = 0x1f;
0x00025528 addiu t2, zero, 7 | t2 = 7;
0x0002552c addiu t6, t6, 0x5180 | t6 += 0x5180;
0x00025530 addiu t5, zero, 1 | t5 = 1;
0x00025534 mflo v0 | __asm ("mflo v0");
0x00025538 addu t7, t7, v0 | t7 += v0;
0x0002553c div zero, v1, a0 | __asm ("div zero, v1, a0");
0x00025540 teq a0, zero, 7 | __asm ("teq a0, zero, 7");
0x00025544 addiu v1, zero, 7 | v1 = 7;
0x00025548 mflo v0 | __asm ("mflo v0");
0x0002554c addu t7, t7, v0 | t7 += v0;
0x00025550 move v0, s2 | v0 = s2;
0x00025554 div zero, t7, v1 | __asm ("div zero, t7, v1");
0x00025558 teq v1, zero, 7 | __asm ("teq v1, zero, 7");
0x0002555c mfhi t7 | __asm ("mfhi t7");
0x00025560 b 0x25568 |
| while (a2 == t5) {
0x00025564 move t4, v1 | t4 = v1;
0x00025568 lh a0, 0xe(v0) | a0 = *((v0 + 7));
0x0002556c lh v1, 8(v0) | v1 = *((v0 + 4));
| if (a0 == t8) {
0x00025570 bne a0, t8, 0x25590 |
| if (a3 == 0) {
0x00025574 beql a3, zero, 0x25618 | goto label_5;
| }
0x00025578 addiu v1, v1, -1 | v1 += -1;
0x0002557c slti a0, v1, 0x3c | a0 = (v1 < 0x3c) ? 1 : 0;
| if (a0 == 0) {
0x00025580 beqz a0, 0x25618 | goto label_5;
| }
0x00025584 nop |
0x00025588 addiu v1, v1, -1 | v1 += -1;
0x0002558c b 0x25618 |
| if (a0 != t9) {
| } else {
0x00025590 bne a0, t9, 0x25618 | goto label_5;
| }
0x00025594 nop |
0x00025598 lh t0, 0xc(v0) | t0 = *((v0 + 6));
0x0002559c addu a0, t0, s6 | a0 = t0 + s6;
0x000255a0 lbu t3, -1(a0) | t3 = *((a0 - 1));
0x000255a4 mul a0, t0, s7 | __asm ("mul a0, t0, s7");
0x000255a8 subu a0, a0, t3 | __asm ("subu a0, a0, t3");
| if (a3 != 0) {
0x000255ac beqz a3, 0x255bc |
0x000255b0 slti fp, a0, 0x3b | fp = (a0 < 0x3b) ? 1 : 0;
0x000255b4 sltiu fp, fp, 1 | fp = (fp < 1) ? 1 : 0;
0x000255b8 addu a0, a0, fp | a0 += fp;
| }
0x000255bc addu fp, s5, t0 | fp = s5 + t0;
0x000255c0 lbu fp, (fp) | fp = *(fp);
0x000255c4 addiu t3, t3, 0x1f | t3 += 0x1f;
0x000255c8 subu t3, t3, fp | __asm ("subu t3, t3, fp");
| if (a3 != 0) {
0x000255cc beqz a3, 0x255dc |
0x000255d0 xori t0, t0, 2 | t0 ^= 2;
0x000255d4 sltiu t0, t0, 1 | t0 = (t0 < 1) ? 1 : 0;
0x000255d8 addu t3, t3, t0 | t3 += t0;
| }
0x000255dc addu t0, t7, a0 | t0 = t7 + a0;
0x000255e0 div zero, t0, t2 | __asm ("div zero, t0, t2");
0x000255e4 teq t2, zero, 7 | __asm ("teq t2, zero, 7");
0x000255e8 mfhi fp | __asm ("mfhi fp");
0x000255ec subu v1, v1, fp | __asm ("subu v1, v1, fp");
0x000255f0 addiu t0, v1, -7 | t0 = v1 + -7;
0x000255f4 slti fp, v1, 0 | fp = (v1 < 0) ? 1 : 0;
| if (fp != 0) {
0x000255f8 movz v1, t0, fp | v1 = t0;
| }
0x000255fc lh t0, 0xa(v0) | t0 = *((v0 + 5));
0x00025600 mul fp, t0, t2 | __asm ("mul fp, t0, t2");
0x00025604 addu v1, fp, v1 | v1 = fp + v1;
0x00025608 slt t3, v1, t3 | t3 = (v1 < t3) ? 1 : 0;
0x0002560c addiu t0, v1, -7 | t0 = v1 + -7;
| if (t3 != 0) {
0x00025610 movz v1, t0, t3 | v1 = t0;
| }
0x00025614 addu v1, a0, v1 | v1 = a0 + v1;
| }
| label_5:
0x00025618 mul t0, v1, t6 | __asm ("mul t0, v1, t6");
| if (a2 != 0) {
0x0002561c beqz a2, 0x2563c |
0x00025620 lw t0, -0x18(v0) | t0 = *((v0 - 6));
0x00025624 lw a0, (v0) | a0 = *(v0);
0x00025628 slt t4, v1, t4 | t4 = (v1 < t4) ? 1 : 0;
0x0002562c addu a1, a1, t4 | a1 += t4;
0x00025630 subu a0, t0, a0 | __asm ("subu a0, t0, a0");
0x00025634 addu t1, t1, a0 | t1 += a0;
0x00025638 mul t0, v1, t6 | __asm ("mul t0, v1, t6");
| }
0x0002563c lw a0, 4(v0) | a0 = *((v0 + 1));
0x00025640 addiu a2, a2, 1 | a2++;
0x00025644 addiu v0, v0, 0x18 | v0 += 0x18;
0x00025648 addu a0, t0, a0 | a0 = t0 + a0;
0x0002564c slt a0, t1, a0 | a0 = (t1 < a0) ? 1 : 0;
0x00025650 sltiu a0, a0, 1 | a0 = (a0 < 1) ? 1 : 0;
0x00025654 addu a1, a1, a0 | a1 += a0;
0x00025658 beq a2, t5, 0x25564 |
| }
| label_3:
0x0002565c andi a1, a1, 1 | a1 &= 1;
0x00025660 sw a1, 0x20(s0) | *((s0 + 8)) = a1;
| if (a1 != 0) {
0x00025664 bnez a1, 0x25344 | goto label_0;
| }
| label_2:
0x00025668 lw ra, 0x4c(sp) | ra = *(var_4ch);
0x0002566c move v0, s0 | v0 = s0;
0x00025670 lw fp, 0x48(sp) | fp = *(var_48h);
0x00025674 lw s7, 0x44(sp) | s7 = *(var_44h);
0x00025678 lw s6, 0x40(sp) | s6 = *(var_40h);
0x0002567c lw s5, 0x3c(sp) | s5 = *(var_3ch);
0x00025680 lw s4, 0x38(sp) | s4 = *(var_38h);
0x00025684 lw s3, 0x34(sp) | s3 = *(var_34h);
0x00025688 lw s2, 0x30(sp) | s2 = *(var_30h);
0x0002568c lw s1, 0x2c(sp) | s1 = *(var_2ch);
0x00025690 lw s0, 0x28(sp) | s0 = *(var_28h);
0x00025694 addiu sp, sp, 0x50 |
0x00025698 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x35700 */
| #include <stdint.h>
|
; (fcn) fcn.00035700 () | void fcn_00035700 () {
0x00035700 lui gp, 9 |
0x00035704 addiu gp, gp, -0x4020 |
0x00035708 addu gp, gp, t9 | gp += t9;
0x0003570c lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
0x00035710 lw v1, 0x3c(a0) | v1 = *((a0 + 15));
0x00035714 addiu sp, sp, -0x108 |
0x00035718 addiu v0, v0, 0x5850 | v0 += 0x5850;
0x0003571c addu v0, v1, v0 | v0 = v1 + v0;
0x00035720 sw s1, 0xe4(sp) | *(var_e4h) = s1;
0x00035724 sw gp, 0x10(sp) | *(var_10h) = gp;
0x00035728 lbu s1, -1(v0) | s1 = *((v0 - 1));
0x0003572c addiu v0, zero, 1 | v0 = 1;
0x00035730 sw s7, 0xfc(sp) | *(var_fch) = s7;
0x00035734 sw s0, 0xe0(sp) | *(var_e0h) = s0;
0x00035738 sw ra, 0x104(sp) | *(var_104h) = ra;
0x0003573c sw fp, 0x100(sp) | *(var_100h) = fp;
0x00035740 sw s6, 0xf8(sp) | *(var_f8h) = s6;
0x00035744 sw s5, 0xf4(sp) | *(var_f4h) = s5;
0x00035748 sw s4, 0xf0(sp) | *(var_f0h) = s4;
0x0003574c sw s3, 0xec(sp) | *(var_ech) = s3;
0x00035750 sw s2, 0xe8(sp) | *(var_e8h) = s2;
0x00035754 move s0, a0 | s0 = a0;
0x00035758 move s7, a1 | s7 = a1;
0x0003575c sw v1, 0xd0(sp) | *(var_d0h) = v1;
| if (v1 != v0) {
0x00035760 bne v1, v0, 0x357f8 | goto label_3;
| }
0x00035764 lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
0x00035768 lw s4, -0x7b84(gp) | s4 = *((gp - 7905));
0x0003576c addiu s2, v0, 0x5704 | s2 = v0 + 0x5704;
0x00035770 move s3, v0 | s3 = v0;
0x00035774 move t9, s4 | t9 = s4;
| do {
0x00035778 move a0, s7 | a0 = s7;
0x0003577c bal 0x3534c | fcn_0003534c ();
0x00035780 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 >= 0) {
0x00035784 bltz v0, 0x35798 |
0x00035788 lbu a0, (s2) | a0 = *(s2);
0x0003578c lw v0, (s7) | v0 = *(s7);
| if (a0 == v0) {
0x00035790 beql a0, v0, 0x357bc | goto label_4;
| }
0x00035794 addiu s2, s2, 1 | s2++;
| }
0x00035798 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x0003579c addiu s3, s3, 0x5704 | s3 += 0x5704;
0x000357a0 move a0, s7 | a0 = s7;
0x000357a4 sltu s2, s3, s2 | s2 = (s3 < s2) ? 1 : 0;
0x000357a8 bal 0x353e4 | fcn_000353e4 ();
0x000357ac lw gp, 0x10(sp) | gp = *(var_10h);
| if (s2 == 0) {
0x000357b0 beqz s2, 0x357f8 | goto label_3;
| }
0x000357b4 addiu v0, zero, -2 | v0 = -2;
0x000357b8 b 0x36084 | goto label_5;
| label_4:
0x000357bc lbu v0, (s2) | v0 = *(s2);
0x000357c0 move t9, s4 | t9 = s4;
0x000357c4 bnez v0, 0x35778 |
| } while (v0 != 0);
0x000357c8 lbu v0, 0x44(s0) | v0 = *((s0 + 68));
0x000357cc lw v0, 0x34(s0) | v0 = *((s0 + 13));
| if (v0 != 0) {
0x000357d0 bnel v0, zero, 0x357dc |
0x000357d4 move v0, zero | v0 = 0;
0x000357d8 b 0x36084 | goto label_5;
| }
0x000357dc lw a0, 0x2c(s0) | a0 = *((s0 + 11));
0x000357e0 lw a1, 0x38(s0) | a1 = *((s0 + 14));
0x000357e4 addiu v0, v0, 1 | v0++;
0x000357e8 sw v0, 0x34(s0) | *((s0 + 13)) = v0;
0x000357ec move a2, zero | a2 = 0;
0x000357f0 move a3, zero | a3 = 0;
0x000357f4 b 0x35d08 | goto label_6;
| label_3:
0x000357f8 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
0x000357fc move a0, s7 | a0 = s7;
0x00035800 bal 0x3534c | fcn_0003534c ();
0x00035804 lw v0, (s7) | v0 = *(s7);
0x00035808 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x0003580c bltz v0, 0x36080 | goto label_7;
| }
0x00035810 addiu a0, zero, 0x2b | a0 = 0x2b;
0x00035814 addiu a0, zero, 0x2d | a0 = 0x2d;
| if (v0 != a0) {
0x00035818 beq v0, a0, 0x35824 |
0x0003581c addiu fp, sp, 0x18 | fp = sp + 0x18;
| if (v0 != a0) {
0x00035820 bne v0, a0, 0x3583c | goto label_8;
| }
| }
0x00035824 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
0x00035828 sb v0, 0x18(sp) | *(var_18h) = v0;
0x0003582c move a0, s7 | a0 = s7;
0x00035830 bal 0x3534c | fcn_0003534c ();
0x00035834 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035838 addiu fp, sp, 0x19 | fp = sp + 0x19;
| label_8:
0x0003583c andi v0, s1, 0xef | v0 = s1 & 0xef;
0x00035840 lbu v0, 0x45(s0) | v0 = *((s0 + 69));
| if (v0 != 0) {
0x00035844 bnel v0, zero, 0x358e8 |
0x00035848 lw s2, (s7) | s2 = *(s7);
0x0003584c addiu v0, zero, 0x30 | v0 = 0x30;
0x00035850 addiu v0, zero, 0xa | v0 = 0xa;
| if (s2 == v0) {
0x00035854 bne s2, v0, 0x358d8 |
0x00035858 lw s4, -0x7b84(gp) | s4 = *((gp - 7905));
0x0003585c move t9, s4 | t9 = s4;
0x00035860 move a0, s7 | a0 = s7;
0x00035864 bal 0x3534c | fcn_0003534c ();
0x00035868 lw s3, (s7) | s3 = *(s7);
0x0003586c addiu v0, zero, 0x78 | v0 = 0x78;
0x00035870 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035874 ori s3, s3, 0x20 | s3 |= 0x20;
0x00035878 move a0, s7 | a0 = s7;
| if (s3 == v0) {
0x0003587c bne s3, v0, 0x358a8 |
0x00035880 move t9, s4 | t9 = s4;
0x00035884 bal 0x3534c | fcn_0003534c ();
0x00035888 nop |
0x0003588c lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x00035890 bltz v0, 0x3606c | goto label_9;
| }
0x00035894 sb s2, (fp) | *(fp) = s2;
0x00035898 sb s3, 1(fp) | *(var_1h) = s3;
0x0003589c addiu s1, zero, 0x10 | s1 = 0x10;
0x000358a0 addiu fp, fp, 2 | fp += 2;
0x000358a4 b 0x358e4 |
0x000358a8 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x000358ac bal 0x353e4 | fcn_000353e4 ();
0x000358b0 nop |
0x000358b4 lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x000358b8 lw gp, 0x10(sp) | gp = *(var_10h);
0x000358bc slti v0, v0, 8 | v0 = (v0 < 8) ? 1 : 0;
0x000358c0 sw s2, (s7) | *(s7) = s2;
| } else {
| } else {
| }
| }
| if (v0 != 0) {
0x000358c4 beqz v0, 0x358e0 |
0x000358c8 ext s1, s1, 1, 8 | __asm ("ext s1, s1, 1, 8");
0x000358cc addiu s1, s1, 8 | s1 += 8;
0x000358d0 andi s1, s1, 0xff | s1 &= 0xff;
0x000358d4 b 0x358e4 |
| if (s1 != 0) {
0x000358d8 movz s1, v0, s1 | s1 = v0;
| }
0x000358dc b 0x358e4 |
| } else {
0x000358e0 addiu s1, zero, 0xa | s1 = 0xa;
| }
0x000358e4 lbu v0, 0x45(s0) | v0 = *((s0 + 69));
| }
0x000358e8 andi v0, v0, 0x20 | v0 &= 0x20;
0x000358ec andi v0, v0, 0xff | v0 &= 0xff;
0x000358f0 move s2, zero | s2 = 0;
| if (v0 == 0) {
0x000358f4 beqz v0, 0x35ba8 | goto label_10;
| }
0x000358f8 addiu v0, zero, 0xa | v0 = 0xa;
0x000358fc move s3, zero | s3 = 0;
| if (s1 != v0) {
0x00035900 bne s1, v0, 0x35bac | goto label_11;
| }
0x00035904 lw v0, 0x30(s7) | v0 = *((s7 + 12));
0x00035908 lbu s5, (v0) | s5 = *(v0);
| if (s5 == 0) {
0x0003590c beql s5, zero, 0x35bb0 | goto label_12;
| }
0x00035910 lw v0, (s7) | v0 = *(s7);
0x00035914 lbu t1, 1(v0) | t1 = *((v0 + 1));
| if (t1 != 0) {
0x00035918 beql t1, zero, 0x35934 |
0x0003591c sw s5, 0xd4(sp) | *(var_d4h) = s5;
0x00035920 slt v0, s5, t1 | v0 = (s5 < t1) ? 1 : 0;
0x00035924 move v1, s5 | v1 = s5;
| if (v0 == 0) {
0x00035928 movn v1, t1, v0 | v1 = t1;
| }
0x0003592c sw v1, 0xd4(sp) | *(var_d4h) = v1;
0x00035930 b 0x35938 |
| } else {
0x00035934 move t1, s5 | t1 = s5;
| }
0x00035938 lw v0, (s7) | v0 = *(s7);
0x0003593c addiu a0, v0, -0x30 | a0 = v0 + -0x30;
0x00035940 sltiu a0, a0, 0xa | a0 = (a0 < 0xa) ? 1 : 0;
0x00035944 addiu a0, zero, 0x30 | a0 = 0x30;
| if (a0 == 0) {
0x00035948 bnez a0, 0x35964 |
0x0003594c lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x00035950 slti v0, v0, 8 | v0 = (v0 < 8) ? 1 : 0;
0x00035954 move s2, zero | s2 = 0;
| if (v0 == 0) {
0x00035958 beqz v0, 0x35d1c | goto label_13;
| }
0x0003595c lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x00035960 b 0x36070 | goto label_14;
| }
0x00035964 move s2, zero | s2 = 0;
| if (v0 == a0) {
0x00035968 bne v0, a0, 0x35978 |
0x0003596c sb v0, (fp) | *(fp) = v0;
0x00035970 addiu s2, zero, 1 | s2 = 1;
0x00035974 addiu fp, fp, 1 | fp++;
| }
0x00035978 addiu t9, sp, 0x59 | t9 = sp + 0x59;
0x0003597c sw zero, 0xcc(sp) | *(var_cch) = 0;
0x00035980 move s4, zero | s4 = 0;
0x00035984 move s3, zero | s3 = 0;
0x00035988 sw t9, 0xc8(sp) | *(var_c8h) = t9;
| label_0:
0x0003598c move a1, zero | a1 = 0;
0x00035990 b 0x35a18 |
| while (a0 != 0) {
0x00035994 lw t9, 0xcc(sp) | t9 = *(var_cch);
| if (a1 == v1) {
0x00035998 bne a1, v1, 0x359c4 |
0x0003599c slt a1, s5, a1 | a1 = (s5 < a1) ? 1 : 0;
| if (t9 != 0) {
0x000359a0 bnel t9, zero, 0x359b4 |
0x000359a4 addiu s2, zero, 1 | s2 = 1;
| if (s4 != 0) {
0x000359a8 bnez s4, 0x35bf0 | goto label_15;
| }
0x000359ac lw v0, (s7) | v0 = *(s7);
0x000359b0 b 0x35bb0 | goto label_12;
| }
0x000359b4 addiu s2, zero, 1 | s2 = 1;
| if (a1 != 0) {
0x000359b8 bnez a1, 0x3606c | goto label_9;
| }
0x000359bc lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x000359c0 b 0x35c84 | goto label_16;
| }
0x000359c4 addiu a1, a1, 1 | a1++;
| if (s4 == 0) {
0x000359c8 bnez s4, 0x359d8 |
0x000359cc addiu v1, zero, 0x30 | v1 = 0x30;
0x000359d0 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| if (v0 == v1) {
0x000359d4 beq v0, v1, 0x359f8 | goto label_17;
| }
| }
0x000359d8 lw t9, 0xc8(sp) | t9 = *(var_c8h);
0x000359dc sltu a0, fp, t9 | a0 = (fp < t9) ? 1 : 0;
| if (a0 != 0) {
0x000359e0 beql a0, zero, 0x359f4 |
0x000359e4 addiu s3, s3, 1 | s3++;
0x000359e8 sb v0, (fp) | *(fp) = v0;
0x000359ec addiu s4, zero, 1 | s4 = 1;
0x000359f0 addiu fp, fp, 1 | fp++;
| }
0x000359f4 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| label_17:
0x000359f8 sw a1, 0xdc(sp) | *(var_dch) = a1;
0x000359fc sw t1, 0xd8(sp) | *(var_d8h) = t1;
0x00035a00 move a0, s7 | a0 = s7;
0x00035a04 bal 0x3534c | fcn_0003534c ();
0x00035a08 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035a0c lw t1, 0xd8(sp) | t1 = *(var_d8h);
0x00035a10 lw a1, 0xdc(sp) | a1 = *(var_dch);
0x00035a14 addiu s2, zero, 1 | s2 = 1;
0x00035a18 lw v0, (s7) | v0 = *(s7);
0x00035a1c addiu a0, v0, -0x30 | a0 = v0 + -0x30;
0x00035a20 sltiu a0, a0, 0xa | a0 = (a0 < 0xa) ? 1 : 0;
0x00035a24 lw v1, 0xd4(sp) | v1 = *(var_d4h);
0x00035a28 bnez a0, 0x35994 |
| }
0x00035a2c lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
| if (a1 == 0) {
0x00035a30 beqz a1, 0x36070 | goto label_14;
| }
0x00035a34 slt a0, a1, t1 | a0 = (a1 < t1) ? 1 : 0;
| if (a1 != t1) {
0x00035a38 beq a1, t1, 0x35a4c |
0x00035a3c lw v1, 0xcc(sp) | v1 = *(var_cch);
| if (a0 == 0) {
0x00035a40 beqz a0, 0x35b84 | goto label_18;
| }
| if (v1 != 0) {
0x00035a44 bnez v1, 0x35b84 | goto label_18;
| }
0x00035a48 nop |
| }
0x00035a4c lw s6, 0x34(s7) | s6 = *((s7 + 13));
0x00035a50 lbu a0, (s6) | a0 = *(s6);
0x00035a54 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| if (a0 != v0) {
0x00035a58 bne a0, v0, 0x35b84 | goto label_18;
| }
0x00035a5c sw a1, 0xdc(sp) | *(var_dch) = a1;
0x00035a60 sw t1, 0xd8(sp) | *(var_d8h) = t1;
0x00035a64 move a0, s7 | a0 = s7;
0x00035a68 bal 0x3534c | fcn_0003534c ();
0x00035a6c lw gp, 0x10(sp) | gp = *(var_10h);
0x00035a70 lw t1, 0xd8(sp) | t1 = *(var_d8h);
0x00035a74 lw a1, 0xdc(sp) | a1 = *(var_dch);
| do {
0x00035a78 addiu s6, s6, 1 | s6++;
0x00035a7c lbu v0, (s6) | v0 = *(s6);
0x00035a80 lw a0, (s7) | a0 = *(s7);
| if (v0 != 0) {
0x00035a84 bnel v0, zero, 0x35a98 |
0x00035a88 lw v1, 0xcc(sp) | v1 = *(var_cch);
0x00035a8c addiu v1, v1, 1 | v1++;
0x00035a90 sw v1, 0xcc(sp) | *(var_cch) = v1;
0x00035a94 b 0x3598c | goto label_0;
| }
0x00035a98 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| if (v0 != a0) {
0x00035a9c bne v0, a0, 0x35ac0 | goto label_19;
| }
0x00035aa0 sw a1, 0xdc(sp) | *(var_dch) = a1;
0x00035aa4 sw t1, 0xd8(sp) | *(var_d8h) = t1;
0x00035aa8 move a0, s7 | a0 = s7;
0x00035aac bal 0x3534c | fcn_0003534c ();
0x00035ab0 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035ab4 lw a1, 0xdc(sp) | a1 = *(var_dch);
0x00035ab8 lw t1, 0xd8(sp) | t1 = *(var_d8h);
0x00035abc b 0x35a78 |
| } while (1);
| label_19:
0x00035ac0 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x00035ac4 move a0, s7 | a0 = s7;
0x00035ac8 sw a1, 0xdc(sp) | *(var_dch) = a1;
0x00035acc bal 0x353e4 | fcn_000353e4 ();
0x00035ad0 lw v0, (s7) | v0 = *(s7);
0x00035ad4 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035ad8 lw a0, 0x34(s7) | a0 = *((s7 + 13));
0x00035adc lw a1, 0xdc(sp) | a1 = *(var_dch);
| if (v0 < 0) {
0x00035ae0 bgez v0, 0x35af4 |
0x00035ae4 addiu v0, a0, 1 | v0 = a0 + 1;
0x00035ae8 sltu v0, v0, s6 | v0 = (v0 < s6) ? 1 : 0;
| if (v0 == 0) {
0x00035aec beqz v0, 0x35b84 | goto label_18;
| }
0x00035af0 nop |
| }
0x00035af4 lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x00035af8 subu s6, s6, a0 | __asm ("subu s6, s6, a0");
0x00035afc slti v0, v0, 8 | v0 = (v0 < 8) ? 1 : 0;
0x00035b00 addiu s6, s6, -1 | s6 += -1;
| if (v0 != 0) {
0x00035b04 bnez v0, 0x36078 | goto label_20;
| }
0x00035b08 lw v1, 0xcc(sp) | v1 = *(var_cch);
0x00035b0c lw t9, -0x7d84(gp) | t9 = *((gp - 8033));
| if (v1 != 0) {
0x00035b10 beqz v1, 0x35b1c |
0x00035b14 addiu v0, zero, -2 | v0 = -2;
| if (a1 != s5) {
0x00035b18 bne a1, s5, 0x36084 | goto label_5;
| }
| }
0x00035b1c lw a1, 0x4c(s7) | a1 = *((s7 + 19));
0x00035b20 move a2, s6 | a2 = s6;
0x00035b24 bal 0x3ab1c | sym_bcmp ();
0x00035b28 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x00035b2c bnez v0, 0x36078 | goto label_20;
| }
0x00035b30 lw s5, -0x7b84(gp) | s5 = *((gp - 7905));
0x00035b34 move t9, s5 | t9 = s5;
0x00035b38 move a0, s7 | a0 = s7;
0x00035b3c bal 0x3534c | fcn_0003534c ();
0x00035b40 lw v0, 0x4c(s7) | v0 = *((s7 + 19));
0x00035b44 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035b48 addu s6, v0, s6 | s6 = v0 + s6;
| do {
0x00035b4c addiu s6, s6, 1 | s6++;
0x00035b50 lbu v0, (s6) | v0 = *(s6);
0x00035b54 lw a0, (s7) | a0 = *(s7);
| if (v0 != 0) {
0x00035b58 bnel v0, zero, 0x35b64 |
0x00035b5c lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00035b60 b 0x35d3c | goto label_21;
| }
| if (v0 != a0) {
0x00035b64 beql v0, a0, 0x35b74 |
0x00035b68 move t9, s5 | t9 = s5;
0x00035b6c lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x00035b70 b 0x36070 | goto label_14;
| }
0x00035b74 move a0, s7 | a0 = s7;
0x00035b78 bal 0x3534c | fcn_0003534c ();
0x00035b7c lw gp, 0x10(sp) | gp = *(var_10h);
0x00035b80 b 0x35b4c |
| } while (1);
| if (a1 == s5) {
| label_18:
0x00035b84 beql a1, s5, 0x35c84 | goto label_16;
| }
0x00035b88 lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x00035b8c slt a1, a1, s5 | a1 = (a1 < s5) ? 1 : 0;
0x00035b90 lw v1, 0xcc(sp) | v1 = *(var_cch);
| if (a1 == 0) {
0x00035b94 beqz a1, 0x3606c | goto label_9;
| }
| if (v1 == 0) {
0x00035b98 beql v1, zero, 0x35c84 | goto label_16;
| }
0x00035b9c lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x00035ba0 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x00035ba4 b 0x36070 | goto label_14;
| label_10:
0x00035ba8 move s3, zero | s3 = 0;
| label_11:
0x00035bac lw v0, (s7) | v0 = *(s7);
| label_12:
0x00035bb0 addiu a0, zero, 0x30 | a0 = 0x30;
0x00035bb4 move s4, zero | s4 = 0;
| if (v0 != a0) {
0x00035bb8 bne v0, a0, 0x35c38 | goto label_22;
| }
0x00035bbc lw s2, -0x7b84(gp) | s2 = *((gp - 7905));
0x00035bc0 sb v0, (fp) | *(fp) = v0;
0x00035bc4 addiu s4, zero, 0x30 | s4 = 0x30;
0x00035bc8 addiu fp, fp, 1 | fp++;
| do {
0x00035bcc move t9, s2 | t9 = s2;
0x00035bd0 move a0, s7 | a0 = s7;
0x00035bd4 bal 0x3534c | fcn_0003534c ();
0x00035bd8 lw v0, (s7) | v0 = *(s7);
0x00035bdc lw gp, 0x10(sp) | gp = *(var_10h);
0x00035be0 beq v0, s4, 0x35bcc |
| } while (v0 == s4);
0x00035be4 addiu s2, zero, 1 | s2 = 1;
0x00035be8 move s4, zero | s4 = 0;
0x00035bec b 0x35c38 | goto label_22;
| label_15:
0x00035bf0 addiu s4, zero, 1 | s4 = 1;
0x00035bf4 b 0x35c38 |
| while (s1 == a1) {
0x00035bf8 subu a0, fp, s6 | __asm ("subu a0, fp, s6");
| label_1:
0x00035bfc slti a0, a0, 0x41 | a0 = (a0 < 0x41) ? 1 : 0;
| if (a0 != 0) {
0x00035c00 beql a0, zero, 0x35c18 |
0x00035c04 addiu s3, s3, 1 | s3++;
0x00035c08 sb v0, (fp) | *(fp) = v0;
0x00035c0c addiu s2, zero, 1 | s2 = 1;
0x00035c10 addiu fp, fp, 1 | fp++;
0x00035c14 addiu s4, zero, 1 | s4 = 1;
| }
0x00035c18 sw a1, 0xdc(sp) | *(var_dch) = a1;
0x00035c1c sw t9, 0xd8(sp) | *(var_d8h) = t9;
0x00035c20 move a0, s7 | a0 = s7;
0x00035c24 jalr t9 | t9 ();
0x00035c28 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035c2c lw a1, 0xdc(sp) | a1 = *(var_dch);
0x00035c30 lw t9, 0xd8(sp) | t9 = *(var_d8h);
0x00035c34 b 0x35c48 | goto label_23;
| label_22:
0x00035c38 lw s5, -0x7f78(gp) | s5 = *((gp - 8158));
0x00035c3c lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
0x00035c40 addiu a1, zero, 0x10 | a1 = 0x10;
0x00035c44 addiu s6, sp, 0x18 | s6 = sp + 0x18;
| label_23:
0x00035c48 lw v0, (s7) | v0 = *(s7);
0x00035c4c lw a2, (s5) | a2 = *(s5);
0x00035c50 sll a0, v0, 1 | a0 = v0 << 1;
0x00035c54 addu a0, a2, a0 | a0 = a2 + a0;
0x00035c58 lhu a0, (a0) | a0 = *(a0);
0x00035c5c andi a0, a0, 0x10 | a0 &= 0x10;
0x00035c60 andi a0, a0, 0xffff | a0 &= 0xffff;
| if (a0 == 0) {
0x00035c64 beql a0, zero, 0x35c84 | goto label_16;
| }
0x00035c68 lw v0, 0x3c(s0) | v0 = *((s0 + 15));
0x00035c6c addiu a0, v0, -0x2f | a0 = v0 + -0x2f;
0x00035c70 beq s1, a1, 0x35bf8 |
| }
0x00035c74 slt a0, s1, a0 | a0 = (s1 < a0) ? 1 : 0;
0x00035c78 subu a0, fp, s6 | __asm ("subu a0, fp, s6");
| if (a0 == 0) {
0x00035c7c beqz a0, 0x35bfc | goto label_1;
| }
0x00035c80 lw v0, 0x3c(s0) | v0 = *((s0 + 15));
| label_16:
0x00035c84 slti v0, v0, 8 | v0 = (v0 < 8) ? 1 : 0;
| if (v0 != 0) {
0x00035c88 beql v0, zero, 0x35d28 |
0x00035c8c lw s5, 0x4c(s7) | s5 = *((s7 + 19));
0x00035c90 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x00035c94 move a0, s7 | a0 = s7;
0x00035c98 bal 0x353e4 | fcn_000353e4 ();
0x00035c9c lw gp, 0x10(sp) | gp = *(var_10h);
0x00035ca0 sb zero, (fp) | *(fp) = 0;
| if (s2 == 0) {
0x00035ca4 beqz s2, 0x36078 | goto label_20;
| }
0x00035ca8 lbu v0, 0x44(s0) | v0 = *((s0 + 68));
0x00035cac lbu v1, 0x18(sp) | v1 = *(var_18h);
| if (v0 == 0) {
0x00035cb0 beqz v0, 0x36064 | goto label_24;
| }
0x00035cb4 lw t9, 0xd0(sp) | t9 = *(var_d0h);
0x00035cb8 addiu a3, zero, 1 | a3 = 1;
0x00035cbc xori v0, v1, 0x2d | v0 = v1 ^ 0x2d;
0x00035cc0 lw v1, 0x34(s0) | v1 = *((s0 + 13));
0x00035cc4 slti s6, t9, 6 | s6 = (t9 < 6) ? 1 : 0;
0x00035cc8 lw t9, -0x7b6c(gp) | t9 = *((gp - 7899));
| if (v0 != 0) {
0x00035ccc movz s6, zero, v0 | s6 = 0;
| }
0x00035cd0 addiu v1, v1, 1 | v1++;
0x00035cd4 lw s2, 0x2c(s0) | s2 = *((s0 + 11));
0x00035cd8 sw v1, 0x34(s0) | *((s0 + 13)) = v1;
0x00035cdc addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x00035ce0 lw s0, 0x38(s0) | s0 = *((s0 + 14));
0x00035ce4 move a1, zero | a1 = 0;
0x00035ce8 move a2, s1 | a2 = s1;
0x00035cec subu a3, a3, s6 | __asm ("subu a3, a3, s6");
0x00035cf0 jalr t9 | t9 ();
0x00035cf4 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035cf8 move a0, s2 | a0 = s2;
0x00035cfc move a1, s0 | a1 = s0;
0x00035d00 move a2, v0 | a2 = v0;
0x00035d04 move a3, v1 | a3 = v1;
| label_6:
0x00035d08 lw t9, -0x7ba8(gp) | t9 = *((gp - 7914));
0x00035d0c bal 0x31a60 | fcn_00031a60 ();
0x00035d10 nop |
0x00035d14 b 0x36064 | goto label_24;
0x00035d18 nop |
| label_13:
0x00035d1c move s4, zero | s4 = 0;
0x00035d20 move s3, zero | s3 = 0;
0x00035d24 lw s5, 0x4c(s7) | s5 = *((s7 + 19));
| }
0x00035d28 lw s6, -0x7b84(gp) | s6 = *((gp - 7905));
| do {
0x00035d2c lbu v0, (s5) | v0 = *(s5);
0x00035d30 lw a0, (s7) | a0 = *(s7);
| if (v0 != 0) {
0x00035d34 bnel v0, zero, 0x35d58 |
0x00035d38 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
| label_21:
0x00035d3c lw a1, 0x40(s7) | a1 = *((s7 + 16));
0x00035d40 move a0, fp | a0 = fp;
0x00035d44 bal 0x3b630 | sym_strcpy ()
0x00035d48 lw v0, 0x44(s7) | v0 = *((s7 + 17));
0x00035d4c lw gp, 0x10(sp) | gp = *(var_10h);
0x00035d50 addu fp, fp, v0 | fp += v0;
0x00035d54 b 0x35d8c |
| } else {
0x00035d58 move t9, s6 | t9 = s6;
| if (v0 != a0) {
0x00035d5c beq v0, a0, 0x35d78 |
0x00035d60 lw v0, 0x4c(s7) | v0 = *((s7 + 19));
0x00035d64 sltu s5, v0, s5 | s5 = (v0 < s5) ? 1 : 0;
0x00035d68 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
| if (s5 == 0) {
0x00035d6c beqz s5, 0x35e58 | goto label_25;
| }
0x00035d70 b 0x36070 | goto label_14;
0x00035d74 nop |
| }
0x00035d78 move a0, s7 | a0 = s7;
0x00035d7c bal 0x3534c | fcn_0003534c ();
0x00035d80 addiu s5, s5, 1 | s5++;
0x00035d84 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035d88 b 0x35d2c |
| } while (1);
| }
0x00035d8c lw s6, -0x7f78(gp) | s6 = *((gp - 8158));
| if (s4 != 0) {
0x00035d90 bnez s4, 0x35e10 | goto label_26;
| }
0x00035d94 lw v0, (s7) | v0 = *(s7);
0x00035d98 addiu a0, zero, 0x30 | a0 = 0x30;
0x00035d9c lw s5, -0x7b84(gp) | s5 = *((gp - 7905));
| if (v0 != a0) {
0x00035da0 bne v0, a0, 0x35e14 | goto label_27;
| }
0x00035da4 lw s2, -0x7b84(gp) | s2 = *((gp - 7905));
0x00035da8 sb v0, (fp) | *(fp) = v0;
0x00035dac addiu s3, s3, 1 | s3++;
0x00035db0 addiu fp, fp, 1 | fp++;
0x00035db4 addiu s4, zero, 0x30 | s4 = 0x30;
| do {
0x00035db8 move t9, s2 | t9 = s2;
0x00035dbc move a0, s7 | a0 = s7;
0x00035dc0 bal 0x3534c | fcn_0003534c ();
0x00035dc4 lw v0, (s7) | v0 = *(s7);
0x00035dc8 addiu s3, s3, -1 | s3 += -1;
0x00035dcc lw gp, 0x10(sp) | gp = *(var_10h);
0x00035dd0 beq v0, s4, 0x35db8 |
| } while (v0 == s4);
0x00035dd4 addiu s2, zero, 1 | s2 = 1;
0x00035dd8 b 0x35e0c |
| while (s1 == s4) {
0x00035ddc lw v1, 0xc8(sp) | v1 = *(var_c8h);
| label_2:
0x00035de0 subu a0, fp, v1 | __asm ("subu a0, fp, v1");
0x00035de4 slti a0, a0, 0x41 | a0 = (a0 < 0x41) ? 1 : 0;
0x00035de8 move t9, s5 | t9 = s5;
| if (a0 != 0) {
0x00035dec beqz a0, 0x35dfc |
0x00035df0 sb v0, (fp) | *(fp) = v0;
0x00035df4 addiu s2, zero, 1 | s2 = 1;
0x00035df8 addiu fp, fp, 1 | fp++;
| }
0x00035dfc move a0, s7 | a0 = s7;
0x00035e00 bal 0x3534c | fcn_0003534c ();
0x00035e04 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035e08 b 0x35e20 | goto label_28;
0x00035e0c lw s6, -0x7f78(gp) | s6 = *((gp - 8158));
| label_26:
0x00035e10 lw s5, -0x7b84(gp) | s5 = *((gp - 7905));
| label_27:
0x00035e14 addiu v1, sp, 0x18 | v1 = sp + 0x18;
0x00035e18 addiu s4, zero, 0x10 | s4 = 0x10;
0x00035e1c sw v1, 0xc8(sp) | *(var_c8h) = v1;
| label_28:
0x00035e20 lw v0, (s7) | v0 = *(s7);
0x00035e24 lw a1, (s6) | a1 = *(s6);
0x00035e28 sll a0, v0, 1 | a0 = v0 << 1;
0x00035e2c addu a0, a1, a0 | a0 = a1 + a0;
0x00035e30 lhu a0, (a0) | a0 = *(a0);
0x00035e34 andi a0, a0, 0x10 | a0 &= 0x10;
0x00035e38 andi a0, a0, 0xffff | a0 &= 0xffff;
| if (a0 == 0) {
0x00035e3c beqz a0, 0x35e58 | goto label_25;
| }
0x00035e40 nop |
0x00035e44 addiu a0, v0, -0x2f | a0 = v0 + -0x2f;
0x00035e48 beq s1, s4, 0x35ddc |
| }
0x00035e4c slt a0, s1, a0 | a0 = (s1 < a0) ? 1 : 0;
0x00035e50 lw v1, 0xc8(sp) | v1 = *(var_c8h);
| if (a0 == 0) {
0x00035e54 beqz a0, 0x35de0 | goto label_2;
| }
| label_25:
0x00035e58 addiu a0, zero, 0x10 | a0 = 0x10;
| if (s2 != 0) {
0x00035e5c bnez s2, 0x35ef8 | goto label_29;
| }
0x00035e60 addiu v0, zero, 0x10 | v0 = 0x10;
0x00035e64 addiu a1, zero, 0x69 | a1 = 0x69;
| if (s1 == v0) {
0x00035e68 beq s1, v0, 0x3606c | goto label_9;
| }
0x00035e6c lw v0, (s7) | v0 = *(s7);
0x00035e70 ori a0, v0, 0x20 | a0 = v0 | 0x20;
0x00035e74 addiu a1, zero, 0x6e | a1 = 0x6e;
| if (a0 != a1) {
0x00035e78 beq a0, a1, 0x35e8c |
0x00035e7c lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
| if (a0 != a1) {
0x00035e80 bne a0, a1, 0x36070 | goto label_14;
| }
0x00035e84 lw s1, -0x7fd0(gp) | s1 = *((gp - 8180));
0x00035e88 b 0x35e98 |
| } else {
0x00035e8c lw s1, -0x7fd0(gp) | s1 = *((gp - 8180));
0x00035e90 addiu s1, s1, 0x5863 | s1 += 0x5863;
0x00035e94 b 0x35e9c | goto label_30;
| }
0x00035e98 addiu s1, s1, 0x5860 | s1 += 0x5860;
| label_30:
0x00035e9c lw s2, -0x7b84(gp) | s2 = *((gp - 7905));
0x00035ea0 sb v0, (fp) | *(fp) = v0;
0x00035ea4 addiu fp, fp, 1 | fp++;
| do {
0x00035ea8 move t9, s2 | t9 = s2;
0x00035eac move a0, s7 | a0 = s7;
0x00035eb0 bal 0x3534c | fcn_0003534c ();
0x00035eb4 lw a0, (s7) | a0 = *(s7);
0x00035eb8 lbu v0, (s1) | v0 = *(s1);
0x00035ebc ori a1, a0, 0x20 | a1 = a0 | 0x20;
0x00035ec0 lw gp, 0x10(sp) | gp = *(var_10h);
| if (a1 != v0) {
0x00035ec4 bne a1, v0, 0x35ed8 | goto label_31;
| }
0x00035ec8 sb a0, (fp) | *(fp) = a0;
0x00035ecc addiu s1, s1, 1 | s1++;
0x00035ed0 addiu fp, fp, 1 | fp++;
0x00035ed4 b 0x35ea8 |
| } while (1);
| label_31:
0x00035ed8 lw t9, -0x7b68(gp) | t9 = *((gp - 7898));
| if (v0 == 0) {
0x00035edc beqz v0, 0x35ffc | goto label_32;
| }
0x00035ee0 lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
0x00035ee4 addiu v0, v0, 0x5865 | v0 += 0x5865;
| if (s1 == v0) {
0x00035ee8 beql s1, v0, 0x36000 | goto label_33;
| }
0x00035eec sb zero, (fp) | *(fp) = 0;
0x00035ef0 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x00035ef4 b 0x36070 | goto label_14;
| label_29:
0x00035ef8 lw v0, (s7) | v0 = *(s7);
| if (s1 == a0) {
0x00035efc bne s1, a0, 0x35f10 |
0x00035f00 ori a1, v0, 0x20 | a1 = v0 | 0x20;
0x00035f04 addiu a0, zero, 0x70 | a0 = 0x70;
0x00035f08 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| if (a1 == a0) {
0x00035f0c beq a1, a0, 0x35f28 | goto label_34;
| }
| }
0x00035f10 ori v0, v0, 0x20 | v0 |= 0x20;
0x00035f14 addiu a0, zero, 0x65 | a0 = 0x65;
0x00035f18 lw t9, -0x7b68(gp) | t9 = *((gp - 7898));
| if (v0 != a0) {
0x00035f1c bne v0, a0, 0x35ffc | goto label_32;
| }
0x00035f20 lw v0, (s7) | v0 = *(s7);
0x00035f24 lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| label_34:
0x00035f28 move a0, s7 | a0 = s7;
0x00035f2c sb v0, (fp) | *(fp) = v0;
0x00035f30 bal 0x3534c | fcn_0003534c ();
0x00035f34 lw v0, (s7) | v0 = *(s7);
0x00035f38 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x00035f3c bltz v0, 0x3606c | goto label_9;
| }
0x00035f40 addiu a0, zero, 0x2b | a0 = 0x2b;
0x00035f44 addiu a0, zero, 0x2d | a0 = 0x2d;
| if (v0 != a0) {
0x00035f48 beq v0, a0, 0x35f5c |
0x00035f4c lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| if (v0 != a0) {
0x00035f50 beq v0, a0, 0x35f60 |
0x00035f54 addiu fp, fp, 1 | fp++;
0x00035f58 b 0x35f78 |
| } else {
0x00035f5c lw t9, -0x7b84(gp) | t9 = *((gp - 7905));
| }
0x00035f60 sb v0, 1(fp) | *(var_1h) = v0;
0x00035f64 move a0, s7 | a0 = s7;
0x00035f68 bal 0x3534c | fcn_0003534c ();
0x00035f6c lw gp, 0x10(sp) | gp = *(var_10h);
0x00035f70 addiu fp, fp, 2 | fp += 2;
0x00035f74 lw v0, (s7) | v0 = *(s7);
| }
0x00035f78 addiu a0, zero, 0x30 | a0 = 0x30;
0x00035f7c move s1, zero | s1 = 0;
| if (v0 != a0) {
0x00035f80 bne v0, a0, 0x35fdc | goto label_35;
| }
0x00035f84 lw s1, -0x7b84(gp) | s1 = *((gp - 7905));
0x00035f88 sb v0, (fp) | *(fp) = v0;
0x00035f8c addiu s2, zero, 0x30 | s2 = 0x30;
0x00035f90 addiu fp, fp, 1 | fp++;
| do {
0x00035f94 move t9, s1 | t9 = s1;
0x00035f98 move a0, s7 | a0 = s7;
0x00035f9c bal 0x3534c | fcn_0003534c ();
0x00035fa0 lw v0, (s7) | v0 = *(s7);
0x00035fa4 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035fa8 beq v0, s2, 0x35f94 |
| } while (v0 == s2);
0x00035fac addiu s1, zero, 1 | s1 = 1;
0x00035fb0 b 0x35fdc |
| while (a0 != 0) {
0x00035fb4 move t9, s2 | t9 = s2;
| if (a0 != 0) {
0x00035fb8 beqz a0, 0x35fcc |
0x00035fbc addiu s1, s1, 1 | s1++;
0x00035fc0 sb v0, (fp) | *(fp) = v0;
0x00035fc4 andi s1, s1, 0xff | s1 &= 0xff;
0x00035fc8 addiu fp, fp, 1 | fp++;
| }
0x00035fcc move a0, s7 | a0 = s7;
0x00035fd0 bal 0x3534c | fcn_0003534c ();
0x00035fd4 lw gp, 0x10(sp) | gp = *(var_10h);
0x00035fd8 b 0x35fe0 | goto label_36;
| label_35:
0x00035fdc lw s2, -0x7b84(gp) | s2 = *((gp - 7905));
| label_36:
0x00035fe0 lw v0, (s7) | v0 = *(s7);
0x00035fe4 addiu a0, v0, -0x30 | a0 = v0 + -0x30;
0x00035fe8 sltiu a0, a0, 0xa | a0 = (a0 < 0xa) ? 1 : 0;
0x00035fec sltiu a0, s1, 0x14 | a0 = (s1 < 0x14) ? 1 : 0;
0x00035ff0 bnez a0, 0x35fb4 |
| }
0x00035ff4 lw t9, -0x7b68(gp) | t9 = *((gp - 7898));
| if (s1 != 0) {
0x00035ff8 beqz s1, 0x3606c |
| label_32:
0x00035ffc sb zero, (fp) | *(fp) = 0;
| label_33:
0x00036000 addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x00036004 addiu a1, sp, 0xc0 | a1 = sp + 0xc0;
0x00036008 move a2, s3 | a2 = s3;
0x0003600c jalr t9 | t9 ();
0x00036010 lbu v0, 0x44(s0) | v0 = *((s0 + 68));
0x00036014 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x00036018 beqz v0, 0x36058 |
0x0003601c lw a0, 0x38(s0) | a0 = *((s0 + 14));
0x00036020 andi a1, a0, 0x800 | a1 = a0 & aav.0x00000800;
0x00036024 lw v0, 0x2c(s0) | v0 = *((s0 + 11));
| if (a1 != 0) {
0x00036028 beqz a1, 0x36034 |
0x0003602c sdc1 f0, (v0) | __asm ("sdc1 f0, (v0)");
0x00036030 b 0x3604c |
| } else {
0x00036034 andi a0, a0, 0x400 | a0 &= aav.0x00000400;
| if (a0 != 0) {
0x00036038 beql a0, zero, 0x36048 |
0x0003603c cvt.s.d f0, f0 | __asm ("cvt.s.d f0, f0");
0x00036040 sdc1 f0, (v0) | __asm ("sdc1 f0, (v0)");
0x00036044 b 0x3604c |
| } else {
0x00036048 swc1 f0, (v0) | __asm ("swc1 f0, (v0)");
| }
| }
0x0003604c lw v0, 0x34(s0) | v0 = *((s0 + 13));
0x00036050 addiu v0, v0, 1 | v0++;
0x00036054 sw v0, 0x34(s0) | *((s0 + 13)) = v0;
| }
0x00036058 lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
0x0003605c move a0, s7 | a0 = s7;
0x00036060 bal 0x353e4 | fcn_000353e4 ();
| label_24:
0x00036064 move v0, zero | v0 = 0;
0x00036068 b 0x36084 |
| } else {
| label_9:
0x0003606c lw t9, -0x7b78(gp) | t9 = *((gp - 7902));
| label_14:
0x00036070 move a0, s7 | a0 = s7;
0x00036074 bal 0x353e4 | fcn_000353e4 ();
| label_20:
0x00036078 addiu v0, zero, -2 | v0 = -2;
0x0003607c b 0x36084 | goto label_5;
| label_7:
0x00036080 addiu v0, zero, -1 | v0 = -1;
| }
| label_5:
0x00036084 lw ra, 0x104(sp) | ra = *(var_104h);
0x00036088 lw fp, 0x100(sp) | fp = *(var_100h);
0x0003608c lw s7, 0xfc(sp) | s7 = *(var_fch);
0x00036090 lw s6, 0xf8(sp) | s6 = *(var_f8h);
0x00036094 lw s5, 0xf4(sp) | s5 = *(var_f4h);
0x00036098 lw s4, 0xf0(sp) | s4 = *(var_f0h);
0x0003609c lw s3, 0xec(sp) | s3 = *(var_ech);
0x000360a0 lw s2, 0xe8(sp) | s2 = *(var_e8h);
0x000360a4 lw s1, 0xe4(sp) | s1 = *(var_e4h);
0x000360a8 lw s0, 0xe0(sp) | s0 = *(var_e0h);
0x000360ac addiu sp, sp, 0x108 |
0x000360b0 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x455c8 */
| #include <stdint.h>
|
; (fcn) fcn.000455c8 () | void fcn_000455c8 () {
0x000455c8 lui gp, 8 |
0x000455cc addiu gp, gp, -0x3ee8 |
0x000455d0 addu gp, gp, t9 | gp += t9;
0x000455d4 addiu sp, sp, -0x68 |
0x000455d8 sw fp, 0x60(sp) | *(var_60h) = fp;
0x000455dc move fp, sp | fp = sp;
0x000455e0 sw s5, 0x58(sp) | *(var_58h) = s5;
0x000455e4 sw s4, 0x54(sp) | *(var_54h) = s4;
0x000455e8 sw s3, 0x50(sp) | *(var_50h) = s3;
0x000455ec sw s2, 0x4c(sp) | *(var_4ch) = s2;
0x000455f0 sw ra, 0x64(sp) | *(var_64h) = ra;
0x000455f4 sw s6, 0x5c(sp) | *(var_5ch) = s6;
0x000455f8 sw s1, 0x48(sp) | *(var_48h) = s1;
0x000455fc sw s0, 0x44(sp) | *(var_44h) = s0;
0x00045600 sw gp, 0x18(sp) | *(var_18h) = gp;
0x00045604 move s5, a0 | s5 = a0;
0x00045608 move s3, a1 | s3 = a1;
0x0004560c move s4, a2 | s4 = a2;
0x00045610 move s2, a3 | s2 = a3;
0x00045614 beqz a1, 0x45620 |
| while (v0 == 0) {
0x00045618 addiu s0, zero, -1 | s0 = -1;
0x0004561c b 0x45678 | goto label_0;
0x00045620 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00045624 lw t9, -0x7b10(gp) | t9 = *((gp - 7876));
0x00045628 addiu t9, t9, 0x5030 | t9 += 0x5030;
0x0004562c addiu a0, a0, 0x7188 | a0 += 0x7188;
0x00045630 bal 0x45030 | fcn_00045030 ();
0x00045634 move s1, v0 | s1 = v0;
0x00045638 lw gp, 0x18(fp) | gp = *(var_18h);
0x0004563c beqz v0, 0x45618 |
| }
0x00045640 lw t9, -0x7b10(gp) | t9 = *((gp - 7876));
0x00045644 move a0, v0 | a0 = v0;
0x00045648 move a1, s5 | a1 = s5;
0x0004564c move a2, s2 | a2 = s2;
0x00045650 addiu t9, t9, 0x512c | t9 += 0x512c;
0x00045654 move a3, s4 | a3 = s4;
0x00045658 bal 0x4512c | fcn_0004512c ();
0x0004565c lw gp, 0x18(fp) | gp = *(var_18h);
0x00045660 move s0, v0 | s0 = v0;
0x00045664 lw t9, -0x7dd0(gp) | t9 = *((gp - 8052));
0x00045668 move a0, s1 | a0 = s1;
0x0004566c bal 0x2de70 | sym_fclose ();
0x00045670 lw gp, 0x18(fp) | gp = *(var_18h);
| if (s0 != 0) {
0x00045674 beqz s0, 0x457d4 |
| label_0:
0x00045678 lw v0, -0x7608(gp) | v0 = *((gp - 7554));
0x0004567c lw v0, (v0) | v0 = *(v0);
0x00045680 or s3, s3, v0 | s3 |= v0;
0x00045684 lw t9, -0x7ef0(gp) | t9 = *((gp - 8124));
| if (s3 != 0) {
0x00045688 beqz s3, 0x457d0 |
0x0004568c addiu a0, zero, 0x46 | a0 = 0x46;
0x00045690 bal 0x60b5c | sym_sysconf ();
0x00045694 lw gp, 0x18(fp) | gp = *(var_18h);
0x00045698 addiu v1, v0, 0xe | v1 = v0 + 0xe;
0x0004569c srl v1, v1, 3 | v1 >>= 3;
0x000456a0 sll v1, v1, 3 | v1 <<= 3;
0x000456a4 lw t9, -0x7f7c(gp) | t9 = *((gp - 8159));
0x000456a8 subu sp, sp, v1 |
0x000456ac addiu v1, fp, 0x3c | v1 = fp + 0x3c;
0x000456b0 sw v1, 0x10(sp) | *(var_10h) = v1;
0x000456b4 move a0, s2 | a0 = s2;
0x000456b8 addiu a1, fp, 0x20 | a1 = fp + 0x20;
0x000456bc addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x000456c0 move a3, v0 | a3 = v0;
0x000456c4 bal 0x2cec0 | sym_getpwnam_r ();
0x000456c8 lw gp, 0x18(fp) | gp = *(var_18h);
| if (v0 != 0) {
0x000456cc bnez v0, 0x457d0 | goto label_1;
| }
0x000456d0 lw v0, 0x3c(fp) | v0 = *(arg_3ch);
0x000456d4 lw t9, -0x7fdc(gp) | t9 = *(var_7fdch);
| if (v0 == 0) {
0x000456d8 beqz v0, 0x457d0 | goto label_1;
| }
0x000456dc lw a0, 0x14(v0) | a0 = *((v0 + 5));
0x000456e0 bal 0x3b6e0 | sym_strlen ();
0x000456e4 lw gp, 0x18(fp) | gp = *(var_18h);
0x000456e8 lw t9, -0x759c(gp) | t9 = *(var_759ch);
0x000456ec addiu a0, v0, 9 | a0 = v0 + 9;
0x000456f0 jalr t9 | t9 ();
0x000456f4 move s1, v0 | s1 = v0;
0x000456f8 lw gp, 0x18(fp) | gp = *(var_18h);
0x000456fc move a0, v0 | a0 = v0;
0x00045700 lw v0, 0x3c(fp) | v0 = *(arg_3ch);
0x00045704 lw t9, -0x7f48(gp) | t9 = *(var_7f48h);
0x00045708 lw a1, 0x14(v0) | a1 = *((v0 + 5));
0x0004570c bal 0x3b630 | sym_strcpy ()
0x00045710 lw gp, 0x18(fp) | gp = *(var_18h);
0x00045714 move a0, s1 | a0 = s1;
0x00045718 lw a1, -0x7fd0(gp) | a1 = *(s2);
0x0004571c lw t9, -0x7e00(gp) | t9 = *(var_7e00h);
0x00045720 addiu a1, a1, 0x719c | a1 += 0x719c;
0x00045724 bal 0x3b3d0 | sym_strcat ();
0x00045728 lw gp, 0x18(fp) | gp = *(var_18h);
0x0004572c lw t9, -0x7aa8(gp) | t9 = *(var_7aa8h);
0x00045730 jalr t9 | t9 ();
0x00045734 nop |
0x00045738 move s6, v0 | s6 = v0;
0x0004573c lw gp, 0x18(fp) | gp = *(var_18h);
0x00045740 lw v0, 0x3c(fp) | v0 = *(arg_3ch);
0x00045744 lw t9, -0x79b8(gp) | t9 = *(var_79b8h);
0x00045748 lw a0, 8(v0) | a0 = *((v0 + 2));
0x0004574c jalr t9 | t9 ();
0x00045750 lw gp, 0x18(fp) | gp = *(var_18h);
0x00045754 lw v0, 0x3c(fp) | v0 = *(arg_3ch);
0x00045758 move a0, s1 | a0 = s1;
0x0004575c lw t9, -0x7b10(gp) | t9 = *(var_7b10h);
0x00045760 addiu t9, t9, 0x5030 | t9 += 0x5030;
0x00045764 lw a1, 8(v0) | a1 = *((v0 + 2));
0x00045768 bal 0x45030 | fcn_00045030 ();
0x0004576c lw gp, 0x18(fp) | gp = *(var_18h);
0x00045770 move s3, v0 | s3 = v0;
0x00045774 lw t9, -0x7664(gp) | t9 = *(var_7664h);
0x00045778 move a0, s1 | a0 = s1;
0x0004577c jalr t9 | t9 ();
0x00045780 lw gp, 0x18(fp) | gp = *(var_18h);
| if (s3 != 0) {
0x00045784 beqz s3, 0x457bc |
0x00045788 lw t9, -0x7b10(gp) | t9 = *(var_7b10h);
0x0004578c move a0, s3 | a0 = s3;
0x00045790 move a1, s5 | a1 = s5;
0x00045794 move a2, s2 | a2 = s2;
0x00045798 addiu t9, t9, 0x512c | t9 += 0x512c;
0x0004579c move a3, s4 | a3 = s4;
0x000457a0 bal 0x4512c | fcn_0004512c ();
0x000457a4 lw gp, 0x18(fp) | gp = *(var_18h);
0x000457a8 move a0, s3 | a0 = s3;
0x000457ac lw t9, -0x7dd0(gp) | t9 = *(var_7dd0h);
0x000457b0 move s0, v0 | s0 = v0;
0x000457b4 bal 0x2de70 | sym_fclose ();
0x000457b8 lw gp, 0x18(fp) | gp = *(var_18h);
| }
0x000457bc lw t9, -0x79b8(gp) | t9 = *(var_79b8h);
0x000457c0 move a0, s6 | a0 = s6;
0x000457c4 jalr t9 | t9 ();
0x000457c8 move sp, fp |
0x000457cc b 0x457d8 | goto label_2;
| }
| label_1:
0x000457d0 addiu s0, zero, -1 | s0 = -1;
| }
0x000457d4 move sp, fp |
| label_2:
0x000457d8 lw ra, 0x64(sp) | ra = *(var_64h);
0x000457dc move v0, s0 | v0 = s0;
0x000457e0 lw fp, 0x60(sp) | fp = *(var_60h);
0x000457e4 lw s6, 0x5c(sp) | s6 = *(var_5ch);
0x000457e8 lw s5, 0x58(sp) | s5 = *(var_58h);
0x000457ec lw s4, 0x54(sp) | s4 = *(var_54h);
0x000457f0 lw s3, 0x50(sp) | s3 = *(var_50h);
0x000457f4 lw s2, 0x4c(sp) | s2 = *(var_4ch);
0x000457f8 lw s1, 0x48(sp) | s1 = *(var_48h);
0x000457fc lw s0, 0x44(sp) | s0 = *(var_44h);
0x00045800 addiu sp, sp, 0x68 |
0x00045804 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x51f60 */
| #include <stdint.h>
|
; (fcn) fcn.00051f60 () | void fcn_00051f60 () {
0x00051f60 lui gp, 7 |
0x00051f64 addiu gp, gp, -0x880 |
0x00051f68 addu gp, gp, t9 | gp += t9;
0x00051f6c addiu sp, sp, -0x40 |
0x00051f70 move v1, zero | v1 = 0;
0x00051f74 move t1, zero | t1 = 0;
0x00051f78 sw s1, 0x38(sp) | *(var_38h) = s1;
0x00051f7c sw s0, 0x34(sp) | *(var_34h) = s0;
0x00051f80 sw gp, 0x10(sp) | *(var_10h) = gp;
0x00051f84 move s0, a1 | s0 = a1;
0x00051f88 sw ra, 0x3c(sp) | *(var_3ch) = ra;
0x00051f8c move s1, a2 | s1 = a2;
0x00051f90 sb zero, 0x18(sp) | *(var_18h) = 0;
0x00051f94 addiu t3, zero, 0x64 | t3 = 0x64;
0x00051f98 addiu t4, zero, 0x30 | t4 = 0x30;
0x00051f9c addiu a3, zero, 0xa | a3 = 0xa;
0x00051fa0 addiu a1, zero, 0x2e | a1 = 0x2e;
0x00051fa4 addiu v0, zero, 4 | v0 = 4;
| do {
0x00051fa8 addu a2, a0, t1 | a2 = a0 + t1;
0x00051fac lbu t0, (a2) | t0 = *(a2);
0x00051fb0 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x00051fb4 addu t6, a2, v1 | t6 = a2 + v1;
0x00051fb8 divu zero, t0, t3 | __asm ("divu zero, t0, t3");
0x00051fbc teq t3, zero, 7 | __asm ("teq t3, zero, 7");
0x00051fc0 mflo t2 | __asm ("mflo t2");
0x00051fc4 addiu t5, t2, 0x30 | t5 = t2 + 0x30;
0x00051fc8 andi t5, t5, 0xff | t5 &= 0xff;
0x00051fcc sb t5, (t6) | *(t6) = t5;
0x00051fd0 addiu t2, v1, 1 | t2 = v1 + 1;
| if (t5 == t4) {
0x00051fd4 bne t5, t4, 0x52004 |
0x00051fd8 divu zero, t0, a3 | __asm ("divu zero, t0, a3");
0x00051fdc teq a3, zero, 7 | __asm ("teq a3, zero, 7");
0x00051fe0 mflo t5 | __asm ("mflo t5");
0x00051fe4 divu zero, t5, a3 | __asm ("divu zero, t5, a3");
0x00051fe8 teq a3, zero, 7 | __asm ("teq a3, zero, 7");
0x00051fec mfhi t5 | __asm ("mfhi t5");
0x00051ff0 addiu t5, t5, 0x30 | t5 += 0x30;
0x00051ff4 sb t5, (t6) | *(t6) = t5;
0x00051ff8 xor t5, t5, t4 | t5 ^= t4;
| if (t5 == 0) {
0x00051ffc movn v1, t2, t5 | v1 = t2;
| }
0x00052000 b 0x52030 |
| } else {
0x00052004 divu zero, t0, a3 | __asm ("divu zero, t0, a3");
0x00052008 teq a3, zero, 7 | __asm ("teq a3, zero, 7");
0x0005200c addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x00052010 addu t2, a2, t2 | t2 = a2 + t2;
0x00052014 addiu v1, v1, 2 | v1 += 2;
0x00052018 mflo t5 | __asm ("mflo t5");
0x0005201c divu zero, t5, a3 | __asm ("divu zero, t5, a3");
0x00052020 teq a3, zero, 7 | __asm ("teq a3, zero, 7");
0x00052024 mfhi a2 | __asm ("mfhi a2");
0x00052028 addiu a2, a2, 0x30 | a2 += 0x30;
0x0005202c sb a2, (t2) | *(t2) = a2;
| }
0x00052030 divu zero, t0, a3 | __asm ("divu zero, t0, a3");
0x00052034 teq a3, zero, 7 | __asm ("teq a3, zero, 7");
0x00052038 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x0005203c addu t2, a2, v1 | t2 = a2 + v1;
0x00052040 addiu t1, t1, 1 | t1++;
0x00052044 sb a1, 1(t2) | *(var_1h) = a1;
0x00052048 addiu v1, v1, 2 | v1 += 2;
0x0005204c mfhi a2 | __asm ("mfhi a2");
0x00052050 addiu t0, a2, 0x30 | t0 = a2 + 0x30;
0x00052054 sb t0, (t2) | *(t2) = t0;
0x00052058 bne t1, v0, 0x51fa8 |
| } while (t1 != v0);
0x0005205c addiu t2, sp, 0x18 | t2 = sp + 0x18;
0x00052060 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00052064 addu v1, t2, v1 | v1 = t2 + v1;
0x00052068 sb zero, -1(v1) | *(var_1h) = 0;
0x0005206c move a0, t2 | a0 = t2;
0x00052070 bal 0x3b6e0 | sym_strlen ();
0x00052074 sltu v0, s1, v0 | v0 = (s1 < v0) ? 1 : 0;
0x00052078 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x0005207c beqz v0, 0x520a0 |
0x00052080 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00052084 move v0, v1 | v0 = v1;
0x00052088 lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x0005208c addu v0, v1, v0 | v0 = v1 + v0;
0x00052090 addiu v1, zero, 0x1c | v1 = 0x1c;
0x00052094 sw v1, (v0) | *(v0) = v1;
0x00052098 move v0, zero | v0 = 0;
0x0005209c b 0x520b0 |
| } else {
0x000520a0 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x000520a4 move a0, s0 | a0 = s0;
0x000520a8 addiu a1, sp, 0x18 | a1 = sp + 0x18;
0x000520ac bal 0x3b630 | sym_strcpy ()
| }
0x000520b0 lw ra, 0x3c(sp) | ra = *(var_3ch);
0x000520b4 lw s1, 0x38(sp) | s1 = *(var_38h);
0x000520b8 lw s0, 0x34(sp) | s0 = *(var_34h);
0x000520bc addiu sp, sp, 0x40 |
0x000520c0 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x532e0 */
| #include <stdint.h>
|
; (fcn) fcn.000532e0 () | void fcn_000532e0 () {
0x000532e0 lui gp, 7 |
0x000532e4 addiu gp, gp, -0x1c00 |
0x000532e8 addu gp, gp, t9 | gp += t9;
0x000532ec lw t9, -0x759c(gp) | t9 = *((gp - 7527));
0x000532f0 addiu sp, sp, -0x200 |
0x000532f4 sw gp, 0x18(sp) | *(var_18h) = gp;
0x000532f8 sw ra, 0x1fc(sp) | *(var_1fch) = ra;
0x000532fc sw fp, 0x1f8(sp) | *(var_1f8h) = fp;
0x00053300 sw s6, 0x1f0(sp) | *(var_1f0h) = s6;
0x00053304 sw s2, 0x1e0(sp) | *(var_1e0h) = s2;
0x00053308 sw s1, 0x1dc(sp) | *(var_1dch) = s1;
0x0005330c sw s0, 0x1d8(sp) | *(var_1d8h) = s0;
0x00053310 move s1, a0 | s1 = a0;
0x00053314 sw a2, 0x208(sp) | *(arg_208h) = a2;
0x00053318 addiu a0, zero, 0x200 | a0 = aav.0x00000200;
0x0005331c sw s7, 0x1f4(sp) | *(var_1f4h) = s7;
0x00053320 sw s5, 0x1ec(sp) | *(var_1ech) = s5;
0x00053324 sw s4, 0x1e8(sp) | *(var_1e8h) = s4;
0x00053328 sw s3, 0x1e4(sp) | *(var_1e4h) = s3;
0x0005332c move fp, a1 | fp = a1;
0x00053330 move s0, a3 | s0 = a3;
0x00053334 jalr t9 | t9 ();
0x00053338 lw gp, 0x18(sp) | gp = *(var_18h);
0x0005333c move a0, s1 | a0 = s1;
0x00053340 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00053344 move s2, v0 | s2 = v0;
0x00053348 bal 0x3b6e0 | sym_strlen ();
0x0005334c move s6, v0 | s6 = v0;
0x00053350 sltiu v0, v0, 0x37f | v0 = (v0 < 0x37f) ? 1 : 0;
0x00053354 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 == 0) {
0x00053358 bnez v0, 0x53364 |
0x0005335c move s4, zero | s4 = 0;
0x00053360 b 0x53aa0 | goto label_6;
| }
0x00053364 lw t9, -0x759c(gp) | t9 = *((gp - 7527));
0x00053368 addiu a0, s6, 0x82 | a0 = s6 + 0x82;
0x0005336c jalr t9 | t9 ();
0x00053370 move s4, v0 | s4 = v0;
0x00053374 lw gp, 0x18(sp) | gp = *(var_18h);
| if (s2 == 0) {
0x00053378 beqz s2, 0x53aa0 | goto label_6;
| }
| if (v0 == 0) {
0x0005337c beql v0, zero, 0x53aa0 | goto label_6;
| }
0x00053380 move s4, zero | s4 = 0;
0x00053384 lbu v0, (s1) | v0 = *(s1);
0x00053388 addu v0, s1, s6 | v0 = s1 + s6;
| if (v0 == 0) {
0x0005338c beqz v0, 0x53aa0 | goto label_6;
| }
0x00053390 lbu v0, -1(v0) | v0 = *((v0 - 1));
0x00053394 lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00053398 move a0, s4 | a0 = s4;
0x0005339c sw v0, 0x1bc(sp) | *(var_1bch) = v0;
0x000533a0 move a1, s1 | a1 = s1;
0x000533a4 move a2, s6 | a2 = s6;
0x000533a8 bal 0x3a830 | sym_memcpy ();
0x000533ac addiu v0, s6, 1 | v0 = s6 + 1;
0x000533b0 addu v0, s4, v0 | v0 = s4 + v0;
0x000533b4 lw gp, 0x18(sp) | gp = *(var_18h);
0x000533b8 addiu s3, zero, -1 | s3 = -1;
0x000533bc addiu s7, zero, -1 | s7 = -1;
0x000533c0 sw zero, 0x1b8(sp) | *(var_1b8h) = 0;
0x000533c4 sw v0, 0x1c0(sp) | *(dest) = v0;
0x000533c8 b 0x533e0 | goto label_7;
| label_5:
0x000533cc lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| if (s1 != v0) {
0x000533d0 beq s1, v0, 0x533e0 |
0x000533d4 move a0, s1 | a0 = s1;
0x000533d8 bal 0x620b8 | sym_libc_close ();
0x000533dc lw gp, 0x18(sp) | gp = *(var_18h);
| }
| label_7:
0x000533e0 lw a1, -0x75cc(gp) | a1 = *((gp - 7539));
0x000533e4 lw a2, -0x75d0(gp) | a2 = *((gp - 7540));
0x000533e8 lw t9, -0x7600(gp) | t9 = *((gp - 7552));
0x000533ec addiu a0, sp, 0x20 | a0 = sp + 0x20;
0x000533f0 jalr t9 | t9 ();
0x000533f4 lw gp, 0x18(sp) | gp = *(var_18h);
0x000533f8 lw a0, -0x75d0(gp) | a0 = *((gp - 7540));
0x000533fc lw t9, -0x7588(gp) | t9 = *((gp - 7522));
0x00053400 jalr t9 | t9 ();
0x00053404 nop |
0x00053408 lw gp, 0x18(sp) | gp = *(var_18h);
0x0005340c lw t9, -0x7858(gp) | t9 = *((gp - 7702));
0x00053410 bal 0x53bf0 | fcn_00053bf0 ();
0x00053414 nop |
0x00053418 lw gp, 0x18(sp) | gp = *(var_18h);
0x0005341c lw v0, -0x7854(gp) | v0 = *((gp - 7701));
0x00053420 lw v0, (v0) | v0 = *(v0);
0x00053424 sw v0, 0x1b4(sp) | *(var_1b4h) = v0;
0x00053428 lw t9, 0x1b4(sp) | t9 = *(var_1b4h);
0x0005342c sltu v1, s7, t9 | v1 = (s7 < t9) ? 1 : 0;
0x00053430 addu v0, s4, s6 | v0 = s4 + s6;
| if (v1 == 0) {
0x00053434 bnez v1, 0x53440 |
0x00053438 sb zero, (v0) | *(v0) = 0;
0x0005343c b 0x5346c |
| } else {
0x00053440 addiu v1, zero, 0x2e | v1 = 0x2e;
0x00053444 sb v1, (v0) | *(v0) = v1;
0x00053448 lw v0, -0x7850(gp) | v0 = *((gp - 7700));
0x0005344c lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00053450 lw a0, 0x1c0(sp) | a0 = *(dest);
0x00053454 lw v1, (v0) | v1 = *(v0);
0x00053458 sll v0, s7, 2 | v0 = s7 << 2;
0x0005345c addu v0, v1, v0 | v0 = v1 + v0;
0x00053460 lw a1, (v0) | a1 = *(v0);
0x00053464 bal 0x3b630 | sym_strcpy ()
0x00053468 lw gp, 0x18(sp) | gp = *(var_18h);
| }
0x0005346c lw v0, -0x784c(gp) | v0 = *((gp - 7699));
| if (s3 < 0) {
0x00053470 bgez s3, 0x534a4 |
0x00053474 lw v0, -0x7ed0(gp) | v0 = *((gp - 8116));
0x00053478 lw v1, -0x7ed0(gp) | v1 = *((gp - 8116));
0x0005347c lhu v0, -0x6a80(v0) | v0 = *((v0 - 13632));
0x00053480 lw s3, -0x2310(v1) | s3 = *((v1 - 2244));
0x00053484 sw v0, 0x1b0(sp) | *(var_1b0h) = v0;
0x00053488 lw v0, -0x7848(gp) | v0 = *((gp - 7698));
0x0005348c lbu v1, (v0) | v1 = *(v0);
0x00053490 lw v0, -0x784c(gp) | v0 = *((gp - 7699));
0x00053494 lw v0, (v0) | v0 = *(v0);
0x00053498 mul a0, v1, v0 | __asm ("mul a0, v1, v0");
0x0005349c sw a0, 0x1b8(sp) | *(var_1b8h) = a0;
0x000534a0 lw v0, -0x784c(gp) | v0 = *((gp - 7699));
| }
0x000534a4 lw v1, 0x1b0(sp) | v1 = *(var_1b0h);
0x000534a8 addiu a1, zero, 0x1c | a1 = 0x1c;
0x000534ac lw v0, (v0) | v0 = *(v0);
0x000534b0 lw a0, -0x7ed0(gp) | a0 = *((gp - 8116));
0x000534b4 lw t9, 0x1b8(sp) | t9 = *(var_1b8h);
0x000534b8 sltu v0, s3, v0 | v0 = (s3 < v0) ? 1 : 0;
| if (v0 != 0) {
0x000534bc movz s3, zero, v0 | s3 = 0;
| }
0x000534c0 addiu v0, v1, 1 | v0 = v1 + 1;
0x000534c4 mul v1, s3, a1 | __asm ("mul v1, s3, a1");
0x000534c8 andi v0, v0, 0xffff | v0 &= 0xffff;
0x000534cc sh v0, -0x6a80(a0) | *((a0 - 13632)) = v0;
0x000534d0 addiu t9, t9, -1 | t9 += -1;
0x000534d4 sw v0, 0x1b0(sp) | *(var_1b0h) = v0;
0x000534d8 lw v0, -0x7844(gp) | v0 = *((gp - 7697));
0x000534dc sw t9, 0x1b8(sp) | *(var_1b8h) = t9;
0x000534e0 lw t9, -0x7ed0(gp) | t9 = *((gp - 8116));
0x000534e4 lw v0, (v0) | v0 = *(v0);
0x000534e8 addiu a2, zero, 0x1c | a2 = 0x1c;
0x000534ec sw s3, -0x2310(t9) | *((t9 - 8976)) = s3;
0x000534f0 lw t9, -0x7598(gp) | t9 = *((gp - 7526));
0x000534f4 addiu a0, sp, 0x178 | a0 = sp + aav.0x00000178;
0x000534f8 addu a1, v1, v0 | a1 = v1 + v0;
0x000534fc jalr t9 | t9 ();
0x00053500 lw gp, 0x18(sp) | gp = *(var_18h);
0x00053504 addiu a0, sp, 0x20 | a0 = sp + 0x20;
0x00053508 lw t9, -0x75a8(gp) | t9 = *((gp - 7530));
0x0005350c addiu a1, zero, 1 | a1 = 1;
0x00053510 jalr t9 | t9 ();
0x00053514 lw gp, 0x18(sp) | gp = *(var_18h);
0x00053518 move a0, s2 | a0 = s2;
0x0005351c move a1, zero | a1 = 0;
0x00053520 lw s1, -0x7fe4(gp) | s1 = *((gp - 8185));
0x00053524 move t9, s1 | t9 = s1;
0x00053528 addiu a2, zero, 0x200 | a2 = aav.0x00000200;
0x0005352c bal 0x3a970 | sym_memset ();
0x00053530 addiu v1, sp, 0x120 | v1 = sp + aav.0x00000120;
0x00053534 move a0, v1 | a0 = v1;
0x00053538 move t9, s1 | t9 = s1;
0x0005353c sw v1, 0x1a8(sp) | *(var_1a8h) = v1;
0x00053540 move a1, zero | a1 = 0;
0x00053544 addiu a2, zero, 0x30 | a2 = 0x30;
0x00053548 bal 0x3a970 | sym_memset ();
0x0005354c lw gp, 0x18(sp) | gp = *(var_18h);
0x00053550 lw v1, 0x1b0(sp) | v1 = *(var_1b0h);
0x00053554 addiu s1, zero, 1 | s1 = 1;
0x00053558 lw t9, -0x7840(gp) | t9 = *((gp - 7696));
0x0005355c sw v1, 0x120(sp) | *(var_120h) = v1;
0x00053560 sw s1, 0x140(sp) | *(var_140h) = s1;
0x00053564 sw s1, 0x134(sp) | *(var_134h) = s1;
0x00053568 addiu a0, sp, 0x120 | a0 = sp + aav.0x00000120;
0x0005356c move a1, s2 | a1 = s2;
0x00053570 addiu a2, zero, 0x200 | a2 = aav.0x00000200;
0x00053574 bal 0x52a30 | fcn_00052a30 ();
0x00053578 move s5, v0 | s5 = v0;
0x0005357c lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 < 0) {
0x00053580 bltz v0, 0x53aa0 | goto label_6;
| }
0x00053584 lw t9, -0x783c(gp) | t9 = *((gp - 7695));
0x00053588 addiu a2, zero, 0x200 | a2 = aav.0x00000200;
0x0005358c sw s4, 0x194(sp) | *(var_194h) = s4;
0x00053590 sw fp, 0x198(sp) | *(var_198h) = fp;
0x00053594 sw s1, 0x19c(sp) | *(var_19ch) = s1;
0x00053598 addiu a0, sp, 0x194 | a0 = sp + aav.0x00000194;
0x0005359c addu a1, s2, v0 | a1 = s2 + v0;
0x000535a0 subu a2, a2, v0 | __asm ("subu a2, a2, v0");
0x000535a4 bal 0x52e90 | fcn_00052e90 ();
0x000535a8 sw v0, 0x1ac(sp) | *(length) = v0;
0x000535ac lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 < 0) {
0x000535b0 bltz v0, 0x53aa0 | goto label_6;
| }
0x000535b4 lw t9, -0x7d44(gp) | t9 = *((gp - 8017));
0x000535b8 lhu a0, 0x178(sp) | a0 = *(domain);
0x000535bc addiu a1, zero, 1 | a1 = 1;
0x000535c0 addiu a2, zero, 0x11 | a2 = 0x11;
0x000535c4 bal 0x584a0 | sym_socket ();
0x000535c8 move s1, v0 | s1 = v0;
0x000535cc lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 < 0) {
0x000535d0 bltz v0, 0x53a84 | goto label_8;
| }
0x000535d4 lw t9, -0x7d40(gp) | t9 = *((gp - 8016));
0x000535d8 move a0, v0 | a0 = v0;
0x000535dc addiu a1, sp, 0x178 | a1 = sp + aav.0x00000178;
0x000535e0 addiu a2, zero, 0x1c | a2 = 0x1c;
0x000535e4 bal 0x57bc0 | sym_connect ();
0x000535e8 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 < 0) {
0x000535ec bltz v0, 0x53a84 | goto label_8;
| }
0x000535f0 lw t9, 0x1ac(sp) | t9 = *(length);
0x000535f4 move a0, s1 | a0 = s1;
0x000535f8 move a1, s2 | a1 = s2;
0x000535fc addu a2, s5, t9 | a2 = s5 + t9;
0x00053600 lw t9, -0x7d30(gp) | t9 = *((gp - 8012));
0x00053604 move a3, zero | a3 = 0;
0x00053608 bal 0x580e0 | sym_send ();
0x0005360c lw gp, 0x18(sp) | gp = *(var_18h);
0x00053610 lw v0, -0x7838(gp) | v0 = *((gp - 7694));
0x00053614 lbu v1, (v0) | v1 = *(v0);
0x00053618 addiu v0, zero, 0x3e8 | v0 = aav.0x000003e8;
0x0005361c mul a0, v1, v0 | __asm ("mul a0, v1, v0");
0x00053620 sw a0, 0x1ac(sp) | *(length) = a0;
0x00053624 lw t9, -0x7a40(gp) | t9 = *((gp - 7824));
| do {
0x00053628 lw a2, 0x1ac(sp) | a2 = *(length);
0x0005362c addiu v0, zero, 1 | v0 = 1;
0x00053630 sw s1, 0x1a0(sp) | *(var_1a0h) = s1;
0x00053634 sh v0, 0x1a4(sp) | *(var_1a4h) = v0;
0x00053638 addiu a0, sp, 0x1a0 | a0 = sp + aav.0x000001a0;
0x0005363c addiu a1, zero, 1 | a1 = 1;
0x00053640 jalr t9 | t9 ();
0x00053644 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 <= 0) {
0x00053648 blez v0, 0x53a84 | goto label_8;
| }
0x0005364c lw v1, 0x1ac(sp) | v1 = *(length);
0x00053650 lw t9, -0x7834(gp) | t9 = *((gp - 7693));
0x00053654 move a0, s1 | a0 = s1;
0x00053658 addiu v1, v1, -0x3e8 | v1 += -aav.0x000003e8;
0x0005365c sw v1, 0x1ac(sp) | *(length) = v1;
0x00053660 move a1, s2 | a1 = s2;
0x00053664 addiu a2, zero, 0x200 | a2 = aav.0x00000200;
0x00053668 addiu a3, zero, 0x40 | a3 = 0x40;
0x0005366c bal 0x57db0 | sym_recv ();
0x00053670 move s5, v0 | s5 = v0;
0x00053674 slti v0, v0, 0xc | v0 = (v0 < 0xc) ? 1 : 0;
0x00053678 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 == 0) {
0x0005367c beqz v0, 0x5369c | goto label_9;
| }
| if (s5 < 0) {
0x00053680 bltzl s5, 0x53a88 | goto label_10;
| }
0x00053684 addiu s3, s3, 1 | s3++;
| label_0:
0x00053688 lw v1, 0x1ac(sp) | v1 = *(length);
| label_1:
0x0005368c lw t9, -0x7a40(gp) | t9 = *((gp - 7824));
0x00053690 bnez v1, 0x53628 |
| } while (v1 != 0);
0x00053694 addiu s3, s3, 1 | s3++;
0x00053698 b 0x53a88 | goto label_10;
| label_9:
0x0005369c lw t9, -0x7830(gp) | t9 = *((gp - 7692));
0x000536a0 move a0, s2 | a0 = s2;
0x000536a4 addiu a1, sp, 0x120 | a1 = sp + aav.0x00000120;
0x000536a8 bal 0x52b10 | fcn_00052b10 ();
0x000536ac lw v0, 0x120(sp) | v0 = *(var_120h);
0x000536b0 lw v1, 0x1b0(sp) | v1 = *(var_1b0h);
0x000536b4 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 != v1) {
0x000536b8 bne v0, v1, 0x53688 | goto label_0;
| }
0x000536bc lw v0, 0x124(sp) | v0 = *(var_124h);
0x000536c0 lw v1, 0x1ac(sp) | v1 = *(length);
| if (v0 == 0) {
0x000536c4 beqz v0, 0x5368c | goto label_1;
| }
0x000536c8 lw v0, 0x13c(sp) | v0 = *(var_13ch);
0x000536cc addiu v1, v0, -2 | v1 = v0 + -2;
0x000536d0 sltiu v1, v1, 2 | v1 = (v1 < 2) ? 1 : 0;
0x000536d4 lw t9, 0x1bc(sp) | t9 = *(var_1bch);
| if (v1 != 0) {
0x000536d8 beqz v1, 0x53714 |
0x000536dc addiu v0, zero, 0x2e | v0 = 0x2e;
| if (t9 != v0) {
0x000536e0 beq t9, v0, 0x536fc |
0x000536e4 nop |
0x000536e8 lw v1, 0x1b4(sp) | v1 = *(var_1b4h);
0x000536ec addiu v0, v1, -1 | v0 = v1 + -1;
0x000536f0 slt v0, s7, v0 | v0 = (s7 < v0) ? 1 : 0;
0x000536f4 addiu s7, s7, 1 | s7++;
| if (v0 != 0) {
0x000536f8 bnez v0, 0x53a8c | goto label_11;
| }
| }
0x000536fc rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00053700 move v0, v1 | v0 = v1;
0x00053704 lw v1, -0x756c(gp) | v1 = *((gp - 7515));
0x00053708 addu v0, v1, v0 | v0 = v1 + v0;
0x0005370c addiu v1, zero, 1 | v1 = 1;
0x00053710 b 0x5373c |
| } else {
0x00053714 addiu s3, s3, 1 | s3++;
| if (v0 == 0) {
0x00053718 bnel v0, zero, 0x53a88 | goto label_10;
| }
0x0005371c lw v0, 0x144(sp) | v0 = *(var_144h);
0x00053720 addiu s7, zero, 0xc | s7 = 0xc;
| if (v0 > 0) {
0x00053724 bgtz v0, 0x537a8 | goto label_12;
| }
0x00053728 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x0005372c move v0, v1 | v0 = v1;
0x00053730 lw v1, -0x756c(gp) | v1 = *((gp - 7515));
0x00053734 addu v0, v1, v0 | v0 = v1 + v0;
0x00053738 addiu v1, zero, 4 | v1 = 4;
| }
0x0005373c sw v1, (v0) | *(v0) = v1;
0x00053740 b 0x53ac0 | goto label_13;
| label_2:
0x00053744 subu v0, s5, s7 | __asm ("subu v0, s5, s7");
| if (a2 == 0) {
0x00053748 beqz a2, 0x53a84 | goto label_8;
| }
0x0005374c move a0, a2 | a0 = a2;
| if (v0 <= 0) {
| do {
0x00053750 blezl v0, 0x53a88 | goto label_10;
| }
0x00053754 addiu s3, s3, 1 | s3++;
0x00053758 lbu v1, (a0) | v1 = *(a0);
0x0005375c addiu a3, a0, 1 | a3 = a0 + 1;
| if (v1 == 0) {
0x00053760 beqz v1, 0x53788 | goto label_14;
| }
0x00053764 and t3, v1, t1 | t3 = v1 & t1;
0x00053768 addu a0, a3, v1 | a0 = a3 + v1;
| if (t3 != t2) {
0x0005376c bnel t3, t2, 0x5377c |
0x00053770 addiu a3, a0, 2 | a3 = a0 + 2;
0x00053774 addiu v0, v0, -2 | v0 += -2;
0x00053778 b 0x53788 |
| } else {
0x0005377c nor v1, zero, v1 | __asm ("nor v1, zero, v1");
0x00053780 addu v0, v1, v0 | v0 = v1 + v0;
0x00053784 b 0x53750 |
| }
| } while (1);
| label_14:
0x00053788 slti v0, v0, 4 | v0 = (v0 < 4) ? 1 : 0;
0x0005378c subu a2, a3, a2 | __asm ("subu a2, a3, a2");
| if (v0 != 0) {
0x00053790 bnez v0, 0x53a84 | goto label_8;
| }
0x00053794 addiu a2, a2, 4 | a2 += 4;
0x00053798 addu s7, s7, a2 | s7 += a2;
| if (a2 < 0) {
0x0005379c bltz a2, 0x53a84 | goto label_8;
| }
0x000537a0 addiu a1, a1, 1 | a1++;
0x000537a4 b 0x537b4 | goto label_15;
| label_12:
0x000537a8 move a1, zero | a1 = 0;
0x000537ac addiu t1, zero, -0x40 | t1 = -0x40;
0x000537b0 addiu t2, zero, 0xc0 | t2 = 0xc0;
| label_15:
0x000537b4 lw v0, 0x140(sp) | v0 = *(var_140h);
0x000537b8 slt v0, a1, v0 | v0 = (a1 < v0) ? 1 : 0;
0x000537bc addu a2, s2, s7 | a2 = s2 + s7;
| if (v0 != 0) {
0x000537c0 bnez v0, 0x53744 | goto label_2;
| }
0x000537c4 addiu t9, zero, 1 | t9 = 1;
0x000537c8 sw zero, (s0) | *(s0) = 0;
0x000537cc sw t9, 0x1b4(sp) | *(var_1b4h) = t9;
0x000537d0 sw zero, 0x1ac(sp) | *(length) = 0;
0x000537d4 b 0x53a3c | goto label_16;
| label_4:
0x000537d8 addiu v0, zero, 0x100 | v0 = aav.0x00000100;
0x000537dc sw v0, 0x10(sp) | *(var_10h) = v0;
0x000537e0 move a0, s2 | a0 = s2;
0x000537e4 move a1, s7 | a1 = s7;
0x000537e8 move a2, s5 | a2 = s5;
0x000537ec addiu a3, sp, 0x20 | a3 = sp + 0x20;
0x000537f0 bal 0x52d00 | fcn_00052d00 ();
0x000537f4 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 >= 0) {
0x000537f8 bltz v0, 0x538e4 |
0x000537fc addiu a2, zero, -0xa | a2 = -0xa;
0x00053800 subu a2, a2, v0 | __asm ("subu a2, a2, v0");
0x00053804 subu a2, a2, s7 | __asm ("subu a2, a2, s7");
0x00053808 addu a2, s5, a2 | a2 = s5 + a2;
0x0005380c addu a3, s7, v0 | a3 = s7 + v0;
| if (a2 >= 0) {
0x00053810 bltz a2, 0x538d8 |
0x00053814 lw t9, -0x7fac(gp) | t9 = *((gp - 8171));
0x00053818 addu v1, s2, a3 | v1 = s2 + a3;
0x0005381c addiu a0, sp, 0x20 | a0 = sp + 0x20;
0x00053820 sw v1, 0x1cc(sp) | *(var_1cch) = v1;
0x00053824 sw a2, 0x1d0(sp) | *(var_1d0h) = a2;
0x00053828 sw a3, 0x1c8(sp) | *(var_1c8h) = a3;
0x0005382c sw v0, 0x1c4(sp) | *(var_1c4h) = v0;
0x00053830 bal 0x3c470 | sym_strdup ();
0x00053834 lw v1, 0x1cc(sp) | v1 = *(var_1cch);
0x00053838 sw v0, 0x150(sp) | *(s2) = v0;
0x0005383c lw a3, 0x1c8(sp) | a3 = *(var_1c8h);
0x00053840 lbu v0, (v1) | v0 = *(v1);
0x00053844 lbu a0, 1(v1) | a0 = *((v1 + 1));
0x00053848 lw a2, 0x1d0(sp) | a2 = *(var_1d0h);
0x0005384c sll v0, v0, 8 | v0 <<= 8;
0x00053850 or v0, v0, a0 | v0 |= a0;
0x00053854 sw v0, 0x154(sp) | *(var_154h) = v0;
0x00053858 lbu v0, 2(v1) | v0 = *((v1 + 2));
0x0005385c lbu a0, 3(v1) | a0 = *((v1 + 3));
0x00053860 addiu a3, a3, 0xa | a3 += 0xa;
0x00053864 sll v0, v0, 8 | v0 <<= 8;
0x00053868 or v0, v0, a0 | v0 |= a0;
0x0005386c sw v0, 0x158(sp) | *(var_158h) = v0;
0x00053870 lbu a0, 4(v1) | a0 = *((v1 + 4));
0x00053874 lbu v0, 5(v1) | v0 = *((v1 + 5));
0x00053878 addiu v1, v1, 0xa | v1 += 0xa;
0x0005387c sll a0, a0, 0x18 | a0 <<= 0x18;
0x00053880 sll v0, v0, 0x10 | v0 <<= 0x10;
0x00053884 or v0, a0, v0 | v0 = a0 | v0;
0x00053888 lbu a0, -3(v1) | a0 = *((v1 - 3));
0x0005388c lw gp, 0x18(sp) | gp = *(var_18h);
0x00053890 lw a1, 0x1c4(sp) | a1 = *(var_1c4h);
0x00053894 or v0, v0, a0 | v0 |= a0;
0x00053898 lbu a0, -4(v1) | a0 = *((v1 - 4));
0x0005389c sll a0, a0, 8 | a0 <<= 8;
0x000538a0 or v0, v0, a0 | v0 |= a0;
0x000538a4 sw v0, 0x15c(sp) | *(var_15ch) = v0;
0x000538a8 lbu v0, -2(v1) | v0 = *((v1 - 2));
0x000538ac lbu a0, -1(v1) | a0 = *((v1 - 1));
0x000538b0 sw v1, 0x164(sp) | *(var_164h) = v1;
0x000538b4 sll v0, v0, 8 | v0 <<= 8;
0x000538b8 or v0, v0, a0 | v0 |= a0;
0x000538bc slt a2, a2, v0 | a2 = (a2 < v0) ? 1 : 0;
0x000538c0 sw v0, 0x160(sp) | *(var_160h) = v0;
0x000538c4 sw a3, 0x168(sp) | *(c) = a3;
| if (a2 != 0) {
0x000538c8 bnez a2, 0x538e4 | goto label_17;
| }
0x000538cc addiu a1, a1, 0xa | a1 += 0xa;
0x000538d0 addu a1, a1, v0 | a1 += v0;
0x000538d4 b 0x538dc |
| } else {
0x000538d8 move a1, a2 | a1 = a2;
| }
0x000538dc lw v1, 0x1b4(sp) | v1 = *(var_1b4h);
| if (a1 >= 0) {
0x000538e0 bgez a1, 0x5391c | goto label_18;
| }
| }
| label_17:
0x000538e4 lw v1, 0x1ac(sp) | v1 = *(length);
0x000538e8 addiu s3, s3, 1 | s3++;
| if (v1 == 0) {
0x000538ec beqz v1, 0x53a88 | goto label_10;
| }
0x000538f0 lw v0, 0x130(sp) | v0 = *(var_130h);
0x000538f4 addiu s7, zero, -1 | s7 = -1;
| if (v0 == 0) {
0x000538f8 beqz v0, 0x53a8c | goto label_11;
| }
| do {
0x000538fc lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| label_3:
0x00053900 move a0, s1 | a0 = s1;
0x00053904 bal 0x620b8 | sym_libc_close ();
0x00053908 lw t9, 0x208(sp) | t9 = *(arg_208h);
0x0005390c lw gp, 0x18(sp) | gp = *(var_18h);
| if (t9 != 0) {
0x00053910 bnez t9, 0x53a58 | goto label_19;
| }
0x00053914 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00053918 b 0x53a64 | goto label_20;
| label_18:
0x0005391c addu s7, s7, a1 | s7 += a1;
| if (v1 == 0) {
0x00053920 beqz v1, 0x539cc | goto label_21;
| }
0x00053924 lw v0, 0x1c(s0) | v0 = *((s0 + 7));
0x00053928 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x0005392c lw a0, (s0) | a0 = *(s0);
0x00053930 sw v0, 0x16c(sp) | *(var_16ch) = v0;
0x00053934 lw v0, 0x20(s0) | v0 = *((s0 + 8));
0x00053938 sw v0, 0x170(sp) | *(var_170h) = v0;
0x0005393c lw v0, 0x24(s0) | v0 = *((s0 + 9));
0x00053940 sw v0, 0x174(sp) | *(var_174h) = v0;
0x00053944 jalr t9 | t9 ();
0x00053948 lw gp, 0x18(sp) | gp = *(var_18h);
0x0005394c move a0, s0 | a0 = s0;
0x00053950 addiu a1, sp, 0x150 | a1 = sp + aav.0x00000150;
0x00053954 lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00053958 addiu a2, zero, 0x28 | a2 = 0x28;
0x0005395c bal 0x3a830 | sym_memcpy ();
0x00053960 lw v0, 4(s0) | v0 = *((s0 + 1));
0x00053964 addiu v1, zero, 0x18 | v1 = 0x18;
0x00053968 lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 == v1) {
0x0005396c beq v0, v1, 0x5398c | goto label_22;
| }
0x00053970 lw v1, 0x1c(s0) | v1 = *((s0 + 7));
0x00053974 addiu v1, zero, 1 | v1 = 1;
0x00053978 beqz v1, 0x538fc |
| } while (v1 == 0);
0x0005397c addiu v1, zero, 0x1c | v1 = 0x1c;
| if (fp == v1) {
0x00053980 beq fp, v1, 0x5398c | goto label_22;
| }
0x00053984 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| if (fp != v1) {
0x00053988 bne fp, v1, 0x53900 | goto label_3;
| }
| label_22:
0x0005398c lw v1, 0x1ac(sp) | v1 = *(length);
| if (v0 != fp) {
0x00053990 bne v0, fp, 0x53a34 | goto label_23;
| }
0x00053994 lw v0, 0x144(sp) | v0 = *(var_144h);
0x00053998 subu v0, v0, v1 | __asm ("subu v0, v0, v1");
0x0005399c lw v1, 0x10(s0) | v1 = *((s0 + 4));
0x000539a0 addiu v0, v0, -1 | v0 += -1;
0x000539a4 sw v0, 0x24(s0) | *((s0 + 9)) = v0;
0x000539a8 addiu v1, v1, 4 | v1 += 4;
0x000539ac mul v0, v0, v1 | __asm ("mul v0, v0, v1");
0x000539b0 lw v1, 0x20(s0) | v1 = *((s0 + 8));
0x000539b4 sltu v0, v1, v0 | v0 = (v1 < v0) ? 1 : 0;
0x000539b8 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
| if (v0 != 0) {
0x000539bc bnez v0, 0x53900 | goto label_3;
| }
0x000539c0 sw zero, 0x24(s0) | *((s0 + 9)) = 0;
0x000539c4 sw zero, 0x1b4(sp) | *(var_1b4h) = 0;
0x000539c8 b 0x53a30 | goto label_24;
| label_21:
0x000539cc lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x000539d0 lw a0, 0x150(sp) | a0 = *(s2);
0x000539d4 jalr t9 | t9 ();
0x000539d8 lw v0, 0x154(sp) | v0 = *(var_154h);
0x000539dc lw gp, 0x18(sp) | gp = *(var_18h);
| if (v0 == fp) {
0x000539e0 bne v0, fp, 0x53a30 |
0x000539e4 lw a2, 0x10(s0) | a2 = *((s0 + 4));
0x000539e8 lw v0, 0x160(sp) | v0 = *(var_160h);
| if (a2 != v0) {
0x000539ec beql a2, v0, 0x53a08 |
0x000539f0 lw a0, 0x24(s0) | a0 = *((s0 + 9));
0x000539f4 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x000539f8 lw a0, (s0) | a0 = *(s0);
0x000539fc jalr t9 | t9 ();
0x00053a00 lw gp, 0x18(sp) | gp = *(var_18h);
0x00053a04 b 0x53a84 | goto label_8;
| }
0x00053a08 lw v0, 0x1c(s0) | v0 = *((s0 + 7));
0x00053a0c lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00053a10 mul v1, a2, a0 | __asm ("mul v1, a2, a0");
0x00053a14 lw a1, 0x164(sp) | a1 = *(var_164h);
0x00053a18 addu a0, v1, v0 | a0 = v1 + v0;
0x00053a1c bal 0x3a830 | sym_memcpy ();
0x00053a20 lw v0, 0x24(s0) | v0 = *((s0 + 9));
0x00053a24 lw gp, 0x18(sp) | gp = *(var_18h);
0x00053a28 addiu v0, v0, 1 | v0++;
0x00053a2c sw v0, 0x24(s0) | *((s0 + 9)) = v0;
| }
| label_24:
0x00053a30 lw v1, 0x1ac(sp) | v1 = *(length);
| label_23:
0x00053a34 addiu v1, v1, 1 | v1++;
0x00053a38 sw v1, 0x1ac(sp) | *(length) = v1;
| label_16:
0x00053a3c lw v0, 0x144(sp) | v0 = *(var_144h);
0x00053a40 lw t9, 0x1ac(sp) | t9 = *(length);
0x00053a44 slt v0, t9, v0 | v0 = (t9 < v0) ? 1 : 0;
0x00053a48 lw t9, -0x782c(gp) | t9 = *((gp - 7691));
| if (v0 == 0) {
0x00053a4c bnel v0, zero, 0x537d8 | goto label_4;
| }
0x00053a50 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
0x00053a54 b 0x53900 | goto label_3;
| label_19:
0x00053a58 lw v1, 0x208(sp) | v1 = *(arg_208h);
0x00053a5c sw s2, (v1) | *(v1) = s2;
0x00053a60 b 0x53a70 | goto label_25;
| label_20:
0x00053a64 move a0, s2 | a0 = s2;
0x00053a68 jalr t9 | t9 ();
0x00053a6c lw gp, 0x18(sp) | gp = *(var_18h);
| label_25:
0x00053a70 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00053a74 move a0, s4 | a0 = s4;
0x00053a78 jalr t9 | t9 ();
0x00053a7c lw ra, 0x1fc(sp) | ra = *(var_1fch);
0x00053a80 b 0x53af4 | goto label_26;
| label_8:
0x00053a84 addiu s3, s3, 1 | s3++;
| label_10:
0x00053a88 addiu s7, zero, -1 | s7 = -1;
| label_11:
0x00053a8c lw t9, 0x1b8(sp) | t9 = *(var_1b8h);
0x00053a90 addiu v0, zero, -1 | v0 = -1;
| if (t9 > 0) {
0x00053a94 bgtz t9, 0x533cc | goto label_5;
| }
0x00053a98 b 0x53aa4 | goto label_27;
0x00053a9c nop |
| label_6:
0x00053aa0 addiu s1, zero, -1 | s1 = -1;
| label_27:
0x00053aa4 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00053aa8 move v0, v1 | v0 = v1;
0x00053aac lw v1, -0x756c(gp) | v1 = *((gp - 7515));
0x00053ab0 addu v1, v1, v0 | v1 += v0;
0x00053ab4 addiu v0, zero, -1 | v0 = -1;
0x00053ab8 sw v0, (v1) | *(v1) = v0;
| if (s1 != v0) {
0x00053abc beq s1, v0, 0x53ad0 |
| label_13:
0x00053ac0 lw t9, -0x7fa0(gp) | t9 = *((gp - 8168));
0x00053ac4 move a0, s1 | a0 = s1;
0x00053ac8 bal 0x620b8 | sym_libc_close ();
0x00053acc lw gp, 0x18(sp) | gp = *(var_18h);
| }
0x00053ad0 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00053ad4 move a0, s4 | a0 = s4;
0x00053ad8 addiu s5, zero, -1 | s5 = -1;
0x00053adc jalr t9 | t9 ();
0x00053ae0 lw gp, 0x18(sp) | gp = *(var_18h);
0x00053ae4 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00053ae8 move a0, s2 | a0 = s2;
0x00053aec jalr t9 | t9 ();
0x00053af0 lw ra, 0x1fc(sp) | ra = *(var_1fch);
| label_26:
0x00053af4 move v0, s5 | v0 = s5;
0x00053af8 lw fp, 0x1f8(sp) | fp = *(var_1f8h);
0x00053afc lw s7, 0x1f4(sp) | s7 = *(var_1f4h);
0x00053b00 lw s6, 0x1f0(sp) | s6 = *(var_1f0h);
0x00053b04 lw s5, 0x1ec(sp) | s5 = *(var_1ech);
0x00053b08 lw s4, 0x1e8(sp) | s4 = *(var_1e8h);
0x00053b0c lw s3, 0x1e4(sp) | s3 = *(var_1e4h);
0x00053b10 lw s2, 0x1e0(sp) | s2 = *(var_1e0h);
0x00053b14 lw s1, 0x1dc(sp) | s1 = *(var_1dch);
0x00053b18 lw s0, 0x1d8(sp) | s0 = *(var_1d8h);
0x00053b1c addiu sp, sp, 0x200 |
0x00053b20 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x3fb50 */
| #include <stdint.h>
|
; (fcn) sym.clnt_create () | void clnt_create () {
0x0003fb50 lui gp, 8 |
0x0003fb54 addiu gp, gp, 0x1b90 |
0x0003fb58 addu gp, gp, t9 | gp += t9;
0x0003fb5c addiu sp, sp, -0xf0 |
0x0003fb60 sw s2, 0xd0(sp) | *(var_d0h) = s2;
0x0003fb64 move s2, a1 | s2 = a1;
0x0003fb68 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x0003fb6c lw t9, -0x7e98(gp) | t9 = *((gp - 8102));
0x0003fb70 sw fp, 0xe8(sp) | *(var_e8h) = fp;
0x0003fb74 sw s4, 0xd8(sp) | *(var_d8h) = s4;
0x0003fb78 move fp, sp | fp = sp;
0x0003fb7c sw s3, 0xd4(sp) | *(var_d4h) = s3;
0x0003fb80 sw s1, 0xcc(sp) | *(var_cch) = s1;
0x0003fb84 sw gp, 0x18(sp) | *(var_18h) = gp;
0x0003fb88 sw ra, 0xec(sp) | *(var_ech) = ra;
0x0003fb8c sw s7, 0xe4(sp) | *(var_e4h) = s7;
0x0003fb90 sw s6, 0xe0(sp) | *(var_e0h) = s6;
0x0003fb94 sw s5, 0xdc(sp) | *(var_dch) = s5;
0x0003fb98 sw s0, 0xc8(sp) | *(var_c8h) = s0;
0x0003fb9c move s4, a0 | s4 = a0;
0x0003fba0 addiu a1, a1, 0x6988 | a1 += 0x6988;
0x0003fba4 move a0, a3 | a0 = a3;
0x0003fba8 move s1, a2 | s1 = a2;
0x0003fbac move s3, a3 | s3 = a3;
0x0003fbb0 bal 0x3b600 | sym_strcmp ();
0x0003fbb4 lw gp, 0x18(fp) | gp = *(var_18h);
| if (v0 == 0) {
0x0003fbb8 bnez v0, 0x3fc18 |
0x0003fbbc lw t9, -0x7fe4(gp) | t9 = *((gp - 8185));
0x0003fbc0 addiu a2, zero, 0x6e | a2 = 0x6e;
0x0003fbc4 addiu a0, fp, 0x20 | a0 = fp + 0x20;
0x0003fbc8 move a1, zero | a1 = 0;
0x0003fbcc bal 0x3a970 | sym_memset ();
0x0003fbd0 lw gp, 0x18(fp) | gp = *(var_18h);
0x0003fbd4 addiu v0, zero, 1 | v0 = 1;
0x0003fbd8 addiu a0, fp, 0x22 | a0 = fp + 0x22;
0x0003fbdc lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x0003fbe0 move a1, s4 | a1 = s4;
0x0003fbe4 sh v0, 0x20(fp) | *(var_20h) = v0;
0x0003fbe8 bal 0x3b630 | sym_strcpy ()
0x0003fbec lw gp, 0x18(fp) | gp = *(var_18h);
0x0003fbf0 addiu v0, zero, -1 | v0 = -1;
0x0003fbf4 sw v0, 0xb8(fp) | *(var_b8h) = v0;
0x0003fbf8 sw zero, 0x10(sp) | *(var_10h_3) = 0;
0x0003fbfc sw zero, 0x14(sp) | *(var_14h_3) = 0;
0x0003fc00 addiu a0, fp, 0x20 | a0 = fp + 0x20;
0x0003fc04 move a1, s2 | a1 = s2;
0x0003fc08 move a2, s1 | a2 = s1;
0x0003fc0c addiu a3, fp, 0xb8 | a3 = fp + 0xb8;
0x0003fc10 lw t9, -0x7a84(gp) | t9 = *((gp - 7841));
0x0003fc14 b 0x3fe08 | goto label_2;
| }
0x0003fc18 lw s7, -0x7560(gp) | s7 = *((gp - 7512));
0x0003fc1c addiu sp, sp, -0x408 |
0x0003fc20 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x0003fc24 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x0003fc28 addiu s0, zero, 0x400 | s0 = aav.0x00000400;
0x0003fc2c addiu s5, fp, 0xc0 | s5 = fp + 0xc0;
0x0003fc30 addiu s6, fp, 0xb4 | s6 = fp + 0xb4;
0x0003fc34 addu s7, s7, v1 | s7 += v1;
0x0003fc38 b 0x3fc84 |
| while (v0 != 0) {
0x0003fc3c lw v1, 0xb4(fp) | v1 = *(var_b4h);
| label_0:
0x0003fc40 addiu v0, zero, -1 | v0 = -1;
0x0003fc44 addiu v0, zero, 0x22 | v0 = 0x22;
| if (v1 == v0) {
0x0003fc48 bne v1, v0, 0x3fc58 |
0x0003fc4c lw v1, (s7) | v1 = *(s7);
0x0003fc50 sll s0, s0, 1 | s0 <<= 1;
| if (v1 == v0) {
0x0003fc54 beq v1, v0, 0x3fc70 | goto label_3;
| }
| }
0x0003fc58 lw t9, -0x7a80(gp) | t9 = *((gp - 7840));
0x0003fc5c jalr t9 | t9 ();
0x0003fc60 nop |
0x0003fc64 addiu v1, zero, 0xd | v1 = 0xd;
0x0003fc68 sw v1, (v0) | *(v0) = v1;
0x0003fc6c b 0x3fe30 | goto label_4;
| label_3:
0x0003fc70 addiu v0, s0, 0xe | v0 = s0 + 0xe;
0x0003fc74 srl v0, v0, 3 | v0 >>= 3;
0x0003fc78 sll v0, v0, 3 | v0 <<= 3;
0x0003fc7c subu sp, sp, v0 |
0x0003fc80 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x0003fc84 lw t9, -0x7a7c(gp) | t9 = *((gp - 7839));
0x0003fc88 sw s5, 0x10(sp) | *(var_10h) = s5;
0x0003fc8c sw s6, 0x14(sp) | *(var_14h) = s6;
0x0003fc90 move a0, s4 | a0 = s4;
0x0003fc94 addiu a1, fp, 0x20 | a1 = fp + 0x20;
0x0003fc98 move a3, s0 | a3 = s0;
0x0003fc9c bal 0x54d80 | sym_gethostbyname_r ();
0x0003fca0 lw gp, 0x18(fp) | gp = *(var_18h);
0x0003fca4 bnez v0, 0x3fc3c |
| }
0x0003fca8 lw v0, 0xc0(fp) | v0 = *(var_c0h);
0x0003fcac lw v1, 0xb4(fp) | v1 = *(var_b4h);
| if (v0 == 0) {
0x0003fcb0 beqz v0, 0x3fc40 | goto label_0;
| }
0x0003fcb4 lw v0, 8(v0) | v0 = *((v0 + 2));
0x0003fcb8 addiu v1, zero, 2 | v1 = 2;
0x0003fcbc lw t9, -0x7fe4(gp) | t9 = *((gp - 8185));
| if (v0 != v1) {
0x0003fcc0 beq v0, v1, 0x3fce0 |
0x0003fcc4 lw t9, -0x7a80(gp) | t9 = *((gp - 7840));
0x0003fcc8 jalr t9 | t9 ();
0x0003fccc nop |
0x0003fcd0 addiu v1, zero, 0xc | v1 = 0xc;
0x0003fcd4 sw v1, (v0) | *(v0) = v1;
0x0003fcd8 addiu v1, zero, 0x7c | v1 = 0x7c;
0x0003fcdc b 0x3fe2c | goto label_5;
| }
0x0003fce0 addiu a0, fp, 0x98 | a0 = fp + 0x98;
0x0003fce4 move a1, zero | a1 = 0;
0x0003fce8 addiu a2, zero, 8 | a2 = 8;
0x0003fcec sh v0, 0x90(fp) | *(var_90h) = v0;
0x0003fcf0 sh zero, 0x92(fp) | *(var_92h) = 0;
0x0003fcf4 bal 0x3a970 | sym_memset ();
0x0003fcf8 lw v0, 0xc0(fp) | v0 = *(var_c0h);
0x0003fcfc lw gp, 0x18(fp) | gp = *(var_18h);
0x0003fd00 addiu a0, fp, 0x94 | a0 = fp + 0x94;
0x0003fd04 lw v1, 0x10(v0) | v1 = *((v0 + 4));
0x0003fd08 lw a2, 0xc(v0) | a2 = *((v0 + 3));
0x0003fd0c lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x0003fd10 lw a1, (v1) | a1 = *(v1);
0x0003fd14 addiu s0, zero, 0x400 | s0 = aav.0x00000400;
0x0003fd18 addiu s4, fp, 0xbc | s4 = fp + 0xbc;
0x0003fd1c bal 0x3a830 | sym_memcpy ();
0x0003fd20 lw gp, 0x18(fp) | gp = *(var_18h);
0x0003fd24 addiu sp, sp, -0x408 |
0x0003fd28 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x0003fd2c lw s5, -0x7560(gp) | s5 = *((gp - 7512));
0x0003fd30 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x0003fd34 addu s5, s5, v1 | s5 += v1;
0x0003fd38 b 0x3fd74 |
| while (v0 != 0) {
0x0003fd3c lw v1, (s5) | v1 = *(s5);
| label_1:
0x0003fd40 addiu v0, zero, 0x22 | v0 = 0x22;
0x0003fd44 sll s0, s0, 1 | s0 <<= 1;
| if (v1 != v0) {
0x0003fd48 beq v1, v0, 0x3fd60 |
0x0003fd4c lw t9, -0x7a80(gp) | t9 = *((gp - 7840));
0x0003fd50 jalr t9 | t9 ();
0x0003fd54 nop |
0x0003fd58 addiu v1, zero, 0x11 | v1 = 0x11;
0x0003fd5c b 0x3fe24 | goto label_6;
| }
0x0003fd60 addiu v0, s0, 0xe | v0 = s0 + 0xe;
0x0003fd64 srl v0, v0, 3 | v0 >>= 3;
0x0003fd68 sll v0, v0, 3 | v0 <<= 3;
0x0003fd6c subu sp, sp, v0 |
0x0003fd70 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x0003fd74 lw t9, -0x7a78(gp) | t9 = *((gp - 7838));
0x0003fd78 sw s4, 0x10(sp) | *(var_10h_2) = s4;
0x0003fd7c move a0, s3 | a0 = s3;
0x0003fd80 addiu a1, fp, 0xa0 | a1 = fp + 0xa0;
0x0003fd84 move a3, s0 | a3 = s0;
0x0003fd88 bal 0x4e5d0 | sym_getprotobyname_r ();
0x0003fd8c lw gp, 0x18(fp) | gp = *(var_18h);
0x0003fd90 bnez v0, 0x3fd3c |
| }
0x0003fd94 lw v0, 0xbc(fp) | v0 = *(var_bch);
| if (v0 == 0) {
0x0003fd98 beql v0, zero, 0x3fd40 | goto label_1;
| }
0x0003fd9c lw v1, (s5) | v1 = *(s5);
0x0003fda0 lw v0, 8(v0) | v0 = *((v0 + 2));
0x0003fda4 addiu v1, zero, -1 | v1 = -1;
0x0003fda8 sw v1, 0xb8(fp) | *(var_b8h) = v1;
0x0003fdac addiu v1, zero, 6 | v1 = 6;
0x0003fdb0 addiu v1, zero, 0x11 | v1 = 0x11;
| if (v0 != v1) {
0x0003fdb4 beq v0, v1, 0x3fdec |
0x0003fdb8 lw t9, -0x7a80(gp) | t9 = *((gp - 7840));
| if (v0 != v1) {
0x0003fdbc bne v0, v1, 0x3fe18 | goto label_7;
| }
0x0003fdc0 lw t9, -0x7a74(gp) | t9 = *((gp - 7837));
0x0003fdc4 addiu v0, fp, 0xb8 | v0 = fp + 0xb8;
0x0003fdc8 sw v0, 0x14(sp) | *(var_14h_2) = v0;
0x0003fdcc sw zero, 0x10(sp) | *(var_10h_2) = 0;
0x0003fdd0 addiu a3, zero, 5 | a3 = 5;
0x0003fdd4 addiu a0, fp, 0x90 | a0 = fp + 0x90;
0x0003fdd8 move a1, s2 | a1 = s2;
0x0003fddc move a2, s1 | a2 = s1;
0x0003fde0 bal 0x423a8 | sym_clntudp_create ();
0x0003fde4 b 0x3fe10 | goto label_8;
0x0003fde8 nop |
| }
0x0003fdec lw t9, -0x7a70(gp) | t9 = *((gp - 7836));
0x0003fdf0 sw zero, 0x10(sp) | *(var_10h_2) = 0;
0x0003fdf4 sw zero, 0x14(sp) | *(var_14h_2) = 0;
0x0003fdf8 addiu a0, fp, 0x90 | a0 = fp + 0x90;
0x0003fdfc move a1, s2 | a1 = s2;
0x0003fe00 move a2, s1 | a2 = s1;
0x0003fe04 addiu a3, fp, 0xb8 | a3 = fp + 0xb8;
| label_2:
0x0003fe08 jalr t9 | t9 ();
0x0003fe0c nop |
| label_8:
0x0003fe10 move sp, fp |
0x0003fe14 b 0x3fe38 | goto label_9;
| label_7:
0x0003fe18 jalr t9 | t9 ();
0x0003fe1c nop |
0x0003fe20 addiu v1, zero, 0xc | v1 = 0xc;
| label_6:
0x0003fe24 sw v1, (v0) | *(v0) = v1;
0x0003fe28 addiu v1, zero, 0x7b | v1 = 0x7b;
| label_5:
0x0003fe2c sw v1, 8(v0) | *((v0 + 2)) = v1;
| label_4:
0x0003fe30 move v0, zero | v0 = 0;
0x0003fe34 move sp, fp |
| label_9:
0x0003fe38 lw ra, 0xec(sp) | ra = *(var_ech);
0x0003fe3c lw fp, 0xe8(sp) | fp = *(var_e8h);
0x0003fe40 lw s7, 0xe4(sp) | s7 = *(var_e4h);
0x0003fe44 lw s6, 0xe0(sp) | s6 = *(var_e0h);
0x0003fe48 lw s5, 0xdc(sp) | s5 = *(var_dch);
0x0003fe4c lw s4, 0xd8(sp) | s4 = *(var_d8h);
0x0003fe50 lw s3, 0xd4(sp) | s3 = *(var_d4h);
0x0003fe54 lw s2, 0xd0(sp) | s2 = *(var_d0h);
0x0003fe58 lw s1, 0xcc(sp) | s1 = *(var_cch);
0x0003fe5c lw s0, 0xc8(sp) | s0 = *(var_c8h);
0x0003fe60 addiu sp, sp, 0xf0 |
0x0003fe64 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x401fc */
| #include <stdint.h>
|
; (fcn) sym.clnt_spcreateerror () | void clnt_spcreateerror () {
0x000401fc lui gp, 8 |
0x00040200 addiu gp, gp, 0x14e4 |
0x00040204 addu gp, gp, t9 | gp += t9;
0x00040208 lw t9, -0x7b10(gp) | t9 = *((gp - 7876));
0x0004020c addiu sp, sp, -0x438 |
0x00040210 sw gp, 0x10(sp) | *(var_10h) = gp;
0x00040214 sw s3, 0x428(sp) | *(var_428h) = s3;
0x00040218 sw s0, 0x41c(sp) | *(var_41ch) = s0;
0x0004021c sw ra, 0x434(sp) | *(var_434h) = ra;
0x00040220 sw s5, 0x430(sp) | *(var_430h) = s5;
0x00040224 sw s4, 0x42c(sp) | *(var_42ch) = s4;
0x00040228 sw s2, 0x424(sp) | *(var_424h) = s2;
0x0004022c sw s1, 0x420(sp) | *(var_420h) = s1;
0x00040230 addiu t9, t9, -0x190 | t9 += -aav.0x00000190;
0x00040234 move s0, a0 | s0 = a0;
0x00040238 bal 0x3fe70 | fcn_0003fe70 ();
0x0004023c move s3, v0 | s3 = v0;
0x00040240 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x00040244 beqz v0, 0x40380 |
0x00040248 lw t9, -0x7a80(gp) | t9 = *((gp - 7840));
0x0004024c jalr t9 | t9 ();
0x00040250 nop |
0x00040254 lw gp, 0x10(sp) | gp = *(var_10h);
0x00040258 move a2, s0 | a2 = s0;
0x0004025c move a0, s3 | a0 = s3;
0x00040260 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00040264 lw t9, -0x7f74(gp) | t9 = *((gp - 8157));
0x00040268 move s4, v0 | s4 = v0;
0x0004026c addiu a1, a1, 0x47a0 | a1 += 0x47a0;
0x00040270 bal 0x2f960 | sym_sprintf ();
0x00040274 lw gp, 0x10(sp) | gp = *(var_10h);
0x00040278 lw a0, (s4) | a0 = *(s4);
0x0004027c lw s5, -0x7a6c(gp) | s5 = *((gp - 7835));
0x00040280 move t9, s5 | t9 = s5;
0x00040284 addu s0, s3, v0 | s0 = s3 + v0;
0x00040288 bal 0x3fecc | sym_clnt_sperrno ();
0x0004028c lw gp, 0x10(sp) | gp = *(var_10h);
0x00040290 move a0, s0 | a0 = s0;
0x00040294 lw s2, -0x7f48(gp) | s2 = *((gp - 8146));
0x00040298 move t9, s2 | t9 = s2;
0x0004029c move a1, v0 | a1 = v0;
0x000402a0 bal 0x3b630 | sym_strcpy ()
0x000402a4 lw gp, 0x10(sp) | gp = *(var_10h);
0x000402a8 lw s1, -0x7fdc(gp) | s1 = *((gp - 8183));
0x000402ac move t9, s1 | t9 = s1;
0x000402b0 move a0, s0 | a0 = s0;
0x000402b4 bal 0x3b6e0 | sym_strlen ();
0x000402b8 addu s0, s0, v0 | s0 += v0;
0x000402bc lw v0, (s4) | v0 = *(s4);
0x000402c0 addiu v1, zero, 0xc | v1 = 0xc;
0x000402c4 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != v1) {
0x000402c8 beq v0, v1, 0x40314 |
0x000402cc addiu v1, zero, 0xe | v1 = 0xe;
0x000402d0 addiu v0, zero, 0xa | v0 = 0xa;
| if (v0 != v1) {
0x000402d4 bne v0, v1, 0x40378 | goto label_0;
| }
0x000402d8 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x000402dc move a0, s0 | a0 = s0;
0x000402e0 move t9, s2 | t9 = s2;
0x000402e4 addiu a1, a1, 0x6a2c | a1 += 0x6a2c;
0x000402e8 bal 0x3b630 | sym_strcpy ()
0x000402ec move t9, s1 | t9 = s1;
0x000402f0 move a0, s0 | a0 = s0;
0x000402f4 bal 0x3b6e0 | sym_strlen ();
0x000402f8 lw a0, 4(s4) | a0 = *((s4 + 1));
0x000402fc move t9, s5 | t9 = s5;
0x00040300 addu s0, s0, v0 | s0 += v0;
0x00040304 bal 0x3fecc | sym_clnt_sperrno ();
0x00040308 move a1, v0 | a1 = v0;
0x0004030c move a0, s0 | a0 = s0;
0x00040310 b 0x40358 |
| } else {
0x00040314 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00040318 move a0, s0 | a0 = s0;
0x0004031c move t9, s2 | t9 = s2;
0x00040320 addiu a1, a1, 0x6a2c | a1 += 0x6a2c;
0x00040324 bal 0x3b630 | sym_strcpy ()
0x00040328 move t9, s1 | t9 = s1;
0x0004032c move a0, s0 | a0 = s0;
0x00040330 bal 0x3b6e0 | sym_strlen ();
0x00040334 lw gp, 0x10(sp) | gp = *(var_10h);
0x00040338 lw a0, 8(s4) | a0 = *((s4 + 2));
0x0004033c addu s0, s0, v0 | s0 += v0;
0x00040340 lw t9, -0x7b94(gp) | t9 = *((gp - 7909));
0x00040344 addiu a1, sp, 0x18 | a1 = sp + 0x18;
0x00040348 addiu a2, zero, 0x400 | a2 = aav.0x00000400;
0x0004034c bal 0x3be20 | sym_glibc_strerror_r ();
0x00040350 move a0, s0 | a0 = s0;
0x00040354 addiu a1, sp, 0x18 | a1 = sp + 0x18;
| }
0x00040358 move t9, s2 | t9 = s2;
0x0004035c bal 0x3b630 | sym_strcpy ()
0x00040360 nop |
0x00040364 move t9, s1 | t9 = s1;
0x00040368 move a0, s0 | a0 = s0;
0x0004036c bal 0x3b6e0 | sym_strlen ();
0x00040370 addu s0, s0, v0 | s0 += v0;
0x00040374 addiu v0, zero, 0xa | v0 = 0xa;
| label_0:
0x00040378 sb v0, (s0) | *(s0) = v0;
0x0004037c sb zero, 1(s0) | *(var_1h) = 0;
| }
0x00040380 lw ra, 0x434(sp) | ra = *(var_434h);
0x00040384 move v0, s3 | v0 = s3;
0x00040388 lw s5, 0x430(sp) | s5 = *(var_430h);
0x0004038c lw s4, 0x42c(sp) | s4 = *(var_42ch);
0x00040390 lw s3, 0x428(sp) | s3 = *(var_428h);
0x00040394 lw s2, 0x424(sp) | s2 = *(var_424h);
0x00040398 lw s1, 0x420(sp) | s1 = *(var_420h);
0x0004039c lw s0, 0x41c(sp) | s0 = *(var_41ch);
0x000403a0 addiu sp, sp, 0x438 |
0x000403a4 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x3ff68 */
| #include <stdint.h>
|
; (fcn) sym.clnt_sperror () | void clnt_sperror () {
0x0003ff68 lui gp, 8 |
0x0003ff6c addiu gp, gp, 0x1778 |
0x0003ff70 addu gp, gp, t9 | gp += t9;
0x0003ff74 lw t9, -0x7b10(gp) | t9 = *((gp - 7876));
0x0003ff78 addiu sp, sp, -0x448 |
0x0003ff7c sw s0, 0x430(sp) | *(var_430h) = s0;
0x0003ff80 sw gp, 0x10(sp) | *(var_10h) = gp;
0x0003ff84 sw a0, 0x428(sp) | *(var_428h) = a0;
0x0003ff88 sw ra, 0x444(sp) | *(var_444h) = ra;
0x0003ff8c sw s4, 0x440(sp) | *(var_440h) = s4;
0x0003ff90 sw s3, 0x43c(sp) | *(var_43ch) = s3;
0x0003ff94 sw s2, 0x438(sp) | *(var_438h) = s2;
0x0003ff98 sw s1, 0x434(sp) | *(var_434h) = s1;
0x0003ff9c addiu t9, t9, -0x190 | t9 += -aav.0x00000190;
0x0003ffa0 move s0, a1 | s0 = a1;
0x0003ffa4 bal 0x3fe70 | fcn_0003fe70 ();
0x0003ffa8 lw a0, 0x428(sp) | a0 = *(var_428h);
| if (v0 != 0) {
0x0003ffac beqz v0, 0x40194 |
0x0003ffb0 move s1, v0 | s1 = v0;
0x0003ffb4 lw v0, 4(a0) | v0 = *((a0 + 1));
0x0003ffb8 lw t9, 8(v0) | t9 = *((v0 + 2));
0x0003ffbc addiu a1, sp, 0x418 | a1 = sp + aav.0x00000418;
0x0003ffc0 jalr t9 | t9 ();
0x0003ffc4 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ffc8 move a2, s0 | a2 = s0;
0x0003ffcc move a0, s1 | a0 = s1;
0x0003ffd0 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x0003ffd4 lw s2, -0x7f74(gp) | s2 = *((gp - 8157));
0x0003ffd8 move t9, s2 | t9 = s2;
0x0003ffdc addiu a1, a1, 0x47a0 | a1 += 0x47a0;
0x0003ffe0 bal 0x2f960 | sym_sprintf ();
0x0003ffe4 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ffe8 lw a0, 0x418(sp) | a0 = *(format);
0x0003ffec lw t9, -0x7a6c(gp) | t9 = *((gp - 7835));
0x0003fff0 addu s0, s1, v0 | s0 = s1 + v0;
0x0003fff4 bal 0x3fecc | sym_clnt_sperrno ();
0x0003fff8 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003fffc j 0x4008084 | void (*0x4008084)() ();
0x00040000 lw zero, (t8) | 0 = *(t8);
0x00040004 move a1, v0 | a1 = v0;
0x00040008 bal 0x3b630 | sym_strcpy ()
0x0004000c lw gp, 0x10(sp) | gp = *(var_10h);
0x00040010 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00040014 move a0, s0 | a0 = s0;
0x00040018 bal 0x3b6e0 | sym_strlen ();
0x0004001c addu s0, s0, v0 | s0 += v0;
0x00040020 lw v0, 0x418(sp) | v0 = *(format);
0x00040024 sltiu v1, v0, 0x12 | v1 = (v0 < 0x12) ? 1 : 0;
0x00040028 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v1 != 0) {
0x0004002c beqz v1, 0x4015c |
0x00040030 lw v1, -0x7fd0(gp) | v1 = *((gp - 8180));
0x00040034 sll v0, v0, 2 | v0 <<= 2;
0x00040038 addiu v1, v1, 0x6a30 | v1 += 0x6a30;
0x0004003c addu v0, v1, v0 | v0 = v1 + v0;
0x00040040 lw v0, (v0) | v0 = *(v0);
0x00040044 addu v0, v0, gp | v0 += gp;
0x00040048 jr v0 | v0 ();
0x0004004c nop |
| }
0x0004015c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00040160 lw a2, 0x41c(sp) | a2 = *(var_41ch);
0x00040164 lw a3, 0x420(sp) | a3 = *(var_420h);
0x00040168 move a0, s0 | a0 = s0;
0x0004016c addiu a1, a1, 0x6a14 | a1 += 0x6a14;
0x00040170 move t9, s2 | t9 = s2;
0x00040174 bal 0x2f960 | sym_sprintf ();
0x00040178 nop |
0x0004017c addu s0, s0, v0 | s0 += v0;
0x00040180 addiu v0, zero, 0xa | v0 = 0xa;
0x00040184 sb v0, (s0) | *(s0) = v0;
0x00040188 sb zero, 1(s0) | *((s0 + 1)) = 0;
0x0004018c move v0, s1 | v0 = s1;
0x00040190 b 0x40198 |
| } else {
0x00040194 move v0, zero | v0 = 0;
| }
0x00040198 lw ra, 0x444(sp) | ra = *(var_444h);
0x0004019c lw s4, 0x440(sp) | s4 = *(var_440h);
0x000401a0 lw s3, 0x43c(sp) | s3 = *(var_43ch);
0x000401a4 lw s2, 0x438(sp) | s2 = *(var_438h);
0x000401a8 lw s1, 0x434(sp) | s1 = *(var_434h);
0x000401ac lw s0, 0x430(sp) | s0 = *(var_430h);
0x000401b0 addiu sp, sp, 0x448 |
0x000401b4 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x30040 */
| #include <stdint.h>
|
; (fcn) sym.ctermid () | void ctermid () {
0x00030040 lui gp, 9 |
0x00030044 addiu gp, gp, 0x16a0 |
0x00030048 addu gp, gp, t9 | gp += t9;
0x0003004c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
| if (a0 == 0) {
0x00030050 bnez a0, 0x3005c |
0x00030054 lw a0, -0x7ed0(gp) | a0 = *((gp - 8116));
0x00030058 addiu a0, a0, -0x49b0 | a0 += -0x49b0;
| }
0x0003005c lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00030060 addiu a1, a1, 0x55fc | a1 += 0x55fc;
0x00030064 b 0x3b630 | return void (*0x3b630)() ();
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x5883c */
| #include <stdint.h>
|
; (fcn) sym.ether_ntohost () | void ether_ntohost () {
0x0005883c lui gp, 7 |
0x00058840 addiu gp, gp, -0x715c |
0x00058844 addu gp, gp, t9 | gp += t9;
0x00058848 addiu sp, sp, -0x140 |
0x0005884c sw s4, 0x130(sp) | *(var_130h) = s4;
0x00058850 sw s3, 0x12c(sp) | *(var_12ch) = s3;
0x00058854 move s4, a1 | s4 = a1;
0x00058858 move s3, a0 | s3 = a0;
0x0005885c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00058860 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00058864 lw t9, -0x7dd4(gp) | t9 = *((gp - 8053));
0x00058868 sw gp, 0x10(sp) | *(var_10h) = gp;
0x0005886c sw ra, 0x13c(sp) | *(var_13ch) = ra;
0x00058870 sw s6, 0x138(sp) | *(var_138h) = s6;
0x00058874 sw s5, 0x134(sp) | *(var_134h) = s5;
0x00058878 sw s2, 0x128(sp) | *(var_128h) = s2;
0x0005887c sw s1, 0x124(sp) | *(var_124h) = s1;
0x00058880 sw s0, 0x120(sp) | *(var_120h) = s0;
0x00058884 addiu a0, a0, 0x7cd8 | a0 += 0x7cd8;
0x00058888 addiu a1, a1, 0x4bfc | a1 += 0x4bfc;
0x0005888c jalr t9 | t9 ();
0x00058890 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x00058894 bnez v0, 0x588f0 | goto label_0;
| }
0x00058898 addiu s1, zero, -1 | s1 = -1;
0x0005889c b 0x58934 | goto label_1;
| do {
0x000588a0 addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x000588a4 addiu t9, s5, -0x78e8 | t9 = s5 + -0x78e8;
0x000588a8 addiu a1, sp, 0x118 | a1 = sp + aav.0x00000118;
0x000588ac bal 0x58718 | fcn_00058718 ();
0x000588b0 move s1, v0 | s1 = v0;
| if (v0 != 0) {
0x000588b4 beqz v0, 0x58900 |
0x000588b8 move a0, s4 | a0 = s4;
0x000588bc addiu a1, sp, 0x118 | a1 = sp + aav.0x00000118;
0x000588c0 move t9, s6 | t9 = s6;
0x000588c4 addiu a2, zero, 6 | a2 = 6;
0x000588c8 bal 0x3ab1c | sym_bcmp ();
0x000588cc lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x000588d0 bnez v0, 0x58900 | goto label_2;
| }
0x000588d4 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x000588d8 move a1, s1 | a1 = s1;
0x000588dc move a0, s3 | a0 = s3;
0x000588e0 bal 0x3b630 | sym_strcpy ()
0x000588e4 move s1, zero | s1 = 0;
0x000588e8 lw gp, 0x10(sp) | gp = *(var_10h);
0x000588ec b 0x58920 | goto label_3;
| label_0:
0x000588f0 lw s2, -0x7dcc(gp) | s2 = *((gp - 8051));
0x000588f4 lw s5, -0x77b8(gp) | s5 = *((gp - 7662));
0x000588f8 lw s6, -0x7d84(gp) | s6 = *((gp - 8033));
0x000588fc move s0, v0 | s0 = v0;
| }
| label_2:
0x00058900 addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x00058904 addiu a1, zero, 0x100 | a1 = aav.0x00000100;
0x00058908 move t9, s2 | t9 = s2;
0x0005890c move a2, s0 | a2 = s0;
0x00058910 jalr t9 | t9 ();
0x00058914 lw gp, 0x10(sp) | gp = *(var_10h);
0x00058918 bnez v0, 0x588a0 |
| } while (v0 != 0);
0x0005891c addiu s1, zero, -1 | s1 = -1;
| label_3:
0x00058920 lw t9, -0x7dd0(gp) | t9 = *((gp - 8052));
0x00058924 move a0, s0 | a0 = s0;
0x00058928 jalr t9 | t9 ();
0x0005892c lw ra, 0x13c(sp) | ra = *(var_13ch);
0x00058930 b 0x58938 | goto label_4;
| label_1:
0x00058934 lw ra, 0x13c(sp) | ra = *(var_13ch);
| label_4:
0x00058938 move v0, s1 | v0 = s1;
0x0005893c lw s6, 0x138(sp) | s6 = *(var_138h);
0x00058940 lw s5, 0x134(sp) | s5 = *(var_134h);
0x00058944 lw s4, 0x130(sp) | s4 = *(var_130h);
0x00058948 lw s3, 0x12c(sp) | s3 = *(var_12ch);
0x0005894c lw s2, 0x128(sp) | s2 = *(var_128h);
0x00058950 lw s1, 0x124(sp) | s1 = *(var_124h);
0x00058954 lw s0, 0x120(sp) | s0 = *(var_120h);
0x00058958 addiu sp, sp, 0x140 |
0x0005895c jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x54a00 */
| #include <stdint.h>
|
; (fcn) sym.gethostbyaddr_r () | void gethostbyaddr_r () {
0x00054a00 lui gp, 7 |
0x00054a04 addiu gp, gp, -0x3320 |
0x00054a08 addu gp, gp, t9 | gp += t9;
0x00054a0c addiu sp, sp, -0x90 |
0x00054a10 lw t9, 0xa8(sp) | t9 = *(arg_a8h);
0x00054a14 sw gp, 0x20(sp) | *(var_20h) = gp;
0x00054a18 sw s6, 0x80(sp) | *(var_80h) = s6;
0x00054a1c sw s3, 0x74(sp) | *(var_74h) = s3;
0x00054a20 sw s0, 0x68(sp) | *(var_68h) = s0;
0x00054a24 sw ra, 0x8c(sp) | *(var_8ch) = ra;
0x00054a28 sw fp, 0x88(sp) | *(var_88h) = fp;
0x00054a2c sw s7, 0x84(sp) | *(var_84h) = s7;
0x00054a30 sw s5, 0x7c(sp) | *(var_7ch) = s5;
0x00054a34 sw s4, 0x78(sp) | *(var_78h) = s4;
0x00054a38 sw s2, 0x70(sp) | *(var_70h) = s2;
0x00054a3c sw s1, 0x6c(sp) | *(var_6ch) = s1;
0x00054a40 lw s3, 0xa0(sp) | s3 = *(arg_a0h);
0x00054a44 lw s6, 0xa4(sp) | s6 = *(arg_a4h);
0x00054a48 lw s0, 0xac(sp) | s0 = *(arg_ach);
0x00054a4c sw zero, (t9) | *(t9) = 0;
| if (a0 == 0) {
0x00054a50 beqz a0, 0x54d40 | goto label_0;
| }
0x00054a54 addiu v0, zero, 2 | v0 = 2;
0x00054a58 move s7, a0 | s7 = a0;
0x00054a5c move s2, a1 | s2 = a1;
0x00054a60 move s5, a2 | s5 = a2;
0x00054a64 move s1, a3 | s1 = a3;
| if (a2 != v0) {
0x00054a68 beq a2, v0, 0x54a80 |
0x00054a6c addiu v0, zero, 0xa | v0 = 0xa;
0x00054a70 addiu v0, zero, 0x16 | v0 = 0x16;
| if (a2 != v0) {
0x00054a74 bne a2, v0, 0x54d44 | goto label_1;
| }
0x00054a78 addiu v1, zero, 0x10 | v1 = 0x10;
0x00054a7c b 0x54a88 |
| } else {
0x00054a80 addiu v0, zero, 0x16 | v0 = 0x16;
0x00054a84 addiu v1, zero, 4 | v1 = 4;
| }
0x00054a88 lw ra, 0x8c(sp) | ra = *(var_8ch);
| if (a1 != v1) {
0x00054a8c bne a1, v1, 0x54d48 | goto label_2;
| }
0x00054a90 lw t9, 0xa8(sp) | t9 = *(arg_a8h);
0x00054a94 sw s3, 0x10(sp) | *(var_10h) = s3;
0x00054a98 sw s6, 0x14(sp) | *(var_14h) = s6;
0x00054a9c sw t9, 0x18(sp) | *(var_18h) = t9;
0x00054aa0 lw t9, -0x7804(gp) | t9 = *((gp - 7681));
0x00054aa4 sw s0, 0x1c(sp) | *(var_1ch) = s0;
0x00054aa8 move a0, s7 | a0 = s7;
0x00054aac move a1, s2 | a1 = s2;
0x00054ab0 move a2, s5 | a2 = s5;
0x00054ab4 move a3, s1 | a3 = s1;
0x00054ab8 bal 0x548c0 | fcn_000548c0 ();
0x00054abc lw gp, 0x20(sp) | gp = *(var_20h);
| if (v0 == 0) {
0x00054ac0 beqz v0, 0x54d44 | goto label_1;
| }
0x00054ac4 lw v1, (s0) | v1 = *(s0);
0x00054ac8 addiu a0, zero, 1 | a0 = 1;
0x00054acc addiu a0, zero, 4 | a0 = 4;
| if (v1 != a0) {
0x00054ad0 beq v1, a0, 0x54adc |
0x00054ad4 lw ra, 0x8c(sp) | ra = *(var_8ch);
| if (v1 != a0) {
0x00054ad8 bne v1, a0, 0x54d48 | goto label_2;
| }
| }
0x00054adc addiu v0, zero, -1 | v0 = -1;
0x00054ae0 sltiu v1, s2, 0x11 | v1 = (s2 < 0x11) ? 1 : 0;
0x00054ae4 sw v0, (s0) | *(s0) = v0;
0x00054ae8 addiu v0, zero, 0x22 | v0 = 0x22;
| if (v1 == 0) {
0x00054aec beqz v1, 0x54d44 | goto label_1;
| }
0x00054af0 negu s4, s3 | __asm ("negu s4, s3");
0x00054af4 andi s4, s4, 3 | s4 &= 3;
0x00054af8 addiu s6, s6, -0x18 | s6 += -0x18;
0x00054afc subu s6, s6, s4 | __asm ("subu s6, s6, s4");
0x00054b00 slti v1, s6, 0x100 | v1 = (s6 < aav.0x00000100) ? 1 : 0;
0x00054b04 lw ra, 0x8c(sp) | ra = *(var_8ch);
| if (v1 != 0) {
0x00054b08 bnez v1, 0x54d48 | goto label_2;
| }
0x00054b0c addu s4, s3, s4 | s4 = s3 + s4;
0x00054b10 lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00054b14 addiu a0, s4, 8 | a0 = s4 + 8;
0x00054b18 sw zero, 4(s4) | *((s4 + 1)) = 0;
0x00054b1c sw a0, (s4) | *(s4) = a0;
0x00054b20 move a1, s7 | a1 = s7;
0x00054b24 move a2, s2 | a2 = s2;
0x00054b28 bal 0x3a830 | sym_memcpy ();
0x00054b2c addiu v0, zero, 2 | v0 = 2;
0x00054b30 addiu s3, s4, 0x18 | s3 = s4 + 0x18;
0x00054b34 lw gp, 0x20(sp) | gp = *(var_20h);
| if (s5 == v0) {
0x00054b38 bne s5, v0, 0x54b70 |
0x00054b3c lbu v0, 1(s7) | v0 = *((s7 + 1));
0x00054b40 lbu a2, 3(s7) | a2 = *((s7 + 3));
0x00054b44 lbu a3, 2(s7) | a3 = *((s7 + 2));
0x00054b48 sw v0, 0x10(sp) | *(var_10h) = v0;
0x00054b4c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00054b50 lbu v0, (s7) | v0 = *(s7);
0x00054b54 lw t9, -0x7f74(gp) | t9 = *((gp - 8157));
0x00054b58 move a0, s3 | a0 = s3;
0x00054b5c sw v0, 0x14(sp) | *(var_14h) = v0;
0x00054b60 addiu a1, a1, 0x7c54 | a1 += 0x7c54;
0x00054b64 jalr t9 | t9 ();
0x00054b68 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054b6c b 0x54be4 | goto label_3;
| }
0x00054b70 lw t1, -0x7fd0(gp) | t1 = *((gp - 8180));
0x00054b74 lw t9, -0x7f74(gp) | t9 = *((gp - 8157));
0x00054b78 addiu t0, s2, -1 | t0 = s2 + -1;
0x00054b7c addu t0, s7, t0 | t0 = s7 + t0;
0x00054b80 move fp, s3 | fp = s3;
0x00054b84 addiu t1, t1, 0x7c70 | t1 += 0x7c70;
| do {
0x00054b88 lbu a3, (t0) | a3 = *(t0);
0x00054b8c move a0, fp | a0 = fp;
0x00054b90 move a1, t1 | a1 = t1;
0x00054b94 andi a2, a3, 0xf | a2 = a3 & 0xf;
0x00054b98 sw t0, 0x58(sp) | *(var_58h) = t0;
0x00054b9c sw t1, 0x5c(sp) | *(var_5ch) = t1;
0x00054ba0 sw t9, 0x60(sp) | *(var_60h) = t9;
0x00054ba4 srl a3, a3, 4 | a3 >>= 4;
0x00054ba8 jalr t9 | t9 ();
0x00054bac lw t0, 0x58(sp) | t0 = *(var_58h);
0x00054bb0 addu fp, fp, v0 | fp += v0;
0x00054bb4 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054bb8 addiu t0, t0, -1 | t0 += -1;
0x00054bbc sltu v0, t0, s7 | v0 = (t0 < s7) ? 1 : 0;
0x00054bc0 lw t1, 0x5c(sp) | t1 = *(var_5ch);
0x00054bc4 lw t9, 0x60(sp) | t9 = *(var_60h);
0x00054bc8 beqz v0, 0x54b88 |
| } while (v0 == 0);
0x00054bcc lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00054bd0 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00054bd4 move a0, fp | a0 = fp;
0x00054bd8 addiu a1, a1, 0x7c78 | a1 += 0x7c78;
0x00054bdc bal 0x3b630 | sym_strcpy ()
0x00054be0 lw gp, 0x20(sp) | gp = *(var_20h);
| label_3:
0x00054be4 lw t9, -0x7fe4(gp) | t9 = *((gp - 8185));
0x00054be8 addiu fp, sp, 0x28 | fp = sp + 0x28;
0x00054bec move a0, fp | a0 = fp;
0x00054bf0 move a1, zero | a1 = 0;
0x00054bf4 addiu a2, zero, 0x28 | a2 = 0x28;
0x00054bf8 bal 0x3a970 | sym_memset ();
0x00054bfc lw gp, 0x20(sp) | gp = *(var_20h);
0x00054c00 move s7, zero | s7 = 0;
| do {
0x00054c04 lw t9, -0x7800(gp) | t9 = *((gp - 7680));
0x00054c08 move a0, s3 | a0 = s3;
0x00054c0c addiu a1, zero, 0xc | a1 = 0xc;
0x00054c10 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x00054c14 move a3, fp | a3 = fp;
0x00054c18 bal 0x532e0 | fcn_000532e0 ();
0x00054c1c lw gp, 0x20(sp) | gp = *(var_20h);
| if (v0 < 0) {
0x00054c20 bgez v0, 0x54c2c |
0x00054c24 addiu v0, zero, 1 | v0 = 1;
0x00054c28 b 0x54d34 | goto label_4;
| }
0x00054c2c lw t9, -0x7ce8(gp) | t9 = *((gp - 7994));
0x00054c30 lw a1, 0x28(sp) | a1 = *(src);
0x00054c34 move a0, s3 | a0 = s3;
0x00054c38 move a2, s6 | a2 = s6;
0x00054c3c sw v0, 0x58(sp) | *(var_58h) = v0;
0x00054c40 bal 0x3b910 | sym_strncpy ();
0x00054c44 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054c48 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00054c4c lw a0, 0x28(sp) | a0 = *(src);
0x00054c50 jalr t9 | t9 ();
0x00054c54 lw v0, 0x2c(sp) | v0 = *(var_2ch);
0x00054c58 addiu a0, zero, 5 | a0 = 5;
0x00054c5c lw gp, 0x20(sp) | gp = *(var_20h);
0x00054c60 lw v1, 0x58(sp) | v1 = *(var_58h);
| if (v0 != a0) {
0x00054c64 bne v0, a0, 0x54cc8 | goto label_5;
| }
0x00054c68 addiu s7, s7, 1 | s7++;
0x00054c6c addiu v0, zero, 6 | v0 = 6;
0x00054c70 lw t9, -0x782c(gp) | t9 = *((gp - 7691));
| if (s7 == v0) {
0x00054c74 bne s7, v0, 0x54c80 |
0x00054c78 addiu v0, zero, 3 | v0 = 3;
0x00054c7c b 0x54cbc | goto label_6;
| }
0x00054c80 lw a0, 0x50(sp) | a0 = *(var_50h);
0x00054c84 lw a1, 0x40(sp) | a1 = *(var_40h);
0x00054c88 move a2, v1 | a2 = v1;
0x00054c8c move a3, s3 | a3 = s3;
0x00054c90 sw s6, 0x10(sp) | *(var_10h) = s6;
0x00054c94 bal 0x52d00 | fcn_00052d00 ();
0x00054c98 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054c9c lw a0, 0x50(sp) | a0 = *(var_50h);
0x00054ca0 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00054ca4 sw v0, 0x58(sp) | *(var_58h) = v0;
0x00054ca8 jalr t9 | t9 ();
0x00054cac lw v0, 0x58(sp) | v0 = *(var_58h);
0x00054cb0 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054cb4 bgez v0, 0x54c04 |
| } while (v0 >= 0);
0x00054cb8 addiu v0, zero, 3 | v0 = 3;
| label_6:
0x00054cbc sw v0, (s0) | *(s0) = v0;
0x00054cc0 addiu v0, zero, -1 | v0 = -1;
0x00054cc4 b 0x54d44 | goto label_1;
| label_5:
0x00054cc8 addiu a1, zero, 0xc | a1 = 0xc;
0x00054ccc lw a0, 0x50(sp) | a0 = *(var_50h);
| if (v0 == a1) {
0x00054cd0 bne v0, a1, 0x54d24 |
0x00054cd4 lw t9, -0x782c(gp) | t9 = *((gp - 7691));
0x00054cd8 lw a1, 0x40(sp) | a1 = *(var_40h);
0x00054cdc move a2, v1 | a2 = v1;
0x00054ce0 move a3, s3 | a3 = s3;
0x00054ce4 sw s6, 0x10(sp) | *(var_10h) = s6;
0x00054ce8 bal 0x52d00 | fcn_00052d00 ();
0x00054cec lw gp, 0x20(sp) | gp = *(var_20h);
0x00054cf0 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00054cf4 lw a0, 0x50(sp) | a0 = *(var_50h);
0x00054cf8 jalr t9 | t9 ();
0x00054cfc lw t9, 0xa8(sp) | t9 = *(arg_a8h);
0x00054d00 sw s3, (s1) | *(s1) = s3;
0x00054d04 sw s5, 8(s1) | *((s1 + 2)) = s5;
0x00054d08 sw s2, 0xc(s1) | *((s1 + 3)) = s2;
0x00054d0c sw s4, 0x10(s1) | *((s1 + 4)) = s4;
0x00054d10 sw s4, 4(s1) | *((s1 + 1)) = s4;
0x00054d14 sw s1, (t9) | *(t9) = s1;
0x00054d18 move v0, zero | v0 = 0;
0x00054d1c sw zero, (s0) | *(s0) = 0;
0x00054d20 b 0x54d44 |
| } else {
0x00054d24 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x00054d28 jalr t9 | t9 ();
0x00054d2c nop |
0x00054d30 addiu v0, zero, 4 | v0 = 4;
| label_4:
0x00054d34 sw v0, (s0) | *(s0) = v0;
0x00054d38 addiu v0, zero, 2 | v0 = 2;
0x00054d3c b 0x54d44 | goto label_1;
| label_0:
0x00054d40 addiu v0, zero, 0x16 | v0 = 0x16;
| }
| label_1:
0x00054d44 lw ra, 0x8c(sp) | ra = *(var_8ch);
| label_2:
0x00054d48 lw fp, 0x88(sp) | fp = *(var_88h);
0x00054d4c lw s7, 0x84(sp) | s7 = *(var_84h);
0x00054d50 lw s6, 0x80(sp) | s6 = *(var_80h);
0x00054d54 lw s5, 0x7c(sp) | s5 = *(var_7ch);
0x00054d58 lw s4, 0x78(sp) | s4 = *(var_78h);
0x00054d5c lw s3, 0x74(sp) | s3 = *(var_74h);
0x00054d60 lw s2, 0x70(sp) | s2 = *(var_70h);
0x00054d64 lw s1, 0x6c(sp) | s1 = *(var_6ch);
0x00054d68 lw s0, 0x68(sp) | s0 = *(var_68h);
0x00054d6c addiu sp, sp, 0x90 |
0x00054d70 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x54d80 */
| #include <stdint.h>
|
; (fcn) sym.gethostbyname_r () | void gethostbyname_r () {
0x00054d80 lui gp, 7 |
0x00054d84 addiu gp, gp, -0x36a0 |
0x00054d88 addu gp, gp, t9 | gp += t9;
0x00054d8c addiu sp, sp, -0x90 |
0x00054d90 sw s6, 0x80(sp) | *(var_80h) = s6;
0x00054d94 lw s6, 0xa0(sp) | s6 = *(arg_a0h);
0x00054d98 sw gp, 0x20(sp) | *(var_20h) = gp;
0x00054d9c sw s7, 0x84(sp) | *(var_84h) = s7;
0x00054da0 sw s1, 0x6c(sp) | *(var_6ch) = s1;
0x00054da4 sw ra, 0x8c(sp) | *(var_8ch) = ra;
0x00054da8 sw fp, 0x88(sp) | *(var_88h) = fp;
0x00054dac sw s5, 0x7c(sp) | *(var_7ch) = s5;
0x00054db0 sw s4, 0x78(sp) | *(var_78h) = s4;
0x00054db4 sw s3, 0x74(sp) | *(var_74h) = s3;
0x00054db8 sw s2, 0x70(sp) | *(var_70h) = s2;
0x00054dbc sw s0, 0x68(sp) | *(var_68h) = s0;
0x00054dc0 lw s1, 0xa4(sp) | s1 = *(arg_a4h);
0x00054dc4 sw zero, (s6) | *(s6) = 0;
0x00054dc8 addiu s7, zero, 0x16 | s7 = 0x16;
| if (a0 == 0) {
0x00054dcc beqz a0, 0x550c8 | goto label_0;
| }
0x00054dd0 lw t0, -0x7560(gp) | t0 = *((gp - 7512));
0x00054dd4 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00054dd8 lw t9, -0x77fc(gp) | t9 = *((gp - 7679));
0x00054ddc addu s3, t0, v1 | s3 = t0 + v1;
0x00054de0 move s0, a1 | s0 = a1;
0x00054de4 move s4, a2 | s4 = a2;
0x00054de8 lw fp, (s3) | fp = *(s3);
0x00054dec move s2, a3 | s2 = a3;
0x00054df0 sw zero, (s3) | *(s3) = 0;
0x00054df4 addiu a1, zero, 2 | a1 = 2;
0x00054df8 sw a3, 0x10(sp) | *(var_10h) = a3;
0x00054dfc sw t0, 0x5c(sp) | *(var_5ch) = t0;
0x00054e00 sw s6, 0x14(sp) | *(var_14h) = s6;
0x00054e04 sw s1, 0x18(sp) | *(var_18h) = s1;
0x00054e08 move a2, s0 | a2 = s0;
0x00054e0c move a3, s4 | a3 = s4;
0x00054e10 move s5, a0 | s5 = a0;
0x00054e14 bal 0x54990 | fcn_00054990 ();
0x00054e18 move s7, v0 | s7 = v0;
0x00054e1c lw gp, 0x20(sp) | gp = *(var_20h);
0x00054e20 lw t0, 0x5c(sp) | t0 = *(var_5ch);
| if (v0 == 0) {
0x00054e24 bnez v0, 0x54e30 |
0x00054e28 sw fp, (s3) | *(s3) = fp;
0x00054e2c b 0x550c8 | goto label_0;
| }
0x00054e30 lw v0, (s1) | v0 = *(s1);
0x00054e34 addiu v1, zero, 1 | v1 = 1;
0x00054e38 addiu v1, zero, 4 | v1 = 4;
| if (v0 != v1) {
0x00054e3c beq v0, v1, 0x54e58 |
0x00054e40 addiu v1, zero, -1 | v1 = -1;
| if (v0 == v1) {
0x00054e44 beq v0, v1, 0x54e70 | goto label_1;
| }
0x00054e48 lw ra, 0x8c(sp) | ra = *(var_8ch);
| if (v0 != v1) {
0x00054e4c bne v0, v1, 0x550cc | goto label_2;
| }
0x00054e50 lw v1, (s3) | v1 = *(s3);
0x00054e54 b 0x54e64 |
| } else {
0x00054e58 xori s7, s7, 2 | s7 ^= 2;
0x00054e5c sltiu s7, s7, 1 | s7 = (s7 < 1) ? 1 : 0;
0x00054e60 b 0x54e74 | goto label_3;
| }
0x00054e64 addiu v0, zero, 2 | v0 = 2;
0x00054e68 lw ra, 0x8c(sp) | ra = *(var_8ch);
| if (v1 != v0) {
0x00054e6c bne v1, v0, 0x550cc | goto label_2;
| }
| label_1:
0x00054e70 move s7, zero | s7 = 0;
| label_3:
0x00054e74 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00054e78 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00054e7c addu t0, t0, v1 | t0 += v1;
0x00054e80 addiu v0, zero, -1 | v0 = -1;
0x00054e84 sw fp, (t0) | *(t0) = fp;
0x00054e88 sw v1, 0x58(sp) | *(var_58h) = v1;
0x00054e8c sw v0, (s1) | *(s1) = v0;
0x00054e90 move a0, s5 | a0 = s5;
0x00054e94 bal 0x3b6e0 | sym_strlen ();
0x00054e98 addiu fp, v0, 1 | fp = v0 + 1;
0x00054e9c slt v0, fp, s2 | v0 = (fp < s2) ? 1 : 0;
0x00054ea0 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054ea4 bnez v0, 0x54eb0 |
| while (a0 != 0) {
0x00054ea8 addiu s7, zero, 0x22 | s7 = 0x22;
0x00054eac b 0x550c8 | goto label_0;
0x00054eb0 lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00054eb4 move a0, s4 | a0 = s4;
0x00054eb8 move a2, fp | a2 = fp;
0x00054ebc move a1, s5 | a1 = s5;
0x00054ec0 bal 0x3a830 | sym_memcpy ();
0x00054ec4 addu v0, s4, fp | v0 = s4 + fp;
0x00054ec8 negu s3, v0 | __asm ("negu s3, v0");
0x00054ecc subu s2, s2, fp | __asm ("subu s2, s2, fp");
0x00054ed0 andi s3, s3, 3 | s3 &= 3;
0x00054ed4 subu v1, s2, s3 | __asm ("subu v1, s2, s3");
0x00054ed8 addiu fp, v1, -8 | fp = v1 + -8;
0x00054edc slti a0, fp, 0x100 | a0 = (fp < aav.0x00000100) ? 1 : 0;
0x00054ee0 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054ee4 bnez a0, 0x54ea8 |
| }
0x00054ee8 addu s3, v0, s3 | s3 = v0 + s3;
0x00054eec lw t9, -0x7864(gp) | t9 = *((gp - 7705));
0x00054ef0 addiu a2, s3, 0x10 | a2 = s3 + 0x10;
0x00054ef4 sw s4, (s3) | *(s3) = s4;
0x00054ef8 sw zero, 4(s3) | *((s3 + 1)) = 0;
0x00054efc move a1, a2 | a1 = a2;
0x00054f00 sw v1, 0x5c(sp) | *(var_5ch) = v1;
0x00054f04 sw a2, 0x60(sp) | *(var_60h) = a2;
0x00054f08 move a0, s5 | a0 = s5;
0x00054f0c bal 0x526d0 | sym_inet_aton ();
0x00054f10 addiu s2, s3, 8 | s2 = s3 + 8;
0x00054f14 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054f18 lw v1, 0x5c(sp) | v1 = *(var_5ch);
0x00054f1c lw a2, 0x60(sp) | a2 = *(var_60h);
| if (v0 != 0) {
0x00054f20 beqz v0, 0x54f58 |
0x00054f24 addiu v0, zero, 2 | v0 = 2;
0x00054f28 sw a2, 8(s3) | *((s3 + 2)) = a2;
0x00054f2c sw zero, 0xc(s3) | *((s3 + 3)) = 0;
0x00054f30 sw v0, 8(s0) | *((s0 + 2)) = v0;
0x00054f34 addiu v0, zero, 4 | v0 = 4;
0x00054f38 sw s4, (s0) | *(s0) = s4;
0x00054f3c sw s3, 4(s0) | *((s0 + 1)) = s3;
0x00054f40 sw v0, 0xc(s0) | *((s0 + 3)) = v0;
0x00054f44 sw s2, 0x10(s0) | *((s0 + 4)) = s2;
0x00054f48 move s7, zero | s7 = 0;
0x00054f4c sw s0, (s6) | *(s6) = s0;
0x00054f50 sw zero, (s1) | *(s1) = 0;
0x00054f54 b 0x550c8 | goto label_0;
| }
0x00054f58 addiu v0, zero, 1 | v0 = 1;
| if (s7 == 0) {
0x00054f5c bnez s7, 0x54f94 |
0x00054f60 lw t9, -0x7800(gp) | t9 = *((gp - 7680));
0x00054f64 addiu v1, v1, -0x14 | v1 += -0x14;
0x00054f68 sw s2, 0x44(sp) | *(var_44h) = s2;
0x00054f6c sw v1, 0x48(sp) | *(var_48h) = v1;
0x00054f70 sw zero, 0x4c(sp) | *(var_4ch) = 0;
0x00054f74 move a0, s5 | a0 = s5;
0x00054f78 addiu a1, zero, 1 | a1 = 1;
0x00054f7c addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x00054f80 addiu a3, sp, 0x28 | a3 = sp + 0x28;
0x00054f84 bal 0x532e0 | fcn_000532e0 ();
0x00054f88 lw gp, 0x20(sp) | gp = *(var_20h);
| if (v0 >= 0) {
0x00054f8c bgez v0, 0x54fa0 | goto label_4;
| }
0x00054f90 addiu v0, zero, 1 | v0 = 1;
| }
0x00054f94 sw v0, (s1) | *(s1) = v0;
0x00054f98 addiu s7, zero, 2 | s7 = 2;
0x00054f9c b 0x550c8 | goto label_0;
| label_4:
0x00054fa0 lw v1, 0x2c(sp) | v1 = *(var_2ch);
0x00054fa4 addiu v0, zero, 1 | v0 = 1;
0x00054fa8 lw v1, -0x756c(gp) | v1 = *((gp - 7515));
| if (v1 != v0) {
0x00054fac bne v1, v0, 0x55098 | goto label_5;
| }
0x00054fb0 lw v0, 0x4c(sp) | v0 = *(var_4ch);
0x00054fb4 lw a2, 0x38(sp) | a2 = *(var_38h);
0x00054fb8 addiu s5, v0, 3 | s5 = v0 + 3;
0x00054fbc mul a2, v0, a2 | __asm ("mul a2, v0, a2");
0x00054fc0 sll s5, s5, 2 | s5 <<= 2;
0x00054fc4 addu v0, s5, a2 | v0 = s5 + a2;
0x00054fc8 subu fp, fp, v0 | __asm ("subu fp, fp, v0");
0x00054fcc addiu s7, zero, 0x22 | s7 = 0x22;
| if (fp < 0) {
0x00054fd0 bltz fp, 0x550ac | goto label_6;
| }
0x00054fd4 lw t9, -0x7f04(gp) | t9 = *((gp - 8129));
0x00054fd8 addu a0, s2, s5 | a0 = s2 + s5;
0x00054fdc move a1, s2 | a1 = s2;
0x00054fe0 bal 0x3aee0 | sym_memmove ();
0x00054fe4 lw gp, 0x20(sp) | gp = *(var_20h);
0x00054fe8 addiu s5, s5, -4 | s5 += -4;
0x00054fec lw a1, 0x3c(sp) | a1 = *(s2);
0x00054ff0 lw t9, -0x7f1c(gp) | t9 = *((gp - 8135));
0x00054ff4 addu s5, s2, s5 | s5 = s2 + s5;
0x00054ff8 move a0, s5 | a0 = s5;
0x00054ffc addiu a2, zero, 4 | a2 = 4;
0x00055000 bal 0x3a830 | sym_memcpy ();
0x00055004 lw gp, 0x20(sp) | gp = *(var_20h);
0x00055008 move v0, zero | v0 = 0;
0x0005500c b 0x5501c |
| while (a0 == 0) {
0x00055010 sw s5, (v1) | *(v1) = s5;
0x00055014 addiu v0, v0, 1 | v0++;
0x00055018 addiu s5, s5, 4 | s5 += 4;
0x0005501c lw a0, 0x4c(sp) | a0 = *(var_4ch);
0x00055020 sll v1, v0, 2 | v1 = v0 << 2;
0x00055024 sltu a0, a0, v0 | a0 = (a0 < v0) ? 1 : 0;
0x00055028 addu v1, s2, v1 | v1 = s2 + v1;
0x0005502c beqz a0, 0x55010 |
| }
0x00055030 lw s7, 0x28(sp) | s7 = *(var_28h);
0x00055034 sw zero, (v1) | *(v1) = 0;
| if (s7 != 0) {
0x00055038 beqz s7, 0x5506c |
0x0005503c lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00055040 move a0, s7 | a0 = s7;
0x00055044 bal 0x3b6e0 | sym_strlen ();
0x00055048 sltu v0, v0, fp | v0 = (v0 < fp) ? 1 : 0;
0x0005504c lw gp, 0x20(sp) | gp = *(var_20h);
| if (v0 == 0) {
0x00055050 beqz v0, 0x5506c | goto label_7;
| }
0x00055054 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00055058 move a0, s5 | a0 = s5;
0x0005505c move a1, s7 | a1 = s7;
0x00055060 bal 0x3b630 | sym_strcpy ()
0x00055064 lw gp, 0x20(sp) | gp = *(var_20h);
0x00055068 move s4, s5 | s4 = s5;
| }
| label_7:
0x0005506c addiu v0, zero, 2 | v0 = 2;
0x00055070 sw v0, 8(s0) | *((s0 + 2)) = v0;
0x00055074 addiu v0, zero, 4 | v0 = 4;
0x00055078 sw s4, (s0) | *(s0) = s4;
0x0005507c sw s3, 4(s0) | *((s0 + 1)) = s3;
0x00055080 sw v0, 0xc(s0) | *((s0 + 3)) = v0;
0x00055084 sw s2, 0x10(s0) | *((s0 + 4)) = s2;
0x00055088 move s7, zero | s7 = 0;
0x0005508c sw s0, (s6) | *(s6) = s0;
0x00055090 sw zero, (s1) | *(s1) = 0;
0x00055094 b 0x550ac | goto label_6;
| label_5:
0x00055098 lw t9, 0x58(sp) | t9 = *(var_58h);
0x0005509c sw v0, (s1) | *(s1) = v0;
0x000550a0 addiu s7, zero, 2 | s7 = 2;
0x000550a4 addu v1, v1, t9 | v1 += t9;
0x000550a8 sw v0, (v1) | *(v1) = v0;
| label_6:
0x000550ac lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x000550b0 lw a0, 0x28(sp) | a0 = *(var_28h);
0x000550b4 jalr t9 | t9 ();
0x000550b8 lw gp, 0x20(sp) | gp = *(var_20h);
0x000550bc lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x000550c0 lw a0, 0x50(sp) | a0 = *(var_50h);
0x000550c4 jalr t9 | t9 ();
| label_0:
0x000550c8 lw ra, 0x8c(sp) | ra = *(var_8ch);
| label_2:
0x000550cc move v0, s7 | v0 = s7;
0x000550d0 lw fp, 0x88(sp) | fp = *(var_88h);
0x000550d4 lw s7, 0x84(sp) | s7 = *(var_84h);
0x000550d8 lw s6, 0x80(sp) | s6 = *(var_80h);
0x000550dc lw s5, 0x7c(sp) | s5 = *(var_7ch);
0x000550e0 lw s4, 0x78(sp) | s4 = *(var_78h);
0x000550e4 lw s3, 0x74(sp) | s3 = *(var_74h);
0x000550e8 lw s2, 0x70(sp) | s2 = *(var_70h);
0x000550ec lw s1, 0x6c(sp) | s1 = *(var_6ch);
0x000550f0 lw s0, 0x68(sp) | s0 = *(var_68h);
0x000550f4 addiu sp, sp, 0x90 |
0x000550f8 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x520c4 */
| #include <stdint.h>
|
; (fcn) sym.inet_ntop () | void inet_ntop () {
0x000520c4 lui gp, 7 |
0x000520c8 addiu gp, gp, -0x9e4 |
0x000520cc addu gp, gp, t9 | gp += t9;
0x000520d0 addiu sp, sp, -0x98 |
0x000520d4 addiu v0, zero, 2 | v0 = 2;
0x000520d8 sw gp, 0x10(sp) | *(var_10h) = gp;
0x000520dc sw ra, 0x94(sp) | *(var_94h) = ra;
0x000520e0 sw fp, 0x90(sp) | *(var_90h) = fp;
0x000520e4 sw s7, 0x8c(sp) | *(var_8ch) = s7;
0x000520e8 sw s6, 0x88(sp) | *(var_88h) = s6;
0x000520ec sw s5, 0x84(sp) | *(var_84h) = s5;
0x000520f0 sw s4, 0x80(sp) | *(var_80h) = s4;
0x000520f4 sw s3, 0x7c(sp) | *(var_7ch) = s3;
0x000520f8 sw s2, 0x78(sp) | *(var_78h) = s2;
0x000520fc sw s1, 0x74(sp) | *(var_74h) = s1;
0x00052100 sw s0, 0x70(sp) | *(var_70h) = s0;
0x00052104 lw t9, -0x7908(gp) | t9 = *((gp - 7746));
| if (a0 != v0) {
0x00052108 beq a0, v0, 0x52120 |
0x0005210c addiu v0, zero, 0xa | v0 = 0xa;
0x00052110 lw t9, -0x7fe4(gp) | t9 = *((gp - 8185));
| if (a0 != v0) {
0x00052114 bne a0, v0, 0x523b8 | goto label_1;
| }
0x00052118 addiu a0, sp, 0x48 | a0 = sp + 0x48;
0x0005211c b 0x5213c |
| } else {
0x00052120 move a0, a1 | a0 = a1;
0x00052124 move a1, a2 | a1 = a2;
0x00052128 addiu t9, t9, 0x1f60 | t9 += 0x1f60;
0x0005212c move a2, a3 | a2 = a3;
0x00052130 bal 0x51f60 | fcn_00051f60 ();
0x00052134 b 0x523b0 | goto label_2;
0x00052138 nop |
| }
0x0005213c move s6, a1 | s6 = a1;
0x00052140 move s4, a2 | s4 = a2;
0x00052144 move a1, zero | a1 = 0;
0x00052148 addiu a2, zero, 0x20 | a2 = 0x20;
0x0005214c move s5, a3 | s5 = a3;
0x00052150 bal 0x3a970 | sym_memset ();
0x00052154 lw gp, 0x10(sp) | gp = *(var_10h);
0x00052158 move v0, zero | v0 = 0;
0x0005215c addiu a0, zero, 0x10 | a0 = 0x10;
| do {
0x00052160 sra a1, v0, 1 | a1 = v0 >> 1;
0x00052164 addiu v1, sp, 0x18 | v1 = sp + 0x18;
0x00052168 sll a1, a1, 2 | a1 <<= 2;
0x0005216c addu a1, v1, a1 | a1 = v1 + a1;
0x00052170 addu v1, s6, v0 | v1 = s6 + v0;
0x00052174 lbu a2, 1(v1) | a2 = *((v1 + 1));
0x00052178 lbu v1, (v1) | v1 = *(v1);
0x0005217c addiu v0, v0, 2 | v0 += 2;
0x00052180 sll v1, v1, 8 | v1 <<= 8;
0x00052184 or v1, a2, v1 | v1 = a2 | v1;
0x00052188 sw v1, 0x30(a1) | *(var_48h) = v1;
0x0005218c bne v0, a0, 0x52160 |
| } while (v0 != a0);
0x00052190 addiu s1, zero, -1 | s1 = -1;
0x00052194 addiu v0, zero, -1 | v0 = -1;
0x00052198 move v1, zero | v1 = 0;
0x0005219c addiu a0, zero, -1 | a0 = -1;
0x000521a0 addiu a1, zero, 8 | a1 = 8;
0x000521a4 sll a2, v1, 2 | a2 = v1 << 2;
| do {
0x000521a8 addiu a3, sp, 0x18 | a3 = sp + 0x18;
0x000521ac addu a2, a3, a2 | a2 = a3 + a2;
0x000521b0 lw a2, 0x30(a2) | a2 = *(var_48h);
| if (a2 == 0) {
0x000521b4 bnez a2, 0x521cc |
0x000521b8 nop |
| if (v0 != a0) {
0x000521bc beql v0, a0, 0x521ec |
0x000521c0 move v0, v1 | v0 = v1;
0x000521c4 addiu s3, s3, 1 | s3++;
0x000521c8 b 0x52200 |
| if (v0 == a0) {
| } else {
0x000521cc beql v0, a0, 0x52204 | goto label_3;
| }
0x000521d0 addiu v1, v1, 1 | v1++;
0x000521d4 slt a2, s2, s3 | a2 = (s2 < s3) ? 1 : 0;
| if (s1 != a0) {
0x000521d8 beq s1, a0, 0x521f4 |
0x000521dc move s2, s3 | s2 = s3;
| if (a2 != 0) {
0x000521e0 bnel a2, zero, 0x521f8 |
0x000521e4 addiu v0, zero, -1 | v0 = -1;
0x000521e8 b 0x52200 |
| } else {
0x000521ec addiu s3, zero, 1 | s3 = 1;
| }
0x000521f0 b 0x52200 |
| } else {
0x000521f4 move s2, s3 | s2 = s3;
| }
0x000521f8 move s1, v0 | s1 = v0;
0x000521fc addiu v0, zero, -1 | v0 = -1;
| }
| }
0x00052200 addiu v1, v1, 1 | v1++;
| label_3:
0x00052204 sll a2, v1, 2 | a2 = v1 << 2;
0x00052208 bne v1, a1, 0x521a8 |
| } while (v1 != a1);
0x0005220c addiu v1, zero, -1 | v1 = -1;
| if (v0 != v1) {
0x00052210 beq v0, v1, 0x5222c |
0x00052214 nop |
0x00052218 slt v1, s2, s3 | v1 = (s2 < s3) ? 1 : 0;
| if (s1 == v1) {
0x0005221c beq s1, v1, 0x523d8 | goto label_4;
| }
| if (v1 != 0) {
0x00052220 movz v0, s1, v1 | v0 = s1;
| }
| if (v1 == 0) {
0x00052224 movn s2, s3, v1 | s2 = s3;
| }
0x00052228 b 0x523dc | goto label_5;
| }
0x0005222c lw v1, -0x7fd0(gp) | v1 = *((gp - 8180));
| if (s1 != v0) {
0x00052230 beq s1, v0, 0x52244 |
| label_0:
0x00052234 slti v1, s2, 2 | v1 = (s2 < 2) ? 1 : 0;
0x00052238 addiu v0, zero, -1 | v0 = -1;
| if (v1 == 0) {
0x0005223c movn s1, v0, v1 | s1 = v0;
| }
0x00052240 lw v1, -0x7fd0(gp) | v1 = *((gp - 8180));
| }
0x00052244 lw t9, -0x7f74(gp) | t9 = *((gp - 8157));
0x00052248 addiu s0, sp, 0x18 | s0 = sp + 0x18;
0x0005224c move s3, zero | s3 = 0;
0x00052250 move fp, s0 | fp = s0;
0x00052254 addiu s7, v1, 0x7b90 | s7 = v1 + 0x7b90;
0x00052258 addu a3, s1, s2 | a3 = s1 + s2;
0x0005225c addiu v0, zero, -1 | v0 = -1;
| do {
0x00052260 slt v0, s3, s1 | v0 = (s3 < s1) ? 1 : 0;
| if (s1 != v0) {
0x00052264 beq s1, v0, 0x52290 |
0x00052268 slt v0, s3, a3 | v0 = (s3 < a3) ? 1 : 0;
| if (v0 == 0) {
0x0005226c bnez v0, 0x52290 |
| if (v0 == 0) {
0x00052270 beqz v0, 0x52290 | goto label_6;
| }
0x00052274 nop |
0x00052278 addiu s3, s3, 1 | s3++;
| if (s3 == s1) {
0x0005227c bnel s3, s1, 0x52344 | goto label_7;
| }
0x00052280 addiu v0, zero, 0x3a | v0 = 0x3a;
0x00052284 sb v0, (s0) | *(s0) = v0;
0x00052288 addiu s0, s0, 1 | s0++;
0x0005228c b 0x52340 |
| }
| } else {
| label_6:
0x00052290 sll v0, s3, 2 | v0 = s3 << 2;
| if (s3 != 0) {
0x00052294 beqz s3, 0x52314 |
0x00052298 addiu v0, zero, 0x3a | v0 = 0x3a;
0x0005229c sb v0, (s0) | *(s0) = v0;
0x000522a0 addiu v0, zero, 6 | v0 = 6;
0x000522a4 addiu s0, s0, 1 | s0++;
| if (s3 == v0) {
0x000522a8 bne s3, v0, 0x52310 |
0x000522ac sll v0, s3, 2 | v0 = s3 << 2;
| if (s1 != 0) {
0x000522b0 bnez s1, 0x52314 | goto label_8;
| }
0x000522b4 addiu v0, zero, 5 | v0 = 5;
| if (s2 != s3) {
0x000522b8 beq s2, s3, 0x522d4 |
0x000522bc sll v0, s3, 2 | v0 = s3 << 2;
| if (s2 != v0) {
0x000522c0 bne s2, v0, 0x52314 | goto label_8;
| }
0x000522c4 lw a0, 0x5c(sp) | a0 = *(var_5ch);
0x000522c8 ori v0, zero, 0xffff | v0 = 0xffff;
0x000522cc sll v0, s3, 2 | v0 = s3 << 2;
| if (a0 != v0) {
0x000522d0 bne a0, v0, 0x52314 | goto label_8;
| }
| }
0x000522d4 lw t9, -0x7908(gp) | t9 = *((gp - 7746));
0x000522d8 subu a2, sp, s0 | __asm ("subu a2, sp, s0");
0x000522dc addiu a0, s6, 0xc | a0 = s6 + 0xc;
0x000522e0 move a1, s0 | a1 = s0;
0x000522e4 addiu t9, t9, 0x1f60 | t9 += 0x1f60;
0x000522e8 addiu a2, a2, 0x46 | a2 += 0x46;
0x000522ec bal 0x51f60 | fcn_00051f60 ();
0x000522f0 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 == 0) {
0x000522f4 beqz v0, 0x523d0 | goto label_9;
| }
0x000522f8 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x000522fc move a0, s0 | a0 = s0;
0x00052300 bal 0x3b6e0 | sym_strlen ();
0x00052304 addu s0, s0, v0 | s0 += v0;
0x00052308 lw gp, 0x10(sp) | gp = *(var_10h);
0x0005230c b 0x52358 | goto label_10;
| }
0x00052310 sll v0, s3, 2 | v0 = s3 << 2;
| }
| label_8:
0x00052314 addu v0, fp, v0 | v0 = fp + v0;
0x00052318 lw a2, 0x30(v0) | a2 = *(var_48h);
0x0005231c move a0, s0 | a0 = s0;
0x00052320 sw a3, 0x6c(sp) | *(var_6ch) = a3;
0x00052324 sw t9, 0x68(sp) | *(var_68h) = t9;
0x00052328 move a1, s7 | a1 = s7;
0x0005232c jalr t9 | t9 ();
0x00052330 lw gp, 0x10(sp) | gp = *(var_10h);
0x00052334 lw t9, 0x68(sp) | t9 = *(var_68h);
0x00052338 lw a3, 0x6c(sp) | a3 = *(var_6ch);
0x0005233c addu s0, s0, v0 | s0 += v0;
| }
0x00052340 addiu s3, s3, 1 | s3++;
| label_7:
0x00052344 addiu v0, zero, 8 | v0 = 8;
0x00052348 addiu v0, zero, -1 | v0 = -1;
0x0005234c bne s3, v0, 0x52260 |
| } while (s3 != v0);
| if (s1 != v0) {
0x00052350 beql s1, v0, 0x52378 |
0x00052354 sb zero, (s0) | *(s0) = 0;
| label_10:
0x00052358 addu s1, s1, s2 | s1 += s2;
0x0005235c addiu v0, zero, 8 | v0 = 8;
0x00052360 sb zero, (s0) | *(s0) = 0;
| if (s1 == v0) {
0x00052364 bnel s1, v0, 0x52378 | goto label_11;
| }
0x00052368 addiu v0, zero, 0x3a | v0 = 0x3a;
0x0005236c sb v0, (s0) | *(s0) = v0;
0x00052370 addiu s0, s0, 1 | s0++;
0x00052374 sb zero, (s0) | *(s0) = 0;
| }
| label_11:
0x00052378 addiu a1, sp, 0x18 | a1 = sp + 0x18;
0x0005237c addiu s0, s0, 1 | s0++;
0x00052380 subu s0, s0, a1 | __asm ("subu s0, s0, a1");
0x00052384 sltu s5, s5, s0 | s5 = (s5 < s0) ? 1 : 0;
| if (s5 != 0) {
0x00052388 beql s5, zero, 0x523a8 |
0x0005238c lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00052390 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00052394 move v0, v1 | v0 = v1;
0x00052398 lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x0005239c addu v0, v1, v0 | v0 = v1 + v0;
0x000523a0 addiu v1, zero, 0x1c | v1 = 0x1c;
0x000523a4 b 0x523cc |
| } else {
0x000523a8 move a0, s4 | a0 = s4;
0x000523ac bal 0x3b630 | sym_strcpy ()
| label_2:
0x000523b0 lw ra, 0x94(sp) | ra = *(var_94h);
0x000523b4 b 0x523e8 | goto label_12;
| label_1:
0x000523b8 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x000523bc move v0, v1 | v0 = v1;
0x000523c0 lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x000523c4 addu v0, v1, v0 | v0 = v1 + v0;
0x000523c8 addiu v1, zero, 0x7c | v1 = 0x7c;
| }
0x000523cc sw v1, (v0) | *(v0) = v1;
| label_9:
0x000523d0 move v0, zero | v0 = 0;
0x000523d4 b 0x523e4 | goto label_13;
| label_4:
0x000523d8 move s2, s3 | s2 = s3;
| label_5:
0x000523dc move s1, v0 | s1 = v0;
0x000523e0 b 0x52234 | goto label_0;
| label_13:
0x000523e4 lw ra, 0x94(sp) | ra = *(var_94h);
| label_12:
0x000523e8 lw fp, 0x90(sp) | fp = *(var_90h);
0x000523ec lw s7, 0x8c(sp) | s7 = *(var_8ch);
0x000523f0 lw s6, 0x88(sp) | s6 = *(var_88h);
0x000523f4 lw s5, 0x84(sp) | s5 = *(var_84h);
0x000523f8 lw s4, 0x80(sp) | s4 = *(var_80h);
0x000523fc lw s3, 0x7c(sp) | s3 = *(var_7ch);
0x00052400 lw s2, 0x78(sp) | s2 = *(var_78h);
0x00052404 lw s1, 0x74(sp) | s1 = *(var_74h);
0x00052408 lw s0, 0x70(sp) | s0 = *(var_70h);
0x0005240c addiu sp, sp, 0x98 |
0x00052410 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x47a3c */
| #include <stdint.h>
|
; (fcn) sym.ruserpass () | void ruserpass () {
0x00047a3c lui gp, 8 |
0x00047a40 addiu gp, gp, -0x635c |
0x00047a44 addu gp, gp, t9 | gp += t9;
0x00047a48 lw t9, -0x7f84(gp) | t9 = *((gp - 8161));
0x00047a4c addiu sp, sp, -0x4e0 |
0x00047a50 sw ra, 0x4dc(sp) | *(var_4dch) = ra;
0x00047a54 sw fp, 0x4d8(sp) | *(var_4d8h) = fp;
0x00047a58 sw s7, 0x4d4(sp) | *(var_4d4h) = s7;
0x00047a5c move fp, sp | fp = sp;
0x00047a60 sw s5, 0x4cc(sp) | *(var_4cch) = s5;
0x00047a64 sw s2, 0x4c0(sp) | *(var_4c0h) = s2;
0x00047a68 sw s0, 0x4b8(sp) | *(var_4b8h) = s0;
0x00047a6c sw gp, 0x10(sp) | *(dest) = gp;
0x00047a70 sw s6, 0x4d0(sp) | *(var_4d0h) = s6;
0x00047a74 sw s4, 0x4c8(sp) | *(var_4c8h) = s4;
0x00047a78 sw s3, 0x4c4(sp) | *(var_4c4h) = s3;
0x00047a7c sw s1, 0x4bc(sp) | *(var_4bch) = s1;
0x00047a80 move s2, a0 | s2 = a0;
0x00047a84 move s5, a1 | s5 = a1;
0x00047a88 move s7, a2 | s7 = a2;
0x00047a8c jalr t9 | t9 ();
0x00047a90 lw gp, 0x10(fp) | gp = *(dest);
0x00047a94 lw t9, -0x7aa8(gp) | t9 = *((gp - 7850));
0x00047a98 move s0, v0 | s0 = v0;
0x00047a9c jalr t9 | t9 ();
0x00047aa0 lw gp, 0x10(fp) | gp = *(dest);
| if (s0 != v0) {
0x00047aa4 beq s0, v0, 0x47ab0 |
0x00047aa8 addiu s1, zero, -1 | s1 = -1;
0x00047aac b 0x47f0c | goto label_3;
| }
0x00047ab0 lw t9, -0x7960(gp) | t9 = *((gp - 7768));
0x00047ab4 jalr t9 | t9 ();
0x00047ab8 nop |
0x00047abc lw gp, 0x10(fp) | gp = *(dest);
0x00047ac0 lw t9, -0x7aa4(gp) | t9 = *((gp - 7849));
0x00047ac4 move s0, v0 | s0 = v0;
0x00047ac8 jalr t9 | t9 ();
0x00047acc lw gp, 0x10(fp) | gp = *(dest);
| if (s0 != v0) {
0x00047ad0 bne s0, v0, 0x47f08 | goto label_4;
| }
0x00047ad4 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00047ad8 lw t9, -0x7f88(gp) | t9 = *((gp - 8162));
0x00047adc addiu a0, a0, 0x54f0 | a0 += 0x54f0;
0x00047ae0 bal 0x5b510 | sym_getenv ();
0x00047ae4 move s1, v0 | s1 = v0;
0x00047ae8 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 == 0) {
0x00047aec beqz v0, 0x47f08 | goto label_4;
| }
0x00047af0 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00047af4 move a0, v0 | a0 = v0;
0x00047af8 bal 0x3b6e0 | sym_strlen ();
0x00047afc addiu v0, v0, 0x16 | v0 += 0x16;
0x00047b00 lw gp, 0x10(fp) | gp = *(dest);
0x00047b04 srl v0, v0, 3 | v0 >>= 3;
0x00047b08 sll v0, v0, 3 | v0 <<= 3;
0x00047b0c subu sp, sp, v0 |
0x00047b10 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00047b14 addiu s0, sp, 0x10 | s0 = sp + 0x10;
0x00047b18 move a0, s0 | a0 = s0;
0x00047b1c move a1, s1 | a1 = s1;
0x00047b20 bal 0x3b630 | sym_strcpy ()
0x00047b24 lw gp, 0x10(fp) | gp = *(dest);
0x00047b28 move a0, s0 | a0 = s0;
0x00047b2c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00047b30 lw t9, -0x7e00(gp) | t9 = *((gp - 8064));
0x00047b34 addiu a1, a1, 0x7320 | a1 += 0x7320;
0x00047b38 bal 0x3b3d0 | sym_strcat ();
0x00047b3c lw gp, 0x10(fp) | gp = *(dest);
0x00047b40 move a0, s0 | a0 = s0;
0x00047b44 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00047b48 lw t9, -0x7dd4(gp) | t9 = *((gp - 8053));
0x00047b4c addiu a1, a1, 0x4bfc | a1 += 0x4bfc;
0x00047b50 bal 0x2e630 | sym_fopen ();
0x00047b54 lw gp, 0x10(fp) | gp = *(dest);
0x00047b58 lw s3, -0x7ed0(gp) | s3 = *((gp - 8116));
0x00047b5c sw v0, -0x2420(s3) | *((s3 - 2312)) = v0;
| if (v0 == 0) {
0x00047b60 bnez v0, 0x47ba0 |
0x00047b64 rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x00047b68 move v0, v1 | v0 = v1;
0x00047b6c lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x00047b70 addu v0, v1, v0 | v0 = v1 + v0;
0x00047b74 lw v1, (v0) | v1 = *(v0);
0x00047b78 addiu v0, zero, 2 | v0 = 2;
0x00047b7c move s1, zero | s1 = 0;
| if (v1 == v0) {
0x00047b80 beq v1, v0, 0x47f0c | goto label_3;
| }
0x00047b84 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00047b88 lw t9, -0x795c(gp) | t9 = *((gp - 7767));
0x00047b8c move a1, s0 | a1 = s0;
0x00047b90 addiu a0, a0, 0x4c8c | a0 += 0x4c8c;
0x00047b94 bal 0x2f7b0 | sym_printf ();
0x00047b98 move sp, fp |
0x00047b9c b 0x47f10 | goto label_5;
| }
0x00047ba0 lw t9, -0x7cd4(gp) | t9 = *((gp - 7989));
0x00047ba4 move a0, v0 | a0 = v0;
0x00047ba8 addiu a1, zero, 2 | a1 = 2;
0x00047bac bal 0x32810 | sym_fsetlocking ();
0x00047bb0 lw gp, 0x10(fp) | gp = *(dest);
0x00047bb4 addiu a0, fp, 0x18 | a0 = fp + 0x18;
0x00047bb8 lw t9, -0x7aac(gp) | t9 = *((gp - 7851));
0x00047bbc addiu a1, zero, 0x400 | a1 = aav.0x00000400;
0x00047bc0 jalr t9 | t9 ();
0x00047bc4 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 < 0) {
0x00047bc8 bgez v0, 0x47bd0 |
0x00047bcc sb zero, 0x18(fp) | *(var_18h) = 0;
| }
0x00047bd0 lw t9, -0x7f94(gp) | t9 = *((gp - 8165));
0x00047bd4 addiu a0, fp, 0x18 | a0 = fp + 0x18;
0x00047bd8 addiu a1, zero, 0x2e | a1 = 0x2e;
0x00047bdc bal 0x3b410 | sym_index ();
0x00047be0 move s4, v0 | s4 = v0;
0x00047be4 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 == 0) {
0x00047be8 bnez v0, 0x47c04 |
0x00047bec lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00047bf0 addiu a0, fp, 0x18 | a0 = fp + 0x18;
0x00047bf4 bal 0x3b6e0 | sym_strlen ();
0x00047bf8 lw gp, 0x10(fp) | gp = *(dest);
0x00047bfc addiu v1, fp, 0x18 | v1 = fp + 0x18;
0x00047c00 addu s4, v1, v0 | s4 = v1 + v0;
| }
0x00047c04 lw s0, -0x7ed0(gp) | s0 = *((gp - 8116));
0x00047c08 move s1, zero | s1 = 0;
0x00047c0c addiu s0, s0, -0x241c | s0 += -0x241c;
0x00047c10 b 0x47ed4 | goto label_6;
| label_2:
0x00047c14 addiu v1, zero, 1 | v1 = 1;
0x00047c18 addiu v1, zero, 0xb | v1 = 0xb;
| if (v0 != v1) {
0x00047c1c beq v0, v1, 0x47c64 |
0x00047c20 lw v1, -0x7b10(gp) | v1 = *((gp - 7876));
| if (v0 != v1) {
0x00047c24 bne v0, v1, 0x47ed8 | goto label_7;
| }
0x00047c28 addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
| if (s1 == 0) {
0x00047c2c bnel s1, zero, 0x47e8c | goto label_8;
| }
0x00047c30 jalr t9 | t9 ();
0x00047c34 nop |
0x00047c38 addiu v1, zero, 0xa | v1 = 0xa;
0x00047c3c lw gp, 0x10(fp) | gp = *(dest);
| if (v0 != v1) {
0x00047c40 bne v0, v1, 0x47ed4 | goto label_6;
| }
0x00047c44 lw t9, -0x7da0(gp) | t9 = *((gp - 8040));
0x00047c48 move a0, s2 | a0 = s2;
0x00047c4c move a1, s0 | a1 = s0;
0x00047c50 bal 0x3c390 | sym_strcasecmp ();
0x00047c54 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 != 0) {
0x00047c58 bnez v0, 0x47c6c | goto label_9;
| }
0x00047c5c addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
0x00047c60 b 0x47e8c | goto label_8;
| }
0x00047c64 addiu s1, zero, 1 | s1 = 1;
0x00047c68 b 0x47e88 | goto label_10;
| label_9:
0x00047c6c lw t9, -0x7f94(gp) | t9 = *((gp - 8165));
0x00047c70 move a0, s2 | a0 = s2;
0x00047c74 addiu a1, zero, 0x2e | a1 = 0x2e;
0x00047c78 bal 0x3b410 | sym_index ();
0x00047c7c lw gp, 0x10(fp) | gp = *(dest);
| if (v0 == 0) {
0x00047c80 beqz v0, 0x47ed4 | goto label_6;
| }
0x00047c84 lw t9, -0x7da0(gp) | t9 = *((gp - 8040));
0x00047c88 move a0, v0 | a0 = v0;
0x00047c8c move a1, s4 | a1 = s4;
0x00047c90 sw v0, 0x4b0(fp) | *(var_4b0h) = v0;
0x00047c94 bal 0x3c390 | sym_strcasecmp ();
0x00047c98 lw gp, 0x10(fp) | gp = *(dest);
0x00047c9c lw a2, 0x4b0(fp) | a2 = *(var_4b0h);
| if (v0 != 0) {
0x00047ca0 bnez v0, 0x47ed4 | goto label_6;
| }
0x00047ca4 lw t9, -0x7cf0(gp) | t9 = *((gp - 7996));
0x00047ca8 subu v1, a2, s2 | __asm ("subu v1, a2, s2");
0x00047cac move a2, v1 | a2 = v1;
0x00047cb0 sw v1, 0x4b0(fp) | *(var_4b0h) = v1;
0x00047cb4 move a0, s2 | a0 = s2;
0x00047cb8 move a1, s0 | a1 = s0;
0x00047cbc bal 0x3c5f0 | sym_strncasecmp ();
0x00047cc0 lw gp, 0x10(fp) | gp = *(dest);
0x00047cc4 lw v1, 0x4b0(fp) | v1 = *(var_4b0h);
| if (v0 != 0) {
0x00047cc8 bnez v0, 0x47ed4 | goto label_6;
| }
0x00047ccc addu v1, v1, s0 | v1 += s0;
0x00047cd0 lbu v0, (v1) | v0 = *(v1);
0x00047cd4 move s1, zero | s1 = 0;
0x00047cd8 b 0x47d84 | goto label_11;
| label_0:
0x00047cdc slti v1, v0, 4 | v1 = (v0 < 4) ? 1 : 0;
| if (v0 == v1) {
0x00047ce0 beq v0, v1, 0x47d94 | goto label_12;
| }
| if (v1 != 0) {
0x00047ce4 beql v1, zero, 0x47d00 |
0x00047ce8 slti v0, v0, 6 | v0 = (v0 < 6) ? 1 : 0;
0x00047cec addiu v1, zero, 2 | v1 = 2;
0x00047cf0 lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
| if (v0 != v1) {
0x00047cf4 bne v0, v1, 0x47e78 | goto label_13;
| }
0x00047cf8 b 0x47d10 | goto label_14;
0x00047cfc nop |
| }
0x00047d00 lw v0, -0x7fd0(gp) | v0 = *((gp - 8180));
| if (v0 == 0) {
0x00047d04 beqz v0, 0x47e78 | goto label_13;
| }
0x00047d08 addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
0x00047d0c b 0x47e8c | goto label_8;
| label_14:
0x00047d10 jalr t9 | t9 ();
0x00047d14 nop |
0x00047d18 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 == 0) {
0x00047d1c beqz v0, 0x47e88 | goto label_10;
| }
0x00047d20 lw a0, (s5) | a0 = *(s5);
0x00047d24 lw t9, -0x7e98(gp) | t9 = *((gp - 8102));
| if (a0 != 0) {
0x00047d28 bnez a0, 0x47d78 | goto label_15;
| }
0x00047d2c lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00047d30 move a0, s0 | a0 = s0;
0x00047d34 bal 0x3b6e0 | sym_strlen ();
0x00047d38 lw gp, 0x10(fp) | gp = *(dest);
0x00047d3c lw t9, -0x759c(gp) | t9 = *((gp - 7527));
0x00047d40 addiu a0, v0, 1 | a0 = v0 + 1;
0x00047d44 jalr t9 | t9 ();
0x00047d48 lw gp, 0x10(fp) | gp = *(dest);
0x00047d4c bnez v0, 0x47d60 |
| while (v0 == 0) {
0x00047d50 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00047d54 lw t9, -0x795c(gp) | t9 = *((gp - 7767));
0x00047d58 addiu a0, a0, 0x7328 | a0 += 0x7328;
0x00047d5c b 0x47e0c | goto label_16;
0x00047d60 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00047d64 move a0, v0 | a0 = v0;
0x00047d68 move a1, s0 | a1 = s0;
0x00047d6c bal 0x3b630 | sym_strcpy ()
0x00047d70 sw v0, (s5) | *(s5) = v0;
0x00047d74 b 0x47e88 | goto label_10;
| label_15:
0x00047d78 move a1, s0 | a1 = s0;
0x00047d7c bal 0x3b600 | sym_strcmp ();
0x00047d80 lw gp, 0x10(fp) | gp = *(dest);
| label_11:
0x00047d84 addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
| if (v0 == 0) {
0x00047d88 beqz v0, 0x47e8c | goto label_8;
| }
0x00047d8c lw v1, -0x7b10(gp) | v1 = *((gp - 7876));
0x00047d90 b 0x47ed8 | goto label_7;
| label_12:
0x00047d94 lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00047d98 lw t9, -0x7e98(gp) | t9 = *((gp - 8102));
0x00047d9c lw a0, (s5) | a0 = *(s5);
0x00047da0 addiu a1, a1, 0x7338 | a1 += 0x7338;
0x00047da4 bal 0x3b600 | sym_strcmp ();
0x00047da8 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 != 0) {
0x00047dac beqz v0, 0x47e1c |
0x00047db0 lw t9, -0x79c4(gp) | t9 = *((gp - 7793));
0x00047db4 lw a0, -0x2420(s3) | a0 = *((s3 - 2312));
0x00047db8 bal 0x387f0 | sym_fileno ();
0x00047dbc lw gp, 0x10(fp) | gp = *(dest);
0x00047dc0 move a0, v0 | a0 = v0;
0x00047dc4 lw t9, -0x7e94(gp) | t9 = *((gp - 8101));
0x00047dc8 addiu a1, fp, 0x418 | a1 = fp + aav.0x00000418;
0x00047dcc jalr t9 | t9 ();
0x00047dd0 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 < 0) {
0x00047dd4 bltz v0, 0x47e1c | goto label_17;
| }
0x00047dd8 lw v0, 0x42c(fp) | v0 = *(var_42ch);
0x00047ddc andi v0, v0, 0x3f | v0 &= 0x3f;
0x00047de0 addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
| if (v0 == 0) {
0x00047de4 beqz v0, 0x47e20 | goto label_18;
| }
0x00047de8 lw s0, -0x795c(gp) | s0 = *((gp - 7767));
0x00047dec lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00047df0 move t9, s0 | t9 = s0;
0x00047df4 addiu a0, a0, 0x7344 | a0 += 0x7344;
0x00047df8 bal 0x2f7b0 | sym_printf ();
0x00047dfc lw gp, 0x10(fp) | gp = *(dest);
0x00047e00 move t9, s0 | t9 = s0;
0x00047e04 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x00047e08 addiu a0, a0, 0x7370 | a0 += 0x7370;
| label_16:
0x00047e0c bal 0x2f7b0 | sym_printf ();
0x00047e10 nop |
0x00047e14 lw gp, 0x10(fp) | gp = *(dest);
0x00047e18 b 0x47efc | goto label_19;
| }
| label_17:
0x00047e1c addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
| label_18:
0x00047e20 bal 0x47770 | fcn_00047770 ();
0x00047e24 nop |
0x00047e28 lw gp, 0x10(fp) | gp = *(dest);
| if (v0 == 0) {
0x00047e2c beqz v0, 0x47e88 | goto label_10;
| }
0x00047e30 lw v0, (s7) | v0 = *(s7);
0x00047e34 addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
| if (v0 != 0) {
0x00047e38 bnez v0, 0x47e8c | goto label_8;
| }
0x00047e3c lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x00047e40 move a0, s0 | a0 = s0;
0x00047e44 bal 0x3b6e0 | sym_strlen ();
0x00047e48 lw gp, 0x10(fp) | gp = *(dest);
0x00047e4c lw t9, -0x759c(gp) | t9 = *((gp - 7527));
0x00047e50 addiu a0, v0, 1 | a0 = v0 + 1;
0x00047e54 jalr t9 | t9 ();
0x00047e58 lw gp, 0x10(fp) | gp = *(dest);
0x00047e5c beqz v0, 0x47d50 |
| }
0x00047e60 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00047e64 move a0, v0 | a0 = v0;
0x00047e68 move a1, s0 | a1 = s0;
0x00047e6c bal 0x3b630 | sym_strcpy ()
0x00047e70 sw v0, (s7) | *(s7) = v0;
0x00047e74 b 0x47e88 | goto label_10;
| label_13:
0x00047e78 lw t9, -0x795c(gp) | t9 = *((gp - 7767));
0x00047e7c move a1, s0 | a1 = s0;
0x00047e80 addiu a0, v0, 0x73a4 | a0 = v0 + 0x73a4;
0x00047e84 bal 0x2f7b0 | sym_printf ();
| label_10:
0x00047e88 addiu t9, s6, 0x7770 | t9 = s6 + 0x7770;
| label_8:
0x00047e8c sw t9, 0x4b0(fp) | *(var_4b0h) = t9;
0x00047e90 bal 0x47770 | fcn_00047770 ();
0x00047e94 lw gp, 0x10(fp) | gp = *(dest);
0x00047e98 lw t9, 0x4b0(fp) | t9 = *(var_4b0h);
0x00047e9c bnez v0, 0x47eb8 |
| while (v0 == v1) {
0x00047ea0 lw a0, -0x2420(s3) | a0 = *((s3 - 2312));
| label_1:
0x00047ea4 lw t9, -0x7dd0(gp) | t9 = *((gp - 8052));
0x00047ea8 move s1, zero | s1 = 0;
0x00047eac bal 0x2de70 | sym_fclose ();
0x00047eb0 move sp, fp |
0x00047eb4 b 0x47f10 | goto label_5;
0x00047eb8 addiu v1, zero, 0xb | v1 = 0xb;
0x00047ebc addiu v1, zero, 1 | v1 = 1;
0x00047ec0 beq v0, v1, 0x47ea0 |
| }
0x00047ec4 addiu v1, zero, 3 | v1 = 3;
| if (v0 != v1) {
0x00047ec8 bne v0, v1, 0x47cdc | goto label_0;
| }
0x00047ecc lw a0, -0x2420(s3) | a0 = *((s3 - 2312));
0x00047ed0 b 0x47ea4 | goto label_1;
| label_6:
0x00047ed4 lw v1, -0x7b10(gp) | v1 = *((gp - 7876));
| label_7:
0x00047ed8 addiu t9, v1, 0x7770 | t9 = v1 + 0x7770;
0x00047edc sw t9, 0x4b0(fp) | *(var_4b0h) = t9;
0x00047ee0 bal 0x47770 | fcn_00047770 ();
0x00047ee4 lw gp, 0x10(fp) | gp = *(dest);
0x00047ee8 lw t9, 0x4b0(fp) | t9 = *(var_4b0h);
0x00047eec lw s6, -0x7b10(gp) | s6 = *((gp - 7876));
| if (v0 != 0) {
0x00047ef0 bnez v0, 0x47c14 | goto label_2;
| }
0x00047ef4 lw a0, -0x2420(s3) | a0 = *((s3 - 2312));
0x00047ef8 b 0x47ea4 | goto label_1;
| label_19:
0x00047efc lw t9, -0x7dd0(gp) | t9 = *((gp - 8052));
0x00047f00 lw a0, -0x2420(s3) | a0 = *((s3 - 2312));
0x00047f04 bal 0x2de70 | sym_fclose ();
| label_4:
0x00047f08 addiu s1, zero, -1 | s1 = -1;
| label_3:
0x00047f0c move sp, fp |
| label_5:
0x00047f10 lw ra, 0x4dc(sp) | ra = *(var_4dch);
0x00047f14 move v0, s1 | v0 = s1;
0x00047f18 lw fp, 0x4d8(sp) | fp = *(var_4d8h);
0x00047f1c lw s7, 0x4d4(sp) | s7 = *(var_4d4h);
0x00047f20 lw s6, 0x4d0(sp) | s6 = *(var_4d0h);
0x00047f24 lw s5, 0x4cc(sp) | s5 = *(var_4cch);
0x00047f28 lw s4, 0x4c8(sp) | s4 = *(var_4c8h);
0x00047f2c lw s3, 0x4c4(sp) | s3 = *(var_4c4h);
0x00047f30 lw s2, 0x4c0(sp) | s2 = *(var_4c0h);
0x00047f34 lw s1, 0x4bc(sp) | s1 = *(var_4bch);
0x00047f38 lw s0, 0x4b8(sp) | s0 = *(var_4b8h);
0x00047f3c addiu sp, sp, 0x4e0 |
0x00047f40 jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x2dda0 */
| #include <stdint.h>
|
; (fcn) sym.sgetspent_r () | void sgetspent_r () {
0x0002dda0 lui gp, 9 |
0x0002dda4 addiu gp, gp, 0x3940 |
0x0002dda8 addu gp, gp, t9 | gp += t9;
0x0002ddac addiu sp, sp, -0x30 |
0x0002ddb0 sw s1, 0x1c(sp) | *(var_1ch) = s1;
0x0002ddb4 lw s1, 0x40(sp) | s1 = *(arg_40h);
0x0002ddb8 sw gp, 0x10(sp) | *(var_10h) = gp;
0x0002ddbc sltiu v0, a3, 0x100 | v0 = (a3 < aav.0x00000100) ? 1 : 0;
0x0002ddc0 sw ra, 0x2c(sp) | *(var_2ch) = ra;
0x0002ddc4 sw s4, 0x28(sp) | *(var_28h) = s4;
0x0002ddc8 sw s3, 0x24(sp) | *(var_24h) = s3;
0x0002ddcc sw s2, 0x20(sp) | *(var_20h) = s2;
0x0002ddd0 sw s0, 0x18(sp) | *(var_18h) = s0;
0x0002ddd4 sw zero, (s1) | *(s1) = 0;
0x0002ddd8 beqz v0, 0x2ddfc |
| while (v0 == 0) {
0x0002dddc rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x0002dde0 move v0, v1 | v0 = v1;
0x0002dde4 lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x0002dde8 addu v0, v1, v0 | v0 = v1 + v0;
0x0002ddec addiu v1, zero, 0x22 | v1 = 0x22;
0x0002ddf0 sw v1, (v0) | *(v0) = v1;
0x0002ddf4 addiu v0, zero, 0x22 | v0 = 0x22;
0x0002ddf8 b 0x2de50 | goto label_0;
0x0002ddfc move s2, a1 | s2 = a1;
0x0002de00 move s0, a2 | s0 = a2;
| if (a0 == a2) {
0x0002de04 beq a0, a2, 0x2de38 | goto label_1;
| }
0x0002de08 lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x0002de0c move s4, a3 | s4 = a3;
0x0002de10 move s3, a0 | s3 = a0;
0x0002de14 bal 0x3b6e0 | sym_strlen ();
0x0002de18 sltu v0, v0, s4 | v0 = (v0 < s4) ? 1 : 0;
0x0002de1c lw gp, 0x10(sp) | gp = *(var_10h);
0x0002de20 beqz v0, 0x2dddc |
| }
0x0002de24 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x0002de28 move a0, s0 | a0 = s0;
0x0002de2c move a1, s3 | a1 = s3;
0x0002de30 bal 0x3b630 | sym_strcpy ()
0x0002de34 lw gp, 0x10(sp) | gp = *(var_10h);
| label_1:
0x0002de38 lw t9, -0x7c7c(gp) | t9 = *(gp);
0x0002de3c move a0, s2 | a0 = s2;
0x0002de40 move a1, s0 | a1 = s0;
0x0002de44 bal 0x2bf20 | fcn_0002bf20 ();
| if (v0 != 0) {
0x0002de48 beql v0, zero, 0x2de50 |
0x0002de4c sw s2, (s1) | *(s1) = s2;
| }
| label_0:
0x0002de50 lw ra, 0x2c(sp) | ra = *(var_2ch);
0x0002de54 lw s4, 0x28(sp) | s4 = *(var_28h);
0x0002de58 lw s3, 0x24(sp) | s3 = *(var_24h);
0x0002de5c lw s2, 0x20(sp) | s2 = *(var_20h);
0x0002de60 lw s1, 0x1c(sp) | s1 = *(var_1ch);
0x0002de64 lw s0, 0x18(sp) | s0 = *(var_18h);
0x0002de68 addiu sp, sp, 0x30 |
0x0002de6c jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x24ea0 */
| #include <stdint.h>
|
; (fcn) sym.timegm () | void timegm () {
0x00024ea0 lui gp, 0xa |
0x00024ea4 addiu gp, gp, -0x37c0 |
0x00024ea8 addu gp, gp, t9 | gp += t9;
0x00024eac lw t9, -0x7fe4(gp) | t9 = *((gp - 8185));
0x00024eb0 addiu sp, sp, -0x50 |
0x00024eb4 addiu a2, zero, 0x30 | a2 = 0x30;
0x00024eb8 move a1, zero | a1 = 0;
0x00024ebc sw ra, 0x4c(sp) | *(var_4ch) = ra;
0x00024ec0 sw s0, 0x48(sp) | *(var_48h) = s0;
0x00024ec4 sw gp, 0x10(sp) | *(var_10h) = gp;
0x00024ec8 move s0, a0 | s0 = a0;
0x00024ecc addiu a0, sp, 0x18 | a0 = sp + 0x18;
0x00024ed0 bal 0x3a970 | sym_memset ();
0x00024ed4 lw gp, 0x10(sp) | gp = *(var_10h);
0x00024ed8 addiu a0, sp, 0x28 | a0 = sp + 0x28;
0x00024edc lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x00024ee0 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x00024ee4 addiu a1, a1, 0x4f24 | a1 += 0x4f24;
0x00024ee8 bal 0x3b630 | sym_strcpy ()
0x00024eec lw gp, 0x10(sp) | gp = *(var_10h);
0x00024ef0 move a0, s0 | a0 = s0;
0x00024ef4 addiu a2, sp, 0x18 | a2 = sp + 0x18;
0x00024ef8 lw t9, -0x7ce0(gp) | t9 = *((gp - 7992));
0x00024efc addiu a1, zero, 1 | a1 = 1;
0x00024f00 bal 0x24f20 | fcn_00024f20 ();
0x00024f04 lw ra, 0x4c(sp) | ra = *(var_4ch);
0x00024f08 lw s0, 0x48(sp) | s0 = *(var_48h);
0x00024f0c addiu sp, sp, 0x50 |
0x00024f10 jr ra | return;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x3ed70 */
| #include <stdint.h>
|
; (fcn) sym.ttyname_r () | void ttyname_r () {
0x0003ed70 lui gp, 8 |
0x0003ed74 addiu gp, gp, 0x2970 |
0x0003ed78 addu gp, gp, t9 | gp += t9;
0x0003ed7c lw t9, -0x7e94(gp) | t9 = *((gp - 8101));
0x0003ed80 addiu sp, sp, -0x198 |
0x0003ed84 sw gp, 0x10(sp) | *(var_10h) = gp;
0x0003ed88 sw s5, 0x184(sp) | *(var_184h) = s5;
0x0003ed8c sw s4, 0x180(sp) | *(var_180h) = s4;
0x0003ed90 sw s0, 0x170(sp) | *(var_170h) = s0;
0x0003ed94 sw ra, 0x194(sp) | *(var_194h) = ra;
0x0003ed98 sw fp, 0x190(sp) | *(var_190h) = fp;
0x0003ed9c sw s7, 0x18c(sp) | *(var_18ch) = s7;
0x0003eda0 sw s6, 0x188(sp) | *(var_188h) = s6;
0x0003eda4 sw s3, 0x17c(sp) | *(var_17ch) = s3;
0x0003eda8 sw s2, 0x178(sp) | *(var_178h) = s2;
0x0003edac sw s1, 0x174(sp) | *(var_174h) = s1;
0x0003edb0 move s4, a1 | s4 = a1;
0x0003edb4 addiu a1, sp, 0xb0 | a1 = sp + 0xb0;
0x0003edb8 move s0, a0 | s0 = a0;
0x0003edbc move s5, a2 | s5 = a2;
0x0003edc0 jalr t9 | t9 ();
0x0003edc4 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 < 0) {
0x0003edc8 bgez v0, 0x3ede4 |
0x0003edcc rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x0003edd0 move v0, v1 | v0 = v1;
0x0003edd4 lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x0003edd8 addu v0, v1, v0 | v0 = v1 + v0;
0x0003eddc lw v0, (v0) | v0 = *(v0);
0x0003ede0 b 0x3ef70 | goto label_1;
| }
0x0003ede4 lw t9, -0x7be4(gp) | t9 = *((gp - 7929));
0x0003ede8 move a0, s0 | a0 = s0;
0x0003edec bal 0x3e6f0 | sym_isatty ();
0x0003edf0 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x0003edf4 bnez v0, 0x3ef38 | goto label_2;
| }
0x0003edf8 addiu v0, zero, 0x19 | v0 = 0x19;
0x0003edfc b 0x3ef5c | goto label_3;
| label_0:
0x0003ee00 addiu a0, sp, 0x148 | a0 = sp + aav.0x00000148;
0x0003ee04 move t9, s3 | t9 = s3;
0x0003ee08 move a1, s2 | a1 = s2;
0x0003ee0c bal 0x3b630 | sym_strcpy ()
0x0003ee10 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ee14 addiu v0, sp, 0x148 | v0 = sp + aav.0x00000148;
0x0003ee18 move a0, s2 | a0 = s2;
0x0003ee1c lw t9, -0x7e80(gp) | t9 = *((gp - 8096));
0x0003ee20 addu s7, v0, s1 | s7 = v0 + s1;
0x0003ee24 addiu fp, zero, 0x1e | fp = 0x1e;
0x0003ee28 jalr t9 | t9 ();
0x0003ee2c subu fp, fp, s1 | __asm ("subu fp, fp, s1");
0x0003ee30 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ee34 move s1, v0 | s1 = v0;
| if (v0 != 0) {
0x0003ee38 bnez v0, 0x3ef04 | goto label_4;
| }
0x0003ee3c lbu s0, (s0) | s0 = *(s0);
0x0003ee40 b 0x3ef2c | goto label_5;
| do {
0x0003ee44 addiu a1, v0, 0xb | a1 = v0 + 0xb;
0x0003ee48 move a0, a1 | a0 = a1;
0x0003ee4c move t9, s6 | t9 = s6;
0x0003ee50 sw a1, 0x168(sp) | *(var_168h) = a1;
0x0003ee54 bal 0x3b6e0 | sym_strlen ();
0x0003ee58 sltu v0, fp, v0 | v0 = (fp < v0) ? 1 : 0;
0x0003ee5c lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ee60 lw a1, 0x168(sp) | a1 = *(var_168h);
| if (v0 == 0) {
0x0003ee64 bnez v0, 0x3ef04 |
0x0003ee68 move t9, s3 | t9 = s3;
0x0003ee6c move a0, s7 | a0 = s7;
0x0003ee70 bal 0x3b630 | sym_strcpy ()
0x0003ee74 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ee78 addiu a0, sp, 0x148 | a0 = sp + aav.0x00000148;
0x0003ee7c lw t9, -0x7e2c(gp) | t9 = *((gp - 8075));
0x0003ee80 addiu a1, sp, 0x18 | a1 = sp + 0x18;
0x0003ee84 jalr t9 | t9 ();
0x0003ee88 lw gp, 0x10(sp) | gp = *(var_10h);
| if (v0 != 0) {
0x0003ee8c bnez v0, 0x3ef04 | goto label_4;
| }
0x0003ee90 lw v1, 0x2c(sp) | v1 = *(var_2ch);
0x0003ee94 addiu v0, zero, 0x2000 | v0 = 0x2000;
0x0003ee98 andi v1, v1, 0xf000 | v1 &= aav.0x0000f000;
0x0003ee9c lw t9, -0x7e7c(gp) | t9 = *((gp - 8095));
| if (v1 != v0) {
0x0003eea0 bne v1, v0, 0x3ef08 | goto label_6;
| }
0x0003eea4 lw v0, 0x40(sp) | v0 = *(var_40h);
0x0003eea8 lw v1, 0xd8(sp) | v1 = *(var_d8h);
0x0003eeac lw v0, 0x44(sp) | v0 = *(var_44h);
| if (v1 != v0) {
0x0003eeb0 bne v1, v0, 0x3ef08 | goto label_6;
| }
0x0003eeb4 lw v1, 0xdc(sp) | v1 = *(var_dch);
0x0003eeb8 lw t9, -0x7e78(gp) | t9 = *((gp - 8094));
| if (v1 != v0) {
0x0003eebc bne v1, v0, 0x3ef04 | goto label_4;
| }
0x0003eec0 move a0, s1 | a0 = s1;
0x0003eec4 jalr t9 | t9 ();
0x0003eec8 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003eecc lw t9, -0x7fdc(gp) | t9 = *((gp - 8183));
0x0003eed0 addiu a0, sp, 0x148 | a0 = sp + aav.0x00000148;
0x0003eed4 bal 0x3b6e0 | sym_strlen ();
0x0003eed8 sltu s5, s5, v0 | s5 = (s5 < v0) ? 1 : 0;
0x0003eedc lw gp, 0x10(sp) | gp = *(var_10h);
0x0003eee0 addiu v0, zero, 0x22 | v0 = 0x22;
| if (s5 != 0) {
0x0003eee4 bnez s5, 0x3ef5c | goto label_3;
| }
0x0003eee8 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x0003eeec move a0, s4 | a0 = s4;
0x0003eef0 addiu a1, sp, 0x148 | a1 = sp + aav.0x00000148;
0x0003eef4 bal 0x3b630 | sym_strcpy ()
0x0003eef8 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003eefc move v0, zero | v0 = 0;
0x0003ef00 b 0x3ef5c | goto label_3;
| }
| label_4:
0x0003ef04 lw t9, -0x7e7c(gp) | t9 = *((gp - 8095));
| label_6:
0x0003ef08 move a0, s1 | a0 = s1;
0x0003ef0c jalr t9 | t9 ();
0x0003ef10 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ef14 bnez v0, 0x3ee44 |
| } while (v0 != 0);
0x0003ef18 lw t9, -0x7e78(gp) | t9 = *((gp - 8094));
0x0003ef1c move a0, s1 | a0 = s1;
0x0003ef20 jalr t9 | t9 ();
0x0003ef24 lw gp, 0x10(sp) | gp = *(var_10h);
0x0003ef28 lbu s0, (s0) | s0 = *(s0);
| label_5:
0x0003ef2c addiu s0, s0, 1 | s0++;
0x0003ef30 addu s0, s2, s0 | s0 = s2 + s0;
0x0003ef34 b 0x3ef48 | goto label_7;
| label_2:
0x0003ef38 lw s0, -0x7fd0(gp) | s0 = *((gp - 8180));
0x0003ef3c lw s3, -0x7f48(gp) | s3 = *((gp - 8146));
0x0003ef40 lw s6, -0x7fdc(gp) | s6 = *((gp - 8183));
0x0003ef44 addiu s0, s0, 0x6900 | s0 += 0x6900;
| label_7:
0x0003ef48 lbu s1, (s0) | s1 = *(s0);
0x0003ef4c addiu s2, s0, 1 | s2 = s0 + 1;
| if (s1 != 0) {
0x0003ef50 bnez s1, 0x3ee00 | goto label_0;
| }
0x0003ef54 addiu v0, zero, 0x19 | v0 = 0x19;
0x0003ef58 b 0x3ef5c |
| label_3:
0x0003ef5c rdhwr v1, 29 | __asm ("rdhwr v1, 29");
0x0003ef60 move a0, v1 | a0 = v1;
0x0003ef64 lw v1, -0x7560(gp) | v1 = *((gp - 7512));
0x0003ef68 addu a0, v1, a0 | a0 = v1 + a0;
0x0003ef6c sw v0, (a0) | *(a0) = v0;
| label_1:
0x0003ef70 lw ra, 0x194(sp) | ra = *(var_194h);
0x0003ef74 lw fp, 0x190(sp) | fp = *(var_190h);
0x0003ef78 lw s7, 0x18c(sp) | s7 = *(var_18ch);
0x0003ef7c lw s6, 0x188(sp) | s6 = *(var_188h);
0x0003ef80 lw s5, 0x184(sp) | s5 = *(var_184h);
0x0003ef84 lw s4, 0x180(sp) | s4 = *(var_180h);
0x0003ef88 lw s3, 0x17c(sp) | s3 = *(var_17ch);
0x0003ef8c lw s2, 0x178(sp) | s2 = *(var_178h);
0x0003ef90 lw s1, 0x174(sp) | s1 = *(var_174h);
0x0003ef94 lw s0, 0x170(sp) | s0 = *(var_170h);
0x0003ef98 addiu sp, sp, 0x198 |
0x0003ef9c jr ra | return v0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/2097216-5451840.squashfs_v4_le_extract/lib/libuClibc-0.9.33.2.so @ 0x2b07c */
| #include <stdint.h>
|
; (fcn) sym.wordexp () | void wordexp () {
0x0002b07c lui gp, 9 |
0x0002b080 addiu gp, gp, 0x6664 |
0x0002b084 addu gp, gp, t9 | gp += t9;
0x0002b088 lw v1, (a1) | v1 = *(a1);
0x0002b08c addiu sp, sp, -0xa0 |
0x0002b090 lw t9, 4(a1) | t9 = *((a1 + 1));
0x0002b094 sw v1, 0x70(sp) | *(var_70h) = v1;
0x0002b098 lw v1, 8(a1) | v1 = *((a1 + 2));
0x0002b09c sw gp, 0x28(sp) | *(var_28h) = gp;
0x0002b0a0 andi v0, a2, 8 | v0 = a2 & 8;
0x0002b0a4 sw s3, 0x84(sp) | *(var_84h) = s3;
0x0002b0a8 sw s1, 0x7c(sp) | *(var_7ch) = s1;
0x0002b0ac sw s0, 0x78(sp) | *(var_78h) = s0;
0x0002b0b0 sw ra, 0x9c(sp) | *(var_9ch) = ra;
0x0002b0b4 sw fp, 0x98(sp) | *(var_98h) = fp;
0x0002b0b8 sw s7, 0x94(sp) | *(var_94h) = s7;
0x0002b0bc sw s6, 0x90(sp) | *(var_90h) = s6;
0x0002b0c0 sw s5, 0x8c(sp) | *(var_8ch) = s5;
0x0002b0c4 sw s4, 0x88(sp) | *(var_88h) = s4;
0x0002b0c8 sw s2, 0x80(sp) | *(var_80h) = s2;
0x0002b0cc move s1, a0 | s1 = a0;
0x0002b0d0 move s0, a1 | s0 = a1;
0x0002b0d4 move s3, a2 | s3 = a2;
0x0002b0d8 sw zero, 0x50(sp) | *(var_50h) = 0;
0x0002b0dc sw zero, 0x54(sp) | *(var_54h) = 0;
0x0002b0e0 sw zero, 0x4c(sp) | *(var_4ch) = 0;
0x0002b0e4 sw t9, 0x64(sp) | *(var_64h) = t9;
0x0002b0e8 sw v1, 0x6c(sp) | *(var_6ch) = v1;
| if (v0 != 0) {
0x0002b0ec beqz v0, 0x2b104 |
0x0002b0f0 lw t9, -0x7f4c(gp) | t9 = *((gp - 8147));
0x0002b0f4 move a0, a1 | a0 = a1;
0x0002b0f8 bal 0x2aff8 | sym_wordfree ();
0x0002b0fc lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b100 sw zero, 0x64(sp) | *(var_64h) = 0;
| }
0x0002b104 andi t9, s3, 2 | t9 = s3 & 2;
0x0002b108 sw t9, 0x60(sp) | *(var_60h) = t9;
| if (t9 == 0) {
0x0002b10c bnez t9, 0x2b160 |
0x0002b110 andi v0, s3, 1 | v0 = s3 & 1;
0x0002b114 sw zero, (s0) | *(s0) = 0;
0x0002b118 lw t9, -0x75c8(gp) | t9 = *((gp - 7538));
| if (v0 != 0) {
0x0002b11c beqz v0, 0x2b144 |
0x0002b120 lw a0, 8(s0) | a0 = *((s0 + 2));
0x0002b124 addiu a1, zero, 4 | a1 = 4;
0x0002b128 addiu a0, a0, 1 | a0++;
0x0002b12c jalr t9 | t9 ();
0x0002b130 sw v0, 4(s0) | *((s0 + 1)) = v0;
0x0002b134 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b138 bnez v0, 0x2b160 | goto label_10;
| }
0x0002b13c addiu s7, zero, 1 | s7 = 1;
0x0002b140 b 0x2b9f0 | goto label_9;
| }
0x0002b144 addiu a0, zero, 1 | a0 = 1;
0x0002b148 addiu a1, zero, 4 | a1 = 4;
0x0002b14c jalr t9 | t9 ();
0x0002b150 sw v0, 4(s0) | *((s0 + 1)) = v0;
0x0002b154 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 == 0) {
0x0002b158 beqz v0, 0x2ba60 | goto label_11;
| }
0x0002b15c sw zero, 8(s0) | *((s0 + 2)) = 0;
| }
| label_10:
0x0002b160 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x0002b164 lw t9, -0x7f88(gp) | t9 = *((gp - 8162));
0x0002b168 addiu a0, a0, 0x54ec | a0 += 0x54ec;
0x0002b16c jalr t9 | t9 ();
0x0002b170 move s2, v0 | s2 = v0;
0x0002b174 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 == 0) {
0x0002b178 bnez v0, 0x2b19c |
0x0002b17c lw a1, -0x7fd0(gp) | a1 = *((gp - 8180));
0x0002b180 lw t9, -0x7f48(gp) | t9 = *((gp - 8146));
0x0002b184 addiu a0, sp, 0x48 | a0 = sp + 0x48;
0x0002b188 addiu a1, a1, 0x4954 | a1 += 0x4954;
0x0002b18c bal 0x3b630 | sym_strcpy ()
0x0002b190 move s2, v0 | s2 = v0;
0x0002b194 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b198 b 0x2b210 | goto label_12;
| }
0x0002b19c sb zero, 0x48(sp) | *(dest) = 0;
0x0002b1a0 move a1, v0 | a1 = v0;
0x0002b1a4 addiu v1, sp, 0x48 | v1 = sp + 0x48;
0x0002b1a8 addiu a3, zero, 0x20 | a3 = 0x20;
0x0002b1ac addiu t0, zero, 9 | t0 = 9;
0x0002b1b0 addiu t1, zero, 0xa | t1 = 0xa;
0x0002b1b4 b 0x2b200 | goto label_13;
| label_0:
0x0002b1b8 addiu v0, sp, 0x48 | v0 = sp + 0x48;
| if (a0 == a3) {
0x0002b1bc beq a0, a3, 0x2b1d0 | goto label_14;
| }
0x0002b1c0 sltu a2, v0, v1 | a2 = (v0 < v1) ? 1 : 0;
| if (a0 == t0) {
0x0002b1c4 beq a0, t0, 0x2b1d4 | goto label_15;
| }
0x0002b1c8 addiu a1, a1, 1 | a1++;
| if (a0 == t1) {
0x0002b1cc bnel a0, t1, 0x2b200 | goto label_13;
| }
| do {
| label_14:
0x0002b1d0 sltu a2, v0, v1 | a2 = (v0 < v1) ? 1 : 0;
| if (a2 == 0) {
| label_15:
0x0002b1d4 beqz a2, 0x2b1f0 | goto label_16;
| }
0x0002b1d8 nop |
0x0002b1dc lbu a2, (v0) | a2 = *(v0);
| if (a2 == 0) {
0x0002b1e0 beqz a2, 0x2b1f0 | goto label_16;
| }
0x0002b1e4 nop |
0x0002b1e8 addiu v0, v0, 1 | v0++;
0x0002b1ec bnel a2, a0, 0x2b1d0 |
| } while (a2 == a0);
| label_16:
0x0002b1f0 addiu a1, a1, 1 | a1++;
| if (v0 == v1) {
0x0002b1f4 bne v0, v1, 0x2b200 |
0x0002b1f8 sb a0, (v1) | *(v1) = a0;
0x0002b1fc addiu v1, v1, 1 | v1++;
| }
| label_13:
0x0002b200 lbu a0, (a1) | a0 = *(a1);
| if (a0 != 0) {
0x0002b204 bnez a0, 0x2b1b8 | goto label_0;
| }
0x0002b208 nop |
0x0002b20c sb zero, (v1) | *(v1) = 0;
| label_12:
0x0002b210 sw zero, 0x58(sp) | *(var_58h) = 0;
0x0002b214 lw s4, -0x7fb4(gp) | s4 = *((gp - 8173));
0x0002b218 lw s5, -0x7fb4(gp) | s5 = *((gp - 8173));
0x0002b21c b 0x2b9b8 | goto label_17;
| label_6:
0x0002b220 sltiu v1, s6, 0x40 | v1 = (s6 < 0x40) ? 1 : 0;
| if (s6 == v1) {
0x0002b224 beq s6, v1, 0x2b56c | goto label_18;
| }
0x0002b228 addiu v1, zero, 0x5c | v1 = 0x5c;
| if (v1 != 0) {
0x0002b22c beqz v1, 0x2b268 |
0x0002b230 addiu v1, zero, 0x24 | v1 = 0x24;
0x0002b234 sltiu v1, s6, 0x25 | v1 = (s6 < 0x25) ? 1 : 0;
| if (s6 == v1) {
0x0002b238 beq s6, v1, 0x2b2d4 | goto label_19;
| }
0x0002b23c addiu v1, zero, 0x27 | v1 = 0x27;
| if (v1 != 0) {
0x0002b240 beqz v1, 0x2b258 |
0x0002b244 addiu v1, zero, 0x22 | v1 = 0x22;
0x0002b248 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
| if (s6 != v1) {
0x0002b24c bne s6, v1, 0x2b90c | goto label_20;
| }
0x0002b250 addiu v0, v0, 1 | v0++;
0x0002b254 b 0x2b364 | goto label_21;
| }
| if (s6 == v1) {
0x0002b258 beql s6, v1, 0x2b4b8 | goto label_22;
| }
0x0002b25c addiu v0, v0, 1 | v0++;
0x0002b260 addiu v0, zero, 0x2a | v0 = 0x2a;
0x0002b264 b 0x2b27c |
| } else {
0x0002b268 sltiu v1, s6, 0x5d | v1 = (s6 < 0x5d) ? 1 : 0;
| if (s6 == v1) {
0x0002b26c beq s6, v1, 0x2b2a8 | goto label_23;
| }
0x0002b270 addiu v1, zero, 0x60 | v1 = 0x60;
| if (v1 == 0) {
0x0002b274 beqz v1, 0x2b28c | goto label_24;
| }
0x0002b278 addiu v0, zero, 0x5b | v0 = 0x5b;
| }
0x0002b27c lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
| if (s6 != v0) {
0x0002b280 bne s6, v0, 0x2b90c | goto label_20;
| }
0x0002b284 sw zero, 0x3c(sp) | *(var_3ch) = 0;
0x0002b288 b 0x2b570 | goto label_25;
| label_24:
0x0002b28c andi v1, s3, 4 | v1 = s3 & 4;
| if (s6 != v1) {
0x0002b290 beq s6, v1, 0x2b318 |
0x0002b294 addiu v0, zero, 0x7e | v0 = 0x7e;
0x0002b298 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
| if (s6 != v0) {
0x0002b29c bne s6, v0, 0x2b90c | goto label_20;
| }
0x0002b2a0 addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b2a4 b 0x2b530 | goto label_26;
| label_23:
0x0002b2a8 lw t9, -0x7fb4(gp) | t9 = *((gp - 8173));
0x0002b2ac addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b2b0 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b2b4 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b2b8 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b2bc addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b2c0 addiu t9, t9, -0x7c80 | t9 += -0x7c80;
0x0002b2c4 move a3, s1 | a3 = s1;
0x0002b2c8 bal 0x28380 | fcn_00028380 ();
0x0002b2cc lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b2d0 b 0x2b55c | goto label_27;
| label_19:
0x0002b2d4 lw t9, -0x7fb4(gp) | t9 = *((gp - 8173));
0x0002b2d8 addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b2dc sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b2e0 addiu v0, sp, 0x48 | v0 = sp + 0x48;
0x0002b2e4 sw s3, 0x14(sp) | *(var_14h) = s3;
0x0002b2e8 sw s0, 0x18(sp) | *(var_18h) = s0;
0x0002b2ec sw s2, 0x1c(sp) | *(var_1ch) = s2;
0x0002b2f0 sw v0, 0x20(sp) | *(var_20h) = v0;
0x0002b2f4 sw zero, 0x24(sp) | *(var_24h) = 0;
0x0002b2f8 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b2fc addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b300 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b304 addiu t9, t9, -0x6634 | t9 += -0x6634;
0x0002b308 move a3, s1 | a3 = s1;
0x0002b30c bal 0x299cc | fcn_000299cc ();
0x0002b310 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b314 b 0x2b55c | goto label_27;
| }
0x0002b318 lw t9, -0x7fb4(gp) | t9 = *((gp - 8173));
| if (v1 != 0) {
0x0002b31c bnez v1, 0x2ba44 | goto label_28;
| }
0x0002b320 addiu v0, v0, 1 | v0++;
0x0002b324 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b328 addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b32c sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b330 addiu v0, sp, 0x48 | v0 = sp + 0x48;
0x0002b334 sw s3, 0x14(sp) | *(var_14h) = s3;
0x0002b338 sw s0, 0x18(sp) | *(var_18h) = s0;
0x0002b33c sw s2, 0x1c(sp) | *(var_1ch) = s2;
0x0002b340 sw v0, 0x20(sp) | *(var_20h) = v0;
0x0002b344 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b348 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b34c addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b350 addiu t9, t9, -0x73b4 | t9 += -0x73b4;
0x0002b354 move a3, s1 | a3 = s1;
0x0002b358 bal 0x28c4c | fcn_00028c4c ();
0x0002b35c lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b360 b 0x2b55c | goto label_27;
| label_21:
0x0002b364 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b368 lw fp, -0x7fb4(gp) | fp = *((gp - 8173));
0x0002b36c lw s6, -0x7fb4(gp) | s6 = *((gp - 8173));
0x0002b370 b 0x2b49c | goto label_29;
| label_3:
0x0002b374 sltiu v1, a3, 0x25 | v1 = (a3 < 0x25) ? 1 : 0;
| if (a3 != v1) {
0x0002b378 beq a3, v1, 0x2b3b0 |
| if (v1 != 0) {
0x0002b37c beql v1, zero, 0x2b398 |
0x0002b380 addiu v1, zero, 0x5c | v1 = 0x5c;
0x0002b384 addiu v0, zero, 0x22 | v0 = 0x22;
0x0002b388 lw a0, 0x4c(sp) | a0 = *(var_4ch);
| if (a3 != v0) {
0x0002b38c bne a3, v0, 0x2b478 | goto label_30;
| }
0x0002b390 lw v0, 0x54(sp) | v0 = *(var_54h);
0x0002b394 b 0x2ba50 | goto label_31;
| }
0x0002b398 addiu v1, zero, 0x60 | v1 = 0x60;
| if (a3 == v1) {
0x0002b39c beq a3, v1, 0x2b44c | goto label_32;
| }
0x0002b3a0 lw a0, 0x4c(sp) | a0 = *(var_4ch);
| if (a3 != v1) {
0x0002b3a4 bne a3, v1, 0x2b478 | goto label_30;
| }
0x0002b3a8 andi v1, s3, 4 | v1 = s3 & 4;
0x0002b3ac b 0x2b408 | goto label_33;
| }
0x0002b3b0 addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b3b4 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b3b8 addiu v0, sp, 0x48 | v0 = sp + 0x48;
0x0002b3bc sw v0, 0x20(sp) | *(var_20h) = v0;
0x0002b3c0 addiu v0, zero, 1 | v0 = 1;
0x0002b3c4 sw s3, 0x14(sp) | *(var_14h) = s3;
0x0002b3c8 sw s0, 0x18(sp) | *(var_18h) = s0;
0x0002b3cc sw s2, 0x1c(sp) | *(var_1ch) = s2;
0x0002b3d0 sw v0, 0x24(sp) | *(var_24h) = v0;
0x0002b3d4 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b3d8 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b3dc addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b3e0 addiu t9, fp, -0x6634 | t9 = fp + -0x6634;
0x0002b3e4 move a3, s1 | a3 = s1;
0x0002b3e8 bal 0x299cc | fcn_000299cc ();
0x0002b3ec lw gp, 0x28(sp) | gp = *(var_28h);
| do {
| label_1:
0x0002b3f0 move s7, v0 | s7 = v0;
| if (v0 != 0) {
0x0002b3f4 bnez v0, 0x2b9f0 | goto label_9;
| }
| label_2:
0x0002b3f8 lw v0, 0x58(sp) | v0 = *(var_58h);
0x0002b3fc addiu v0, v0, 1 | v0++;
0x0002b400 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b404 b 0x2b49c | goto label_29;
| label_33:
0x0002b408 addiu v0, v0, 1 | v0++;
| if (v1 != 0) {
0x0002b40c bnez v1, 0x2ba44 | goto label_28;
| }
0x0002b410 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b414 addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b418 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b41c sw s3, 0x14(sp) | *(var_14h) = s3;
0x0002b420 sw zero, 0x18(sp) | *(var_18h) = 0;
0x0002b424 sw zero, 0x1c(sp) | *(var_1ch) = 0;
0x0002b428 sw zero, 0x20(sp) | *(var_20h) = 0;
0x0002b42c addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b430 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b434 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b438 addiu t9, s6, -0x73b4 | t9 = s6 + -0x73b4;
0x0002b43c move a3, s1 | a3 = s1;
0x0002b440 bal 0x28c4c | fcn_00028c4c ();
0x0002b444 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b448 b 0x2b3f0 |
| } while (1);
| label_32:
0x0002b44c addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b450 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b454 lw v0, -0x7fb4(gp) | v0 = *((gp - 8173));
0x0002b458 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b45c addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b460 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b464 addiu t9, v0, -0x7bec | t9 = v0 + -0x7bec;
0x0002b468 move a3, s1 | a3 = s1;
0x0002b46c bal 0x28414 | fcn_00028414 ();
0x0002b470 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b474 b 0x2b3f0 | goto label_1;
| label_30:
0x0002b478 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b47c addiu t9, s4, -0x7d40 | t9 = s4 + -0x7d40;
0x0002b480 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b484 bal 0x282c0 | fcn_000282c0 ();
0x0002b488 sw v0, 0x4c(sp) | *(var_4ch) = v0;
0x0002b48c lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b490 bnez v0, 0x2b3f8 | goto label_2;
| }
0x0002b494 addiu s7, zero, 1 | s7 = 1;
0x0002b498 b 0x2b9f0 | goto label_9;
| label_29:
0x0002b49c lw v0, 0x58(sp) | v0 = *(var_58h);
0x0002b4a0 addu v1, s1, v0 | v1 = s1 + v0;
0x0002b4a4 lbu a3, (v1) | a3 = *(v1);
0x0002b4a8 addiu v1, zero, 0x24 | v1 = 0x24;
| if (a3 != 0) {
0x0002b4ac bnez a3, 0x2b374 | goto label_3;
| }
0x0002b4b0 addiu s7, zero, 5 | s7 = 5;
0x0002b4b4 b 0x2b9f0 | goto label_9;
| label_22:
0x0002b4b8 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b4bc addiu s6, zero, 0x27 | s6 = 0x27;
0x0002b4c0 b 0x2b4f4 |
| while (a3 != 0) {
0x0002b4c4 lw a0, 0x4c(sp) | a0 = *(var_4ch);
| if (a3 == s6) {
0x0002b4c8 beq a3, s6, 0x2ba4c | goto label_34;
| }
0x0002b4cc addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b4d0 addiu t9, s4, -0x7d40 | t9 = s4 + -0x7d40;
0x0002b4d4 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b4d8 bal 0x282c0 | fcn_000282c0 ();
0x0002b4dc sw v0, 0x4c(sp) | *(var_4ch) = v0;
0x0002b4e0 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 == 0) {
0x0002b4e4 beqz v0, 0x2ba60 | goto label_11;
| }
0x0002b4e8 lw v0, 0x58(sp) | v0 = *(var_58h);
0x0002b4ec addiu v0, v0, 1 | v0++;
0x0002b4f0 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b4f4 lw v0, 0x58(sp) | v0 = *(var_58h);
0x0002b4f8 addu v0, s1, v0 | v0 = s1 + v0;
0x0002b4fc lbu a3, (v0) | a3 = *(v0);
0x0002b500 addiu s7, zero, 5 | s7 = 5;
0x0002b504 bnez a3, 0x2b4c4 |
| }
0x0002b508 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x0002b50c b 0x2b9f4 | goto label_35;
| label_8:
0x0002b510 addiu t9, s5, -0x792c | t9 = s5 + -0x792c;
0x0002b514 move a1, zero | a1 = 0;
0x0002b518 bal 0x286d4 | fcn_000286d4 ();
0x0002b51c move s7, v0 | s7 = v0;
0x0002b520 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 == 0) {
0x0002b524 beqz v0, 0x2b9ac | goto label_36;
| }
0x0002b528 lw ra, 0x9c(sp) | ra = *(var_9ch);
0x0002b52c b 0x2ba6c | goto label_37;
| label_26:
0x0002b530 lw t9, -0x7fb4(gp) | t9 = *((gp - 8173));
0x0002b534 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b538 lw v0, (s0) | v0 = *(s0);
0x0002b53c addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b540 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b544 sw v0, 0x14(sp) | *(var_14h) = v0;
0x0002b548 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b54c addiu t9, t9, -0x71c8 | t9 += -0x71c8;
0x0002b550 move a3, s1 | a3 = s1;
0x0002b554 bal 0x28e38 | fcn_00028e38 ();
0x0002b558 lw gp, 0x28(sp) | gp = *(var_28h);
| label_27:
0x0002b55c move s7, v0 | s7 = v0;
| if (v0 == 0) {
0x0002b560 beqz v0, 0x2b9ac | goto label_36;
| }
0x0002b564 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x0002b568 b 0x2b9f4 | goto label_35;
| label_18:
0x0002b56c sw zero, 0x3c(sp) | *(var_3ch) = 0;
| label_25:
0x0002b570 sw zero, 0x40(sp) | *(var_40h) = 0;
0x0002b574 sw zero, 0x44(sp) | *(var_44h) = 0;
0x0002b578 move s6, zero | s6 = 0;
0x0002b57c addiu s7, zero, 1 | s7 = 1;
0x0002b580 b 0x2b6e8 |
| while (fp != 0) {
0x0002b584 lw t9, -0x7f94(gp) | t9 = *((gp - 8165));
| if (s2 != 0) {
0x0002b588 beqz s2, 0x2b594 |
0x0002b58c move a0, s2 | a0 = s2;
0x0002b590 b 0x2b59c |
| } else {
0x0002b594 lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x0002b598 addiu a0, a0, 0x4954 | a0 += 0x4954;
| }
0x0002b59c move a1, fp | a1 = fp;
0x0002b5a0 bal 0x3b410 | sym_index ();
0x0002b5a4 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b5a8 bnez v0, 0x2b6fc | goto label_38;
| }
0x0002b5ac addiu v0, zero, 0x27 | v0 = 0x27;
0x0002b5b0 addiu v0, zero, 0x22 | v0 = 0x22;
| if (fp != v0) {
0x0002b5b4 bnel fp, v0, 0x2b5c8 |
0x0002b5b8 addiu v0, zero, 1 | v0 = 1;
| if (s6 == 0) {
0x0002b5bc bnez s6, 0x2b5dc |
0x0002b5c0 addiu s6, zero, 1 | s6 = 1;
0x0002b5c4 b 0x2b6d0 |
| } else {
0x0002b5c8 addiu v0, zero, 1 | v0 = 1;
| if (fp != v0) {
0x0002b5cc bne fp, v0, 0x2b5e4 | goto label_39;
| }
| if (s6 == 0) {
0x0002b5d0 beql s6, zero, 0x2b6dc | goto label_40;
| }
0x0002b5d4 addiu s6, zero, 2 | s6 = 2;
0x0002b5d8 addiu v0, zero, 2 | v0 = 2;
| }
0x0002b5dc addiu v0, zero, 1 | v0 = 1;
| if (s6 == v0) {
0x0002b5e0 beq s6, v0, 0x2b6d8 | goto label_41;
| }
| label_39:
0x0002b5e4 addiu v0, zero, 0x24 | v0 = 0x24;
| if (s6 != v0) {
0x0002b5e8 beq s6, v0, 0x2b650 |
0x0002b5ec addiu v0, zero, 0x5c | v0 = 0x5c;
| if (fp != v0) {
0x0002b5f0 bne fp, v0, 0x2b654 | goto label_42;
| }
0x0002b5f4 addiu v0, sp, 0x58 | v0 = sp + 0x58;
0x0002b5f8 sw v0, 0x10(sp) | *(var_10h) = v0;
0x0002b5fc addiu v0, sp, 0x3c | v0 = sp + 0x3c;
0x0002b600 lw t9, -0x7fb4(gp) | t9 = *((gp - 8173));
0x0002b604 sw v0, 0x18(sp) | *(var_18h) = v0;
0x0002b608 addiu v0, sp, 0x48 | v0 = sp + 0x48;
0x0002b60c sw v0, 0x20(sp) | *(var_20h) = v0;
0x0002b610 xori v0, s6, 2 | v0 = s6 ^ 2;
0x0002b614 sltiu v0, v0, 1 | v0 = (v0 < 1) ? 1 : 0;
0x0002b618 sw s3, 0x14(sp) | *(var_14h) = s3;
0x0002b61c sw s2, 0x1c(sp) | *(var_1ch) = s2;
0x0002b620 sw v0, 0x24(sp) | *(var_24h) = v0;
0x0002b624 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b628 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b62c addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b630 addiu t9, t9, -0x6634 | t9 += -0x6634;
0x0002b634 move a3, s1 | a3 = s1;
0x0002b638 bal 0x299cc | fcn_000299cc ();
0x0002b63c move s7, v0 | s7 = v0;
0x0002b640 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 == 0) {
0x0002b644 beqz v0, 0x2b6dc | goto label_40;
| }
0x0002b648 lw t9, -0x7f4c(gp) | t9 = *((gp - 8147));
0x0002b64c b 0x2b8f4 | goto label_43;
| }
0x0002b650 addiu v0, zero, 0x5c | v0 = 0x5c;
| label_42:
0x0002b654 lw a0, 0x4c(sp) | a0 = *(var_4ch);
| if (fp == v0) {
0x0002b658 bne fp, v0, 0x2b6a8 |
0x0002b65c addiu v1, sp, 0x58 | v1 = sp + 0x58;
0x0002b660 sw v1, 0x10(sp) | *(var_10h) = v1;
0x0002b664 addiu a0, sp, 0x4c | a0 = sp + 0x4c;
0x0002b668 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b66c addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b670 move a3, s1 | a3 = s1;
| if (s6 != 0) {
0x0002b674 beqz s6, 0x2b684 |
0x0002b678 lw v0, -0x7fb4(gp) | v0 = *((gp - 8173));
0x0002b67c addiu t9, v0, -0x7bec | t9 = v0 + -0x7bec;
0x0002b680 b 0x2b68c |
| } else {
0x0002b684 lw v0, -0x7fb4(gp) | v0 = *((gp - 8173));
0x0002b688 addiu t9, v0, -0x7c80 | t9 = v0 + -0x7c80;
| }
0x0002b68c jalr t9 | t9 ();
0x0002b690 nop |
0x0002b694 move s7, v0 | s7 = v0;
0x0002b698 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 == 0) {
0x0002b69c beqz v0, 0x2b6dc | goto label_40;
| }
0x0002b6a0 lw t9, -0x7f4c(gp) | t9 = *((gp - 8147));
0x0002b6a4 b 0x2b8f4 | goto label_43;
| }
0x0002b6a8 addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b6ac addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b6b0 addiu t9, s4, -0x7d40 | t9 = s4 + -0x7d40;
0x0002b6b4 move a3, fp | a3 = fp;
0x0002b6b8 bal 0x282c0 | fcn_000282c0 ();
0x0002b6bc sw v0, 0x4c(sp) | *(var_4ch) = v0;
0x0002b6c0 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b6c4 bnez v0, 0x2b6dc | goto label_40;
| }
0x0002b6c8 lw t9, -0x7f4c(gp) | t9 = *((gp - 8147));
0x0002b6cc b 0x2b8f4 | goto label_43;
| }
0x0002b6d0 lw v0, 0x58(sp) | v0 = *(var_58h);
0x0002b6d4 b 0x2b6e0 | goto label_44;
| label_41:
0x0002b6d8 move s6, zero | s6 = 0;
| label_40:
0x0002b6dc lw v0, 0x58(sp) | v0 = *(var_58h);
| label_44:
0x0002b6e0 addiu v0, v0, 1 | v0++;
0x0002b6e4 sw v0, 0x58(sp) | *(var_58h) = v0;
0x0002b6e8 lw v1, 0x58(sp) | v1 = *(var_58h);
0x0002b6ec addu v0, s1, v1 | v0 = s1 + v1;
0x0002b6f0 lbu fp, (v0) | fp = *(v0);
0x0002b6f4 sw v1, 0x68(sp) | *(var_68h) = v1;
0x0002b6f8 bnez fp, 0x2b584 |
| }
| label_38:
0x0002b6fc lw t9, 0x68(sp) | t9 = *(var_68h);
0x0002b700 lw a1, 0x4c(sp) | a1 = *(var_4ch);
0x0002b704 addiu a0, sp, 0x3c | a0 = sp + 0x3c;
0x0002b708 addiu s6, t9, -1 | s6 = t9 + -1;
0x0002b70c addiu t9, s5, -0x792c | t9 = s5 + -0x792c;
0x0002b710 sw s6, 0x58(sp) | *(var_58h) = s6;
0x0002b714 bal 0x286d4 | fcn_000286d4 ();
0x0002b718 move s7, v0 | s7 = v0;
0x0002b71c lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b720 sw zero, 0x50(sp) | *(var_50h) = 0;
0x0002b724 sw zero, 0x54(sp) | *(var_54h) = 0;
0x0002b728 sw zero, 0x4c(sp) | *(var_4ch) = 0;
0x0002b72c move s6, zero | s6 = 0;
0x0002b730 b 0x2b8dc | goto label_45;
| label_5:
0x0002b734 sll v0, s6, 2 | v0 = s6 << 2;
0x0002b738 lw t9, -0x7f44(gp) | t9 = *((gp - 8145));
0x0002b73c addu v0, v1, v0 | v0 = v1 + v0;
0x0002b740 lw a0, (v0) | a0 = *(v0);
0x0002b744 addiu a1, zero, 0x10 | a1 = 0x10;
0x0002b748 move a2, zero | a2 = 0;
0x0002b74c addiu a3, sp, 0x30 | a3 = sp + 0x30;
0x0002b750 bal 0x17e64 | sym_glob ();
0x0002b754 addiu s7, zero, 1 | s7 = 1;
0x0002b758 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b75c bnez v0, 0x2b8d8 | goto label_46;
| }
0x0002b760 lw a0, 0x4c(sp) | a0 = *(var_4ch);
| if (s2 == 0) {
0x0002b764 beqz s2, 0x2b834 | goto label_47;
| }
0x0002b768 lbu v0, (s2) | v0 = *(s2);
0x0002b76c lw v0, 0x34(sp) | v0 = *(var_34h);
| if (v0 != 0) {
0x0002b770 bnez v0, 0x2b834 | goto label_47;
| }
0x0002b774 addiu s7, sp, 0x54 | s7 = sp + 0x54;
0x0002b778 addiu fp, sp, 0x50 | fp = sp + 0x50;
0x0002b77c lw a3, (v0) | a3 = *(v0);
0x0002b780 lw v0, -0x7fb4(gp) | v0 = *((gp - 8173));
0x0002b784 move a1, s7 | a1 = s7;
0x0002b788 addiu t9, v0, -0x7998 | t9 = v0 + -0x7998;
0x0002b78c move a2, fp | a2 = fp;
0x0002b790 bal 0x28668 | fcn_00028668 ();
0x0002b794 sw v0, 0x4c(sp) | *(var_4ch) = v0;
0x0002b798 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b79c addiu v1, zero, 1 | v1 = 1;
0x0002b7a0 b 0x2b800 |
| while (a0 == 0) {
0x0002b7a4 move a1, s7 | a1 = s7;
0x0002b7a8 move a2, fp | a2 = fp;
0x0002b7ac addiu t9, s4, -0x7d40 | t9 = s4 + -0x7d40;
0x0002b7b0 addiu a3, zero, 0x20 | a3 = 0x20;
0x0002b7b4 bal 0x282c0 | fcn_000282c0 ();
0x0002b7b8 sw v0, 0x4c(sp) | *(var_4ch) = v0;
0x0002b7bc lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b7c0 lw v1, 0x74(sp) | v1 = *(var_74h);
| if (v0 != 0) {
0x0002b7c4 beqz v0, 0x2b7fc |
0x0002b7c8 lw a0, 0x34(sp) | a0 = *(var_34h);
0x0002b7cc sll a3, v1, 2 | a3 = v1 << 2;
0x0002b7d0 move a1, s7 | a1 = s7;
0x0002b7d4 addu a3, a0, a3 | a3 = a0 + a3;
0x0002b7d8 move a0, v0 | a0 = v0;
0x0002b7dc lw v0, -0x7fb4(gp) | v0 = *((gp - 8173));
0x0002b7e0 lw a3, (a3) | a3 = *(a3);
0x0002b7e4 addiu t9, v0, -0x7998 | t9 = v0 + -0x7998;
0x0002b7e8 move a2, fp | a2 = fp;
0x0002b7ec bal 0x28668 | fcn_00028668 ();
0x0002b7f0 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b7f4 lw v1, 0x74(sp) | v1 = *(var_74h);
0x0002b7f8 sw v0, 0x4c(sp) | *(var_4ch) = v0;
| }
0x0002b7fc addiu v1, v1, 1 | v1++;
0x0002b800 lw v0, 0x30(sp) | v0 = *(var_30h);
0x0002b804 sltu v0, v1, v0 | v0 = (v1 < v0) ? 1 : 0;
0x0002b808 lw a0, 0x4c(sp) | a0 = *(var_4ch);
| if (v0 == 0) {
0x0002b80c beqz v0, 0x2b818 | goto label_48;
| }
0x0002b810 sw v1, 0x74(sp) | *(var_74h) = v1;
0x0002b814 bnel a0, zero, 0x2b7a4 |
| }
| label_48:
0x0002b818 lw t9, -0x7f40(gp) | t9 = *((gp - 8144));
0x0002b81c addiu a0, sp, 0x30 | a0 = sp + 0x30;
0x0002b820 bal 0x1810c | sym_globfree ();
0x0002b824 lw v1, 0x4c(sp) | v1 = *(var_4ch);
0x0002b828 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b82c sltiu s7, v1, 1 | s7 = (v1 < 1) ? 1 : 0;
0x0002b830 b 0x2b8d8 | goto label_46;
| label_47:
0x0002b834 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
| if (a0 != 0) {
0x0002b838 beqz a0, 0x2b854 |
0x0002b83c jalr t9 | t9 ();
0x0002b840 nop |
0x0002b844 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b848 sw zero, 0x50(sp) | *(var_50h) = 0;
0x0002b84c sw zero, 0x54(sp) | *(var_54h) = 0;
0x0002b850 sw zero, 0x4c(sp) | *(var_4ch) = 0;
| }
0x0002b854 move fp, zero | fp = 0;
0x0002b858 lw s7, -0x7fac(gp) | s7 = *((gp - 8171));
0x0002b85c b 0x2b8b4 | goto label_49;
| label_4:
0x0002b860 sll v0, fp, 2 | v0 = fp << 2;
0x0002b864 move t9, s7 | t9 = s7;
0x0002b868 addu v0, v1, v0 | v0 = v1 + v0;
0x0002b86c lw a0, (v0) | a0 = *(v0);
0x0002b870 bal 0x3c470 | sym_strdup ();
0x0002b874 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b878 bnez v0, 0x2b894 |
| while (v0 != 0) {
0x0002b87c lw t9, -0x7f40(gp) | t9 = *((gp - 8144));
0x0002b880 addiu a0, sp, 0x30 | a0 = sp + 0x30;
0x0002b884 addiu s7, zero, 1 | s7 = 1;
0x0002b888 bal 0x1810c | sym_globfree ();
0x0002b88c lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b890 b 0x2b8d8 | goto label_46;
0x0002b894 move a1, v0 | a1 = v0;
0x0002b898 lw v0, -0x7fb4(gp) | v0 = *((gp - 8173));
0x0002b89c addiu t9, v0, -0x792c | t9 = v0 + -0x792c;
0x0002b8a0 move a0, s0 | a0 = s0;
0x0002b8a4 bal 0x286d4 | fcn_000286d4 ();
0x0002b8a8 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b8ac bnez v0, 0x2b87c |
| }
0x0002b8b0 addiu fp, fp, 1 | fp++;
| label_49:
0x0002b8b4 lw v0, 0x30(sp) | v0 = *(var_30h);
0x0002b8b8 sltu v0, fp, v0 | v0 = (fp < v0) ? 1 : 0;
0x0002b8bc lw v1, 0x34(sp) | v1 = *(var_34h);
| if (v0 != 0) {
0x0002b8c0 bnez v0, 0x2b860 | goto label_4;
| }
0x0002b8c4 lw t9, -0x7f40(gp) | t9 = *((gp - 8144));
0x0002b8c8 addiu a0, sp, 0x30 | a0 = sp + 0x30;
0x0002b8cc move s7, zero | s7 = 0;
0x0002b8d0 bal 0x1810c | sym_globfree ();
0x0002b8d4 lw gp, 0x28(sp) | gp = *(var_28h);
| label_46:
0x0002b8d8 addiu s6, s6, 1 | s6++;
| label_45:
0x0002b8dc lw v0, 0x3c(sp) | v0 = *(var_3ch);
| if (s7 != 0) {
0x0002b8e0 bnez s7, 0x2b8f0 | goto label_50;
| }
0x0002b8e4 sltu v0, s6, v0 | v0 = (s6 < v0) ? 1 : 0;
0x0002b8e8 lw v1, 0x40(sp) | v1 = *(var_40h);
| if (v0 != 0) {
0x0002b8ec bnez v0, 0x2b734 | goto label_5;
| }
| label_50:
0x0002b8f0 lw t9, -0x7f4c(gp) | t9 = *((gp - 8147));
| label_43:
0x0002b8f4 addiu a0, sp, 0x3c | a0 = sp + 0x3c;
0x0002b8f8 bal 0x2aff8 | sym_wordfree ();
0x0002b8fc lw gp, 0x28(sp) | gp = *(var_28h);
| if (s7 == 0) {
0x0002b900 beqz s7, 0x2b9ac | goto label_36;
| }
0x0002b904 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x0002b908 b 0x2b9f4 | goto label_35;
| label_20:
0x0002b90c lw fp, -0x7f94(gp) | fp = *((gp - 8165));
0x0002b910 move a1, s6 | a1 = s6;
0x0002b914 move t9, fp | t9 = fp;
0x0002b918 addiu a0, a0, 0x5534 | a0 += 0x5534;
0x0002b91c bal 0x3b410 | sym_index ();
0x0002b920 lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b924 lw s7, 0x4c(sp) | s7 = *(var_4ch);
| if (v0 == 0) {
0x0002b928 bnez v0, 0x2b974 |
0x0002b92c lw a0, -0x7fd0(gp) | a0 = *((gp - 8180));
0x0002b930 move a1, s6 | a1 = s6;
0x0002b934 move t9, fp | t9 = fp;
0x0002b938 addiu a0, a0, 0x5538 | a0 += 0x5538;
0x0002b93c bal 0x3b410 | sym_index ();
0x0002b940 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b944 bnez v0, 0x2b9ec | goto label_51;
| }
0x0002b948 move a0, s7 | a0 = s7;
0x0002b94c addiu a1, sp, 0x54 | a1 = sp + 0x54;
0x0002b950 addiu a2, sp, 0x50 | a2 = sp + 0x50;
0x0002b954 addiu t9, s4, -0x7d40 | t9 = s4 + -0x7d40;
0x0002b958 move a3, s6 | a3 = s6;
0x0002b95c bal 0x282c0 | fcn_000282c0 ();
0x0002b960 sw v0, 0x4c(sp) | *(var_4ch) = v0;
0x0002b964 lw gp, 0x28(sp) | gp = *(var_28h);
| if (v0 != 0) {
0x0002b968 bnez v0, 0x2b9ac | goto label_36;
| }
0x0002b96c addiu s7, zero, 1 | s7 = 1;
0x0002b970 b 0x2b9f0 | goto label_9;
| }
0x0002b974 move a1, s7 | a1 = s7;
0x0002b978 bnez s7, 0x2b98c |
| while (v0 == 0) {
0x0002b97c sw zero, 0x50(sp) | *(var_50h) = 0;
0x0002b980 sw zero, 0x54(sp) | *(var_54h) = 0;
0x0002b984 sw zero, 0x4c(sp) | *(var_4ch) = 0;
0x0002b988 b 0x2b9ac | goto label_36;
0x0002b98c addiu t9, s5, -0x792c | t9 = s5 + -0x792c;
0x0002b990 move a0, s0 | a0 = s0;
0x0002b994 bal 0x286d4 | fcn_000286d4 ();
0x0002b998 move s7, v0 | s7 = v0;
0x0002b99c lw gp, 0x28(sp) | gp = *(var_28h);
0x0002b9a0 beqz v0, 0x2b97c |
| }
0x0002b9a4 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
0x0002b9a8 b 0x2b9f4 | goto label_35;
| label_36:
0x0002b9ac lw v0, 0x58(sp) | v0 = *(var_58h);
| label_7:
0x0002b9b0 addiu v0, v0, 1 | v0++;
0x0002b9b4 sw v0, 0x58(sp) | *(var_58h) = v0;
| label_17:
0x0002b9b8 lw v0, 0x58(sp) | v0 = *(var_58h);
0x0002b9bc addu v1, s1, v0 | v1 = s1 + v0;
0x0002b9c0 lbu s6, (v1) | s6 = *(v1);
0x0002b9c4 addiu v1, zero, 0x3f | v1 = 0x3f;
| if (s6 != 0) {
0x0002b9c8 bnez s6, 0x2b220 | goto label_6;
| }
0x0002b9cc lw a1, 0x4c(sp) | a1 = *(var_4ch);
0x0002b9d0 lw t9, -0x7fb4(gp) | t9 = *((gp - 8173));
| if (a1 == 0) {
0x0002b9d4 beqz a1, 0x2ba3c | goto label_52;
| }
0x0002b9d8 addiu t9, t9, -0x792c | t9 += -0x792c;
0x0002b9dc move a0, s0 | a0 = s0;
0x0002b9e0 bal 0x286d4 | fcn_000286d4 ();
0x0002b9e4 move s7, v0 | s7 = v0;
0x0002b9e8 b 0x2ba68 | goto label_53;
| label_51:
0x0002b9ec addiu s7, zero, 2 | s7 = 2;
| do {
| label_9:
0x0002b9f0 lw t9, -0x7664(gp) | t9 = *((gp - 7577));
| label_35:
0x0002b9f4 lw a0, 0x4c(sp) | a0 = *(var_4ch);
0x0002b9f8 jalr t9 | t9 ();
0x0002b9fc addiu v0, zero, 1 | v0 = 1;
0x0002ba00 lw gp, 0x28(sp) | gp = *(var_28h);
| if (s7 == v0) {
0x0002ba04 beq s7, v0, 0x2ba68 | goto label_53;
| }
0x0002ba08 lw v1, 0x60(sp) | v1 = *(var_60h);
0x0002ba0c lw t9, 0x70(sp) | t9 = *(var_70h);
| if (v1 == 0) {
0x0002ba10 bnez v1, 0x2ba24 |
0x0002ba14 lw t9, -0x7f4c(gp) | t9 = *((gp - 8147));
0x0002ba18 move a0, s0 | a0 = s0;
0x0002ba1c bal 0x2aff8 | sym_wordfree ();
0x0002ba20 lw t9, 0x70(sp) | t9 = *(var_70h);
| }
0x0002ba24 lw v1, 0x64(sp) | v1 = *(var_64h);
0x0002ba28 sw t9, (s0) | *(s0) = t9;
0x0002ba2c lw t9, 0x6c(sp) | t9 = *(var_6ch);
0x0002ba30 sw v1, 4(s0) | *((s0 + 1)) = v1;
0x0002ba34 sw t9, 8(s0) | *((s0 + 2)) = t9;
0x0002ba38 b 0x2ba68 | goto label_53;
| label_52:
0x0002ba3c move s7, zero | s7 = 0;
0x0002ba40 b 0x2ba68 | goto label_53;
| label_28:
0x0002ba44 addiu s7, zero, 4 | s7 = 4;
0x0002ba48 b 0x2b9f0 |
| } while (1);
| label_34:
0x0002ba4c lw v0, 0x54(sp) | v0 = *(var_54h);
| label_31:
0x0002ba50 lw v0, 0x58(sp) | v0 = *(var_58h);
| if (v0 != 0) {
0x0002ba54 bnez v0, 0x2b9b0 | goto label_7;
| }
0x0002ba58 move a0, s0 | a0 = s0;
0x0002ba5c b 0x2b510 | goto label_8;
| label_11:
0x0002ba60 addiu s7, zero, 1 | s7 = 1;
0x0002ba64 b 0x2b9f0 | goto label_9;
| label_53:
0x0002ba68 lw ra, 0x9c(sp) | ra = *(var_9ch);
| label_37:
0x0002ba6c move v0, s7 | v0 = s7;
0x0002ba70 lw fp, 0x98(sp) | fp = *(var_98h);
0x0002ba74 lw s7, 0x94(sp) | s7 = *(var_94h);
0x0002ba78 lw s6, 0x90(sp) | s6 = *(var_90h);
0x0002ba7c lw s5, 0x8c(sp) | s5 = *(var_8ch);
0x0002ba80 lw s4, 0x88(sp) | s4 = *(var_88h);
0x0002ba84 lw s3, 0x84(sp) | s3 = *(var_84h);
0x0002ba88 lw s2, 0x80(sp) | s2 = *(var_80h);
0x0002ba8c lw s1, 0x7c(sp) | s1 = *(var_7ch);
0x0002ba90 lw s0, 0x78(sp) | s0 = *(var_78h);
0x0002ba94 addiu sp, sp, 0xa0 |
0x0002ba98 jr ra | return v0;
| }
[*] Function strcpy used 26 times libuClibc-0.9.33.2.so