[*] Binary protection state of libc.so.6
Full RELRO Canary found NX enabled DSO No RPATH No RUNPATH No Symbols
[*] Function mmap tear down of libc.so.6
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x2a0c8 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.0002a0c8 () | void fcn_0002a0c8 (int16_t arg1, int16_t arg2) {
| void * s1;
| int16_t var_8h_2;
| int32_t var_18h;
| int16_t var_0h;
| r0 = arg1;
| r1 = arg2;
0x0002a0c8 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0002a0cc movs r2, 1 | r2 = 1;
0x0002a0ce sub sp, 0x84 |
0x0002a0d0 mov r4, r0 | r4 = r0;
0x0002a0d2 movs r3, 0 | r3 = 0;
0x0002a0d4 mov r8, r1 | r8 = r1;
0x0002a0d6 ldr r0, [r0] | r0 = *(r0);
0x0002a0d8 add r7, sp, 8 | r7 += s1;
0x0002a0da mov.w r1, 0x80000 | r1 = 0x80000;
0x0002a0de strd r2, r3, [r4, 4] | __asm ("strd r2, r3, [r4, 4]");
0x0002a0e2 bl 0xa65f4 | r0 = open_nocancel ();
0x0002a0e6 subs r5, r0, 0 | r5 = r0 - 0;
| if (r5 >= r0) {
0x0002a0e8 blt 0x2a14c |
0x0002a0ea add.w r6, r7, 8 | r6 += var_8h_2;
0x0002a0ee mov r1, r6 | r1 = r6;
0x0002a0f0 bl 0x9ea88 | r0 = fstat64_time64 ();
0x0002a0f4 cmp r0, 0 |
| if (r0 < 0) {
0x0002a0f6 blt 0x2a1aa | goto label_2;
| }
0x0002a0f8 ldr r3, [r7, 0x18] | r3 = var_18h;
0x0002a0fa and r3, r3, 0xf000 | r3 &= 0xf000;
0x0002a0fe cmp.w r3, 0x4000 |
| if (r3 == 0x4000) {
0x0002a102 beq 0x2a1b8 | goto label_4;
| }
| label_1:
0x0002a104 ldr r3, [pc, 0x164] |
0x0002a106 mrc p15, 0, sb, c13, c0, 3 | __asm ("mrc p15, 0, sb, c13, c0, 3");
0x0002a10a movs r0, 0 | r0 = 0;
0x0002a10c ldr r1, [r7, 0x30] | r1 = *((r7 + 0x30));
0x0002a10e movs r2, 1 | r2 = 1;
0x0002a110 add r3, pc |
0x0002a112 ldr r3, [r3] | r3 = *(0x54380);
0x0002a114 ldr.w r3, [sb, r3] | r3 = *((sb + r3));
0x0002a118 strd r5, r0, [sp] | __asm ("strd r5, r0, [sp]");
0x0002a11c str r3, [r7, 4] | *((r7 + 4)) = r3;
0x0002a11e movs r3, 2 | r3 = 2;
0x0002a120 bl 0xa9f88 | r0 = mmap ()
0x0002a124 adds r3, r0, 1 | r3 = r0 + 1;
0x0002a126 mov r6, r0 | r6 = r0;
| if (r3 == r0) {
0x0002a128 beq 0x2a154 | goto label_5;
| }
0x0002a12a mov r0, r5 | r0 = r5;
0x0002a12c bl 0xa64c4 | close_nocancel ();
| if (r6 == 0) {
0x0002a130 cbz r6, 0x2a14c | goto label_0;
| }
0x0002a132 ldr r2, [r7, 0x30] | r2 = *((r7 + 0x30));
0x0002a134 mov r1, r6 | r1 = r6;
0x0002a136 mov r0, r8 | r0 = r8;
0x0002a138 bl 0x29f54 | r0 = fcn_00029f54 (r0, r1, r2, r3);
0x0002a13c cmp r0, 0 |
| if (r0 == 0) {
0x0002a13e beq.w 0x2a260 | goto label_6;
| }
0x0002a142 movs r3, 1 | r3 = 1;
| label_3:
0x0002a144 movs r2, 0 | r2 = 0;
0x0002a146 str r3, [r0, 0xc] | *((r0 + 0xc)) = r3;
0x0002a148 str r2, [r0] | *(r0) = r2;
0x0002a14a str r0, [r4, 8] | *((r4 + 8)) = r0;
| }
| label_0:
0x0002a14c adds r7, 0x7c | r7 += 0x7c;
0x0002a14e mov sp, r7 |
0x0002a150 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_5:
0x0002a154 ldr r3, [pc, 0x118] |
0x0002a156 add r3, pc |
0x0002a158 ldr r3, [r3] | r3 = *(0x543ca);
0x0002a15a ldr.w r3, [sb, r3] | r3 = *((sb + r3));
0x0002a15e cmp r3, 0x26 |
| if (r3 != 0x26) {
0x0002a160 bne 0x2a1aa | goto label_2;
| }
0x0002a162 ldr r6, [r7, 0x30] | r6 = *((r7 + 0x30));
0x0002a164 mov r0, r6 | r0 = r6;
0x0002a166 blx 0x21354 | fcn_00021354 ();
0x0002a16a str r0, [r7] | *(r7) = r0;
| if (r0 == 0) {
0x0002a16c cbz r0, 0x2a1aa | goto label_2;
| }
0x0002a16e subs.w sl, r6, 0 | sl = r6 - 0;
0x0002a172 it gt |
| if (sl <= r6) {
0x0002a174 ldrgt fp, [r7] | fp = *(r7);
| }
| if (sl > r6) {
0x0002a178 bgt 0x2a182 | goto label_7;
| }
0x0002a17a b 0x2a23a | goto label_8;
| do {
0x0002a17c cmp.w sl, 0 |
| if (sl <= 0) {
0x0002a180 ble 0x2a23a | goto label_8;
| }
| label_7:
0x0002a182 mov r2, sl | r2 = sl;
0x0002a184 mov r1, fp | r1 = fp;
0x0002a186 mov r0, r5 | r0 = r5;
0x0002a188 bl 0xa6780 | r0 = read_nocancel ();
0x0002a18c subs r6, r0, 0 | r6 = r0 - 0;
0x0002a18e sub.w sl, sl, r6 | sl -= r6;
0x0002a192 add fp, r6 |
0x0002a194 bgt 0x2a17c |
| } while (r6 > r0);
0x0002a196 ldr r0, [r7] | r0 = *(r7);
0x0002a198 blx 0x212d4 | fcn_000212d4 ();
| if (r6 == 0) {
0x0002a19c cbnz r6, 0x2a1aa |
0x0002a19e ldr r3, [pc, 0xd4] |
0x0002a1a0 movs r2, 0x16 | r2 = 0x16;
0x0002a1a2 add r3, pc |
0x0002a1a4 ldr r3, [r3] | r3 = *(0x5441c);
0x0002a1a6 str.w r2, [sb, r3] | __asm ("str.w r2, [sb, r3]");
| }
| label_2:
0x0002a1aa mov r0, r5 | r0 = r5;
0x0002a1ac bl 0xa64c4 | close_nocancel ();
0x0002a1b0 adds r7, 0x7c | r7 += 0x7c;
0x0002a1b2 mov sp, r7 |
0x0002a1b4 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_4:
0x0002a1b8 mov r0, r5 | r0 = r5;
0x0002a1ba bl 0xa64c4 | close_nocancel ();
0x0002a1be ldr.w sb, [r4] | sb = *(r4);
0x0002a1c2 mov r0, sb | r0 = sb;
0x0002a1c4 bl 0x6a8c0 | strlen ();
0x0002a1c8 ldr r3, [pc, 0xb0] |
0x0002a1ca mov r1, sb | r1 = sb;
0x0002a1cc mov r5, r0 | r5 = r0;
0x0002a1ce mov r2, r0 | r2 = r0;
0x0002a1d0 add r3, pc | r3 = 0x54450;
0x0002a1d2 ldrb.w sl, [r3, r8] | sl = *((r3 + r8));
0x0002a1d6 add.w r3, sl, r0 | r3 = sl + r0;
0x0002a1da adds r3, 0xd | r3 += 0xd;
0x0002a1dc bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x0002a1e0 sub.w sp, sp, r3 |
0x0002a1e4 add.w sb, sp, 8 | sb += s1;
0x0002a1e8 mov r0, sb | r0 = sb;
0x0002a1ea blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002a1ee ldr.w ip, [pc, 0x90] | ip = *(0x0002a280);
0x0002a1f2 mov r3, r0 | r3 = r0;
0x0002a1f4 ldr r1, [pc, 0x8c] |
0x0002a1f6 add.w r2, sl, 1 | r2 = sl + 1;
0x0002a1fa add ip, pc |
0x0002a1fc ldr.w r0, [ip] | r0 = *(ip);
0x0002a200 add r1, pc | r1 = 0x54488;
0x0002a202 ldrb.w r1, [r1, r8] | r1 = *((r1 + r8));
0x0002a206 str r0, [r3, r5] | *((r3 + r5)) = r0;
0x0002a208 adds r0, r3, r5 | r0 = r3 + r5;
0x0002a20a ldrb.w r3, [ip, 4] | r3 = *((ip + 4));
0x0002a20e adds r0, 5 | r0 += 5;
0x0002a210 strb r3, [r0, -0x1] | *((r0 - 0x1)) = r3;
0x0002a214 ldr r3, [pc, 0x70] |
0x0002a216 add r3, pc | r3 = 0x544a2;
0x0002a218 add r1, r3 | r1 += r3;
0x0002a21a blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002a21e mov.w r1, 0x80000 | r1 = 0x80000;
0x0002a222 mov r0, sb | r0 = sb;
0x0002a224 bl 0xa65f4 | r0 = open_nocancel ();
0x0002a228 subs r5, r0, 0 | r5 = r0 - 0;
| if (r5 < r0) {
0x0002a22a blt 0x2a14c | goto label_0;
| }
0x0002a22c mov r1, r6 | r1 = r6;
0x0002a22e bl 0x9ea88 | r0 = fstat64_time64 ();
0x0002a232 cmp r0, 0 |
| if (r0 >= 0) {
0x0002a234 bge.w 0x2a104 | goto label_1;
| }
0x0002a238 b 0x2a1aa | goto label_2;
| label_8:
0x0002a23a ldr r3, [pc, 0x3c] |
0x0002a23c mov r0, r5 | r0 = r5;
0x0002a23e ldr r2, [r7, 4] | r2 = *((r7 + 4));
0x0002a240 add r3, pc |
0x0002a242 ldr r3, [r3] | r3 = *(0x544be);
0x0002a244 str.w r2, [sb, r3] | __asm ("str.w r2, [sb, r3]");
0x0002a248 bl 0xa64c4 | close_nocancel ();
0x0002a24c ldr r2, [r7, 0x30] | r2 = *((r7 + 0x30));
0x0002a24e mov r0, r8 | r0 = r8;
0x0002a250 ldr r1, [r7] | r1 = *(r7);
0x0002a252 bl 0x29f54 | fcn_00029f54 (r0, r1, r2, r3);
0x0002a256 movs r3, 0 | r3 = 0;
0x0002a258 cmp r0, 0 |
| if (r0 == 0) {
0x0002a25a beq.w 0x2a14c | goto label_0;
| }
0x0002a25e b 0x2a144 | goto label_3;
| label_6:
0x0002a260 ldr r1, [r7, 0x30] | r1 = *((r7 + 0x30));
0x0002a262 mov r0, r6 | r0 = r6;
0x0002a264 bl 0xaa040 | munmap ();
0x0002a268 b 0x2a14c | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x2b1ac */
| #include <stdint.h>
|
; (fcn) fcn.0002b1ac () | void fcn_0002b1ac (int16_t arg_28h, int16_t arg1, int16_t arg2, int16_t arg3, int16_t arg4) {
| int16_t var_0h;
| int32_t var_4h;
| int32_t var_4h_2;
| int32_t var_ch;
| int32_t var_ch_2;
| int16_t var_14h;
| char * src;
| char * dest;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
| r3 = arg4;
0x0002b1ac push {r7, lr} |
0x0002b1ae mov r6, r0 | r6 = r0;
0x0002b1b0 sub sp, 0x20 |
0x0002b1b2 ldr r4, [pc, 0xdc] |
0x0002b1b4 mov r8, r1 | r8 = r1;
0x0002b1b6 movs r0, 1 | r0 = 1;
0x0002b1b8 movs r1, 0 | r1 = 0;
0x0002b1ba mov r5, r2 | r5 = r2;
0x0002b1bc mov r7, r3 | r7 = r3;
0x0002b1be ldr.w sb, [sp, 0x28] | sb = *(arg_28h);
0x0002b1c2 bl 0x62128 | pthread_setcancelstate ();
0x0002b1c6 ldr r3, [pc, 0xcc] | r3 = *(0x2b296);
0x0002b1c8 add r4, pc | r4 = 0x5645e;
0x0002b1ca ldr r3, [r4, r3] | r3 = *(0x5645e);
0x0002b1cc ldr r2, [r3] | r2 = *(0x5645e);
0x0002b1ce ldrb r3, [r2] | r3 = *(r2);
0x0002b1d0 cmp r3, 0 |
| if (r3 != 0) {
0x0002b1d2 bne 0x2b26c | goto label_3;
| }
0x0002b1d4 ldr r3, [pc, 0xc0] |
0x0002b1d6 add r3, pc | r3 = 0x56472;
0x0002b1d8 cmp.w sb, 0 |
| if (sb == 0) {
0x0002b1dc beq 0x2b276 | goto label_4;
| }
| label_0:
0x0002b1de ldr r1, [pc, 0xbc] |
0x0002b1e0 add r1, pc | r1 = 0x56482;
| label_1:
0x0002b1e2 str r5, [sp] | *(sp) = r5;
0x0002b1e4 add r5, sp, 0x1c | r5 += dest;
0x0002b1e6 strd r1, r8, [sp, 0xc] | __asm ("strd r1, r8, [var_ch]");
0x0002b1ea add r0, sp, 0x18 | r0 += src;
0x0002b1ec mov r1, r6 | r1 = r6;
0x0002b1ee strd r7, sb, [sp, 4] | __asm ("strd r7, sb, [var_4h]");
0x0002b1f2 str r5, [sp, 0x14] | var_14h = r5;
0x0002b1f4 bl 0x3eec0 | r0 = asprintf ();
0x0002b1f8 cmp r0, 0 |
| if (r0 < 0) {
0x0002b1fa blt 0x2b280 | goto label_5;
| }
0x0002b1fc ldr r1, [pc, 0xa0] |
0x0002b1fe movs r0, 0 | r0 = 0;
0x0002b200 ldr r2, [sp, 0x18] | r2 = src;
0x0002b202 add r1, pc | r1 = 0x564a6;
0x0002b204 bl 0x4f2f0 | fcn_0004f2f0 ();
0x0002b208 ldr r3, [pc, 0x98] | r3 = *(0x2b2a4);
0x0002b20a ldr r3, [r4, r3] | r3 = *((r4 + r3));
0x0002b20c ldr r0, [r3] | r0 = *(0x2b2a4);
0x0002b20e bl 0x4f804 | IO_fflush ();
0x0002b212 ldr r3, [pc, 0x94] | r3 = *(0x2b2aa);
0x0002b214 movs r0, 0 | r0 = 0;
0x0002b216 ldr r1, [sp, 0x1c] | r1 = dest;
0x0002b218 mov.w r2, -1 | r2 = -1;
0x0002b21c ldr r4, [r4, r3] | r4 = *((r4 + r3));
0x0002b21e movs r3, 0x22 | r3 = 0x22;
0x0002b220 strd r2, r0, [sp] | __asm ("strd r2, r0, [sp]");
0x0002b224 movs r2, 3 | r2 = 3;
0x0002b226 ldr r4, [r4, 0x10] | r4 = *((r4 + 0x10));
0x0002b228 add r1, r4 | r1 += r4;
0x0002b22a rsbs r4, r4, 0 | r4 -= ;
0x0002b22c ands r1, r4 | r1 &= r4;
0x0002b22e str r1, [sp, 0x1c] | dest = r1;
0x0002b230 bl 0xa9f88 | r0 = mmap ()
0x0002b234 adds r3, r0, 1 | r3 = r0 + 1;
0x0002b236 mov r4, r0 | r4 = r0;
| if (r3 == r0) {
0x0002b238 beq 0x2b262 | goto label_6;
| }
0x0002b23a ldr r3, [sp, 0x1c] | r3 = dest;
0x0002b23c ldr r1, [sp, 0x18] | r1 = src;
0x0002b23e str r3, [r0], 4 | *(r0) = r3;
| r0 += 4;
0x0002b242 bl 0x6a480 | strcpy (r0, r1);
0x0002b246 ldr r3, [pc, 0x64] |
0x0002b248 add r3, pc | r3 = 0x564fa;
| do {
0x0002b24a ldrex r0, [r3] | __asm ("ldrex r0, [r3]");
0x0002b24e strex r2, r4, [r3] | __asm ("strex r2, r4, [r3]");
0x0002b252 cmp r2, 0 |
0x0002b254 bne 0x2b24a |
| } while (r2 != 0);
0x0002b256 dmb ish | __asm ("dmb ish");
| if (r0 != 0) {
0x0002b25a cbz r0, 0x2b262 |
0x0002b25c ldr r1, [r0] | r1 = *(r0);
0x0002b25e bl 0xaa040 | munmap ();
| }
| label_6:
0x0002b262 ldr r0, [sp, 0x18] | r0 = src;
0x0002b264 blx 0x212d4 | fcn_000212d4 ();
| label_2:
0x0002b268 bl 0x21388 | abort ();
| label_3:
0x0002b26c ldr r3, [pc, 0x40] |
0x0002b26e add r3, pc | r3 = 0x56522;
0x0002b270 cmp.w sb, 0 |
| if (sb != 0) {
0x0002b274 bne 0x2b1de | goto label_0;
| }
| label_4:
0x0002b276 ldr.w sb, [pc, 0x3c] | sb = *(0x0002b2b4);
0x0002b27a add sb, pc | sb += pc;
0x0002b27c mov r1, sb | r1 = sb;
0x0002b27e b 0x2b1e2 | goto label_1;
| label_5:
0x0002b280 ldr r1, [pc, 0x34] |
0x0002b282 movs r2, 0x12 | r2 = 0x12;
0x0002b284 movs r0, 2 | r0 = 2;
0x0002b286 add r1, pc | r1 = 0x56542;
0x0002b288 bl 0x9f800 | write (r0, r1, r2);
0x0002b28c b 0x2b268 | goto label_2;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x2c830 */
| #include <stdint.h>
|
| #define SWAP32(n) ((uint32_t) (((n & 0x000000ff) << 24) | \
| ((n & 0x0000ff00) << 8) | \
| ((n & 0x00ff0000) >> 8) | \
| ((n & 0xff000000) >> 24)))
| #define SWAP64(val) ((uint64_t) (((val & 0x00000000000000ffull) << 56) | \
| ((val & 0x000000000000ff00ull) << 40) | \
| ((val & 0x0000000000ff0000ull) << 24) | \
| ((val & 0x00000000ff000000ull) << 8) | \
| ((val & 0x000000ff00000000ull) >> 8) | \
| ((val & 0x0000ff0000000000ull) >> 24) | \
| ((val & 0x00ff000000000000ull) >> 40) | \
| ((val & 0xff00000000000000ull) >> 56)))
|
; (fcn) fcn.0002c830 () | void fcn_0002c830 (int16_t arg_0h, int16_t arg_8h, int16_t arg_14h, int16_t arg_168h, int16_t arg_238h, int16_t arg_240h, int16_t arg_258h, int16_t arg_2b8h, int16_t arg_2d8h, int16_t arg_2f8h, int16_t arg_360h, int16_t arg_388h, int16_t arg_390h, int16_t arg_3a8h, uint32_t arg1, int16_t arg2) {
| int16_t var_bp_8h;
| int16_t var_0h;
| int32_t var_0h_2;
| int16_t var_8h;
| int16_t var_ch;
| int16_t var_10h;
| int16_t var_14h;
| int16_t var_18h;
| 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;
| int16_t var_4ch;
| int16_t var_50h;
| int16_t var_54h;
| int16_t var_58h;
| int16_t var_5ch;
| int16_t var_60h;
| int32_t var_60h_2;
| int16_t var_68h;
| int16_t var_90h;
| int32_t var_90h_2;
| int16_t var_a8h;
| r0 = arg1;
| r1 = arg2;
0x0002c830 ldr.w r3, [pc, 0x490] | r3 = *(0x0002ccc4);
0x0002c834 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0002c838 mrc p15, 0, r7, c13, c0, 3 | __asm ("mrc p15, 0, r7, c13, c0, 3");
0x0002c83c sub.w r5, r7, 0x540 | r5 = r7 - 0x540;
0x0002c840 sub sp, 0xdc |
0x0002c842 add r3, pc | r3 += pc;
0x0002c844 mov r4, r0 | r4 = r0;
0x0002c846 ldr r2, [r3, 8] | r2 = *((r3 + 8));
0x0002c848 mov sb, r1 | sb = r1;
0x0002c84a cmp r2, r5 |
| if (r2 == r5) {
0x0002c84c beq 0x2c870 | goto label_43;
| }
0x0002c84e movs r2, 1 | r2 = 1;
| do {
0x0002c850 ldrex r1, [r3] | __asm ("ldrex r1, [r3]");
0x0002c854 cmp r1, 0 |
| if (r1 != 0) {
0x0002c856 bne 0x2c864 | goto label_44;
| }
0x0002c858 strex r0, r2, [r3] | __asm ("strex r0, r2, [r3]");
0x0002c85c cmp r0, 0 |
0x0002c85e bne 0x2c850 |
| } while (arg_0h != );
0x0002c860 dmb ish | __asm ("dmb ish");
| if (arg_0h != ) {
| label_44:
0x0002c864 bne.w 0x2caa6 | goto label_45;
| }
| label_4:
0x0002c868 ldr.w r3, [pc, 0x45c] |
0x0002c86c add r3, pc | r3 = 0x59538;
0x0002c86e str r5, [r3, 8] | *((r3 + 8)) = r5;
| label_43:
0x0002c870 ldr.w r6, [pc, 0x458] | r6 = *(0x0002cccc);
0x0002c874 ldr r1, [r4, 4] | r1 = *((r4 + 4));
0x0002c876 add r6, pc | r6 += pc;
0x0002c878 ldr r3, [r6, 4] | r3 = *((r6 + 4));
0x0002c87a adds r2, r3, 1 | r2 = r3 + 1;
0x0002c87c str r2, [r6, 4] | *((r6 + 4)) = r2;
0x0002c87e cmp r1, 0 |
| if (r1 == 0) {
0x0002c880 bne.w 0x2c9d4 |
0x0002c884 ldr r0, [r4] | r0 = *(r4);
0x0002c886 mov.w r2, -1 | r2 = -1;
0x0002c88a str r1, [r4, 8] | *((r4 + 8)) = r1;
0x0002c88c str r2, [r4, 4] | *((r4 + 4)) = r2;
0x0002c88e cmp r0, 0 |
| if (r0 != 0) {
0x0002c890 beq.w 0x2c9d0 |
0x0002c894 bl 0xa65f4 | r0 = open_nocancel ();
0x0002c898 cmp.w r0, -1 |
0x0002c89c mov r8, r0 | r8 = r0;
| if (r0 == -1) {
0x0002c89e beq.w 0x2ca4e | goto label_46;
| }
0x0002c8a2 add r1, sp, 0x68 | r1 += var_68h;
0x0002c8a4 bl 0x9ea88 | r0 = fstat64_time64 ();
0x0002c8a8 mov sl, r0 | sl = r0;
0x0002c8aa cmp r0, 0 |
| if (r0 != 0) {
0x0002c8ac bne.w 0x2ca10 | goto label_8;
| }
0x0002c8b0 ldrd fp, r2, [sp, 0x90] | __asm ("ldrd fp, r2, [var_90h]");
0x0002c8b4 cmp.w fp, 0x2f |
0x0002c8b8 ite hi |
| if (fp <= 0x2f) {
0x0002c8ba movhi r3, 0 | r3 = 0;
| }
| if (fp > 0x2f) {
0x0002c8bc movls r3, 1 | r3 = 1;
| }
0x0002c8be cmp r0, r2 |
0x0002c8c0 it ne |
| if (r0 == r2) {
0x0002c8c2 orrne r3, r3, 1 | r3 |= 1;
| }
0x0002c8c6 cmp r3, 0 |
| if (r3 != 0) {
0x0002c8c8 bne.w 0x2ca10 | goto label_8;
| }
0x0002c8cc mov r1, fp | r1 = fp;
0x0002c8ce movs r3, 2 | r3 = 2;
0x0002c8d0 movs r2, 1 | r2 = 1;
0x0002c8d2 strd r8, r0, [sp] | __asm ("strd r8, r0, [sp]");
0x0002c8d6 bl 0xa9f88 | r0 = mmap ()
0x0002c8da adds r1, r0, 1 | r1 = r0 + 1;
0x0002c8dc mov r5, r0 | r5 = r0;
| if (r1 == r0) {
0x0002c8de beq.w 0x2cc48 | goto label_47;
| }
0x0002c8e2 mov r0, r8 | r0 = r8;
0x0002c8e4 bl 0xa64c4 | close_nocancel ();
0x0002c8e8 ldr r7, [r5] | r7 = *(r5);
0x0002c8ea movw r3, 0x12de |
0x0002c8ee movt r3, 0x9504 | r3 = 0x950412de;
0x0002c8f2 movw r2, 0x495 |
0x0002c8f6 movt r2, 0xde12 | r2 = 0xde120495;
0x0002c8fa subs r1, r7, r3 | r1 = r7 - r3;
0x0002c8fc it ne |
| if (r1 == r7) {
0x0002c8fe movne r1, 1 | r1 = 1;
| }
0x0002c900 cmp r7, r2 |
0x0002c902 it ne |
| if (r7 != r2) {
0x0002c904 cmpne r7, r3 | __asm ("cmpne r7, r3");
| }
| if (r7 != r2) {
0x0002c906 bne.w 0x2ca46 | goto label_48;
| }
0x0002c90a mov.w sl, 1 | sl = 1;
| label_11:
0x0002c90e movs r0, 0x68 | r0 = 0x68;
0x0002c910 str r1, [sp, 8] | var_8h = r1;
0x0002c912 blx 0x21354 | fcn_00021354 ();
0x0002c916 ldr r1, [sp, 8] | r1 = var_8h;
0x0002c918 mov r8, r0 | r8 = r0;
0x0002c91a cmp r0, 0 |
| if (r0 == 0) {
0x0002c91c beq.w 0x2d34a | goto label_49;
| }
0x0002c920 movw r2, 0x12de |
0x0002c924 movs r3, 0 | r3 = 0;
0x0002c926 movt r2, 0x9504 | r2 = 0x950412de;
0x0002c92a str r3, [r0, 0x10] | *((r0 + 0x10)) = r3;
0x0002c92c cmp r7, r2 |
0x0002c92e ldr r3, [r5, 4] | r3 = *((r5 + 4));
0x0002c930 str r0, [r4, 8] | *((r4 + 8)) = r0;
0x0002c932 strd r5, sl, [r0] | __asm ("strd r5, sl, [r0]");
0x0002c936 strd fp, r1, [r0, 8] | __asm ("strd fp, r1, [r0, 8]");
| if (r7 == r2) {
0x0002c93a beq.w 0x2ca54 | goto label_50;
| }
0x0002c93e rev r3, r3 | r3 = SWAP32 (r3);
0x0002c940 cmp.w r3, 0x20000 |
0x0002c944 mov r0, r3 | r0 = r3;
| if (r3 >= 0x20000) {
0x0002c946 bhs 0x2ca20 | goto label_6;
| }
0x0002c948 ldr r2, [r5, 0xc] | r2 = *((r5 + 0xc));
0x0002c94a ldr r6, [r5, 8] | r6 = *((r5 + 8));
0x0002c94c rev r2, r2 | r2 = SWAP32 (r2);
0x0002c94e add.w ip, r5, r2 |
0x0002c952 ldr r2, [r5, 0x10] | r2 = *((r5 + 0x10));
0x0002c954 rev r6, r6 | r6 = SWAP32 (r6);
0x0002c956 str.w r6, [r8, 0x14] | __asm ("str.w r6, [r8, 0x14]");
0x0002c95a rev r2, r2 | r2 = SWAP32 (r2);
0x0002c95c add r2, r5 | r2 += r5;
0x0002c95e strd ip, r2, [r8, 0x18] | __asm ("strd ip, r2, [r8, 0x18]");
0x0002c962 ldr r2, [r5, 0x14] | r2 = *((r5 + 0x14));
0x0002c964 rev r2, r2 | r2 = SWAP32 (r2);
0x0002c966 cmp r2, 2 |
0x0002c968 str r2, [sp, 0xc] | var_ch = r2;
0x0002c96a str.w r2, [r8, 0x2c] | __asm ("str.w r2, [r8, 0x2c]");
| if (r2 > 2) {
0x0002c96e bhi.w 0x2cab8 | goto label_51;
| }
| label_2:
0x0002c972 uxth r0, r0 | r0 = (int16_t) r0;
0x0002c974 movs r3, 0 | r3 = 0;
0x0002c976 str.w r1, [r8, 0x34] | __asm ("str.w r1, [r8, 0x34]");
0x0002c97a str.w r3, [r8, 0x30] | __asm ("str.w r3, [r8, 0x30]");
0x0002c97c adds r0, 0x30 | r0 += 0x30;
0x0002c97e cmp r0, 0 |
| if (r0 != 0) {
0x0002c980 bne 0x2ca20 | goto label_6;
| }
| label_3:
0x0002c982 movs r3, 0 | r3 = 0;
0x0002c984 strd r3, r3, [r8, 0x20] | __asm ("strd r3, r3, [r8, 0x20]");
0x0002c988 str.w r3, [r8, 0x28] | __asm ("str.w r3, [r8, 0x28]");
0x0002c98c add r3, sp, 0x60 | r3 += var_60h;
0x0002c98e str r3, [sp, 8] | var_8h = r3;
| label_13:
0x0002c990 movs r6, 0 | r6 = 0;
0x0002c992 add.w r0, r8, 0x40 | r0 = r8 + 0x40;
0x0002c996 mov r1, r6 | r1 = r6;
0x0002c998 strd r6, r6, [r8, 0x38] | __asm ("strd r6, r6, [r8, 0x38]");
0x0002c99c bl 0x61138 | pthread_rwlock_init ();
0x0002c9a0 ldr r3, [sp, 8] | r3 = var_8h;
0x0002c9a2 mov r1, sb | r1 = sb;
0x0002c9a4 ldr r2, [pc, 0x328] |
0x0002c9a6 mov r0, r4 | r0 = r4;
0x0002c9a8 str r3, [sp] | *(sp) = r3;
0x0002c9aa mov r3, r6 | r3 = r6;
0x0002c9ac add r2, pc | r2 = 0x59680;
0x0002c9ae bl 0x2bad4 | r0 = fcn_0002bad4 (r0, r1, r2, r3, r4, r5);
0x0002c9b2 adds r3, r0, 1 | r3 = r0 + 1;
0x0002c9b4 it eq |
| if (r3 != r0) {
0x0002c9b6 ldreq r0, [r8, 0x10] | r0 = *((r8 + 0x10));
| }
| if (r3 == r0) {
0x0002c9ba beq 0x2ca22 | goto label_12;
| }
0x0002c9bc add.w r2, r8, 0x64 | r2 = r8 + 0x64;
0x0002c9c0 add.w r1, r8, 0x60 | r1 = r8 + 0x60;
0x0002c9c4 bl 0x2ea2c | fcn_0002ea2c (r0, r1, r2);
0x0002c9c8 ldr r3, [pc, 0x308] |
0x0002c9ca add r3, pc |
0x0002c9cc ldr r3, [r3, 4] | r3 = *(0x596a6);
0x0002c9ce subs r3, 1 | r3--;
| }
| label_1:
0x0002c9d0 movs r2, 1 | r2 = 1;
0x0002c9d2 str r2, [r4, 4] | *((r4 + 4)) = r2;
| }
0x0002c9d4 ldr r0, [pc, 0x300] |
0x0002c9d6 add r0, pc | r0 = 0x596b2;
0x0002c9d8 str r3, [r0, 4] | *((r0 + 4)) = r3;
| if (r3 != 0) {
0x0002c9da cbz r3, 0x2c9e2 |
| label_0:
0x0002c9dc add sp, 0xdc |
0x0002c9de pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x0002c9e2 str r3, [r0, 8] | *((r0 + 8)) = r3;
0x0002c9e4 dmb ish | __asm ("dmb ish");
| do {
0x0002c9e8 ldrex r2, [r0] | __asm ("ldrex r2, [r0]");
0x0002c9ec strex r1, r3, [r0] | __asm ("strex r1, r3, [r0]");
0x0002c9f0 cmp r1, 0 |
0x0002c9f2 bne 0x2c9e8 |
| } while (r1 != 0);
0x0002c9f4 cmp r2, 1 |
| if (r2 <= 1) {
0x0002c9f6 ble 0x2c9dc | goto label_0;
| }
0x0002c9f8 bl 0x5a6c0 | lll_lock_wake_private ();
0x0002c9fc b 0x2c9dc | goto label_0;
| label_9:
0x0002c9fe adds r0, 1 | r0++;
| if (r0 == 1) {
0x0002ca00 bne 0x2ca10 |
0x0002ca02 ldr r3, [pc, 0x2bc] |
0x0002ca04 add r3, pc |
0x0002ca06 ldr r3, [r3] | r3 = *(0x596ca);
0x0002ca08 ldr r3, [r7, r3] | r3 = *((r7 + r3));
0x0002ca0a cmp r3, 4 |
| if (r3 == 4) {
0x0002ca0c beq.w 0x2cc5a | goto label_10;
| }
| }
| label_8:
0x0002ca10 mov r0, r8 | r0 = r8;
0x0002ca12 bl 0xa64c4 | close_nocancel ();
0x0002ca16 ldr r3, [pc, 0x2c4] |
0x0002ca18 add r3, pc |
0x0002ca1a ldr r3, [r3, 4] | r3 = *(0x596fe);
0x0002ca1c subs r3, 1 | r3--;
0x0002ca1e b 0x2c9d0 | goto label_1;
| do {
| label_6:
0x0002ca20 movs r0, 0 | r0 = 0;
| label_12:
0x0002ca22 blx 0x212d4 | fcn_000212d4 ();
0x0002ca26 cmp.w sl, 0 |
| if (sl != 0) {
0x0002ca2a bne 0x2caae | goto label_52;
| }
0x0002ca2c mov r0, r5 | r0 = r5;
0x0002ca2e blx 0x212d4 | fcn_000212d4 ();
| label_5:
0x0002ca32 mov r0, r8 | r0 = r8;
0x0002ca34 blx 0x212d4 | fcn_000212d4 ();
0x0002ca38 ldr r3, [pc, 0x2a4] |
0x0002ca3a movs r2, 0 | r2 = 0;
0x0002ca3c str r2, [r4, 8] | *((r4 + 8)) = r2;
0x0002ca3e add r3, pc |
0x0002ca40 ldr r3, [r3, 4] | r3 = *(0x59726);
0x0002ca42 subs r3, 1 | r3--;
0x0002ca44 b 0x2c9d0 | goto label_1;
| label_48:
0x0002ca46 mov r1, fp | r1 = fp;
0x0002ca48 mov r0, r5 | r0 = r5;
0x0002ca4a bl 0xaa040 | munmap ();
| label_46:
0x0002ca4e ldr r3, [r6, 4] | r3 = *((r6 + 4));
0x0002ca50 subs r3, 1 | r3--;
0x0002ca52 b 0x2c9d0 | goto label_1;
| label_50:
0x0002ca54 cmp.w r3, 0x20000 |
0x0002ca58 mov r0, r3 | r0 = r3;
0x0002ca5a bhs 0x2ca20 |
| } while (r3 >= 0x20000);
0x0002ca5c ldr r2, [r5, 0xc] | r2 = *((r5 + 0xc));
0x0002ca5e adds r6, r5, r2 | r6 = r5 + r2;
0x0002ca60 ldr r2, [r5, 0x10] | r2 = *((r5 + 0x10));
0x0002ca62 add.w ip, r2, r5 |
0x0002ca66 ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x0002ca68 str.w ip, [r8, 0x1c] | __asm ("str.w ip, [r8, 0x1c]");
0x0002ca6c strd r2, r6, [r8, 0x14] | __asm ("strd r2, r6, [r8, 0x14]");
0x0002ca70 ldr r2, [r5, 0x14] | r2 = *((r5 + 0x14));
0x0002ca72 cmp r2, 2 |
0x0002ca74 str r2, [sp, 0xc] | var_ch = r2;
0x0002ca76 str.w r2, [r8, 0x2c] | __asm ("str.w r2, [r8, 0x2c]");
| if (r2 < 2) {
0x0002ca7a bls.w 0x2c972 | goto label_2;
| }
0x0002ca7e ldr r2, [r5, 0x18] | r2 = *((r5 + 0x18));
0x0002ca80 uxth r3, r3 | r3 = (int16_t) r3;
0x0002ca82 str.w r1, [r8, 0x34] | __asm ("str.w r1, [r8, 0x34]");
0x0002ca86 adds r2, r5, r2 | r2 = r5 + r2;
0x0002ca88 str r2, [sp, 0x2c] | var_2ch = r2;
0x0002ca8a str.w r2, [r8, 0x30] | __asm ("str.w r2, [r8, 0x30]");
0x0002ca8c movs r0, 0x30 | r0 = 0x30;
0x0002ca8e cmp r3, 0 |
| if (r3 == 0) {
0x0002ca90 beq.w 0x2c982 | goto label_3;
| }
0x0002ca94 ldr r3, [r5, 0x24] | r3 = *((r5 + 0x24));
0x0002ca96 str r3, [sp, 0x18] | var_18h = r3;
0x0002ca98 cmp r3, 0 |
| if (r3 == 0) {
0x0002ca9a beq.w 0x2c982 | goto label_3;
| }
0x0002ca9e ldr r3, [r5, 0x1c] | r3 = *((r5 + 0x1c));
0x0002caa0 str r3, [sp, 0x24] | var_24h = r3;
0x0002caa2 ldr r3, [r5, 0x20] | r3 = *((r5 + 0x20));
0x0002caa4 b 0x2cae6 | goto label_53;
| label_45:
0x0002caa6 mov r0, r3 | r0 = r3;
0x0002caa8 bl 0x5a624 | lll_lock_wait_private ();
0x0002caac b 0x2c868 | goto label_4;
| label_52:
0x0002caae mov r1, fp | r1 = fp;
0x0002cab0 mov r0, r5 | r0 = r5;
0x0002cab2 bl 0xaa040 | munmap ();
0x0002cab6 b 0x2ca32 | goto label_5;
| label_51:
0x0002cab8 ldr r2, [r5, 0x18] | r2 = *((r5 + 0x18));
0x0002caba uxth r3, r3 | r3 = (int16_t) r3;
0x0002cabc str.w r1, [r8, 0x34] | __asm ("str.w r1, [r8, 0x34]");
0x0002cac0 rev r2, r2 | r2 = SWAP32 (r2);
0x0002cac2 adds r2, r5, r2 | r2 = r5 + r2;
0x0002cac4 str r2, [sp, 0x2c] | var_2ch = r2;
0x0002cac6 str.w r2, [r8, 0x30] | __asm ("str.w r2, [r8, 0x30]");
0x0002caca cmp r3, 0 |
| if (r3 == 0) {
0x0002cacc beq.w 0x2c982 | goto label_3;
| }
0x0002cad0 ldr r3, [r5, 0x24] | r3 = *((r5 + 0x24));
0x0002cad2 rev r2, r3 | r3 = SWAP32 (r2);
0x0002cad4 str r2, [sp, 0x18] | var_18h = r2;
0x0002cad6 cmp r3, 0 |
| if (r3 == 0) {
0x0002cad8 beq.w 0x2c982 | goto label_3;
| }
0x0002cadc ldr r3, [r5, 0x1c] | r3 = *((r5 + 0x1c));
0x0002cade rev r3, r3 | r3 = SWAP32 (r3);
0x0002cae0 str r3, [sp, 0x24] | var_24h = r3;
0x0002cae2 ldr r3, [r5, 0x20] | r3 = *((r5 + 0x20));
0x0002cae4 rev r3, r3 | r3 = SWAP32 (r3);
| label_53:
0x0002cae6 ldr r6, [sp, 0x24] | r6 = var_24h;
0x0002cae8 adds r3, r5, r3 | r3 = r5 + r3;
0x0002caea movs r1, 4 | r1 = 4;
0x0002caec str r3, [sp, 8] | var_8h = r3;
0x0002caee mov r0, r6 | r0 = r6;
0x0002caf0 blx 0x212c4 | fcn_000212c4 ();
0x0002caf4 str r0, [sp, 0x20] | var_20h = r0;
0x0002caf6 cmp r0, 0 |
| if (r0 == 0) {
0x0002caf8 beq 0x2ca20 | goto label_6;
| }
0x0002cafa cmp r6, 0 |
| if (r6 == 0) {
0x0002cafc beq.w 0x2cd14 | goto label_54;
| }
0x0002cb00 ldr r2, [pc, 0x1e0] |
0x0002cb02 movw ip, 0x12de |
0x0002cb04 cmp r4, 0xde |
0x0002cb06 ldr r3, [pc, 0x1e0] |
0x0002cb08 movt ip, 0x9504 | ip = 0x950412de;
0x0002cb0c ldr r6, [sp, 8] | r6 = var_8h;
0x0002cb0e movs r1, 0 | r1 = 0;
0x0002cb10 add r2, pc | r2 = 0x597f8;
0x0002cb12 str.w r8, [sp, 0x10] | __asm ("str.w r8, [var_10h]");
0x0002cb16 str r2, [sp, 0x28] | var_28h = r2;
0x0002cb18 add r3, pc | r3 = 0x59806;
0x0002cb1a ldr r2, [pc, 0x1d0] |
0x0002cb1c add.w lr, r6, 4 | lr = r6 + 4;
0x0002cb20 ldr.w r8, [sp, 0x24] | r8 = var_24h;
0x0002cb24 str r4, [sp, 0x14] | var_14h = r4;
0x0002cb26 add r2, pc | r2 = 0x59818;
0x0002cb28 str.w sb, [sp, 0x1c] | __asm ("str.w sb, [var_1ch]");
0x0002cb2c str r2, [sp, 0x30] | var_30h = r2;
0x0002cb2e ldr r2, [pc, 0x1c0] |
0x0002cb30 str r3, [sp, 8] | var_8h = r3;
0x0002cb32 add r2, pc | r2 = 0x59828;
0x0002cb34 str r2, [sp, 0x34] | var_34h = r2;
0x0002cb36 ldr r2, [pc, 0x1bc] |
0x0002cb38 add r2, pc | r2 = 0x59832;
0x0002cb3a str r2, [sp, 0x38] | var_38h = r2;
0x0002cb3c ldr r2, [pc, 0x1b8] |
0x0002cb3e add r2, pc | r2 = 0x5983a;
0x0002cb40 str r2, [sp, 0x3c] | var_3ch = r2;
0x0002cb42 ldr r2, [pc, 0x1b8] |
0x0002cb44 add r2, pc | r2 = 0x59846;
0x0002cb46 str r2, [sp, 0x40] | var_40h = r2;
0x0002cb48 ldr r2, [pc, 0x1b4] |
0x0002cb4a add r2, pc | r2 = 0x5984e;
0x0002cb4c str r2, [sp, 0x44] | var_44h = r2;
0x0002cb4e ldr r2, [sp, 0x20] | r2 = var_20h;
0x0002cb50 subs r0, r2, 4 | r0 = r2 - 4;
0x0002cb52 b 0x2cb70 |
| while (sb != 0x50) {
0x0002cb54 cmp.w sb, 0x49 |
| if (sb == 0x49) {
0x0002cb58 bne 0x2cb64 |
0x0002cb5a ldrb r3, [r3, 1] | r3 = *((r3 + 1));
0x0002cb5c cmp r3, 0 |
0x0002cb5e ldr r3, [sp, 8] | r3 = var_8h;
0x0002cb60 it eq |
| if (r3 == 0) {
0x0002cb62 moveq r2, r3 | r2 = r3;
| goto label_7;
| }
| }
| label_7:
0x0002cb64 adds r1, 1 | r1++;
0x0002cb66 str r2, [r0, 4]! | *((r0 += 4)) = r2;
0x0002cb6a cmp r1, r8 |
| if (r1 == r8) {
0x0002cb6c beq.w 0x2cd0c | goto label_55;
| }
0x0002cb70 ldr.w r2, [r6, r1, lsl 3] | offset_0 = r1 << 3;
| r2 = *((r6 + offset_0));
0x0002cb74 cmp r7, ip |
0x0002cb76 ldr.w r3, [lr, r1, lsl 3] | offset_1 = r1 << 3;
| r3 = *((lr + offset_1));
0x0002cb7a itt ne |
| if (r7 != ip) {
0x0002cb7c revne r2, r2 | __asm ("revne r2, r2");
| }
| if (r7 != ip) {
0x0002cb7e revne r3, r3 | __asm ("revne r3, r3");
| }
0x0002cb80 add r3, r5 | r3 += r5;
0x0002cb82 cmp r2, 0 |
| if (r2 == 0) {
0x0002cb84 beq.w 0x2ccb0 | goto label_56;
| }
0x0002cb88 add r2, r3 | r2 += r3;
0x0002cb8a ldrb r2, [r2, -0x1] | r2 = *((r2 - 0x1));
0x0002cb8e cmp r2, 0 |
| if (r2 != 0) {
0x0002cb90 bne.w 0x2ccb0 | goto label_56;
| }
0x0002cb94 ldrb.w sb, [r3] | sb = *(r3);
0x0002cb98 cmp.w sb, 0x50 |
0x0002cb9c bne 0x2cb54 |
| }
0x0002cb9e ldrb.w sb, [r3, 1] | sb = *((r3 + 1));
0x0002cba2 cmp.w sb, 0x52 |
| if (sb != 0x52) {
0x0002cba6 bne 0x2cb64 | goto label_7;
| }
0x0002cba8 ldrb.w sb, [r3, 2] | sb = *((r3 + 2));
0x0002cbac cmp.w sb, 0x49 |
| if (sb != 0x49) {
0x0002cbb0 bne 0x2cb64 | goto label_7;
| }
0x0002cbb2 ldrb.w sb, [r3, 3] | sb = *((r3 + 3));
0x0002cbb6 cmp.w sb, 0x69 |
0x0002cbba it ne |
| if (sb != 0x69) {
0x0002cbbc cmpne sb, 0x64 | __asm ("cmpne sb, 0x64");
| }
0x0002cbc0 ite eq |
| if (sb != 0x69) {
0x0002cbc2 moveq r2, 1 | r2 = 1;
| }
| if (sb == 0x69) {
0x0002cbc4 movne r2, 0 | r2 = 0;
| }
0x0002cbc6 str r2, [sp, 0x48] | var_48h = r2;
| if (sb == 0x69) {
0x0002cbc8 beq 0x2cbea | goto label_57;
| }
0x0002cbca cmp.w sb, 0x58 |
| if (sb == 0x58) {
0x0002cbce beq 0x2cbea | goto label_57;
| }
0x0002cbd0 sub.w r2, sb, 0x6f | r2 = sb - 0x6f;
0x0002cbd4 uxtb r2, r2 | r2 = (int8_t) r2;
0x0002cbd6 cmp r2, 9 |
0x0002cbd8 mov r4, r2 | r4 = r2;
| if (r2 > 9) {
0x0002cbda bhi.w 0x2cfea | goto label_58;
| }
0x0002cbde movw r2, 0x241 | r2 = 0x241;
0x0002cbe2 lsrs r2, r4 | r2 >>= r4;
0x0002cbe4 ands r2, r2, 1 | r2 &= 1;
| if (r2 == r2) {
0x0002cbe8 beq 0x2cb64 | goto label_7;
| }
| label_57:
0x0002cbea ldrb r2, [r3, 4] | r2 = *((r3 + 4));
0x0002cbec cmp r2, 0x38 |
| if (r2 == 0x38) {
0x0002cbee beq.w 0x2cf1a | goto label_59;
| }
0x0002cbf2 cmp r2, 0x31 |
| if (r2 == 0x31) {
0x0002cbf4 beq.w 0x2cf78 | goto label_60;
| }
0x0002cbf8 cmp r2, 0x33 |
| if (r2 != 0x33) {
0x0002cbfa bne.w 0x2ce6e | goto label_61;
| }
0x0002cbfe ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002cc00 cmp r2, 0x32 |
0x0002cc02 it ne |
| if (r2 != 0x32) {
0x0002cc04 movne r2, 0 | r2 = 0;
| goto label_62;
| }
| if (r2 != 0x32) {
| label_62:
0x0002cc06 bne 0x2cb64 | goto label_7;
| }
0x0002cc08 ldrb r3, [r3, 6] | r3 = *((r3 + 6));
0x0002cc0a cmp r3, 0 |
| if (r3 != 0) {
0x0002cc0c bne.w 0x2d2a2 | goto label_63;
| }
0x0002cc10 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002cc14 cmp.w sb, 0x14 |
| if (sb > 0x14) {
0x0002cc18 bhi 0x2ccaa | goto label_64;
| }
| /* switch table (22 cases) at 0x2cc1e */
0x0002cc1a tbh [pc, sb, lsl 1] | __asm ("tbh [pc, sb, lsl 1]");
| label_47:
0x0002cc48 mov r0, fp | r0 = fp;
0x0002cc4a blx 0x21354 | r0 = fcn_00021354 ();
0x0002cc4e mov r5, r0 | r5 = r0;
0x0002cc50 cmp r0, 0 |
| if (r0 == 0) {
0x0002cc52 beq.w 0x2ca10 | goto label_8;
| }
0x0002cc56 mov r6, fp | r6 = fp;
0x0002cc58 str r0, [sp, 8] | var_8h = r0;
| label_10:
0x0002cc5a mov r2, r6 | r2 = r6;
0x0002cc5c mov r1, r5 | r1 = r5;
0x0002cc5e mov r0, r8 | r0 = r8;
0x0002cc60 bl 0xa6780 | r0 = read_nocancel ();
0x0002cc64 cmp r0, 0 |
| if (r0 <= 0) {
0x0002cc66 ble.w 0x2c9fe | goto label_9;
| }
0x0002cc6a subs r6, r6, r0 | r6 -= r0;
0x0002cc6c add r5, r0 | r5 += r0;
| if (r6 != r6) {
0x0002cc6e bne 0x2cc5a | goto label_10;
| }
0x0002cc70 ldr r5, [sp, 8] | r5 = var_8h;
0x0002cc72 mov r0, r8 | r0 = r8;
0x0002cc74 bl 0xa64c4 | close_nocancel ();
0x0002cc78 movw r3, 0x12de |
0x0002cc7c movw r2, 0x495 |
0x0002cc80 ldr r7, [r5] | r7 = *(r5);
0x0002cc82 movt r3, 0x9504 | r3 = 0x950412de;
0x0002cc86 movt r2, 0xde12 | r2 = 0xde120495;
0x0002cc8a subs r1, r7, r3 | r1 = r7 - r3;
0x0002cc8c it ne |
| if (r1 == r7) {
0x0002cc8e movne r1, 1 | r1 = 1;
| }
0x0002cc90 cmp r7, r2 |
0x0002cc92 it ne |
| if (r7 == r2) {
0x0002cc94 cmpne r7, r3 | __asm ("cmpne r7, r3");
| goto label_65;
| }
| if (r7 == r2) {
| label_65:
0x0002cc96 beq.w 0x2c90e | goto label_11;
| }
0x0002cc9a mov r0, r5 | r0 = r5;
0x0002cc9c blx 0x212d4 | fcn_000212d4 ();
0x0002cca0 ldr r3, [pc, 0x60] |
0x0002cca2 add r3, pc |
0x0002cca4 ldr r3, [r3, 4] | r3 = *(0x599ae);
0x0002cca6 subs r3, 1 | r3--;
0x0002cca8 b 0x2c9d0 | goto label_1;
| label_64:
0x0002ccaa ldr r2, [pc, 0x5c] |
0x0002ccac add r2, pc | r2 = 0x599ba;
0x0002ccae b 0x2cb64 | goto label_7;
| label_56:
0x0002ccb0 ldr r0, [sp, 0x20] | r0 = var_20h;
0x0002ccb2 ldrd r8, r4, [sp, 0x10] | __asm ("ldrd r8, r4, [var_14h]");
0x0002ccb6 blx 0x212d4 | fcn_000212d4 ();
0x0002ccba movs r0, 0 | r0 = 0;
0x0002ccbc b 0x2ca22 | goto label_12;
| label_55:
0x0002cd0c ldrd r8, r4, [sp, 0x10] | __asm ("ldrd r8, r4, [var_14h]");
0x0002cd10 ldr.w sb, [sp, 0x1c] | sb = var_1ch;
| label_54:
0x0002cd14 movw r1, 0x12de |
0x0002cd18 ldrd r3, r2, [r5, 0x28] | __asm ("ldrd r3, r2, [r5, 0x28]");
0x0002cd1c movt r1, 0x9504 | r1 = 0x950412de;
0x0002cd20 cmp r7, r1 |
| if (r7 == r1) {
0x0002cd22 beq.w 0x2ce6a | goto label_66;
| }
0x0002cd26 rev r3, r3 | r3 = SWAP32 (r3);
0x0002cd28 rev r2, r2 | r2 = SWAP32 (r2);
0x0002cd2a add r3, r5 | r3 += r5;
| label_21:
0x0002cd2c ldr r1, [sp, 0xc] | r1 = var_ch;
0x0002cd2e movw r6, 0x12de |
0x0002cd32 str.w sb, [sp, 0x48] | __asm ("str.w sb, [var_48h]");
0x0002cd36 movt r6, 0x9504 | r6 = 0x950412de;
0x0002cd3a ldr.w sb, [sp, 0x20] | sb = var_20h;
0x0002cd3e adds r2, r5, r2 | r2 = r5 + r2;
0x0002cd40 str.w r8, [sp, 0x40] | __asm ("str.w r8, [var_40h]");
0x0002cd44 movs r0, 0 | r0 = 0;
0x0002cd46 lsls r1, r1, 2 | r1 <<= 2;
0x0002cd48 ldr.w r8, [sp, 0x24] | r8 = var_24h;
0x0002cd4c str r4, [sp, 0x24] | var_24h = r4;
0x0002cd4e mov r4, r6 | r4 = r6;
0x0002cd50 str r3, [sp, 0x38] | var_38h = r3;
0x0002cd52 strd r2, r3, [sp, 0x10] | __asm ("strd r2, r3, [var_14h]");
0x0002cd56 add r3, sp, 0x60 | r3 += var_60h;
0x0002cd58 str r2, [sp, 0x50] | var_50h = r2;
0x0002cd5a str r1, [sp, 0x4c] | var_4ch = r1;
0x0002cd5c str r0, [sp, 0x28] | var_28h = r0;
0x0002cd5e strd r0, r1, [sp, 0x30] | __asm ("strd r0, r1, [var_30h]");
0x0002cd62 str r3, [sp, 8] | var_8h = r3;
0x0002cd64 str.w sl, [sp, 0x3c] | __asm ("str.w sl, [var_3ch]");
0x0002cd68 str r5, [sp, 0x1c] | var_1ch = r5;
0x0002cd6a str.w fp, [sp, 0x44] | __asm ("str.w fp, [var_44h]");
0x0002cd6c add sp, 0x110 |
| do {
0x0002cd6e ldr.w sl, [sp, 8] | sl = var_8h;
0x0002cd72 movs r6, 0 | r6 = 0;
| label_15:
0x0002cd74 cmp r7, r4 |
| if (r7 == r4) {
0x0002cd76 beq 0x2cdf2 | goto label_67;
| }
0x0002cd78 cmp r6, 0 |
| if (r6 == 0) {
0x0002cd7a beq 0x2ce5e | goto label_68;
| }
0x0002cd7c ldr r3, [sp, 0x10] | r3 = var_10h;
0x0002cd7e ldr r3, [r3] | r3 = *(r3);
| label_19:
0x0002cd80 rev.w fp, r3 | r3 = SWAPundefined (fp);
0x0002cd84 ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x0002cd86 add fp, r3 |
0x0002cd88 ldr.w r0, [fp, 8] | r0 = *(arg_8h);
0x0002cd8c adds r5, r0, 1 | r5 = r0 + 1;
0x0002cd8e it ne |
| if (r5 == r0) {
0x0002cd90 movne r5, 1 | r5 = 1;
| }
| label_14:
0x0002cd92 cmp r5, 0 |
| if (r5 != 0) {
0x0002cd94 bne 0x2ce10 | goto label_69;
| }
| label_17:
0x0002cd96 str r5, [sl], 4 | *(sl) = r5;
| sl += 4;
0x0002cd9a cmp r6, 0 |
| if (r6 == 0) {
0x0002cd9c beq 0x2ce0c | goto label_70;
| }
0x0002cd9e ldr r3, [sp, 0x30] | r3 = var_30h;
0x0002cda0 adds r3, 1 | r3++;
0x0002cda2 str r3, [sp, 0x30] | var_30h = r3;
0x0002cda4 ldrd r3, r2, [sp, 0x60] | __asm ("ldrd r3, r2, [var_60h]");
0x0002cda8 add r3, r2 | r3 += r2;
0x0002cdaa ldr r2, [sp, 0x34] | r2 = var_34h;
0x0002cdac add r2, r3 | r2 += r3;
0x0002cdae str r2, [sp, 0x34] | var_34h = r2;
| label_16:
0x0002cdb0 ldr r2, [sp, 0x14] | r2 = var_14h;
0x0002cdb2 ldr r3, [sp, 0x28] | r3 = var_28h;
0x0002cdb4 adds r2, 4 | r2 += 4;
0x0002cdb6 str r2, [sp, 0x14] | var_14h = r2;
0x0002cdb8 adds r3, 1 | r3++;
0x0002cdba ldr r2, [sp, 0x10] | r2 = var_10h;
0x0002cdbc str r3, [sp, 0x28] | var_28h = r3;
0x0002cdbe adds r2, 4 | r2 += 4;
0x0002cdc0 str r2, [sp, 0x10] | var_10h = r2;
0x0002cdc2 ldr r2, [sp, 0x18] | r2 = var_18h;
0x0002cdc4 cmp r3, r2 |
0x0002cdc6 blo 0x2cd6e |
| } while (r3 <= r2);
0x0002cdc8 ldr r3, [sp, 0x30] | r3 = var_30h;
0x0002cdca ldr.w sl, [sp, 0x3c] | sl = var_3ch;
0x0002cdce ldr r5, [sp, 0x1c] | r5 = var_1ch;
0x0002cdd0 ldr.w r8, [sp, 0x40] | r8 = var_40h;
0x0002cdd4 ldr r4, [sp, 0x24] | r4 = var_24h;
0x0002cdd6 ldrd fp, sb, [sp, 0x44] | __asm ("ldrd fp, sb, [var_48h]");
0x0002cdda cmp r3, 0 |
| if (r3 != 0) {
0x0002cddc bne.w 0x2cfee | goto label_71;
| }
0x0002cde0 ldr r3, [sp, 0x30] | r3 = var_30h;
0x0002cde2 strd r3, r3, [r8, 0x20] | __asm ("strd r3, r3, [r8, 0x20]");
0x0002cde6 str.w r3, [r8, 0x28] | __asm ("str.w r3, [r8, 0x28]");
| label_26:
0x0002cdea ldr r0, [sp, 0x20] | r0 = var_20h;
0x0002cdec blx 0x212d4 | fcn_000212d4 ();
0x0002cdf0 b 0x2c990 | goto label_13;
| label_67:
0x0002cdf2 cmp r6, 0 |
| if (r6 == 0) {
0x0002cdf4 beq 0x2ce64 | goto label_72;
| }
0x0002cdf6 ldr r3, [sp, 0x10] | r3 = var_10h;
0x0002cdf8 ldr r3, [r3] | r3 = *(r3);
| label_20:
0x0002cdfa ldr r2, [sp, 0x1c] | r2 = var_1ch;
0x0002cdfc add.w fp, r2, r3 |
0x0002ce00 ldr.w r0, [fp, 8] | r0 = *(arg_8h);
0x0002ce04 adds r5, r0, 1 | r5 = r0 + 1;
0x0002ce06 it ne |
| if (r5 == r0) {
0x0002ce08 movne r5, 1 | r5 = 1;
| }
0x0002ce0a b 0x2cd92 | goto label_14;
| label_70:
0x0002ce0c movs r6, 1 | r6 = 1;
0x0002ce0e b 0x2cd74 | goto label_15;
| label_69:
0x0002ce10 movs r0, 0 | r0 = 0;
0x0002ce12 add.w fp, fp, 0xc |
0x0002ce16 mov r5, r0 | r5 = r0;
0x0002ce18 b 0x2ce2c | goto label_73;
| label_18:
0x0002ce1a ldr.w r0, [sb, r3, lsl 2] | offset_2 = r3 << 2;
| r0 = *((sb + offset_2));
0x0002ce1e add.w fp, fp, 8 |
0x0002ce22 cmp r0, 0 |
| if (r0 == 0) {
0x0002ce24 beq 0x2cdb0 | goto label_16;
| }
0x0002ce26 bl 0x6a8c0 | r0 = strlen ();
0x0002ce2a add r5, r0 | r5 += r0;
| label_73:
0x0002ce2c ldrd r2, r3, [fp, -0x8] | __asm ("ldrd r2, r3, [fp, -0x8]");
0x0002ce30 cmp r7, r4 |
0x0002ce32 ittte ne |
| if (r7 != r4) {
0x0002ce34 revne r2, r2 | __asm ("revne r2, r2");
| }
| if (r7 != r4) {
0x0002ce36 revne r3, r3 | __asm ("revne r3, r3");
| }
| if (r7 == r4) {
0x0002ce38 addne r5, r5, r2 | r5 += r2;
| }
| if (r7 != r4) {
0x0002ce3a addeq r5, r5, r2 | r5 += r2;
| }
0x0002ce3c adds r2, r3, 1 | r2 = r3 + 1;
| if (r2 == r3) {
0x0002ce3e beq 0x2cd96 | goto label_17;
| }
0x0002ce40 cmp r3, r8 |
| if (r3 <= r8) {
0x0002ce42 blo 0x2ce1a | goto label_18;
| }
0x0002ce44 ldr r0, [sp, 0x20] | r0 = var_20h;
0x0002ce46 ldr.w sl, [sp, 0x3c] | sl = var_3ch;
0x0002ce4a ldr r5, [sp, 0x1c] | r5 = var_1ch;
0x0002ce4c ldr.w r8, [sp, 0x40] | r8 = var_40h;
0x0002ce50 ldr r4, [sp, 0x24] | r4 = var_24h;
0x0002ce52 ldr.w fp, [sp, 0x44] | fp = var_44h;
0x0002ce56 blx 0x212d4 | fcn_000212d4 ();
0x0002ce5a movs r0, 0 | r0 = 0;
0x0002ce5c b 0x2ca22 | goto label_12;
| label_68:
0x0002ce5e ldr r3, [sp, 0x14] | r3 = var_14h;
0x0002ce60 ldr r3, [r3] | r3 = *(r3);
0x0002ce62 b 0x2cd80 | goto label_19;
| label_72:
0x0002ce64 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0002ce66 ldr r3, [r3] | r3 = *(r3);
0x0002ce68 b 0x2cdfa | goto label_20;
| label_66:
0x0002ce6a add r3, r5 | r3 += r5;
0x0002ce6c b 0x2cd2c | goto label_21;
| label_61:
0x0002ce6e cmp r2, 0x36 |
| if (r2 != 0x36) {
0x0002ce70 bne 0x2cec6 | goto label_74;
| }
0x0002ce72 ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002ce74 cmp r2, 0x34 |
0x0002ce76 it ne |
| if (r2 != 0x34) {
0x0002ce78 movne r2, 0 | r2 = 0;
| goto label_75;
| }
| if (r2 != 0x34) {
| label_75:
0x0002ce7a bne.w 0x2cb64 | goto label_7;
| }
0x0002ce7e ldrb r3, [r3, 6] | r3 = *((r3 + 6));
0x0002ce80 cmp r3, 0 |
| if (r3 != 0) {
0x0002ce82 bne.w 0x2d29a | goto label_76;
| }
0x0002ce86 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002ce8a cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002ce8e bhi 0x2cebe |
| /* switch table (22 cases) at 0x2ce94 */
0x0002ce90 tbh [pc, sb, lsl 1] | __asm ("tbh [pc, sb, lsl 1]");
| }
0x0002cebe ldr.w r2, [pc, 0x8e0] | r2 = *(0x0002d7a0);
0x0002cec2 add r2, pc | r2 += pc;
0x0002cec4 b 0x2cb64 | goto label_7;
| label_74:
0x0002cec6 cmp r2, 0x4c |
| if (r2 != 0x4c) {
0x0002cec8 bne 0x2cee2 | goto label_77;
| }
0x0002ceca ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002cecc cmp r2, 0x45 |
0x0002cece it ne |
| if (r2 != 0x45) {
0x0002ced0 movne r2, 0 | r2 = 0;
| goto label_78;
| }
| if (r2 != 0x45) {
| label_78:
0x0002ced2 bne.w 0x2cb64 | goto label_7;
| }
0x0002ced6 ldrb r2, [r3, 6] | r2 = *((r3 + 6));
0x0002ced8 cmp r2, 0x41 |
| if (r2 == 0x41) {
0x0002ceda beq.w 0x2d2e8 | goto label_79;
| }
0x0002cede movs r2, 0 | r2 = 0;
0x0002cee0 b 0x2cb64 | goto label_7;
| label_77:
0x0002cee2 cmp r2, 0x46 |
| if (r2 != 0x46) {
0x0002cee4 bne 0x2cefe | goto label_80;
| }
0x0002cee6 ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002cee8 cmp r2, 0x41 |
0x0002ceea it ne |
| if (r2 != 0x41) {
0x0002ceec movne r2, 0 | r2 = 0;
| goto label_81;
| }
| if (r2 != 0x41) {
| label_81:
0x0002ceee bne.w 0x2cb64 | goto label_7;
| }
0x0002cef2 ldrb r2, [r3, 6] | r2 = *((r3 + 6));
0x0002cef4 cmp r2, 0x53 |
| if (r2 == 0x53) {
0x0002cef6 beq.w 0x2d2f2 | goto label_82;
| }
0x0002cefa movs r2, 0 | r2 = 0;
0x0002cefc b 0x2cb64 | goto label_7;
| label_80:
0x0002cefe cmp r2, 0x4d |
| if (r2 != 0x4d) {
0x0002cf00 bne 0x2cfcc | goto label_83;
| }
0x0002cf02 ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002cf04 cmp r2, 0x41 |
0x0002cf06 it ne |
| if (r2 != 0x41) {
0x0002cf08 movne r2, 0 | r2 = 0;
| goto label_84;
| }
| if (r2 != 0x41) {
| label_84:
0x0002cf0a bne.w 0x2cb64 | goto label_7;
| }
0x0002cf0e ldrb r2, [r3, 6] | r2 = *((r3 + 6));
0x0002cf10 cmp r2, 0x58 |
| if (r2 == 0x58) {
0x0002cf12 beq.w 0x2d2a6 | goto label_85;
| }
0x0002cf16 movs r2, 0 | r2 = 0;
0x0002cf18 b 0x2cb64 | goto label_7;
| label_59:
0x0002cf1a ldrb r3, [r3, 5] | r3 = *((r3 + 5));
0x0002cf1c movs r2, 0 | r2 = 0;
0x0002cf1e cmp r3, 0 |
| if (r3 != 0) {
0x0002cf20 bne.w 0x2cb64 | goto label_7;
| }
0x0002cf24 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002cf28 cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002cf2c bhi 0x2cf48 |
| /* switch table (21 cases) at 0x2cf32 */
0x0002cf2e tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| }
0x0002cf48 ldr.w r2, [pc, 0x858] |
0x0002cf4c add r2, pc | r2 = 0x5a6f4;
0x0002cf4e b 0x2cb64 | goto label_7;
0x0002cf50 ldr.w r2, [pc, 0x854] |
0x0002cf54 add r2, pc | r2 = 0x5a700;
0x0002cf56 b 0x2cb64 | goto label_7;
0x0002cf58 ldr.w r2, [pc, 0x850] |
0x0002cf5c add r2, pc | r2 = 0x5a70c;
0x0002cf5e b 0x2cb64 | goto label_7;
0x0002cf60 ldr.w r2, [pc, 0x84c] |
0x0002cf64 add r2, pc | r2 = 0x5a718;
0x0002cf66 b 0x2cb64 | goto label_7;
0x0002cf68 ldr.w r2, [pc, 0x848] |
0x0002cf6c add r2, pc | r2 = 0x5a724;
0x0002cf6e b 0x2cb64 | goto label_7;
0x0002cf70 ldr.w r2, [pc, 0x844] |
0x0002cf74 add r2, pc | r2 = 0x5a730;
0x0002cf76 b 0x2cb64 | goto label_7;
| label_60:
0x0002cf78 ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002cf7a cmp r2, 0x36 |
0x0002cf7c it ne |
| if (r2 != 0x36) {
0x0002cf7e movne r2, 0 | r2 = 0;
| goto label_86;
| }
| if (r2 != 0x36) {
| label_86:
0x0002cf80 bne.w 0x2cb64 | goto label_7;
| }
0x0002cf84 ldrb r3, [r3, 6] | r3 = *((r3 + 6));
0x0002cf86 cmp r3, 0 |
| if (r3 != 0) {
0x0002cf88 bne.w 0x2d29e | goto label_87;
| }
0x0002cf8c sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002cf90 cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002cf94 bhi 0x2cfc4 |
| /* switch table (22 cases) at 0x2cf9a */
0x0002cf96 tbh [pc, sb, lsl 1] | __asm ("tbh [pc, sb, lsl 1]");
| }
0x0002cfc4 ldr.w r2, [pc, 0x7f4] |
0x0002cfc8 add r2, pc | r2 = 0x5a788;
0x0002cfca b 0x2cb64 | goto label_7;
| label_83:
0x0002cfcc cmp r2, 0x50 |
| if (r2 != 0x50) {
0x0002cfce bne.w 0x2d376 | goto label_88;
| }
0x0002cfd2 ldrb r2, [r3, 5] | r2 = *((r3 + 5));
0x0002cfd4 cmp r2, 0x54 |
0x0002cfd6 it ne |
| if (r2 != 0x54) {
0x0002cfd8 movne r2, 0 | r2 = 0;
| goto label_89;
| }
| if (r2 != 0x54) {
| label_89:
0x0002cfda bne.w 0x2cb64 | goto label_7;
| }
0x0002cfde ldrb r2, [r3, 6] | r2 = *((r3 + 6));
0x0002cfe0 cmp r2, 0x52 |
| if (r2 == 0x52) {
0x0002cfe2 beq.w 0x2d2fc | goto label_90;
| }
0x0002cfe6 movs r2, 0 | r2 = 0;
0x0002cfe8 b 0x2cb64 | goto label_7;
| label_58:
0x0002cfea ldr r2, [sp, 0x48] | r2 = var_48h;
0x0002cfec b 0x2cb64 | goto label_7;
| label_71:
0x0002cfee ldrd r6, r3, [sp, 0x30] | __asm ("ldrd r6, r3, [var_30h]");
0x0002cff2 add.w r0, r3, r6, lsl 4 | r0 = r3 + (r6 << 4);
0x0002cff6 blx 0x21354 | fcn_00021354 ();
0x0002cff8 invalid |
0x0002cffc str r0, [sp, 0x24] | var_24h = r0;
0x0002cffe cmp r0, 0 |
| if (r0 == 0) {
0x0002d000 beq.w 0x2ca20 | goto label_6;
| }
0x0002d004 add.w r1, r0, r6, lsl 4 | r1 = r0 + (r6 << 4);
0x0002d008 str.w r0, [r8, 0x10] | __asm ("str.w r0, [r8, 0x10]");
0x0002d00c ldr r0, [sp, 0x4c] | r0 = var_4ch;
0x0002d00e mov r2, r6 | r2 = r6;
0x0002d010 str.w r8, [sp, 0x54] | __asm ("str.w r8, [var_54h]");
0x0002d014 movw r6, 0x12de |
0x0002d018 ldr.w r8, [sp, 0x20] | r8 = var_20h;
0x0002d01c add.w r3, r3, r2, lsl 3 | r3 += (r2 << 3);
0x0002d020 add r0, r1 | r0 += r1;
0x0002d022 str r1, [sp, 0x48] | var_48h = r1;
0x0002d024 mov r1, r0 | r1 = r0;
0x0002d026 str.w sb, [sp, 0x58] | __asm ("str.w sb, [var_58h]");
0x0002d02a str.w fp, [sp, 0x5c] | __asm ("str.w fp, [var_5ch]");
0x0002d02e movt r6, 0x9504 | r6 = 0x950412de;
0x0002d032 mov sb, r1 | sb = r1;
0x0002d034 mov fp, r5 |
0x0002d036 movs r0, 0 | r0 = 0;
0x0002d038 str r3, [sp, 0x3c] | var_3ch = r3;
0x0002d03a str r0, [sp, 0x1c] | var_1ch = r0;
0x0002d03c ldr r3, [sp, 0x50] | r3 = var_50h;
0x0002d03e str r0, [sp, 0x10] | var_10h = r0;
0x0002d040 str.w sl, [sp, 0x4c] | __asm ("str.w sl, [var_4ch]");
0x0002d044 str r4, [sp, 0x50] | var_50h = r4;
| label_24:
0x0002d046 movs r1, 0 | r1 = 0;
| label_28:
0x0002d048 cmp r7, r6 |
| if (r7 == r6) {
0x0002d04a beq 0x2d0e2 | goto label_91;
| }
0x0002d04c cmp r1, 0 |
| if (r1 == 0) {
0x0002d04e beq.w 0x2d208 | goto label_92;
| }
0x0002d052 ldr r2, [r3] | r2 = *(r3);
0x0002d054 rev r2, r2 | r2 = SWAP32 (r2);
0x0002d056 add r2, fp | r2 += fp;
0x0002d058 ldr r0, [r2, 8] | r0 = *((r2 + 8));
0x0002d05a adds r5, r0, 1 | r5 = r0 + 1;
| if (r5 != r0) {
0x0002d05c bne 0x2d0f2 | goto label_27;
| }
| label_23:
0x0002d05e cmp r1, 0 |
| if (r1 == 0) {
0x0002d060 beq.w 0x2d218 | goto label_93;
| }
0x0002d064 ldr r2, [sp, 0x1c] | r2 = var_1ch;
0x0002d066 movs r1, 0 | r1 = 0;
0x0002d068 str r1, [sp, 0x14] | var_14h = r1;
0x0002d06a cmp r7, r6 |
0x0002d06c ldr r1, [sp, 0x3c] | r1 = var_3ch;
0x0002d06e str r3, [sp, 0x34] | var_34h = r3;
0x0002d070 lsl.w r2, r2, 3 | r2 <<= 3;
0x0002d074 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0002d076 add r1, r2 | r1 += r2;
0x0002d078 str r1, [sp, 0x44] | var_44h = r1;
0x0002d07a ldr r1, [sp, 0x24] | r1 = var_24h;
0x0002d07c add r2, r1 | r2 += r1;
0x0002d07e str r2, [sp, 0x40] | var_40h = r2;
| if (r7 == r6) {
0x0002d080 beq 0x2d0be | goto label_94;
| }
| do {
0x0002d082 cmp r3, 0 |
| if (r3 == 0) {
0x0002d084 beq.w 0x2d27c | goto label_95;
| }
0x0002d088 ldr r3, [sp, 0x34] | r3 = var_34h;
0x0002d08a ldr r4, [r3] | r4 = *(r3);
0x0002d08c ldr r3, [sp, 0x44] | r3 = var_44h;
0x0002d08e rev r4, r4 | r4 = SWAP32 (r4);
| label_30:
0x0002d090 ldr.w sl, [fp, r4] | sl = *((fp + r4));
0x0002d094 add r4, fp | r4 += fp;
0x0002d096 ldr r2, [r4, 8] | r2 = *((r4 + 8));
0x0002d098 str r3, [sp, 0x28] | var_28h = r3;
0x0002d09a rev.w sl, sl | sl = SWAP32 (sl);
0x0002d09e adds r2, 1 | r2++;
0x0002d0a0 add sl, fp | sl += fp;
| if (r2 != 1) {
0x0002d0a2 bne.w 0x2d22a | goto label_96;
| }
0x0002d0a6 ldr r2, [r4, 4] | r2 = *((r4 + 4));
0x0002d0a8 rev r2, r2 | r2 = SWAP32 (r2);
| label_22:
0x0002d0aa ldr r3, [sp, 0x28] | r3 = var_28h;
0x0002d0ac strd r2, sl, [r3] | __asm ("strd r2, sl, [r3]");
| label_29:
0x0002d0b0 ldr r3, [sp, 0x14] | r3 = var_14h;
| if (r3 != 0) {
0x0002d0b2 cbnz r3, 0x2d10c | goto label_97;
| }
0x0002d0b4 movs r3, 1 | r3 = 1;
0x0002d0b6 cmp r7, r6 |
0x0002d0b8 str r3, [sp, 0x14] | var_14h = r3;
0x0002d0ba ldr r3, [sp, 0x14] | r3 = var_14h;
0x0002d0bc bne 0x2d082 |
| } while (r7 != r6);
| label_94:
0x0002d0be cmp r3, 0 |
| if (r3 == 0) {
0x0002d0c0 beq.w 0x2d286 | goto label_98;
| }
0x0002d0c4 ldr r3, [sp, 0x34] | r3 = var_34h;
0x0002d0c6 ldr r4, [r3] | r4 = *(r3);
0x0002d0c8 ldr r3, [sp, 0x44] | r3 = var_44h;
0x0002d0ca ldr.w r2, [fp, r4] | r2 = *((fp + r4));
0x0002d0ce add r4, fp | r4 += fp;
0x0002d0d0 str r3, [sp, 0x28] | var_28h = r3;
0x0002d0d2 add.w sl, fp, r2 | sl = fp + r2;
| label_31:
0x0002d0d6 ldr r2, [r4, 8] | r2 = *((r4 + 8));
0x0002d0d8 adds r2, 1 | r2++;
| if (r2 != 1) {
0x0002d0da bne.w 0x2d22a | goto label_96;
| }
0x0002d0de ldr r2, [r4, 4] | r2 = *((r4 + 4));
0x0002d0e0 b 0x2d0aa | goto label_22;
| label_91:
0x0002d0e2 cmp r1, 0 |
| if (r1 == 0) {
0x0002d0e4 beq.w 0x2d21c | goto label_99;
| }
0x0002d0e8 ldr r2, [r3] | r2 = *(r3);
0x0002d0ea add r2, fp | r2 += fp;
0x0002d0ec ldr r0, [r2, 8] | r0 = *((r2 + 8));
0x0002d0ee adds r5, r0, 1 | r5 = r0 + 1;
| if (r5 == r0) {
0x0002d0f0 beq 0x2d05e | goto label_23;
| }
| label_27:
0x0002d0f2 adds r2, 4 | r2 += 4;
0x0002d0f4 b 0x2d100 |
| while (r4 != r0) {
0x0002d0f6 ldr.w r0, [r8, r0, lsl 2] | offset_3 = r0 << 2;
| r0 = *((r8 + offset_3));
| if (r0 == 0) {
0x0002d0fa cbz r0, 0x2d114 | goto label_100;
| }
0x0002d0fc ldr r0, [r2, 0xc] | r0 = *((r2 + 0xc));
0x0002d0fe adds r2, 8 | r2 += 8;
0x0002d100 cmp r7, r6 |
0x0002d102 it ne |
| if (r7 != r6) {
0x0002d104 revne r0, r0 | __asm ("revne r0, r0");
| }
0x0002d106 adds r4, r0, 1 | r4 = r0 + 1;
0x0002d108 bne 0x2d0f6 |
| }
0x0002d10a b 0x2d05e | goto label_23;
| label_97:
0x0002d10c ldr r2, [sp, 0x1c] | r2 = var_1ch;
0x0002d10e ldr r3, [sp, 0x34] | r3 = var_34h;
0x0002d110 adds r2, 1 | r2++;
0x0002d112 str r2, [sp, 0x1c] | var_1ch = r2;
| label_100:
0x0002d114 ldr r1, [sp, 0x38] | r1 = var_38h;
0x0002d116 adds r3, 4 | r3 += 4;
0x0002d118 ldr r2, [sp, 0x10] | r2 = var_10h;
0x0002d11a adds r1, 4 | r1 += 4;
0x0002d11c str r1, [sp, 0x38] | var_38h = r1;
0x0002d11e adds r2, 1 | r2++;
0x0002d120 ldr r1, [sp, 0x18] | r1 = var_18h;
0x0002d122 str r2, [sp, 0x10] | var_10h = r2;
0x0002d124 cmp r2, r1 |
| if (r2 <= r1) {
0x0002d126 blo 0x2d046 | goto label_24;
| }
0x0002d128 ldr r3, [sp, 0x30] | r3 = var_30h;
0x0002d12a mov r5, fp | r5 = fp;
0x0002d12c ldr r2, [sp, 0x1c] | r2 = var_1ch;
0x0002d12e ldr.w sl, [sp, 0x4c] | sl = var_4ch;
0x0002d132 ldrd r4, r8, [sp, 0x50] | __asm ("ldrd r4, r8, [var_50h]");
0x0002d136 cmp r3, r2 |
0x0002d138 ldrd sb, fp, [sp, 0x58] | __asm ("ldrd sb, fp, [var_58h]");
| if (r3 != r2) {
0x0002d13c bne.w 0x2d79c | goto label_101;
| }
0x0002d140 ldr r2, [sp, 0x48] | r2 = var_48h;
0x0002d142 movw r6, 0x12de |
0x0002d146 ldr r3, [sp, 0x2c] | r3 = var_2ch;
0x0002d148 movt r6, 0x9504 | r6 = 0x950412de;
0x0002d14c ldr.w ip, [sp, 0xc] | ip = var_ch;
0x0002d150 subs r0, r2, 4 | r0 = r2 - 4;
0x0002d152 movs r2, 0 | r2 = 0;
0x0002d154 subs r3, 4 | r3 -= 4;
| do {
0x0002d156 ldr r1, [r3, 4]! | r1 = *((r3 += 4));
0x0002d15a cmp r7, r6 |
0x0002d15c add.w r2, r2, 1 | r2++;
0x0002d160 it ne |
| if (r7 != r6) {
0x0002d162 revne r1, r1 | __asm ("revne r1, r1");
| }
0x0002d164 cmp r2, ip |
0x0002d166 str r1, [r0, 4]! | *((r0 += 4)) = r1;
0x0002d16a blo 0x2d156 |
| } while (r2 <= ip);
0x0002d16c ldr r2, [sp, 0x24] | r2 = var_24h;
0x0002d16e movs r3, 0 | r3 = 0;
0x0002d170 strd sl, r5, [sp, 0xc] | __asm ("strd sl, r5, [var_ch]");
0x0002d174 ldr r7, [sp, 0x48] | r7 = var_48h;
0x0002d176 ldr r5, [sp, 0x30] | r5 = var_30h;
0x0002d178 adds r2, 4 | r2 += 4;
0x0002d17a strd r4, sb, [sp, 0x14] | __asm ("strd r4, sb, [var_18h]");
0x0002d17e mov sl, r2 | sl = r2;
0x0002d180 mov sb, r3 | sb = r3;
0x0002d182 str.w fp, [sp, 0x1c] | __asm ("str.w fp, [var_1ch]");
| label_25:
0x0002d186 ldr.w r0, [sl, sb, lsl 3] | offset_4 = sb << 3;
| r0 = *((sl + offset_4));
0x0002d18a bl 0x2eac8 | fcn_0002eac8 (r0);
0x0002d18e ldr.w r4, [r8, 0x2c] | r4 = *((r8 + 0x2c));
0x0002d192 mov fp, r0 |
0x0002d194 mov r1, r4 | r1 = r4;
0x0002d196 bl 0xdcbcc | fcn_000dcbcc (r0);
0x0002d19a mov r0, fp | r0 = fp;
0x0002d19c mov r6, r1 | r6 = r1;
0x0002d19e subs r1, r4, 2 | r1 = r4 - 2;
0x0002d1a0 bl 0xdcbcc | fcn_000dcbcc (r0);
0x0002d1a4 ldr.w r2, [r7, r6, lsl 2] | offset_5 = r6 << 2;
| r2 = *((r7 + offset_5));
0x0002d1a8 adds r0, r1, 1 | r0 = r1 + 1;
0x0002d1aa sub.w ip, r4, r0 |
0x0002d1ae add.w r1, r7, r6, lsl 2 | r1 = r7 + (r6 << 2);
0x0002d1b2 subs r4, r0, r4 | r4 = r0 - r4;
| if (r2 == 0) {
0x0002d1b4 cbz r2, 0x2d1ca | goto label_102;
| }
| do {
0x0002d1b6 cmp r6, ip |
0x0002d1b8 ite hs |
| if (r6 < ip) {
0x0002d1ba addhs r6, r6, r4 | r6 += r4;
| }
| if (r6 >= ip) {
0x0002d1bc addlo r6, r6, r0 | r6 += r0;
| }
0x0002d1be ldr.w r3, [r7, r6, lsl 2] | offset_6 = r6 << 2;
| r3 = *((r7 + offset_6));
0x0002d1c2 add.w r1, r7, r6, lsl 2 | r1 = r7 + (r6 << 2);
0x0002d1c6 cmp r3, 0 |
0x0002d1c8 bne 0x2d1b6 |
| } while (r3 != 0);
| label_102:
0x0002d1ca ldr.w r2, [r8, 0x14] | r2 = *((r8 + 0x14));
0x0002d1ce adds r2, 1 | r2++;
0x0002d1d0 add r2, sb | r2 += sb;
0x0002d1d2 add.w sb, sb, 1 | sb++;
0x0002d1d6 cmp r5, sb |
0x0002d1d8 str r2, [r1] | *(r1) = r2;
| if (r5 != sb) {
0x0002d1da bne 0x2d186 | goto label_25;
| }
0x0002d1dc ldr r3, [sp, 0x30] | r3 = var_30h;
0x0002d1de ldrd sl, r5, [sp, 0xc] | __asm ("ldrd sl, r5, [var_ch]");
0x0002d1e2 ldrd r4, sb, [sp, 0x14] | __asm ("ldrd r4, sb, [var_18h]");
0x0002d1e6 str.w r3, [r8, 0x20] | __asm ("str.w r3, [r8, 0x20]");
0x0002d1ea ldr r3, [sp, 0x24] | r3 = var_24h;
0x0002d1ec ldr.w fp, [sp, 0x1c] | fp = var_1ch;
0x0002d1f0 str.w r3, [r8, 0x24] | __asm ("str.w r3, [r8, 0x24]");
0x0002d1f4 ldr r3, [sp, 0x3c] | r3 = var_3ch;
0x0002d1f6 str.w r3, [r8, 0x28] | __asm ("str.w r3, [r8, 0x28]");
0x0002d1fa ldr r3, [sp, 0x48] | r3 = var_48h;
0x0002d1fc str.w r3, [r8, 0x30] | __asm ("str.w r3, [r8, 0x30]");
0x0002d200 movs r3, 0 | r3 = 0;
0x0002d202 str.w r3, [r8, 0x34] | __asm ("str.w r3, [r8, 0x34]");
0x0002d206 b 0x2cdea | goto label_26;
| label_92:
0x0002d208 ldr r2, [sp, 0x38] | r2 = var_38h;
0x0002d20a ldr r2, [r2] | r2 = *(r2);
0x0002d20c rev r2, r2 | r2 = SWAP32 (r2);
0x0002d20e add r2, fp | r2 += fp;
0x0002d210 ldr r0, [r2, 8] | r0 = *((r2 + 8));
0x0002d212 adds r4, r0, 1 | r4 = r0 + 1;
| if (r4 != r0) {
0x0002d214 bne.w 0x2d0f2 | goto label_27;
| }
| do {
| label_93:
0x0002d218 movs r1, 1 | r1 = 1;
0x0002d21a b 0x2d048 | goto label_28;
| label_99:
0x0002d21c ldr r2, [sp, 0x38] | r2 = var_38h;
0x0002d21e ldr r2, [r2] | r2 = *(r2);
0x0002d220 add r2, fp | r2 += fp;
0x0002d222 ldr r0, [r2, 8] | r0 = *((r2 + 8));
0x0002d224 adds r4, r0, 1 | r4 = r0 + 1;
0x0002d226 beq 0x2d218 |
| } while (r4 == r0);
0x0002d228 b 0x2d0f2 | goto label_27;
| label_96:
0x0002d22a ldr r3, [sp, 0x28] | r3 = var_28h;
0x0002d22c adds r4, 0xc | r4 += 0xc;
0x0002d22e str.w sb, [r3, 4] | __asm ("str.w sb, [r3, 4]");
0x0002d232 b 0x2d252 |
| while (r2 == 0) {
0x0002d234 adds r2, r5, 1 | r2 = r5 + 1;
0x0002d236 add.w r4, r4, 8 | r4 += 8;
| if (r2 == r5) {
0x0002d23a beq 0x2d270 | goto label_103;
| }
0x0002d23c ldr.w r5, [r8, r5, lsl 2] | offset_7 = r5 << 2;
| r5 = *((r8 + offset_7));
0x0002d240 mov r0, r5 | r0 = r5;
0x0002d242 bl 0x6a8c0 | strlen ();
0x0002d246 mov r1, r5 | r1 = r5;
0x0002d248 mov r2, r0 | r2 = r0;
0x0002d24a mov r0, sb | r0 = sb;
0x0002d24c add sb, r2 | sb += r2;
0x0002d24e blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002d252 ldrd r2, r5, [r4, -0x8] | __asm ("ldrd r2, r5, [r4, -0x8]");
0x0002d256 cmp r7, r6 |
0x0002d258 itt ne |
| if (r7 != r6) {
0x0002d25a revne r2, r2 | __asm ("revne r2, r2");
| }
| if (r7 != r6) {
0x0002d25c revne r5, r5 | __asm ("revne r5, r5");
| }
0x0002d25e cmp r2, 0 |
0x0002d260 beq 0x2d234 |
| }
0x0002d262 mov r1, sl | r1 = sl;
0x0002d264 mov r0, sb | r0 = sb;
0x0002d266 add sl, r2 | sl += r2;
0x0002d268 add sb, r2 | sb += r2;
0x0002d26a blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002d26c invalid |
| label_103:
0x0002d270 ldr r3, [sp, 0x28] | r3 = var_28h;
0x0002d272 ldr r2, [r3, 4] | r2 = *((r3 + 4));
0x0002d274 sub.w r2, sb, r2 | r2 = sb - r2;
0x0002d278 str r2, [r3] | *(r3) = r2;
0x0002d27a b 0x2d0b0 | goto label_29;
| label_95:
0x0002d27c ldr r3, [sp, 0x38] | r3 = var_38h;
0x0002d27e ldr r4, [r3] | r4 = *(r3);
0x0002d280 ldr r3, [sp, 0x40] | r3 = var_40h;
0x0002d282 rev r4, r4 | r4 = SWAP32 (r4);
0x0002d284 b 0x2d090 | goto label_30;
| label_98:
0x0002d286 ldr r3, [sp, 0x38] | r3 = var_38h;
0x0002d288 ldr r4, [r3] | r4 = *(r3);
0x0002d28a ldr r3, [sp, 0x40] | r3 = var_40h;
0x0002d28c ldr.w r2, [fp, r4] | r2 = *((fp + r4));
0x0002d290 add r4, fp | r4 += fp;
0x0002d292 str r3, [sp, 0x28] | var_28h = r3;
0x0002d294 add.w sl, fp, r2 | sl = fp + r2;
0x0002d298 b 0x2d0d6 | goto label_31;
| label_76:
0x0002d29a movs r2, 0 | r2 = 0;
0x0002d29c b 0x2cb64 | goto label_7;
| label_87:
0x0002d29e movs r2, 0 | r2 = 0;
0x0002d2a0 b 0x2cb64 | goto label_7;
| label_63:
0x0002d2a2 movs r2, 0 | r2 = 0;
0x0002d2a4 b 0x2cb64 | goto label_7;
| label_85:
0x0002d2a6 ldrb r3, [r3, 7] | r3 = *((r3 + 7));
0x0002d2a8 cmp r3, 0 |
| if (r3 == 0) {
0x0002d2aa bne 0x2d33a |
0x0002d2ac sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d2b0 cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002d2b4 bhi 0x2d2e4 |
| /* switch table (22 cases) at 0x2d2ba */
0x0002d2b6 tbh [pc, sb, lsl 1] | __asm ("tbh [pc, sb, lsl 1]");
| }
0x0002d2e4 ldr r2, [sp, 0x44] | r2 = var_44h;
0x0002d2e6 b 0x2cb64 | goto label_7;
| label_79:
0x0002d2e8 ldrb r2, [r3, 7] | r2 = *((r3 + 7));
0x0002d2ea cmp r2, 0x53 |
| if (r2 == 0x53) {
0x0002d2ec beq 0x2d33e | goto label_104;
| }
0x0002d2ee movs r2, 0 | r2 = 0;
0x0002d2f0 b 0x2cb64 | goto label_7;
| label_82:
0x0002d2f2 ldrb r2, [r3, 7] | r2 = *((r3 + 7));
0x0002d2f4 cmp r2, 0x54 |
| if (r2 == 0x54) {
0x0002d2f6 beq 0x2d35c | goto label_105;
| }
0x0002d2f8 movs r2, 0 | r2 = 0;
0x0002d2fa b 0x2cb64 | goto label_7;
| label_90:
0x0002d2fc ldrb r3, [r3, 7] | r3 = *((r3 + 7));
| if (r3 != 0) {
0x0002d2fe cbnz r3, 0x2d358 | goto label_106;
| }
0x0002d300 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d304 cmp.w sb, 0x14 |
| if (sb > 0x14) {
0x0002d308 bhi.w 0x2d778 | goto label_107;
| }
| /* switch table (22 cases) at 0x2d310 */
0x0002d30c tbh [pc, sb, lsl 1] | __asm ("tbh [pc, sb, lsl 1]");
| }
0x0002d33a movs r2, 0 | r2 = 0;
0x0002d33c b 0x2cb64 | goto label_7;
| label_104:
0x0002d33e ldrb r2, [r3, 8] | r2 = *((r3 + 8));
0x0002d340 cmp r2, 0x54 |
| if (r2 != 0x54) {
0x0002d342 beq.w 0x2d594 |
0x0002d346 movs r2, 0 | r2 = 0;
0x0002d348 b 0x2cb64 | goto label_7;
| label_49:
0x0002d34a ldr.w r3, [pc, 0x474] | r3 = *(0x0002d7c0);
0x0002d34e add r3, pc | r3 += pc;
0x0002d350 ldr r3, [r3, 4] | r3 = *((r3 + 4));
0x0002d352 subs r3, 1 | r3--;
0x0002d354 b.w 0x2c9d0 | goto label_1;
| label_106:
0x0002d358 movs r2, 0 | r2 = 0;
0x0002d35a b 0x2cb64 | goto label_7;
| label_105:
0x0002d35c ldrb r2, [r3, 8] | r2 = *((r3 + 8));
0x0002d35e cmp r2, 0x38 |
| if (r2 != 0x38) {
0x0002d360 beq 0x2d45e |
0x0002d362 cmp r2, 0x31 |
| if (r2 != 0x31) {
0x0002d364 beq 0x2d452 |
0x0002d366 cmp r2, 0x33 |
| if (r2 == 0x33) {
0x0002d368 bne 0x2d3a6 |
0x0002d36a ldrb r2, [r3, 9] | r2 = *((r3 + 9));
0x0002d36c cmp r2, 0x32 |
| if (r2 != 0x32) {
0x0002d36e beq 0x2d37c |
0x0002d370 movs r2, 0 | r2 = 0;
0x0002d372 b.w 0x2cb64 | goto label_7;
| label_88:
0x0002d376 movs r2, 0 | r2 = 0;
0x0002d378 b.w 0x2cb64 | goto label_7;
| }
0x0002d37c ldrb r3, [r3, 0xa] | r3 = *((r3 + 0xa));
0x0002d37e cmp r3, 0 |
| if (r3 != 0) {
0x0002d380 bne 0x2d44c | goto label_108;
| }
0x0002d382 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d386 cmp.w sb, 0x14 |
| if (sb > 0x14) {
0x0002d38a bhi 0x2d444 | goto label_109;
| }
| /* switch table (21 cases) at 0x2d390 */
0x0002d38c tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| }
0x0002d3a6 cmp r2, 0x36 |
| if (r2 == 0x36) {
0x0002d3a8 bne 0x2d3e8 |
0x0002d3aa ldrb r2, [r3, 9] | r2 = *((r3 + 9));
0x0002d3ac cmp r2, 0x34 |
| if (r2 != 0x34) {
0x0002d3ae beq 0x2d3c0 |
0x0002d3b0 movs r2, 0 | r2 = 0;
0x0002d3b2 b.w 0x2cb64 | goto label_7;
0x0002d3b6 ldr.w r2, [pc, 0x40c] | r2 = *(0x0002d7c4);
0x0002d3ba add r2, pc | r2 += pc;
0x0002d3bc b.w 0x2cb64 | goto label_7;
| }
0x0002d3c0 ldrb r3, [r3, 0xa] | r3 = *((r3 + 0xa));
| if (r3 != 0) {
0x0002d3c2 cbnz r3, 0x2d41e | goto label_110;
| }
0x0002d3c4 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d3c8 cmp.w sb, 0x14 |
| if (sb > 0x14) {
0x0002d3cc bhi 0x2d416 | goto label_111;
| }
| /* switch table (21 cases) at 0x2d3d2 */
0x0002d3ce tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| }
0x0002d3e8 movs r2, 0 | r2 = 0;
0x0002d3ea b.w 0x2cb64 | goto label_7;
0x0002d3ee ldr r2, [pc, 0x3d8] |
0x0002d3f0 add r2, pc | r2 = 0x5abbe;
0x0002d3f2 b.w 0x2cb64 | goto label_7;
0x0002d3f6 ldr r2, [pc, 0x3d4] |
0x0002d3f8 add r2, pc | r2 = 0x5abca;
0x0002d3fa b.w 0x2cb64 | goto label_7;
0x0002d3fe ldr r2, [pc, 0x3d0] |
0x0002d400 add r2, pc | r2 = 0x5abd6;
0x0002d402 b.w 0x2cb64 | goto label_7;
0x0002d406 ldr r2, [pc, 0x3cc] |
0x0002d408 add r2, pc | r2 = 0x5abe2;
0x0002d40a b.w 0x2cb64 | goto label_7;
0x0002d40e ldr r2, [pc, 0x3c8] |
0x0002d410 add r2, pc | r2 = 0x5abee;
0x0002d412 b.w 0x2cb64 | goto label_7;
| label_111:
0x0002d416 ldr r2, [pc, 0x3c4] |
0x0002d418 add r2, pc | r2 = 0x5abfa;
0x0002d41a b.w 0x2cb64 | goto label_7;
| label_110:
0x0002d41e movs r2, 0 | r2 = 0;
0x0002d420 b.w 0x2cb64 | goto label_7;
0x0002d424 ldr r2, [pc, 0x3b8] |
0x0002d426 add r2, pc | r2 = 0x5ac0a;
0x0002d428 b.w 0x2cb64 | goto label_7;
0x0002d42c ldr r2, [pc, 0x3b4] |
0x0002d42e add r2, pc | r2 = 0x5ac16;
0x0002d430 b.w 0x2cb64 | goto label_7;
0x0002d434 ldr r2, [pc, 0x3b0] |
0x0002d436 add r2, pc | r2 = 0x5ac22;
0x0002d438 b.w 0x2cb64 | goto label_7;
0x0002d43c ldr r2, [pc, 0x3ac] |
0x0002d43e add r2, pc | r2 = 0x5ac2e;
0x0002d440 b.w 0x2cb64 | goto label_7;
| label_109:
0x0002d444 ldr r2, [pc, 0x3a8] |
0x0002d446 add r2, pc | r2 = 0x5ac3a;
0x0002d448 b.w 0x2cb64 | goto label_7;
| label_108:
0x0002d44c movs r2, 0 | r2 = 0;
0x0002d44e b.w 0x2cb64 | goto label_7;
| }
0x0002d452 ldrb r2, [r3, 9] | r2 = *((r3 + 9));
0x0002d454 cmp r2, 0x36 |
| if (r2 == 0x36) {
0x0002d456 beq 0x2d488 | goto label_112;
| }
0x0002d458 movs r2, 0 | r2 = 0;
0x0002d45a b.w 0x2cb64 | goto label_7;
| }
0x0002d45e ldrb r3, [r3, 9] | r3 = *((r3 + 9));
0x0002d460 cmp r3, 0 |
| if (r3 == 0) {
0x0002d462 bne 0x2d516 |
0x0002d464 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d468 cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002d46c bhi 0x2d50e |
| /* switch table (21 cases) at 0x2d472 */
0x0002d46e tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| label_112:
0x0002d488 ldrb r3, [r3, 0xa] | r3 = *((r3 + 0xa));
| if (r3 == 0) {
0x0002d48a cbnz r3, 0x2d4e8 |
0x0002d48c sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d490 cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002d494 bhi 0x2d4e0 |
| /* switch table (21 cases) at 0x2d49a */
0x0002d496 tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
0x0002d4b0 ldr r2, [pc, 0x340] |
0x0002d4b2 add r2, pc | r2 = 0x5acaa;
0x0002d4b4 b.w 0x2cb64 | goto label_7;
0x0002d4b8 ldr r2, [pc, 0x33c] |
0x0002d4ba add r2, pc | r2 = 0x5acb6;
0x0002d4bc b.w 0x2cb64 | goto label_7;
0x0002d4c0 ldr r2, [pc, 0x338] |
0x0002d4c2 add r2, pc | r2 = 0x5acc2;
0x0002d4c4 b.w 0x2cb64 | goto label_7;
0x0002d4c8 ldr r2, [pc, 0x334] |
0x0002d4ca add r2, pc | r2 = 0x5acce;
0x0002d4cc b.w 0x2cb64 | goto label_7;
0x0002d4d0 ldr r2, [pc, 0x330] |
0x0002d4d2 add r2, pc | r2 = 0x5acda;
0x0002d4d4 b.w 0x2cb64 | goto label_7;
0x0002d4d8 ldr r2, [pc, 0x32c] |
0x0002d4da add r2, pc | r2 = 0x5ace6;
0x0002d4dc b.w 0x2cb64 | goto label_7;
| }
0x0002d4e0 ldr r2, [pc, 0x328] |
0x0002d4e2 add r2, pc | r2 = 0x5acf2;
0x0002d4e4 b.w 0x2cb64 | goto label_7;
| }
0x0002d4e8 movs r2, 0 | r2 = 0;
0x0002d4ea b.w 0x2cb64 | goto label_7;
0x0002d4ee ldr r2, [pc, 0x320] |
0x0002d4f0 add r2, pc | r2 = 0x5ad06;
0x0002d4f2 b.w 0x2cb64 | goto label_7;
0x0002d4f6 ldr r2, [pc, 0x31c] |
0x0002d4f8 add r2, pc | r2 = 0x5ad12;
0x0002d4fa b.w 0x2cb64 | goto label_7;
0x0002d4fe ldr r2, [pc, 0x318] |
0x0002d500 add r2, pc | r2 = 0x5ad1e;
0x0002d502 b.w 0x2cb64 | goto label_7;
0x0002d506 ldr r2, [pc, 0x314] |
0x0002d508 add r2, pc | r2 = 0x5ad2a;
0x0002d50a b.w 0x2cb64 | goto label_7;
| }
0x0002d50e ldr r2, [pc, 0x310] |
0x0002d510 add r2, pc | r2 = 0x5ad36;
0x0002d512 b.w 0x2cb64 | goto label_7;
| }
0x0002d516 movs r2, 0 | r2 = 0;
0x0002d518 b.w 0x2cb64 | goto label_7;
0x0002d51c ldr r2, [pc, 0x304] |
0x0002d51e add r2, pc | r2 = 0x5ad46;
0x0002d520 b.w 0x2cb64 | goto label_7;
0x0002d524 ldr r2, [pc, 0x300] |
0x0002d526 add r2, pc | r2 = 0x5ad52;
0x0002d528 b.w 0x2cb64 | goto label_7;
0x0002d52c ldr r2, [pc, 0x2fc] |
0x0002d52e add r2, pc | r2 = 0x5ad5e;
0x0002d530 b.w 0x2cb64 | goto label_7;
0x0002d534 ldr r2, [pc, 0x2f8] |
0x0002d536 add r2, pc | r2 = 0x5ad6a;
0x0002d538 b.w 0x2cb64 | goto label_7;
0x0002d53c ldr r2, [pc, 0x2f4] |
0x0002d53e add r2, pc | r2 = 0x5ad76;
0x0002d540 b.w 0x2cb64 | goto label_7;
0x0002d544 ldr r2, [pc, 0x2f0] |
0x0002d546 add r2, pc | r2 = 0x5ad82;
0x0002d548 b.w 0x2cb64 | goto label_7;
0x0002d54c ldr r2, [pc, 0x2ec] |
0x0002d54e add r2, pc | r2 = 0x5ad8e;
0x0002d550 b.w 0x2cb64 | goto label_7;
0x0002d554 ldr r2, [pc, 0x2e8] |
0x0002d556 add r2, pc | r2 = 0x5ad9a;
0x0002d558 b.w 0x2cb64 | goto label_7;
0x0002d55c ldr r2, [pc, 0x2e4] |
0x0002d55e add r2, pc | r2 = 0x5ada6;
0x0002d560 b.w 0x2cb64 | goto label_7;
0x0002d564 ldr r2, [pc, 0x2e0] |
0x0002d566 add r2, pc | r2 = 0x5adb2;
0x0002d568 b.w 0x2cb64 | goto label_7;
0x0002d56c ldr r2, [pc, 0x2dc] |
0x0002d56e add r2, pc | r2 = 0x5adbe;
0x0002d570 b.w 0x2cb64 | goto label_7;
0x0002d574 ldr r2, [pc, 0x2d8] |
0x0002d576 add r2, pc | r2 = 0x5adca;
0x0002d578 b.w 0x2cb64 | goto label_7;
0x0002d57c ldr r2, [pc, 0x2d4] |
0x0002d57e add r2, pc | r2 = 0x5add6;
0x0002d580 b.w 0x2cb64 | goto label_7;
0x0002d584 ldr r2, [pc, 0x2d0] |
0x0002d586 add r2, pc | r2 = 0x5ade2;
0x0002d588 b.w 0x2cb64 | goto label_7;
0x0002d58c ldr r2, [pc, 0x2cc] |
0x0002d58e add r2, pc | r2 = 0x5adee;
0x0002d590 b.w 0x2cb64 | goto label_7;
| }
0x0002d594 ldrb r2, [r3, 9] | r2 = *((r3 + 9));
0x0002d596 cmp r2, 0x38 |
| if (r2 != 0x38) {
0x0002d598 beq.w 0x2d6b2 |
0x0002d59c cmp r2, 0x31 |
| if (r2 != 0x31) {
0x0002d59e beq.w 0x2d6a6 |
0x0002d5a2 cmp r2, 0x33 |
| if (r2 == 0x33) {
0x0002d5a4 bne 0x2d5fc |
0x0002d5a6 ldrb r2, [r3, 0xa] | r2 = *((r3 + 0xa));
0x0002d5a8 cmp r2, 0x32 |
| if (r2 != 0x32) {
0x0002d5aa beq 0x2d5d2 |
0x0002d5ac movs r2, 0 | r2 = 0;
0x0002d5ae b.w 0x2cb64 | goto label_7;
0x0002d5b2 ldr r2, [pc, 0x2ac] |
0x0002d5b4 add r2, pc | r2 = 0x5ae1a;
0x0002d5b6 b.w 0x2cb64 | goto label_7;
0x0002d5ba ldr r2, [pc, 0x2a8] |
0x0002d5bc add r2, pc | r2 = 0x5ae26;
0x0002d5be b.w 0x2cb64 | goto label_7;
0x0002d5c0 revsh r1, r2 | __asm ("revsh r1, r2");
0x0002d5c2 ldr r2, [pc, 0x2a4] |
0x0002d5c4 add r2, pc | r2 = 0x5ae32;
0x0002d5c6 b.w 0x2cb64 | goto label_7;
0x0002d5ca ldr r2, [pc, 0x2a0] |
0x0002d5cc add r2, pc | r2 = 0x5ae3e;
0x0002d5ce b.w 0x2cb64 | goto label_7;
| }
0x0002d5d2 ldrb r3, [r3, 0xb] | r3 = *((r3 + 0xb));
0x0002d5d4 cmp r3, 0 |
| if (r3 != 0) {
0x0002d5d6 bne 0x2d6a0 | goto label_113;
| }
0x0002d5d8 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d5dc cmp.w sb, 0x14 |
| if (sb > 0x14) {
0x0002d5e0 bhi 0x2d698 | goto label_114;
| }
| /* switch table (21 cases) at 0x2d5e6 */
0x0002d5e2 tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| }
0x0002d5fc cmp r2, 0x36 |
| if (r2 == 0x36) {
0x0002d5fe bne 0x2d63c |
0x0002d600 ldrb r2, [r3, 0xa] | r2 = *((r3 + 0xa));
0x0002d602 cmp r2, 0x34 |
| if (r2 != 0x34) {
0x0002d604 beq 0x2d614 |
0x0002d606 movs r2, 0 | r2 = 0;
0x0002d608 b.w 0x2cb64 | goto label_7;
0x0002d60c ldr r2, [pc, 0x260] |
0x0002d60e add r2, pc | r2 = 0x5ae82;
0x0002d610 b.w 0x2cb64 | goto label_7;
| }
0x0002d614 ldrb r3, [r3, 0xb] | r3 = *((r3 + 0xb));
| if (r3 != 0) {
0x0002d616 cbnz r3, 0x2d672 | goto label_115;
| }
0x0002d618 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d61c cmp.w sb, 0x14 |
| if (sb > 0x14) {
0x0002d620 bhi 0x2d66a | goto label_116;
| }
| /* switch table (21 cases) at 0x2d626 */
0x0002d622 tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| }
0x0002d63c movs r2, 0 | r2 = 0;
0x0002d63e b.w 0x2cb64 | goto label_7;
0x0002d642 ldr r2, [pc, 0x230] |
0x0002d644 add r2, pc | r2 = 0x5aebe;
0x0002d646 b.w 0x2cb64 | goto label_7;
0x0002d64a ldr r2, [pc, 0x22c] |
0x0002d64c add r2, pc | r2 = 0x5aeca;
0x0002d64e b.w 0x2cb64 | goto label_7;
0x0002d652 ldr r2, [pc, 0x228] |
0x0002d654 add r2, pc | r2 = 0x5aed6;
0x0002d656 b.w 0x2cb64 | goto label_7;
0x0002d65a ldr r2, [pc, 0x224] |
0x0002d65c add r2, pc | r2 = 0x5aee2;
0x0002d65e b.w 0x2cb64 | goto label_7;
0x0002d662 ldr r2, [pc, 0x220] |
0x0002d664 add r2, pc | r2 = 0x5aeee;
0x0002d666 b.w 0x2cb64 | goto label_7;
| label_116:
0x0002d66a ldr r2, [pc, 0x21c] |
0x0002d66c add r2, pc | r2 = 0x5aefa;
0x0002d66e b.w 0x2cb64 | goto label_7;
| label_115:
0x0002d672 movs r2, 0 | r2 = 0;
0x0002d674 b.w 0x2cb64 | goto label_7;
0x0002d678 ldr r2, [pc, 0x210] |
0x0002d67a add r2, pc | r2 = 0x5af0a;
0x0002d67c b.w 0x2cb64 | goto label_7;
0x0002d680 ldr r2, [pc, 0x20c] |
0x0002d682 add r2, pc | r2 = 0x5af16;
0x0002d684 b.w 0x2cb64 | goto label_7;
0x0002d688 ldr r2, [pc, 0x208] |
0x0002d68a add r2, pc | r2 = 0x5af22;
0x0002d68c b.w 0x2cb64 | goto label_7;
0x0002d690 ldr r2, [pc, 0x204] |
0x0002d692 add r2, pc | r2 = 0x5af2e;
0x0002d694 b.w 0x2cb64 | goto label_7;
| label_114:
0x0002d698 ldr r2, [pc, 0x200] |
0x0002d69a add r2, pc | r2 = 0x5af3a;
0x0002d69c b.w 0x2cb64 | goto label_7;
| label_113:
0x0002d6a0 movs r2, 0 | r2 = 0;
0x0002d6a2 b.w 0x2cb64 | goto label_7;
| }
0x0002d6a6 ldrb r2, [r3, 0xa] | r2 = *((r3 + 0xa));
0x0002d6a8 cmp r2, 0x36 |
| if (r2 == 0x36) {
0x0002d6aa beq 0x2d6dc | goto label_117;
| }
0x0002d6ac movs r2, 0 | r2 = 0;
0x0002d6ae b.w 0x2cb64 | goto label_7;
| }
0x0002d6b2 ldrb r3, [r3, 0xa] | r3 = *((r3 + 0xa));
0x0002d6b4 cmp r3, 0 |
| if (r3 == 0) {
0x0002d6b6 bne 0x2d76a |
0x0002d6b8 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d6bc cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002d6c0 bhi 0x2d762 |
| /* switch table (21 cases) at 0x2d6c6 */
0x0002d6c2 tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
| label_117:
0x0002d6dc ldrb r3, [r3, 0xb] | r3 = *((r3 + 0xb));
| if (r3 == 0) {
0x0002d6de cbnz r3, 0x2d73c |
0x0002d6e0 sub.w sb, sb, 0x64 | sb -= 0x64;
0x0002d6e4 cmp.w sb, 0x14 |
| if (sb <= 0x14) {
0x0002d6e8 bhi 0x2d734 |
| /* switch table (21 cases) at 0x2d6ee */
0x0002d6ea tbb [pc, sb] | __asm ("tbb aav.0x000000ff");
0x0002d704 ldr r2, [pc, 0x198] |
0x0002d706 add r2, pc | r2 = 0x5afaa;
0x0002d708 b.w 0x2cb64 | goto label_7;
0x0002d70c ldr r2, [pc, 0x194] |
0x0002d70e add r2, pc | r2 = 0x5afb6;
0x0002d710 b.w 0x2cb64 | goto label_7;
0x0002d714 ldr r2, [pc, 0x190] |
0x0002d716 add r2, pc | r2 = 0x5afc2;
0x0002d718 b.w 0x2cb64 | goto label_7;
0x0002d71c ldr r2, [pc, 0x18c] |
0x0002d71e add r2, pc | r2 = 0x5afce;
0x0002d720 b.w 0x2cb64 | goto label_7;
0x0002d724 ldr r2, [pc, 0x188] |
0x0002d726 add r2, pc | r2 = 0x5afda;
0x0002d728 b.w 0x2cb64 | goto label_7;
0x0002d72c ldr r2, [pc, 0x184] |
0x0002d72e add r2, pc | r2 = 0x5afe6;
0x0002d730 b.w 0x2cb64 | goto label_7;
| }
0x0002d734 ldr r2, [pc, 0x180] |
0x0002d736 add r2, pc | r2 = 0x5aff2;
0x0002d738 b.w 0x2cb64 | goto label_7;
| }
0x0002d73c movs r2, 0 | r2 = 0;
0x0002d73e b.w 0x2cb64 | goto label_7;
0x0002d742 ldr r2, [pc, 0x178] |
0x0002d744 add r2, pc | r2 = 0x5b006;
0x0002d746 b.w 0x2cb64 | goto label_7;
0x0002d74a ldr r2, [pc, 0x174] |
0x0002d74c add r2, pc | r2 = 0x5b012;
0x0002d74e b.w 0x2cb64 | goto label_7;
0x0002d752 ldr r2, [pc, 0x170] |
0x0002d754 add r2, pc | r2 = 0x5b01e;
0x0002d756 b.w 0x2cb64 | goto label_7;
0x0002d75a ldr r2, [pc, 0x16c] |
0x0002d75c add r2, pc | r2 = 0x5b02a;
0x0002d75e b.w 0x2cb64 | goto label_7;
| }
0x0002d762 ldr r2, [pc, 0x168] |
0x0002d764 add r2, pc | r2 = 0x5b036;
0x0002d766 b.w 0x2cb64 | goto label_7;
| }
0x0002d76a movs r2, 0 | r2 = 0;
0x0002d76c b.w 0x2cb64 | goto label_7;
0x0002d770 ldr r2, [pc, 0x15c] |
0x0002d772 add r2, pc | r2 = 0x5b046;
0x0002d774 b.w 0x2cb64 | goto label_7;
| label_107:
0x0002d778 ldr r2, [sp, 0x30] | r2 = var_30h;
0x0002d77a b.w 0x2cb64 | goto label_7;
0x0002d77e ldr r2, [sp, 0x28] | r2 = var_28h;
0x0002d780 b.w 0x2cb64 | goto label_7;
0x0002d784 ldr r2, [sp, 0x3c] | r2 = var_3ch;
0x0002d786 b.w 0x2cb64 | goto label_7;
0x0002d78a ldr r2, [sp, 0x34] | r2 = var_34h;
0x0002d78c b.w 0x2cb64 | goto label_7;
0x0002d790 ldr r2, [sp, 0x38] | r2 = var_38h;
0x0002d792 b.w 0x2cb64 | goto label_7;
0x0002d796 ldr r2, [sp, 0x40] | r2 = var_40h;
0x0002d798 b.w 0x2cb64 | goto label_7;
| label_101:
0x0002d79c bl 0x21388 | abort ();
0x0002d7a0 strb r6, [r7, r4] | *((r7 + r4)) = r6;
0x0002d7a2 movs r4, r1 | r4 = r1;
0x0002d7a4 ldrsh r4, [r7, r0] | r4 = *((r7 + r0));
0x0002d7a6 movs r4, r1 | r4 = r1;
0x0002d7a8 adr r1, 0x120 | r1 = 0x120;
0x0002d7aa movs r4, r1 | r4 = r1;
0x0002d7ac adr r4, 0x1e0 | r4 = 0x1e0;
0x0002d7ae movs r4, r1 | r4 = r1;
0x0002d7b0 strb r4, [r2, r2] | *((r2 + r2)) = r4;
0x0002d7b2 movs r4, r1 | r4 = r1;
0x0002d7b4 strb r0, [r1, r2] | *((r1 + r2)) = r0;
0x0002d7b6 movs r4, r1 | r4 = r1;
0x0002d7b8 ldr r0, [r1, r2] | r0 = *((r1 + r2));
0x0002d7ba movs r4, r1 | r4 = r1;
0x0002d7bc ldrb r0, [r0, r7] | r0 = *((r0 + r7));
0x0002d7be movs r4, r1 | r4 = r1;
0x0002d7c0 movs r1, 0x1a | r1 = 0x1a;
0x0002d7c2 movs r6, r1 | r6 = r1;
0x0002d7c4 ldr r4, [sp, 0x388] | r4 = *(arg_388h);
0x0002d7c6 movs r4, r1 | r4 = r1;
0x0002d7c8 str r4, [r2, r0] | *((r2 + r0)) = r4;
0x0002d7ca movs r4, r1 | r4 = r1;
0x0002d7cc str r4, [r0, r0] | *((r0 + r0)) = r4;
0x0002d7ce movs r4, r1 | r4 = r1;
0x0002d7d0 str r0, [r1, r0] | *((r1 + r0)) = r0;
0x0002d7d2 movs r4, r1 | r4 = r1;
0x0002d7d4 str r4, [r0, r0] | *((r0 + r0)) = r4;
0x0002d7d6 movs r4, r1 | r4 = r1;
0x0002d7d8 ldr r7, [pc, 0x380] | r7 = *(0x2db5c);
0x0002d7da movs r4, r1 | r4 = r1;
0x0002d7dc ldr r7, [pc, 0x3a0] | r7 = *(0x2db80);
0x0002d7de movs r4, r1 | r4 = r1;
0x0002d7e0 ldr r7, [sp, 0x2b8] | r7 = *(arg_2b8h);
0x0002d7e2 movs r4, r1 | r4 = r1;
0x0002d7e4 ldr r7, [pc, 0x328] | r7 = *(0x2db10);
0x0002d7e6 movs r4, r1 | r4 = r1;
0x0002d7e8 ldr r7, [pc, 0x2f8] | r7 = *(0x2dae4);
0x0002d7ea movs r4, r1 | r4 = r1;
0x0002d7ec strh r6, [r7, r6] | *((r7 + r6)) = r6;
0x0002d7ee movs r4, r1 | r4 = r1;
0x0002d7f0 ldr r2, [r0, r5] | r2 = *((r0 + r5));
0x0002d7f2 movs r4, r1 | r4 = r1;
0x0002d7f4 ldr r3, [sp, 0x3a8] | r3 = *(arg_3a8h);
0x0002d7f6 movs r4, r1 | r4 = r1;
0x0002d7f8 ldr r3, [sp, 0x388] | r3 = *(arg_388h);
0x0002d7fa movs r4, r1 | r4 = r1;
0x0002d7fc ldr r7, [sp, 0x48] | r7 = var_48h;
0x0002d7fe movs r4, r1 | r4 = r1;
0x0002d800 ldr r7, [pc, 0xb8] | r7 = *(0x2d8bc);
0x0002d802 movs r4, r1 | r4 = r1;
0x0002d804 ldr r7, [pc, 0x88] | r7 = *(0x2d890);
0x0002d806 movs r4, r1 | r4 = r1;
0x0002d808 strh r2, [r4, r4] | *((r4 + r4)) = r2;
0x0002d80a movs r4, r1 | r4 = r1;
0x0002d80c ldr r6, [r4, r2] | r6 = *((r4 + r2));
0x0002d80e movs r4, r1 | r4 = r1;
0x0002d810 ldr r6, [sp, 0x390] | r6 = *(arg_390h);
0x0002d812 movs r4, r1 | r4 = r1;
0x0002d814 ldr r7, [pc, 0] | r7 = *(0x2d818);
0x0002d816 movs r4, r1 | r4 = r1;
0x0002d818 ldr r6, [pc, 0x3d0] | r6 = *(0x2dbec);
0x0002d81a movs r4, r1 | r4 = r1;
0x0002d81c strh r4, [r6, r3] | *((r6 + r3)) = r4;
0x0002d81e movs r4, r1 | r4 = r1;
0x0002d820 ldr r0, [r7, r1] |
0x0002d822 movs r4, r1 | r4 = r1;
0x0002d824 ldr r6, [sp, 0x2d8] | r6 = *(arg_2d8h);
0x0002d826 movs r4, r1 | r4 = r1;
0x0002d828 ldr r6, [pc, 0x348] | r6 = *(0x2db74);
0x0002d82a movs r4, r1 | r4 = r1;
0x0002d82c ldr r6, [pc, 0x318] | r6 = *(0x2db48);
0x0002d82e movs r4, r1 | r4 = r1;
0x0002d830 strh r6, [r0, r3] | *((r0 + r3)) = r6;
0x0002d832 movs r4, r1 | r4 = r1;
0x0002d834 ldr r6, [pc, 0x2f8] | r6 = *(0x2db30);
0x0002d836 movs r4, r1 | r4 = r1;
0x0002d838 ldr r6, [pc, 0x308] | r6 = *(0x2db44);
0x0002d83a movs r4, r1 | r4 = r1;
0x0002d83c ldr r6, [pc, 0x2f8] | r6 = *(0x2db38);
0x0002d83e movs r4, r1 | r4 = r1;
0x0002d840 ldr r6, [pc, 0x268] | r6 = *(0x2daac);
0x0002d842 movs r4, r1 | r4 = r1;
0x0002d844 ldr r6, [pc, 0x278] | r6 = *(0x2dac0);
0x0002d846 movs r4, r1 | r4 = r1;
0x0002d848 ldr r6, [pc, 0x288] | r6 = *(0x2dad4);
0x0002d84a movs r4, r1 | r4 = r1;
0x0002d84c ldr r6, [pc, 0x278] | r6 = *(0x2dac8);
0x0002d84e movs r4, r1 | r4 = r1;
0x0002d850 ldr r6, [pc, 0x1e8] | r6 = *(0x2da3c);
0x0002d852 movs r4, r1 | r4 = r1;
0x0002d854 ldr r6, [pc, 0x218] | r6 = *(0x2da70);
0x0002d856 movs r4, r1 | r4 = r1;
0x0002d858 ldr r6, [pc, 0x1f8] | r6 = *(0x2da54);
0x0002d85a movs r4, r1 | r4 = r1;
0x0002d85c strh r6, [r5, r1] | *((r5 + r1)) = r6;
0x0002d85e movs r4, r1 | r4 = r1;
0x0002d860 ldr r6, [pc, 0x110] | r6 = *(0x2d974);
0x0002d862 movs r4, r1 | r4 = r1;
0x0002d864 ldr r6, [pc, 0xe0] | r6 = *(0x2d948);
0x0002d866 movs r4, r1 | r4 = r1;
0x0002d868 ldr r2, [sp, 0x360] | r2 = *(arg_360h);
0x0002d86a movs r4, r1 | r4 = r1;
0x0002d86c ldr r6, [sp, 0x20] | r6 = var_20h;
0x0002d86e movs r4, r1 | r4 = r1;
0x0002d870 ldr r2, [sp, 0x238] | r2 = *(arg_238h);
0x0002d872 movs r4, r1 | r4 = r1;
0x0002d874 ldr r5, [pc, 0x300] | r5 = *(0x2db78);
0x0002d876 movs r4, r1 | r4 = r1;
0x0002d878 ldr r5, [pc, 0x2c0] | r5 = *(0x2db3c);
0x0002d87a movs r4, r1 | r4 = r1;
0x0002d87c ldr r5, [pc, 0x2d0] | r5 = *(0x2db50);
0x0002d87e movs r4, r1 | r4 = r1;
0x0002d880 ldr r5, [pc, 0x2c0] | r5 = *(0x2db44);
0x0002d882 movs r4, r1 | r4 = r1;
0x0002d884 ldr r5, [pc, 0x230] | r5 = *(0x2dab8);
0x0002d886 movs r4, r1 | r4 = r1;
0x0002d888 ldr r5, [pc, 0x250] | r5 = *(0x2dadc);
0x0002d88a movs r4, r1 | r4 = r1;
0x0002d88c ldr r5, [sp, 0x168] | r5 = *(arg_168h);
0x0002d88e movs r4, r1 | r4 = r1;
0x0002d890 ldr r5, [pc, 0x1d8] | r5 = *(0x2da6c);
0x0002d892 movs r4, r1 | r4 = r1;
0x0002d894 ldr r5, [pc, 0x1a8] | r5 = *(0x2da40);
0x0002d896 movs r4, r1 | r4 = r1;
0x0002d898 str r2, [r5, r5] | *((r5 + r5)) = r2;
0x0002d89a movs r4, r1 | r4 = r1;
0x0002d89c ldrsb r6, [r5, r3] | r6 = *((r5 + r3));
0x0002d89e movs r4, r1 | r4 = r1;
0x0002d8a0 ldr r1, [sp, 0x258] | r1 = *(arg_258h);
0x0002d8a2 movs r4, r1 | r4 = r1;
0x0002d8a4 ldr r1, [sp, 0x238] | r1 = *(arg_238h);
0x0002d8a6 movs r4, r1 | r4 = r1;
0x0002d8a8 ldr r4, [sp, 0x2f8] | r4 = *(arg_2f8h);
0x0002d8aa movs r4, r1 | r4 = r1;
0x0002d8ac ldr r4, [pc, 0x368] | r4 = *(0x2dc18);
0x0002d8ae movs r4, r1 | r4 = r1;
0x0002d8b0 ldr r4, [pc, 0x338] | r4 = *(0x2dbec);
0x0002d8b2 movs r4, r1 | r4 = r1;
0x0002d8b4 str r6, [r1, r3] | *((r1 + r3)) = r6;
0x0002d8b6 movs r4, r1 | r4 = r1;
0x0002d8b8 ldrsb r2, [r2, r1] | r2 = *((r2 + r1));
0x0002d8ba movs r4, r1 | r4 = r1;
0x0002d8bc ldr r4, [sp, 0x240] | r4 = *(arg_240h);
0x0002d8be movs r4, r1 | r4 = r1;
0x0002d8c0 ldr r4, [pc, 0x2b0] | r4 = *(0x2db74);
0x0002d8c2 movs r4, r1 | r4 = r1;
0x0002d8c4 ldr r4, [pc, 0x280] | r4 = *(0x2db48);
0x0002d8c6 movs r4, r1 | r4 = r1;
0x0002d8c8 str r0, [r4, r2] | *((r4 + r2)) = r0;
0x0002d8ca movs r4, r1 | r4 = r1;
0x0002d8cc ldrsb r4, [r4, r0] | r4 = *((r4 + r0));
0x0002d8ce movs r4, r1 | r4 = r1;
0x0002d8d0 ldr r1, [sp, 0xa8] | r1 = var_a8h;
0x0002d8d2 movs r4, r1 | r4 = r1;
0x0002d8d4 ldr r2, [pc, 8] | r2 = *(0x0002d8e0);
0x0002d8d6 ldr r1, [r1] | r1 = *(r1);
0x0002d8d8 ldr r0, [r0] | r0 = *(0x2d818);
0x0002d8da add r2, pc | r2 += pc;
0x0002d8dc b.w 0x6ba08 | void (*0x6ba08)() ();
0x000358ce movw r1, 0xfc01 |
0x000358d2 movt r1, 0xffff | r1 = 0xfffffc01;
0x000358d6 cmp.w r3, -1 |
0x000358da it eq |
| if (r3 == -1) {
0x000358dc cmpeq r5, r1 | __asm ("cmpeq r5, r1");
| }
| if (r3 != -1) {
0x000358de bne 0x359b6 | goto label_118;
| }
0x000358e0 movw r5, 0xfc02 |
0x000358e4 tst.w r2, 0x100000 |
0x000358e8 movt r5, 0xffff | r5 = 0xfffffc02;
0x000358ec it ne |
| if ((r2 & 0x100000) == 0) {
0x000358ee movne r1, r5 | r1 = r5;
| }
0x000358f0 b 0x359b8 |
| while (r8 != r4) {
0x00035966 vldr d17, [pc, 0x148] | __asm ("vldr d17, aav.0x000000ff");
0x0003596a vmov.f64 d16, 1.000000e+00 | __asm ("vmov.f64 d16, 1");
0x0003596e vadd.f64 d16, d16, d17 | __asm ("vadd.f64 d16, d16, d17");
0x00035972 vstr d16, [sp] | __asm ("vstr d16, [sp]");
0x00035976 mov r2, fp | r2 = fp;
0x00035978 mov r0, r6 | r0 = r6;
0x0003597a add sp, 0xc |
0x0003597c pop.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00035980 b.w 0x3b1f8 | goto label_119;
| label_118:
0x000359b6 mov r1, r5 | r1 = r5;
0x000359b8 orrs.w r8, r4, r8 | r8 = r4 | r8;
0x000359bc bne 0x35966 |
| }
0x000359be mov r2, fp | r2 = fp;
0x000359c0 mov r0, r6 | r0 = r6;
0x000359c2 add sp, 0xc |
0x000359c4 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000359c8 b.w 0x3b1f8 |
| label_119:
0x0003b1f8 push {r4, r5} |
0x0003b1fa addw r1, r1, 0x3ff | __asm ("addw r1, r1, aav.0x000000ff");
0x0003b1fe ldrd r4, r3, [r0] | __asm ("ldrd r4, r3, [r0]");
0x0003b200 orrs r0, r0 | r0 |= r0;
0x0003b202 ubfx r1, r1, 0, 0xb | r1 = (r1 >> 0) & ((1 << 0xb) - 1);
0x0003b206 ubfx r3, r3, 0, 0x14 | r3 = (r3 >> 0) & ((1 << 0x14) - 1);
0x0003b20a orr.w r3, r3, r1, lsl 20 | r3 |= (r1 << 20);
0x0003b20e orr.w r5, r3, r2, lsl 31 | r5 = r3 | (r2 << 31);
0x0003b212 vmov d0, r4, r5 | __asm ("vmov d0, r4, r5");
0x0003b214 ldr r3, [pc, 0x40] | r3 = *(0x3b258);
0x0003b216 pop {r4, r5} |
0x0003b218 bx lr | return;
| label_33:
0x0004bada ldr.w r3, [r7, 0x8ec] | r3 = *((r7 + 0x8ec));
0x0004bade ldrd r1, r5, [fp, 0x14] | __asm ("ldrd r1, r5, [arg_14h]");
0x0004bae2 cmp r3, 0 |
0x0004bae4 sub.w r5, r5, r1 | r5 -= r1;
0x0004bae8 asr.w r5, r5, 2 | r5 >>= 2;
| if (r3 < 0) {
0x0004baec blt.w 0x4c61c | goto label_120;
| }
0x0004baf0 ldrd sb, r4, [r7, 0x1c] | __asm ("ldrd sb, r4, [r7, 0x1c]");
0x0004baf4 ldr.w r6, [sl, 0x98] | r6 = *((sl + 0x98));
0x0004baf8 subs r4, r6, r4 | r4 = r6 - r4;
0x0004bafa cmp r4, sb |
| if (r4 >= sb) {
0x0004bafc bhs.w 0x4bdd8 | goto label_121;
| }
| label_32:
0x0004bb00 ldr r3, [r6, 0x1c] | r3 = *((r6 + 0x1c));
0x0004bb02 mov r2, r5 | r2 = r5;
0x0004bb04 mov r0, sl | r0 = sl;
0x0004bb06 blx r3 | r0 = uint32_t (*r3)(uint32_t, uint32_t, uint32_t) (r0, r2, r3);
0x0004bb08 cmp r0, r5 |
| if (r0 != r5) {
0x0004bb0a bne.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004bb0e ldr.w r2, [r7, 0x8ec] | r2 = *((r7 + 0x8ec));
0x0004bb12 movs r3, 0 | r3 = 0;
0x0004bb14 adds r0, r2, r5 | r0 = r2 + r5;
| if (r0 < r2) {
0x0004bb16 bmi.w 0x4ccde | goto label_122;
| }
0x0004bb1a cmp r0, r5 |
| if (r0 <= r5) {
0x0004bb1c blo.w 0x4ccde | goto label_122;
| }
| label_41:
0x0004bb20 str.w r0, [r7, 0x8ec] | __asm ("str.w r0, aav.0x000000ff");
0x0004bb24 cmp r3, 0 |
| if (r3 != 0) {
0x0004bb26 bne.w 0x4c8a6 | goto label_123;
| }
0x0004bb28 strh r6, [r7, 0x34] | *((r7 + 0x34)) = r6;
0x0004bb2a cmp r0, 0 |
| if (r0 < 0) {
0x0004bb2c blt.w 0x4b97e | void (*0x4b97e)() ();
| }
0x0004bb30 ldr.w r3, [r7, 0x8f0] | r3 = *((r7 + 0x8f0));
0x0004bb34 add.w fp, fp, 0x34 |
0x0004bb38 adds r3, 1 | r3++;
0x0004bb3a str.w r3, [r7, 0x8f0] | __asm ("str.w r3, aav.0x000000ff");
0x0004bb3e ldr.w r2, [r7, 0x8f0] | r2 = *((r7 + 0x8f0));
0x0004bb42 ldr r3, [r7, 0x38] | r3 = *((r7 + 0x38));
0x0004bb44 cmp r3, r2 |
| if (r3 > r2) {
0x0004bb46 bhi.w 0x4b754 | void (*0x4b754)() ();
| }
0x0004bb4a mov r4, r0 | r4 = r0;
0x0004bb4c b 0x4b9ea | void (*0x4b9ea)() ();
| label_34:
0x0004bdc0 ldr.w r6, [sl, 0x98] | r6 = *((sl + 0x98));
0x0004bdc4 ldrd r1, r5, [fp, 0x14] | __asm ("ldrd r1, r5, [arg_14h]");
0x0004bdc8 subs r4, r6, r4 | r4 = r6 - r4;
0x0004bdca cmp r4, sb |
0x0004bdcc sub.w r5, r5, r1 | r5 -= r1;
0x0004bdd0 asr.w r5, r5, 2 | r5 >>= 2;
| if (r4 <= sb) {
0x0004bdd4 blo.w 0x4bb00 | goto label_32;
| }
| label_121:
0x0004bdd8 str r1, [r7, 0x74] | *((r7 + 0x74)) = r1;
0x0004bdda bl 0x56650 | fcn_00056650 ();
0x0004bdde ldr r1, [r7, 0x74] | r1 = *((r7 + 0x74));
0x0004bde0 b 0x4bb00 | goto label_32;
0x0004c052 adds r3, 1 | r3++;
0x0004c054 str.w r3, [r7, 0x8ec] | __asm ("str.w r3, aav.0x000000ff");
0x0004c058 b 0x4bada | goto label_33;
| label_36:
0x0004c10c ldr.w r1, [r7, 0x8ec] | r1 = *((r7 + 0x8ec));
0x0004c110 mvn r3, 0x80000000 | r3 = ~0x80000000;
0x0004c114 cmp r1, r3 |
| if (r1 == r3) {
0x0004c116 beq.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004c11a mov r3, r1 | r3 = r1;
0x0004c11c subs r5, 1 | r5--;
0x0004c11e adds r3, 1 | r3++;
0x0004c120 str.w r3, [r7, 0x8ec] | __asm ("str.w r3, aav.0x000000ff");
| label_35:
0x0004c124 ldr r3, [r7, 0x3c] | r3 = *((r7 + 0x3c));
| if (r3 == 0) {
0x0004c126 cbz r3, 0x4c198 | goto label_124;
| }
0x0004c128 ldr r3, [r7, 0x54] | r3 = *((r7 + 0x54));
0x0004c12a ldr r1, [r7, 0x40] | r1 = *((r7 + 0x40));
0x0004c12c cmp r1, 0x10 |
0x0004c12e ite ne |
| if (r1 == 0x10) {
0x0004c130 movne r3, 0 | r3 = 0;
| }
| if (r1 != 0x10) {
0x0004c132 andeq r3, r3, 1 | r3 &= 1;
| }
| if (r3 == 0) {
0x0004c136 cbz r3, 0x4c198 | goto label_124;
| }
0x0004c138 ldr.w r3, [sl, 0x5c] | r3 = *((sl + 0x5c));
0x0004c13c cmp r3, 0 |
| if (r3 == 0) {
0x0004c13e beq.w 0x4cbf4 | goto label_125;
| }
0x0004c142 ldrd r1, r8, [r3, 0x10] | __asm ("ldrd r1, r8, [r3, 0x10]");
0x0004c146 cmp r1, r8 |
| if (r1 >= r8) {
0x0004c148 bhs.w 0x4cbf4 | goto label_125;
| }
0x0004c14c ldr.w r0, [r7, 0x8ec] | r0 = *((r7 + 0x8ec));
0x0004c150 add.w lr, r1, 4 | lr = r1 + 4;
0x0004c154 mov.w ip, 0x30 |
0x0004c158 str.w lr, [r3, 0x10] | __asm ("str.w lr, [r3, 0x10]");
0x0004c15c str.w ip, [r1] | __asm ("str.w ip, [r1]");
0x0004c160 mvn r1, 0x80000000 | r1 = ~0x80000000;
0x0004c164 cmp r0, r1 |
| if (r0 == r1) {
0x0004c166 beq.w 0x4b976 | void (*0x4b976)() ();
| }
| label_40:
0x0004c16a cmp lr, r8 |
| if (lr >= r8) {
0x0004c16c bhs.w 0x4cbde | goto label_39;
| }
0x0004c170 add.w r1, lr, 4 | r1 = lr + 4;
0x0004c174 str r1, [r3, 0x10] | *((r3 + 0x10)) = r1;
0x0004c176 ldr r3, [r7, 0x74] | r3 = *((r7 + 0x74));
0x0004c178 str.w r3, [lr] | __asm ("str.w r3, [lr]");
| label_38:
0x0004c17c ldr.w r1, [r7, 0x8ec] | r1 = *((r7 + 0x8ec));
0x0004c180 movw r3, 0xfffe |
0x0004c184 movt r3, 0x7fff | r3 = 0x7ffffffe;
0x0004c188 cmp r1, r3 |
| if (r1 == r3) {
0x0004c18a beq.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004c18e mov r3, r1 | r3 = r1;
0x0004c190 subs r5, 2 | r5 -= 2;
0x0004c192 adds r3, 2 | r3 += 2;
0x0004c194 str.w r3, [r7, 0x8ec] | __asm ("str.w r3, aav.0x000000ff");
| label_124:
0x0004c198 asr.w r8, r2, 2 | r8 = r2 >> 2;
0x0004c19c cmp r4, 0 |
0x0004c19e add.w r3, r8, sb | r3 = r8 + sb;
0x0004c1a2 sub.w r5, r5, r3 | r5 -= r3;
| if (r4 <= 0) {
0x0004c1a6 ble.w 0x4c316 | goto label_126;
| }
0x0004c1aa mov r2, sb | r2 = sb;
0x0004c1ac movs r1, 0x30 | r1 = 0x30;
0x0004c1ae mov r0, sl | r0 = sl;
0x0004c1b0 bl 0x51f84 | r0 = fcn_00051f84 (r0, r1, r2);
0x0004c1b4 cmp r0, sb |
| if (r0 != sb) {
0x0004c1b6 bne.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004c1ba ldr.w r3, [r7, 0x8ec] | r3 = *((r7 + 0x8ec));
0x0004c1be cmp r3, 0 |
| if (r3 < 0) {
0x0004c1c0 blt.w 0x4b97e | void (*0x4b97e)() ();
| }
0x0004c1c4 adds.w r3, r3, sb | r3 += sb;
0x0004c1c8 str.w r3, [r7, 0x8ec] | __asm ("str.w r3, aav.0x000000ff");
0x0004c1cc bvs.w 0x4c8a6 | __asm ("bvs.w aav.0x000000ff");
0x0004c1d0 cmp r3, 0 |
| if (r3 < 0) {
0x0004c1d2 bge.w 0x4c320 |
0x0004c1d6 b.w 0x4b97e | void (*0x4b97e)() ();
| label_126:
0x0004c316 ldr.w r3, [r7, 0x8ec] | r3 = *((r7 + 0x8ec));
0x0004c31a cmp r3, 0 |
| if (r3 < 0) {
0x0004c31c blt.w 0x4c61c | goto label_120;
| }
| }
0x0004c320 ldr.w r4, [pc, 0x6c0] |
0x0004c324 ldr.w sb, [pc, 0x6c0] | sb = *(0x0004c9e8);
0x0004c328 ldr.w r3, [sl, 0x98] | r3 = *((sl + 0x98));
0x0004c32c add r4, pc | r4 = 0x98d14;
0x0004c32e add sb, pc | sb += pc;
0x0004c330 sub.w sb, sb, r4 | sb -= r4;
0x0004c334 subs r2, r3, r4 | r2 = r3 - r4;
0x0004c336 cmp sb, r2 |
| if (sb < r2) {
0x0004c338 bls.w 0x4ca6a | goto label_127;
| }
| label_37:
0x0004c33c ldr r3, [r3, 0x1c] | r3 = *((r3 + 0x1c));
0x0004c33e mov r1, r6 | r1 = r6;
0x0004c340 mov r2, r8 | r2 = r8;
0x0004c342 mov r0, sl | r0 = sl;
0x0004c344 blx r3 | r0 = uint32_t (*r3)(uint32_t, uint32_t, uint32_t, uint32_t) (r0, r1, r2, r3);
0x0004c346 cmp r0, r8 |
| if (r0 != r8) {
0x0004c348 bne.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004c34c ldr.w r3, [r7, 0x8ec] | r3 = *((r7 + 0x8ec));
0x0004c350 movs r2, 0 | r2 = 0;
0x0004c352 adds.w r3, r3, r8 | r3 += r8;
| if (r3 < r3) {
0x0004c356 bmi.w 0x4cd18 | goto label_128;
| }
0x0004c35a cmp r3, r8 |
| if (r3 <= r8) {
0x0004c35c blo.w 0x4cd18 | goto label_128;
| }
| label_42:
0x0004c360 str.w r3, [r7, 0x8ec] | __asm ("str.w r3, aav.0x000000ff");
0x0004c364 cmp r2, 0 |
| if (r2 != 0) {
0x0004c366 bne.w 0x4c8a6 | goto label_123;
| }
0x0004c36a cmp r3, 0 |
| if (r3 < 0) {
0x0004c36c blt.w 0x4b97e | void (*0x4b97e)() ();
| }
0x0004c370 cmp r5, 0 |
| if (r5 <= 0) {
0x0004c372 ble.w 0x4bdc0 | goto label_34;
| }
0x0004c376 mov r2, r5 | r2 = r5;
0x0004c378 movs r1, 0x20 | r1 = 0x20;
0x0004c37a mov r0, sl | r0 = sl;
0x0004c37c bl 0x51f84 | r0 = fcn_00051f84 (r0, r1, r2);
0x0004c380 cmp r5, r0 |
| if (r5 != r0) {
0x0004c382 bne.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004c386 ldr.w r3, [r7, 0x8ec] | r3 = *((r7 + 0x8ec));
0x0004c38a adds r5, r3, r5 | r5 = r3 + r5;
0x0004c38c str.w r5, [r7, 0x8ec] | __asm ("str.w r5, aav.0x000000ff");
0x0004c390 bvs.w 0x4c8a6 | __asm ("bvs.w aav.0x000000ff");
0x0004c394 cmp r5, 0 |
| if (r5 >= 0) {
0x0004c396 bge.w 0x4bdc0 | goto label_34;
| }
0x0004c39a b.w 0x4b97e | void (*0x4b97e)() ();
| label_120:
0x0004c61c bl 0x4b2c0 | fcn_0004b2c0 (r0, r1, r2, r3, r4, r5);
0x0004c620 ldr r3, [r7, 0x58] | r3 = *((r7 + 0x58));
0x0004c622 cmp r3, 0 |
| if (r3 == 0) {
0x0004c624 beq.w 0x4c124 | goto label_35;
| }
0x0004c628 ldr.w r3, [sl, 0x5c] | r3 = *((sl + 0x5c));
| if (r3 == 0) {
0x0004c62c cbz r3, 0x4c642 | goto label_129;
| }
0x0004c62e ldrd r1, r0, [r3, 0x10] | __asm ("ldrd r1, r0, [r3, 0x10]");
0x0004c632 cmp r1, r0 |
0x0004c634 itttt lo |
| if (r1 >= r0) {
0x0004c636 addlo r0, r1, 4 | r0 = r1 + 4;
| }
| if (r1 >= r0) {
0x0004c638 strlo r0, [r3, 0x10] | *((r3 + 0x10)) = r0;
| }
| if (r1 >= r0) {
0x0004c63a movlo r3, 0x20 | r3 = 0x20;
| }
| if (r1 < r0) {
0x0004c63c strlo r3, [r1] | *(r1) = r3;
| goto label_130;
| }
| if (r1 <= r0) {
| label_130:
0x0004c63e blo.w 0x4c10c | goto label_36;
| }
| label_129:
0x0004c642 movs r1, 0x20 | r1 = 0x20;
0x0004c644 str r2, [r7, 0x6c] | *((r7 + 0x6c)) = r2;
0x0004c646 mov r0, sl | r0 = sl;
0x0004c648 bl 0x529ec | woverflow ();
0x0004c64c adds r0, 1 | r0++;
0x0004c64e ldr r2, [r7, 0x6c] | r2 = *((r7 + 0x6c));
| if (r0 != 1) {
0x0004c650 bne.w 0x4c10c | goto label_36;
| }
0x0004c654 b.w 0x4b976 | void (*0x4b976)() ();
| label_123:
0x0004c8a6 ldr r3, [pc, 0x11c] |
0x0004c8a8 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x0004c8ac movs r1, 0x4b | r1 = 0x4b;
0x0004c8ae add r3, pc |
0x0004c8b0 ldr r3, [r3] | r3 = *(0x99278);
0x0004c8b2 str r1, [r2, r3] | *((r2 + r3)) = r1;
0x0004c8b4 mov.w r3, -1 | r3 = -1;
0x0004c8b8 str.w r3, [r7, 0x8ec] | __asm ("str.w r3, aav.0x000000ff");
0x0004c8bc b.w 0x4b97e | void (*0x4b97e)() ();
| label_127:
0x0004ca6a str r3, [r7, 0x74] | *((r7 + 0x74)) = r3;
0x0004ca6c bl 0x56650 | fcn_00056650 ();
0x0004ca70 ldr r3, [r7, 0x74] | r3 = *((r7 + 0x74));
0x0004ca72 b 0x4c33c | goto label_37;
| label_39:
0x0004cbde ldr r1, [r7, 0x74] | r1 = *((r7 + 0x74));
0x0004cbe0 mov r0, sl | r0 = sl;
0x0004cbe2 str r2, [r7, 0x6c] | *((r7 + 0x6c)) = r2;
0x0004cbe4 bl 0x529ec | woverflow ();
0x0004cbe8 adds r0, 1 | r0++;
0x0004cbea ldr r2, [r7, 0x6c] | r2 = *((r7 + 0x6c));
| if (r0 != 1) {
0x0004cbec bne.w 0x4c17c | goto label_38;
| }
0x0004cbf0 b.w 0x4b976 | void (*0x4b976)() ();
| label_125:
0x0004cbf4 movs r1, 0x30 | r1 = 0x30;
0x0004cbf6 mov r0, sl | r0 = sl;
0x0004cbf8 str r2, [r7, 0x6c] | *((r7 + 0x6c)) = r2;
0x0004cbfa bl 0x529ec | woverflow ();
0x0004cbfe adds r0, 1 | r0++;
0x0004cc00 ldr r2, [r7, 0x6c] | r2 = *((r7 + 0x6c));
| if (r0 == 1) {
0x0004cc02 beq.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004cc06 ldr.w r1, [r7, 0x8ec] | r1 = *((r7 + 0x8ec));
0x0004cc0a mvn r3, 0x80000000 | r3 = ~0x80000000;
0x0004cc0e cmp r1, r3 |
| if (r1 == r3) {
0x0004cc10 beq.w 0x4b976 | void (*0x4b976)() ();
| }
0x0004cc14 ldr.w r3, [sl, 0x5c] | r3 = *((sl + 0x5c));
0x0004cc18 cmp r3, 0 |
| if (r3 == 0) {
0x0004cc1a beq 0x4cbde | goto label_39;
| }
0x0004cc1c ldrd lr, r8, [r3, 0x10] | __asm ("ldrd lr, r8, [r3, 0x10]");
0x0004cc20 b.w 0x4c16a | goto label_40;
| label_122:
0x0004ccde movs r3, 1 | r3 = 1;
0x0004cce0 b.w 0x4bb20 | goto label_41;
| label_128:
0x0004cd18 movs r2, 1 | r2 = 1;
0x0004cd1a b.w 0x4c360 | goto label_42;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x55fa4 */
| #include <stdint.h>
|
; (fcn) fcn.00055fa4 () | void fcn_00055fa4 (int16_t arg1) {
| size_t s2;
| int16_t var_4h;
| int16_t var_8h_2;
| int16_t var_ch;
| int16_t var_10h;
| int16_t var_8h;
| int32_t var_4h_3;
| int32_t var_ch_2;
| int16_t var_0h_2;
| int16_t var_34h;
| int16_t var_4h_2;
| r0 = arg1;
0x00055fa4 push {r1, r2, r3} |
0x00055fa6 push.w {r4, r5, r6, r7, r8, sb, sl, lr} |
0x00055faa sub sp, 0x1c |
0x00055fac add r7, sp, 8 | r7 += var_8h;
0x00055fae add.w r3, r7, 0x34 | r3 += var_34h;
0x00055fb2 movs r5, 0 | r5 = 0;
0x00055fb4 ldr sl, [r3], 4 | sl = *(r3);
| r3 += 4;
0x00055fb8 and r8, r0, 1 | r8 = r0 & 1;
0x00055fbc ldr.w sb, [pc, 0x140] | sb = *(0x00056100);
0x00055fc0 mov r6, r5 | r6 = r5;
0x00055fc2 ldrb.w r4, [sl] | r4 = *(sl);
0x00055fc6 add sb, pc | sb += pc;
0x00055fc8 str r3, [r7, 0xc] | var_ch_2 = r3;
0x00055fca cmp r4, 0 |
| if (r4 == 0) {
0x00055fcc beq 0x5608c | goto label_3;
| }
| label_1:
0x00055fce mov r3, r4 | r3 = r4;
0x00055fd0 mov r0, sl | r0 = sl;
0x00055fd2 b 0x55fe0 |
| while (r3 != 0x25) {
| label_0:
0x00055fd4 adds r0, 1 | r0++;
0x00055fd6 movs r1, 0x25 | r1 = 0x25;
0x00055fd8 bl 0x6c8b8 | r0 = strchrnul ();
0x00055fdc ldrb r3, [r0] | r3 = *(r0);
| if (r3 == 0) {
0x00055fde cbz r3, 0x55fea | goto label_4;
| }
0x00055fe0 cmp r3, 0x25 |
0x00055fe2 bne 0x55fd4 |
| }
0x00055fe4 ldrb r3, [r0, 1] | r3 = *((r0 + 1));
0x00055fe6 cmp r3, 0x73 |
| if (r3 != 0x73) {
0x00055fe8 bne 0x55fd4 | goto label_0;
| }
| label_4:
0x00055fea cmp r4, 0x25 |
0x00055fec beq 0x5600e |
| while (r3 != 0x73) {
0x00055fee sub.w ip, r0, sl |
0x00055ff2 mov r1, sl | r1 = sl;
0x00055ff4 mov sl, r0 | sl = r0;
| label_2:
0x00055ff6 sub sp, 0x10 |
0x00055ff8 adds r2, r5, 1 | r2 = r5 + 1;
0x00055ffa strd r1, ip, [sp, 8] | __asm ("strd r1, ip, [var_8h_2]");
0x00055ffe add r3, sp, 8 | r3 += var_8h_2;
0x00056000 str r6, [sp, 0x10] | var_10h = r6;
0x00056002 ldrb.w r4, [sl] | r4 = *(sl);
| if (r4 == 0) {
0x00056006 cbz r4, 0x56030 | goto label_5;
| }
0x00056008 mov r5, r2 | r5 = r2;
0x0005600a mov r6, r3 | r6 = r3;
0x0005600c b 0x55fce | goto label_1;
0x0005600e ldrb.w r3, [sl, 1] | r3 = *((sl + 1));
0x00056012 cmp r3, 0x73 |
0x00056014 bne 0x55fee |
| }
0x00056016 ldr r3, [r7, 0xc] | r3 = var_ch_2;
0x00056018 add.w sl, sl, 2 | sl += 2;
0x0005601c ldr r1, [r3] | r1 = *(r3);
0x0005601e adds r3, 4 | r3 += 4;
0x00056020 str r3, [r7, 0xc] | var_ch_2 = r3;
0x00056022 mov r0, r1 | r0 = r1;
0x00056024 str r1, [r7, 4] | var_4h_3 = r1;
0x00056026 bl 0x6a8c0 | strlen ();
0x0005602a ldr r1, [r7, 4] | r1 = var_4h_3;
0x0005602c mov ip, r0 |
0x0005602e b 0x55ff6 | goto label_2;
| label_5:
0x00056030 mov r3, sp | r3 = sp;
0x00056032 lsl.w sl, r2, 3 | sl = r2 << 3;
0x00056036 sub.w r3, r3, r2, lsl 3 | r3 -= (r2 << 3);
0x0005603a mov sp, r3 |
0x0005603c mov r3, r4 | r3 = r4;
0x0005603e add r0, sp, 0xc | r0 += var_ch;
0x00056040 add r4, sp, 8 | r4 += var_8h_2;
0x00056042 b 0x5604a |
| while (r1 != r5) {
0x00056044 ldrd r1, ip, [r6] | __asm ("ldrd r1, ip, [r6]");
0x00056048 ldr r6, [r6, 8] | r6 = *((r6 + 8));
0x0005604a str.w r1, [r4, r5, lsl 3] | __asm ("str.w r1, [r4, r5, lsl 3]");
0x0005604e add r3, ip | r3 += ip;
0x00056050 str.w ip, [r0, r5, lsl 3] | __asm ("str.w ip, [r0, r5, lsl 3]");
0x00056054 subs r5, 1 | r5--;
0x00056056 adds r1, r5, 1 | r1 = r5 + 1;
0x00056058 bne 0x56044 |
| }
| do {
0x0005605a movs r0, 2 | r0 = 2;
0x0005605c mov r1, r4 | r1 = r4;
0x0005605e mov.w ip, 0x92 |
0x00056062 bl 0x21990 | r0 = fcn_00021990 ();
0x00056066 adds r5, r0, 4 | r5 = r0 + 4;
0x00056068 ite ne |
| if (r5 == r0) {
0x0005606a movne r1, 0 | r1 = 0;
| }
| if (r5 != r0) {
0x0005606c moveq r1, 1 | r1 = 1;
| }
0x0005606e cmn.w r0, 0x1000 |
0x00056072 it ls |
| if (r0 > 0x1000) {
0x00056074 movls r1, 0 | r1 = 0;
| }
0x00056076 cmp r1, 0 |
0x00056078 bne 0x5605a |
| } while (r1 != 0);
0x0005607a cmp.w r8, 0 |
| if (r8 != 0) {
0x0005607e bne 0x56094 | goto label_6;
| }
| do {
0x00056080 adds r7, 0x14 | r7 += 0x14;
0x00056082 mov sp, r7 |
0x00056084 pop.w {r4, r5, r6, r7, r8, sb, sl, lr} |
0x00056088 add sp, 0xc |
0x0005608a bx lr | return;
| label_3:
0x0005608c cmp.w r8, 0 |
0x00056090 beq 0x56080 |
| } while (r8 == 0);
0x00056092 b 0x560f2 | goto label_7;
| label_6:
0x00056094 ldr r2, [pc, 0x6c] |
0x00056096 mov r0, r1 | r0 = r1;
0x00056098 ldr.w r2, [sb, r2] | r2 = *((sb + r2));
0x0005609c str r1, [sp, 4] | var_4h = r1;
0x0005609e ldr r2, [r2, 0x10] | r2 = *(0x56114);
0x000560a0 add r3, r2 | r3 += r2;
0x000560a2 rsbs r2, r2, 0 | r2 -= ;
0x000560a4 and.w r5, r3, r2 | r5 = r3 & r2;
0x000560a8 mov.w r2, -1 | r2 = -1;
0x000560ac movs r3, 0x22 | r3 = 0x22;
0x000560ae str r2, [sp] | *(sp) = r2;
0x000560b0 mov r1, r5 | r1 = r5;
0x000560b2 movs r2, 3 | r2 = 3;
0x000560b4 bl 0xa9f88 | r0 = mmap ()
0x000560b8 adds r3, r0, 1 | r3 = r0 + 1;
0x000560ba mov r6, r0 | r6 = r0;
| if (r3 == r0) {
0x000560bc beq 0x560f2 | goto label_7;
| }
0x000560be add sl, r4 | sl += r4;
0x000560c0 str r5, [r0], 4 | *(r0) = r5;
| r0 += 4;
| do {
0x000560c4 ldrd r1, r2, [r4] | __asm ("ldrd r1, r2, [r4]");
0x000560c8 adds r4, 8 | r4 += 8;
0x000560ca blx 0x6fa80 | memcpy (r0, r1, r2);
0x000560ce cmp sl, r4 |
0x000560d0 ldr r3, [r4, -0x4] | r3 = *((r4 - 0x4));
0x000560d4 add r0, r3 | r0 += r3;
0x000560d6 bne 0x560c4 |
| } while (sl != r4);
0x000560d8 ldr r3, [pc, 0x2c] |
0x000560da movs r2, 0 | r2 = 0;
0x000560dc strb r2, [r0] | *(r0) = r2;
0x000560de add r3, pc | r3 = 0xac1ea;
| do {
0x000560e0 ldrex r0, [r3] | __asm ("ldrex r0, [r3]");
0x000560e4 strex r2, r6, [r3] | __asm ("strex r2, r6, [r3]");
0x000560e8 cmp r2, 0 |
0x000560ea bne 0x560e0 |
| } while (r2 != 0);
0x000560ec dmb ish | __asm ("dmb ish");
0x000560f0 cbnz r0, 0x560f6 |
| while (1) {
| label_7:
0x000560f2 bl 0x21388 | r0 = abort ();
0x000560f6 ldr r1, [r0] | r1 = *(r0);
0x000560f8 bl 0xaa040 | munmap ();
0x000560fc b 0x560f2 |
| }
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x62c54 */
| #include <stdint.h>
|
; (fcn) fcn.00062c54 () | void fcn_00062c54 (int16_t arg1, char * arg2, int16_t arg3) {
| int32_t var_0h;
| int32_t var_0h_2;
| int16_t var_8h;
| int32_t var_8h_3;
| int32_t var_60h;
| int16_t var_70h;
| int32_t var_8h_2;
| void * s1;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
0x00062c54 push.w {r4, r5, r6, r7, r8, sb, sl, lr} |
0x00062c58 sub sp, 0x188 |
0x00062c5a mov r8, r0 | r8 = r0;
0x00062c5c mov r7, r1 | r7 = r1;
0x00062c5e mov r4, r2 | r4 = r2;
0x00062c60 bl 0x6a8c0 | r0 = strlen ();
0x00062c64 cmp r0, 0xff |
0x00062c66 it hi |
| if (r0 <= 0xff) {
0x00062c68 movhi r6, 0 | r6 = 0;
| }
| if (r0 > 0xff) {
0x00062c6a bhi 0x62d04 | goto label_1;
| }
0x00062c6c add.w sb, sp, 8 | sb += var_8h;
0x00062c70 mov r5, r0 | r5 = r0;
0x00062c72 mov r1, sb | r1 = sb;
0x00062c74 mov r0, r7 | r0 = r7;
0x00062c76 bl 0x9eab8 | r0 = fstat64 ();
0x00062c7a cmp r0, 0 |
| if (r0 != 0) {
0x00062c7c bne 0x62d0c | goto label_5;
| }
0x00062c7e ldr r0, [pc, 0x154] |
0x00062c80 movs r3, 1 | r3 = 1;
0x00062c82 add r0, pc | r0 = 0xc5a5c;
| do {
0x00062c84 ldrex r2, [r0] | __asm ("ldrex r2, [r0]");
0x00062c88 cmp r2, 0 |
| if (r2 != 0) {
0x00062c8a bne 0x62c98 | goto label_6;
| }
0x00062c8c strex r1, r3, [r0] | __asm ("strex r1, r3, [r0]");
0x00062c90 cmp r1, 0 |
0x00062c92 bne 0x62c84 |
| } while (r1 != 0);
0x00062c94 dmb ish | __asm ("dmb ish");
| if (r1 != 0) {
| label_6:
0x00062c98 bne.w 0x62db2 | goto label_7;
| }
| label_3:
0x00062c9c add.w sl, r5, 1 | sl = r5 + 1;
0x00062ca0 mov r1, r8 | r1 = r8;
0x00062ca2 mov r2, sl | r2 = sl;
0x00062ca4 add r0, sp, 0x84 | r0 += s1;
0x00062ca6 blx 0x6fa80 | memcpy (r0, r1, r2);
0x00062caa ldr r1, [pc, 0x12c] |
0x00062cac add r0, sp, 0x70 | r0 += var_70h;
0x00062cae ldr r2, [pc, 0x12c] |
0x00062cb0 ldr.w r3, [sb, 0x60] | r3 = var_60h;
0x00062cb4 vldr d16, [sp, 8] | __asm ("vldr d16, [sp, 8]");
0x00062cb8 add r1, pc | r1 = 0xc5a96;
0x00062cba adds r1, 4 | r1 += 4;
0x00062cbc add r2, pc | r2 = 0xc5a9e;
0x00062cbe str r3, [r0, 8] | var_8h_2 = r3;
0x00062cc0 vstr d16, [sp, 0x70] | __asm ("vstr d16, [sp, 0x70]");
0x00062cc4 bl 0xaaef8 | r0 = tfind ();
0x00062cc8 mov r6, r0 | r6 = r0;
0x00062cca cmp r0, 0 |
| if (r0 == 0) {
0x00062ccc beq 0x62d46 | goto label_8;
| }
0x00062cce ldr r3, [r0] | r3 = *(r0);
0x00062cd0 subs r1, r4, 1 | r1 = r4 - 1;
0x00062cd2 ldrd r2, r6, [r3, 0xc] | __asm ("ldrd r2, r6, [r3, 0xc]");
0x00062cd6 subs r5, r4, r6 | r5 = r4 - r6;
0x00062cd8 add.w r2, r2, 1 | r2++;
0x00062cdc it ne |
| if (r5 == r4) {
0x00062cde movne r5, 1 | r5 = 1;
| }
0x00062ce0 adds r1, 3 | r1 += 3;
0x00062ce2 it hi |
| if (r1 <= 3) {
0x00062ce4 movhi r5, 0 | r5 = 0;
| }
0x00062ce6 str r2, [r3, 0xc] | *((r3 + 0xc)) = r2;
| label_0:
0x00062ce8 ldr r0, [pc, 0xf4] |
0x00062cea movs r2, 0 | r2 = 0;
0x00062cec dmb ish | __asm ("dmb ish");
0x00062cf0 add r0, pc | r0 = 0xc5ad4;
| do {
0x00062cf2 ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x00062cf6 strex r1, r2, [r0] | __asm ("strex r1, r2, [r0]");
0x00062cfa cmp r1, 0 |
0x00062cfc bne 0x62cf2 |
| } while (r1 != 0);
0x00062cfe cmp r3, 1 |
| if (r3 > 1) {
0x00062d00 bgt 0x62d90 | goto label_9;
| }
| if (r5 != 0) {
0x00062d02 cbnz r5, 0x62d20 | goto label_2;
| }
| do {
| label_1:
0x00062d04 mov r0, r6 | r0 = r6;
0x00062d06 add sp, 0x188 |
0x00062d08 pop.w {r4, r5, r6, r7, r8, sb, sl, pc} |
| label_5:
0x00062d0c movs r6, 0 | r6 = 0;
0x00062d0e subs r3, r4, 1 | r3 = r4 - 1;
0x00062d10 subs r5, r4, r6 | r5 = r4 - r6;
0x00062d12 it ne |
| if (r5 == r4) {
0x00062d14 movne r5, 1 | r5 = 1;
| }
0x00062d16 adds r3, 3 | r3 += 3;
0x00062d18 it hi |
| if (r3 <= 3) {
0x00062d1a movhi r5, 0 | r5 = 0;
| }
0x00062d1c cmp r5, 0 |
0x00062d1e beq 0x62d04 |
| } while (r5 == 0);
| label_2:
0x00062d20 ldr r2, [pc, 0xa8] |
0x00062d22 mrc p15, 0, r3, c13, c0, 3 | __asm ("mrc p15, 0, r3, c13, c0, 3");
0x00062d26 movs r1, 0x10 | r1 = 0x10;
0x00062d28 mov r0, r4 | r0 = r4;
0x00062d2a mov r4, r3 | r4 = r3;
0x00062d2c add r2, pc |
0x00062d2e ldr r2, [r2] | r2 = *(0xc5afc);
0x00062d30 ldr r5, [r3, r2] | r5 = *((r3 + r2));
0x00062d32 bl 0xaa040 | munmap ();
0x00062d36 ldr r3, [pc, 0x98] |
0x00062d38 mov r0, r6 | r0 = r6;
0x00062d3a add r3, pc |
0x00062d3c ldr r3, [r3] | r3 = *(0xc5b10);
0x00062d3e str r5, [r4, r3] | *((r4 + r3)) = r5;
0x00062d40 add sp, 0x188 |
0x00062d42 pop.w {r4, r5, r6, r7, r8, sb, sl, pc} |
| label_8:
0x00062d46 add.w r0, r5, 0x19 | r0 = r5 + 0x19;
0x00062d4a blx 0x21354 | r0 = fcn_00021354 ();
0x00062d4e mov r5, r0 | r5 = r0;
| if (r0 == 0) {
0x00062d50 cbz r0, 0x62da0 | goto label_10;
| }
| if (r4 == 0) {
0x00062d52 cbz r4, 0x62db8 | goto label_11;
| }
| label_4:
0x00062d54 ldr.w r3, [sb, 0x60] | r3 = var_60h;
0x00062d58 mov r1, r8 | r1 = r8;
0x00062d5a ldrd r8, sb, [sp, 8] | __asm ("ldrd r8, sb, [var_8h]");
0x00062d5e mov r2, sl | r2 = sl;
0x00062d60 add.w r0, r5, 0x14 | r0 = r5 + 0x14;
0x00062d64 str r4, [r5, 0x10] | *((r5 + 0x10)) = r4;
0x00062d66 str r3, [r5, 8] | *((r5 + 8)) = r3;
0x00062d68 movs r3, 1 | r3 = 1;
0x00062d6a str r3, [r5, 0xc] | *((r5 + 0xc)) = r3;
0x00062d6c strd r8, sb, [r5] | __asm ("strd r8, sb, [r5]");
0x00062d70 blx 0x6fa80 | memcpy (r0, r1, r2);
0x00062d74 adds r3, r4, 1 | r3 = r4 + 1;
| if (r3 == r4) {
0x00062d76 beq 0x62d9a | goto label_12;
| }
0x00062d78 ldr r1, [pc, 0x68] |
0x00062d7a mov r0, r5 | r0 = r5;
0x00062d7c ldr r2, [pc, 0x68] |
0x00062d7e add r1, pc | r1 = 0xc5b66;
0x00062d80 add r2, pc | r2 = 0xc5b6c;
0x00062d82 adds r1, 4 | r1 += 4;
0x00062d84 bl 0xaae0c | r0 = tsearch ();
| if (r0 == 0) {
0x00062d88 cbz r0, 0x62d9a | goto label_12;
| }
0x00062d8a mov r6, r4 | r6 = r4;
0x00062d8c movs r5, 0 | r5 = 0;
0x00062d8e b 0x62ce8 | goto label_0;
| label_9:
0x00062d90 bl 0x5a6c0 | lll_lock_wake_private ();
0x00062d94 cmp r5, 0 |
| if (r5 == 0) {
0x00062d96 beq 0x62d04 | goto label_1;
| }
0x00062d98 b 0x62d20 | goto label_2;
| label_12:
0x00062d9a mov r0, r5 | r0 = r5;
0x00062d9c blx 0x212d4 | fcn_000212d4 ();
| label_10:
0x00062da0 subs r5, r4, 0 | r5 = r4 - 0;
0x00062da2 add.w r3, r4, -1 | r3 = r4 + -1;
0x00062da6 it ne |
| if (r5 == r4) {
0x00062da8 movne r5, 1 | r5 = 1;
| }
0x00062daa adds r3, 3 | r3 += 3;
0x00062dac it hi |
| if (r3 <= 3) {
0x00062dae movhi r5, 0 | r5 = 0;
| }
0x00062db0 b 0x62ce8 | goto label_0;
| label_7:
0x00062db2 bl 0x5a624 | lll_lock_wait_private ();
0x00062db6 b 0x62c9c | goto label_3;
| label_11:
0x00062db8 mov r0, r4 | r0 = r4;
0x00062dba strd r7, r4, [sp] | __asm ("strd r7, r4, [sp]");
0x00062dbe movs r3, 1 | r3 = 1;
0x00062dc0 movs r2, 3 | r2 = 3;
0x00062dc2 movs r1, 0x10 | r1 = 0x10;
0x00062dc4 bl 0xa9f88 | r0 = mmap ()
0x00062dc8 mov r4, r0 | r4 = r0;
0x00062dca b 0x62d54 | goto label_4;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x65f64 */
| #include <stdint.h>
|
; (fcn) fcn.00065f64 () | void fcn_00065f64 (uint32_t arg1) {
| int32_t var_0h;
| int32_t var_0h_2;
| r0 = arg1;
0x00065f64 ldr r3, [pc, 0x100] |
0x00065f66 add r1, r0 | r1 += r0;
0x00065f68 ldr r2, [pc, 0x100] | r2 = *(0x6606c);
0x00065f6a cmp.w r1, 0x8000 |
0x00065f6e push {r4, r5, r6, r7, lr} |
0x00065f70 sub sp, 0xc |
0x00065f72 add r3, pc |
0x00065f74 ldr r3, [r3, r2] | r3 = *(0xcbfde);
0x00065f76 ldr r5, [r3, 0x10] | r5 = *(0xcbfee);
| if (r1 <= 0x8000) {
0x00065f78 blo 0x66016 | goto label_4;
| }
0x00065f7a cmp.w r1, 0x100000 |
| if (r1 > 0x100000) {
0x00065f7e bhi 0x6601c | goto label_5;
| }
| do {
| label_0:
0x00065f80 ldr r6, [pc, 0xec] |
0x00065f82 subs r3, r5, 1 | r3 = r5 - 1;
0x00065f84 add r3, r1 | r3 += r1;
0x00065f86 rsbs r5, r5, 0 | r5 -= ;
0x00065f88 ands r5, r3 | r5 &= r3;
0x00065f8a add r6, pc | r6 = 0xcbffe;
0x00065f8c ldr r0, [r6, 8] | r0 = *(0xcc006);
| if (r0 != 0) {
0x00065f8e cbz r0, 0x65fbe |
0x00065f90 movs r7, 0 | r7 = 0;
0x00065f92 mov.w r3, -1 | r3 = -1;
0x00065f96 mov.w r1, 0x100000 | r1 = 0x100000;
0x00065f9a strd r3, r7, [sp] | __asm ("strd r3, r7, [sp]");
0x00065f9e mov r2, r7 | r2 = r7;
0x00065fa0 movw r3, 0x4022 | r3 = 0x4022;
0x00065fa4 bl 0xa9f88 | r0 = mmap ()
0x00065fa8 adds r1, r0, 1 | r1 = r0 + 1;
0x00065faa mov r4, r0 | r4 = r0;
0x00065fac str r7, [r6, 8] | *((r6 + 8)) = r7;
| if (r1 == r0) {
0x00065fae beq 0x65fbe | goto label_6;
| }
0x00065fb0 ubfx r3, r0, 0, 0x14 | r3 = (r0 >> 0) & ((1 << 0x14) - 1);
| if (r3 == 0) {
0x00065fb4 cbz r3, 0x66000 | goto label_2;
| }
0x00065fb6 mov.w r1, 0x100000 | r1 = 0x100000;
0x00065fba bl 0xaa040 | munmap ();
| }
| label_6:
0x00065fbe movs r6, 0 | r6 = 0;
0x00065fc0 mov.w r1, -1 | r1 = -1;
0x00065fc4 mov r2, r6 | r2 = r6;
0x00065fc6 strd r1, r6, [sp] | __asm ("strd r1, r6, [sp]");
0x00065fca movw r3, 0x4022 | r3 = 0x4022;
0x00065fce mov.w r1, 0x200000 | r1 = 0x200000;
0x00065fd2 mov r0, r6 | r0 = r6;
0x00065fd4 bl 0xa9f88 | r0 = mmap ()
0x00065fd8 adds r2, r0, 1 | r2 = r0 + 1;
| if (r2 == r0) {
0x00065fda beq 0x6602c | goto label_7;
| }
0x00065fdc add.w r4, r0, 0xff000 | r4 = r0 + 0xff000;
0x00065fe0 addw r4, r4, 0xfff | __asm ("addw r4, r4, aav.0x000000ff");
0x00065fe4 lsrs r4, r4, 0x14 | r4 >>= 0x14;
0x00065fe6 lsls r4, r4, 0x14 | r4 <<= 0x14;
0x00065fe8 subs r6, r4, r0 | r6 = r4 - r0;
0x00065fea add.w r7, r4, 0x100000 | r7 = r4 + 0x100000;
| if (r6 != r4) {
0x00065fee bne 0x6605a | goto label_8;
| }
0x00065ff0 ldr r3, [pc, 0x80] |
0x00065ff2 add r3, pc | r3 = 0xcc06a;
0x00065ff4 str r7, [r3, 8] | *((r3 + 8)) = r7;
| label_3:
0x00065ff6 rsb.w r1, r6, 0x100000 | r1 = 0x100000 - r6;
0x00065ffa mov r0, r7 | r0 = r7;
0x00065ffc bl 0xaa040 | munmap ();
| label_2:
0x00066000 movs r2, 3 | r2 = 3;
0x00066002 mov r1, r5 | r1 = r5;
0x00066004 mov r0, r4 | r0 = r4;
0x00066006 bl 0xaa060 | r0 = mprotect ();
| if (r0 != 0) {
0x0006600a cbnz r0, 0x66062 | goto label_9;
| }
0x0006600c strd r5, r5, [r4, 8] | __asm ("strd r5, r5, [r4, 8]");
| label_1:
0x00066010 mov r0, r4 | r0 = r4;
0x00066012 add sp, 0xc |
0x00066014 pop {r4, r5, r6, r7, pc} |
| label_4:
0x00066016 mov.w r1, 0x8000 | r1 = 0x8000;
0x0006601a b 0x65f80 |
| } while (1);
| label_5:
0x0006601c cmp.w r0, 0x100000 |
0x00066020 it ls |
| if (r0 <= 0x100000) {
0x00066022 movls r1, 0x100000 | r1 = 0x100000;
| goto label_10;
| }
| if (r0 < 0x100000) {
| label_10:
0x00066026 bls 0x65f80 | goto label_0;
| }
| do {
0x00066028 movs r4, 0 | r4 = 0;
0x0006602a b 0x66010 | goto label_1;
| label_7:
0x0006602c movw r3, 0x4022 | r3 = 0x4022;
0x00066030 strd r0, r6, [sp] | __asm ("strd r0, r6, [sp]");
0x00066034 mov r2, r6 | r2 = r6;
0x00066036 mov.w r1, 0x100000 | r1 = 0x100000;
0x0006603a mov r0, r6 | r0 = r6;
0x0006603c bl 0xa9f88 | r0 = mmap ()
0x00066040 adds r3, r0, 1 | r3 = r0 + 1;
0x00066042 mov r4, r0 | r4 = r0;
0x00066044 beq 0x66028 |
| } while (r3 == r0);
0x00066046 ubfx r3, r0, 0, 0x14 | r3 = (r0 >> 0) & ((1 << 0x14) - 1);
0x0006604a cmp r3, 0 |
| if (r3 == 0) {
0x0006604c beq 0x66000 | goto label_2;
| }
| do {
0x0006604e mov.w r1, 0x100000 | r1 = 0x100000;
0x00066052 movs r4, 0 | r4 = 0;
0x00066054 bl 0xaa040 | munmap ();
0x00066058 b 0x66010 | goto label_1;
| label_8:
0x0006605a mov r1, r6 | r1 = r6;
0x0006605c bl 0xaa040 | munmap ();
0x00066060 b 0x65ff6 | goto label_3;
| label_9:
0x00066062 mov r0, r4 | r0 = r4;
0x00066064 b 0x6604e |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x66e1c */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.00066e1c () | void fcn_00066e1c (int16_t arg_0h, int16_t arg_4h, int16_t arg_e0h, int16_t arg_148h, int16_t arg_388h, int16_t arg1, uint32_t arg2, int16_t arg3) {
| int16_t var_8h_2;
| int16_t var_ch_2;
| int16_t var_10h_2;
| int16_t var_0h;
| int16_t var_4h;
| int16_t var_8h;
| int16_t var_ch;
| int16_t var_10h;
| int16_t var_14h;
| int16_t var_18h;
| int16_t var_1ch;
| int16_t var_27h;
| int16_t var_40h;
| int8_t var_fh;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
0x00066e1c ldr.w r3, [pc, 0x5f4] | r3 = fcn.000a7038;
0x00066e20 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00066e24 sub sp, 0x2c |
0x00066e26 mov r7, r2 | r7 = r2;
0x00066e28 add r3, pc | r3 += pc;
0x00066e2a str r3, [sp, 0x10] | var_10h = r3;
0x00066e2c ldr r3, [r1, 4] | r3 = *((r1 + 4));
0x00066e2e bic r5, r3, 7 | r5 = BIT_MASK (r3, 7);
0x00066e32 rsbs r2, r5, 0 | r2 = r5 - ;
0x00066e34 cmp r2, r1 |
| if (r2 <= r1) {
0x00066e36 blo.w 0x6712e | goto label_34;
| }
0x00066e3a ands fp, r1, 7 |
0x00066e3e mov r4, r1 | r4 = r1;
| if (fp != r1) {
0x00066e40 bne.w 0x6712e | goto label_34;
| }
0x00066e44 cmp r5, 0xf |
| if (r5 < 0xf) {
0x00066e46 bls.w 0x671e0 | goto label_35;
| }
0x00066e4a ldr.w r2, [pc, 0x5cc] |
0x00066e4e mov r6, r0 | r6 = r0;
0x00066e50 add r2, pc |
0x00066e52 ldr r2, [r2, 4] | r2 = *(0xce272);
0x00066e54 cmp r5, r2 |
| if (r5 > r2) {
0x00066e56 bhi 0x66edc | goto label_36;
| }
0x00066e58 add.w r8, r1, r5 | r8 = r1 + r5;
0x00066e5c ldr.w r3, [r8, 4] | r3 = *((r8 + 4));
0x00066e60 cmp r3, 8 |
| if (r3 < 8) {
0x00066e62 bls.w 0x671e8 | goto label_37;
| }
0x00066e66 ldr.w r2, [r0, 0x450] | r2 = *(arg_0hx450);
0x00066e6a bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x00066e6e cmp r3, r2 |
| if (r3 >= r2) {
0x00066e70 bhs.w 0x671e8 | goto label_37;
| }
| label_6:
0x00066e74 ldr.w r3, [pc, 0x5a4] |
0x00066e78 add r3, pc | r3 = 0xce298;
0x00066e7a ldr r1, [r3] | r1 = *(0xce298);
0x00066e7c cmp r1, 0 |
| if (r1 != 0) {
0x00066e7e bne.w 0x67298 | goto label_38;
| }
| label_11:
0x00066e82 movs r3, 1 | r3 = 1;
0x00066e84 lsrs r5, r5, 3 | r5 >>= 3;
0x00066e86 str r3, [r6, 8] | *((r6 + 8)) = r3;
0x00066e88 mrc p15, 0, r3, c13, c0, 3 | __asm ("mrc p15, 0, r3, c13, c0, 3");
0x00066e8c sub.w r3, r3, 0x540 | r3 -= 0x540;
0x00066e90 add.w r2, r6, r5, lsl 2 | r2 = r6 + (r5 << 2);
0x00066e94 ldr r1, [r3] | r1 = *(r3);
0x00066e96 ldr r3, [r2, 4] | r3 = *((r2 + 4));
0x00066e98 cmp r1, 0 |
| if (r1 == 0) {
0x00066e9a beq.w 0x670de | goto label_39;
| }
0x00066e9e adds r1, r5, 1 | r1 = r5 + 1;
0x00066ea0 add.w r0, r4, 8 | r0 = r4 + 8;
0x00066ea4 add.w r1, r6, r1, lsl 2 | r1 = r6 + (r1 << 2);
0x00066ea8 lsrs r0, r0, 0xc | r0 >>= 0xc;
0x00066eaa b 0x66ece | goto label_40;
| label_0:
0x00066eac eor.w r2, r0, r3 | r2 = r0 ^ r3;
0x00066eb0 str r2, [r4, 8] | *((r4 + 8)) = r2;
0x00066eb2 dmb ish | __asm ("dmb ish");
| do {
0x00066eb6 ldrex r2, [r1] | __asm ("ldrex r2, [r1]");
0x00066eba cmp r2, r3 |
| if (r2 != r3) {
0x00066ebc bne 0x66ec6 | goto label_41;
| }
0x00066ebe strex r6, r4, [r1] | __asm ("strex r6, r4, [r1]");
0x00066ec2 cmp r6, 0 |
0x00066ec4 bne 0x66eb6 |
| } while (r6 != 0);
| label_41:
0x00066ec6 cmp r3, r2 |
| if (r3 == r2) {
0x00066ec8 beq.w 0x670f2 | goto label_42;
| }
0x00066ecc mov r3, r2 | r3 = r2;
| label_40:
0x00066ece cmp r3, r4 |
| if (r3 != r4) {
0x00066ed0 bne 0x66eac | goto label_0;
| }
| label_2:
0x00066ed2 ldr.w r0, [pc, 0x54c] | r0 = *(0x00067420);
0x00066ed6 add r0, pc | r0 += pc;
0x00066ed8 bl 0x66078 | fcn_00066078 (r0);
| label_36:
0x00066edc lsls r3, r3, 0x1e | r3 <<= 0x1e;
| if (r3 < r3) {
0x00066ede bmi.w 0x671d4 | goto label_43;
| }
0x00066ee2 mrc p15, 0, r3, c13, c0, 3 | __asm ("mrc p15, 0, r3, c13, c0, 3");
0x00066ee6 eor r7, r7, 1 | r7 ^= 1;
0x00066eea sub.w r3, r3, 0x540 | r3 -= 0x540;
0x00066eee ldr r3, [r3] | r3 = *(r3);
0x00066ef0 cmp r3, 0 |
0x00066ef2 ite eq |
| if (r3 != 0) {
0x00066ef4 moveq r7, 0 | r7 = 0;
| }
| if (r3 == 0) {
0x00066ef6 andne r7, r7, 1 | r7 &= 1;
| }
0x00066efa cmp r7, 0 |
| if (r7 != 0) {
0x00066efc bne.w 0x6710e | goto label_44;
| }
0x00066f00 mov.w fp, 1 |
| label_3:
0x00066f04 ldr r3, [r6, 0x34] | r3 = *((r6 + 0x34));
0x00066f06 adds r7, r4, r5 | r7 = r4 + r5;
0x00066f08 cmp r3, r4 |
| if (r3 == r4) {
0x00066f0a beq.w 0x672b0 | goto label_45;
| }
0x00066f0e ldr r2, [r6, 4] | r2 = *((r6 + 4));
0x00066f10 lsls r1, r2, 0x1e | r1 = r2 << 0x1e;
| if (r1 >= r2) {
0x00066f12 bpl.w 0x672be | goto label_46;
| }
| label_14:
0x00066f16 ldr r3, [r7, 4] | r3 = *((r7 + 4));
0x00066f18 lsls r2, r3, 0x1f | r2 = r3 << 0x1f;
| if (r2 >= r3) {
0x00066f1a bpl.w 0x672d4 | goto label_47;
| }
0x00066f1e cmp r3, 8 |
0x00066f20 bic r8, r3, 7 | r8 = BIT_MASK (r3, 7);
| if (r3 < 8) {
0x00066f24 bls.w 0x67290 | goto label_48;
| }
0x00066f28 ldr.w r3, [r6, 0x450] | r3 = *((r6 + 0x450));
0x00066f2c cmp r3, r8 |
| if (r3 < r8) {
0x00066f2e bls.w 0x67290 | goto label_48;
| }
0x00066f32 ldr.w r3, [pc, 0x4f0] | r3 = *(0x00067424);
0x00066f36 add r3, pc | r3 += pc;
0x00066f38 ldr r1, [r3] | r1 = *(r3);
0x00066f3a cmp r1, 0 |
| if (r1 != 0) {
0x00066f3c bne.w 0x672dc | goto label_49;
| }
| label_15:
0x00066f40 ldr r3, [r4, 4] | r3 = *((r4 + 4));
0x00066f42 lsls r0, r3, 0x1f | r0 = r3 << 0x1f;
| if (r0 >= r3) {
0x00066f44 bmi 0x66f5e |
0x00066f46 ldr r3, [r4] | r3 = *(r4);
0x00066f48 subs r4, r4, r3 | r4 -= r3;
0x00066f4a add r5, r3 | r5 += r3;
0x00066f4c ldr r2, [r4, 4] | r2 = *((r4 + 4));
0x00066f4e bic r2, r2, 7 | r2 = BIT_MASK (r2, 7);
0x00066f52 cmp r2, r3 |
| if (r2 != r3) {
0x00066f54 bne.w 0x672fa | goto label_50;
| }
0x00066f58 mov r0, r4 | r0 = r4;
0x00066f5a bl 0x665b8 | fcn_000665b8 (r0);
| }
0x00066f5e ldr r3, [r6, 0x34] | r3 = *((r6 + 0x34));
0x00066f60 cmp r3, r7 |
| if (r3 == r7) {
0x00066f62 beq.w 0x67284 | goto label_51;
| }
0x00066f66 add.w r3, r7, r8 | r3 = r7 + r8;
0x00066f6a ldr r3, [r3, 4] | r3 = *((r3 + 4));
0x00066f6c lsls r1, r3, 0x1f | r1 = r3 << 0x1f;
| if (r1 >= r3) {
0x00066f6e bpl.w 0x672a6 | goto label_52;
| }
0x00066f72 ldr r3, [r7, 4] | r3 = *((r7 + 4));
0x00066f74 bic r3, r3, 1 | r3 = BIT_MASK (r3, 1);
0x00066f78 str r3, [r7, 4] | *((r7 + 4)) = r3;
| label_12:
0x00066f7a ldr r2, [r6, 0x3c] | r2 = *((r6 + 0x3c));
0x00066f7c add.w r3, r6, 0x34 | r3 = r6 + 0x34;
0x00066f80 ldr r1, [r2, 0xc] | r1 = *((r2 + 0xc));
0x00066f82 cmp r1, r3 |
| if (r1 != r3) {
0x00066f84 bne.w 0x672f2 | goto label_53;
| }
0x00066f88 cmp.w r5, 0x200 |
0x00066f8c strd r2, r1, [r4, 8] | __asm ("strd r2, r1, [r4, 8]");
0x00066f90 itt hs |
| if (r5 < 0x200) {
0x00066f92 movhs r3, 0 | r3 = 0;
| }
| if (r5 >= 0x200) {
0x00066f94 strdhs r3, r3, [r4, 0x10] | __asm ("strdhs r3, r3, [r4, 0x10]");
| }
0x00066f98 orr r3, r5, 1 | r3 = r5 | 1;
0x00066f9c str r4, [r6, 0x3c] | *((r6 + 0x3c)) = r4;
0x00066f9e str r4, [r2, 0xc] | *((r2 + 0xc)) = r4;
0x00066fa0 str r3, [r4, 4] | *((r4 + 4)) = r3;
0x00066fa2 str r5, [r4, r5] | *((r4 + r5)) = r5;
| label_10:
0x00066fa4 cmp.w r5, 0x10000 |
| if (r5 <= 0x10000) {
0x00066fa8 blo.w 0x671ae | goto label_8;
| }
0x00066fac ldr r3, [r6, 8] | r3 = *((r6 + 8));
0x00066fae cmp r3, 0 |
| if (r3 != 0) {
0x00066fb0 bne.w 0x6725a | goto label_54;
| }
| label_7:
0x00066fb4 ldr.w r3, [pc, 0x470] |
0x00066fb8 add r3, pc | r3 = 0xce3e4;
0x00066fba cmp r6, r3 |
| if (r6 == r3) {
0x00066fbc beq.w 0x67262 | goto label_55;
| }
0x00066fc0 ldr r7, [r6, 0x34] | r7 = *((r6 + 0x34));
0x00066fc2 lsrs r5, r7, 0x14 | r5 = r7 >> 0x14;
0x00066fc4 lsls r5, r5, 0x14 | r5 <<= 0x14;
0x00066fc6 ldr r3, [r5] | r3 = *(r5);
0x00066fc8 cmp r3, r6 |
| if (r3 != r6) {
0x00066fca bne.w 0x67400 | goto label_56;
| }
0x00066fce ldr r2, [sp, 0x10] | r2 = var_10h;
0x00066fd0 ldr.w r3, [pc, 0x458] |
0x00066fd4 ldr r3, [r2, r3] | r3 = *((r2 + r3));
0x00066fd6 ldr r2, [r3, 0x10] | r2 = *(0x6743c);
0x00066fd8 ldr.w r3, [pc, 0x454] | r3 = *(0x00067430);
0x00066fdc str r2, [sp, 0xc] | var_ch = r2;
0x00066fde add r3, pc | r3 = 0xce40e;
0x00066fe0 ldr r1, [r3, 4] | r1 = *(0xce412);
0x00066fe2 add.w r3, r5, 0x10 | r3 = r5 + 0x10;
0x00066fe6 cmp r7, r3 |
0x00066fe8 str r1, [sp, 0x1c] | var_1ch = r1;
| if (r7 != r3) {
0x00066fea bne.w 0x6730a | goto label_57;
| }
0x00066fee movw r3, 0xfffe |
0x00066ff2 add.w sl, r1, r2 | sl = r1 + r2;
0x00066ff6 movt r3, 0xf | r3 = 0xffffe;
0x00066ffa str.w fp, [sp, 0x18] | __asm ("str.w fp, [var_18h]");
0x00066ffe str r3, [sp, 0x14] | var_14h = r3;
0x00067000 add.w r3, sl, 0x10 | r3 = sl + 0x10;
0x00067004 mov sl, r3 | sl = r3;
0x00067006 b 0x67030 |
| while (r1 < r1) {
| label_1:
0x00067008 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0006700a adds r1, r7, r4 | r1 = r7 + r4;
0x0006700c subs r3, 1 | r3--;
0x0006700e tst r1, r3 |
| if ((r1 & r3) != 0) {
0x00067010 bne.w 0x673bc | goto label_58;
| }
0x00067014 ldr r3, [r5, 8] | r3 = *((r5 + 8));
0x00067016 add r3, r5 | r3 += r5;
0x00067018 cmp r1, r3 |
| if (r1 != r3) {
0x0006701a bne.w 0x673a8 | goto label_59;
| }
0x0006701e add.w r3, r5, 0x10 | r3 = r5 + 0x10;
0x00067022 orr r4, r4, 1 | r4 |= 1;
0x00067026 cmp r7, r3 |
0x00067028 str r7, [r6, 0x34] | *((r6 + 0x34)) = r7;
0x0006702a str r4, [r7, 4] | *((r7 + 4)) = r4;
| if (r7 != r3) {
0x0006702c bne.w 0x672b8 | goto label_60;
| }
0x00067030 mov r0, r5 | r0 = r5;
0x00067032 ldr r5, [r5, 4] | r5 = *((r5 + 4));
0x00067034 ldr r3, [r5, 8] | r3 = *((r5 + 8));
0x00067036 sub.w r4, r3, 8 | r4 = r3 - 8;
0x0006703a add.w lr, r5, r4 | lr = r5 + r4;
0x0006703e and lr, lr, 7 | lr &= 7;
0x00067042 sub.w r4, r4, lr | r4 -= lr;
0x00067046 add.w fp, r5, r4 |
0x0006704a ldr.w r1, [fp, 4] | r1 = *(arg_4h);
0x0006704e cmp r1, 1 |
| if (r1 != 1) {
0x00067050 bne.w 0x67394 | goto label_61;
| }
0x00067054 ldr r1, [r5, r4] | r1 = *((r5 + r4));
0x00067056 sub.w sb, fp, r1 | sb = fp - r1;
0x0006705a rsb.w r8, r1, 0 | r8 = r1 - ;
0x0006705e ldr.w r1, [sb, 4] | r1 = *((sb + 4));
0x00067062 bic r4, r1, 7 | r4 = BIT_MASK (r1, 7);
0x00067066 orr.w r4, r4, lr | r4 |= lr;
0x0006706a add.w lr, r4, 7 | lr = r4 + 7;
0x0006706e adds r4, 8 | r4 += 8;
0x00067070 cmp.w lr, 0x1e |
| if (lr > 0x1e) {
0x00067074 bhi.w 0x67380 | goto label_62;
| }
0x00067078 lsls r2, r1, 0x1f | r2 = r1 << 0x1f;
| if (r2 >= r1) {
0x0006707a bmi 0x6708c |
0x0006707c ldr.w r1, [fp, r8] | r1 = *((fp + r8));
0x00067080 ldr r2, [sp, 0x14] | r2 = var_14h;
0x00067082 add r4, r1 | r4 += r1;
0x00067084 subs r1, r4, 1 | r1 = r4 - 1;
0x00067086 cmp r1, r2 |
| if (r1 > r2) {
0x00067088 bhi.w 0x6736c | goto label_63;
| }
| }
0x0006708c rsb.w ip, r3, 0x100000 |
0x00067090 add ip, r4 |
0x00067092 cmp ip, sl |
| if (ip <= sl) {
0x00067094 blo 0x67136 | goto label_64;
| }
0x00067096 ldr r7, [r0, 8] | r7 = *((r0 + 8));
0x00067098 ldr.w r1, [r6, 0x450] | r1 = *((r6 + 0x450));
0x0006709c ldr.w ip, [pc, 0x394] | ip = *(0x00067434);
0x000670a0 subs r1, r1, r7 | r1 -= r7;
0x000670a2 add.w r7, r0, 0x100000 | r7 = r0 + 0x100000;
0x000670a6 add ip, pc |
0x000670a8 str.w r1, [r6, 0x450] | __asm ("str.w r1, aav.0x000000ff");
0x000670ac ldr.w r1, [ip, 8] | r1 = *((ip + 8));
0x000670b0 cmp r1, r7 |
0x000670b2 itt eq |
| if (r1 != r7) {
0x000670b4 moveq r1, 0 | r1 = 0;
| }
| if (r1 != r7) {
0x000670b6 streq r1, [ip, 8] | *((ip + 8)) = r1;
| }
0x000670ba mov.w r1, 0x100000 | r1 = 0x100000;
0x000670be bl 0xaa040 | munmap ();
0x000670c2 ldr.w r1, [sb, 4] | r1 = *((sb + 4));
0x000670c6 lsls r1, r1, 0x1f | r1 <<= 0x1f;
0x000670c8 it mi |
| if (r1 >= r1) {
0x000670ca movmi r7, sb | r7 = sb;
| }
0x000670cc bmi 0x67008 |
| }
0x000670ce ldr.w r7, [fp, r8] | r7 = *((fp + r8));
0x000670d2 sub.w r7, sb, r7 | r7 = sb - r7;
0x000670d6 mov r0, r7 | r0 = r7;
0x000670d8 bl 0x665b8 | fcn_000665b8 (r0);
0x000670dc b 0x67008 | goto label_1;
| label_39:
0x000670de cmp r4, r3 |
0x000670e0 itttt ne |
| if (r4 == r3) {
0x000670e2 addne r1, r4, 8 | r1 = r4 + 8;
| }
| if (r4 == r3) {
0x000670e6 eorne r1, r3, r1, lsr 12 | r1 = r3 ^ (r1 >> 12);
| }
| if (r4 != r3) {
0x000670ea str r1, [r4, 8] | *((r4 + 8)) = r1;
| }
| if (r4 == r3) {
0x000670ec str r4, [r2, 4] | *((r2 + 4)) = r4;
| goto label_65;
| }
| if (r4 == r3) {
| label_65:
0x000670ee beq.w 0x66ed2 | goto label_2;
| }
| label_42:
0x000670f2 cmp r3, 0 |
0x000670f4 ite eq |
| if (r3 != 0) {
0x000670f6 moveq r7, 0 | r7 = 0;
| }
| if (r3 == 0) {
0x000670f8 andne r7, r7, 1 | r7 &= 1;
| }
| if (r7 != 0) {
0x000670fc cbz r7, 0x67108 |
0x000670fe ldr r3, [r3, 4] | r3 = *((r3 + 4));
0x00067100 cmp.w r5, r3, lsr 3 |
| if (r5 != r3) {
0x00067104 bne.w 0x672ea | goto label_66;
| }
| }
| label_4:
0x00067108 add sp, 0x2c |
0x0006710a pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_44:
0x0006710e movs r3, 1 | r3 = 1;
| do {
0x00067110 ldrex r2, [r6] | __asm ("ldrex r2, [r6]");
0x00067114 cmp r2, 0 |
| if (r2 != 0) {
0x00067116 bne 0x67124 | goto label_67;
| }
0x00067118 strex r1, r3, [r6] | __asm ("strex r1, r3, [r6]");
0x0006711c cmp r1, 0 |
0x0006711e bne 0x67110 |
| } while (r1 != 0);
0x00067120 dmb ish | __asm ("dmb ish");
| if (r1 == 0) {
| label_67:
0x00067124 beq.w 0x66f04 | goto label_3;
| }
0x00067128 bl 0x5a624 | lll_lock_wait_private ();
0x0006712c b 0x66f04 | goto label_3;
| label_34:
0x0006712e ldr r0, [pc, 0x308] |
0x00067130 add r0, pc | r0 = 0xce56e;
0x00067132 bl 0x66078 | fcn_00066078 (r0);
| label_64:
0x00067136 ldr.w fp, [sp, 0x18] | fp = var_18h;
0x0006713a mov r5, r0 | r5 = r0;
0x0006713c ldr r4, [r7, 4] | r4 = *((r7 + 4));
| label_13:
0x0006713e ldr r3, [pc, 0x2fc] |
0x00067140 bic r4, r4, 7 | r4 = BIT_MASK (r4, 7);
0x00067144 add r3, pc | r3 = 0xce586;
0x00067146 ldr r2, [r3] | r2 = *(0xce586);
0x00067148 cmp r2, r4 |
| if (r2 <= r4) {
0x0006714a bhi 0x671ae |
0x0006714c ldr r1, [sp, 0x1c] | r1 = var_1ch;
0x0006714e sub.w r8, r4, 0x11 | r8 = r4 - 0x11;
0x00067152 cmp r1, r8 |
0x00067154 ite lo |
| if (r1 >= r8) {
0x00067156 movlo r2, 0 | r2 = 0;
| }
| if (r1 < r8) {
0x00067158 movhs r2, 1 | r2 = 1;
| }
0x0006715a orrs.w r2, r2, r8, lsr 31 | r2 |= (r8 >> 31);
0x0006715c strb r0, [r3, 0xb] | *((r3 + 0xb)) = r0;
| if (r2 != r2) {
0x0006715e bne 0x671ae | goto label_8;
| }
0x00067160 ldr r2, [sp, 0xc] | r2 = var_ch;
0x00067162 sub.w r8, r8, r1 | r8 -= r1;
0x00067166 rsb.w sb, r2, 0 | sb = r2 - ;
0x0006716a ands.w r8, r8, sb | r8 &= sb;
| if (r8 == r8) {
0x0006716e beq 0x671ae | goto label_8;
| }
0x00067170 ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x00067172 sub.w sb, r2, r8 | sb = r2 - r8;
0x00067176 cmp.w sb, 0xf |
| if (sb <= 0xf) {
0x0006717a ble 0x671ae | goto label_8;
| }
0x0006717c ldr r2, [r3, 0x34] | r2 = *((r3 + 0x34));
0x0006717e cmp r2, 0 |
| if (r2 < 0) {
0x00067180 blt.w 0x6730e | goto label_68;
| }
| if (r2 != 0) {
0x00067184 bne.w 0x67340 | goto label_69;
| }
| label_17:
0x00067188 movs r2, 4 | r2 = 4;
0x0006718a mov r1, r8 | r1 = r8;
0x0006718c add.w r0, r5, sb | r0 = r5 + sb;
0x00067190 bl 0xaa0f0 | madvise ();
| label_18:
0x00067194 ldr.w r2, [r6, 0x450] | r2 = *((r6 + 0x450));
0x00067198 sub.w r4, r4, r8 | r4 -= r8;
0x0006719c orr r4, r4, 1 | r4 |= 1;
0x000671a0 str.w sb, [r5, 8] | __asm ("str.w sb, [r5, 8]");
0x000671a4 sub.w r2, r2, r8 | r2 -= r8;
0x000671a8 str.w r2, [r6, 0x450] | __asm ("str.w r2, aav.0x000000ff");
0x000671ac str r4, [r7, 4] | *((r7 + 4)) = r4;
| }
| label_8:
0x000671ae cmp.w fp, 0 |
| if (fp != 0) {
0x000671b2 bne 0x67108 | goto label_4;
| }
| label_9:
0x000671b4 dmb ish | __asm ("dmb ish");
| do {
0x000671b8 ldrex r3, [r6] | __asm ("ldrex r3, [r6]");
0x000671bc strex r2, fp, [r6] | __asm ("strex r2, fp, [r6]");
0x000671c0 cmp r2, 0 |
0x000671c2 bne 0x671b8 |
| } while (r2 != 0);
0x000671c4 cmp r3, 1 |
| if (r3 <= 1) {
0x000671c6 ble 0x67108 | goto label_4;
| }
0x000671c8 mov r0, r6 | r0 = r6;
0x000671ca add sp, 0x2c |
0x000671cc pop.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000671d0 b.w 0x5a6c0 | void (*0x5a6c0)() ();
| label_43:
0x000671d4 mov r0, r1 | r0 = r1;
0x000671d6 add sp, 0x2c |
0x000671d8 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000671dc b.w 0x6608c | void (*0x6608c)() ();
| label_35:
0x000671e0 ldr r0, [pc, 0x25c] |
0x000671e2 add r0, pc | r0 = 0xce626;
0x000671e4 bl 0x66078 | fcn_00066078 (r0);
| if (r7 != 0) {
| label_37:
0x000671e8 cbnz r7, 0x67226 | goto label_70;
| }
0x000671ea movs r3, 1 | r3 = 1;
| do {
0x000671ec ldrex r2, [r6] | __asm ("ldrex r2, [r6]");
0x000671f0 cmp r2, 0 |
| if (r2 != 0) {
0x000671f2 bne 0x67200 | goto label_71;
| }
0x000671f4 strex r1, r3, [r6] | __asm ("strex r1, r3, [r6]");
0x000671f8 cmp r1, 0 |
0x000671fa bne 0x671ec |
| } while (r1 != 0);
0x000671fc dmb ish | __asm ("dmb ish");
| if (r1 != 0) {
| label_71:
0x00067200 bne 0x67302 | goto label_72;
| }
| label_16:
0x00067202 ldr.w r3, [r8, 4] | r3 = *((r8 + 4));
0x00067206 cmp r3, 8 |
| if (r3 > 8) {
0x00067208 bhi 0x6722e | goto label_73;
| }
| label_5:
0x0006720a movs r2, 0 | r2 = 0;
0x0006720c dmb ish | __asm ("dmb ish");
| do {
0x00067210 ldrex r3, [r6] | __asm ("ldrex r3, [r6]");
0x00067214 strex r1, r2, [r6] | __asm ("strex r1, r2, [r6]");
0x00067218 cmp r1, 0 |
0x0006721a bne 0x67210 |
| } while (r1 != 0);
0x0006721c cmp r3, 1 |
| if (r3 > 1) {
0x0006721e ble 0x67226 |
0x00067220 mov r0, r6 | r0 = r6;
0x00067222 bl 0x5a6c0 | lll_lock_wake_private ();
| }
| label_70:
0x00067226 ldr r0, [pc, 0x21c] |
0x00067228 add r0, pc | r0 = 0xce672;
0x0006722a bl 0x66078 | fcn_00066078 (r0);
| label_73:
0x0006722e ldr.w r2, [r6, 0x450] | r2 = *((r6 + 0x450));
0x00067232 bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x00067236 cmp r3, r2 |
| if (r3 >= r2) {
0x00067238 bhs 0x6720a | goto label_5;
| }
0x0006723a movs r2, 0 | r2 = 0;
0x0006723c dmb ish | __asm ("dmb ish");
| do {
0x00067240 ldrex r3, [r6] | __asm ("ldrex r3, [r6]");
0x00067244 strex r1, r2, [r6] | __asm ("strex r1, r2, [r6]");
0x00067248 cmp r1, 0 |
0x0006724a bne 0x67240 |
| } while (r1 != 0);
0x0006724c cmp r3, 1 |
| if (r3 <= 1) {
0x0006724e ble.w 0x66e74 | goto label_6;
| }
0x00067252 mov r0, r6 | r0 = r6;
0x00067254 bl 0x5a6c0 | lll_lock_wake_private ();
0x00067258 b 0x66e74 | goto label_6;
| label_54:
0x0006725a mov r0, r6 | r0 = r6;
0x0006725c bl 0x6663c | fcn_0006663c (r0);
0x00067260 b 0x66fb4 | goto label_7;
| label_55:
0x00067262 ldr r3, [r6, 0x34] | r3 = *((r6 + 0x34));
0x00067264 ldr r2, [pc, 0x1e0] |
0x00067266 ldr r3, [r3, 4] | r3 = *((r3 + 4));
0x00067268 add r2, pc | r2 = 0xce6b4;
0x0006726a ldr r1, [r2] | r1 = *(0xce6b4);
0x0006726c bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x00067270 cmp r3, r1 |
| if (r3 <= r1) {
0x00067272 blo 0x671ae | goto label_8;
| }
0x00067274 ldr r0, [r2, 4] | r0 = *((r2 + 4));
0x00067276 bl 0x66d9c | fcn_00066d9c (r0);
0x0006727a invalid |
| label_25:
0x0006727c lsrs r0, r0, 0x1c | r0 >>= 0x1c;
| if (r0 != r0) {
0x0006727e bne.w 0x67108 | goto label_4;
| }
0x00067282 b 0x671b4 | goto label_9;
| label_51:
0x00067284 add r5, r8 | r5 += r8;
0x00067286 orr r3, r5, 1 | r3 = r5 | 1;
0x0006728a str r3, [r4, 4] | *((r4 + 4)) = r3;
0x0006728c str r4, [r6, 0x34] | *((r6 + 0x34)) = r4;
0x0006728e b 0x66fa4 | goto label_10;
| label_48:
0x00067290 ldr r0, [pc, 0x1b8] |
0x00067292 add r0, pc | r0 = 0xce6e2;
0x00067294 bl 0x66078 | fcn_00066078 (r0);
| label_38:
0x00067298 sub.w r2, r5, 8 | r2 = r5 - 8;
0x0006729c add.w r0, r4, 8 | r0 = r4 + 8;
0x000672a0 blx 0x6b880 | memset (r0, r1, r2);
0x000672a4 b 0x66e82 | goto label_11;
| label_52:
0x000672a6 mov r0, r7 | r0 = r7;
0x000672a8 add r5, r8 | r5 += r8;
0x000672aa bl 0x665b8 | fcn_000665b8 (r0);
0x000672ae b 0x66f7a | goto label_12;
| label_45:
0x000672b0 ldr r0, [pc, 0x19c] |
0x000672b2 add r0, pc | r0 = 0xce706;
| label_24:
0x000672b4 bl 0x66078 | fcn_00066078 (r0);
| label_60:
0x000672b8 ldr.w fp, [sp, 0x18] | fp = var_18h;
0x000672bc b 0x6713e | goto label_13;
| label_46:
0x000672be ldr r2, [r3, 4] | r2 = *((r3 + 4));
0x000672c0 bic r2, r2, 7 | r2 = BIT_MASK (r2, 7);
0x000672c4 add r3, r2 | r3 += r2;
0x000672c6 cmp r7, r3 |
| if (r7 <= r3) {
0x000672c8 blo.w 0x66f16 | goto label_14;
| }
0x000672cc ldr r0, [pc, 0x184] |
0x000672ce add r0, pc | r0 = 0xce726;
0x000672d0 bl 0x66078 | fcn_00066078 (r0);
| label_47:
0x000672d4 ldr r0, [pc, 0x180] |
0x000672d6 add r0, pc | r0 = 0xce732;
0x000672d8 bl 0x66078 | fcn_00066078 (r0);
| label_49:
0x000672dc sub.w r2, r5, 8 | r2 = r5 - 8;
0x000672e0 add.w r0, r4, 8 | r0 = r4 + 8;
0x000672e4 blx 0x6b880 | memset (r0, r1, r2);
0x000672e8 b 0x66f40 | goto label_15;
| label_66:
0x000672ea ldr r0, [pc, 0x170] |
0x000672ec add r0, pc | r0 = 0xce74e;
0x000672ee bl 0x66078 | fcn_00066078 (r0);
| label_53:
0x000672f2 ldr r0, [pc, 0x16c] |
0x000672f4 add r0, pc | r0 = 0xce75a;
0x000672f6 bl 0x66078 | fcn_00066078 (r0);
| label_50:
0x000672fa ldr r0, [pc, 0x168] |
0x000672fc add r0, pc | r0 = 0xce766;
0x000672fe bl 0x66078 | fcn_00066078 (r0);
| label_72:
0x00067302 mov r0, r6 | r0 = r6;
0x00067304 bl 0x5a624 | lll_lock_wait_private ();
0x00067308 b 0x67202 | goto label_16;
| label_57:
0x0006730a ldr r4, [r7, 4] | r4 = *((r7 + 4));
0x0006730c b 0x6713e | goto label_13;
| label_68:
0x0006730e ldr r2, [pc, 0x158] | r2 = *(0x6746a);
0x00067310 ldr r1, [sp, 0x10] | r1 = var_10h;
0x00067312 ldr r2, [r1, r2] | r2 = *((r1 + r2));
0x00067314 ldr.w sl, [r2] | sl = *(0x6746a);
0x00067318 str.w sl, [r3, 0x34] | __asm ("str.w sl, [r3, 0x34]");
0x0006731c cmp.w sl, 0 |
| if (sl != 0) {
0x00067320 bne 0x67340 | goto label_69;
| }
0x00067322 ldr r0, [pc, 0x148] |
0x00067324 mov.w r1, 0x80000 | r1 = 0x80000;
0x00067328 add r0, pc | r0 = 0xce79a;
0x0006732a bl 0xa65f4 | r0 = open_nocancel ();
0x0006732e subs r3, r0, 0 | r3 = r0 - 0;
0x00067330 str r3, [sp, 0xc] | var_ch = r3;
| if (r3 >= r0) {
0x00067332 bge 0x673d0 | goto label_74;
| }
| label_19:
0x00067334 ldr r3, [pc, 0x138] |
0x00067336 add r3, pc |
0x00067338 ldr r3, [r3, 0x34] | r3 = *(0xce7de);
0x0006733a cmp r3, 0 |
| if (r3 == 0) {
0x0006733c beq.w 0x67188 | goto label_17;
| }
| label_69:
0x00067340 mov.w r3, -1 | r3 = -1;
0x00067344 movs r2, 0 | r2 = 0;
0x00067346 strd r3, r2, [sp] | __asm ("strd r3, r2, [sp]");
0x0006734a mov r1, r8 | r1 = r8;
0x0006734c movs r3, 0x32 | r3 = 0x32;
0x0006734e add.w r0, r5, sb | r0 = r5 + sb;
0x00067352 bl 0xa9f88 | mmap ()
0x00067354 cdp2 p0, 1, c3, c9, c1, 0 | __asm ("cdp2 p0, 1, c3, c9, c1, 0");
| label_20:
0x00067358 it ne |
| if (r3 != 0x32) {
0x0006735a strne sb, [r5, 0xc] | *((r5 + 0xc)) = sb;
| goto label_75;
| }
| if (r3 != 0x32) {
| label_75:
0x0006735e bne.w 0x67194 | goto label_18;
| }
0x00067362 cmp.w fp, 0 |
| if (fp != 0) {
0x00067366 bne.w 0x67108 | goto label_4;
| }
0x0006736a b 0x671b4 | goto label_9;
| label_63:
0x0006736c ldr r3, [pc, 0x104] |
0x0006736e movw r2, 0x263 | r2 = 0x263;
0x00067372 ldr r1, [pc, 0x104] |
0x00067374 ldr r0, [pc, 0x104] |
0x00067376 add r3, pc | r3 = 0xce7ee;
0x00067378 add r1, pc | r1 = 0xce7f6;
0x0006737a add r0, pc | r0 = 0xce7fa;
0x0006737c bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_62:
0x00067380 ldr r3, [pc, 0xfc] |
0x00067382 mov.w r2, 0x260 | r2 = 0x260;
0x00067386 ldr r1, [pc, 0xfc] |
0x00067388 ldr r0, [pc, 0xfc] |
0x0006738a add r3, pc | r3 = 0xce80e;
0x0006738c add r1, pc | r1 = 0xce816;
0x0006738e add r0, pc | r0 = 0xce81a;
0x00067390 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_61:
0x00067394 ldr r3, [pc, 0xf4] |
0x00067396 movw r2, 0x25d | r2 = 0x25d;
0x0006739a ldr r1, [pc, 0xf4] |
0x0006739c ldr r0, [pc, 0xf4] |
0x0006739e add r3, pc | r3 = 0xce82e;
0x000673a0 add r1, pc | r1 = 0xce836;
0x000673a2 add r0, pc | r0 = 0xce83a;
0x000673a4 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_59:
0x000673a8 ldr r3, [pc, 0xec] |
0x000673aa mov.w r2, 0x270 | r2 = 0x270;
0x000673ae ldr r1, [pc, 0xec] |
0x000673b0 ldr r0, [pc, 0xec] |
0x000673b2 add r3, pc | r3 = 0xce84e;
0x000673b4 add r1, pc | r1 = 0xce856;
0x000673b6 add r0, pc | r0 = 0xce85a;
0x000673b8 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_58:
0x000673bc ldr r3, [pc, 0xe4] |
0x000673be movw r2, 0x26f | r2 = 0x26f;
0x000673c2 ldr r1, [pc, 0xe4] |
0x000673c4 ldr r0, [pc, 0xe4] |
0x000673c6 add r3, pc | r3 = 0xce86e;
0x000673c8 add r1, pc | r1 = 0xce876;
0x000673ca add r0, pc | r0 = 0xce87a;
| label_21:
0x000673cc bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_74:
0x000673d0 movs r2, 1 | r2 = 1;
0x000673d2 add.w r1, sp, 0x27 | r1 += var_27h;
0x000673d6 bl 0xa6780 | r0 = read_nocancel ();
0x000673da cmp r0, 0 |
0x000673dc ldr r3, [sp, 0xc] | r3 = var_ch;
| if (r0 > 0) {
0x000673de ble 0x673f0 |
| label_23:
0x000673e0 ldrb.w sl, [sp, 0x27] | sl = var_27h;
0x000673e4 sub.w r2, sl, 0x32 | r2 = sl - 0x32;
0x000673e8 rsbs.w sl, r2, 0 | sl = r2 - ;
0x000673ec adc.w sl, sl, r2 | __asm ("adc.w sl, sl, r2");
| }
0x000673f0 mov r0, r3 | r0 = r3;
0x000673f2 ldr r3, [pc, 0xbc] |
0x000673f4 add r3, pc | r3 = 0xce8aa;
0x000673f6 str.w sl, [r3, 0x34] | __asm ("str.w sl, [r3, 0x34]");
0x000673fa bl 0xa64c4 | close_nocancel ();
0x000673fe b 0x67334 | goto label_19;
| label_56:
0x00067400 ldr r3, [pc, 0xb0] |
0x00067402 movw r2, 0x11de | r2 = 0x11de;
0x00067406 ldr r1, [pc, 0xb0] |
0x00067408 ldr r0, [pc, 0xb0] |
0x0006740a add r3, pc | r3 = 0xce8c2;
0x0006740c add r1, pc | r1 = 0xce8ca;
0x0006740e add r0, pc | r0 = 0xce8ce;
0x00067410 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
0x00067414 strb r0, [r7] | *(r7) = r0;
0x00067416 movs r2, r1 | r2 = r1;
0x00067418 add r6, sp, 0xe0 | r6 += arg_e0h;
0x0006741a movs r2, r1 | r2 = r1;
0x0006741c add r6, sp, 0x40 | r6 += var_40h;
0x0006741e movs r2, r1 | r2 = r1;
| label_22:
0x00067420 svc 0xd2 | __asm ("svc 0xd2");
0x00067422 movs r0, r1 | r0 = r1;
0x00067424 add r5, sp, 0x148 | r5 += arg_148h;
0x00067426 movs r2, r1 | r2 = r1;
0x00067428 strb r0, [r4, 0x18] | *((r4 + 0x18)) = r0;
0x0006742a movs r2, r1 | r2 = r1;
0x0006742c lsls r0, r3, 3 | r0 = r3 << 3;
0x0006742e movs r0, r0 |
0x00067430 strb r2, [r7, 3] | *((r7 + 3)) = r2;
0x00067432 movs r2, r1 | r2 = r1;
0x00067434 add r3, sp, 0x388 | r3 += arg_388h;
0x00067436 movs r2, r1 | r2 = r1;
| if (r2 <= r1) {
0x00067438 ble 0x67484 | goto label_76;
| }
0x0006743a movs r0, r1 | r0 = r1;
| label_26:
0x0006743c ldr r4, [r2, 0x78] | r4 = *((r2 + 0x78));
0x0006743e movs r2, r1 | r2 = r1;
| if (r2 > r1) {
0x00067440 bgt 0x67358 | goto label_20;
| }
0x00067442 movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067444 bgt 0x67500 | goto label_77;
| }
0x00067446 movs r0, r1 | r0 = r1;
0x00067448 ldr r0, [r6, 0x64] | r0 = *((r6 + 0x64));
0x0006744a movs r2, r1 | r2 = r1;
| if (r2 > r1) {
0x0006744c bgt 0x673cc | goto label_21;
| }
0x0006744e movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067450 bgt 0x674c8 | void (*0x674c8)() ();
| }
0x00067452 movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067454 bgt 0x674d4 | void (*0x674d4)() ();
| }
0x00067456 movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067458 bgt 0x67508 | goto label_78;
| }
0x0006745a movs r0, r1 | r0 = r1;
| if (r0 < r1) {
0x0006745c blt 0x67420 | goto label_22;
| }
0x0006745e movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067460 bgt 0x673cc | goto label_21;
| }
0x00067462 movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067464 bgt 0x67558 | goto label_79;
| }
0x00067466 movs r0, r1 | r0 = r1;
0x00067468 lsls r0, r5, 2 | r0 = r5 << 2;
0x0006746a movs r0, r0 |
| if (r0 <= r0) {
0x0006746c ble 0x673e0 | goto label_23;
| }
0x0006746e movs r0, r1 | r0 = r1;
0x00067470 ldr r2, [r4, 0x58] | r2 = *((r4 + 0x58));
0x00067472 movs r2, r1 | r2 = r1;
0x00067474 b 0x672b4 | goto label_24;
| label_76:
0x00067484 bvs 0x674b8 | __asm ("bvs aav.0x000000ff");
0x00067486 movs r0, r1 | r0 = r1;
| if (r0 > r1) {
0x00067488 bgt 0x67588 | goto label_80;
| }
0x0006748a movs r0, r1 | r0 = r1;
0x0006748c b 0x6727c | goto label_25;
| if (r0 >= r1) {
0x000674b8 bpl 0x674fc | goto label_81;
| }
0x000674ba movs r0, r1 | r0 = r1;
| if (r0 < r1) {
0x000674bc blt 0x6743c | goto label_26;
| }
0x000674be movs r0, r1 | r0 = r1;
| label_81:
0x000674fc ldrb r0, [r6, 0xf] | r0 = var_fh;
0x000674fe invalid |
| label_77:
0x00067500 adds r4, 0x78 | r4 += 0x78;
0x00067502 add r3, pc | r3 += pc;
0x00067504 str r3, [sp, 0xc] | var_ch = r3;
0x00067506 invalid |
| label_78:
0x00067508 adds r4, 0x74 | r4 += 0x74;
0x0006750a add r3, pc | r3 += pc;
0x0006750c str r3, [sp, 0x10] | var_10h = r3;
| label_32:
0x0006750e ldr r7, [r4, 0x34] | r7 = *((r4 + 0x34));
0x00067510 ldr r2, [sp, 8] | r2 = var_8h;
0x00067512 ldr r3, [r7, 4] | r3 = *((r7 + 4));
0x00067514 bic r6, r3, 7 | r6 = BIT_MASK (r3, 7);
0x00067518 cmp r7, r2 |
0x0006751a it eq |
| if (r7 == r2) {
0x0006751c cmpeq r6, 0 | __asm ("cmpeq r6, 0");
| }
0x0006751e add.w sb, r7, r6 | sb = r7 + r6;
| if (r7 != r2) {
0x00067522 beq 0x6753c |
0x00067524 cmp r6, 0xf |
| if (r6 < 0xf) {
0x00067526 bls.w 0x67a12 | goto label_82;
| }
0x0006752a lsls r1, r3, 0x1f | r1 = r3 << 0x1f;
| if (r1 >= r3) {
0x0006752c bpl.w 0x67a12 | goto label_82;
| }
0x00067530 add.w r3, r8, -1 | r3 = r8 + -1;
0x00067534 tst.w sb, r3 |
| if ((sb & r3) != 0) {
0x00067538 bne.w 0x67a12 | goto label_82;
| }
| }
0x0006753c add.w sl, r5, 0x10 | sl = r5 + 0x10;
0x00067540 cmp sl, r6 |
| if (sl < r6) {
0x00067542 bls.w 0x67a26 | goto label_83;
| }
0x00067546 ldr r3, [sp, 0xc] | r3 = var_ch;
0x00067548 cmp r4, r3 |
| if (r4 == r3) {
0x0006754a beq.w 0x6776a | goto label_84;
| }
0x0006754e and.w r3, r7, fp | r3 = r7 & fp;
0x00067552 sub.w r2, sl, r6 | r2 = sl - r6;
0x00067556 ldr r1, [r3, 8] | r1 = *((r3 + 8));
| label_79:
0x00067558 cmp r2, 0 |
0x0006755a str r1, [sp, 0x14] | var_14h = r1;
| if (r2 > 0) {
0x0006755c ble 0x67602 |
0x0006755e add.w sb, r8, -1 | sb = r8 + -1;
0x00067562 add sb, r2 | sb += r2;
0x00067564 rsb.w r2, r8, 0 | r2 = r8 - ;
0x00067568 and.w sb, sb, r2 | sb &= r2;
0x0006756c add sb, r1 | sb += r1;
0x0006756e cmp.w sb, 0x100000 |
| if (sb > 0x100000) {
0x00067572 bhi 0x67602 | goto label_27;
| }
0x00067574 ldr r0, [r3, 0xc] | r0 = *((r3 + 0xc));
0x00067576 cmp sb, r0 |
| if (sb > r0) {
0x00067578 bhi.w 0x6781c | goto label_85;
| }
0x0006757c mov r2, sb | r2 = sb;
0x0006757e mov r1, r7 | r1 = r7;
0x00067580 mov sb, r3 | sb = r3;
0x00067582 mov r3, r2 | r3 = r2;
| label_28:
0x00067584 ldr.w r0, [r4, 0x450] | r0 = *((r4 + 0x450));
| label_80:
0x00067588 add.w r2, sb, r3 | r2 = sb + r3;
0x0006758c ldr r6, [sp, 0x14] | r6 = var_14h;
0x0006758e subs r2, r2, r7 | r2 -= r7;
0x00067590 str.w r3, [sb, 8] | __asm ("str.w r3, [sb, 8]");
0x00067594 orr r2, r2, 1 | r2 |= 1;
0x00067598 subs r0, r0, r6 | r0 -= r6;
0x0006759a add r3, r0 | r3 += r0;
0x0006759c str.w r3, [r4, 0x450] | __asm ("str.w r3, aav.0x000000ff");
0x000675a0 str r2, [r7, 4] | *((r7 + 4)) = r2;
| }
| label_27:
0x00067602 str r3, [sp, 0x14] | var_14h = r3;
0x00067604 add.w r0, r5, 0x20 | r0 = r5 + 0x20;
0x00067608 ldr r3, [sp, 0x10] | r3 = var_10h;
0x0006760a ldr r1, [r3, 4] | r1 = *((r3 + 4));
0x0006760c bl 0x65f64 | r0 = fcn_00065f64 (r0);
0x00067610 mov r2, r0 | r2 = r0;
0x00067612 cmp r0, 0 |
| if (r0 == 0) {
0x00067614 beq.w 0x6780c | goto label_86;
| }
0x00067618 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0006761a sub.w ip, r6, 8 |
0x0006761e ldr r1, [r0, 8] | r1 = *((r0 + 8));
0x00067620 subs r6, 0x10 | r6 -= 0x10;
0x00067622 cmp r6, 0xf |
0x00067624 strd r4, r3, [r0] | __asm ("strd r4, r3, [r0]");
0x00067628 ldr.w r3, [r4, 0x450] | r3 = *((r4 + 0x450));
0x0006762c add r3, r1 | r3 += r1;
0x0006762e sub.w r1, r1, 0x10 | r1 -= 0x10;
0x00067632 orr r0, r1, 1 | r0 = r1 | 1;
0x00067636 add.w r1, r2, 0x10 | r1 = r2 + 0x10;
0x0006763a str.w r3, [r4, 0x450] | __asm ("str.w r3, aav.0x000000ff");
0x0006763e str r1, [r4, 0x34] | *((r4 + 0x34)) = r1;
0x00067640 str r0, [r2, 0x14] | *((r2 + 0x14)) = r0;
0x00067642 mov.w r2, 1 | r2 = 1;
0x00067646 add.w r0, r7, ip | r0 = r7 + ip;
0x0006764a str r2, [r0, 4] | *((r0 + 4)) = r2;
0x0006764c ittt ls |
| if (r6 > 0xf) {
0x0006764e orrls r2, ip, 1 | r2 = ip | 1;
| }
| if (r6 > 0xf) {
0x00067652 strls r2, [r7, 4] | *((r7 + 4)) = r2;
| }
| if (r6 > 0xf) {
0x00067654 str.w ip, [r7, ip] | __asm ("str.w ip, [r7, ip]");
| goto label_87;
| }
| if (r6 < 0xf) {
| label_87:
0x00067658 bls 0x675a2 | void (*0x675a2)() ();
| }
0x0006765a adds r3, r7, r6 | r3 = r7 + r6;
0x0006765c movs r1, 9 | r1 = 9;
0x0006765e str r1, [r3, 4] | *((r3 + 4)) = r1;
0x00067660 orr r6, r6, 5 | r6 |= 5;
0x00067664 movs r3, 8 | r3 = 8;
0x00067666 mov r1, r7 | r1 = r7;
0x00067668 str.w r3, [r7, ip] | __asm ("str.w r3, [r7, ip]");
0x0006766c mov r0, r4 | r0 = r4;
0x0006766e str r6, [r7, 4] | *((r7 + 4)) = r6;
0x00067670 bl 0x66e1c | fcn_00066e1c (r0, r1, r2, r3, r4, r5, r6);
0x00067674 ldr.w r3, [r4, 0x450] | r3 = *((r4 + 0x450));
0x00067678 ldr r1, [r4, 0x34] | r1 = *((r4 + 0x34));
0x0006767a b 0x675a2 | void (*0x675a2)() ();
| label_84:
0x0006776a ldr r3, [pc, 0x228] |
0x0006776c add.w r2, r8, -1 | r2 = r8 + -1;
0x00067770 str r2, [sp, 8] | var_8h = r2;
0x00067772 rsb.w r8, r8, 0 | r8 -= ;
0x00067776 add r3, pc |
0x00067778 ldr r3, [r3, 4] | r3 = *(0xcf114);
0x0006777a add.w fp, r3, 0x10 |
0x0006777e ldr r3, [r4, 4] | r3 = *((r4 + 4));
0x00067780 add fp, r2 |
0x00067782 add fp, r5 |
0x00067784 lsls r2, r3, 0x1e | r2 = r3 << 0x1e;
| if (r2 >= r3) {
0x00067786 bpl 0x677da | goto label_88;
| }
0x00067788 and.w fp, fp, r8 |
0x0006778c cmp.w fp, 0 |
| if (fp <= 0) {
0x00067790 ble 0x677f2 | goto label_30;
| }
| do {
0x00067792 mov r0, fp | r0 = fp;
0x00067794 bl 0x66d80 | r0 = default_morecore ();
0x00067798 mov ip, r0 |
0x0006779a cmp r0, 0 |
| if (r0 == 0) {
0x0006779c beq.w 0x679fc | goto label_89;
| }
0x000677a0 ldr r3, [pc, 0x1f4] |
0x000677a2 mov.w lr, 1 | lr = 1;
0x000677a6 add r3, pc | r3 = 0xcf142;
0x000677a8 ldr r2, [r3, 0x2c] | r2 = *(0xcf16e);
0x000677aa cmp r2, 0 |
| if (r2 == 0) {
0x000677ac beq.w 0x6795e | goto label_90;
| }
0x000677b0 movs r2, 0 | r2 = 0;
| label_29:
0x000677b2 ldr r0, [pc, 0x1e8] |
0x000677b4 cmp sb, ip |
0x000677b6 ite ne |
| if (sb == ip) {
0x000677b8 movne r1, 0 | r1 = 0;
| }
| if (sb != ip) {
0x000677ba andeq r1, lr, 1 | r1 = lr & 1;
| }
0x000677be add r0, pc | r0 = 0xcf160;
0x000677c0 ldr.w r3, [r0, 0x450] | r3 = *(0xcf5b0);
0x000677c4 add r3, fp | r3 += fp;
0x000677c6 str.w r3, [r0, 0x450] | __asm ("str.w r3, aav.0x000000ff");
0x000677c8 adds r4, 0x50 | r4 += 0x50;
0x000677ca cmp r1, 0 |
| if (r1 == 0) {
0x000677cc beq 0x67844 | goto label_91;
| }
0x000677ce add fp, r6 |
0x000677d0 ldr r1, [r0, 0x34] | r1 = *((r0 + 0x34));
0x000677d2 orr r2, fp, 1 | r2 = fp | 1;
0x000677d6 str r2, [r7, 4] | *((r7 + 4)) = r2;
0x000677d8 b 0x675a2 | void (*0x675a2)() ();
| label_88:
0x000677da sub.w fp, fp, r6 |
0x000677de and.w fp, fp, r8 |
0x000677e2 cmp.w fp, 0 |
0x000677e6 bgt 0x67792 |
| } while (fp > 0);
| label_31:
0x000677e8 ldr r3, [sp, 8] | r3 = var_8h;
0x000677ea adds r3, r6, r3 | r3 = r6 + r3;
0x000677ec add r3, fp | r3 += fp;
0x000677ee and.w fp, r3, r8 |
| label_30:
0x000677f2 cmp.w fp, 0x100000 |
0x000677f6 it lo |
| if (fp >= 0x100000) {
0x000677f8 movlo fp, 0x100000 |
| }
0x000677fc cmp r5, fp |
| if (r5 <= fp) {
0x000677fe blo 0x678fa | goto label_92;
| }
0x00067800 ldr r2, [pc, 0x19c] |
0x00067802 add r2, pc | r2 = 0xcf1a6;
0x00067804 ldr.w r3, [r2, 0x450] | r3 = *(0xcf5f6);
0x00067808 ldr r1, [r2, 0x34] | r1 = *(0xcf1da);
0x0006780a b 0x675a2 | void (*0x675a2)() ();
| label_86:
0x0006780c ldr r3, [sp, 0x18] | r3 = var_18h;
0x0006780e cmp r3, 0 |
| if (r3 == 0) {
0x00067810 beq.w 0x67a42 | goto label_93;
| }
0x00067814 ldr.w r3, [r4, 0x450] | r3 = *((r4 + 0x450));
0x00067818 ldr r1, [r4, 0x34] | r1 = *((r4 + 0x34));
0x0006781a b 0x675a2 | void (*0x675a2)() ();
| label_85:
0x0006781c sub.w r1, sb, r0 | r1 = sb - r0;
0x00067820 movs r2, 3 | r2 = 3;
0x00067822 add r0, r3 | r0 += r3;
0x00067824 str r3, [sp, 0x1c] | var_1ch = r3;
0x00067826 bl 0xaa060 | mprotect ();
0x0006782a ldr r3, [sp, 0x1c] | r3 = var_1ch;
0x0006782c cmp r0, 0 |
| if (r0 != 0) {
0x0006782e bne.w 0x67602 | goto label_27;
| }
0x00067830 add r6, sp, 0x3a0 | r6 = sp + 0x3a0;
0x00067832 mov r2, sb | r2 = sb;
0x00067834 mov sb, r3 | sb = r3;
0x00067836 ldr r1, [r4, 0x34] | r1 = *((r4 + 0x34));
0x00067838 mov r3, r2 | r3 = r2;
0x0006783a str.w r2, [sb, 0xc] | __asm ("str.w r2, [sb, 0xc]");
0x0006783e b 0x67584 | goto label_28;
| label_91:
0x00067844 ldr r1, [r0, 4] | r1 = *((r0 + 4));
0x00067846 lsls r1, r1, 0x1e | r1 <<= 0x1e;
| if (r1 < r1) {
0x00067848 bmi.w 0x679cc | goto label_94;
| }
0x0006784c cmp r6, 0 |
0x0006784e it ne |
| if (r6 != 0) {
0x00067850 cmpne sb, ip | __asm ("cmpne sb, ip");
| }
| if (r6 > 0) {
0x00067852 bhi.w 0x67a3a | goto label_95;
| }
| if (r6 != 0) {
0x00067856 cbz r6, 0x67862 |
0x00067858 sub.w r2, ip, sb | r2 = ip - sb;
0x0006785c add r3, r2 | r3 += r2;
0x0006785e str.w r3, [r0, 0x450] | __asm ("str.w r3, aav.0x000000ff");
| }
0x00067862 ands r2, ip, 7 | r2 = ip & 7;
0x00067866 ldr r3, [sp, 8] | r3 = var_8h;
0x00067868 itett ne |
| if (r2 != ip) {
0x0006786a rsbne r2, r2, 8 | __asm ("rsbne r2, r2, 8");
| }
| if (r2 == ip) {
0x0006786e movne r2, r6 | r2 = r6;
| }
| if (r2 == ip) {
0x00067870 addne r1, ip, r2 | r1 = ip + r2;
| }
| if (r2 != ip) {
0x00067874 adds r2, r2, r6 | r2 += r6;
| }
0x00067876 add fp, r2 |
0x00067878 it eq |
| if (r2 != r2) {
0x0006787a moveq r1, ip | r1 = ip;
| }
0x0006787c add fp, ip |
0x0006787e add r3, fp | r3 += fp;
0x00067880 sub.w r2, r2, fp | r2 -= fp;
0x00067884 and.w r3, r3, r8 | r3 &= r8;
0x00067888 add.w r8, r3, r2 | r8 = r3 + r2;
0x0006788c cmp.w r8, 0 |
0x00067890 mov fp, r8 |
| if (r8 < 0) {
0x00067892 blt.w 0x67a58 | goto label_96;
| }
0x00067894 strh r1, [r4, 6] | *((r4 + 6)) = r1;
0x00067896 mov r0, r8 | r0 = r8;
0x00067898 str r1, [sp, 8] | var_8h = r1;
0x0006789a bl 0x66d80 | default_morecore ();
0x0006789e ldr r1, [sp, 8] | r1 = var_8h;
0x000678a0 mov r2, r0 | r2 = r0;
0x000678a2 cmp r0, 0 |
| if (r0 == 0) {
0x000678a4 beq.w 0x679e4 | goto label_97;
| }
| label_92:
0x000678fa mov.w r3, -1 | r3 = -1;
0x000678fe movs r0, 0 | r0 = 0;
0x00067900 mov r1, fp | r1 = fp;
0x00067902 strd r3, r0, [sp] | __asm ("strd r3, r0, [sp]");
0x00067906 movs r2, 3 | r2 = 3;
0x00067908 movs r3, 0x22 | r3 = 0x22;
0x0006790a bl 0xa9f88 | r0 = mmap ()
0x0006790e mov r1, r0 | r1 = r0;
0x00067910 adds r0, r1, 1 | r0 = r1 + 1;
| if (r0 == r1) {
0x00067912 beq 0x679c0 | goto label_98;
| }
0x00067914 ldr r0, [pc, 0x90] |
0x00067916 add.w r2, r1, fp | r2 = r1 + fp;
0x0006791a add r0, pc | r0 = 0xcf2c6;
0x0006791c ldr r3, [r0, 4] | r3 = *(0xcf2ca);
0x0006791e orr r3, r3, 2 | r3 |= 2;
0x00067922 str r3, [r0, 4] | *((r0 + 4)) = r3;
0x00067924 cmp r1, 0 |
| if (r1 == 0) {
0x00067926 beq 0x67a0a | goto label_99;
| }
0x00067928 ldr r3, [pc, 0x80] |
0x0006792a ldr.w ip, [r0, 0x450] | ip = *((r0 + 0x450));
0x0006792e add r3, pc |
0x00067930 ldr r3, [r3, 0x2c] | r3 = *(0xcf30a);
| if (r3 == 0) {
0x00067932 cbz r3, 0x6795a | goto label_100;
| }
0x00067934 ands r8, r1, 7 | r8 = r1 & 7;
0x00067938 add.w r3, fp, ip | r3 = fp + ip;
0x0006793c str.w r3, [r0, 0x450] | __asm ("str.w r3, aav.0x000000ff");
0x00067940 it eq |
| if (r8 == r1) {
0x00067942 moveq fp, r8 | goto label_101;
| }
| if (r8 == r1) {
| label_101:
0x00067944 beq 0x678a8 | void (*0x678a8)() ();
| }
| do {
0x00067946 ldr r3, [pc, 0x68] |
0x00067948 movw r2, 0xac7 | r2 = 0xac7;
0x0006794c ldr r1, [pc, 0x64] |
0x0006794e ldr r0, [pc, 0x68] |
0x00067950 add r3, pc | r3 = 0xcf306;
0x00067952 add r1, pc | r1 = 0xcf30a;
0x00067954 add r0, pc | r0 = 0xcf312;
0x00067956 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_100:
0x0006795a mov ip, r1 |
0x0006795c mov lr, r3 | lr = r3;
| label_90:
0x0006795e ldr r3, [pc, 0x5c] |
0x00067960 add r3, pc | r3 = 0xcf322;
0x00067962 str.w ip, [r3, 0x2c] | __asm ("str.w ip, [r3, 0x2c]");
0x00067966 b 0x677b2 | goto label_29;
| label_98:
0x000679c0 ldr r2, [pc, 0x100] |
0x000679c2 add r2, pc | r2 = 0xcf48a;
0x000679c4 ldr.w r3, [r2, 0x450] | r3 = *(0xcf8da);
0x000679c8 ldr r1, [r2, 0x34] | r1 = *(0xcf4be);
0x000679ca b 0x675a2 | void (*0x675a2)() ();
| label_94:
0x000679cc ands r8, ip, 7 | r8 = ip & 7;
0x000679d0 bne 0x67946 |
| } while (r8 != ip);
0x000679d2 mov r1, ip | r1 = ip;
0x000679d4 mov fp, r8 |
0x000679d6 cmp.w lr, 0 |
| if (lr == 0) {
0x000679da beq.w 0x678a8 | void (*0x678a8)() ();
| }
0x000679de mov r0, r8 | r0 = r8;
0x000679e0 str.w ip, [sp, 8] | __asm ("str.w ip, [var_8h]");
| label_97:
0x000679e4 bl 0x66d80 | default_morecore ();
0x000679e8 ldr r1, [sp, 8] | r1 = var_8h;
0x000679ea mov r2, r0 | r2 = r0;
0x000679ec cmp r0, 0 |
| if (r0 != 0) {
0x000679ee bne 0x67a80 | void (*0x67a80)() ();
| }
0x000679f0 ldr r2, [pc, 0xd4] |
0x000679f2 add r2, pc | r2 = 0xcf4be;
0x000679f4 ldr.w r3, [r2, 0x450] | r3 = *(0xcf90e);
0x000679f8 ldr r1, [r2, 0x34] | r1 = *(0xcf4f2);
0x000679fa b 0x675a2 | void (*0x675a2)() ();
| label_89:
0x000679fc ldr r3, [pc, 0xcc] |
0x000679fe add r3, pc |
0x00067a00 ldr r3, [r3, 4] | r3 = *(0xcf4d2);
0x00067a02 lsls r3, r3, 0x1e | r3 <<= 0x1e;
| if (r3 < r3) {
0x00067a04 bmi.w 0x677f2 | goto label_30;
| }
0x00067a08 b 0x677e8 | goto label_31;
| label_99:
0x00067a0a ldr.w r3, [r0, 0x450] | r3 = *((r0 + 0x450));
0x00067a0e ldr r1, [r0, 0x34] | r1 = *((r0 + 0x34));
0x00067a10 b 0x675a2 | void (*0x675a2)() ();
| label_82:
0x00067a12 ldr r3, [pc, 0xbc] |
0x00067a14 movw r2, 0x9d4 | r2 = 0x9d4;
0x00067a18 ldr r1, [pc, 0xb8] |
0x00067a1a ldr r0, [pc, 0xbc] |
0x00067a1c add r3, pc | r3 = 0xcf4f2;
0x00067a1e add r1, pc | r1 = 0xcf4f6;
0x00067a20 add r0, pc | r0 = 0xcf4fe;
0x00067a22 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
0x00067a24 invalid |
| label_83:
0x00067a26 ldr r3, [pc, 0xb4] |
0x00067a28 movw r2, 0x9da | r2 = 0x9da;
0x00067a2c ldr r1, [pc, 0xb0] |
0x00067a2e ldr r0, [pc, 0xb4] |
0x00067a30 add r3, pc | r3 = 0xcf512;
0x00067a32 add r1, pc | r1 = 0xcf516;
0x00067a34 add r0, pc | r0 = 0xcf51e;
0x00067a36 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| label_95:
0x00067a3a ldr r0, [pc, 0xac] |
0x00067a3c add r0, pc | r0 = 0xcf52a;
0x00067a3e bl 0x66078 | fcn_00066078 (r0);
| label_93:
0x00067a42 add.w r6, r8, 3 | r6 = r8 + 3;
0x00067a46 rsb.w r3, r8, 0 | r3 = r8 - ;
0x00067a4a add r6, r5 | r6 += r5;
0x00067a4c ands r6, r3 | r6 &= r3;
0x00067a4e cmp r6, r5 |
| if (r6 <= r5) {
0x00067a50 bhi 0x67aa6 |
| label_33:
0x00067a52 movs r3, 1 | r3 = 1;
0x00067a54 str r3, [sp, 0x18] | var_18h = r3;
0x00067a56 b 0x6750e | goto label_32;
| label_96:
0x00067a58 ldr r3, [pc, 0x90] |
0x00067a5a movw r2, 0xaae | r2 = 0xaae;
0x00067a5e ldr r1, [pc, 0x90] |
0x00067a60 ldr r0, [pc, 0x90] |
0x00067a62 add r3, pc | r3 = 0xcf552;
0x00067a64 add r1, pc | r1 = 0xcf55a;
0x00067a66 add r0, pc | r0 = 0xcf55e;
0x00067a68 bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
| }
0x00067aa6 ldr r3, [sp, 0x18] | r3 = var_18h;
0x00067aa8 movs r2, 3 | r2 = 3;
0x00067aaa mov r1, r6 | r1 = r6;
0x00067aac str r3, [sp, 4] | var_4h = r3;
0x00067aae mov.w r3, -1 | r3 = -1;
0x00067ab0 adds r3, 0xff | r3 += 0xff;
0x00067ab2 str r3, [sp] | *(sp) = r3;
0x00067ab4 movs r3, 0x22 | r3 = 0x22;
0x00067ab6 bl 0xa9f88 | mmap ()
0x00067ab8 invalid |
0x00067abc adds r0, r3, 1 | r0 = r3 + 1;
| if (r0 != r3) {
0x00067abe bne.w 0x676c2 | void (*0x676c2)() ();
| }
0x00067ac0 add r6, sp, 0 | r6 = sp + 0;
0x00067ac2 b 0x67a52 | goto label_33;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x674c0 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.000674c0 () | void fcn_000674c0 (int16_t arg_34h, int16_t arg_450h, uint32_t arg1, uint32_t arg2) {
| int16_t var_0h_2;
| int16_t var_4h_2;
| int16_t var_8h_2;
| int16_t var_18h_2;
| r0 = arg1;
| r1 = arg2;
0x000674c0 ldr.w r3, [pc, 0x4a8] | r3 = *(0x0006796c);
0x000674c4 ldr.w r2, [pc, 0x4a8] | r2 = *(0x67970);
0x000674c8 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000674cc mov r5, r0 | r5 = r0;
0x000674ce add r3, pc | r3 += pc;
0x000674d0 sub sp, 0x24 |
0x000674d2 mov r4, r1 | r4 = r1;
0x000674d4 ldr r2, [r3, r2] | r2 = *((r3 + r2));
0x000674d6 ldr.w r8, [r2, 0x10] | r8 = *((r2 + 0x10));
0x000674da cmp r1, 0 |
| if (r1 == 0) {
0x000674dc beq.w 0x67692 | goto label_10;
| }
0x000674e0 ldr.w r3, [pc, 0x490] |
0x000674e4 add r3, pc | r3 = 0xcee5c;
0x000674e6 ldr r2, [r3, 8] | r2 = *(0xcee64);
0x000674e8 cmp r2, r0 |
0x000674ea bls 0x675e2 |
| while (r2 >= r3) {
0x000674ec movs r3, 0 | r3 = 0;
0x000674ee str r3, [sp, 0x18] | var_18h_2 = r3;
| label_0:
0x000674f0 add.w r3, r4, 0x34 | r3 = r4 + 0x34;
0x000674f4 mov.w fp, 0 |
0x000674f8 str r3, [sp, 8] | var_8h_2 = r3;
0x000674fa movt fp, 0xfff0 |
0x000674fc ldrb r0, [r6, 0xf] | r0 = *(var_fh);
| label_6:
0x000675a2 ldr.w r2, [r4, 0x454] | r2 = *((r4 + 0x454));
0x000675a6 cmp r2, r3 |
0x000675a8 it lo |
| if (r2 >= r3) {
0x000675aa strlo r3, [r4, 0x454] | *((r4 + 0x454)) = r3;
| }
0x000675ae ldr r3, [r1, 4] | r3 = *((r1 + 4));
0x000675b0 bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x000675b4 cmp sl, r3 |
| if (sl > r3) {
0x000675b6 bhi 0x6767c | goto label_11;
| }
0x000675b8 ldr r2, [pc, 0x3c4] |
0x000675ba subs r3, r3, r5 | r3 -= r5;
0x000675bc add.w r0, r1, 8 | r0 = r1 + 8;
0x000675c0 adds r6, r1, r5 | r6 = r1 + r5;
0x000675c2 orr r3, r3, 1 | r3 |= 1;
0x000675c6 str r6, [r4, 0x34] | *((r4 + 0x34)) = r6;
0x000675c8 add r2, pc | r2 = 0xcef4c;
0x000675ca subs r2, r4, r2 | r2 = r4 - r2;
0x000675cc it ne |
| if (r2 == r4) {
0x000675ce movne r2, 1 | r2 = 1;
| }
0x000675d0 orr.w r2, r5, r2, lsl 2 | r2 = r5 | (r2 << 2);
0x000675d4 orr r2, r2, 1 | r2 |= 1;
0x000675d8 str r2, [r1, 4] | *((r1 + 4)) = r2;
0x000675da str r3, [r6, 4] | *((r6 + 4)) = r3;
| label_4:
0x000675dc add sp, 0x24 |
0x000675de pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
0x000675e2 ldrd r2, r3, [r3, 0x14] | __asm ("ldrd r2, r3, [r3, 0x14]");
0x000675e6 cmp r2, r3 |
0x000675e8 bge 0x674ec |
| }
0x000675ea add.w r6, r8, 3 | r6 = r8 + 3;
0x000675ee rsb.w r3, r8, 0 | r3 = r8 - ;
0x000675f2 add r6, r0 | r6 += r0;
0x000675f4 ands r6, r3 | r6 &= r3;
0x000675f6 cmp r0, r6 |
| if (r0 <= r6) {
0x000675f8 blo.w 0x67a88 | goto label_12;
| }
| label_9:
0x000675fc movs r3, 1 | r3 = 1;
0x000675fe str r3, [sp, 0x18] | var_18h_2 = r3;
0x00067600 b 0x674f0 | goto label_0;
| label_11:
0x0006767c ldr r3, [pc, 0x2e8] |
0x0006767e mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x00067682 movs r1, 0xc | r1 = 0xc;
0x00067684 movs r0, 0 | r0 = 0;
0x00067686 add r3, pc |
0x00067688 ldr r3, [r3] | r3 = *(0xceff2);
0x0006768a str r1, [r2, r3] | *((r2 + r3)) = r1;
0x0006768c add sp, 0x24 |
0x0006768e pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_10:
0x00067692 add.w r6, r8, 3 | r6 = r8 + 3;
0x00067696 rsb.w r8, r8, 0 | r8 -= ;
0x0006769a add r6, r0 | r6 += r0;
0x0006769c and.w r6, r6, r8 | r6 &= r8;
0x000676a0 cmp r0, r6 |
| if (r0 >= r6) {
0x000676a2 bhs.w 0x67840 | goto label_13;
| }
0x000676a6 mov.w r1, -1 | r1 = -1;
0x000676aa movs r3, 0x22 | r3 = 0x22;
0x000676ac movs r2, 3 | r2 = 3;
0x000676ae str r1, [sp] | *(sp) = r1;
0x000676b0 mov r0, r4 | r0 = r4;
0x000676b2 mov r1, r6 | r1 = r6;
0x000676b4 str r4, [sp, 4] | var_4h_2 = r4;
0x000676b6 bl 0xa9f88 | r0 = mmap ()
0x000676ba adds r2, r0, 1 | r2 = r0 + 1;
0x000676bc mov r3, r0 | r3 = r0;
| if (r2 == r0) {
0x000676be beq.w 0x67840 | goto label_13;
| }
| label_8:
0x000676c2 ands r2, r3, 7 | r2 = r3 & 7;
0x000676c6 add.w r0, r3, 8 | r0 = r3 + 8;
| if (r2 != r3) {
0x000676ca bne.w 0x67a6c | goto label_14;
| }
0x000676ce ldr r4, [pc, 0x2b4] |
0x000676d0 orr r1, r6, 2 | r1 = r6 | 2;
0x000676d4 strd r2, r1, [r3] | __asm ("strd r2, r1, [r3]");
0x000676d8 add r4, pc | r4 = 0xcf062;
0x000676da add.w r1, r4, 0x14 | r1 = r4 + 0x14;
| label_1:
0x000676de ldr r2, [r4, 0x14] | r2 = *((r4 + 0x14));
0x000676e0 adds r3, r2, 1 | r3 = r2 + 1;
| do {
0x000676e2 ldrex r5, [r1] | __asm ("ldrex r5, [r1]");
0x000676e6 cmp r5, r2 |
| if (r5 != r2) {
0x000676e8 bne 0x676f6 | goto label_15;
| }
0x000676ea strex r7, r3, [r1] | __asm ("strex r7, r3, [r1]");
0x000676ee cmp r7, 0 |
0x000676f0 bne 0x676e2 |
| } while (r7 != 0);
0x000676f2 dmb ish | __asm ("dmb ish");
| if (r7 != 0) {
| label_15:
0x000676f6 bne 0x676de | goto label_1;
| }
0x000676f8 ldr r1, [pc, 0x28c] |
0x000676fa add r1, pc | r1 = 0xcf086;
0x000676fc add.w r4, r1, 0x1c | r4 = r1 + 0x1c;
| label_2:
0x00067700 ldr r2, [r1, 0x1c] | r2 = *((r1 + 0x1c));
0x00067702 cmp r3, r2 |
| if (r3 <= r2) {
0x00067704 ble 0x6771c | goto label_16;
| }
| do {
0x00067706 ldrex r5, [r4] | __asm ("ldrex r5, [r4]");
0x0006770a cmp r5, r2 |
| if (r5 != r2) {
0x0006770c bne 0x6771a | goto label_17;
| }
0x0006770e strex r7, r3, [r4] | __asm ("strex r7, r3, [r4]");
0x00067712 cmp r7, 0 |
0x00067714 bne 0x67706 |
| } while (r7 != 0);
0x00067716 dmb ish | __asm ("dmb ish");
| if (r7 != 0) {
| label_17:
0x0006771a bne 0x67700 | goto label_2;
| }
| label_16:
0x0006771c ldr r4, [pc, 0x26c] |
0x0006771e add r4, pc | r4 = 0xcf0ae;
0x00067720 add.w r1, r4, 0x24 | r1 = r4 + 0x24;
| label_3:
0x00067724 ldr r2, [r4, 0x24] | r2 = *((r4 + 0x24));
0x00067726 adds r3, r2, r6 | r3 = r2 + r6;
| do {
0x00067728 ldrex r5, [r1] | __asm ("ldrex r5, [r1]");
0x0006772c cmp r5, r2 |
| if (r5 != r2) {
0x0006772e bne 0x6773c | goto label_18;
| }
0x00067730 strex r7, r3, [r1] | __asm ("strex r7, r3, [r1]");
0x00067734 cmp r7, 0 |
0x00067736 bne 0x67728 |
| } while (r7 != 0);
0x00067738 dmb ish | __asm ("dmb ish");
| if (r7 != 0) {
| label_18:
0x0006773c bne 0x67724 | goto label_3;
| }
0x0006773e ldr r1, [pc, 0x250] |
0x00067740 add r1, pc | r1 = 0xcf0d6;
0x00067742 add.w r4, r1, 0x28 | r4 = r1 + 0x28;
| label_5:
0x00067746 ldr r2, [r1, 0x28] | r2 = *((r1 + 0x28));
0x00067748 cmp r3, r2 |
| if (r3 < r2) {
0x0006774a bls.w 0x675dc | goto label_4;
| }
| do {
0x0006774e ldrex r5, [r4] | __asm ("ldrex r5, [r4]");
0x00067752 cmp r5, r2 |
| if (r5 != r2) {
0x00067754 bne 0x67762 | goto label_19;
| }
0x00067756 strex r6, r3, [r4] | __asm ("strex r6, r3, [r4]");
0x0006775a cmp r6, 0 |
0x0006775c bne 0x6774e |
| } while (r6 != 0);
0x0006775e dmb ish | __asm ("dmb ish");
| if (r6 != 0) {
| label_19:
0x00067762 bne 0x67746 | goto label_5;
| }
0x00067764 add sp, 0x24 |
0x00067766 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
0x00067768 ldrh r0, [r6, 0x3e] | r0 = *((r6 + 0x3e));
| label_13:
0x00067840 movs r0, 0 | r0 = 0;
0x00067842 b 0x675dc | goto label_4;
| label_7:
0x000678a8 subs r3, r2, r1 | r3 = r2 - r1;
0x000678aa add r3, fp | r3 += fp;
0x000678ac ldr.w fp, [pc, 0xf4] |
0x000678b0 orr r3, r3, 1 | r3 |= 1;
0x000678b4 add fp, pc | fp = 0xcf25c;
0x000678b6 str.w r1, [fp, 0x34] | __asm ("str.w r1, [arg_34h]");
0x000678ba str r3, [r1, 4] | *((r1 + 4)) = r3;
0x000678bc ldr.w r3, [fp, 0x450] | r3 = *(arg_450h);
0x000678c0 add r3, r8 | r3 += r8;
0x000678c2 str.w r3, [fp, 0x450] | __asm ("str.w r3, [arg_450h]");
0x000678c6 cmp r6, 0 |
| if (r6 == 0) {
0x000678c8 beq.w 0x675a2 | goto label_6;
| }
0x000678cc subs r6, 0x10 | r6 -= 0x10;
0x000678ce movs r2, 9 | r2 = 9;
0x000678d0 orr r0, r6, 1 | r0 = r6 | 1;
0x000678d4 cmp r6, 0xf |
0x000678d6 str r0, [r7, 4] | *((r7 + 4)) = r0;
0x000678d8 add.w r0, r7, r6 | r0 = r7 + r6;
0x000678dc str r2, [r0, 4] | *((r0 + 4)) = r2;
0x000678de str r2, [sb, -0x4] | *((sb - 0x4)) = r2;
| if (r6 < 0xf) {
0x000678e2 bls.w 0x675a2 | goto label_6;
| }
0x000678e6 mov r1, r7 | r1 = r7;
0x000678e8 movs r2, 1 | r2 = 1;
0x000678ea mov r0, fp | r0 = fp;
0x000678ec bl 0x66e1c | fcn_00066e1c (r0, r1, r2, r3, r4, r5, r6);
0x000678f0 ldr.w r3, [fp, 0x450] | r3 = *(arg_450h);
0x000678f4 ldr.w r1, [fp, 0x34] | r1 = *(arg_34h);
0x000678f8 b 0x675a2 | goto label_6;
| label_14:
0x00067a6c ldr r3, [pc, 0x88] |
0x00067a6e mov.w r2, 0x9a0 | r2 = 0x9a0;
0x00067a72 ldr r1, [pc, 0x88] |
0x00067a74 ldr r0, [pc, 0x88] |
0x00067a76 add r3, pc | r3 = 0xcf572;
0x00067a78 add r1, pc | r1 = 0xcf57a;
0x00067a7a add r0, pc | r0 = 0xcf57e;
0x00067a7c bl 0x65f00 | fcn_00065f00 (r0, r1, r2, r3);
0x00067a80 mov.w r8, 0 | r8 = 0;
0x00067a84 mov fp, r8 |
0x00067a86 b 0x678a8 | goto label_7;
| label_12:
0x00067a88 mov.w r3, -1 | r3 = -1;
0x00067a8c movs r0, 0 | r0 = 0;
0x00067a8e mov r1, r6 | r1 = r6;
0x00067a90 strd r3, r0, [sp] | __asm ("strd r3, r0, [sp]");
0x00067a94 movs r2, 3 | r2 = 3;
0x00067a96 movs r3, 0x22 | r3 = 0x22;
0x00067a98 bl 0xa9f88 | r0 = mmap ()
0x00067a9c adds r1, r0, 1 | r1 = r0 + 1;
0x00067a9e mov r3, r0 | r3 = r0;
| if (r1 != r0) {
0x00067aa0 bne.w 0x676c2 | goto label_8;
| }
0x00067aa4 b 0x675fc | goto label_9;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x9cd38 */
| #include <stdint.h>
|
; (fcn) fcn.0009cd38 () | void fcn_0009cd38 (int16_t arg_290h, int16_t arg_294h, int16_t arg_298h, int16_t arg_29ch, int16_t arg1, int16_t arg2, int16_t arg3, int16_t arg4) {
| int16_t var_bp_0h;
| int16_t var_0h;
| int16_t var_4h;
| int16_t var_8h;
| int16_t var_ch;
| int16_t var_18h;
| void * s;
| int32_t var_28h;
| int32_t var_30h;
| int16_t var_74h;
| int32_t var_80h;
| int32_t var_84h;
| int32_t var_88h;
| int32_t var_8ch;
| int32_t var_90h;
| int32_t var_90h_2;
| int32_t var_98h;
| int32_t var_9ch;
| int32_t var_a0h;
| void * var_118h;
| int16_t var_26ch;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
| r3 = arg4;
0x0009cd38 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0009cd3c sub.w sp, sp, 0x26c |
0x0009cd40 mov sb, r3 | sb = r3;
0x0009cd42 strd r1, r2, [sp, 8] | __asm ("strd r1, r2, [var_8h]");
0x0009cd46 mov sl, r0 | sl = r0;
0x0009cd48 movs r4, 0 | r4 = 0;
0x0009cd4a ldr r3, [sp, 0x290] | r3 = *(arg_290h);
0x0009cd4c ldr r2, [pc, 0x174] |
0x0009cd4e subs r3, 4 | r3 -= 4;
0x0009cd50 add r2, pc | r2 = 0x139c18;
| do {
0x0009cd52 ldr r5, [r3, 4]! | r5 = *((r3 += 4));
0x0009cd56 mov r6, r4 | r6 = r4;
0x0009cd58 adds r4, 1 | r4++;
0x0009cd5a cmp r5, 0 |
0x0009cd5c bne 0x9cd52 |
| } while (r5 != 0);
0x0009cd5e ldr r3, [pc, 0x168] |
0x0009cd60 mov r0, r5 | r0 = r5;
0x0009cd62 ldr r3, [r2, r3] | r3 = *((r2 + r3));
0x0009cd64 ldr r3, [r3, 0x10] | r3 = *(0x9ceda);
0x0009cd66 add.w r6, r3, r6, lsl 2 | r6 = r3 + (r6 << 2);
0x0009cd6a rsbs r3, r3, 0 | r3 -= ;
0x0009cd6c add.w r6, r6, 0x8200 | r6 += 0x8200;
0x0009cd70 adds r6, 3 | r6 += 3;
0x0009cd72 ands r6, r3 | r6 &= r3;
0x0009cd74 ldr r3, [pc, 0x154] | r3 = *(0x9cecc);
0x0009cd76 mov r1, r6 | r1 = r6;
0x0009cd78 ldr r3, [r2, r3] | r3 = *((r2 + r3));
0x0009cd7a str r5, [sp, 4] | var_4h = r5;
0x0009cd7c ldr.w r2, [r3, 0x878] | r2 = *(0x9d744);
0x0009cd80 mov.w r3, -1 | r3 = -1;
0x0009cd84 str r3, [sp] | *(sp) = r3;
0x0009cd86 movs r3, 0x22 |
0x0009cd88 movt r3, 2 | r3 = 0x20022;
0x0009cd8c lsls r2, r2, 2 | r2 <<= 2;
0x0009cd8e and r2, r2, 4 | r2 &= 4;
0x0009cd92 orr r2, r2, 3 | r2 |= 3;
0x0009cd96 bl 0xa9f88 | r0 = mmap ()
0x0009cd9a cmp.w r0, -1 |
0x0009cd9e mov r8, r0 | r8 = r0;
| if (r0 == -1) {
0x0009cda0 beq 0x9ce98 | goto label_2;
| }
0x0009cda2 add.w fp, sp, 0x14 |
0x0009cda6 movs r0, 1 | r0 = 1;
0x0009cda8 mov r1, fp | r1 = fp;
0x0009cdaa add r7, sp, 0x74 | r7 += var_74h;
0x0009cdac bl 0x62128 | pthread_setcancelstate ();
0x0009cdb0 ldr r3, [sp, 8] | r3 = var_8h;
0x0009cdb2 str.w r5, [r7, 0xa0] | __asm ("str.w r5, [var_a0h]");
0x0009cdb6 str.w r3, [r7, 0x80] | __asm ("str.w r3, [var_80h]");
0x0009cdba ldr r3, [sp, 0xc] | r3 = var_ch;
0x0009cdbc str.w r3, [r7, 0x88] | __asm ("str.w r3, [var_88h]");
0x0009cdc0 ldr r3, [sp, 0x29c] | r3 = *(arg_29ch);
0x0009cdc2 str.w r3, [r7, 0x84] | __asm ("str.w r3, [var_84h]");
0x0009cdc6 cmp.w sb, 0 |
| if (sb == 0) {
0x0009cdca beq 0x9ce88 | goto label_3;
| }
| label_1:
0x0009cdcc ldr r3, [sp, 0x290] | r3 = *(arg_290h);
0x0009cdce movs r0, 0 | r0 = 0;
0x0009cdd0 ldr r1, [pc, 0xfc] |
0x0009cdd2 mov r2, r7 | r2 = r7;
0x0009cdd4 mov.w ip, 0xaf |
0x0009cdd8 str.w sb, [r7, 0x8c] | __asm ("str.w sb, [var_8ch]");
0x0009cddc strd r3, r4, [r7, 0x90] | __asm ("strd r3, r4, [var_90h]");
0x0009cde0 ldr r3, [sp, 0x294] | r3 = *(arg_294h);
0x0009cde2 add r1, pc | r1 = 0x139cb6;
0x0009cde4 str.w r3, [r7, 0x98] | __asm ("str.w r3, [var_98h]");
0x0009cde8 ldr r3, [sp, 0x298] | r3 = *(arg_298h);
0x0009cdea str.w r3, [r7, 0x9c] | __asm ("str.w r3, [var_9ch]");
0x0009cdee movs r3, 8 | r3 = 8;
0x0009cdf0 bl 0x21990 | fcn_00021990 ();
0x0009cdf4 movs r2, 0x50 | r2 = 0x50;
0x0009cdf6 movs r1, 0 | r1 = 0;
0x0009cdf8 add r0, sp, 0x20 | r0 += s;
0x0009cdfa movs r4, 0 | r4 = 0;
0x0009cdfc blx 0x6b880 | memset (r0, r1, r2);
0x0009ce00 vldr d16, [pc, 0xac] | __asm ("vldr d16, aav.0x000000ff");
0x0009ce04 add r0, sp, 0x18 | r0 += var_18h;
0x0009ce06 ldr r1, [pc, 0xcc] |
0x0009ce08 mov r2, r7 | r2 = r7;
0x0009ce0a str.w r8, [r0, 0x28] | __asm ("str.w r8, [var_28h]");
0x0009ce0e vstr d16, [sp, 0x18] | __asm ("vstr d16, [sp, 0x18]");
0x0009ce12 vldr d16, [pc, 0xa4] | __asm ("vldr d16, aav.0x000000ff");
0x0009ce16 add r1, pc | r1 = 0x139cf0;
0x0009ce18 str r6, [r0, 0x30] | var_30h = r6;
0x0009ce1a vstr d16, [r0, 0x20] | __asm ("vstr d16, [r0, 0x20]");
0x0009ce1e bl 0xad4d0 | fcn_000ad4d0 (r0, r1, r2);
0x0009ce20 smmla lr, r7, r5, r1 | __asm ("smmla lr, r7, r5, r1");
| if (r4 <= 0) {
0x0009ce24 ble 0x9ce82 | goto label_4;
| }
0x0009ce26 ldr.w sb, [r7, 0xa0] | sb = var_a0h;
0x0009ce2a cmp sb, r4 |
| if (sb > r4) {
0x0009ce2c bgt 0x9ce70 | goto label_5;
| }
| label_0:
0x0009ce2e mov r1, r6 | r1 = r6;
0x0009ce30 mov r0, r8 | r0 = r8;
0x0009ce32 bl 0xaa040 | munmap ();
0x0009ce36 clz r3, sb | r3 &= sb;
0x0009ce3a cmp.w sl, 0 |
0x0009ce3e lsr.w r3, r3, 5 | r3 >>= 5;
0x0009ce42 it eq |
| if (sl != 0) {
0x0009ce44 moveq r3, 0 | r3 = 0;
| }
| if (r3 == 0) {
0x0009ce46 cbz r3, 0x9ce4c | goto label_6;
| }
0x0009ce48 str.w r5, [sl] | __asm ("str.w r5, [sl]");
| do {
| label_6:
0x0009ce4c movs r0, 2 | r0 = 2;
0x0009ce4e mov r1, r7 | r1 = r7;
0x0009ce50 movs r2, 0 | r2 = 0;
0x0009ce52 movs r3, 8 | r3 = 8;
0x0009ce54 mov.w ip, 0xaf |
0x0009ce58 bl 0x21990 | fcn_00021990 ();
0x0009ce5c ldr.w r0, [fp] | r0 = *(fp);
0x0009ce60 mov r1, r2 | r1 = r2;
0x0009ce62 bl 0x62128 | pthread_setcancelstate ();
0x0009ce66 mov r0, sb | r0 = sb;
0x0009ce68 add.w sp, sp, 0x26c |
0x0009ce6c pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_5:
0x0009ce70 mov r1, r4 | r1 = r4;
0x0009ce72 mov r2, r4 | r2 = r4;
0x0009ce74 bl 0x85068 | waitpid ();
0x0009ce78 mov r1, r6 | r1 = r6;
0x0009ce7a mov r0, r8 | r0 = r8;
0x0009ce7c bl 0xaa040 | munmap ();
0x0009ce80 b 0x9ce4c |
| } while (1);
| label_4:
0x0009ce82 rsb.w sb, r5, 0 | sb = r5 - ;
0x0009ce86 b 0x9ce2e | goto label_0;
| label_3:
0x0009ce88 mov r1, sb | r1 = sb;
0x0009ce8a add r0, sp, 0x118 | r0 += var_118h;
0x0009ce8c mov.w r2, 0x150 | r2 = 0x150;
0x0009ce90 mov sb, r0 | sb = r0;
0x0009ce92 blx 0x6b880 | memset (r0, r1, r2);
0x0009ce96 b 0x9cdcc | goto label_1;
| label_2:
0x0009ce98 ldr r3, [pc, 0x24] |
0x0009ce9a mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x0009ce9e add r3, pc |
0x0009cea0 ldr r3, [r3] | r3 = GLIBC_2.4;
0x0009cea2 ldr.w sb, [r2, r3] | sb = *((r2 + r3));
0x0009cea6 mov r0, sb | r0 = sb;
0x0009cea8 add.w sp, sp, 0x26c |
0x0009ceac pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0xd7d44 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.000d7d44 () | void fcn_000d7d44 (int16_t arg_0h, int16_t arg_78h, int16_t arg1, int16_t arg3, char * s) {
| int32_t var_0h_3;
| int32_t var_4h_3;
| int16_t var_0h;
| int16_t var_4h_2;
| int16_t var_8h;
| int32_t fildes;
| char * s1;
| int32_t var_ch;
| int16_t var_10h;
| int32_t var_10h_2;
| int32_t var_1ch;
| int32_t var_1ch_2;
| int32_t var_24h;
| int32_t var_28h;
| int32_t var_2ch;
| int32_t var_30h;
| int32_t var_30h_2;
| int32_t var_38h;
| int32_t var_3ch;
| int32_t var_3ch_2;
| int32_t var_44h;
| int32_t var_48h;
| int32_t var_4ch;
| int32_t var_50h;
| int32_t var_54h;
| int16_t var_58h;
| int32_t var_80h;
| int32_t var_80h_2;
| int16_t var_0h_2;
| r0 = arg1;
| r2 = arg3;
| r1 = s;
0x000d7d44 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000d7d48 sub sp, 0xd4 |
0x000d7d4a mov r4, r0 | r4 = r0;
0x000d7d4c mov r0, r1 | r0 = r1;
0x000d7d4e add r7, sp, 8 | r7 += var_8h;
0x000d7d50 mov r6, r1 | r6 = r1;
0x000d7d52 mov sb, r2 | sb = r2;
0x000d7d54 bl 0x6a8c0 | strlen ();
0x000d7d58 ldr r3, [pc, 0x230] |
0x000d7d5a mrc p15, 0, r5, c13, c0, 3 | __asm ("mrc p15, 0, r5, c13, c0, 3");
0x000d7d5e mov r8, r0 | r8 = r0;
0x000d7d60 add.w sl, r0, 1 | sl = r0 + 1;
0x000d7d64 mov r1, r6 | r1 = r6;
0x000d7d66 mov r0, r4 | r0 = r4;
0x000d7d68 add r3, pc |
0x000d7d6a ldr r3, [r3] | r3 = GLIBC_2.4;
0x000d7d6c mov r2, sl | r2 = sl;
0x000d7d6e ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x000d7d70 str r3, [r7, 0xc] | var_ch = r3;
0x000d7d72 add.w r3, r8, 8 | r3 = r8 + 8;
0x000d7d76 bic r3, r3, 7 | r3 = BIT_MASK (r3, 7);
0x000d7d7a sub.w sp, sp, r3 |
0x000d7d7e bl 0xd7a0c | r0 = fcn_000d7a0c (r0, r1, r2);
0x000d7d82 subs r4, r0, 0 | r4 = r0 - 0;
0x000d7d84 add r3, sp, 8 | r3 += var_8h;
0x000d7d86 it lt |
| if (r4 >= r0) {
0x000d7d88 movlt r6, -1 | r6 = -1;
| }
0x000d7d8c str r3, [r7, 8] | s1 = r3;
| if (r4 >= r0) {
0x000d7d8e blt 0xd7de2 |
0x000d7d90 strd r3, sl, [r7, 0x1c] | __asm ("strd r3, sl, [var_1ch]");
0x000d7d94 movs r3, 0 | r3 = 0;
0x000d7d96 strd r3, r3, [r7, 0x3c] | __asm ("strd r3, r3, [var_3ch]");
0x000d7d9a movw r1, 0x1388 | r1 = 0x1388;
0x000d7d9e str r3, [r7, 0x54] | var_54h = r3;
0x000d7da0 movs r3, 0x10 | r3 = 0x10;
0x000d7da2 str r3, [r7, 0x50] | var_50h = r3;
0x000d7da4 add.w fp, r7, 0x3c |
0x000d7da8 str r3, [r7, 0x2c] | var_2ch = r3;
0x000d7daa movs r3, 1 | r3 = 1;
0x000d7dac strd r3, r3, [r7, 0x30] | __asm ("strd r3, r3, [var_30h]");
0x000d7db0 add.w r3, r7, 0x10 | r3 += var_10h;
0x000d7db4 str r3, [r7, 0x24] | var_24h = r3;
0x000d7db6 movs r3, 8 | r3 = 8;
0x000d7db8 str r3, [r7, 0x28] | var_28h = r3;
0x000d7dba add.w r3, r7, 0x1c | r3 += var_1ch;
0x000d7dbe str r3, [r7, 0x44] | var_44h = r3;
0x000d7dc0 movs r3, 2 | r3 = 2;
0x000d7dc2 str r3, [r7, 0x48] | var_48h = r3;
0x000d7dc4 add.w r3, r7, 0x2c | r3 += var_2ch;
0x000d7dc8 str r3, [r7, 0x4c] | var_4ch = r3;
0x000d7dca mov.w r3, -1 | r3 = -1;
0x000d7dce str r3, [r7, 0x38] | var_38h = r3;
0x000d7dd0 bl 0xd7950 | r0 = fcn_000d7950 (r0, r1);
0x000d7dd4 cmp r0, 0 |
| if (r0 > 0) {
0x000d7dd6 bgt 0xd7e2e | goto label_8;
| }
| label_1:
0x000d7dd8 mov r0, r4 | r0 = r4;
0x000d7dda mov.w r6, -1 | r6 = -1;
0x000d7dde bl 0x9ff60 | close (r0);
| }
| label_2:
0x000d7de2 ldr.w r4, [sb] | r4 = *(sb);
0x000d7de6 ldr r3, [pc, 0x1a8] |
0x000d7de8 ldr r2, [r7, 0xc] | r2 = var_ch;
0x000d7dea add r3, pc |
0x000d7dec ldr r3, [r3] | r3 = GLIBC_2.4;
0x000d7dee str r2, [r5, r3] | *((r5 + r3)) = r2;
0x000d7df0 str.w r6, [sb] | __asm ("str.w r6, [sb]");
| if (r4 == 0) {
0x000d7df4 cbz r4, 0xd7e18 | goto label_9;
| }
0x000d7df6 add.w r2, r4, 0xc | r2 = r4 + 0xc;
| label_0:
0x000d7dfa ldr r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x000d7dfc subs r1, r3, 1 | r1 = r3 - 1;
| do {
0x000d7dfe ldrex r0, [r2] | __asm ("ldrex r0, [r2]");
0x000d7e02 cmp r0, r3 |
| if (r0 != r3) {
0x000d7e04 bne 0xd7e12 | goto label_10;
| }
0x000d7e06 strex r5, r1, [r2] | __asm ("strex r5, r1, [r2]");
0x000d7e0a cmp r5, 0 |
0x000d7e0c bne 0xd7dfe |
| } while (r5 != 0);
0x000d7e0e dmb ish | __asm ("dmb ish");
| if (r5 != 0) {
| label_10:
0x000d7e12 bne 0xd7dfa | goto label_0;
| }
0x000d7e14 cmp r3, 1 |
| if (r3 == 1) {
0x000d7e16 beq 0xd7e76 | goto label_11;
| }
| label_9:
0x000d7e18 mov r0, r6 | r0 = r6;
0x000d7e1a adds r7, 0xcc | r7 += 0xcc;
0x000d7e1c mov sp, r7 |
0x000d7e1e pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| do {
0x000d7e22 ldr r3, [pc, 0x170] |
0x000d7e24 add r3, pc |
0x000d7e26 ldr r3, [r3] | r3 = GLIBC_2.4;
0x000d7e28 ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x000d7e2a cmp r3, 4 |
| if (r3 != 4) {
0x000d7e2c bne 0xd7e3e | goto label_12;
| }
| label_8:
0x000d7e2e mov.w r2, 0x40000000 | r2 = 0x40000000;
0x000d7e32 mov r1, fp | r1 = fp;
0x000d7e34 mov r0, r4 | r0 = r4;
0x000d7e36 bl 0xadd54 | r0 = recvmsg (r0, r1);
0x000d7e3a adds r3, r0, 1 | r3 = r0 + 1;
0x000d7e3c beq 0xd7e22 |
| } while (r3 == r0);
| label_12:
0x000d7e3e ldr r3, [r7, 0x50] | r3 = var_50h;
0x000d7e40 cmp r3, 0xb |
| if (r3 < 0xb) {
0x000d7e42 bls 0xd7dd8 | goto label_1;
| }
0x000d7e44 ldr r3, [r7, 0x4c] | r3 = var_4ch;
0x000d7e46 cmp r3, 0 |
| if (r3 == 0) {
0x000d7e48 beq 0xd7dd8 | goto label_1;
| }
0x000d7e4a ldr r3, [r3] | r3 = *(r3);
0x000d7e4c cmp r3, 0x10 |
| if (r3 != 0x10) {
0x000d7e4e bne 0xd7dd8 | goto label_1;
| }
0x000d7e50 ldr r3, [r7, 0x38] | r3 = var_38h;
0x000d7e52 cmp sl, r0 |
0x000d7e54 str r3, [r7, 4] | fildes = r3;
| if (sl != r0) {
0x000d7e56 bne 0xd7e94 | goto label_13;
| }
0x000d7e58 ldr r0, [r7, 8] | r0 = s1;
0x000d7e5a mov r1, r6 | r1 = r6;
0x000d7e5c bl 0x6a170 | r0 = strcmp (r0, r1);
0x000d7e60 cmp r0, 0 |
| if (r0 == 0) {
0x000d7e62 beq 0xd7f2e | goto label_14;
| }
| do {
| label_3:
0x000d7e64 mov.w r6, -1 | r6 = -1;
| label_4:
0x000d7e68 ldr r0, [r7, 4] | r0 = fildes;
0x000d7e6a bl 0x9ff60 | close (r0);
0x000d7e6e mov r0, r4 | r0 = r4;
0x000d7e70 bl 0x9ff60 | close (r0);
0x000d7e74 b 0xd7de2 | goto label_2;
| label_11:
0x000d7e76 ldr r3, [r4, 0xc] | r3 = *((r4 + 0xc));
0x000d7e78 cmp r3, 0 |
| if (r3 != 0) {
0x000d7e7a bne 0xd7f78 | goto label_15;
| }
0x000d7e7c ldr r1, [r4, 8] | r1 = *((r4 + 8));
0x000d7e7e ldr r0, [r4] | r0 = *(r4);
0x000d7e80 bl 0xaa040 | munmap ();
0x000d7e84 mov r0, r4 | r0 = r4;
0x000d7e86 blx 0x212d4 | fcn_000212d4 ();
0x000d7e8a mov r0, r6 | r0 = r6;
0x000d7e8c adds r7, 0xcc | r7 += 0xcc;
0x000d7e8e mov sp, r7 |
0x000d7e90 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_13:
0x000d7e94 add.w r8, r8, 9 | r8 += 9;
0x000d7e98 cmp r8, r0 |
0x000d7e9a bne 0xd7e64 |
| } while (r8 != r0);
0x000d7e9c ldr r0, [r7, 8] | r0 = s1;
0x000d7e9e mov r1, r6 | r1 = r6;
0x000d7ea0 bl 0x6a170 | r0 = strcmp (r0, r1);
0x000d7ea4 cmp r0, 0 |
| if (r0 != 0) {
0x000d7ea6 bne 0xd7e64 | goto label_3;
| }
0x000d7ea8 ldr r1, [r7, 0x10] | r1 = var_10h;
| label_5:
0x000d7eaa ldr r3, [r7, 4] | r3 = fildes;
0x000d7eac movs r0, 0 | r0 = 0;
0x000d7eae str r0, [sp, 4] | var_4h_2 = r0;
0x000d7eb0 str r3, [sp] | *(sp) = r3;
0x000d7eb2 movs r3, 1 | r3 = 1;
0x000d7eb4 mov r2, r3 | r2 = r3;
0x000d7eb6 bl 0xa9f88 | r0 = mmap ()
0x000d7eba cmp.w r0, -1 |
0x000d7ebe mov r8, r0 | r8 = r0;
| if (r0 == -1) {
0x000d7ec0 beq 0xd7e64 | goto label_3;
| }
0x000d7ec2 ldr r3, [r0] | r3 = *(r0);
0x000d7ec4 cmp r3, 2 |
| if (r3 == 2) {
0x000d7ec6 bne 0xd7f24 |
0x000d7ec8 ldr r3, [r0, 4] | r3 = *((r0 + 4));
0x000d7eca cmp r3, 0x78 |
| if (r3 != 0x78) {
0x000d7ecc bne 0xd7f24 | goto label_6;
| }
0x000d7ece ldr r3, [r0, 0x28] | r3 = *((r0 + 0x28));
| if (r3 == 0) {
0x000d7ed0 cbz r3, 0xd7f24 | goto label_6;
| }
0x000d7ed2 ldr r2, [r0, 0xc] | r2 = *((r0 + 0xc));
0x000d7ed4 cmp r2, 0 |
| if (r2 == 0) {
0x000d7ed6 beq 0xd7f50 | goto label_16;
| }
| label_7:
0x000d7ed8 ldr.w fp, [r8, 0x2c] | fp = *((r8 + 0x2c));
0x000d7edc lsls r3, r3, 2 | r3 <<= 2;
0x000d7ede ldrd r1, r2, [r7, 0x10] | __asm ("ldrd r1, r2, [var_10h]");
0x000d7ee2 adds r3, 0xf | r3 += 0xf;
0x000d7ee4 bic r3, r3, 0xf | r3 = BIT_MASK (r3, 0xf);
0x000d7ee8 add.w sl, fp, 0x78 | sl += arg_78h;
0x000d7eec add sl, r3 | sl += r3;
0x000d7eee str r3, [r7, 8] | s1 = r3;
0x000d7ef0 cmp r1, sl |
0x000d7ef2 sbcs r2, r2, 0 | __asm ("sbcs r2, r2, 0");
| if (r1 <= sl) {
0x000d7ef6 blo 0xd7f26 | goto label_17;
| }
0x000d7ef8 movs r0, 0x14 | r0 = 0x14;
0x000d7efa str r1, [r7] | *(r7) = r1;
0x000d7efc blx 0x21354 | fcn_00021354 ();
0x000d7f00 ldr r1, [r7] | r1 = *(r7);
0x000d7f02 mov r6, r0 | r6 = r0;
| if (r0 == 0) {
0x000d7f04 cbz r0, 0xd7f26 | goto label_17;
| }
0x000d7f06 ldr.w r2, [r8, 4] | r2 = *((r8 + 4));
0x000d7f0a ldr r3, [r7, 8] | r3 = s1;
0x000d7f0c str.w r8, [r0] | __asm ("str.w r8, [r0]");
0x000d7f10 str.w sl, [r0, 8] | __asm ("str.w sl, [r0, 8]");
0x000d7f14 add r3, r2 | r3 += r2;
0x000d7f16 str.w fp, [r0, 0x10] | __asm ("str.w fp, [r0, 0x10]");
0x000d7f1a add r3, r8 | r3 += r8;
0x000d7f1c str r3, [r0, 4] | *((r0 + 4)) = r3;
0x000d7f1e movs r3, 1 | r3 = 1;
0x000d7f20 str r3, [r0, 0xc] | *((r0 + 0xc)) = r3;
0x000d7f22 b 0xd7e68 | goto label_4;
| }
| label_6:
0x000d7f24 ldr r1, [r7, 0x10] | r1 = var_10h;
| label_17:
0x000d7f26 mov r0, r8 | r0 = r8;
0x000d7f28 bl 0xaa040 | munmap ();
0x000d7f2c b 0xd7e64 | goto label_3;
| label_14:
0x000d7f2e ldr r0, [r7, 4] | r0 = fildes;
0x000d7f30 add.w r1, r7, 0x58 | r1 += var_58h;
0x000d7f34 bl 0x9ea88 | r0 = fstat64_time64 ();
0x000d7f38 cmp r0, 0 |
| if (r0 != 0) {
0x000d7f3a bne 0xd7e64 | goto label_3;
| }
0x000d7f3c ldrd r1, r3, [r7, 0x80] | __asm ("ldrd r1, r3, [var_80h]");
0x000d7f40 cmp r1, 0x78 |
0x000d7f42 sbcs r2, r3, 0 | __asm ("sbcs r2, r3, 0");
0x000d7f46 it ge |
| if (r1 < 0x78) {
0x000d7f48 strdge r1, r3, [r7, 0x10] | __asm ("strdge r1, r3, [var_10h]");
| goto label_18;
| }
| if (r1 >= 0x78) {
| label_18:
0x000d7f4c bge 0xd7eaa | goto label_5;
| }
0x000d7f4e b 0xd7e64 | goto label_3;
| label_16:
0x000d7f50 add.w r1, r7, 0x58 | r1 += var_58h;
0x000d7f54 movs r0, 5 | r0 = 5;
0x000d7f56 ldrd sl, fp, [r8, 0x10] | __asm ("ldrd sl, fp, [r8, 0x10]");
0x000d7f5a bl 0x8199c | clock_gettime ();
0x000d7f5e ldr r2, [r7, 0x58] | r2 = var_58h;
0x000d7f60 adds.w r0, sl, 0x12c | r0 = sl + 0x12c;
0x000d7f64 adc r3, fp, 0 | __asm ("adc r3, arg_0h");
0x000d7f68 cmp r0, r2 |
0x000d7f6a asr.w r1, r2, 0x1f | r1 = r2 >> 0x1f;
0x000d7f6c strb r2, [r4, 7] | *((r4 + 7)) = r2;
0x000d7f6e sbcs r3, r1 | __asm ("sbcs r3, r1");
| if (r0 <= r2) {
0x000d7f70 blo 0xd7f24 | goto label_6;
| }
0x000d7f72 ldr.w r3, [r8, 0x28] | r3 = *((r8 + 0x28));
0x000d7f76 b 0xd7ed8 | goto label_7;
| label_15:
0x000d7f78 ldr r3, [pc, 0x1c] |
0x000d7f7a movs r2, 0xf9 | r2 = 0xf9;
0x000d7f7c ldr r1, [pc, 0x1c] |
0x000d7f7e ldr r0, [pc, 0x20] |
0x000d7f80 add r3, pc | r3 = 0x1aff1c;
0x000d7f82 add r1, pc | r1 = 0x1aff22;
0x000d7f84 add r0, pc | r0 = 0x1aff2a;
0x000d7f86 bl 0x2b2bc | assert_fail ();
0x000d7f8a nop |
0x000d7f8c str r4, [r5, 0x14] | *((r5 + 0x14)) = r4;
0x000d7f8e movs r3, r0 | r3 = r0;
0x000d7f90 str r2, [r5, 0xc] | *((r5 + 0xc)) = r2;
0x000d7f92 movs r3, r0 | r3 = r0;
0x000d7f94 str r0, [r6, 8] | *((r6 + 8)) = r0;
0x000d7f96 movs r3, r0 | r3 = r0;
0x000d7f98 asrs r0, r0, 0x1e | r0 >>= 0x1e;
0x000d7f9a movs r2, r0 | r2 = r0;
0x000d7f9c asrs r6, r2, 0x1d | r6 = r2 >> 0x1d;
0x000d7f9e movs r2, r0 | r2 = r0;
0x000d7fa0 asrs r4, r4, 0x1d | r4 >>= 0x1d;
0x000d7fa2 movs r2, r0 | r2 = r0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x2ecd0 */
| #include <stdint.h>
|
| #define SWAP32(n) ((uint32_t) (((n & 0x000000ff) << 24) | \
| ((n & 0x0000ff00) << 8) | \
| ((n & 0x00ff0000) >> 8) | \
| ((n & 0xff000000) >> 24)))
|
; (fcn) sym.__open_catalog () | void open_catalog (int16_t arg1, int16_t arg2, int16_t arg3, int16_t arg4) {
| int32_t var_0h;
| int32_t var_0h_2;
| int16_t var_8h;
| int16_t var_ch;
| int16_t var_10h;
| int16_t var_20h;
| int16_t var_40h;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
| r3 = arg4;
0x0002ecd0 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0002ecd4 mov r6, r1 | r6 = r1;
0x0002ecd6 sub sp, 0x7c |
0x0002ecd8 movs r1, 0x2f | r1 = 0x2f;
0x0002ecda mov sb, r0 | sb = r0;
0x0002ecdc mov r8, r2 | r8 = r2;
0x0002ecde str r3, [sp, 0xc] | var_ch = r3;
0x0002ece0 bl 0x6a0a0 | strchr ();
0x0002ece4 clz r3, r6 | r3 &= r6;
0x0002ece8 lsrs r3, r3, 5 | r3 >>= 5;
0x0002ecea cmp r0, 0 |
0x0002ecec it ne |
| if (r0 == 0) {
0x0002ecee orrne r3, r3, 1 | r3 |= 1;
| }
0x0002ecf2 cmp r3, 0 |
| if (r3 == 0) {
0x0002ecf4 beq.w 0x2ee00 | goto label_22;
| }
0x0002ecf8 movs r1, 0 | r1 = 0;
0x0002ecfa mov r0, sb | r0 = sb;
0x0002ecfc bl 0xa65f4 | r0 = open_nocancel ();
0x0002ed00 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 < r0) {
0x0002ed02 blt.w 0x2f102 | goto label_23;
| }
0x0002ed06 movs r7, 0 | r7 = 0;
| label_10:
0x0002ed08 add r1, sp, 0x10 | r1 += var_10h;
0x0002ed0a mov r0, r4 | r0 = r4;
0x0002ed0c bl 0x9eab8 | r0 = fstat64 ();
0x0002ed10 cmp r0, 0 |
| if (r0 >= 0) {
0x0002ed12 blt 0x2ed34 |
0x0002ed14 ldr r3, [sp, 0x20] | r3 = var_20h;
0x0002ed16 and r3, r3, 0xf000 | r3 &= 0xf000;
0x0002ed1a cmp.w r3, 0x8000 |
| if (r3 == 0x8000) {
0x0002ed1e bne 0x2ed26 |
0x0002ed20 ldr r1, [sp, 0x40] | r1 = var_40h;
0x0002ed22 cmp r1, 0xb |
| if (r1 > 0xb) {
0x0002ed24 bhi 0x2ed4c | goto label_24;
| }
| }
0x0002ed26 ldr r3, [pc, 0x2a0] |
0x0002ed28 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x0002ed2c movs r1, 0x16 | r1 = 0x16;
0x0002ed2e add r3, pc |
0x0002ed30 ldr r3, [r3] | r3 = *(0x5dcfc);
0x0002ed32 str r1, [r2, r3] | *((r2 + r3)) = r1;
| }
| label_17:
0x0002ed34 mov.w r5, -1 | r5 = -1;
| label_0:
0x0002ed38 mov r0, r4 | r0 = r4;
0x0002ed3a bl 0xa64c4 | close_nocancel ();
0x0002ed3e mov r0, r7 | r0 = r7;
0x0002ed40 blx 0x212d4 | fcn_000212d4 ();
0x0002ed44 mov r0, r5 | r0 = r5;
0x0002ed46 add sp, 0x7c |
0x0002ed48 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_24:
0x0002ed4c ldr r5, [sp, 0xc] | r5 = var_ch;
0x0002ed4e movs r6, 0 | r6 = 0;
0x0002ed50 movs r3, 2 | r3 = 2;
0x0002ed52 movs r2, 1 | r2 = 1;
0x0002ed54 mov r0, r6 | r0 = r6;
0x0002ed56 str r1, [r5, 0x18] | *((r5 + 0x18)) = r1;
0x0002ed58 strd r4, r6, [sp] | __asm ("strd r4, r6, [sp]");
0x0002ed5c bl 0xa9f88 | r0 = mmap ()
0x0002ed60 adds r3, r0, 1 | r3 = r0 + 1;
0x0002ed62 str r0, [r5, 0x14] | *((r5 + 0x14)) = r0;
| if (r3 == r0) {
0x0002ed64 beq.w 0x2f106 | goto label_25;
| }
| label_20:
0x0002ed68 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0002ed6a ldr r2, [r0] | r2 = *(r0);
0x0002ed6c str r6, [r3] | *(r3) = r6;
0x0002ed6e movw r3, 0x8de |
0x0002ed72 movt r3, 0x9604 | r3 = 0x960408de;
0x0002ed76 cmp r2, r3 |
| if (r2 != r3) {
0x0002ed78 bne.w 0x2f164 | goto label_26;
| }
0x0002ed7c ldr r2, [sp, 0xc] | r2 = var_ch;
0x0002ed7e ldr r3, [r0, 4] | r3 = *((r0 + 4));
0x0002ed80 str r3, [r2, 4] | *((r2 + 4)) = r3;
0x0002ed82 ldr r2, [r0, 8] | r2 = *((r0 + 8));
| label_19:
0x0002ed84 mul ip, r2, r3 |
0x0002ed88 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0002ed8a add.w r5, r0, 0xc | r5 = r0 + 0xc;
0x0002ed8e str r2, [r3, 8] | *((r3 + 8)) = r2;
0x0002ed90 movs r2, 0 | r2 = 0;
0x0002ed92 add.w ip, ip, ip, lsl 1 |
0x0002ed96 str r5, [r3, 0xc] | *((r3 + 0xc)) = r5;
0x0002ed98 lsl.w r8, ip, 1 | r8 = ip << 1;
0x0002ed9c cmp.w ip, 2 |
0x0002eda0 add.w r1, r8, 3 | r1 = r8 + 3;
0x0002eda4 add.w r1, r0, r1, lsl 2 | r1 = r0 + (r1 << 2);
0x0002eda8 str r1, [r3, 0x10] | *((r3 + 0x10)) = r1;
| if (ip < 2) {
0x0002edaa bls 0x2edc2 | goto label_27;
| }
0x0002edac movs r3, 2 | r3 = 2;
0x0002edae mov lr, r1 | lr = r1;
| do {
0x0002edb0 ldr.w r1, [r5, r3, lsl 2] | offset_0 = r3 << 2;
| r1 = *((r5 + offset_0));
0x0002edb4 adds r3, 3 | r3 += 3;
0x0002edb6 cmp r2, r1 |
0x0002edb8 it lo |
| if (r2 >= r1) {
0x0002edba movlo r2, r1 | r2 = r1;
| }
0x0002edbc cmp ip, r3 |
0x0002edbe bhi 0x2edb0 |
| } while (ip > r3);
0x0002edc0 mov r1, lr | r1 = lr;
| label_27:
0x0002edc2 ldr r3, [sp, 0x40] | r3 = var_40h;
0x0002edc4 add.w r5, r8, 0xc | r5 = r8 + 0xc;
0x0002edc8 add r5, r2 | r5 += r2;
0x0002edca cmp r3, r5 |
| if (r3 < r5) {
0x0002edcc bls 0x2edec | goto label_18;
| }
0x0002edce ldrb r5, [r1, r2] | r5 = *((r1 + r2));
0x0002edd0 subs r3, 0xd | r3 -= 0xd;
0x0002edd2 add r3, r8 | r3 += r8;
0x0002edd4 add r1, r2 | r1 += r2;
0x0002edd6 cmp r5, 0 |
| if (r5 == 0) {
0x0002edd8 beq 0x2ed38 | goto label_0;
| }
0x0002edda adds r3, r2, r3 | r3 = r2 + r3;
| if (r3 == r2) {
0x0002eddc beq 0x2edec | goto label_18;
| }
0x0002edde add r3, r1 | r3 += r1;
| label_1:
0x0002ede0 ldrb r5, [r1, 1]! | r5 = *((r1 += 1));
0x0002ede4 cmp r5, 0 |
| if (r5 == 0) {
0x0002ede6 beq 0x2ed38 | goto label_0;
| }
0x0002ede8 cmp r3, r1 |
| if (r3 != r1) {
0x0002edea bne 0x2ede0 | goto label_1;
| }
| label_18:
0x0002edec cmp r6, 0 |
| if (r6 != 0) {
0x0002edee bne.w 0x2f0f8 | goto label_28;
| }
0x0002edf2 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0002edf4 mov.w r5, -1 | r5 = -1;
0x0002edf8 ldr r1, [r3, 0x18] | r1 = *((r3 + 0x18));
0x0002edfa bl 0xaa040 | munmap ();
0x0002edfe b 0x2ed38 | goto label_0;
| label_22:
0x0002ee00 ldrb r2, [r6] | r2 = *(r6);
0x0002ee02 mov fp, r3 |
0x0002ee04 movw sl, 0x101 | sl = 0x101;
0x0002ee08 mov r7, r3 | r7 = r3;
0x0002ee0a cmp r2, 0 |
| if (r2 == 0) {
0x0002ee0c beq.w 0x2f102 | goto label_23;
| }
| do {
0x0002ee10 cmp r2, 0x3a |
| if (r2 != 0x3a) {
0x0002ee12 bne 0x2ee5a | goto label_29;
| }
0x0002ee14 mov r0, sb | r0 = sb;
0x0002ee16 bl 0x6a8c0 | r0 = strlen ();
0x0002ee1a cmp fp, r0 |
0x0002ee1c mov r4, r0 | r4 = r0;
| if (fp < r0) {
0x0002ee1e bls.w 0x2f078 | goto label_30;
| }
| label_13:
0x0002ee22 mov r2, r4 | r2 = r4;
0x0002ee24 mov r1, sb | r1 = sb;
0x0002ee26 mov r0, r7 | r0 = r7;
0x0002ee28 mov r5, r6 | r5 = r6;
0x0002ee2a blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002ee2e adds r2, r4, 1 | r2 = r4 + 1;
| label_21:
0x0002ee30 cmp fp, r2 |
| if (fp < r2) {
0x0002ee32 bls.w 0x2efec | goto label_31;
| }
| label_8:
0x0002ee36 movs r1, 0 | r1 = 0;
0x0002ee38 strb r1, [r7, r4] | *((r7 + r4)) = r1;
0x0002ee3a cmp r4, 0 |
| if (r4 != 0) {
0x0002ee3c bne.w 0x2f00e | goto label_32;
| }
| label_9:
0x0002ee40 ldrb r2, [r5, 1] | r2 = *((r5 + 1));
0x0002ee42 adds r6, r5, 1 | r6 = r5 + 1;
0x0002ee44 cmp r2, 0 |
0x0002ee46 bne 0x2ee10 |
| } while (r2 != 0);
| label_4:
0x0002ee48 mov r0, r7 | r0 = r7;
0x0002ee4a mov.w r5, -1 | r5 = -1;
0x0002ee4e blx 0x212d4 | fcn_000212d4 ();
0x0002ee52 mov r0, r5 | r0 = r5;
0x0002ee54 add sp, 0x7c |
0x0002ee56 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| label_29:
0x0002ee5a ldrb r5, [r6] | r5 = *(r6);
0x0002ee5c cmp r5, 0x3a |
0x0002ee5e it ne |
| if (r5 != 0x3a) {
0x0002ee60 cmpne r5, 0 | __asm ("cmpne r5, 0");
| }
0x0002ee62 itet ne |
| if (r5 == 0x3a) {
0x0002ee64 movne r4, 1 | r4 = 1;
| }
| if (r5 != 0x3a) {
0x0002ee66 moveq r4, 0 | r4 = 0;
| }
| if (r5 == 0x3a) {
0x0002ee68 movne r4, 0 | r4 = 0;
| }
| if (r5 != 0x3a) {
0x0002ee6a bne 0x2ee86 | goto label_33;
| }
0x0002ee6c b 0x2f180 | goto label_34;
| do {
0x0002ee6e adds r3, r4, 1 | r3 = r4 + 1;
0x0002ee70 cmp fp, r3 |
| if (fp < r3) {
0x0002ee72 bls 0x2ef48 | goto label_35;
| }
| label_5:
0x0002ee74 strb r5, [r7, r4] | *((r7 + r4)) = r5;
0x0002ee76 adds r6, 1 | r6++;
0x0002ee78 mov r4, r3 | r4 = r3;
| label_2:
0x0002ee7a ldrb r5, [r6] | r5 = *(r6);
0x0002ee7c cmp r5, 0x3a |
0x0002ee7e it ne |
| if (r5 != 0x3a) {
0x0002ee80 cmpne r5, 0 | __asm ("cmpne r5, 0");
| }
| if (r5 == 0x3a) {
0x0002ee82 beq.w 0x2f1b2 | goto label_36;
| }
| label_33:
0x0002ee86 cmp r5, 0x25 |
0x0002ee88 bne 0x2ee6e |
| } while (r5 != 0x25);
0x0002ee8a ldrb r3, [r6, 1] | r3 = *((r6 + 1));
0x0002ee8c adds r5, r6, 2 | r5 = r6 + 2;
0x0002ee8e cmp r3, 0x63 |
| if (r3 == 0x63) {
0x0002ee90 beq 0x2ef66 | goto label_37;
| }
| if (r3 <= 0x63) {
0x0002ee92 bhi 0x2eebc |
0x0002ee94 cmp r3, 0x4c |
| if (r3 == 0x4c) {
0x0002ee96 beq.w 0x2f01e | goto label_38;
| }
0x0002ee9a cmp r3, 0x4e |
| if (r3 != 0x4e) {
0x0002ee9c bne 0x2eee6 | goto label_39;
| }
0x0002ee9e mov r0, sb | r0 = sb;
0x0002eea0 bl 0x6a8c0 | r0 = strlen ();
0x0002eea4 adds r6, r4, r0 | r6 = r4 + r0;
0x0002eea6 mov r2, r0 | r2 = r0;
0x0002eea8 cmp r6, fp |
| if (r6 >= fp) {
0x0002eeaa bhs.w 0x2f0b4 | goto label_40;
| }
| label_15:
0x0002eeae adds r0, r7, r4 | r0 = r7 + r4;
0x0002eeb0 mov r1, sb | r1 = sb;
0x0002eeb2 mov r4, r6 | r4 = r6;
0x0002eeb4 mov r6, r5 | r6 = r5;
0x0002eeb6 blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002eeba b 0x2ee7a | goto label_2;
| }
0x0002eebc cmp r3, 0x6c |
| if (r3 == 0x6c) {
0x0002eebe beq 0x2eefe | goto label_41;
| }
0x0002eec0 cmp r3, 0x74 |
| if (r3 != 0x74) {
0x0002eec2 bne.w 0x2efcc | goto label_42;
| }
0x0002eec6 mov r2, r8 | r2 = r8;
0x0002eec8 b 0x2eece |
| while (r3 != 0) {
0x0002eeca cmp r3, 0x2e |
| if (r3 == 0x2e) {
0x0002eecc beq 0x2eee2 | goto label_6;
| }
0x0002eece mov r1, r2 | r1 = r2;
0x0002eed0 ldrb r3, [r2, 1]! | r3 = *((r2 += 1));
0x0002eed4 cmp r3, 0 |
0x0002eed6 it ne |
| if (r3 != 0) {
0x0002eed8 cmpne r3, 0x5f | __asm ("cmpne r3, 0x5f");
| }
0x0002eeda bne 0x2eeca |
| }
0x0002eedc cmp r3, 0x5f |
| if (r3 == 0x5f) {
0x0002eede beq.w 0x2f03a | goto label_43;
| }
| do {
| label_6:
0x0002eee2 mov r6, r5 | r6 = r5;
0x0002eee4 b 0x2ee7a | goto label_2;
| label_39:
0x0002eee6 cmp r3, 0x25 |
| if (r3 != 0x25) {
0x0002eee8 bne 0x2efcc | goto label_42;
| }
0x0002eeea adds r3, r4, 1 | r3 = r4 + 1;
0x0002eeec cmp r3, fp |
| if (r3 >= fp) {
0x0002eeee bhs.w 0x2f096 | goto label_44;
| }
| label_14:
0x0002eef2 mov.w r2, 0x25 | r2 = 0x25;
0x0002eef6 mov r6, r5 | r6 = r5;
0x0002eef8 strb r2, [r7, r4] | *((r7 + r4)) = r2;
0x0002eefa mov r4, r3 | r4 = r3;
0x0002eefc b 0x2ee7a | goto label_2;
| label_41:
0x0002eefe mov r6, r8 | r6 = r8;
0x0002ef00 b 0x2ef24 | goto label_45;
| label_3:
0x0002ef02 ldrb r1, [r6], 1 | r1 = *(r6);
| r6++;
0x0002ef06 ldrb r2, [r6] | r2 = *(r6);
0x0002ef08 strb r1, [r7, r3] | *((r7 + r3)) = r1;
0x0002ef0a cmp r2, 0 |
0x0002ef0c it ne |
| if (r2 != 0) {
0x0002ef0e cmpne r2, 0x5f | __asm ("cmpne r2, 0x5f");
| }
0x0002ef10 ite ne |
| if (r2 == 0) {
0x0002ef12 movne r3, 1 | r3 = 1;
| }
| if (r2 != 0) {
0x0002ef14 moveq r3, 0 | r3 = 0;
| }
0x0002ef16 cmp r2, 0x2e |
0x0002ef18 ite eq |
| if (r2 != 0x2e) {
0x0002ef1a moveq r3, 0 | r3 = 0;
| }
| if (r2 == 0x2e) {
0x0002ef1c andne r3, r3, 1 | r3 &= 1;
| }
0x0002ef20 cmp r3, 0 |
0x0002ef22 beq 0x2eee2 |
| } while (r3 == 0);
| label_45:
0x0002ef24 mov r3, r4 | r3 = r4;
0x0002ef26 adds r4, 1 | r4++;
0x0002ef28 cmp r4, fp |
| if (r4 <= fp) {
0x0002ef2a blo 0x2ef02 | goto label_3;
| }
0x0002ef2c cmp fp, sl |
0x0002ef2e ite hs |
| if (fp < sl) {
0x0002ef30 addhs fp, fp |
| }
| if (fp >= sl) {
0x0002ef32 addlo fp, sl |
| }
0x0002ef34 mov r0, r7 | r0 = r7;
0x0002ef36 mov r1, fp | r1 = fp;
0x0002ef38 str r3, [sp, 8] | var_8h = r3;
0x0002ef3a blx 0x212ac | fcn_000212ac ();
0x0002ef3e ldr r3, [sp, 8] | r3 = var_8h;
0x0002ef40 cmp r0, 0 |
| if (r0 == 0) {
0x0002ef42 beq 0x2ee48 | goto label_4;
| }
0x0002ef44 mov r7, r0 | r7 = r0;
0x0002ef46 b 0x2ef02 | goto label_3;
| label_35:
0x0002ef48 cmp fp, sl |
0x0002ef4a ite hs |
| if (fp < sl) {
0x0002ef4c addhs fp, fp |
| }
| if (fp >= sl) {
0x0002ef4e addlo fp, sl |
| }
0x0002ef50 mov r0, r7 | r0 = r7;
0x0002ef52 mov r1, fp | r1 = fp;
0x0002ef54 str r3, [sp, 8] | var_8h = r3;
0x0002ef56 blx 0x212ac | fcn_000212ac ();
0x0002ef5a ldr r3, [sp, 8] | r3 = var_8h;
0x0002ef5c cmp r0, 0 |
| if (r0 == 0) {
0x0002ef5e beq.w 0x2ee48 | goto label_4;
| }
0x0002ef62 mov r7, r0 | r7 = r0;
0x0002ef64 b 0x2ee74 | goto label_5;
| label_37:
0x0002ef66 mov r2, r8 | r2 = r8;
| do {
0x0002ef68 mov r1, r2 | r1 = r2;
0x0002ef6a ldrb r3, [r2, 1]! | r3 = *((r2 += 1));
0x0002ef6e cmp r3, 0 |
0x0002ef70 it ne |
| if (r3 != 0) {
0x0002ef72 cmpne r3, 0x2e | __asm ("cmpne r3, 0x2e");
| }
0x0002ef74 bne 0x2ef68 |
| } while (r3 != 0);
0x0002ef76 cmp r3, 0x2e |
| if (r3 != 0x2e) {
0x0002ef78 bne 0x2eee2 | goto label_6;
| }
0x0002ef7a mov r3, r8 | r3 = r8;
0x0002ef7c adds r6, r1, 2 | r6 = r1 + 2;
0x0002ef7e mov r8, fp | r8 = fp;
0x0002ef80 str r5, [sp, 8] | var_8h = r5;
0x0002ef82 mov fp, r3 |
0x0002ef84 b 0x2ef90 |
| while (r4 <= r8) {
0x0002ef86 ldrb r2, [r6], 1 | r2 = *(r6);
| r6++;
0x0002ef8a ldrb r3, [r6] | r3 = *(r6);
0x0002ef8c strb r2, [r7, r5] | *((r7 + r5)) = r2;
| if (r3 == 0) {
0x0002ef8e cbz r3, 0x2efbc | goto label_11;
| }
| label_7:
0x0002ef90 mov r5, r4 | r5 = r4;
0x0002ef92 adds r4, 1 | r4++;
0x0002ef94 cmp r4, r8 |
0x0002ef96 blo 0x2ef86 |
| }
0x0002ef98 cmp r8, sl |
0x0002ef9a ite hs |
| if (r8 < sl) {
0x0002ef9c addhs r8, r8 | r8 += r8;
| }
| if (r8 >= sl) {
0x0002ef9e addlo r8, sl | r8 += sl;
| }
0x0002efa0 mov r0, r7 | r0 = r7;
0x0002efa2 mov r1, r8 | r1 = r8;
0x0002efa4 blx 0x212ac | r0 = fcn_000212ac ();
0x0002efa8 cmp r0, 0 |
| if (r0 == 0) {
0x0002efaa beq.w 0x2ee48 | goto label_4;
| }
0x0002efae ldrb r2, [r6], 1 | r2 = *(r6);
| r6++;
0x0002efb2 mov r7, r0 | r7 = r0;
0x0002efb4 ldrb r3, [r6] | r3 = *(r6);
0x0002efb6 strb r2, [r7, r5] | *((r7 + r5)) = r2;
0x0002efb8 cmp r3, 0 |
| if (r3 != 0) {
0x0002efba bne 0x2ef90 | goto label_7;
| }
| label_11:
0x0002efbc ldr r5, [sp, 8] | r5 = var_8h;
0x0002efbe mov r3, fp | r3 = fp;
0x0002efc0 mov fp, r8 |
0x0002efc2 mov r8, r3 | r8 = r3;
0x0002efc4 mov r6, r5 | r6 = r5;
0x0002efc6 b 0x2ee7a | goto label_2;
| label_42:
0x0002efcc ldrb r2, [r6, 2] | r2 = *((r6 + 2));
0x0002efce cmp r2, 0 |
0x0002efd0 it ne |
| if (r2 != 0) {
0x0002efd2 cmpne r2, 0x3a | __asm ("cmpne r2, 0x3a");
| }
| if (r2 == 0) {
0x0002efd4 beq 0x2efe2 | goto label_46;
| }
| do {
0x0002efd6 ldrb r3, [r5, 1]! | r3 = *((r5 += 1));
0x0002efda cmp r3, 0 |
0x0002efdc it ne |
| if (r3 != 0) {
0x0002efde cmpne r3, 0x3a | __asm ("cmpne r3, 0x3a");
| }
0x0002efe0 bne 0x2efd6 |
| } while (r3 != 0);
| label_46:
0x0002efe2 movs r2, 1 | r2 = 1;
0x0002efe4 movs r4, 0 | r4 = 0;
0x0002efe6 cmp fp, r2 |
| if (fp > r2) {
0x0002efe8 bhi.w 0x2ee36 | goto label_8;
| }
| label_31:
0x0002efec cmp fp, sl |
0x0002efee ite hs |
| if (fp < sl) {
0x0002eff0 addhs fp, fp |
| }
| if (fp >= sl) {
0x0002eff2 addlo fp, sl |
| }
0x0002eff4 mov r0, r7 | r0 = r7;
0x0002eff6 mov r1, fp | r1 = fp;
0x0002eff8 blx 0x212ac | r0 = fcn_000212ac ();
0x0002effc cmp r0, 0 |
| if (r0 == 0) {
0x0002effe beq.w 0x2ee48 | goto label_4;
| }
0x0002f000 add r7, sp, 0x8c | r7 = sp + 0x8c;
0x0002f002 mov r7, r0 | r7 = r0;
0x0002f004 movs r1, 0 | r1 = 0;
0x0002f006 strb r1, [r7, r4] | *((r7 + r4)) = r1;
0x0002f008 cmp r4, 0 |
| if (r4 == 0) {
0x0002f00a beq.w 0x2ee40 | goto label_9;
| }
| label_32:
0x0002f00e mov r0, r7 | r0 = r7;
0x0002f010 bl 0xa65f4 | r0 = open_nocancel ();
0x0002f014 cmp r0, 0 |
| if (r0 < 0) {
0x0002f016 blt.w 0x2ee40 | goto label_9;
| }
0x0002f01a mov r4, r0 | r4 = r0;
0x0002f01c b 0x2ed08 | goto label_10;
| label_38:
0x0002f01e mov r0, r8 | r0 = r8;
0x0002f020 bl 0x6a8c0 | r0 = strlen ();
0x0002f024 adds r6, r4, r0 | r6 = r4 + r0;
0x0002f026 mov r2, r0 | r2 = r0;
0x0002f028 cmp r6, fp |
| if (r6 >= fp) {
0x0002f02a bhs 0x2f0d6 | goto label_47;
| }
| label_16:
0x0002f02c adds r0, r7, r4 | r0 = r7 + r4;
0x0002f02e mov r1, r8 | r1 = r8;
0x0002f030 mov r4, r6 | r4 = r6;
0x0002f032 mov r6, r5 | r6 = r5;
0x0002f034 blx 0x6fa80 | memcpy (r0, r1, r2);
0x0002f038 b 0x2ee7a | goto label_2;
| label_43:
0x0002f03a mov r3, r8 | r3 = r8;
0x0002f03c adds r6, r1, 2 | r6 = r1 + 2;
0x0002f03e mov r8, fp | r8 = fp;
0x0002f040 str r5, [sp, 8] | var_8h = r5;
0x0002f042 mov fp, r3 |
0x0002f044 b 0x2f056 | goto label_48;
| label_12:
0x0002f046 ldrb r2, [r6], 1 | r2 = *(r6);
| r6++;
0x0002f04a ldrb r3, [r6] | r3 = *(r6);
0x0002f04c strb r2, [r7, r5] | *((r7 + r5)) = r2;
0x0002f04e cmp r3, 0 |
0x0002f050 it ne |
| if (r3 == 0) {
0x0002f052 cmpne r3, 0x2e | __asm ("cmpne r3, 0x2e");
| goto label_49;
| }
| if (r3 == 0) {
| label_49:
0x0002f054 beq 0x2efbc | goto label_11;
| }
| label_48:
0x0002f056 mov r5, r4 | r5 = r4;
0x0002f058 adds r4, 1 | r4++;
0x0002f05a cmp r4, r8 |
| if (r4 <= r8) {
0x0002f05c blo 0x2f046 | goto label_12;
| }
0x0002f05e cmp r8, sl |
0x0002f060 ite hs |
| if (r8 < sl) {
0x0002f062 addhs r8, r8 | r8 += r8;
| }
| if (r8 >= sl) {
0x0002f064 addlo r8, sl | r8 += sl;
| }
0x0002f066 mov r0, r7 | r0 = r7;
0x0002f068 mov r1, r8 | r1 = r8;
0x0002f06a blx 0x212ac | r0 = fcn_000212ac ();
0x0002f06e cmp r0, 0 |
| if (r0 == 0) {
0x0002f070 beq.w 0x2ee48 | goto label_4;
| }
0x0002f074 mov r7, r0 | r7 = r0;
0x0002f076 b 0x2f046 | goto label_12;
| label_30:
0x0002f078 add.w r2, r0, 0x100 | r2 = r0 + 0x100;
0x0002f07c mov r0, r7 | r0 = r7;
0x0002f07e cmp r2, fp |
0x0002f080 ite hs |
| if (r2 < fp) {
0x0002f082 addhs fp, r2 |
| }
| if (r2 >= fp) {
0x0002f084 addlo fp, fp |
| }
0x0002f086 mov r1, fp | r1 = fp;
0x0002f088 blx 0x212ac | r0 = fcn_000212ac ();
0x0002f08c cmp r0, 0 |
| if (r0 == 0) {
0x0002f08e beq.w 0x2ee48 | goto label_4;
| }
0x0002f092 mov r7, r0 | r7 = r0;
0x0002f094 b 0x2ee22 | goto label_13;
| label_44:
0x0002f096 cmp fp, sl |
0x0002f098 ite hs |
| if (fp < sl) {
0x0002f09a addhs fp, fp |
| }
| if (fp >= sl) {
0x0002f09c addlo fp, sl |
| }
0x0002f09e mov r0, r7 | r0 = r7;
0x0002f0a0 mov r1, fp | r1 = fp;
0x0002f0a2 str r3, [sp, 8] | var_8h = r3;
0x0002f0a4 blx 0x212ac | fcn_000212ac ();
0x0002f0a8 ldr r3, [sp, 8] | r3 = var_8h;
0x0002f0aa cmp r0, 0 |
| if (r0 == 0) {
0x0002f0ac beq.w 0x2ee48 | goto label_4;
| }
0x0002f0b0 mov r7, r0 | r7 = r0;
0x0002f0b2 b 0x2eef2 | goto label_14;
| label_40:
0x0002f0b4 add.w r3, r0, 0x100 | r3 = r0 + 0x100;
0x0002f0b8 str r0, [sp, 8] | var_8h = r0;
0x0002f0ba cmp r3, fp |
0x0002f0bc ite hs |
| if (r3 < fp) {
0x0002f0be addhs fp, r3 |
| }
| if (r3 >= fp) {
0x0002f0c0 addlo fp, fp |
| }
0x0002f0c2 mov r0, r7 | r0 = r7;
0x0002f0c4 mov r1, fp | r1 = fp;
0x0002f0c6 blx 0x212ac | fcn_000212ac ();
0x0002f0ca ldr r2, [sp, 8] | r2 = var_8h;
0x0002f0cc cmp r0, 0 |
| if (r0 == 0) {
0x0002f0ce beq.w 0x2ee48 | goto label_4;
| }
0x0002f0d2 mov r7, r0 | r7 = r0;
0x0002f0d4 b 0x2eeae | goto label_15;
| label_47:
0x0002f0d6 add.w r3, r0, 0x100 | r3 = r0 + 0x100;
0x0002f0da str r0, [sp, 8] | var_8h = r0;
0x0002f0dc cmp r3, fp |
0x0002f0de ite hs |
| if (r3 < fp) {
0x0002f0e0 addhs fp, r3 |
| }
| if (r3 >= fp) {
0x0002f0e2 addlo fp, fp |
| }
0x0002f0e4 mov r0, r7 | r0 = r7;
0x0002f0e6 mov r1, fp | r1 = fp;
0x0002f0e8 blx 0x212ac | fcn_000212ac ();
0x0002f0ec ldr r2, [sp, 8] | r2 = var_8h;
0x0002f0ee cmp r0, 0 |
| if (r0 == 0) {
0x0002f0f0 beq.w 0x2ee48 | goto label_4;
| }
0x0002f0f4 mov r7, r0 | r7 = r0;
0x0002f0f6 b 0x2f02c | goto label_16;
| label_28:
0x0002f0f8 mov.w r5, -1 | r5 = -1;
0x0002f0fc blx 0x212d4 | fcn_000212d4 ();
0x0002f100 b 0x2ed38 | goto label_0;
| label_23:
0x0002f102 movs r7, 0 | r7 = 0;
0x0002f104 b 0x2ee48 | goto label_4;
| label_25:
0x0002f106 ldr r5, [sp, 0x40] | r5 = var_40h;
0x0002f108 mov r0, r5 | r0 = r5;
0x0002f10a blx 0x21354 | fcn_00021354 ();
0x0002f10c invalid |
0x0002f10e ldr r3, [sp, 0xc] | r3 = var_ch;
0x0002f110 str r0, [r3, 0x14] | *((r3 + 0x14)) = r0;
0x0002f112 cmp r0, 0 |
| if (r0 == 0) {
0x0002f114 beq.w 0x2ed34 | goto label_17;
| }
0x0002f118 mov sb, r4 | sb = r4;
0x0002f11a mov r8, r3 | r8 = r3;
0x0002f11c mrc p15, 0, r6, c13, c0, 3 | __asm ("mrc p15, 0, r6, c13, c0, 3");
0x0002f120 mov r1, r0 | r1 = r0;
0x0002f122 mov r4, r5 | r4 = r5;
0x0002f124 mov r3, r5 | r3 = r5;
| do {
0x0002f126 subs r3, r3, r4 | r3 -= r4;
0x0002f128 mov r2, r4 | r2 = r4;
0x0002f12a add r1, r3 | r1 += r3;
0x0002f12c mov r0, sb | r0 = sb;
0x0002f12e bl 0xa6780 | r0 = read_nocancel ();
0x0002f132 subs r2, r0, 1 | r2 = r0 - 1;
0x0002f134 ldr r3, [pc, 0x80] | r3 = *(0x2f1b8);
0x0002f136 adds r2, 3 | r2 += 3;
| if (r2 >= 3) {
0x0002f138 bls 0x2f158 |
0x0002f13a adds r0, 1 | r0++;
| if (r0 == 1) {
0x0002f13c bne 0x2f148 |
0x0002f13e add r3, pc | r3 += pc;
0x0002f140 ldr r3, [r3] | r3 = *(r3);
0x0002f142 ldr r3, [r6, r3] | r3 = *((r6 + r3));
0x0002f144 cmp r3, 4 |
| if (r3 == 4) {
0x0002f146 beq 0x2f15a | goto label_50;
| }
| }
0x0002f148 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0002f14a mov r4, sb | r4 = sb;
0x0002f14c mov.w r5, -1 | r5 = -1;
0x0002f150 ldr r0, [r3, 0x14] | r0 = *((r3 + 0x14));
0x0002f152 blx 0x212d4 | fcn_000212d4 ();
0x0002f156 b 0x2ed38 | goto label_0;
| }
0x0002f158 subs r4, r4, r0 | r4 -= r0;
| label_50:
0x0002f15a ldr.w r1, [r8, 0x14] | r1 = *((r8 + 0x14));
| if (r4 == 0) {
0x0002f15e cbz r4, 0x2f1aa | goto label_51;
| }
0x0002f160 ldr r3, [sp, 0x40] | r3 = var_40h;
0x0002f162 b 0x2f126 |
| } while (1);
| label_26:
0x0002f164 movw r3, 0x496 |
0x0002f168 movt r3, 0xde08 | r3 = 0xde080496;
0x0002f16c cmp r2, r3 |
| if (r2 != r3) {
0x0002f16e bne.w 0x2edec | goto label_18;
| }
0x0002f172 ldr r3, [r0, 4] | r3 = *((r0 + 4));
0x0002f174 ldr r2, [r0, 8] | r2 = *((r0 + 8));
0x0002f176 ldr r1, [sp, 0xc] | r1 = var_ch;
0x0002f178 rev r3, r3 | r3 = SWAP32 (r3);
0x0002f17a rev r2, r2 | r2 = SWAP32 (r2);
0x0002f17c str r3, [r1, 4] | *((r1 + 4)) = r3;
0x0002f17e b 0x2ed84 | goto label_19;
| label_34:
0x0002f180 cmp.w fp, 1 |
0x0002f184 itt hi |
| if (fp <= 1) {
0x0002f186 movhi r5, r6 | r5 = r6;
| }
| if (fp > 1) {
0x0002f188 strbhi r4, [r7] | *(r7) = r4;
| goto label_52;
| }
| if (fp > 1) {
| label_52:
0x0002f18a bhi.w 0x2ee40 | goto label_9;
| }
0x0002f18e addw fp, fp, 0x101 | __asm ("addw fp, fp, aav.0x000000ff");
0x0002f192 mov r0, r7 | r0 = r7;
0x0002f194 mov r1, fp | r1 = fp;
0x0002f196 blx 0x212ac | r0 = fcn_000212ac ();
0x0002f19a mov r2, r0 | r2 = r0;
0x0002f19c cmp r0, 0 |
| if (r0 == 0) {
0x0002f19e beq.w 0x2ee48 | goto label_4;
| }
0x0002f1a2 mov r5, r6 | r5 = r6;
0x0002f1a4 mov r7, r2 | r7 = r2;
0x0002f1a6 strb r4, [r2] | *(r2) = r4;
0x0002f1a8 b 0x2ee40 | goto label_9;
| label_51:
0x0002f1aa mov r0, r1 | r0 = r1;
0x0002f1ac mov r4, sb | r4 = sb;
0x0002f1ae movs r6, 1 | r6 = 1;
0x0002f1b0 b 0x2ed68 | goto label_20;
| label_36:
0x0002f1b2 mov r5, r6 | r5 = r6;
0x0002f1b4 adds r2, r4, 1 | r2 = r4 + 1;
0x0002f1b6 b 0x2ee30 | goto label_21;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0xab7d8 */
| #include <stdint.h>
|
; (fcn) sym.get_nprocs () | void get_nprocs () {
| int32_t var_0h;
| int16_t var_4h;
| int16_t var_8h;
| int32_t var_4h_2;
0x000ab7d8 push.w {r4, r5, r6, r7, r8, lr} |
0x000ab7dc sub sp, 0x88 |
0x000ab7de ldr r4, [pc, 0xe0] |
0x000ab7e0 add r2, sp, 8 | r2 += var_8h;
0x000ab7e2 movs r0, 0 | r0 = 0;
0x000ab7e4 movs r1, 0x80 | r1 = 0x80;
0x000ab7e6 mov.w ip, 0xf2 |
0x000ab7ea add r4, pc | r4 = 0x1570b0;
0x000ab7ec bl 0x21990 | r0 = fcn_00021990 ();
0x000ab7f0 cmp r0, 0 |
| if (r0 > 0) {
0x000ab7f2 bgt 0xab802 | goto label_4;
| }
0x000ab7f4 adds r0, 0x16 | r0 += 0x16;
| if (r0 == 0x16) {
0x000ab7f6 beq 0xab834 | goto label_5;
| }
| label_1:
0x000ab7f8 movs r4, 2 | r4 = 2;
| do {
| label_3:
0x000ab7fa mov r0, r4 | r0 = r4;
0x000ab7fc add sp, 0x88 |
0x000ab7fe pop.w {r4, r5, r6, r7, r8, pc} |
| label_4:
0x000ab802 lsrs r6, r0, 2 | r6 = r0 >> 2;
| if (r6 == r0) {
0x000ab804 beq 0xab8b8 | goto label_6;
| }
0x000ab806 ldr r0, [sp, 8] | r0 = var_8h;
0x000ab808 mov r5, r2 | r5 = r2;
0x000ab80a bl 0xdd2ec | fcn_000dd2ec (r0);
0x000ab80e add r3, sp, 4 | r3 += var_4h;
0x000ab810 mov r4, r0 | r4 = r0;
0x000ab812 add.w r6, r3, r6, lsl 2 | r6 = r3 + (r6 << 2);
| label_0:
0x000ab816 cmp r5, r6 |
0x000ab818 beq 0xab7fa |
| } while (r5 == r6);
0x000ab81a ldr r0, [r5, 4]! | r0 = var_4h_2;
0x000ab81e bl 0xdd2ec | r0 = fcn_000dd2ec (r0);
0x000ab822 adds r0, r4, r0 | r0 = r4 + r0;
0x000ab824 mov r4, r0 | r4 = r0;
0x000ab826 bvc 0xab816 | __asm ("bvc aav.0x000000ff");
| goto label_0;
0x000ab828 mvn r4, 0x80000000 | r4 = ~0x80000000;
0x000ab82c mov r0, r4 | r0 = r4;
0x000ab82e add sp, 0x88 |
0x000ab830 pop.w {r4, r5, r6, r7, r8, pc} |
| label_5:
0x000ab834 ldr r2, [pc, 0x8c] | r2 = *(0xab8c4);
0x000ab836 movs r5, 0 | r5 = 0;
0x000ab838 mov.w r0, -1 | r0 = -1;
0x000ab83c movs r3, 0x22 | r3 = 0x22;
0x000ab83e ldr r1, [r4, r2] | r1 = *((r4 + r2));
0x000ab840 movs r2, 3 | r2 = 3;
0x000ab842 strd r0, r5, [sp] | __asm ("strd r0, r5, [sp]");
0x000ab846 mov r0, r5 | r0 = r5;
0x000ab848 ldr.w r8, [r1, 0x10] | r8 = *((r1 + 0x10));
0x000ab84c mov r1, r8 | r1 = r8;
0x000ab84e bl 0xa9f88 | r0 = mmap ()
0x000ab852 adds r3, r0, 1 | r3 = r0 + 1;
0x000ab854 mov r6, r0 | r6 = r0;
| if (r3 == r0) {
0x000ab856 beq 0xab7f8 | goto label_1;
| }
0x000ab858 mov r0, r5 | r0 = r5;
0x000ab85a mov r1, r8 | r1 = r8;
0x000ab85c mov r2, r6 | r2 = r6;
0x000ab85e mov.w ip, 0xf2 |
0x000ab862 bl 0x21990 | r0 = fcn_00021990 ();
0x000ab866 cmp r0, 0 |
| if (r0 <= 0) {
0x000ab868 ble 0xab8a4 | goto label_7;
| }
0x000ab86a lsrs.w r7, r8, 2 | r7 = r8 >> 2;
| if (r7 == r8) {
0x000ab86e beq 0xab8bc | goto label_8;
| }
0x000ab870 mov r5, r6 | r5 = r6;
0x000ab872 add.w r7, r6, r7, lsl 2 | r7 = r6 + (r7 << 2);
0x000ab876 ldr r0, [r5], 4 | r0 = *(r5);
| r5 += 4;
0x000ab87a bl 0xdd2ec | r0 = fcn_000dd2ec (r0);
0x000ab87e mov r4, r0 | r4 = r0;
0x000ab880 b 0xab890 |
| while (r5 != r7) {
0x000ab882 ldr r0, [r5], 4 | r0 = *(r5);
| r5 += 4;
0x000ab886 bl 0xdd2ec | r0 = fcn_000dd2ec (r0);
0x000ab88a adds r0, r4, r0 | r0 = r4 + r0;
0x000ab88c mov r4, r0 | r4 = r0;
0x000ab88e bvs 0xab8b2 | __asm ("bvs aav.0x000000ff");
0x000ab890 cmp r5, r7 |
0x000ab892 bne 0xab882 |
| }
| do {
| label_2:
0x000ab894 mov r1, r8 | r1 = r8;
0x000ab896 mov r0, r6 | r0 = r6;
0x000ab898 bl 0xaa040 | munmap ();
0x000ab89c mov r0, r4 | r0 = r4;
0x000ab89e add sp, 0x88 |
0x000ab8a0 pop.w {r4, r5, r6, r7, r8, pc} |
| label_7:
0x000ab8a4 adds r0, 0x16 | r0 += 0x16;
0x000ab8a6 it eq |
| if (r0 != 0x16) {
0x000ab8a8 lsleq r4, r8, 3 | r4 = r8 << 3;
| }
0x000ab8ac beq 0xab894 |
| } while (r0 == 0x16);
0x000ab8ae movs r4, 2 | r4 = 2;
0x000ab8b0 b 0xab894 | goto label_2;
0x000ab8b2 mvn r4, 0x80000000 | r4 = ~0x80000000;
0x000ab8b6 b 0xab894 | goto label_2;
| label_6:
0x000ab8b8 mov r4, r6 | r4 = r6;
0x000ab8ba b 0xab7fa | goto label_3;
| label_8:
0x000ab8bc mov r4, r7 | r4 = r7;
0x000ab8be b 0xab894 | goto label_2;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0xab8c8 */
| #include <stdint.h>
|
; (fcn) sym.get_nprocs_conf () | void get_nprocs_conf (int16_t arg2) {
| char * * endptr;
| r1 = arg2;
0x000ab8c8 ldr r0, [pc, 0x68] |
0x000ab8ca push {r4, r5, r6, r7, lr} |
0x000ab8cc sub sp, 0xc |
0x000ab8ce movs r6, 1 | r6 = 1;
0x000ab8d0 add r0, pc | r0 = 0x157208;
0x000ab8d2 bl 0x8226c | r0 = opendir ();
| if (r0 == 0) {
0x000ab8d6 cbz r0, 0xab92e | goto label_2;
| }
0x000ab8d8 mov r5, r0 | r5 = r0;
0x000ab8da movs r6, 0 | r6 = 0;
0x000ab8dc add r7, sp, 4 | r7 += endptr;
| do {
| label_0:
0x000ab8de mov r0, r5 | r0 = r5;
0x000ab8e0 bl 0x82734 | r0 = readdir64 ();
| if (r0 == 0) {
0x000ab8e4 cbz r0, 0xab928 | goto label_3;
| }
| label_1:
0x000ab8e6 ldrb r3, [r0, 0x12] | r3 = *((r0 + 0x12));
0x000ab8e8 cmp r3, 4 |
0x000ab8ea bne 0xab8de |
| } while (r3 != 4);
0x000ab8ec ldrb r3, [r0, 0x13] | r3 = *((r0 + 0x13));
0x000ab8ee cmp r3, 0x63 |
| if (r3 != 0x63) {
0x000ab8f0 bne 0xab8de | goto label_0;
| }
0x000ab8f2 ldrb r3, [r0, 0x14] | r3 = *((r0 + 0x14));
0x000ab8f4 add.w r4, r0, 0x16 | r4 = r0 + 0x16;
0x000ab8f8 movs r2, 0xa | r2 = 0xa;
0x000ab8fa cmp r3, 0x70 |
| if (r3 != 0x70) {
0x000ab8fc bne 0xab8de | goto label_0;
| }
0x000ab8fe ldrb r3, [r0, 0x15] | r3 = *((r0 + 0x15));
0x000ab900 cmp r3, 0x75 |
| if (r3 != 0x75) {
0x000ab902 bne 0xab8de | goto label_0;
| }
0x000ab904 mov r1, r7 | r1 = r7;
0x000ab906 mov r0, r4 | r0 = r4;
0x000ab908 bl 0x3271c | strtoul ();
0x000ab90c adds r0, 1 | r0++;
| if (r0 == 1) {
0x000ab90e beq 0xab8de | goto label_0;
| }
0x000ab910 ldr r3, [sp, 4] | r3 = endptr;
0x000ab912 cmp r4, r3 |
| if (r4 == r3) {
0x000ab914 beq 0xab8de | goto label_0;
| }
0x000ab916 ldrb r3, [r3] | r3 = *(r3);
0x000ab918 cmp r3, 0 |
| if (r3 != 0) {
0x000ab91a bne 0xab8de | goto label_0;
| }
0x000ab91c mov r0, r5 | r0 = r5;
0x000ab91e adds r6, 1 | r6++;
0x000ab920 bl 0x82734 | r0 = readdir64 ();
0x000ab924 cmp r0, 0 |
| if (r0 != 0) {
0x000ab926 bne 0xab8e6 | goto label_1;
| }
| label_3:
0x000ab928 mov r0, r5 | r0 = r5;
0x000ab92a bl 0x82318 | closedir ();
| label_2:
0x000ab92e mov r0, r6 | r0 = r6;
0x000ab930 add sp, 0xc |
0x000ab932 pop {r4, r5, r6, r7, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x5d1bc */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) sym.pthread_create () | void pthread_create (int16_t arg_8h, int16_t arg_ch, int16_t arg_10h, int16_t arg_14h, int16_t arg1, int16_t arg2, int16_t arg3, int16_t arg4) {
| int32_t var_0h;
| int32_t var_0h_2;
| int16_t var_ch;
| int32_t var_ch_2;
| int16_t var_14h;
| int16_t var_18h;
| int16_t var_1ch;
| size_t length;
| int16_t var_24h;
| void* addr;
| int16_t var_2ch;
| int16_t var_38h;
| int16_t var_5ch;
| int16_t var_60h;
| int16_t var_64h;
| int16_t var_e0h;
| r0 = arg1;
| r1 = arg2;
| r2 = arg3;
| r3 = arg4;
0x0005d1bc push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x0005d1c0 sub sp, 0xec |
0x0005d1c2 ldr.w r7, [pc, 0xa00] | r7 = *(0x0005dbc4);
0x0005d1c6 strd r2, r3, [sp, 0x14] | __asm ("strd r2, r3, [var_14h]");
0x0005d1ca ldr.w r3, [pc, 0x9fc] | r3 = *(0x5dbca);
0x0005d1ce add r7, pc | r7 += pc;
0x0005d1d0 strd r1, r0, [sp, 0xc] | __asm ("strd r1, r0, [var_ch]");
0x0005d1d4 ldr r4, [r7, r3] | r4 = *((r7 + r3));
0x0005d1d6 ldrb r3, [r4] | r3 = *(r4);
0x0005d1d8 cmp r3, 0 |
| if (r3 != 0) {
0x0005d1da bne.w 0x5d674 | goto label_25;
| }
| label_6:
0x0005d1de ldr r3, [sp, 0xc] | r3 = var_ch;
0x0005d1e0 subs r3, 1 | r3--;
0x0005d1e2 adds r3, 3 | r3 += 3;
| if (r3 < 3) {
0x0005d1e4 bls 0x5d222 | goto label_26;
| }
0x0005d1e6 add.w fp, sp, 0x38 |
0x0005d1ea mov r0, fp | r0 = fp;
0x0005d1ec bl 0x5dd4c | r0 = pthread_getattr_default_np ();
0x0005d1f0 mov r8, r0 | r8 = r0;
| if (r0 != 0) {
0x0005d1f2 cbnz r0, 0x5d21a | void (*0x5d21a)() ();
| }
0x0005d1f4 movs r3, 1 | r3 = 1;
0x0005d1f6 str r3, [sp, 0x1c] | var_1ch = r3;
0x0005d1f8 b 0x5d22a |
| while (r3 < r2) {
0x0005d1fa ldr.w r8, [fp, 0x10] | r8 = *(arg_10h);
0x0005d1fe mov r3, r4 | r3 = r4;
| label_4:
0x0005d200 ldr r2, [sp, 0x20] | r2 = length;
0x0005d202 add.w r2, r2, 0x800 | r2 += 0x800;
0x0005d206 cmp r2, r3 |
| if (r2 < r3) {
0x0005d208 bls.w 0x5d5b0 | goto label_27;
| }
| label_0:
0x0005d20c mov.w r8, 0x16 | r8 = 0x16;
| label_26:
0x0005d222 ldr.w fp, [sp, 0xc] | fp = var_ch;
0x0005d226 movs r3, 0 | r3 = 0;
0x0005d228 str r3, [sp, 0x1c] | var_1ch = r3;
0x0005d22a bl 0xa7b18 | getpagesize ();
0x0005d22e ldr.w r3, [pc, 0x99c] | r3 = *(0x5dbce);
0x0005d232 mov sb, r0 | sb = r0;
0x0005d234 add.w r8, r0, -1 | r8 = r0 + -1;
0x0005d238 ldr r2, [r7, r3] | r2 = *((r7 + r3));
0x0005d23a ldrd r0, r5, [r2, 0x170] | __asm ("ldrd r0, r5, aav.0x000000ff");
0x0005d23e add r0, r5 | r0 += r5;
0x0005d240 mov r1, r5 | r1 = r5;
0x0005d242 subs r0, 1 | r0--;
0x0005d244 bl 0xdc970 | r0 = fcn_000dc970 (r0, r1, r2);
0x0005d248 mul r3, r5, r0 | r3 = r5 * r0;
0x0005d24c tst.w sb, r8 |
0x0005d250 str r3, [sp, 0x20] | length = r3;
| if ((sb & r8) != 0) {
0x0005d252 bne.w 0x5dae8 | goto label_28;
| }
0x0005d256 ldr.w r4, [fp, 0x14] | r4 = *(arg_14h);
0x0005d25a cmp r4, 0 |
| if (r4 == 0) {
0x0005d25c beq.w 0x5d554 | goto label_29;
| }
0x0005d260 ldr.w r2, [fp, 8] | r2 = *(arg_8h);
0x0005d264 lsls r3, r2, 0x1c | r3 = r2 << 0x1c;
0x0005d266 bmi 0x5d1fa |
| }
| label_3:
0x0005d268 ldr.w r2, [pc, 0x964] | r2 = *(0x5dbd0);
0x0005d26c rsbs r5, r5, 0 | r5 -= ;
0x0005d26e ands.w r3, r4, r5 | r3 = r4 & r5;
0x0005d272 ldr.w sl, [r7, r2] | sl = *((r7 + r2));
0x0005d276 str r3, [sp, 0x24] | var_24h = r3;
0x0005d278 ldr.w r1, [sl, 0x878] | r1 = *((sl + 0x878));
| if (r3 == r4) {
0x0005d27c beq.w 0x5dafa | goto label_30;
| }
0x0005d280 ldr.w r2, [fp, 0xc] | r2 = *(arg_ch);
0x0005d284 rsb.w r0, sb, 0 | r0 = sb - ;
0x0005d288 add.w r7, r2, r8 | r7 = r2 + r8;
0x0005d28c ands r7, r0 | r7 &= r0;
0x0005d28e cmp r2, r7 |
| if (r2 > r7) {
0x0005d290 bhi 0x5d20c | goto label_0;
| }
0x0005d292 ldr r3, [sp, 0x24] | r3 = var_24h;
0x0005d294 adds.w sb, r3, r7 | sb = r3 + r7;
0x0005d298 ite hs |
| if (sb < r3) {
0x0005d29a movhs r6, 1 | r6 = 1;
| }
| if (sb < r3) {
0x0005d29c movlo r6, 0 | r6 = 0;
| goto label_31;
| }
| if (sb >= r3) {
| label_31:
0x0005d29e bhs 0x5d20c | goto label_0;
| }
0x0005d2a0 ldr r3, [sp, 0x20] | r3 = length;
0x0005d2a2 add.w r4, r3, 0x800 | r4 = r3 + 0x800;
0x0005d2a6 add.w r3, r4, r8 | r3 = r4 + r8;
0x0005d2aa add r3, r7 | r3 += r7;
0x0005d2ac ands r3, r0 | r3 &= r0;
0x0005d2ae cmp sb, r3 |
| if (sb <= r3) {
0x0005d2b0 blo 0x5d20c | goto label_0;
| }
0x0005d2b2 add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005d2b6 movs r3, 1 | r3 = 1;
| do {
0x0005d2b8 ldrex r4, [r0] | __asm ("ldrex r4, [r0]");
0x0005d2bc cmp r4, 0 |
| if (r4 != 0) {
0x0005d2be bne 0x5d2cc | goto label_32;
| }
0x0005d2c0 strex r2, r3, [r0] | __asm ("strex r2, r3, [r0]");
0x0005d2c4 cmp r2, 0 |
0x0005d2c6 bne 0x5d2b8 |
| } while (r2 != 0);
0x0005d2c8 dmb ish | __asm ("dmb ish");
| if (r2 != 0) {
| label_32:
0x0005d2cc bne.w 0x5d9da | goto label_33;
| }
| label_13:
0x0005d2d0 ldr.w r3, [sl, 0x8b0] | r3 = *((sl + 0x8b0));
0x0005d2d4 lsls r1, r1, 2 | r1 <<= 2;
0x0005d2d6 add.w r0, sl, 0x8b0 | r0 = sl + 0x8b0;
0x0005d2da and r8, r1, 4 | r8 = r1 & 4;
0x0005d2de cmp r3, r0 |
0x0005d2e0 orr r2, r8, 3 | r2 = r8 | 3;
0x0005d2e4 str r2, [sp, 0x2c] | var_2ch = r2;
| if (r3 == r0) {
0x0005d2e6 beq.w 0x5d88c | goto label_34;
| }
0x0005d2ea movs r4, 0 | r4 = 0;
0x0005d2ec b 0x5d2f4 |
| while (r2 > 0) {
| label_1:
0x0005d2ee ldr r3, [r3] | r3 = *(r3);
0x0005d2f0 cmp r3, r0 |
| if (r3 == r0) {
0x0005d2f2 beq 0x5d320 | goto label_35;
| }
| label_2:
0x0005d2f4 ldr r2, [r3, 8] | r2 = *((r3 + 8));
0x0005d2f6 cmp r2, 0 |
0x0005d2f8 bgt 0x5d2ee |
| }
0x0005d2fa ldr.w r2, [r3, 0x244] | r2 = *((r3 + 0x244));
0x0005d2fe cmp sb, r2 |
| if (sb > r2) {
0x0005d300 bhi 0x5d2ee | goto label_1;
| }
0x0005d302 sub.w lr, r3, 0x60 | lr = r3 - 0x60;
| if (sb == r2) {
0x0005d306 beq.w 0x5d9ca | goto label_36;
| }
0x0005d30a cmp r4, 0 |
| if (r4 == 0) {
0x0005d30c beq.w 0x5d6b8 | goto label_37;
| }
0x0005d310 ldr.w r1, [r4, 0x2a4] | r1 = *((r4 + 0x2a4));
0x0005d314 ldr r3, [r3] | r3 = *(r3);
0x0005d316 cmp r2, r1 |
0x0005d318 it lo |
| if (r2 >= r1) {
0x0005d31a movlo r4, lr | r4 = lr;
| }
0x0005d31c cmp r3, r0 |
| if (r3 != r0) {
0x0005d31e bne 0x5d2f4 | goto label_2;
| }
| label_35:
0x0005d320 cmp r4, 0 |
| if (r4 == 0) {
0x0005d322 beq.w 0x5d88c | goto label_34;
| }
| label_10:
0x0005d326 ldr.w r3, [r4, 0x2a4] | r3 = *((r4 + 0x2a4));
0x0005d32a cmp.w r3, sb, lsl 2 |
| if (r3 > sb) {
0x0005d32e bhi.w 0x5d88c | goto label_34;
| }
0x0005d332 add.w r3, r4, 0x60 | r3 = r4 + 0x60;
0x0005d336 mov r5, r3 | r5 = r3;
0x0005d338 str r3, [sp, 0x24] | var_24h = r3;
0x0005d33a mov.w r3, -1 | r3 = -1;
0x0005d33e mov r0, r5 | r0 = r5;
0x0005d340 str.w r3, [r4, 0x218] | __asm ("str.w r3, aav.0x000000ff");
0x0005d344 bl 0x5a6ec | fcn_0005a6ec (r0);
0x0005d348 add.w r1, sl, 0x8a0 | r1 = sl + 0x8a0;
0x0005d34c mov r0, r5 | r0 = r5;
0x0005d34e bl 0x5a720 | fcn_0005a720 (r0, r1);
0x0005d352 ldr.w r1, [r4, 0x2a4] | r1 = *((r4 + 0x2a4));
0x0005d356 add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005d35a ldr.w r3, [sl, 0x8b8] | r3 = *((sl + 0x8b8));
0x0005d35e subs r3, r3, r1 | r3 -= r1;
0x0005d360 movs r1, 0 | r1 = 0;
0x0005d362 str.w r3, [sl, 0x8b8] | __asm ("str.w r3, aav.0x000000ff");
0x0005d366 dmb ish | __asm ("dmb ish");
| do {
0x0005d36a ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005d36e strex r5, r1, [r0] | __asm ("strex r5, r1, [r0]");
0x0005d372 cmp r5, 0 |
0x0005d374 bne 0x5d36a |
| } while (r5 != 0);
0x0005d376 cmp r3, 1 |
| if (r3 > 1) {
0x0005d378 bgt.w 0x5d9fa | goto label_38;
| }
| label_16:
0x0005d37c ldr.w r5, [r4, 0x540] | r5 = *((r4 + 0x540));
0x0005d380 movs r3, 0 | r3 = 0;
0x0005d382 ldr.w r2, [r4, 0x2a4] | r2 = *((r4 + 0x2a4));
0x0005d386 strb.w r3, [r4, 0x535] | *((r4 + 0x535)) = r3;
0x0005d38a strb.w r3, [r4, 0x536] | *((r4 + 0x536)) = r3;
0x0005d38c adds r5, 0x36 | r5 += 0x36;
0x0005d38e ldr r0, [r5, -0x8] | r0 = *((r5 - 0x8));
0x0005d392 str r2, [sp, 0x20] | length = r2;
0x0005d394 ldr.w r2, [r4, 0x2a0] | r2 = *((r4 + 0x2a0));
0x0005d398 str.w r3, [r4, 0x84] | __asm ("str.w r3, [r4, 0x84]");
0x0005d39c str r3, [r4, 0x7c] | *((r4 + 0x7c)) = r3;
0x0005d39e str.w r3, [r4, 0x210] | __asm ("str.w r3, aav.0x000000ff");
0x0005d3a2 str.w r3, [r4, 0x244] | __asm ("str.w r3, aav.0x000000ff");
0x0005d3a6 str.w r3, [r4, 0x538] | __asm ("str.w r3, aav.0x000000ff");
0x0005d3aa str r2, [sp, 0x28] | addr = r2;
0x0005d3ac str.w r3, [r4, 0x53c] | __asm ("str.w r3, aav.0x000000ff");
0x0005d3b0 cmp r0, 0 |
| if (r0 == 0) {
0x0005d3b2 beq.w 0x5d9f6 | goto label_39;
| }
0x0005d3b6 add.w r8, r5, 4 | r8 = r5 + 4;
| do {
0x0005d3ba adds r6, 1 | r6++;
0x0005d3bc ldr.w r0, [r8, r6, lsl 3] | offset_0 = r6 << 3;
| r0 = *((r8 + offset_0));
0x0005d3c0 blx 0x212d4 | fcn_000212d4 ();
0x0005d3c4 ldr r3, [r5, -0x8] | r3 = *((r5 - 0x8));
0x0005d3c8 cmp r6, r3 |
0x0005d3ca blo 0x5d3ba |
| } while (r6 <= r3);
0x0005d3cc adds r3, 1 | r3++;
0x0005d3ce lsls r2, r3, 3 | r2 = r3 << 3;
| label_15:
0x0005d3d0 mov r0, r5 | r0 = r5;
0x0005d3d2 movs r1, 0 | r1 = 0;
0x0005d3d4 add.w r5, r4, 0x540 | r5 = r4 + 0x540;
0x0005d3d8 blx 0x6b880 | memset (r0, r1, r2);
0x0005d3dc mov r0, r5 | r0 = r5;
0x0005d3de blx 0x21338 | nptl_change_stack_perm ();
| label_7:
0x0005d3e2 ldr.w r1, [r4, 0x2a8] | r1 = *((r4 + 0x2a8));
0x0005d3e6 cmp r7, r1 |
| if (r7 > r1) {
0x0005d3e8 bhi.w 0x5d9e4 | goto label_40;
| }
0x0005d3ec ldr r3, [sp, 0x20] | r3 = length;
0x0005d3ee subs r1, r1, r7 | r1 -= r7;
0x0005d3f0 sub.w sb, r3, sb | sb = r3 - sb;
0x0005d3f4 cmp r1, sb |
| if (r1 > sb) {
0x0005d3f6 bhi.w 0x5da00 | goto label_41;
| }
| label_14:
0x0005d3fa mov sb, r4 | sb = r4;
0x0005d3fc str.w r7, [r4, 0x2ac] | __asm ("str.w r7, aav.0x000000ff");
| label_5:
0x0005d400 ldr r3, [sp, 0x14] | r3 = var_14h;
0x0005d402 add.w ip, r4, 0x234 |
0x0005d406 ldr.w r7, [fp, 8] | r7 = *(arg_8h);
0x0005d40a sub.w r8, r4, 0x540 | r8 = r4 - 0x540;
0x0005d40e ldr.w sl, [r4, 0x2a0] | sl = *((r4 + 0x2a0));
0x0005d412 str.w r3, [r4, 0x22c] | __asm ("str.w r3, aav.0x000000ff");
0x0005d416 ldr r3, [sp, 0x18] | r3 = var_18h;
0x0005d418 tst.w r7, 1 |
0x0005d41c sub.w r8, r8, sl | r8 -= sl;
0x0005d420 str.w r3, [r4, 0x230] | __asm ("str.w r3, aav.0x000000ff");
0x0005d424 ldr r3, [sp, 0xc] | r3 = var_ch;
0x0005d426 sub.w r6, r3, -1 | r6 = r3 - -1;
0x0005d42a mrc p15, 0, r3, c13, c0, 3 | __asm ("mrc p15, 0, r3, c13, c0, 3");
0x0005d42e clz r6, r6 | r6 &= r6;
0x0005d432 lsr.w r6, r6, 5 | r6 >>= 5;
0x0005d436 strb.w r6, [r4, 0x534] | *((r4 + 0x534)) = r6;
0x0005d43a sub.w r6, r3, 0x540 | r6 = r3 - 0x540;
0x0005d43e ldr.w r2, [r6, 0x228] | r2 = *((r6 + 0x228));
0x0005d442 sub.w r3, r3, 0x30c | r3 -= 0x30c;
0x0005d446 ldr.w r5, [r6, 0x88] | r5 = *((r6 + 0x88));
0x0005d44a ldr.w lr, [r6, 0x224] |
0x0005d44e str r2, [sp, 0xc] | var_ch = r2;
0x0005d450 bic r2, r7, 0x60 | r2 = BIT_MASK (r7, 0x60);
0x0005d454 and r5, r5, 0x60 | r5 &= 0x60;
0x0005d458 orr.w r5, r5, r2 | r5 |= r2;
0x0005d45c mov.w r2, 0 | r2 = 0;
0x0005d460 str.w r2, [r4, 0x214] | __asm ("str.w r2, aav.0x000000ff");
0x0005d464 str r2, [r4, 0x78] | *((r4 + 0x78)) = r2;
0x0005d466 mvn r2, 0x13 | r2 = ~0x13;
0x0005d46a str r2, [r4, 0x74] | *((r4 + 0x74)) = r2;
0x0005d46c add.w r2, r4, 0x70 | r2 = r4 + 0x70;
0x0005d470 str r2, [r4, 0x70] | *((r4 + 0x70)) = r2;
0x0005d472 ite ne |
| if ((r7 & 1) == 0) {
0x0005d474 movne r2, r4 | r2 = r4;
| }
| if ((r7 & 1) != 0) {
0x0005d476 moveq r2, 0 | r2 = 0;
| }
0x0005d478 str.w r5, [r4, 0x88] | __asm ("str.w r5, [r4, 0x88]");
| label_29:
0x0005d554 ldr.w r0, [pc, 0x688] | r0 = *(0x0005dbe0);
0x0005d558 movs r2, 1 | r2 = 1;
0x0005d55a add r0, pc | r0 += pc;
| do {
0x0005d55c ldrex r1, [r0] | __asm ("ldrex r1, [r0]");
0x0005d560 cmp r1, 0 |
| if (r1 != 0) {
0x0005d562 bne 0x5d570 | goto label_42;
| }
0x0005d564 strex r3, r2, [r0] | __asm ("strex r3, r2, [r0]");
0x0005d568 cmp r3, 0 |
0x0005d56a bne 0x5d55c |
| } while (r3 != 0);
0x0005d56c dmb ish | __asm ("dmb ish");
| if (r3 != 0) {
| label_42:
0x0005d570 bne.w 0x5d9ce | goto label_43;
| }
| label_11:
0x0005d574 ldr.w r0, [pc, 0x66c] | r0 = *(0x0005dbe4);
0x0005d578 movs r1, 0 | r1 = 0;
0x0005d57a ldr.w r2, [pc, 0x66c] |
0x0005d57e add r0, pc | r0 += pc;
0x0005d580 add r2, pc | r2 = 0xbb16e;
0x0005d582 ldr r4, [r2, 0x14] | r4 = *(0xbb182);
0x0005d584 dmb ish | __asm ("dmb ish");
| do {
0x0005d588 ldrex r2, [r0] | __asm ("ldrex r2, [r0]");
0x0005d58c strex ip, r1, [r0] | __asm ("strex ip, r1, [r0]");
0x0005d590 cmp.w ip, 0 |
0x0005d594 bne 0x5d588 |
| } while (ip != 0);
0x0005d596 cmp r2, 1 |
| if (r2 > 1) {
0x0005d598 bgt.w 0x5d9d4 | goto label_44;
| }
| label_12:
0x0005d59c ldr.w r2, [fp, 8] | r2 = *(arg_8h);
0x0005d5a0 lsls r2, r2, 0x1c | r2 <<= 0x1c;
| if (r2 >= r2) {
0x0005d5a2 bpl.w 0x5d268 | goto label_3;
| }
0x0005d5a6 ldrd r8, r3, [fp, 0x10] | __asm ("ldrd r8, r3, [arg_10h]");
0x0005d5aa cmp r3, 0 |
| if (r3 != 0) {
0x0005d5ac bne.w 0x5d200 | goto label_4;
| }
| label_27:
0x0005d5b0 ldr r3, [sp, 0x20] | r3 = length;
0x0005d5b2 subs r5, 1 | r5--;
0x0005d5b4 sub.w sb, r8, r3 | sb = r8 - r3;
0x0005d5b8 and.w r5, r5, sb | r5 &= sb;
0x0005d5bc cmp r5, r4 |
| if (r5 >= r4) {
0x0005d5be bhs.w 0x5db62 | void (*0x5db62)() ();
| }
0x0005d5c2 sub.w sb, sb, 0x540 | sb -= 0x540;
0x0005d5c6 mov.w r2, 0x540 | r2 = 0x540;
0x0005d5ca sub.w sb, sb, r5 | sb -= r5;
0x0005d5ce movs r1, 0 | r1 = 0;
0x0005d5d0 mov r0, sb | r0 = sb;
0x0005d5d2 movs r5, 1 | r5 = 1;
0x0005d5d4 blx 0x6b880 | memset (r0, r1, r2);
0x0005d5d8 sub.w r3, r8, r4 | r3 = r8 - r4;
0x0005d5dc str.w r5, [sb] | __asm ("str.w r5, [sb]");
0x0005d5e0 strd r3, r4, [sb, 0x2a0] | __asm ("strd r3, r4, aav.0x000000ff");
0x0005d5e4 add.w r0, sb, 0x540 | r0 = sb + 0x540;
0x0005d5e8 ldr.w r3, [pc, 0x600] | r3 = *(0x0005dbec);
0x0005d5ec mov r4, sb | r4 = sb;
0x0005d5ee strb.w r5, [sb, 0x20e] | *((sb + 0x20e)) = r5;
0x0005d5f2 add r3, pc | r3 += pc;
0x0005d5f4 str r5, [r3] | *(r3) = r5;
0x0005d5f6 add.w r3, sb, 0x8c | r3 = sb + 0x8c;
0x0005d5fa str.w r3, [sb, 0x18c] | __asm ("str.w r3, aav.0x000000ff");
0x0005d5fe mov.w r3, -1 | r3 = -1;
0x0005d602 str.w r3, [sb, 0x218] | __asm ("str.w r3, aav.0x000000ff");
0x0005d606 blx 0x21314 | r0 = tunable_get_val ();
0x0005d60a cmp r0, 0 |
| if (r0 == 0) {
0x0005d60c beq.w 0x5da8e | goto label_45;
| }
0x0005d610 ldr.w r3, [pc, 0x5bc] | r3 = *(0x5dbd0);
0x0005d614 ldr.w sl, [r7, r3] | sl = *((r7 + r3));
0x0005d618 add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
| do {
0x0005d61c ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005d620 cmp r3, 0 |
| if (r3 != 0) {
0x0005d622 bne 0x5d630 | goto label_46;
| }
0x0005d624 strex r2, r5, [r0] | __asm ("strex r2, r5, [r0]");
0x0005d628 cmp r2, 0 |
0x0005d62a bne 0x5d61c |
| } while (r2 != 0);
0x0005d62c dmb ish | __asm ("dmb ish");
| if (r2 != 0) {
| label_46:
0x0005d630 bne.w 0x5daca | goto label_47;
| }
| label_19:
0x0005d634 ldr.w r2, [sl, 0x8a8] | r2 = *((sl + 0x8a8));
0x0005d638 add.w r3, sb, 0x60 | r3 = sb + 0x60;
0x0005d63c addw r1, sl, 0x8a8 | __asm ("addw r1, sl, aav.0x000000ff");
0x0005d640 add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005d644 str.w r1, [sb, 0x64] | __asm ("str.w r1, [sb, 0x64]");
0x0005d648 str.w r2, [sb, 0x60] | __asm ("str.w r2, [sb, 0x60]");
0x0005d64c str r3, [r2, 4] | *((r2 + 4)) = r3;
0x0005d64e movs r2, 0 | r2 = 0;
0x0005d650 dmb ish | __asm ("dmb ish");
0x0005d654 str.w r3, [sl, 0x8a8] | __asm ("str.w r3, aav.0x000000ff");
0x0005d658 dmb ish | __asm ("dmb ish");
| do {
0x0005d65c ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005d660 strex r1, r2, [r0] | __asm ("strex r1, r2, [r0]");
0x0005d664 cmp r1, 0 |
0x0005d666 bne 0x5d65c |
| } while (r1 != 0);
0x0005d668 cmp r3, 1 |
| if (r3 <= 1) {
0x0005d66a ble.w 0x5d400 | goto label_5;
| }
0x0005d66e bl 0x5a6c0 | lll_lock_wake_private ();
0x0005d672 b 0x5d400 | goto label_5;
| label_25:
0x0005d674 ldr.w r3, [pc, 0x578] | r3 = *(0x0005dbf0);
0x0005d678 movs r5, 0 | r5 = 0;
0x0005d67a mov r2, r5 | r2 = r5;
0x0005d67c add r1, sp, 0x5c | r1 += var_5ch;
0x0005d67e movs r0, 0x21 | r0 = 0x21;
0x0005d680 strd r5, r5, [sp, 0x60] | __asm ("strd r5, r5, [var_60h]");
0x0005d684 add r3, pc | r3 += pc;
0x0005d686 str r3, [sp, 0x5c] | var_5ch = r3;
0x0005d688 movs r3, 4 |
0x0005d68a movt r3, 0x1800 | r3 = 0x18000004;
0x0005d68e str r3, [sp, 0xe0] | var_e0h = r3;
0x0005d690 bl 0x2fa64 | libc_sigaction ();
0x0005d694 ldr r3, [sp, 0x60] | r3 = var_60h;
0x0005d696 movs r0, 1 | r0 = 1;
0x0005d698 add r1, sp, 0x60 | r1 += var_60h;
0x0005d69a mov r2, r5 | r2 = r5;
0x0005d69c mov.w ip, 0xaf |
0x0005d6a0 orr r3, r3, 0x80000000 | r3 |= 0x80000000;
0x0005d6a4 str r3, [sp, 0x60] | var_60h = r3;
0x0005d6a6 ldr r3, [sp, 0x64] | r3 = var_64h;
0x0005d6a8 orr r3, r3, 1 | r3 |= 1;
0x0005d6ac str r3, [sp, 0x64] | var_64h = r3;
0x0005d6ae movs r3, 8 | r3 = 8;
0x0005d6b0 bl 0x21990 | fcn_00021990 ();
0x0005d6b4 strb r5, [r4] | *(r4) = r5;
0x0005d6b6 b 0x5d1de | goto label_6;
| label_37:
0x0005d6b8 mov r4, lr | r4 = lr;
0x0005d6ba b 0x5d2ee | goto label_1;
| label_34:
0x0005d88c add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005d890 movs r2, 0 | r2 = 0;
0x0005d892 dmb ish | __asm ("dmb ish");
| do {
0x0005d896 ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005d89a strex r1, r2, [r0] | __asm ("strex r1, r2, [r0]");
0x0005d89e cmp r1, 0 |
0x0005d8a0 bne 0x5d896 |
| } while (r1 != 0);
0x0005d8a2 cmp r3, 1 |
| if (r3 > 1) {
0x0005d8a4 bgt.w 0x5dac4 | goto label_48;
| }
| label_18:
0x0005d8a8 movs r0, 0 | r0 = 0;
0x0005d8aa mov.w r3, -1 | r3 = -1;
0x0005d8ae cmp r7, 0 |
0x0005d8b0 strd r3, r0, [sp] | __asm ("strd r3, r0, [sp]");
0x0005d8b4 mov.w r3, 0x22 | r3 = 0x22;
0x0005d8b8 ldr r2, [sp, 0x2c] | r2 = var_2ch;
0x0005d8ba movt r3, 2 | r3 = (r3 & 0xFFFF) | 0x20000;
0x0005d8be it ne |
| if (r7 == 0) {
0x0005d8c0 movne r2, r0 | r2 = r0;
| }
0x0005d8c2 mov r1, sb | r1 = sb;
0x0005d8c4 bl 0xa9f88 | r0 = mmap ()
0x0005d8c8 mov r3, r0 | r3 = r0;
0x0005d8ca str r0, [sp, 0x28] | addr = r0;
0x0005d8cc adds r3, 1 | r3++;
| if (r3 == 1) {
0x0005d8ce beq.w 0x5dab4 | goto label_49;
| }
0x0005d8d2 ldr r3, [sp, 0x28] | r3 = addr;
0x0005d8d4 cmp r3, 0 |
| if (r3 == 0) {
0x0005d8d6 beq.w 0x5db3a | void (*0x5db3a)() ();
| }
0x0005d8da ldr r3, [sp, 0x20] | r3 = length;
0x0005d8dc sub.w r4, sb, r3 | r4 = sb - r3;
0x0005d8e0 ldr r3, [sp, 0x28] | r3 = addr;
0x0005d8e2 add r4, r3 | r4 += r3;
0x0005d8e4 ands r4, r5 | r4 &= r5;
0x0005d8e6 sub.w r4, r4, 0x540 | r4 -= 0x540;
| if (r7 != 0) {
0x0005d8ea cbz r7, 0x5d8fa |
0x0005d8ec ldr r1, [sp, 0x24] | r1 = var_24h;
0x0005d8ee adds r0, r3, r7 | r0 = r3 + r7;
0x0005d8f0 ldr r2, [sp, 0x2c] | r2 = var_2ch;
0x0005d8f2 bl 0xaa060 | r0 = mprotect ();
0x0005d8f6 cmp r0, 0 |
| if (r0 != 0) {
0x0005d8f8 bne 0x5d990 | goto label_50;
| }
| }
| label_8:
0x0005d8fa ldr r3, [sp, 0x28] | r3 = addr;
0x0005d8fc movs r6, 1 | r6 = 1;
0x0005d8fe str r6, [r4] | *(r4) = r6;
0x0005d900 add.w r5, r4, 0x540 | r5 = r4 + 0x540;
0x0005d904 mov r0, r5 | r0 = r5;
0x0005d906 str.w r7, [r4, 0x2a8] | __asm ("str.w r7, aav.0x000000ff");
0x0005d90a strd r3, sb, [r4, 0x2a0] | __asm ("strd r3, sb, aav.0x000000ff");
0x0005d90e ldr r3, [pc, 0x2ec] |
0x0005d910 add r3, pc | r3 = 0xbb512;
0x0005d912 str r6, [r3] | *(r3) = r6;
0x0005d914 add.w r3, r4, 0x8c | r3 = r4 + 0x8c;
0x0005d918 str.w r3, [r4, 0x18c] | __asm ("str.w r3, aav.0x000000ff");
0x0005d91c mov.w r3, -1 | r3 = -1;
0x0005d920 str.w r3, [r4, 0x218] | __asm ("str.w r3, aav.0x000000ff");
0x0005d924 blx 0x21314 | r0 = tunable_get_val ();
0x0005d928 cmp r0, 0 |
| if (r0 == 0) {
0x0005d92a beq.w 0x5da6a | goto label_51;
| }
0x0005d92e add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
| do {
0x0005d932 ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005d936 cmp r3, 0 |
| if (r3 != 0) {
0x0005d938 bne 0x5d946 | goto label_52;
| }
0x0005d93a strex r2, r6, [r0] | __asm ("strex r2, r6, [r0]");
0x0005d93e cmp r2, 0 |
0x0005d940 bne 0x5d932 |
| } while (r2 != 0);
0x0005d942 dmb ish | __asm ("dmb ish");
| if (r2 != 0) {
| label_52:
0x0005d946 bne 0x5d9c4 | goto label_53;
| }
| label_9:
0x0005d948 add.w r3, r4, 0x60 | r3 = r4 + 0x60;
0x0005d94c add.w r1, sl, 0x8a0 | r1 = sl + 0x8a0;
0x0005d950 mov r0, r3 | r0 = r3;
0x0005d952 str r3, [sp, 0x24] | var_24h = r3;
0x0005d954 bl 0x5a720 | fcn_0005a720 (r0, r1);
0x0005d958 dmb ish | __asm ("dmb ish");
0x0005d95c add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005d960 movs r2, 0 | r2 = 0;
| do {
0x0005d962 ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005d966 strex r1, r2, [r0] | __asm ("strex r1, r2, [r0]");
0x0005d96a cmp r1, 0 |
0x0005d96c bne 0x5d962 |
| } while (r1 != 0);
0x0005d96e cmp r3, 1 |
| if (r3 > 1) {
0x0005d970 bgt.w 0x5dad0 | goto label_54;
| }
| label_20:
0x0005d974 ldr.w r3, [sl, 0x878] | r3 = *((sl + 0x878));
0x0005d978 cmp.w r8, 0 |
0x0005d97c ite ne |
| if (r8 == 0) {
0x0005d97e movne r3, 0 | r3 = 0;
| }
| if (r8 != 0) {
0x0005d980 andeq r3, r3, 1 | r3 &= 1;
| }
0x0005d984 cmp r3, 0 |
| if (r3 != 0) {
0x0005d986 bne.w 0x5db0e | goto label_55;
| }
| label_23:
0x0005d98a str.w sb, [sp, 0x20] | __asm ("str.w sb, [length]");
0x0005d98e b 0x5d3e2 | goto label_7;
| label_50:
0x0005d990 ldr r3, [pc, 0x214] |
0x0005d992 mrc p15, 0, r5, c13, c0, 3 | __asm ("mrc p15, 0, r5, c13, c0, 3");
0x0005d996 add r3, pc |
0x0005d998 ldr r3, [r3] | r3 = *(0xbb542);
0x0005d99a ldr r3, [r5, r3] | r3 = *((r5 + r3));
0x0005d99c cmp r3, 0 |
| if (r3 == 0) {
0x0005d99e beq 0x5d8fa | goto label_8;
| }
0x0005d9a0 ldr r0, [sp, 0x28] | r0 = addr;
0x0005d9a2 mov r1, sb | r1 = sb;
0x0005d9a4 bl 0xaa040 | munmap ();
0x0005d9a8 ldr r3, [pc, 0x200] |
0x0005d9aa add r3, pc |
0x0005d9ac ldr r3, [r3] | r3 = *(0xbb55a);
0x0005d9ae ldr.w r8, [r5, r3] | r8 = *((r5 + r3));
| label_17:
0x0005d9b2 cmp.w r8, 0 |
| if (r8 == 0) {
0x0005d9b6 beq.w 0x5db9e | void (*0x5db9e)() ();
| }
| label_24:
0x0005d9ba cmp.w r8, 0xc |
| if (r8 == 0xc) {
0x0005d9be beq.w 0x5d7fa | void (*0x5d7fa)() ();
| }
0x0005d9c2 b 0x5d210 | void (*0x5d210)() ();
| label_53:
0x0005d9c4 bl 0x5a624 | lll_lock_wait_private ();
0x0005d9c8 b 0x5d948 | goto label_9;
| label_36:
0x0005d9ca mov r4, lr | r4 = lr;
0x0005d9cc b 0x5d326 | goto label_10;
| label_43:
0x0005d9ce bl 0x5a624 | lll_lock_wait_private ();
0x0005d9d2 b 0x5d574 | goto label_11;
| label_44:
0x0005d9d4 bl 0x5a6c0 | lll_lock_wake_private ();
0x0005d9d8 b 0x5d59c | goto label_12;
| label_33:
0x0005d9da str r1, [sp, 0x28] | addr = r1;
0x0005d9dc bl 0x5a624 | lll_lock_wait_private ();
0x0005d9e0 ldr r1, [sp, 0x28] | r1 = addr;
0x0005d9e2 b 0x5d2d0 | goto label_13;
| label_40:
0x0005d9e4 ldr r0, [sp, 0x28] | r0 = addr;
0x0005d9e6 movs r2, 0 | r2 = 0;
0x0005d9e8 mov r1, r7 | r1 = r7;
0x0005d9ea bl 0xaa060 | r0 = mprotect ();
| if (r0 != 0) {
0x0005d9ee cbnz r0, 0x5da0e | goto label_56;
| }
| do {
0x0005d9f0 str.w r7, [r4, 0x2a8] | __asm ("str.w r7, aav.0x000000ff");
0x0005d9f4 b 0x5d3fa | goto label_14;
| label_39:
0x0005d9f6 movs r2, 8 | r2 = 8;
0x0005d9f8 b 0x5d3d0 | goto label_15;
| label_38:
0x0005d9fa bl 0x5a6c0 | lll_lock_wake_private ();
0x0005d9fe b 0x5d37c | goto label_16;
| label_41:
0x0005da00 ldrd r3, r2, [sp, 0x28] | __asm ("ldrd r3, r2, [addr]");
0x0005da04 adds r0, r3, r7 | r0 = r3 + r7;
0x0005da06 bl 0xaa060 | r0 = mprotect ();
0x0005da0a cmp r0, 0 |
0x0005da0c beq 0x5d9f0 |
| } while (r0 == 0);
| label_56:
0x0005da0e add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005da12 movs r3, 1 | r3 = 1;
| do {
0x0005da14 ldrex r2, [r0] | __asm ("ldrex r2, [r0]");
0x0005da18 cmp r2, 0 |
| if (r2 != 0) {
0x0005da1a bne 0x5da28 | goto label_57;
| }
0x0005da1c strex r1, r3, [r0] | __asm ("strex r1, r3, [r0]");
0x0005da20 cmp r1, 0 |
0x0005da22 bne 0x5da14 |
| } while (r1 != 0);
0x0005da24 dmb ish | __asm ("dmb ish");
| if (r1 != 0) {
| label_57:
0x0005da28 bne 0x5dae2 | goto label_58;
| }
| label_22:
0x0005da2a ldr r0, [sp, 0x24] | r0 = var_24h;
0x0005da2c bl 0x5a6ec | fcn_0005a6ec (r0);
0x0005da30 dmb ish | __asm ("dmb ish");
0x0005da34 add.w r0, sl, 0x8c0 | r0 = sl + 0x8c0;
0x0005da38 movs r2, 0 | r2 = 0;
| do {
0x0005da3a ldrex r3, [r0] | __asm ("ldrex r3, [r0]");
0x0005da3e strex r1, r2, [r0] | __asm ("strex r1, r2, [r0]");
0x0005da42 cmp r1, 0 |
0x0005da44 bne 0x5da3a |
| } while (r1 != 0);
0x0005da46 cmp r3, 1 |
| if (r3 > 1) {
0x0005da48 bgt 0x5dadc | goto label_59;
| }
| label_21:
0x0005da4a mov r0, r5 | r0 = r5;
0x0005da4c movs r1, 0 | r1 = 0;
0x0005da4e blx 0x212ec | fcn_000212ec ();
0x0005da52 ldr r1, [sp, 0x20] | r1 = length;
0x0005da54 ldr r0, [sp, 0x28] | r0 = addr;
0x0005da56 bl 0xaa040 | munmap ();
0x0005da5a ldr r3, [pc, 0x154] |
0x0005da5c mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x0005da60 add r3, pc |
0x0005da62 ldr r3, [r3] | r3 = *(0xbb616);
0x0005da64 ldr.w r8, [r2, r3] | r8 = *((r2 + r3));
0x0005da68 b 0x5d9b2 | goto label_17;
| label_51:
0x0005da6a ldr r3, [pc, 0x148] |
0x0005da6c mrc p15, 0, r4, c13, c0, 3 | __asm ("mrc p15, 0, r4, c13, c0, 3");
0x0005da70 add r3, pc |
0x0005da72 ldr r3, [r3] | r3 = *(0xbb62a);
0x0005da74 ldr r3, [r4, r3] | r3 = *((r4 + r3));
0x0005da76 cmp r3, 0xc |
| if (r3 != 0xc) {
0x0005da78 bne 0x5db4e | void (*0x5db4e)() ();
| }
0x0005da7a ldr r0, [sp, 0x28] | r0 = addr;
0x0005da7c mov r1, sb | r1 = sb;
0x0005da7e bl 0xaa040 | munmap ();
0x0005da82 ldr r3, [pc, 0x134] |
0x0005da84 add r3, pc |
0x0005da86 ldr r3, [r3] | r3 = *(0xbb642);
0x0005da88 ldr.w r8, [r4, r3] | r8 = *((r4 + r3));
0x0005da8c b 0x5d9b2 | goto label_17;
| label_45:
0x0005da8e ldr r3, [pc, 0x12c] |
0x0005da90 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x0005da94 add r3, pc |
0x0005da96 ldr r3, [r3] | r3 = *(0xbb656);
0x0005da98 ldr r3, [r2, r3] | r3 = *((r2 + r3));
0x0005da9a cmp r3, 0xc |
| if (r3 == 0xc) {
0x0005da9c beq.w 0x5d7fa | void (*0x5d7fa)() ();
| }
0x0005daa0 ldr r3, [pc, 0x15c] |
0x0005daa2 mov.w r2, 0x136 | r2 = 0x136;
0x0005daa6 ldr r1, [pc, 0x15c] |
0x0005daa8 ldr r0, [pc, 0x15c] |
0x0005daaa add r3, pc | r3 = 0xbb6ae;
0x0005daac add r1, pc | r1 = 0xbb6b6;
0x0005daae add r0, pc | r0 = 0xbb6ba;
0x0005dab0 bl 0x2b2bc | assert_fail ();
| label_49:
0x0005dab4 ldr r3, [pc, 0x108] |
0x0005dab6 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x0005daba add r3, pc |
0x0005dabc ldr r3, [r3] | r3 = *(0xbb67e);
0x0005dabe ldr.w r8, [r2, r3] | r8 = *((r2 + r3));
0x0005dac2 b 0x5d9b2 | goto label_17;
| label_48:
0x0005dac4 bl 0x5a6c0 | lll_lock_wake_private ();
0x0005dac8 b 0x5d8a8 | goto label_18;
| label_47:
0x0005daca bl 0x5a624 | lll_lock_wait_private ();
0x0005dace b 0x5d634 | goto label_19;
| label_54:
0x0005dad0 bl 0x5a6c0 | lll_lock_wake_private ();
0x0005dad4 b 0x5d974 | goto label_20;
| label_59:
0x0005dadc bl 0x5a6c0 | lll_lock_wake_private ();
0x0005dae0 b 0x5da4a | goto label_21;
| label_58:
0x0005dae2 bl 0x5a624 | lll_lock_wait_private ();
0x0005dae6 b 0x5da2a | goto label_22;
| label_28:
0x0005dae8 ldr r3, [pc, 0x120] |
0x0005daea movs r2, 0xde | r2 = 0xde;
0x0005daec ldr r1, [pc, 0x120] |
0x0005daee ldr r0, [pc, 0x124] |
0x0005daf0 add r3, pc | r3 = 0xbb700;
0x0005daf2 add r1, pc | r1 = 0xbb706;
0x0005daf4 add r0, pc | r0 = 0xbb70e;
0x0005daf6 bl 0x2b2bc | assert_fail ();
| label_30:
0x0005dafa ldr r3, [pc, 0x11c] |
0x0005dafc movw r2, 0x14f | r2 = 0x14f;
0x0005db00 ldr r1, [pc, 0x118] |
0x0005db02 ldr r0, [pc, 0x11c] |
0x0005db04 add r3, pc | r3 = 0xbb722;
0x0005db06 add r1, pc | r1 = 0xbb726;
0x0005db08 add r0, pc | r0 = 0xbb72e;
0x0005db0a bl 0x2b2bc | assert_fail ();
| label_55:
0x0005db0e mov r0, r4 | r0 = r4;
0x0005db10 blx 0x21344 | r0 = fcn_00021344 ();
0x0005db14 mov r8, r0 | r8 = r0;
0x0005db16 cmp r0, 0 |
| if (r0 == 0) {
0x0005db18 beq.w 0x5d98a | goto label_23;
| }
0x0005db1c ldr r0, [sp, 0x28] | r0 = addr;
0x0005db1e mov r1, sb | r1 = sb;
0x0005db20 bl 0xaa040 | munmap ();
0x0005db24 b 0x5d9ba | goto label_24;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/patool_extraction/rootfs.img_unblob_extracted/rootfs.img_extract/0-50593792.squashfs_v4_le_extract/usr/lib/libc.so.6 @ 0x6294c */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) sym.sem_open () | void sem_open (int16_t arg1) {
| int16_t var_0h;
| int16_t var_sp_0h;
| int16_t var_4h;
| int16_t var_8h;
| int16_t var_ch;
| int16_t var_18h;
| int16_t var_1ch;
| int16_t var_20h;
| int32_t var_24h;
| int32_t var_24h_2;
| size_t fildes;
| int16_t var_1h;
| int16_t var_39h;
| int16_t var_4h_2;
| char * path;
| int16_t var_1h_2;
| int16_t var_174h;
| int16_t var_178h;
| int16_t var_17ch;
| r0 = arg1;
0x0006294c push {r1, r2, r3} |
0x0006294e mov r1, r0 | r1 = r0;
0x00062950 push.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x00062954 sub sp, 0x150 |
0x00062956 add.w sb, sp, 0x40 | sb += path;
0x0006295a mov r7, r0 | r7 = r0;
0x0006295c movs r2, 1 | r2 = 1;
0x0006295e mov r0, sb | r0 = sb;
0x00062960 bl 0x9d33c | r0 = shm_get_name ();
0x00062964 cmp r0, 0 |
| if (r0 != 0) {
0x00062966 bne 0x62a52 | goto label_7;
| }
0x00062968 add.w fp, sp, 0x14 |
0x0006296c movs r0, 1 | r0 = 1;
0x0006296e mov r1, fp | r1 = fp;
0x00062970 bl 0x62128 | pthread_setcancelstate ();
0x00062974 ldr r3, [sp, 0x174] | r3 = var_174h;
0x00062976 and r3, r3, 0xc0 | r3 &= 0xc0;
0x0006297a cmp r3, 0xc0 |
| if (r3 == 0xc0) {
0x0006297c beq 0x629ce | goto label_8;
| }
| label_6:
0x0006297e ldr r3, [sp, 0x174] | r3 = var_174h;
0x00062980 mov r0, sb | r0 = sb;
0x00062982 bic r1, r3, 0x8000 | r1 = BIT_MASK (r3, 0x8000);
0x00062986 bic r1, r1, 0x43 | r1 = BIT_MASK (r1, 0x43);
0x0006298a orr r1, r1, 0x8000 | r1 |= 0x8000;
0x0006298e orr r1, r1, 2 | r1 |= 2;
0x00062992 bl 0x9f428 | r0 = open (r0, r1, r2);
0x00062996 mov r4, r0 | r4 = r0;
0x00062998 adds r0, r4, 1 | r0 += var_1h_2;
| if (r0 != var_1h_2) {
0x0006299a bne 0x62a64 | goto label_9;
| }
0x0006299c ldr r3, [sp, 0x174] | r3 = var_174h;
0x0006299e ands r5, r3, 0x40 | r5 = r3 & 0x40;
| if (r5 == r3) {
0x000629a2 beq 0x629b8 | goto label_3;
| }
0x000629a4 ldr r3, [pc, 0x1b0] |
0x000629a6 mrc p15, 0, r8, c13, c0, 3 | __asm ("mrc p15, 0, r8, c13, c0, 3");
0x000629aa add r3, pc |
0x000629ac ldr r3, [r3] | r3 = *(0xc5506);
0x000629ae ldr.w r3, [r8, r3] | r3 = *((r8 + r3));
0x000629b2 cmp r3, 2 |
0x000629b4 beq 0x629ce |
| while (r3 != 0x11) {
| label_1:
0x000629b6 movs r5, 0 | r5 = 0;
| label_3:
0x000629b8 ldr.w r0, [fp] | r0 = *(fp);
0x000629bc movs r1, 0 | r1 = 0;
0x000629be bl 0x62128 | pthread_setcancelstate ();
| label_2:
0x000629c2 mov r0, r5 | r0 = r5;
0x000629c4 add sp, 0x150 |
0x000629c6 pop.w {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000629ca add sp, 0xc |
0x000629cc bx lr | return;
| label_8:
0x000629ce ldr r3, [sp, 0x17c] | r3 = var_17ch;
0x000629d0 add r2, sp, 0x178 | r2 += var_178h;
0x000629d2 ldr.w sl, [sp, 0x178] | sl = var_178h;
0x000629d6 str r2, [sp, 0x18] | var_18h = r2;
0x000629d8 cmp r3, 0 |
| if (r3 < 0) {
0x000629da blt 0x62a96 | goto label_10;
| }
0x000629dc lsls r3, r3, 1 | r3 <<= 1;
0x000629de ldr.w ip, [pc, 0x19c] |
0x000629e2 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x000629e6 ldr.w r8, [pc, 0x198] | r8 = *(0x00062b80);
0x000629ea str r3, [sp, 0x1c] | var_1ch = r3;
0x000629ec movs r3, 0 | r3 = 0;
0x000629ee str r2, [sp, 8] | var_8h = r2;
0x000629f0 add ip, pc | ip = 0xc5572;
0x000629f2 add r2, sp, 0x1c | r2 += var_1ch;
0x000629f4 strd r3, r3, [sp, 0x24] | __asm ("strd r3, r3, [var_24h]");
0x000629f8 movs r3, 0x80 | r3 = 0x80;
0x000629fa str r2, [sp, 0xc] | var_ch = r2;
0x000629fc str r3, [sp, 0x20] | var_20h = r3;
0x000629fe add r6, sp, 0x2c | r6 += fildes;
0x00062a00 ldm.w ip!, {r0, r1, r2, r3} | r0 = *(ip!);
| r1 = *((ip! + 4));
| r2 = *((ip! + 8));
| r3 = *((ip! + 12));
0x00062a04 mov r4, r6 | r4 = r6;
0x00062a06 add r8, pc | r8 += pc;
0x00062a08 movs r5, 0x32 | r5 = 0x32;
0x00062a0a stm r4!, {r0, r1, r2, r3} | *(r4!) = r0;
| *((r4! + 4)) = r1;
| *((r4! + 8)) = r2;
| *((r4! + 12)) = r3;
0x00062a0c ldr.w r3, [ip] | r3 = *(0xc5572);
0x00062a10 str r3, [r4] | *(r4) = r3;
0x00062a12 ldr r4, [sp, 8] | r4 = var_8h;
0x00062a14 b 0x62a3e | goto label_11;
| label_0:
0x00062a16 bl 0x9f428 | open (r0, r1, r2);
0x00062a1a adds r1, r0, 1 | r1 += var_1h;
0x00062a1c ldr r3, [pc, 0x13c] | r3 = *(0x62b5c);
0x00062a1e add.w r2, sp, 0x39 | r2 += var_39h;
| if (r1 != var_1h) {
0x00062a22 bne 0x62aa6 | goto label_12;
| }
0x00062a24 add r3, pc | r3 += pc;
0x00062a26 ldr r3, [r3] | r3 = *(r3);
0x00062a28 ldr r3, [r4, r3] | r3 = *((r4 + r3));
0x00062a2a cmp r3, 0x11 |
0x00062a2c bne 0x629b6 |
| }
0x00062a2e subs r5, 1 | r5--;
| if (r5 == 1) {
0x00062a30 beq 0x62b2a | goto label_13;
| }
0x00062a32 ldr.w r0, [r8] | r0 = *(r8);
0x00062a36 ldrh.w r3, [r8, 4] | r3 = *((r8 + 4));
0x00062a3a str r0, [r2] | *(r2) = r0;
0x00062a3c strh r3, [r2, 4] | var_4h_2 = r3;
| label_11:
0x00062a3e mov r0, r6 | r0 = r6;
0x00062a40 bl 0xa8348 | r0 = mktemp ();
0x00062a44 mov r3, r0 | r3 = r0;
0x00062a46 mov r2, sl | r2 = sl;
0x00062a48 movs r1, 0xc2 | r1 = 0xc2;
0x00062a4a mov r0, r6 | r0 = r6;
0x00062a4c cmp r3, 0 |
| if (r3 != 0) {
0x00062a4e bne 0x62a16 | goto label_0;
| }
0x00062a50 b 0x629b6 | goto label_1;
| label_7:
0x00062a52 ldr r3, [pc, 0x10c] |
0x00062a54 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x00062a58 movs r1, 0x16 | r1 = 0x16;
0x00062a5a movs r5, 0 | r5 = 0;
0x00062a5c add r3, pc |
0x00062a5e ldr r3, [r3] | r3 = *(0xc55c2);
0x00062a60 str r1, [r2, r3] | *((r2 + r3)) = r1;
0x00062a62 b 0x629c2 | goto label_2;
| label_9:
0x00062a64 movs r2, 0 | r2 = 0;
0x00062a66 mov r1, r4 | r1 = r4;
0x00062a68 mov r0, r7 | r0 = r7;
0x00062a6a mrc p15, 0, r8, c13, c0, 3 | __asm ("mrc p15, 0, r8, c13, c0, 3");
0x00062a6e bl 0x62c54 | r0 = fcn_00062c54 (r0, r1, r2);
0x00062a72 mov r5, r0 | r5 = r0;
| label_5:
0x00062a74 adds r3, r5, 1 | r3 = r5 + 1;
0x00062a76 it eq |
| if (r3 != r5) {
0x00062a78 moveq r5, 0 | r5 = 0;
| }
| label_4:
0x00062a7a ldr r3, [pc, 0xe8] |
0x00062a7c mov r0, r4 | r0 = r4;
0x00062a7e add r3, pc |
0x00062a80 ldr r3, [r3] | r3 = *(0xc55e8);
0x00062a82 ldr.w r4, [r8, r3] | r4 = *((r8 + r3));
0x00062a86 bl 0x9ff60 | close (r0);
0x00062a8a ldr r3, [pc, 0xdc] |
0x00062a8c add r3, pc |
0x00062a8e ldr r3, [r3] | r3 = *(0xc55fa);
0x00062a90 str.w r4, [r8, r3] | __asm ("str.w r4, [r8, r3]");
0x00062a94 b 0x629b8 | goto label_3;
| label_10:
0x00062a96 ldr r3, [pc, 0xd4] |
0x00062a98 mrc p15, 0, r2, c13, c0, 3 | __asm ("mrc p15, 0, r2, c13, c0, 3");
0x00062a9c movs r1, 0x16 | r1 = 0x16;
0x00062a9e add r3, pc |
0x00062aa0 ldr r3, [r3] | r3 = *(0xc5610);
0x00062aa2 str r1, [r2, r3] | *((r2 + r3)) = r1;
0x00062aa4 b 0x629b6 | goto label_1;
| label_12:
0x00062aa6 ldr r5, [sp, 0xc] | r5 = var_ch;
0x00062aa8 mov r4, r0 | r4 = r0;
0x00062aaa mrc p15, 0, r8, c13, c0, 3 | __asm ("mrc p15, 0, r8, c13, c0, 3");
0x00062aae b 0x62abc |
| while (r2 == var_1h) {
0x00062ab0 add r3, pc | r3 += pc;
0x00062ab2 ldr r3, [r3] | r3 = *(r3);
0x00062ab4 ldr.w r3, [r8, r3] | r3 = *((r8 + r3));
0x00062ab8 cmp r3, 4 |
| if (r3 != 4) {
0x00062aba bne 0x62b20 | goto label_14;
| }
0x00062abc movs r2, 0x10 | r2 = 0x10;
0x00062abe mov r1, r5 | r1 = r5;
0x00062ac0 mov r0, r4 | r0 = r4;
0x00062ac2 bl 0x9f800 | write (r0, r1, r2);
0x00062ac6 adds r2, r0, 1 | r2 += var_1h;
0x00062ac8 ldr r3, [pc, 0xa4] | r3 = *(0x62b70);
0x00062aca beq 0x62ab0 |
| }
0x00062acc cmp r0, 0x10 |
0x00062ace mov r5, r0 | r5 = r0;
| if (r0 == 0x10) {
0x00062ad0 bne 0x62b20 |
0x00062ad2 mov.w sl, 0 | sl = 0;
0x00062ad6 mov r1, r0 | r1 = r0;
0x00062ad8 movs r3, 1 | r3 = 1;
0x00062ada movs r2, 3 | r2 = 3;
0x00062adc mov r0, sl | r0 = sl;
0x00062ade str r4, [sp] | *(sp) = r4;
0x00062ae0 str.w sl, [sp, 4] | __asm ("str.w sl, [var_4h]");
0x00062ae4 bl 0xa9f88 | r0 = mmap ()
0x00062ae8 adds r1, r0, 1 | r1 = r0 + 1;
| if (r1 == r0) {
0x00062aea beq 0x62b20 | goto label_14;
| }
0x00062aec str r0, [sp, 8] | var_8h = r0;
0x00062aee mov r1, sb | r1 = sb;
0x00062af0 mov r0, r6 | r0 = r6;
0x00062af2 bl 0xa0a40 | link ();
0x00062af6 ldr r2, [sp, 8] | r2 = var_8h;
| if (r0 == 0) {
0x00062af8 cbz r0, 0x62b38 | goto label_15;
| }
0x00062afa mov r1, r5 | r1 = r5;
0x00062afc mov r0, r2 | r0 = r2;
0x00062afe bl 0xaa040 | munmap ();
0x00062b02 ldr r3, [sp, 0x174] | r3 = var_174h;
0x00062b04 ands r5, r3, 0x80 | r5 = r3 & 0x80;
| if (r5 != r3) {
0x00062b08 bne 0x62b20 | goto label_14;
| }
0x00062b0a ldr r3, [pc, 0x68] |
0x00062b0c mov r0, r6 | r0 = r6;
0x00062b0e add r3, pc |
0x00062b10 ldr r3, [r3] | r3 = *(0xc5688);
0x00062b12 ldr.w r3, [r8, r3] | r3 = *((r8 + r3));
0x00062b16 cmp r3, 0x11 |
| if (r3 == 0x11) {
0x00062b18 beq 0x62b4a | goto label_16;
| }
0x00062b1a bl 0xa0b00 | unlink ();
0x00062b1e b 0x62a7a | goto label_4;
| }
| label_14:
0x00062b20 mov r0, r6 | r0 = r6;
0x00062b22 movs r5, 0 | r5 = 0;
0x00062b24 bl 0xa0b00 | unlink ();
0x00062b28 b 0x62a7a | goto label_4;
| label_13:
0x00062b2a ldr r3, [pc, 0x4c] |
0x00062b2c movs r2, 0xb | r2 = 0xb;
0x00062b2e ldr r1, [sp, 8] | r1 = var_8h;
0x00062b30 add r3, pc |
0x00062b32 ldr r3, [r3] | r3 = *(0xc56ae);
0x00062b34 str r2, [r1, r3] | *((r1 + r3)) = r2;
0x00062b36 b 0x629b6 | goto label_1;
| label_15:
0x00062b38 mov r0, r7 | r0 = r7;
0x00062b3a mov r1, r4 | r1 = r4;
0x00062b3c bl 0x62c54 | r0 = fcn_00062c54 (r0, r1, r2);
0x00062b40 mov r5, r0 | r5 = r0;
0x00062b42 mov r0, r6 | r0 = r6;
0x00062b44 bl 0xa0b00 | unlink ();
0x00062b48 b 0x62a74 | goto label_5;
| label_16:
0x00062b4a bl 0xa0b00 | unlink ();
0x00062b4e mov r0, r4 | r0 = r4;
0x00062b50 bl 0x9ff60 | close (r0);
0x00062b54 b 0x6297e | goto label_6;
| }
[*] Function mmap used 20 times libc.so.6