[*] Binary protection state of libkmod.so.2.4.0
Full RELRO Canary found NX enabled DSO No RPATH No RUNPATH No Symbols
[*] Function printf tear down of libkmod.so.2.4.0
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-80367616.squashfs_v4_le_extract/usr/lib/libkmod.so.2.4.0 @ 0x3e60 */
| #include <stdint.h>
|
; (fcn) fcn.00003e60 () | void fcn_00003e60 (int16_t arg1, int16_t arg2, int16_t arg3) {
| int16_t var_0h;
| int16_t var_4h;
| int16_t var_8h;
| int16_t fildes;
| int32_t var_10h_2;
| void * s1;
| int16_t var_1ch;
| int16_t var_20h;
| int16_t var_24h;
| int16_t var_28h;
| int16_t var_2ch;
| int16_t var_30h;
| int16_t var_34h;
| int16_t var_38h;
| int16_t var_3ch;
| int16_t var_40h;
| int16_t var_44h;
| int16_t var_48h;
| void * s2;
| int16_t var_50h;
| void * var_54h;
| int16_t var_58h;
| int16_t var_5ch;
| int16_t var_64h;
| int16_t var_68h;
| int16_t var_d0h;
| int16_t var_140h;
| int16_t var_1120h;
| int32_t var_0h_2;
| int16_t var_1140h;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
0x00003e60 svcmi 0xf0e92d | __asm ("svcmi 0xf0e92d");
0x00003e64 mov r6, r2 | r6 = r2;
0x00003e66 ldr.w r2, [pc, 0xa4c] |
0x00003e6a sub.w sp, sp, 0x1140 |
0x00003e6e sub sp, 4 |
0x00003e70 mov sl, r1 | sl = r1;
0x00003e72 ldr.w r3, [pc, 0xa44] | r3 = *(0x48ba);
0x00003e76 add.w r1, sp, 0x1120 | r1 += var_1120h;
0x00003e7a add r2, pc | r2 = 0x8734;
0x00003e7c adds r1, 0x1c | r1 += 0x1c;
0x00003e7e add r5, sp, 0x140 | r5 += var_140h;
0x00003e80 movs r4, 0 | r4 = 0;
0x00003e82 ldr r3, [r2, r3] |
0x00003e84 mov r8, r0 | r8 = r0;
0x00003e86 ldr r3, [r3] | r3 = *(0x8734);
0x00003e88 str r3, [r1] | *(r1) = r3;
0x00003e8a mov.w r3, 0 | r3 = 0;
0x00003e8e str r5, [sp, 0x2c] | var_2ch = r5;
0x00003e90 str r4, [sp, 0x64] | var_64h = r4;
0x00003e92 blx 0x2160 | fcn_00002160 ();
0x00003e96 ldr.w r2, [pc, 0xa24] |
0x00003e9a add r3, sp, 0x64 | r3 += var_64h;
0x00003e9c mov r1, r0 | r1 = r0;
0x00003e9e mov r0, r3 | r0 = r3;
0x00003ea0 str r3, [sp, 0x18] | s1 = r3;
0x00003ea2 add r2, pc | r2 = 0x8764;
0x00003ea4 bl 0x3c20 | fcn_00003c20 (r0, r1, r2);
0x00003ea8 ldr r5, [r6] | r5 = *(r6);
0x00003eaa cmp r5, 0 |
| if (r5 == 0) {
0x00003eac beq.w 0x485a | goto label_30;
| }
0x00003eb0 ldr.w r3, [pc, 0xa0c] |
0x00003eb4 mov fp, r4 |
0x00003eb6 add r7, sp, 0x68 | r7 += var_68h;
0x00003eb8 strd r8, sl, [sp, 0x30] | __asm ("strd r8, sl, [var_34h]");
0x00003ebc add r3, pc | r3 = 0x8780;
0x00003ebe str r3, [sp, 0x1c] | var_1ch = r3;
0x00003ec0 ldr.w r3, [pc, 0xa00] |
0x00003ec4 add r3, pc | r3 = 0x878c;
0x00003ec6 str r3, [sp, 0x28] | var_28h = r3;
0x00003ec8 ldr r3, [sp, 0x2c] | r3 = var_2ch;
0x00003eca str r3, [sp, 0x24] | var_24h = r3;
0x00003ecc b 0x3ee2 |
| while (r0 != 0) {
0x00003ece blx 0x25e4 | r0 = fcn_000025e4 ();
0x00003ed2 ldr r3, [r0] | r3 = *(r0);
0x00003ed4 cmp r3, 0 |
| if (r3 <= 0) {
0x00003ed6 ble.w 0x41aa | goto label_31;
| }
| label_2:
0x00003eda ldr r5, [r6, 4]! | r5 = *((r6 += 4));
0x00003ede cmp r5, 0 |
| if (r5 == 0) {
0x00003ee0 beq 0x3f58 | goto label_32;
| }
| label_0:
0x00003ee2 mov r1, r7 | r1 = r7;
0x00003ee4 mov r0, r5 | r0 = r5;
0x00003ee6 blx 0x2304 | r0 = asprintf_chk ()
0x00003eea mov r4, r0 | r4 = r0;
0x00003eec cmp r0, 0 |
0x00003eee bne 0x3ece |
| }
0x00003ef0 mov r0, r7 | r0 = r7;
0x00003ef2 bl 0xae54 | fcn_0000ae54 (r0);
0x00003ef6 ldr r3, [sp, 0x24] | r3 = var_24h;
0x00003ef8 strd r0, r1, [sp, 0x10] | __asm ("strd r0, r1, [fildes]");
0x00003efc ldr r3, [r3, -0xc8] | r3 = *((r3 - 0xc8));
0x00003f00 and r3, r3, 0xf000 | r3 &= 0xf000;
0x00003f04 cmp.w r3, 0x4000 |
| if (r3 == 0x4000) {
0x00003f08 beq.w 0x4118 | goto label_33;
| }
0x00003f0c ldr r0, [sp, 0x18] | r0 = s1;
0x00003f0e mov r2, r4 | r2 = r4;
0x00003f10 mov r1, r5 | r1 = r5;
0x00003f12 bl 0x3c20 | fcn_00003c20 (r0, r1, r2);
| label_3:
0x00003f16 mov r0, r5 | r0 = r5;
0x00003f18 blx 0x2340 | r0 = fcn_00002340 ();
0x00003f1c mov r2, r0 | r2 = r0;
0x00003f1e adds r0, 9 | r0 += 9;
0x00003f20 add.w r8, r2, 1 | r8 = r2 + 1;
0x00003f24 blx 0x2480 | r0 = fcn_00002480 ();
0x00003f28 mov r4, r0 | r4 = r0;
0x00003f2a cmp r0, 0 |
| if (r0 == 0) {
0x00003f2c beq.w 0x4418 | goto label_34;
| }
0x00003f30 mov r2, r8 | r2 = r8;
0x00003f32 ldrd r8, sb, [sp, 0x10] | __asm ("ldrd r8, sb, [fildes]");
0x00003f36 mov r1, r5 | r1 = r5;
0x00003f38 strd r8, sb, [r0], 8 | __asm ("strd r8, sb, [r0], 8");
0x00003f3c blx 0x2368 | fcn_00002368 ();
0x00003f40 mov r1, r4 | r1 = r4;
0x00003f42 mov r0, fp | r0 = fp;
0x00003f44 bl 0x3944 | r0 = fcn_00003944 (r0, r1);
0x00003f48 cmp r0, 0 |
| if (r0 == 0) {
0x00003f4a beq.w 0x4412 | goto label_35;
| }
0x00003f4e ldr r5, [r6, 4]! | r5 = *((r6 += 4));
0x00003f52 mov fp, r0 |
0x00003f54 cmp r5, 0 |
| if (r5 != 0) {
0x00003f56 bne 0x3ee2 | goto label_0;
| }
| label_32:
0x00003f58 ldrd r8, sl, [sp, 0x30] | __asm ("ldrd r8, sl, [var_34h]");
| label_26:
0x00003f5c movs r1, 0x20 | r1 = 0x20;
0x00003f5e movs r0, 1 | r0 = 1;
0x00003f60 blx 0x2210 | fcn_00002210 ();
0x00003f64 ldr r2, [sp, 0x2c] | r2 = var_2ch;
0x00003f66 str r0, [sp, 0x28] | var_28h = r0;
0x00003f68 str.w r0, [sl] | __asm ("str.w r0, [sl]");
0x00003f6c ldr r7, [r2, -0xdc] | r7 = *((r2 - 0xdc));
0x00003f70 cmp r0, 0 |
| if (r0 == 0) {
0x00003f72 beq.w 0x4418 | goto label_34;
| }
0x00003f76 str.w fp, [r0, 0x1c] | __asm ("str.w fp, [r0, 0x1c]");
0x00003f7a str.w r8, [r0] | __asm ("str.w r8, [r0]");
0x00003f7e cmp r7, 0 |
| if (r7 == 0) {
0x00003f80 beq.w 0x42a0 | goto label_36;
| }
0x00003f84 ldr.w r5, [pc, 0x940] |
0x00003f88 add.w fp, sp, 0xd0 |
0x00003f8c ldr.w r3, [pc, 0x93c] |
0x00003f90 mov sb, r2 | sb = r2;
0x00003f92 mov sl, fp | sl = fp;
0x00003f94 add r5, pc | r5 = 0x8860;
0x00003f96 add r3, pc | r3 = 0x8866;
0x00003f98 str r5, [sp, 0x34] | var_34h = r5;
0x00003f9a str r3, [sp, 0x30] | var_30h = r3;
0x00003f9c b 0x3fb6 |
| while (r4 < r0) {
| label_4:
0x00003f9e mov r0, r5 | r0 = r5;
0x00003fa0 blx 0x22bc | read (r0, r1, r2);
0x00003fa4 mov r0, r7 | r0 = r7;
0x00003fa6 bl 0x39e8 | r0 = fcn_000039e8 (r0);
0x00003faa mov r7, r0 | r7 = r0;
0x00003fac str r0, [sb, -0xdc] | *((sb - 0xdc)) = r0;
0x00003fb0 cmp r0, 0 |
| if (r0 == 0) {
0x00003fb2 beq.w 0x42a0 | goto label_36;
| }
0x00003fb6 ldr r5, [r7, 8] | r5 = *((r7 + 8));
0x00003fb8 ldrb r3, [r5, 4] | r3 = *((r5 + 4));
0x00003fba ldr r0, [r5] | r0 = *(r5);
0x00003fbc cmp r3, 0 |
| if (r3 == 0) {
0x00003fbe beq.w 0x41c4 | goto label_37;
| }
| label_5:
0x00003fc2 mov.w r1, 0x80000 | r1 = 0x80000;
0x00003fc6 blx 0x23b0 | r0 = fcn_000023b0 ();
0x00003fca subs r4, r0, 0 | r4 = r0 - 0;
0x00003fcc blt 0x3f9e |
| }
0x00003fce movs r3, 0 | r3 = 0;
0x00003fd0 ldr r1, [sp, 0x34] | r1 = var_34h;
0x00003fd2 str r3, [sb, -0xd8] | *((sb - 0xd8)) = r3;
0x00003fd6 blx 0x23f0 | r0 = fcn_000023f0 ();
0x00003fda mov fp, r0 |
0x00003fdc cmp r0, 0 |
| if (r0 == 0) {
0x00003fde beq.w 0x48aa | goto label_38;
| }
0x00003fe2 add r3, sp, 0x68 | r3 += var_68h;
0x00003fe4 str.w sb, [sp, 0x24] | __asm ("str.w sb, [var_24h]");
0x00003fe8 mov r8, r3 | r8 = r3;
0x00003fea ldr.w sb, [sp, 0x30] | sb = var_30h;
0x00003fee strd r7, r5, [sp, 0x1c] | __asm ("strd r7, r5, [var_1ch]");
0x00003ff2 b 0x405c | goto label_39;
0x00003ff4 ldr.w r1, [pc, 0x8d8] |
0x00003ff8 mov r0, r5 | r0 = r5;
0x00003ffa add r1, pc | r1 = 0x88ce;
0x00003ffc blx 0x25d8 | r0 = fcn_000025d8 ();
0x00004000 cmp r0, 0 |
| if (r0 == 0) {
0x00004002 beq.w 0x41f2 | goto label_40;
| }
0x00004006 ldr.w r1, [pc, 0x8cc] |
0x0000400a mov r0, r5 | r0 = r5;
0x0000400c add r1, pc | r1 = 0x88e6;
0x0000400e blx 0x25d8 | r0 = fcn_000025d8 ();
0x00004012 mov r6, r0 | r6 = r0;
0x00004014 cmp r0, 0 |
| if (r0 == 0) {
0x00004016 beq.w 0x4228 | goto label_41;
| }
0x0000401a ldr.w r1, [pc, 0x8bc] |
0x0000401e mov r0, r5 | r0 = r5;
0x00004020 add r1, pc | r1 = 0x88fe;
0x00004022 blx 0x25d8 | r0 = fcn_000025d8 ();
0x00004026 mov r6, r0 | r6 = r0;
0x00004028 cmp r0, 0 |
| if (r0 == 0) {
0x0000402a beq.w 0x4262 | goto label_42;
| }
0x0000402e ldr.w r1, [pc, 0x8ac] |
0x00004032 mov r0, r5 | r0 = r5;
0x00004034 add r1, pc | r1 = 0x8916;
0x00004036 blx 0x25d8 | r0 = fcn_000025d8 ();
0x0000403a mov r6, r0 | r6 = r0;
0x0000403c cmp r0, 0 |
| if (r0 == 0) {
0x0000403e beq.w 0x43d4 | goto label_43;
| }
0x00004042 ldr.w r1, [pc, 0x89c] |
0x00004046 mov r0, r5 | r0 = r5;
0x00004048 add r1, pc | r1 = 0x892e;
0x0000404a blx 0x25d8 | r0 = fcn_000025d8 ();
0x0000404e mov r5, r0 | r5 = r0;
0x00004050 cmp r0, 0 |
| if (r0 == 0) {
0x00004052 beq.w 0x4458 | goto label_44;
| }
| do {
| label_1:
0x00004056 ldr r0, [sp, 0x10] | r0 = fildes;
0x00004058 blx 0x22bc | read (r0, r1, r2);
| label_39:
0x0000405c mov r1, r8 | r1 = r8;
0x0000405e mov r0, fp | r0 = fp;
0x00004060 bl 0xad24 | fcn_0000ad24 (r0, r1);
0x00004064 str r0, [sp, 0x10] | fildes = r0;
0x00004066 cmp r0, 0 |
| if (r0 == 0) {
0x00004068 beq.w 0x41b4 | goto label_45;
| }
0x0000406c ldr r3, [sp, 0x10] | r3 = fildes;
0x0000406e ldrb r3, [r3] | r3 = *(r3);
0x00004070 cmp r3, 0x23 |
0x00004072 it ne |
| if (r3 != 0x23) {
0x00004074 cmpne r3, 0 | __asm ("cmpne r3, 0");
| }
0x00004076 beq 0x4056 |
| } while (r3 == 0x23);
0x00004078 mov r2, sl | r2 = sl;
0x0000407a mov r1, sb | r1 = sb;
0x0000407c blx 0x24c8 | r0 = fcn_000024c8 ();
0x00004080 mov r5, r0 | r5 = r0;
0x00004082 cmp r0, 0 |
| if (r0 == 0) {
0x00004084 beq 0x4056 | goto label_1;
| }
0x00004086 ldr.w r1, [pc, 0x85c] | r1 = *(0x48e6);
0x0000408a lsls r1, r7, 1 | r1 = r7 << 1;
0x0000408c asrs r7, r5, 0x1d | r7 = r5 >> 0x1d;
0x0000408e movs r0, r0 |
0x00004090 asrs r7, r5, 0x1d | r7 = r5 >> 0x1d;
0x00004092 movs r0, r0 |
0x00004094 movs r0, r0 |
0x00004096 mov r0, r0 |
0x00004098 mov r1, sb | r1 = sb;
0x0000409a blx 0x24c8 | fcn_000024c8 ();
0x0000409e mov r2, sl | r2 = sl;
0x000040a0 mov r5, r0 | r5 = r0;
0x000040a2 mov r1, sb | r1 = sb;
0x000040a4 mov r0, r6 | r0 = r6;
0x000040a6 blx 0x24c8 | r0 = fcn_000024c8 ();
0x000040aa mov r6, r0 | r6 = r0;
0x000040ac mov r0, r5 | r0 = r5;
0x000040ae bl 0xaac4 | r0 = fcn_0000aac4 (r0);
0x000040b2 cmp r0, 0 |
| if (r0 < 0) {
0x000040b4 blt 0x4056 | goto label_1;
| }
0x000040b6 mov r0, r6 | r0 = r6;
0x000040b8 bl 0xaac4 | r0 = fcn_0000aac4 (r0);
0x000040bc cmp r0, 0 |
| if (r0 < 0) {
0x000040be blt 0x4056 | goto label_1;
| }
0x000040c0 mov r0, r5 | r0 = r5;
0x000040c2 blx 0x2340 | r0 = fcn_00002340 ();
0x000040c6 adds r4, r0, 1 | r4 = r0 + 1;
0x000040c8 mov r0, r6 | r0 = r6;
0x000040ca str r4, [sp, 0x18] | s1 = r4;
0x000040cc blx 0x2340 | r0 = fcn_00002340 ();
0x000040d0 adds r2, r0, 1 | r2 = r0 + 1;
0x000040d2 mov r7, r0 | r7 = r0;
0x000040d4 adds r0, r4, r2 | r0 = r4 + r2;
0x000040d6 str r2, [sp, 0x38] | var_38h = r2;
0x000040d8 adds r0, 4 | r0 += 4;
0x000040da blx 0x2480 | fcn_00002480 ();
0x000040de ldr r2, [sp, 0x38] | r2 = var_38h;
0x000040e0 mov r4, r0 | r4 = r0;
| if (r0 != 0) {
0x000040e2 cbz r0, 0x410e |
0x000040e4 adds r7, 5 | r7 += 5;
0x000040e6 mov r1, r6 | r1 = r6;
0x000040e8 add r7, r0 | r7 += r0;
0x000040ea str r0, [sp, 0x38] | var_38h = r0;
0x000040ec str r7, [r0], 4 | *(r0) = r7;
| r0 += 4;
0x000040f0 blx 0x2368 | fcn_00002368 ();
0x000040f4 mov r1, r5 | r1 = r5;
0x000040f6 ldr r2, [sp, 0x18] | r2 = s1;
0x000040f8 mov r0, r7 | r0 = r7;
0x000040fa blx 0x2368 | fcn_00002368 ();
0x000040fe ldr r3, [sp, 0x38] | r3 = var_38h;
0x00004100 ldr r5, [sp, 0x28] | r5 = var_28h;
0x00004102 mov r1, r3 | r1 = r3;
0x00004104 ldr r0, [r5, 4] | r0 = *((r5 + 4));
0x00004106 bl 0x3944 | r0 = fcn_00003944 (r0, r1);
| if (r0 == 0) {
0x0000410a cbz r0, 0x4110 | goto label_46;
| }
0x0000410c str r0, [r5, 4] | *((r5 + 4)) = r0;
| }
0x0000410e movs r4, 0 | r4 = 0;
| label_46:
0x00004110 mov r0, r4 | r0 = r4;
0x00004112 blx 0x22bc | read (r0, r1, r2);
0x00004116 b 0x4056 | goto label_1;
| label_33:
0x00004118 mov r0, r5 | r0 = r5;
0x0000411a blx 0x2148 | opendir ();
0x0000411c invalid |
0x00004120 cmp r0, 0 |
| if (r0 == 0) {
0x00004122 beq.w 0x3eda | goto label_2;
| }
0x00004126 blx 0x2554 | r0 = fcn_00002554 ();
0x0000412a mov sl, r0 | sl = r0;
0x0000412c cmp r0, 0 |
| if (r0 == 0) {
0x0000412e beq 0x41a2 | goto label_47;
| }
0x00004130 ldr.w sb, [sp, 0x24] | sb = var_24h;
0x00004134 add r3, sp, 0xd0 | r3 += var_d0h;
0x00004136 str r3, [sp, 0x20] | var_20h = r3;
| do {
0x00004138 add.w r4, sl, 0x13 | r4 = sl + 0x13;
0x0000413c mov r0, r4 | r0 = r4;
0x0000413e blx 0x2340 | fcn_00002340 ();
0x00004142 ldrb.w r2, [sl, 0x13] | r2 = *((sl + 0x13));
0x00004146 mov sl, r0 | sl = r0;
0x00004148 cmp r2, 0x2e |
| if (r2 != 0x2e) {
0x0000414a beq 0x4192 |
0x0000414c cmp r0, 5 |
| if (r0 < 5) {
0x0000414e bls 0x4192 | goto label_48;
| }
0x00004150 subs r0, 5 | r0 -= 5;
0x00004152 ldr r1, [sp, 0x1c] | r1 = var_1ch;
0x00004154 add r0, r4 | r0 += r4;
0x00004156 blx 0x25d8 | r0 = fcn_000025d8 ();
| if (r0 != 0) {
0x0000415a cbz r0, 0x416a |
0x0000415c sub.w r0, sl, 6 | r0 = sl - 6;
0x00004160 ldr r1, [sp, 0x28] | r1 = var_28h;
0x00004162 add r0, r4 | r0 += r4;
0x00004164 blx 0x25d8 | r0 = fcn_000025d8 ();
| if (r0 != 0) {
0x00004168 cbnz r0, 0x4192 | goto label_48;
| }
| }
0x0000416a mov r0, r8 | r0 = r8;
0x0000416c blx 0x23e4 | fcn_000023e4 ();
0x00004170 movs r3, 0 | r3 = 0;
0x00004172 ldr r2, [sp, 0x20] | r2 = var_20h;
0x00004174 mov r1, r4 | r1 = r4;
0x00004176 blx 0x24f8 | fcn_000024f8 ();
0x0000417a ldr r3, [sb, -0x60] | r3 = *((sb - 0x60));
0x0000417e and r3, r3, 0xf000 | r3 &= 0xf000;
0x00004182 cmp.w r3, 0x4000 |
| if (r3 == 0x4000) {
0x00004186 beq 0x4192 | goto label_48;
| }
0x00004188 ldr r0, [sp, 0x18] | r0 = s1;
0x0000418a mov r2, r4 | r2 = r4;
0x0000418c mov r1, r5 | r1 = r5;
0x0000418e bl 0x3c20 | fcn_00003c20 (r0, r1, r2);
| }
| label_48:
0x00004192 mov r0, r8 | r0 = r8;
0x00004194 blx 0x2554 | r0 = fcn_00002554 ();
0x00004198 mov sl, r0 | sl = r0;
0x0000419a cmp r0, 0 |
0x0000419c bne 0x4138 |
| } while (r0 != 0);
0x0000419e str.w sb, [sp, 0x24] | __asm ("str.w sb, [var_24h]");
| label_47:
0x000041a2 mov r0, r8 | r0 = r8;
0x000041a4 blx 0x242c | fcn_0000242c ();
0x000041a8 b 0x3f16 | goto label_3;
| label_31:
0x000041aa vmov.i32 d16, 0 | __asm ("vmov.i32 d16, 0");
0x000041ae vstr d16, [sp, 0x10] | __asm ("vstr d16, [sp, 0x10]");
0x000041b2 b 0x3f16 | goto label_3;
| label_45:
0x000041b4 mov r0, fp | r0 = fp;
0x000041b6 ldrd r7, r5, [sp, 0x1c] | __asm ("ldrd r7, r5, [var_1ch]");
0x000041ba ldr.w sb, [sp, 0x24] | sb = var_24h;
0x000041be blx 0x21d4 | fcn_000021d4 ();
0x000041c2 b 0x3f9e | goto label_4;
| label_37:
0x000041c4 ldr.w r2, [pc, 0x720] |
0x000041c8 mov.w r3, 0x1000 | r3 = 0x1000;
0x000041cc sub.w r4, sb, 4 | r4 = sb - 4;
0x000041d0 str r0, [sp, 4] | var_4h = r0;
0x000041d2 mov r1, r3 | r1 = r3;
0x000041d4 mov r0, r4 | r0 = r4;
0x000041d6 add r2, pc | r2 = 0x8ac2;
0x000041d8 str r2, [sp] | *(sp) = r2;
0x000041da adds r2, r5, 5 | r2 = r5 + 5;
0x000041dc str r2, [sp, 8] | var_8h = r2;
0x000041de movs r2, 1 | r2 = 1;
0x000041e0 blx 0x23d8 | r0 = fcn_000023d8 ();
0x000041e4 cmp.w r0, 0x1000 |
0x000041e8 it lt |
| if (r0 < 0x1000) {
0x000041ea movlt r0, r4 | r0 = r4;
| goto label_49;
| }
| if (r0 < 0x1000) {
| label_49:
0x000041ec blt.w 0x3fc2 | goto label_5;
| }
0x000041f0 b 0x3f9e | goto label_4;
| label_40:
0x000041f2 mov r2, sl | r2 = sl;
0x000041f4 mov r1, sb | r1 = sb;
0x000041f6 blx 0x24c8 | r0 = fcn_000024c8 ();
0x000041fa mov r5, r0 | r5 = r0;
0x000041fc bl 0xaac4 | r0 = fcn_0000aac4 (r0);
0x00004200 cmp r0, 0 |
| if (r0 < 0) {
0x00004202 blt.w 0x4056 | goto label_1;
| }
0x00004204 add r7, sp, 0xa0 | r7 = sp + 0xa0;
0x00004206 mov r0, r5 | r0 = r5;
0x00004208 blx 0x2468 | r0 = fcn_00002468 ();
0x0000420c mov r1, r0 | r1 = r0;
0x0000420e mov r5, r0 | r5 = r0;
| if (r0 != 0) {
0x00004210 cbz r0, 0x421e |
0x00004212 ldr r4, [sp, 0x28] | r4 = var_28h;
0x00004214 ldr r0, [r4, 8] | r0 = *((r4 + 8));
0x00004216 bl 0x3944 | r0 = fcn_00003944 (r0, r1);
| if (r0 == 0) {
0x0000421a cbz r0, 0x4220 | goto label_50;
| }
0x0000421c str r0, [r4, 8] | *((r4 + 8)) = r0;
| }
0x0000421e movs r5, 0 | r5 = 0;
| label_50:
0x00004220 mov r0, r5 | r0 = r5;
0x00004222 blx 0x22bc | read (r0, r1, r2);
0x00004226 b 0x4056 | goto label_1;
| label_41:
0x00004228 mov r2, sl | r2 = sl;
0x0000422a mov r1, sb | r1 = sb;
0x0000422c blx 0x24c8 | fcn_000024c8 ();
0x00004230 ldr.w r1, [pc, 0x6b8] |
0x00004234 mov r5, r0 | r5 = r0;
0x00004236 mov r2, sl | r2 = sl;
0x00004238 mov r0, r6 | r0 = r6;
0x0000423a add r1, pc | r1 = 0x8b2a;
0x0000423c blx 0x24c8 | r0 = fcn_000024c8 ();
0x00004240 mov r6, r0 | r6 = r0;
0x00004242 mov r0, r5 | r0 = r5;
0x00004244 bl 0xaac4 | fcn_0000aac4 (r0);
0x00004248 clz r3, r6 | r3 &= r6;
0x0000424c lsrs r3, r3, 5 | r3 >>= 5;
0x0000424e orrs.w r3, r3, r0, lsr 31 | r3 |= (r0 >> 31);
| if (r3 != r3) {
0x00004252 bne.w 0x4056 | goto label_1;
| }
0x00004256 ldr r0, [sp, 0x28] | r0 = var_28h;
0x00004258 mov r2, r6 | r2 = r6;
0x0000425a mov r1, r5 | r1 = r5;
0x0000425c bl 0x3d14 | fcn_00003d14 (r0, r1, r2);
0x00004260 b 0x4056 | goto label_1;
| label_42:
0x00004262 mov r2, sl | r2 = sl;
0x00004264 mov r1, sb | r1 = sb;
0x00004266 blx 0x24c8 | fcn_000024c8 ();
0x0000426a ldr.w r1, [pc, 0x684] |
0x0000426c asrs r4, r0, 0x1a | r4 = r0 >> 0x1a;
0x0000426e mov r5, r0 | r5 = r0;
0x00004270 mov r2, sl | r2 = sl;
0x00004272 mov r0, r6 | r0 = r6;
0x00004274 add r1, pc | r1 = 0x8b6a;
0x00004276 blx 0x24c8 | r0 = fcn_000024c8 ();
0x0000427a mov r6, r0 | r6 = r0;
0x0000427c mov r0, r5 | r0 = r5;
0x0000427e bl 0xaac4 | fcn_0000aac4 (r0);
0x00004282 clz r3, r6 | r3 &= r6;
0x00004286 lsrs r3, r3, 5 | r3 >>= 5;
0x00004288 orrs.w r3, r3, r0, lsr 31 | r3 |= (r0 >> 31);
| if (r3 != r3) {
0x0000428c bne.w 0x4056 | goto label_1;
| }
0x00004290 ldr r3, [sp, 0x28] | r3 = var_28h;
0x00004292 mov r1, r6 | r1 = r6;
0x00004294 mov r0, r5 | r0 = r5;
0x00004296 add.w r2, r3, 0x14 | r2 = r3 + 0x14;
0x0000429a bl 0x3bbc | fcn_00003bbc (r0, r1, r2);
0x0000429e b 0x4056 | goto label_1;
| label_36:
0x000042a0 ldr.w r0, [pc, 0x650] |
0x000042a4 mov.w r1, 0x80000 | r1 = 0x80000;
0x000042a8 add r0, pc | r0 = 0x8ba0;
0x000042aa blx 0x23b0 | r0 = fcn_000023b0 ();
0x000042ae subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 < r0) {
0x000042b0 blt 0x433a | goto label_12;
| }
0x000042b2 ldr r3, [sp, 0x2c] | r3 = var_2ch;
0x000042b4 mov.w r2, 0x1000 | r2 = 0x1000;
0x000042b8 sub.w r8, r3, 4 | r8 = r3 - 4;
0x000042bc mov r1, r8 | r1 = r8;
0x000042be bl 0xab88 | r0 = fcn_0000ab88 (r0, r1, r2);
0x000042c2 mov r5, r0 | r5 = r0;
0x000042c4 mov r0, r4 | r0 = r4;
0x000042c6 blx 0x2408 | fcn_00002408 ();
0x000042ca cmp r5, 0 |
| if (r5 < 0) {
0x000042cc blt.w 0x4852 | goto label_51;
| }
0x000042d0 ldr.w r6, [pc, 0x624] |
0x000042d4 movs r5, 0 | r5 = 0;
0x000042d6 ldr.w fp, [pc, 0x624] |
0x000042da mov r2, r8 | r2 = r8;
0x000042dc mov sb, r8 | sb = r8;
0x000042de mov r0, r5 | r0 = r5;
0x000042e0 add r6, pc | r6 = 0x8bdc;
0x000042e2 movs r1, 1 | r1 = 1;
0x000042e4 add fp, pc | fp = 0x8be6;
0x000042e6 mov r4, r5 | r4 = r5;
0x000042e8 mov r8, r5 | r8 = r5;
| label_7:
0x000042ea ldrb r3, [r2] | r3 = *(r2);
0x000042ec cmp r3, 0x2e |
| if (r3 > 0x2e) {
0x000042ee bhi 0x436e | goto label_52;
| }
| do {
0x000042f0 cmp r3, 0x2e |
| if (r3 <= 0x2e) {
0x000042f2 bhi 0x4366 |
| /* switch table (47 cases) at 0x42f8 */
0x000042f4 tbb [pc, r3] | __asm ("tbb [0x000042fc]");
0x00004328 cmp r1, 3 |
0x0000432a ite ne |
| if (r1 == 3) {
0x0000432c movne r3, 0 | r3 = 0;
| }
| if (r1 != 3) {
0x0000432e andeq r3, r4, 1 | r3 = r4 & 1;
| }
| if (r3 == 0) {
0x00004332 cbnz r3, 0x433a |
0x00004334 cmp r4, 0 |
| if (r4 == 0) {
0x00004336 beq.w 0x4640 | goto label_53;
| }
| }
| label_12:
0x0000433a movs r0, 0 | r0 = 0;
| label_8:
0x0000433c ldr.w r2, [pc, 0x5c0] |
0x00004340 add.w r1, sp, 0x1120 | r1 += var_1120h;
0x00004344 ldr.w r3, [pc, 0x570] | r3 = *(0x48b8);
0x00004348 adds r1, 0x1c | r1 += 0x1c;
0x0000434a add r2, pc | r2 = 0x8c4e;
0x0000434c ldr r3, [r2, r3] | r3 = *(0x8c4e);
0x0000434e ldr r2, [r3] | r2 = *(0x8c4e);
0x00004350 ldr r3, [r1] | r3 = *(r1);
0x00004352 eors r2, r3 | r2 ^= r3;
0x00004354 mov.w r3, 0 | r3 = 0;
| if (r2 != r3) {
0x00004358 bne.w 0x48a6 | goto label_54;
| }
0x0000435c add.w sp, sp, 0x1140 |
0x00004360 add sp, 4 |
0x00004362 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
| label_6:
0x00004366 ldrb r3, [r2, 1] | r3 = *((r2 + 1));
0x00004368 adds r2, 1 | r2++;
0x0000436a cmp r3, 0x2e |
0x0000436c bls 0x42f0 |
| } while (r3 < 0x2e);
| label_52:
0x0000436e cmp r3, 0x3d |
| if (r3 != 0x3d) {
0x00004370 bne 0x4366 | goto label_6;
| }
0x00004372 cmp r1, 2 |
0x00004374 add.w r3, r2, 1 | r3 = r2 + 1;
| if (r1 == 2) {
0x00004378 beq.w 0x47e2 | goto label_55;
| }
0x0000437c cmp r1, 1 |
| if (r1 == 1) {
0x0000437e beq 0x43aa | goto label_56;
| }
| do {
0x00004380 mov r2, r3 | r2 = r3;
0x00004382 b 0x42ea | goto label_7;
0x00004384 cmp r1, 3 |
0x00004386 ite ne |
| if (r1 == 3) {
0x00004388 movne r3, 0 | r3 = 0;
| }
| if (r1 != 3) {
0x0000438a andeq r3, r4, 1 | r3 = r4 & 1;
| }
0x0000438e cmp r3, 0 |
| if (r3 == 0) {
0x00004390 beq.w 0x461c | goto label_57;
| }
0x00004394 adds r2, 1 | r2++;
0x00004396 mov r4, r3 | r4 = r3;
0x00004398 movs r1, 3 | r1 = 3;
0x0000439a b 0x42ea | goto label_7;
0x0000439c cmp r1, 1 |
0x0000439e add.w r3, r2, 1 | r3 = r2 + 1;
| if (r1 == 1) {
0x000043a2 beq.w 0x47ea | goto label_58;
| }
0x000043a6 cmp r1, 2 |
0x000043a8 bne 0x4380 |
| } while (r1 != 2);
| label_56:
0x000043aa mov r2, r3 | r2 = r3;
0x000043ac movs r1, 0 | r1 = 0;
0x000043ae b 0x42ea | goto label_7;
0x000043b0 eor r4, r4, 1 | r4 ^= 1;
0x000043b4 adds r7, r2, 1 | r7 = r2 + 1;
0x000043b6 cmp r1, 1 |
0x000043b8 ite ne |
| if (r1 == 1) {
0x000043ba movne r3, 0 | r3 = 0;
| }
| if (r1 != 1) {
0x000043bc andeq r3, r4, 1 | r3 = r4 & 1;
| }
0x000043c0 cmp r3, 0 |
| if (r3 == 0) {
0x000043c2 beq.w 0x4610 | goto label_59;
| }
0x000043c6 cmp r2, sb |
| if (r2 == sb) {
0x000043c8 beq.w 0x46d2 | goto label_60;
| }
0x000043cc mov r4, r3 | r4 = r3;
| label_11:
0x000043ce mov r2, r7 | r2 = r7;
0x000043d0 movs r1, 0 | r1 = 0;
0x000043d2 b 0x42ea | goto label_7;
| label_43:
0x000043d4 mov r2, sl | r2 = sl;
0x000043d6 mov r1, sb | r1 = sb;
0x000043d8 blx 0x24c8 | fcn_000024c8 ();
0x000043dc ldr.w r1, [pc, 0x524] |
0x000043e0 mov r5, r0 | r5 = r0;
0x000043e2 mov r2, sl | r2 = sl;
0x000043e4 mov r0, r6 | r0 = r6;
0x000043e6 add r1, pc | r1 = 0x8cee;
0x000043e8 blx 0x24c8 | r0 = fcn_000024c8 ();
0x000043ec mov r6, r0 | r6 = r0;
0x000043ee mov r0, r5 | r0 = r5;
0x000043f0 bl 0xaac4 | fcn_0000aac4 (r0);
0x000043f4 clz r3, r6 | r3 &= r6;
0x000043f8 lsrs r3, r3, 5 | r3 >>= 5;
0x000043fa orrs.w r3, r3, r0, lsr 31 | r3 |= (r0 >> 31);
| if (r3 != r3) {
0x000043fe bne.w 0x4056 | goto label_1;
| }
0x00004402 ldr r3, [sp, 0x28] | r3 = var_28h;
0x00004404 mov r1, r6 | r1 = r6;
0x00004406 mov r0, r5 | r0 = r5;
0x00004408 add.w r2, r3, 0x10 | r2 = r3 + 0x10;
0x0000440c bl 0x3bbc | fcn_00003bbc (r0, r1, r2);
0x00004410 b 0x4056 | goto label_1;
| label_35:
0x00004412 mov r0, r4 | r0 = r4;
0x00004414 blx 0x22bc | read (r0, r1, r2);
0x00004416 invalid |
| label_34:
0x00004418 ldr r3, [sp, 0x2c] | r3 = var_2ch;
0x0000441a ldr r5, [sp, 0x2c] | r5 = var_2ch;
0x0000441c ldr r4, [r3, -0xdc] | r4 = *((r3 - 0xdc));
| if (r4 == 0) {
0x00004420 cbz r4, 0x4438 | goto label_61;
| }
| do {
0x00004422 ldr r0, [r4, 8] | r0 = *((r4 + 8));
0x00004424 blx 0x22bc | read (r0, r1, r2);
0x00004428 mov r0, r4 | r0 = r4;
0x0000442a bl 0x39e8 | r0 = fcn_000039e8 (r0);
0x0000442e mov r4, r0 | r4 = r0;
0x00004430 str r0, [r5, -0xdc] | *((r5 - 0xdc)) = r0;
0x00004434 cmp r0, 0 |
0x00004436 bne 0x4422 |
| } while (r0 != 0);
| label_61:
0x00004438 mov r4, fp | r4 = fp;
0x0000443a cmp.w fp, 0 |
| if (fp == 0) {
0x0000443e beq 0x4452 | goto label_62;
| }
| do {
0x00004440 ldr r0, [r4, 8] | r0 = *((r4 + 8));
0x00004442 blx 0x22bc | read (r0, r1, r2);
0x00004446 mov r0, r4 | r0 = r4;
0x00004448 bl 0x39e8 | r0 = fcn_000039e8 (r0);
0x0000444c mov r4, r0 | r4 = r0;
0x0000444e cmp r0, 0 |
0x00004450 bne 0x4440 |
| } while (r0 != 0);
| label_62:
0x00004452 mvn r0, 0xb | r0 = ~0xb;
0x00004456 b 0x433c | goto label_8;
| label_44:
0x00004458 mov r2, sl | r2 = sl;
0x0000445a mov r1, sb | r1 = sb;
0x0000445c blx 0x24c8 | fcn_000024c8 ();
0x00004460 ldr.w r1, [pc, 0x4a4] |
0x00004464 mov r3, r0 | r3 = r0;
0x00004466 mov r2, sl | r2 = sl;
0x00004468 mov r0, r5 | r0 = r5;
0x0000446a mov r5, r3 | r5 = r3;
0x0000446c str r3, [sp, 0x4c] | s2 = r3;
0x0000446e add r1, pc | r1 = 0x8d7a;
0x00004470 blx 0x24c8 | r0 = fcn_000024c8 ();
0x00004474 mov r4, r0 | r4 = r0;
0x00004476 str r0, [sp, 0x18] | s1 = r0;
0x00004478 mov r0, r5 | r0 = r5;
0x0000447a bl 0xaac4 | fcn_0000aac4 (r0);
0x0000447e clz r3, r4 | r3 &= r4;
0x00004482 lsrs r3, r3, 5 | r3 >>= 5;
0x00004484 orrs.w r3, r3, r0, lsr 31 | r3 |= (r0 >> 31);
| if (r3 != r3) {
0x00004488 bne.w 0x4056 | goto label_1;
| }
0x0000448c mov r0, r5 | r0 = r5;
0x0000448e mov r7, r4 | r7 = r4;
0x00004490 blx 0x2340 | fcn_00002340 ();
0x00004494 ldr.w r3, [pc, 0x474] |
0x00004498 mov r5, r4 | r5 = r4;
0x0000449a movs r2, 0 | r2 = 0;
0x0000449c str r0, [sp, 0x58] | var_58h = r0;
0x0000449e str r2, [sp, 0x38] | var_38h = r2;
0x000044a0 add r3, pc | r3 = 0x8db0;
0x000044a2 strd r2, r2, [sp, 0x3c] | __asm ("strd r2, r2, [var_3ch]");
0x000044a6 str r3, [sp, 0x54] | var_54h = r3;
0x000044a8 mov r3, r0 | r3 = r0;
0x000044aa adds r3, 1 | r3++;
0x000044ac strd r2, r2, [sp, 0x44] | __asm ("strd r2, r2, [var_44h]");
0x000044b0 str r3, [sp, 0x5c] | var_5ch = r3;
0x000044b2 str r4, [sp, 0x50] | var_50h = r4;
| label_20:
0x000044b4 mov r4, r5 | r4 = r5;
0x000044b6 ldrb r6, [r5], 1 | r6 = *(r5);
| r5++;
| if (r6 == 0) {
0x000044ba cbz r6, 0x451e | goto label_63;
| }
| do {
0x000044bc blx 0x2450 | r0 = fcn_00002450 ();
0x000044c0 ldr r2, [r0] | r2 = *(r0);
0x000044c2 ldrh.w r2, [r2, r6, lsl 1] | offset_0 = r6 << 1;
| r2 = *((r2 + offset_0));
0x000044c6 ands r2, r2, 0x2000 | r2 &= 0x2000;
| if (r2 == r2) {
0x000044ca beq.w 0x4758 | goto label_64;
| }
0x000044cc strh r5, [r0, 0xa] | *((r0 + 0xa)) = r5;
0x000044ce ldr r3, [sp, 0x38] | r3 = var_38h;
0x000044d0 cmp r3, 0 |
| if (r3 != 0) {
0x000044d2 bne.w 0x47c0 | goto label_65;
| }
0x000044d6 cmp r4, r7 |
| if (r4 < r7) {
0x000044d8 bls.w 0x47dc | goto label_66;
| }
0x000044dc subs r4, r4, r7 | r4 -= r7;
0x000044de cmp r4, 4 |
| if (r4 == 4) {
0x000044e0 beq.w 0x4836 | goto label_67;
| }
0x000044e4 cmp r4, 5 |
| if (r4 == 5) {
0x000044e6 beq.w 0x47c4 | goto label_68;
| }
| label_24:
0x000044ea movs r3, 1 | r3 = 1;
0x000044ec str r3, [sp, 0x38] | var_38h = r3;
| label_9:
0x000044ee ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x000044f0 cmp r3, 1 |
| if (r3 == 1) {
0x000044f2 beq.w 0x4780 | goto label_69;
| }
0x000044f6 ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x000044f8 cmp r3, 2 |
0x000044fa itt ne |
| if (r3 == 2) {
0x000044fc movne r3, 0 | r3 = 0;
| }
| if (r3 == 2) {
0x000044fe strne r3, [sp, 0x3c] | var_3ch = r3;
| }
| if (r3 == 2) {
0x00004500 bne 0x4510 |
0x00004502 ldr r3, [sp, 0x40] | r3 = var_40h;
0x00004504 adds r3, 1 | r3++;
0x00004506 add r3, r4 | r3 += r4;
0x00004508 str r3, [sp, 0x40] | var_40h = r3;
0x0000450a ldr r3, [sp, 0x48] | r3 = var_48h;
0x0000450c adds r3, 1 | r3++;
0x0000450e str r3, [sp, 0x48] | var_48h = r3;
| }
| label_22:
0x00004510 mov r7, r5 | r7 = r5;
| if (r6 == 0) {
0x00004512 cbz r6, 0x4532 | goto label_18;
| }
0x00004514 mov r4, r5 | r4 = r5;
0x00004516 ldrb r6, [r5], 1 | r6 = *(r5);
| r5++;
0x0000451a cmp r6, 0 |
0x0000451c bne 0x44bc |
| } while (r6 != 0);
| label_63:
0x0000451e subs r4, r4, r7 | r4 -= r7;
0x00004520 cmp r4, 4 |
| if (r4 == 4) {
0x00004522 beq.w 0x472e | goto label_70;
| }
0x00004526 cmp r4, 5 |
| if (r4 == 5) {
0x00004528 beq.w 0x4790 | goto label_71;
| }
| label_17:
0x0000452c ldr r3, [sp, 0x38] | r3 = var_38h;
0x0000452e cmp r3, 0 |
| if (r3 == 0) {
0x00004530 beq 0x44ee | goto label_9;
| }
| label_18:
0x00004532 ldr r0, [sp, 0x58] | r0 = var_58h;
0x00004534 ldr r3, [sp, 0x40] | r3 = var_40h;
0x00004536 ldr r4, [sp, 0x44] | r4 = var_44h;
0x00004538 adds r0, 0x15 | r0 += 0x15;
0x0000453a ldr r7, [sp, 0x50] | r7 = var_50h;
0x0000453c add r0, r3 | r0 += r3;
0x0000453e ldr r3, [sp, 0x48] | r3 = var_48h;
0x00004540 lsls r5, r4, 2 | r5 = r4 << 2;
0x00004542 lsls r6, r3, 2 | r6 = r3 << 2;
0x00004544 add r0, r5 | r0 += r5;
0x00004546 add r0, r6 | r0 += r6;
0x00004548 blx 0x2480 | r0 = fcn_00002480 ();
0x0000454c mov r2, r0 | r2 = r0;
0x0000454e str r0, [sp, 0x40] | var_40h = r0;
0x00004550 cmp r0, 0 |
| if (r0 == 0) {
0x00004552 beq.w 0x4056 | goto label_1;
| }
0x00004556 ldr r3, [sp, 0x48] | r3 = var_48h;
0x00004558 str r4, [r0, 0xc] | *((r0 + 0xc)) = r4;
0x0000455a mov r4, r0 | r4 = r0;
0x0000455c ldr r1, [sp, 0x4c] | r1 = s2;
0x0000455e str r3, [r0, 0x10] | *((r0 + 0x10)) = r3;
0x00004560 add.w r3, r0, 0x14 | r3 = r0 + 0x14;
0x00004564 add r5, r3 | r5 += r3;
0x00004566 str r3, [r0, 4] | *((r0 + 4)) = r3;
0x00004568 adds r0, r5, r6 | r0 = r5 + r6;
0x0000456a str r5, [r2, 8] | *((r2 + 8)) = r5;
0x0000456c ldr r5, [sp, 0x5c] | r5 = var_5ch;
0x0000456e movs r6, 0 | r6 = 0;
0x00004570 str r0, [r2] | *(r2) = r0;
0x00004572 mov r2, r5 | r2 = r5;
0x00004574 blx 0x2368 | fcn_00002368 ();
0x00004578 ldr r3, [r4] | r3 = *(r4);
0x0000457a mov r2, r5 | r2 = r5;
0x0000457c mov r4, r6 | r4 = r6;
0x0000457e lsls r5, r1, 3 | r5 = r1 << 3;
0x00004580 movs r0, r0 |
0x00004582 str r2, [sp] | *(sp) = r2;
0x00004584 add r3, pc | r3 += pc;
0x00004586 invalid |
0x0000458a str r3, [sp, 0x3fc] | *((sp + 0x3fc)) = r3;
| label_19:
0x0000458c mov r2, r7 | r2 = r7;
0x0000458e str r2, [sp, 0x5c] | *((sp + 0x5c)) = r2;
0x00004590 add r3, pc | r3 += pc;
0x00004592 movs r3, r2 | r3 = r2;
| do {
0x00004594 movs r0, r0 |
0x00004596 movs r0, r0 |
0x00004598 movs r0, r0 |
0x0000459a ldr r0, [r0] | r0 = *(r0);
0x0000459c ldrh.w r1, [r1, r5, lsl 1] | offset_1 = r5 << 1;
| r1 = *((r1 + offset_1));
0x000045a0 ands r1, r1, 0x2000 | r1 &= 0x2000;
| if (r1 == r1) {
0x000045a4 beq.w 0x4754 | goto label_72;
| }
0x000045a8 ldr r2, [sp, 0x38] | r2 = var_38h;
0x000045aa cmp r6, 0 |
| if (r6 != 0) {
0x000045ac bne.w 0x47bc | goto label_73;
| }
0x000045b0 ldr r3, [sp, 0x18] | r3 = s1;
0x000045b2 cmp r2, r3 |
| if (r2 < r3) {
0x000045b4 bls.w 0x47b8 | goto label_74;
| }
0x000045b8 subs r6, r2, r3 | r6 = r2 - r3;
0x000045ba cmp r6, 4 |
| if (r6 == 4) {
0x000045bc beq.w 0x4844 | goto label_75;
| }
0x000045c0 cmp r6, 5 |
| if (r6 == 5) {
0x000045c2 beq.w 0x47a2 | goto label_76;
| }
| label_23:
0x000045c6 mov r2, r6 | r2 = r6;
0x000045c8 movs r6, 1 | r6 = 1;
| label_10:
0x000045ca cmp r4, 1 |
| if (r4 == 1) {
0x000045cc beq.w 0x47f6 | goto label_77;
| }
0x000045d0 cmp r4, 2 |
0x000045d2 it ne |
| if (r4 == 2) {
0x000045d4 movne r4, 0 | r4 = 0;
| }
| if (r4 == 2) {
0x000045d6 beq.w 0x4822 | goto label_78;
| }
| label_25:
0x000045da str r7, [sp, 0x18] | s1 = r7;
| if (r5 == 0) {
0x000045dc cbz r5, 0x45fa | goto label_16;
| }
0x000045de mov r2, r7 | r2 = r7;
0x000045e0 ldrb r5, [r7], 1 | r5 = *(r7);
| r7++;
0x000045e4 cmp r5, 0 |
0x000045e6 bne 0x4594 |
| } while (r5 != 0);
0x000045e8 ldr r3, [sp, 0x18] | r3 = s1;
0x000045ea subs r2, r2, r3 | r2 -= r3;
0x000045ec cmp r2, 4 |
| if (r2 == 4) {
0x000045ee beq.w 0x4706 | goto label_79;
| }
0x000045f2 cmp r2, 5 |
| if (r2 == 5) {
0x000045f4 beq 0x46de | goto label_80;
| }
| label_15:
0x000045f6 cmp r6, 0 |
| if (r6 == 0) {
0x000045f8 beq 0x45ca | goto label_10;
| }
| label_16:
0x000045fa ldr r3, [sp, 0x28] | r3 = var_28h;
0x000045fc ldr r1, [sp, 0x40] | r1 = var_40h;
0x000045fe ldr r0, [r3, 0x18] | r0 = *((r3 + 0x18));
0x00004600 bl 0x3944 | r0 = fcn_00003944 (r0, r1);
0x00004604 cmp r0, 0 |
| if (r0 == 0) {
0x00004606 beq.w 0x489c | goto label_81;
| }
0x0000460a ldr r3, [sp, 0x28] | r3 = var_28h;
0x0000460c str r0, [r3, 0x18] | *((r3 + 0x18)) = r0;
0x0000460e b 0x4056 | goto label_1;
| label_59:
0x00004610 cmp r1, 3 |
0x00004612 it eq |
| if (r1 == 3) {
0x00004614 moveq r2, r7 | r2 = r7;
| goto label_82;
| }
| if (r1 == 3) {
| label_82:
0x00004616 beq.w 0x42ea | goto label_7;
| }
0x0000461a b 0x43ce | goto label_11;
| label_57:
0x0000461c adds r7, r2, 1 | r7 = r2 + 1;
| if (r4 != 0) {
0x0000461e cbz r4, 0x4626 |
0x00004620 mov r2, r7 | r2 = r7;
0x00004622 mov r1, r3 | r1 = r3;
0x00004624 b 0x42ea | goto label_7;
| }
0x00004626 movs r4, 1 | r4 = 1;
| label_13:
0x00004628 subs r1, 2 | r1 -= 2;
0x0000462a cmp r1, 1 |
| if (r1 < 1) {
0x0000462c bls 0x4644 | goto label_83;
| }
| label_14:
0x0000462e cmp r4, 0 |
| if (r4 == 0) {
0x00004630 beq.w 0x433a | goto label_12;
| }
0x00004634 movs r4, 0 | r4 = 0;
0x00004636 mov sb, r7 | sb = r7;
0x00004638 mov r2, r7 | r2 = r7;
0x0000463a movs r1, 1 | r1 = 1;
0x0000463c mov r0, r4 | r0 = r4;
0x0000463e b 0x42ea | goto label_7;
| label_53:
0x00004640 adds r7, r2, 1 | r7 = r2 + 1;
0x00004642 b 0x4628 | goto label_13;
| label_83:
0x00004644 cmp r0, 0 |
0x00004646 it ne |
| if (r0 != 0) {
0x00004648 cmpne sb, r0 | __asm ("cmpne sb, r0");
| }
0x0000464a mov.w r3, 0 | r3 = 0;
0x0000464e strb r3, [r2] | *(r2) = r3;
| if (r0 > 0) {
0x00004650 bhi.w 0x475c | goto label_84;
| }
0x00004654 ldr r3, [sp, 0x2c] | r3 = var_2ch;
0x00004656 cmp.w r8, 0 |
0x0000465a it ne |
| if (r8 != 0) {
0x0000465c cmpne sb, 0 | __asm ("cmpne sb, 0");
| }
0x00004660 str r5, [r3, -0x70] | *((r3 - 0x70)) = r5;
| if (r8 == 0) {
0x00004664 beq 0x462e | goto label_14;
| }
| label_21:
0x00004666 mov r1, r6 | r1 = r6;
0x00004668 mov r0, sb | r0 = sb;
0x0000466a blx 0x25d8 | r0 = fcn_000025d8 ();
0x0000466e cmp r0, 0 |
| if (r0 != 0) {
0x00004670 bne 0x46f0 | goto label_85;
| }
0x00004672 movs r2, 0xa | r2 = 0xa;
0x00004674 mov r1, fp | r1 = fp;
0x00004676 mov r0, r8 | r0 = r8;
0x00004678 blx 0x2584 | r0 = fcn_00002584 ();
0x0000467c cmp r0, 0 |
| if (r0 != 0) {
0x0000467e bne 0x46f0 | goto label_85;
| }
0x00004680 ldr.w sl, [pc, 0x290] |
0x00004684 add.w sb, sp, 0xd0 | sb += var_d0h;
0x00004688 mov r0, sb | r0 = sb;
0x0000468a str.w r8, [sp, 0x10] | __asm ("str.w r8, [fildes]");
0x0000468e str r4, [sp, 0x18] | s1 = r4;
0x00004690 add sl, pc | sl = 0x8fa8;
0x00004692 ldr.w r8, [sp, 0x28] | r8 = var_28h;
0x00004696 mov r1, sl | r1 = sl;
0x00004698 blx 0x21ac | r0 = fcn_000021ac ();
| if (r0 == 0) {
0x0000469c cbz r0, 0x46ca | goto label_86;
| }
| do {
0x0000469e blx 0x2468 | r0 = fcn_00002468 ();
0x000046a2 mov r1, r0 | r1 = r0;
0x000046a4 mov r4, r0 | r4 = r0;
| if (r0 != 0) {
0x000046a6 cbz r0, 0x46b6 |
0x000046a8 ldr.w r0, [r8, 8] | r0 = *((r8 + 8));
0x000046ac bl 0x3944 | r0 = fcn_00003944 (r0, r1);
| if (r0 == 0) {
0x000046b0 cbz r0, 0x46b8 | goto label_87;
| }
0x000046b2 str.w r0, [r8, 8] | __asm ("str.w r0, [r8, 8]");
| }
0x000046b6 movs r4, 0 | r4 = 0;
| label_87:
0x000046b8 mov r0, r4 | r0 = r4;
0x000046ba blx 0x22bc | read (r0, r1, r2);
0x000046be mov r1, sl | r1 = sl;
0x000046c0 mov r0, sb | r0 = sb;
0x000046c2 blx 0x21ac | r0 = fcn_000021ac ();
0x000046c6 cmp r0, 0 |
0x000046c8 bne 0x469e |
| } while (r0 != 0);
| label_86:
0x000046ca ldr.w r8, [sp, 0x10] | r8 = fildes;
0x000046ce ldr r4, [sp, 0x18] | r4 = s1;
0x000046d0 b 0x462e | goto label_14;
| label_60:
0x000046d2 mov r0, r2 | r0 = r2;
0x000046d4 mov r4, r3 | r4 = r3;
0x000046d6 mov r2, r7 | r2 = r7;
0x000046d8 mov sb, r7 | sb = r7;
0x000046da movs r1, 1 | r1 = 1;
0x000046dc b 0x42ea | goto label_7;
| label_80:
0x000046de ldr r1, [sp, 0x4c] | r1 = s2;
0x000046e0 ldr r0, [sp, 0x18] | r0 = s1;
0x000046e2 str r2, [sp, 0x38] | var_38h = r2;
0x000046e4 blx 0x2154 | memcmp (r0, r1, r2);
0x000046e8 ldr r2, [sp, 0x38] | r2 = var_38h;
0x000046ea cmp r0, 0 |
| if (r0 != 0) {
0x000046ec bne 0x45f6 | goto label_15;
| }
0x000046ee b 0x45fa | goto label_16;
| label_85:
0x000046f0 mov r0, sb | r0 = sb;
0x000046f2 bl 0xaac4 | r0 = fcn_0000aac4 (r0);
0x000046f6 cmp r0, 0 |
| if (r0 < 0) {
0x000046f8 blt 0x462e | goto label_14;
| }
0x000046fa ldr r0, [sp, 0x28] | r0 = var_28h;
0x000046fc mov r1, sb | r1 = sb;
0x000046fe mov r2, r8 | r2 = r8;
0x00004700 bl 0x3d14 | fcn_00003d14 (r0, r1, r2);
0x00004704 b 0x462e | goto label_14;
| label_79:
0x00004706 ldr r3, [sp, 0x18] | r3 = s1;
0x00004708 ldrb r1, [r3] | r1 = *(r3);
0x0000470a cmp r1, 0x70 |
| if (r1 != 0x70) {
0x0000470c bne.w 0x45f6 | goto label_15;
| }
0x00004710 ldrb r0, [r3, 1] | r0 = *((r3 + 1));
0x00004712 adds r1, r3, 1 | r1 = r3 + 1;
0x00004714 cmp r0, 0x72 |
| if (r0 != 0x72) {
0x00004716 bne.w 0x45f6 | goto label_15;
| }
0x0000471a ldrb r0, [r1, 1]! | r0 = *((r1 += 1));
0x0000471e cmp r0, 0x65 |
| if (r0 != 0x65) {
0x00004720 bne.w 0x45f6 | goto label_15;
| }
0x00004724 ldrb r1, [r1, 1] | r1 = *((r1 + 1));
0x00004726 cmp r1, 0x3a |
| if (r1 != 0x3a) {
0x00004728 bne.w 0x45f6 | goto label_15;
| }
0x0000472c b 0x45fa | goto label_16;
| label_70:
0x0000472e ldrb r2, [r7] | r2 = *(r7);
0x00004730 cmp r2, 0x70 |
| if (r2 != 0x70) {
0x00004732 bne.w 0x452c | goto label_17;
| }
0x00004736 ldrb r2, [r7, 1] | r2 = *((r7 + 1));
0x00004738 adds r3, r7, 1 | r3 = r7 + 1;
0x0000473a cmp r2, 0x72 |
| if (r2 != 0x72) {
0x0000473c bne.w 0x452c | goto label_17;
| }
0x00004740 ldrb r2, [r3, 1]! | r2 = *((r3 += 1));
0x00004744 cmp r2, 0x65 |
| if (r2 != 0x65) {
0x00004746 bne.w 0x452c | goto label_17;
| }
0x0000474a ldrb r3, [r3, 1] | r3 = *((r3 + 1));
0x0000474c cmp r3, 0x3a |
| if (r3 != 0x3a) {
0x0000474e bne.w 0x452c | goto label_17;
| }
0x00004750 add r6, sp, 0x3b4 | r6 = sp + 0x3b4;
0x00004752 b 0x4532 | goto label_18;
| label_72:
0x00004754 mov r6, r1 | r6 = r1;
0x00004756 b 0x458c | goto label_19;
| label_64:
0x00004758 str r2, [sp, 0x38] | var_38h = r2;
0x0000475a b 0x44b4 | goto label_20;
| label_84:
0x0000475c sub.w r2, r5, sb | r2 = r5 - sb;
0x00004760 mov r1, sb | r1 = sb;
0x00004762 blx 0x2514 | munmap (r0, r1);
0x00004766 ldr r2, [sp, 0x2c] | r2 = var_2ch;
0x00004768 subs r3, r5, 1 | r3 = r5 - 1;
0x0000476a add.w r8, r8, -1 | r8 += -1;
0x0000476e add.w sb, sb, -1 | sb += -1;
0x00004772 str r3, [r2, -0x70] | *((r2 - 0x70)) = r3;
0x00004776 movs r2, 0x22 | r2 = 0x22;
0x00004778 strb r2, [r5, -0x1] | *((r5 - 0x1)) = r2;
0x0000477c mov r5, r3 | r5 = r3;
0x0000477e b 0x4666 | goto label_21;
| label_69:
0x00004780 ldr r3, [sp, 0x40] | r3 = var_40h;
0x00004782 adds r3, 1 | r3++;
0x00004784 add r3, r4 | r3 += r4;
0x00004786 str r3, [sp, 0x40] | var_40h = r3;
0x00004788 ldr r3, [sp, 0x44] | r3 = var_44h;
0x0000478a adds r3, 1 | r3++;
0x0000478c str r3, [sp, 0x44] | var_44h = r3;
0x0000478e b 0x4510 | goto label_22;
| label_71:
0x00004790 ldr r1, [sp, 0x54] | r1 = var_54h;
0x00004792 mov r0, r7 | r0 = r7;
0x00004794 mov r2, r4 | r2 = r4;
0x00004796 blx 0x2154 | r0 = memcmp (r0, r1, r2);
0x0000479a cmp r0, 0 |
| if (r0 != 0) {
0x0000479c bne.w 0x452c | goto label_17;
| }
0x000047a0 b 0x4532 | goto label_18;
| label_76:
0x000047a2 ldr r1, [pc, 0x174] |
0x000047a4 mov r2, r6 | r2 = r6;
0x000047a6 ldr r0, [sp, 0x18] | r0 = s1;
0x000047a8 add r1, pc | r1 = 0x90c6;
0x000047aa blx 0x2154 | r0 = memcmp (r0, r1, r2);
0x000047ae cmp r0, 0 |
| if (r0 != 0) {
0x000047b0 bne.w 0x45c6 | goto label_23;
| }
0x000047b4 movs r4, 2 | r4 = 2;
| label_28:
0x000047b6 str r7, [sp, 0x18] | s1 = r7;
| label_74:
0x000047b8 movs r6, 1 | r6 = 1;
0x000047ba b 0x458c | goto label_19;
| label_73:
0x000047bc str r7, [sp, 0x18] | s1 = r7;
0x000047be b 0x458c | goto label_19;
| label_65:
0x000047c0 mov r7, r5 | r7 = r5;
0x000047c2 b 0x44b4 | goto label_20;
| label_68:
0x000047c4 ldr r1, [pc, 0x154] |
0x000047c6 mov r0, r7 | r0 = r7;
0x000047c8 mov r2, r4 | r2 = r4;
0x000047ca add r1, pc | r1 = 0x90ea;
0x000047cc blx 0x2154 | r0 = memcmp (r0, r1, r2);
0x000047d0 cmp r0, 0 |
| if (r0 != 0) {
0x000047d2 bne.w 0x44ea | goto label_24;
| }
0x000047d6 mov r7, r5 | r7 = r5;
0x000047d8 movs r3, 2 | r3 = 2;
0x000047da str r3, [sp, 0x3c] | var_3ch = r3;
| label_66:
0x000047dc movs r3, 1 | r3 = 1;
0x000047de str r3, [sp, 0x38] | var_38h = r3;
0x000047e0 b 0x44b4 | goto label_20;
| label_55:
0x000047e2 mov r5, r3 | r5 = r3;
0x000047e4 movs r1, 3 | r1 = 3;
0x000047e6 mov r2, r3 | r2 = r3;
0x000047e8 b 0x42ea | goto label_7;
| label_58:
0x000047ea movs r1, 0 | r1 = 0;
0x000047ec mov r8, r3 | r8 = r3;
0x000047ee strb r1, [r2] | *(r2) = r1;
0x000047f0 mov r2, r3 | r2 = r3;
0x000047f2 movs r1, 2 | r1 = 2;
0x000047f4 b 0x42ea | goto label_7;
| label_77:
0x000047f6 ldr r3, [sp, 0x40] | r3 = var_40h;
0x000047f8 ldr r5, [sp, 0x3c] | r5 = var_3ch;
0x000047fa ldr r1, [sp, 0x18] | r1 = s1;
0x000047fc ldr r0, [r3, 4] | r0 = *((r3 + 4));
0x000047fe ldr r3, [sp, 0x44] | r3 = var_44h;
0x00004800 str.w r5, [r0, r3, lsl 2] | __asm ("str.w r5, [r0, r3, lsl 2]");
0x00004804 adds r3, 1 | r3++;
0x00004806 str r3, [sp, 0x44] | var_44h = r3;
| do {
0x00004808 mov r0, r5 | r0 = r5;
0x0000480a str r2, [sp, 0x18] | s1 = r2;
0x0000480c blx 0x2368 | fcn_00002368 ();
0x00004810 ldr r2, [sp, 0x18] | r2 = s1;
0x00004812 movs r1, 0 | r1 = 0;
0x00004814 strb r1, [r5, r2] | *((r5 + r2)) = r1;
0x00004816 adds r2, 1 | r2++;
0x00004818 adds r3, r5, r2 | r3 = r5 + r2;
0x0000481a str r3, [sp, 0x3c] | var_3ch = r3;
0x0000481c ldrb r5, [r7, -0x1] | r5 = *((r7 - 0x1));
0x00004820 b 0x45da | goto label_25;
| label_78:
0x00004822 ldr r3, [sp, 0x40] | r3 = var_40h;
0x00004824 ldr r5, [sp, 0x3c] | r5 = var_3ch;
0x00004826 ldr r1, [sp, 0x18] | r1 = s1;
0x00004828 ldr r0, [r3, 8] | r0 = *((r3 + 8));
0x0000482a ldr r3, [sp, 0x48] | r3 = var_48h;
0x0000482c str.w r5, [r0, r3, lsl 2] | __asm ("str.w r5, [r0, r3, lsl 2]");
0x00004830 adds r3, 1 | r3++;
0x00004832 str r3, [sp, 0x48] | var_48h = r3;
0x00004834 b 0x4808 |
| } while (1);
| label_67:
0x00004836 ldrb r2, [r7] | r2 = *(r7);
0x00004838 cmp r2, 0x70 |
| if (r2 == 0x70) {
0x0000483a beq 0x487c | goto label_88;
| }
| label_29:
0x0000483c movs r3, 1 | r3 = 1;
0x0000483e movs r4, 4 | r4 = 4;
0x00004840 str r3, [sp, 0x38] | var_38h = r3;
0x00004842 b 0x44ee | goto label_9;
| label_75:
0x00004844 ldr r3, [sp, 0x18] | r3 = s1;
0x00004846 ldrb r2, [r3] | r2 = *(r3);
0x00004848 cmp r2, 0x70 |
0x0000484a beq 0x4860 |
| while (r1 != 0x72) {
| label_27:
0x0000484c movs r6, 1 | r6 = 1;
0x0000484e movs r2, 4 | r2 = 4;
0x00004850 b 0x45ca | goto label_10;
| label_51:
0x00004852 rsbs r0, r5, 0 | r0 = r5 - ;
0x00004854 blx 0x2130 | strerror (r0);
0x00004858 b 0x433a | goto label_12;
| label_30:
0x0000485a mov fp, r5 |
0x0000485c b.w 0x3f5c | goto label_26;
0x00004860 ldrb r1, [r3, 1] | r1 = *((r3 + 1));
0x00004862 adds r2, r3, 1 | r2 = r3 + 1;
0x00004864 cmp r1, 0x72 |
0x00004866 bne 0x484c |
| }
0x00004868 ldrb r1, [r2, 1]! | r1 = *((r2 += 1));
0x0000486c cmp r1, 0x65 |
| if (r1 != 0x65) {
0x0000486e bne 0x484c | goto label_27;
| }
0x00004870 ldrb r2, [r2, 1] | r2 = *((r2 + 1));
0x00004872 cmp r2, 0x3a |
0x00004874 it eq |
| if (r2 == 0x3a) {
0x00004876 moveq r4, 1 | r4 = 1;
| goto label_89;
| }
| if (r2 != 0x3a) {
| label_89:
0x00004878 bne 0x484c | goto label_27;
| }
0x0000487a b 0x47b6 | goto label_28;
| label_88:
0x0000487c ldrb r2, [r7, 1] | r2 = *((r7 + 1));
0x0000487e adds r3, r7, 1 | r3 = r7 + 1;
0x00004880 cmp r2, 0x72 |
| if (r2 != 0x72) {
0x00004882 bne 0x483c | goto label_29;
| }
0x00004884 ldrb r2, [r3, 1]! | r2 = *((r3 += 1));
0x00004888 cmp r2, 0x65 |
| if (r2 != 0x65) {
0x0000488a bne 0x483c | goto label_29;
| }
0x0000488c ldrb r3, [r3, 1] | r3 = *((r3 + 1));
0x0000488e cmp r3, 0x3a |
| if (r3 != 0x3a) {
0x00004890 bne 0x483c | goto label_29;
| }
0x00004892 movs r3, 1 | r3 = 1;
0x00004894 mov r7, r5 | r7 = r5;
0x00004896 str r3, [sp, 0x3c] | var_3ch = r3;
0x00004898 str r3, [sp, 0x38] | var_38h = r3;
0x0000489a b 0x44b4 | goto label_20;
| label_81:
0x0000489c ldr r0, [sp, 0x40] | r0 = var_40h;
0x0000489e blx 0x22bc | read (r0, r1, r2);
0x000048a2 b.w 0x4056 | goto label_1;
| label_54:
0x000048a6 blx 0x24a4 | fcn_000024a4 ();
| label_38:
0x000048aa mov r0, r4 | r0 = r4;
0x000048ac blx 0x2408 | fcn_00002408 ();
0x000048b0 b.w 0x3f9e | goto label_4;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-80367616.squashfs_v4_le_extract/usr/lib/libkmod.so.2.4.0 @ 0x6e78 */
| #include <stdint.h>
|
; (fcn) sym.kmod_module_get_initstate () | uint32_t kmod_module_get_initstate (int16_t arg1) {
| int16_t var_0h;
| int16_t var_4h;
| int16_t var_8h;
| int16_t var_18h;
| int16_t var_78h;
| int16_t var_94h;
| int16_t var_98h;
| int16_t var_1080h;
| r0 = arg1;
| label_3:
0x00005c70 push.w {r4, r5, r6, r7, r8, lr} |
0x00005c74 sub.w sp, sp, 0x1080 |
0x00005c78 ldr r4, [pc, 0x138] |
0x00005c7a sub sp, 0x18 |
0x00005c7c add.w r5, sp, 0x1080 | r5 += var_1080h;
0x00005c7e strb r4, [r0, r6] | *((r0 + r6)) = r4;
0x00005c80 mov.w r3, 0x1000 | r3 = 0x1000;
0x00005c84 str r0, [sp, 4] | var_4h = r0;
0x00005c86 add r7, sp, 0x94 | r7 += var_94h;
0x00005c88 add r4, pc | r4 = 0xba40;
0x00005c8a ldr r0, [pc, 0x12c] | r0 = *(0x5dba);
0x00005c8c str r4, [sp] | *(sp) = r4;
0x00005c8e adds r5, 0x14 | r5 += 0x14;
0x00005c90 ldr r4, [pc, 0x128] |
0x00005c92 mov r1, r3 | r1 = r3;
0x00005c94 movs r2, 1 | r2 = 1;
0x00005c96 add r4, pc | r4 = 0xba56;
0x00005c98 ldr r0, [r4, r0] |
0x00005c9a ldr r0, [r0] | r0 = *(0xba56);
0x00005c9c str r0, [r5] | *(r5) = r0;
0x00005c9e mov.w r0, 0 | r0 = 0;
0x00005ca2 mov r0, r7 | r0 = r7;
0x00005ca4 blx 0x23d8 | fcn_000023d8 ();
0x00005ca8 mov.w r1, 0x80000 | r1 = 0x80000;
0x00005cac mov r6, r0 | r6 = r0;
0x00005cae mov r0, r7 | r0 = r7;
0x00005cb0 blx 0x23b0 | r0 = fcn_000023b0 ();
0x00005cb4 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 < r0) {
0x00005cb6 blt 0x5d2a | goto label_4;
| }
0x00005cb8 add r6, sp, 0x78 | r6 += var_78h;
0x00005cba movs r2, 0x20 | r2 = 0x20;
0x00005cbc subs r7, r6, 4 | r7 = r6 - 4;
0x00005cbe mov r1, r7 | r1 = r7;
0x00005cc0 bl 0xab88 | r0 = fcn_0000ab88 (r0, r1, r2);
0x00005cc4 mov r5, r0 | r5 = r0;
0x00005cc6 mov r0, r4 | r0 = r4;
0x00005cc8 blx 0x2408 | fcn_00002408 ();
0x00005ccc cmp r5, 0 |
| if (r5 < 0) {
0x00005cce blt 0x5da8 | goto label_5;
| }
0x00005cd0 ldr r2, [r6, -0x4] | r2 = *((r6 - 0x4));
0x00005cd4 movw r3, 0x696c |
0x00005cd8 movt r3, 0x6576 | r3 = 0x6576696c;
0x00005cdc cmp r2, r3 |
| if (r2 == r3) {
0x00005cde beq 0x5d68 | goto label_6;
| }
0x00005ce0 ldr r2, [r6, -0x4] | r2 = *((r6 - 0x4));
0x00005ce4 movw r3, 0x6f63 |
0x00005ce8 movt r3, 0x696d | r3 = 0x696d6f63;
0x00005cec cmp r2, r3 |
| if (r2 == r3) {
0x00005cee beq 0x5d82 | goto label_7;
| }
| label_1:
0x00005cf0 ldr r2, [r6, -0x4] | r2 = *((r6 - 0x4));
0x00005cf4 movw r3, 0x6f67 |
0x00005cf8 movt r3, 0x6e69 | r3 = 0x6e696f67;
0x00005cfc cmp r2, r3 |
| if (r2 == r3) {
0x00005cfe beq 0x5d94 | goto label_8;
| }
| label_2:
0x00005d00 mvn r5, 0x15 | r5 = ~0x15;
| do {
| label_0:
0x00005d04 ldr r2, [pc, 0xb8] |
0x00005d06 add.w r1, sp, 0x1080 | r1 += var_1080h;
0x00005d0a ldr r3, [pc, 0xac] | r3 = *(0x5dba);
0x00005d0c adds r1, 0x14 | r1 += 0x14;
0x00005d0e add r2, pc | r2 = 0xbad2;
0x00005d10 ldr r3, [r2, r3] | r3 = *(0xbad2);
0x00005d12 ldr r2, [r3] | r2 = *(0xbad2);
0x00005d14 ldr r3, [r1] | r3 = *(r1);
0x00005d16 eors r2, r3 | r2 ^= r3;
0x00005d18 mov.w r3, 0 | r3 = 0;
| if (r2 != r3) {
0x00005d1c bne 0x5db0 | goto label_9;
| }
0x00005d1e mov r0, r5 | r0 = r5;
0x00005d20 add.w sp, sp, 0x1080 |
0x00005d24 add sp, 0x18 |
0x00005d26 pop.w {r4, r5, r6, r7, r8, pc} |
| label_4:
0x00005d2a blx 0x25e4 | r0 = fcn_000025e4 ();
0x00005d2e ldr r4, [r0] | r4 = *(r0);
0x00005d30 mov r0, r4 | r0 = r4;
0x00005d32 rsbs r5, r4, 0 | r5 = r4 - ;
0x00005d34 blx 0x2130 | strerror (r0);
0x00005d38 cmp r6, 0xa |
| if (r6 > 0xa) {
0x00005d3a ble 0x5d60 |
0x00005d3c add.w r8, sp, 0x98 | r8 += var_98h;
0x00005d40 movs r2, 0 | r2 = 0;
0x00005d42 add.w r3, r8, r6 | r3 = r8 + r6;
0x00005d46 mov r0, r7 | r0 = r7;
0x00005d48 add r1, sp, 8 | r1 += var_8h;
0x00005d4a strb r2, [r3, -0xe] | *((r3 - 0xe)) = r2;
0x00005d4e blx 0x2304 | r0 = asprintf_chk ()
| if (r0 != 0) {
0x00005d52 cbnz r0, 0x5d60 | goto label_10;
| }
0x00005d54 ldr r3, [sp, 0x18] | r3 = var_18h;
0x00005d56 and r3, r3, 0xf000 | r3 &= 0xf000;
0x00005d5a cmp.w r3, 0x4000 |
| if (r3 == 0x4000) {
0x00005d5e beq 0x5d90 | goto label_11;
| }
| }
| label_10:
0x00005d60 mov r0, r4 | r0 = r4;
0x00005d62 blx 0x2130 | strerror (r0);
0x00005d66 b 0x5d04 |
| } while (1);
| label_6:
0x00005d68 ldrh r3, [r7, 4] | r3 = *((r7 + 4));
0x00005d6a cmp r3, 0xa |
0x00005d6c it eq |
| if (r3 == 0xa) {
0x00005d6e moveq r5, 1 | r5 = 1;
| goto label_12;
| }
| if (r3 == 0xa) {
| label_12:
0x00005d70 beq 0x5d04 | goto label_0;
| }
0x00005d72 ldr r2, [r6, -0x4] | r2 = *((r6 - 0x4));
0x00005d76 movw r3, 0x6f63 |
0x00005d7a movt r3, 0x696d | r3 = 0x696d6f63;
0x00005d7e cmp r2, r3 |
| if (r2 != r3) {
0x00005d80 bne 0x5cf0 | goto label_1;
| }
| label_7:
0x00005d82 ldr r2, [r7, 4] | r2 = *((r7 + 4));
0x00005d84 movw r3, 0x676e |
0x00005d88 movt r3, 0xa | r3 = 0xa676e;
0x00005d8c cmp r2, r3 |
| if (r2 != r3) {
0x00005d8e bne 0x5cf0 | goto label_1;
| }
| label_11:
0x00005d90 movs r5, 2 | r5 = 2;
0x00005d92 b 0x5d04 | goto label_0;
| label_8:
0x00005d94 ldrh r2, [r6] | r2 = *(r6);
0x00005d96 movw r3, 0xa67 | r3 = 0xa67;
0x00005d9a cmp r2, r3 |
| if (r2 != r3) {
0x00005d9c bne 0x5d00 | goto label_2;
| }
0x00005d9e ldrb r3, [r6, 2] | r3 = *((r6 + 2));
0x00005da0 movs r5, 3 | r5 = 3;
0x00005da2 cmp r3, 0 |
| if (r3 == 0) {
0x00005da4 beq 0x5d04 | goto label_0;
| }
0x00005da6 b 0x5d00 | goto label_2;
| label_5:
0x00005da8 rsbs r0, r5, 0 | r0 = r5 - ;
0x00005daa blx 0x2130 | strerror (r0);
0x00005dae b 0x5d04 | goto label_0;
| label_9:
0x00005db0 blx 0x24a4 | fcn_000024a4 ();
0x00005db4 ldr r4, [r7, r0] | r4 = *((r7 + r0));
0x00005db6 movs r0, r0 |
0x00005db8 lsls r4, r6, 6 | r4 = r6 << 6;
0x00005dba movs r0, r0 |
0x00005dbc strh r2, [r4, 0xc] | *((r4 + 0xc)) = r2;
0x00005dbe movs r0, r0 |
0x00005dc0 strh r2, [r5, 8] | *((r5 + 8)) = r2;
0x00005dc2 movs r0, r0 |
| if (r0 == 0) {
0x00006e78 cbz r0, 0x6ea2 | goto label_13;
| }
0x00006e7a push {r4, lr} |
0x00006e7c mov r4, r0 | r4 = r0;
0x00006e7e ldr r0, [r0, 0x34] | r0 = *((r0 + 0x34));
0x00006e80 cbz r0, 0x6e94 |
| while (1) {
0x00006e82 cmp r0, 2 |
| if (r0 == 2) {
0x00006e84 bne 0x6e8a |
0x00006e86 movs r0, 0 | r0 = 0;
0x00006e88 pop {r4, pc} |
| }
0x00006e8a ldr r0, [r4, 8] | r0 = *((r4 + 8));
0x00006e8c pop.w {r4, lr} |
0x00006e90 b.w 0x5c70 | goto label_3;
0x00006e94 ldr r1, [r4, 8] | r1 = *((r4 + 8));
0x00006e96 ldr r0, [r4] | r0 = *(r4);
0x00006e98 bl 0x2cd0 | fcn_00002cd0 (r0, r1);
0x00006e9c adds r0, 1 | r0++;
0x00006e9e str r0, [r4, 0x34] | *((r4 + 0x34)) = r0;
0x00006ea0 b 0x6e82 |
| }
| label_13:
0x00006ea2 mvn r0, 1 | r0 = ~1;
0x00006ea6 bx lr | return r0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-80367616.squashfs_v4_le_extract/usr/lib/libkmod.so.2.4.0 @ 0x5ec4 */
| #include <stdint.h>
|
; (fcn) sym.kmod_module_new_from_path () | void kmod_module_new_from_path (uint32_t arg1, uint32_t arg2, uint32_t arg3) {
| int16_t var_1000h_2;
| int16_t var_0h;
| int16_t var_4h;
| int32_t var_78h;
| int16_t var_14h;
| int16_t var_10h;
| int16_t var_20h;
| int16_t var_4h_2;
| int16_t var_80h;
| int16_t var_1060h;
| int32_t var_0h_2;
| int16_t var_1080h;
| int8_t var_1bh;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
0x00005ec4 push.w {r4, r5, r6, r7, r8, sb, sl, lr} |
0x00005ec8 cmp r2, 0 |
0x00005eca it ne |
| if (r2 != 0) {
0x00005ecc cmpne r1, 0 | __asm ("cmpne r1, 0");
| }
0x00005ece mov r4, r1 | r4 = r1;
0x00005ed0 ldr r1, [pc, 0x11c] |
0x00005ed2 mov r7, r2 | r7 = r2;
0x00005ed4 sub.w sp, sp, 0x1080 |
0x00005ed6 ldrb r4, [r0, r6] | r4 = *((r0 + r6));
0x00005ed8 ldr r2, [pc, 0x118] | r2 = *(0x5ff4);
0x00005eda it eq |
| if (r2 != 0) {
0x00005edc moveq r3, 1 | r3 = 1;
| }
0x00005ede add r1, pc | r1 = 0xbed2;
0x00005ee0 it ne |
| if (r2 == 0) {
0x00005ee2 movne r3, 0 | r3 = 0;
| }
0x00005ee4 cmp r0, 0 |
0x00005ee6 it eq |
| if (r0 != 0) {
0x00005ee8 orreq r3, r3, 1 | r3 |= 1;
| }
0x00005eec mov r6, r0 | r6 = r0;
0x00005eee ldr r2, [r1, r2] |
0x00005ef0 add.w r0, sp, 0x1060 | r0 += var_1060h;
0x00005ef4 adds r0, 0x1c | r0 += 0x1c;
0x00005ef6 ldr r2, [r2] | r2 = *(0xbed2);
0x00005ef8 str r2, [r0] | *(r0) = r2;
0x00005efa mov.w r2, 0 | r2 = 0;
0x00005efe cmp r3, 0 |
| if (r3 != 0) {
0x00005f00 bne 0x5fe6 | goto label_3;
| }
0x00005f02 mov r0, r4 | r0 = r4;
0x00005f04 bl 0xade8 | r0 = fcn_0000ade8 (r0);
0x00005f08 mov r5, r0 | r5 = r0;
0x00005f0a cmp r0, 0 |
| if (r0 == 0) {
0x00005f0c beq 0x5fce | goto label_4;
| }
0x00005f0e add.w r8, sp, 0x20 | r8 += var_20h;
0x00005f12 sub.w r1, r8, 0x10 | r1 -= var_10h;
0x00005f16 blx 0x2304 | r0 = asprintf_chk ()
0x00005f1a cmp r0, 0 |
| if (r0 < 0) {
0x00005f1c blt 0x5f8c | goto label_5;
| }
0x00005f1e add.w sb, sp, 0x80 | sb += var_80h;
0x00005f22 mov r0, r4 | r0 = r4;
0x00005f24 sub.w sl, sb, 4 | sl -= var_4h_2;
0x00005f28 sub.w r2, r8, 0x14 | r2 -= var_14h;
0x00005f2c mov r1, sl | r1 = sl;
0x00005f2e bl 0xab68 | r0 = fcn_0000ab68 (r0, r1);
0x00005f32 cmp r0, 0 |
| if (r0 == 0) {
0x00005f34 beq 0x5fe0 | goto label_6;
| }
0x00005f36 mov r1, sl | r1 = sl;
0x00005f38 mov r0, r6 | r0 = r6;
0x00005f3a bl 0x2b70 | r0 = fcn_00002b70 (r0, r1);
0x00005f3e mov r4, r0 | r4 = r0;
0x00005f40 str r0, [sb, -0x78] | var_78h = r0;
| if (r0 == 0) {
0x00005f44 cbz r0, 0x5fa4 | goto label_7;
| }
0x00005f46 ldr r0, [r0, 0xc] | r0 = *((r0 + 0xc));
| if (r0 == 0) {
0x00005f48 cbz r0, 0x5fa0 | goto label_8;
| }
0x00005f4a mov r1, r5 | r1 = r5;
0x00005f4c blx 0x25d8 | r0 = fcn_000025d8 ();
0x00005f50 cmp r0, 0 |
| if (r0 != 0) {
0x00005f52 bne 0x5fd4 | goto label_9;
| }
0x00005f54 mov r0, r5 | r0 = r5;
0x00005f56 blx 0x22bc | read (r0, r1, r2);
0x00005f58 invalid |
| label_0:
0x00005f5a mov r0, r4 | r0 = r4;
0x00005f5c blx 0x2508 | fnmatch ();
| label_1:
0x00005f60 movs r6, 0 | r6 = 0;
0x00005f62 movs r3, 1 | r3 = 1;
0x00005f64 str r3, [r4, 0x34] | *((r4 + 0x34)) = r3;
0x00005f66 str r4, [r7] | *(r7) = r4;
| do {
| label_2:
0x00005f68 ldr r2, [pc, 0x8c] |
0x00005f6a add.w r1, sp, 0x1060 | r1 += var_1060h;
0x00005f6e ldr r3, [pc, 0x84] | r3 = *(0x5ff6);
0x00005f70 adds r1, 0x1c | r1 += 0x1c;
0x00005f72 add r2, pc | r2 = 0xbf6e;
0x00005f74 ldr r3, [r2, r3] | r3 = *(0xbf6e);
0x00005f76 ldr r2, [r3] | r2 = *(0xbf6e);
0x00005f78 ldr r3, [r1] | r3 = *(r1);
0x00005f7a eors r2, r3 | r2 ^= r3;
0x00005f7c mov.w r3, 0 | r3 = 0;
| if (r2 != r3) {
0x00005f80 bne 0x5fec | goto label_10;
| }
0x00005f82 mov r0, r6 | r0 = r6;
0x00005f84 add.w sp, sp, 0x1080 |
0x00005f88 pop.w {r4, r5, r6, r7, r8, sb, sl, pc} |
| label_5:
0x00005f8c blx 0x25e4 | r0 = fcn_000025e4 ();
0x00005f90 ldr r0, [r0] | r0 = *(r0);
0x00005f92 rsbs r6, r0, 0 | r6 = r0 - ;
0x00005f94 blx 0x2130 | strerror (r0);
0x00005f98 mov r0, r5 | r0 = r5;
0x00005f9a blx 0x22bc | read (r0, r1, r2);
0x00005f9e b 0x5f68 |
| } while (1);
| label_8:
0x00005fa0 str r5, [r4, 0xc] | *((r4 + 0xc)) = r5;
0x00005fa2 b 0x5f5a | goto label_0;
| label_7:
0x00005fa4 sub.w r3, r8, 0x18 | r3 -= var_78h;
0x00005fa8 mov r0, r6 | r0 = r6;
0x00005faa str r3, [sp, 4] | var_4h = r3;
0x00005fac mov r1, sl | r1 = sl;
0x00005fae str r4, [sp] | *(sp) = r4;
0x00005fb0 mov r3, r4 | r3 = r4;
0x00005fb2 ldr r2, [sb, -0x74] | r2 = var_14h;
0x00005fb6 bl 0x5df8 | r0 = fcn_00005df8 (r0, r1, r2, r3, r4, r5);
0x00005fba subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 >= r0) {
0x00005fbc blt 0x5fc6 |
0x00005fbe ldr r4, [sb, -0x78] | r4 = var_78h;
0x00005fc2 str r5, [r4, 0xc] | *((r4 + 0xc)) = r5;
0x00005fc4 b 0x5f60 | goto label_1;
| }
0x00005fc6 mov r0, r5 | r0 = r5;
0x00005fc8 blx 0x22bc | read (r0, r1, r2);
0x00005fcc b 0x5f68 | goto label_2;
| label_4:
0x00005fce mvn r6, 0xb | r6 = ~0xb;
0x00005fd2 b 0x5f68 | goto label_2;
| label_9:
0x00005fd4 mov r0, r5 | r0 = r5;
0x00005fd6 mvn r6, 0x10 | r6 = ~0x10;
0x00005fda blx 0x22bc | read (r0, r1, r2);
0x00005fde b 0x5f68 | goto label_2;
| label_6:
0x00005fe0 mov r0, r5 | r0 = r5;
0x00005fe2 blx 0x22bc | read (r0, r1, r2);
| label_3:
0x00005fe6 mvn r6, 1 | r6 = ~1;
0x00005fea b 0x5f68 | goto label_2;
| label_10:
0x00005fec blx 0x24a4 | fcn_000024a4 ();
0x00005ff0 ldrb r2, [r3, 0x1d] | r2 = *((r3 + 0x1d));
0x00005ff2 movs r0, r0 |
0x00005ff4 lsls r4, r6, 6 | r4 = r6 << 6;
0x00005ff6 movs r0, r0 |
0x00005ff8 ldrb r6, [r0, 0x1b] | r6 = var_1bh;
0x00005ffa movs r0, r0 |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-80367616.squashfs_v4_le_extract/usr/lib/libkmod.so.2.4.0 @ 0x3044 */
| #include <stdint.h>
|
; (fcn) sym.kmod_validate_resources () | void kmod_validate_resources (int16_t arg1) {
| int16_t var_0h;
| int32_t var_4h;
| int32_t var_4h_2;
| int16_t var_10h;
| int16_t var_7ch;
| int16_t var_260h;
| int16_t var_ah;
| int16_t var_278h;
| int16_t var_3a0h;
| int16_t var_1060h;
| int32_t var_0h_2;
| int16_t var_1080h;
| r0 = arg1;
0x00003044 blmi 0xf95940 | __asm ("blmi fcn.0000ade8");
0x00003048 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0000304c sub.w sp, sp, 0x1080 |
0x00003050 add r2, pc | r2 += pc;
0x00003052 sub sp, 4 |
0x00003054 add.w r1, sp, 0x1060 | r1 += var_1060h;
0x00003058 ldr r3, [r2, r3] | r3 = *((r2 + r3));
0x0000305a adds r1, 0x1c | r1 += 0x1c;
0x0000305c ldr r3, [r3] | r3 = *(r3);
0x0000305e str r3, [r1] | *(r1) = r3;
0x00003060 mov.w r3, 0 | r3 = 0;
| if (r0 == 0) {
0x00003064 cbz r0, 0x3094 | goto label_1;
| }
0x00003066 ldr r3, [r0, 0x18] | r3 = *((r0 + 0x18));
0x00003068 mov r5, r0 | r5 = r0;
| if (r3 == 0) {
0x0000306a cbz r3, 0x3094 | goto label_1;
| }
0x0000306c ldr r4, [r3, 0x1c] | r4 = *((r3 + 0x1c));
| if (r4 == 0) {
0x0000306e cbz r4, 0x30c8 | goto label_2;
| }
0x00003070 add r6, sp, 0x10 | r6 += var_10h;
| do {
0x00003072 ldr r3, [r4, 8] | r3 = *((r4 + 8));
0x00003074 mov r1, r6 | r1 = r6;
0x00003076 add.w r0, r3, 8 | r0 = r3 + 8;
0x0000307a ldrd r8, r7, [r3] | __asm ("ldrd r8, r7, [r3]");
0x0000307e blx 0x2304 | r0 = asprintf_chk ()
0x00003082 cmp r0, 0 |
| if (r0 >= 0) {
0x00003084 blt 0x3094 |
0x00003086 mov r0, r6 | r0 = r6;
0x00003088 bl 0xae54 | fcn_0000ae54 (r0);
0x0000308c cmp r7, r1 |
0x0000308e it eq |
| if (r7 == r1) {
0x00003090 cmpeq r8, r0 | __asm ("cmpeq r8, r0");
| }
| if (r7 == r1) {
0x00003092 beq 0x30ba | goto label_3;
| }
| }
| label_1:
0x00003094 movs r0, 2 | r0 = 2;
| label_0:
0x00003096 ldr r2, [pc, 0xac] |
0x00003098 add.w r1, sp, 0x1060 | r1 += var_1060h;
0x0000309c ldr r3, [pc, 0xa0] | r3 = *(0x3140);
0x0000309e adds r1, 0x1c | r1 += 0x1c;
0x000030a0 add r2, pc | r2 = 0x61ea;
0x000030a2 ldr r3, [r2, r3] | r3 = *(0x61ea);
0x000030a4 ldr r2, [r3] | r2 = *(0x61ea);
0x000030a6 ldr r3, [r1] | r3 = *(r1);
0x000030a8 eors r2, r3 | r2 ^= r3;
0x000030aa mov.w r3, 0 | r3 = 0;
| if (r2 != r3) {
0x000030ae bne 0x3138 | goto label_4;
| }
0x000030b0 add.w sp, sp, 0x1080 |
0x000030b4 add sp, 4 |
0x000030b6 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_3:
0x000030ba ldr r3, [r5, 0x18] | r3 = *((r5 + 0x18));
0x000030bc ldr r4, [r4] | r4 = *(r4);
0x000030be ldr r3, [r3, 0x1c] | r3 = *((r3 + 0x1c));
0x000030c0 cmp r4, r3 |
| if (r4 == r3) {
0x000030c2 beq 0x30c8 | goto label_2;
| }
0x000030c4 cmp r4, 0 |
0x000030c6 bne 0x3072 |
| } while (r4 != 0);
| label_2:
0x000030c8 ldr r7, [pc, 0x7c] |
0x000030ca add.w r6, r5, 0x1c | r6 = r5 + 0x1c;
0x000030ce add.w r4, r5, 0x38 | r4 = r5 + 0x38;
0x000030d2 add.w sb, r5, 0x30 | sb = r5 + 0x30;
0x000030d6 add r7, pc | r7 = 0x6222;
| do {
0x000030d8 ldr r3, [r6, 4]! | r3 = *((r6 += 4));
| if (r3 != 0) {
0x000030dc cbz r3, 0x3128 |
0x000030de ldr r2, [r7] | r2 = *(r7);
0x000030e0 add.w r8, sp, 0x7c | r8 += var_7ch;
0x000030e4 ldr r3, [r5, 0x14] | r3 = *((r5 + 0x14));
0x000030e6 mov r0, r8 | r0 = r8;
0x000030e8 strd r3, r2, [sp, 4] | __asm ("strd r3, r2, [var_4h]");
0x000030ea adds r2, 1 | r2++;
0x000030ec movs r2, 1 | r2 = 1;
0x000030ee ldr r3, [pc, 0x5c] |
0x000030f0 add r3, pc | r3 = 0x6242;
0x000030f2 str r3, [sp] | *(sp) = r3;
0x000030f4 mov.w r3, 0x1000 | r3 = 0x1000;
0x000030f8 mov r1, r3 | r1 = r3;
0x000030fa blx 0x23d8 | fcn_000023d8 ();
0x000030fe mov r0, r8 | r0 = r8;
0x00003100 add.w r8, sp, 0x10 | r8 += var_10h;
0x00003104 mov r1, r8 | r1 = r8;
0x00003106 ldr.w fp, [r4] | fp = *(r4);
0x0000310a ldr.w sl, [r4, 4] | sl = *((r4 + 4));
0x0000310e blx 0x2304 | r0 = asprintf_chk ()
0x00003112 cmp r0, 0 |
| if (r0 >= 0) {
0x00003114 blt 0x3124 |
0x00003116 mov r0, r8 | r0 = r8;
0x00003118 bl 0xae54 | fcn_0000ae54 (r0);
0x0000311c cmp sl, r1 |
0x0000311e it eq |
| if (sl == r1) {
0x00003120 cmpeq fp, r0 | __asm ("cmpeq fp, r0");
| }
| if (sl == r1) {
0x00003122 beq 0x3128 | goto label_5;
| }
| }
0x00003124 movs r0, 1 | r0 = 1;
0x00003126 b 0x3096 | goto label_0;
| }
| label_5:
0x00003128 cmp r6, sb |
0x0000312a add.w r7, r7, 8 | r7 += 8;
0x0000312e add.w r4, r4, 8 | r4 += 8;
0x00003132 bne 0x30d8 |
| } while (r6 != sb);
0x00003134 movs r0, 0 | r0 = 0;
0x00003136 b 0x3096 | goto label_0;
| label_4:
0x00003138 blx 0x24a4 | fcn_000024a4 ();
0x0000313c add r5, sp, 0x3a0 | r5 += var_3a0h;
0x0000313e movs r0, r0 |
0x00003140 lsls r4, r6, 6 | r4 = r6 << 6;
0x00003142 movs r0, r0 |
0x00003144 add r5, sp, 0x260 | r5 += var_260h;
0x00003146 movs r0, r0 |
0x00003148 add r3, sp, 0x278 | r3 += var_278h;
0x0000314a movs r0, r0 |
0x0000314c strh r4, [r5, 0xa] | var_ah = r4;
0x0000314e movs r0, r0 |
| }
[*] Function printf used 6 times libkmod.so.2.4.0