[*] Binary protection state of KT-1
Partial RELRO No Canary found NX disabled No PIE No RPATH No RUNPATH No Symbols
[*] Function printf tear down of KT-1
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x3ed84 */
| #include <stdint.h>
|
; (fcn) fcn.0003ed84 () | void fcn_0003ed84 (int32_t arg1) {
| int32_t var_0h;
| int32_t var_0h_2;
| int32_t var_8h;
| int32_t var_14h;
| int32_t var_30h;
| r0 = arg1;
0x0003ed84 push {r4, r5, r6, r7, r8, lr} |
0x0003ed88 add r7, r0, 0x42000 | r7 = r0 + 0x42000;
0x0003ed8c ldr r3, [r7, 0xf4c] | r3 = *((r7 + 0xf4c));
0x0003ed90 sub sp, sp, 0x30 |
0x0003ed94 mov r2, 0 | r2 = 0;
0x0003ed98 mov r1, 0xa | r1 = 0xa;
0x0003ed9c mov r6, r0 | r6 = r0;
0x0003eda0 ldr r4, [r3] | r4 = *(r3);
0x0003eda4 bl 0x39b10 | fcn_00039b10 (r0, r1);
0x0003eda8 add r5, sp, 0x14 | r5 += var_14h;
0x0003edac mov r0, r6 | r0 = r6;
0x0003edb0 bl 0x3cfc8 | fcn_0003cfc8 (r0);
0x0003edb4 mov r0, r5 | r0 = r5;
0x0003edb8 bl 0x3a8cc | fcn_0003a8cc (r0);
0x0003edbc mov r0, r5 | r0 = r5;
0x0003edc0 bl 0x3eb30 | r0 = fcn_0003eb30 (r0);
0x0003edc4 mov r1, r0 | r1 = r0;
0x0003edc8 ldr r0, [pc, 0x138] | r0 = *(0x3ef04);
0x0003edcc add r0, pc, r0 | r0 = pc + r0;
0x0003edd0 bl 0x17750 | printf (r0, r1)
0x0003edd4 mov r0, r5 | r0 = r5;
0x0003edd8 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x0003eddc cmp r4, 0 |
| if (r4 != 0) {
0x0003ede0 beq 0x3eec8 |
0x0003ede4 mov r0, 0xc | r0 = 0xc;
0x0003ede8 bl 0x1769c | r0 = sym ();
0x0003edec mov r5, r0 | r5 = r0;
0x0003edf0 bl 0x8580c | fcn_0008580c ();
0x0003edf4 b 0x3ee0c |
0x0003ee0c bl 0xc4634 | r0 = fcn_000c4634 ();
0x0003ee10 mov r8, r0 | r8 = r0;
0x0003ee14 mov r1, r4 | r1 = r4;
0x0003ee18 mov r0, r5 | r0 = r5;
0x0003ee1c bl 0x85d88 | fcn_00085d88 (r0);
0x0003ee20 b 0x3ee2c |
0x0003ee2c cmp r0, 0 |
| if (r0 == 0) {
0x0003ee30 movne r4, 0 | r4 = 0;
| }
| if (r0 == 0) {
0x0003ee34 bne 0x3eeb4 |
0x0003ee38 bl 0xc4634 | fcn_000c4634 ();
0x0003ee3c b 0x3ee44 |
0x0003ee44 sub r1, r0, r8 | r1 = r0 - r8;
0x0003ee48 ldr r0, [pc, 0xbc] | r0 = *(0x3ef08);
0x0003ee4c add r0, pc, r0 | r0 = pc + r0;
0x0003ee50 bl 0x17750 | printf (r0, r1)
0x0003ee54 b 0x3ee64 |
0x0003ee64 add r3, r6, 0x43000 | r3 = r6 + 0x43000;
0x0003ee68 mov r1, 0x27 | r1 = 0x27;
0x0003ee6c ldr r0, [r3, 0x8ec] | r0 = *((r3 + 0x8ec));
0x0003ee70 bl 0x86d74 | fcn_00086d74 (r0);
0x0003ee74 b 0x3ee7c |
0x0003ee7c mov r3, 0 | r3 = 0;
0x0003ee80 mov r2, 0 | r2 = 0;
0x0003ee84 str r3, [sp, 8] | var_8h = r3;
0x0003ee88 mov r3, 0 | r3 = 0;
0x0003ee8c strd r2, r3, [sp] | __asm ("strd r2, r3, [sp]");
0x0003ee90 mov r1, 0x19 | r1 = 0x19;
0x0003ee94 mov r2, 3 | r2 = 3;
0x0003ee98 mov r0, r6 | r0 = r6;
0x0003ee9c bl 0x3b718 | fcn_0003b718 (r0, r1, r2, r3);
0x0003eea0 b 0x3eea8 |
0x0003eea8 mov r4, 1 | r4 = 1;
0x0003eeac cmp r5, 0 |
| if (r5 == 0) {
0x0003eeb0 beq 0x3eec8 | goto label_0;
| }
| }
0x0003eeb4 mov r0, r5 | r0 = r5;
0x0003eeb8 bl 0x85810 | fcn_00085810 ();
0x0003eebc mov r1, 0xc | r1 = 0xc;
0x0003eec0 mov r0, r5 | r0 = r5;
0x0003eec4 bl 0x17c48 | sym ();
| }
| label_0:
0x0003eec8 ldr r0, [r7, 0xf4c] | r0 = *((r7 + 0xf4c));
0x0003eecc bl 0x5608c | fcn_0005608c (r0);
0x0003eed0 mov r0, r4 | r0 = r4;
0x0003eed4 add sp, sp, 0x30 |
0x0003eed8 pop {r4, r5, r6, r7, r8, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x3ef10 */
| #include <stdint.h>
|
; (fcn) fcn.0003ef10 () | void fcn_0003ef10 (int32_t arg1) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_20h;
| r0 = arg1;
0x0003ef10 push {r4, r5, r6, lr} |
0x0003ef14 sub sp, sp, 0x20 |
0x0003ef18 add r5, sp, 4 | r5 += var_4h;
0x0003ef1c mov r6, r0 | r6 = r0;
0x0003ef20 mov r0, r5 | r0 = r5;
0x0003ef24 bl 0x3a8cc | fcn_0003a8cc (r0);
0x0003ef28 mov r0, r5 | r0 = r5;
0x0003ef2c bl 0x3eb30 | fcn_0003eb30 (r0);
0x0003ef30 b 0x3ef40 |
0x0003ef40 mov r4, r0 | r4 = r0;
0x0003ef44 mov r0, r5 | r0 = r5;
0x0003ef48 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x0003ef4c ldr r0, [pc, 0x20] | r0 = *(0x3ef70);
0x0003ef50 mov r2, r6 | r2 = r6;
0x0003ef54 mov r1, r4 | r1 = r4;
0x0003ef58 add r0, pc, r0 | r0 = pc + r0;
0x0003ef5c bl 0x17750 | printf (r0, r1, r2)
0x0003ef60 sub r0, r4, r6 | r0 = r4 - r6;
0x0003ef64 clz r0, r0 | r0 &= r0;
0x0003ef68 lsr r0, r0, 5 | r0 >>= 5;
0x0003ef6c add sp, sp, 0x20 |
0x0003ef70 pop {r4, r5, r6, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x40120 */
| #include <stdint.h>
|
; (fcn) fcn.00040120 () | void fcn_00040120 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_0h_2;
| int32_t var_8h;
| int32_t var_14h;
| int32_t var_34h;
| r0 = arg1;
| r1 = arg2;
0x00040120 push {r4, r5, r6, r7, r8, sb, lr} |
0x00040124 mov r2, 0 | r2 = 0;
0x00040128 sub sp, sp, 0x34 |
0x0004012c mov r7, r0 | r7 = r0;
0x00040130 mov r5, r1 | r5 = r1;
0x00040134 mov r1, 0xa | r1 = 0xa;
0x00040138 bl 0x39b10 | fcn_00039b10 (r0, r1);
0x0004013c add r4, sp, 0x14 | r4 += var_14h;
0x00040140 mov r0, r7 | r0 = r7;
0x00040144 bl 0x3cfc8 | fcn_0003cfc8 (r0);
0x00040148 mov r0, r4 | r0 = r4;
0x0004014c bl 0x3a8cc | fcn_0003a8cc (r0);
0x00040150 mov r0, r4 | r0 = r4;
0x00040154 bl 0x3eb30 | r0 = fcn_0003eb30 (r0);
0x00040158 mov r1, r0 | r1 = r0;
0x0004015c ldr r0, [pc, 0x174] | r0 = *(0x402d4);
0x00040160 add r0, pc, r0 | r0 = pc + r0;
0x00040164 bl 0x17750 | printf (r0, r1)
0x00040168 add r6, r7, 0x42000 | r6 = r7 + 0x42000;
0x0004016c mov r0, r4 | r0 = r4;
0x00040170 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x00040174 mov r1, 1 | r1 = 1;
0x00040178 ldr r0, [r6, 0xf3c] | r0 = *((r6 + 0xf3c));
0x0004017c bl 0x894ac | fcn_000894ac (r0, r1);
0x00040180 ldr r0, [r6, 0xf3c] | r0 = *((r6 + 0xf3c));
0x00040184 bl 0x89400 | r0 = fcn_00089400 (r0);
0x00040188 bl 0x3ffc4 | fcn_0003ffc4 ();
0x0004018c add r8, r7, 0x43000 | r8 = r7 + 0x43000;
0x00040190 cmp r0, 0 |
| if (r0 == 0) {
0x00040194 beq 0x4029c | goto label_0;
| }
0x00040198 mov r0, 0xc | r0 = 0xc;
0x0004019c bl 0x1769c | r0 = sym ();
0x000401a0 mov r4, r0 | r4 = r0;
0x000401a4 bl 0x8580c | fcn_0008580c ();
0x000401a8 b 0x401b4 |
0x000401b4 cmp r5, 0 |
| if (r5 == 0) {
0x000401b8 beq 0x4029c | goto label_0;
| }
0x000401bc bl 0xc4634 | r0 = fcn_000c4634 ();
0x000401c0 mov sb, r0 | sb = r0;
0x000401c4 mov r1, r5 | r1 = r5;
0x000401c8 mov r0, r4 | r0 = r4;
0x000401cc bl 0x858d0 | fcn_000858d0 (r0);
0x000401d0 b 0x40200 |
0x00040200 clz r5, r0 | r5 &= r0;
0x00040204 lsr r5, r5, 5 | r5 >>= 5;
0x00040208 bl 0xc4634 | fcn_000c4634 ();
0x0004020c b 0x40214 |
0x00040214 sub r1, r0, sb | r1 = r0 - sb;
0x00040218 ldr r0, [pc, 0xbc] | r0 = *(0x402d8);
0x0004021c add r0, pc, r0 | r0 = pc + r0;
0x00040220 bl 0x17750 | printf (r0, r1)
0x00040224 mov r0, r4 | r0 = r4;
0x00040228 bl 0x85810 | fcn_00085810 ();
0x0004022c mov r1, 0xc | r1 = 0xc;
0x00040230 mov r0, r4 | r0 = r4;
0x00040234 bl 0x17c48 | sym ();
0x00040238 cmp r5, 0 |
| if (r5 == 0) {
0x0004023c beq 0x4029c | goto label_0;
| }
0x00040240 mov r1, 0x2b | r1 = 0x2b;
0x00040244 ldr r0, [r8, 0x8ec] | r0 = *((r8 + 0x8ec));
0x00040248 bl 0x86d74 | fcn_00086d74 (r0);
| do {
0x0004024c ldr r0, [r6, 0xf4c] | r0 = *((r6 + 0xf4c));
0x00040250 bl 0x5608c | fcn_0005608c (r0);
0x00040254 mov r4, 0 | r4 = 0;
0x00040258 mov r3, 0 | r3 = 0;
0x0004025c mov r2, 0 | r2 = 0;
0x00040260 strd r2, r3, [sp] | __asm ("strd r2, r3, [sp]");
0x00040264 mov r0, r7 | r0 = r7;
0x00040268 mov r2, 3 | r2 = 3;
0x0004026c str r4, [sp, 8] | var_8h = r4;
0x00040270 mov r1, 0x19 | r1 = 0x19;
0x00040274 bl 0x3b718 | fcn_0003b718 (r0, r1, r2, r3);
0x00040278 ldr r0, [r6, 0xf3c] | r0 = *((r6 + 0xf3c));
0x0004027c ldr r1, [r0] | r1 = *(r0);
0x00040280 bl 0x89398 | fcn_00089398 (r0, r1);
0x00040284 mov r1, r4 | r1 = r4;
0x00040288 ldr r0, [r6, 0xf3c] | r0 = *((r6 + 0xf3c));
0x0004028c bl 0x893c8 | fcn_000893c8 (r0, r1);
0x00040290 mov r0, r5 | r0 = r5;
0x00040294 add sp, sp, 0x34 |
0x00040298 pop {r4, r5, r6, r7, r8, sb, pc} |
| label_0:
0x0004029c mov r1, 0x2c | r1 = 0x2c;
0x000402a0 ldr r0, [r8, 0x8ec] | r0 = *((r8 + 0x8ec));
0x000402a4 bl 0x86d74 | fcn_00086d74 (r0);
0x000402a8 mov r5, 0 | r5 = 0;
0x000402ac b 0x4024c |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x425a4 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.000425a4 () | void fcn_000425a4 (int32_t arg1) {
| int32_t var_0h;
| int32_t var_28h;
| int32_t var_2bh;
| int32_t var_5ch_2;
| int32_t var_30h;
| int32_t var_31h;
| int32_t var_32h;
| int32_t var_33h;
| int32_t var_30h_2;
| int32_t var_3ch;
| int32_t var_40h;
| int32_t var_58h;
| int32_t var_5ch;
| int32_t var_28h_2;
| int32_t var_61h;
| int32_t var_88h;
| r0 = arg1;
0x000425a4 push {r4, r5, r6, r7, r8, sb, sl, lr} |
0x000425a8 add r6, r0, 0x43000 | r6 = r0 + 0x43000;
0x000425ac sub sp, sp, 0x88 |
0x000425b0 mov r4, r0 | r4 = r0;
0x000425b4 ldr r0, [r6, 0x8ec] | r0 = *((r6 + 0x8ec));
0x000425b8 bl 0x8639c | fcn_0008639c (r0);
0x000425bc add r8, sp, 0x3c | r8 += var_3ch;
0x000425c0 mov sb, r0 | sb = r0;
0x000425c4 mov r0, r8 | r0 = r8;
0x000425c8 bl 0x1bae8 | fcn_0001bae8 (r0);
0x000425cc mov r3, 8 | r3 = 8;
0x000425d0 mov r2, 0 | r2 = 0;
0x000425d4 mov r1, r3 | r1 = r3;
0x000425d8 add r0, sp, 0x30 | r0 += var_30h;
0x000425dc strb r2, [sp, 0x2b] | var_2bh = r2;
0x000425e0 bl 0xb9f54 | fcn_000b9f54 (r0, r1);
0x000425e4 mov r3, 1 | r3 = 1;
0x000425e8 mov r2, 0 | r2 = 0;
0x000425ec mov r1, r3 | r1 = r3;
0x000425f0 add r0, sp, 0x28 | r0 += var_28h;
0x000425f4 bl 0xb9f54 | fcn_000b9f54 (r0, r1);
0x000425f8 add r7, r4, 0x42000 | r7 = r4 + 0x42000;
0x000425fc ldr r0, [r7, 0xf3c] | r0 = *((r7 + 0xf3c));
0x00042600 bl 0x88fb0 | fcn_00088fb0 (r0);
0x00042604 cmp sb, 0 |
0x00042608 strb r0, [sp, 0x28] | var_28h = r0;
0x0004260c add r5, sp, 0x58 | r5 += var_58h;
| if (sb == 0) {
0x00042610 beq 0x42768 | goto label_8;
| }
0x00042614 ldr r0, [r6, 0x8e4] | r0 = *((r6 + 0x8e4));
0x00042618 bl 0x640c0 | r0 = fcn_000640c0 ();
0x0004261c cmp r0, 0 |
| if (r0 != 0) {
0x00042620 bne 0x42758 | goto label_9;
| }
0x00042624 add r1, sp, 0x2b | r1 += var_2bh;
0x00042628 mov r0, r4 | r0 = r4;
0x0004262c bl 0x41a28 | r0 = fcn_00041a28 (r0, r1);
0x00042630 cmp r0, 0 |
| if (r0 != 0) {
0x00042634 beq 0x4271c |
0x00042638 ldrb r3, [sp, 0x28] | r3 = var_28h;
0x0004263c tst r3, 0x10 |
| if ((r3 & 0x10) != 0) {
0x00042640 beq 0x42670 |
0x00042644 ldr r0, [pc, 0x464] | r0 = *(0x42aac);
0x00042648 add r0, pc, r0 | r0 = pc + r0;
0x0004264c bl 0x183e0 | basename (r0);
0x00042650 ldr r1, [pc, 0x45c] |
0x00042654 ldr r3, [pc, 0x45c] | r3 = *(0x42ab4);
0x00042658 add r1, pc, r1 | r1 = pc + r1;
0x0004265c add r3, pc, r3 | r3 = pc + r3;
0x00042660 mov r2, 4 | r2 = 4;
0x00042664 add r1, r1, 0x63 | r1 = 0x42b13;
0x00042668 bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x0004266c b 0x428c4 | goto label_10;
| }
0x00042670 tst r3, 8 |
| if ((r3 & 8) != 0) {
0x00042674 beq 0x42684 |
0x00042678 ldrb r3, [r4, 0x13] | r3 = *((r4 + 0x13));
0x0004267c tst r3, 2 |
| if ((r3 & 2) == 0) {
0x00042680 beq 0x426b8 | goto label_11;
| }
| }
0x00042684 ldr r0, [pc, 0x430] | r0 = *(0x42ab8);
0x00042688 mov r3, 0 | r3 = 0;
0x0004268c str r3, [r4, 0x18] | *((r4 + 0x18)) = r3;
0x00042690 add r0, pc, r0 | r0 = pc + r0;
0x00042694 bl 0x183e0 | basename (r0);
0x00042698 ldr r1, [pc, 0x420] |
0x0004269c ldr r3, [pc, 0x420] | r3 = *(0x42ac0);
0x000426a0 add r1, pc, r1 | r1 = pc + r1;
0x000426a4 add r3, pc, r3 | r3 = pc + r3;
0x000426a8 mov r2, 4 | r2 = 4;
0x000426ac add r1, r1, 0x63 | r1 = 0x42b1f;
0x000426b0 bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x000426b4 b 0x42890 | goto label_12;
| label_11:
0x000426b8 ands r3, r3, 4 | r3 &= 4;
| if (r3 != r3) {
0x000426bc beq 0x426ec |
0x000426c0 ldr r0, [pc, 0x400] | r0 = *(0x42ac4);
0x000426c4 add r0, pc, r0 | r0 = pc + r0;
0x000426c8 bl 0x183e0 | basename (r0);
0x000426cc ldr r1, [pc, 0x3f8] |
0x000426d0 ldr r3, [pc, 0x3f8] | r3 = "_";
0x000426d4 add r1, pc, r1 | r1 = pc + r1;
0x000426d8 add r3, pc, r3 | r3 = pc + r3;
0x000426dc mov r2, 4 | r2 = 4;
0x000426e0 add r1, r1, 0x63 | r1 = 0x42b2b;
0x000426e4 bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x000426e8 b 0x428dc | goto label_13;
| }
0x000426ec ldr r0, [pc, 0x3e0] | r0 = *(0x42ad0);
0x000426f0 str r3, [r4, 0x18] | *((r4 + 0x18)) = r3;
0x000426f4 add r0, pc, r0 | r0 = pc + r0;
0x000426f8 bl 0x183e0 | basename (r0);
0x000426fc ldr r1, [pc, 0x3d4] |
0x00042700 ldr r3, [pc, 0x3d4] | r3 = *(0x42ad8);
0x00042704 add r1, pc, r1 | r1 = pc + r1;
0x00042708 add r3, pc, r3 | r3 = pc + r3;
0x0004270c mov r2, 4 | r2 = 4;
0x00042710 add r1, r1, 0x63 | r1 = 0x42b37;
0x00042714 bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x00042718 b 0x428f4 | goto label_14;
| }
0x0004271c ldr r0, [pc, 0x3bc] | r0 = *(0x42adc);
0x00042720 ldrb r1, [sp, 0x2b] | r1 = var_2bh;
0x00042724 add r0, pc, r0 | r0 = pc + r0;
0x00042728 bl 0x17750 | printf (r0, r1)
| do {
0x0004272c ldrb r3, [r4, 0x12] | r3 = *((r4 + 0x12));
0x00042730 ldr r1, [pc, 0x3ac] | r1 = *(0x42ae0);
0x00042734 orr r3, r3, 0x40 | r3 |= 0x40;
0x00042738 strb r3, [r4, 0x12] | *((r4 + 0x12)) = r3;
0x0004273c ldrb r3, [sp, 0x32] | r3 = var_32h;
0x00042740 add r1, pc, r1 | r1 = pc + r1;
0x00042744 orr r3, r3, 0x40 | r3 |= 0x40;
0x00042748 mov r0, r5 | r0 = r5;
0x0004274c strb r3, [sp, 0x32] | var_32h = r3;
0x00042750 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x00042754 b 0x42774 | goto label_15;
| label_9:
0x00042758 ldr r0, [pc, 0x388] | r0 = *(0x42ae4);
0x0004275c add r0, pc, r0 | r0 = pc + r0;
| label_0:
0x00042760 bl 0x179b4 | puts (r0);
0x00042764 b 0x4272c |
| } while (1);
| label_8:
0x00042768 ldr r0, [pc, 0x37c] | r0 = *(0x42ae8);
0x0004276c add r0, pc, r0 | r0 = pc + r0;
0x00042770 b 0x42760 | goto label_0;
| label_15:
0x00042774 add r1, sp, 0x5c | r1 += var_5ch;
0x00042778 add r0, sp, 0x40 | r0 += var_40h;
0x0004277c bl 0x1d84c | method (r0, r1);
0x00042780 mov r0, r5 | r0 = r5;
0x00042784 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x00042788 mov r0, r8 | r0 = r8;
0x0004278c bl 0x1bb20 | fcn_0001bb20 (r0);
0x00042790 add r1, sp, 0x88 | r1 += var_88h;
0x00042794 str r0, [r1, -0x5c]! | *((r1 -= 0x5c)) = r0;
0x00042798 mov r0, r5 | r0 = r5;
0x0004279c bl 0x290f0 | fcn_000290f0 (r0, r1);
0x000427a0 mov r0, r5 | r0 = r5;
0x000427a4 bl 0x28ec8 | r0 = fcn_00028ec8 (r0);
0x000427a8 mov sl, r0 | sl = r0;
0x000427ac mov r0, r5 | r0 = r5;
0x000427b0 bl 0x1b9b4 | fcn_0001b9b4 (r0);
0x000427b4 mov r0, r4 | r0 = r4;
0x000427b8 bl 0x3d358 | fcn_0003d358 (r0);
0x000427bc mov r3, 0x28 | r3 = 0x28;
0x000427c0 add r0, r4, 0x61000 | r0 = r4 + 0x61000;
0x000427c4 mov r2, 0 | r2 = 0;
0x000427c8 mov r1, r3 | r1 = r3;
0x000427cc add r0, r0, 0x68 | r0 += 0x68;
0x000427d0 bl 0xb9f54 | fcn_000b9f54 (r0, r1);
0x000427d4 ldr r0, [r6, 0x904] | r0 = *((r6 + 0x904));
0x000427d8 cmp r0, 0 |
0x000427dc bne 0x427ec |
| while (1) {
0x000427e0 mov r0, r4 | r0 = r4;
0x000427e4 bl 0x3a9fc | fcn_0003a9fc (r0);
0x000427e8 b 0x427f4 | goto label_16;
0x000427ec bl 0x8017c | fcn_0008017c (r0);
0x000427f0 b 0x427e0 |
| }
| label_16:
0x000427f4 and sb, sb, sl | sb &= sl;
0x000427f8 tst sb, 0xff |
0x000427fc beq 0x42838 |
| while (1) {
0x00042800 ldr r0, [r6, 0x900] | r0 = *((r6 + 0x900));
0x00042804 cmp r0, 0 |
| if (r0 != 0) {
0x00042808 bne 0x42844 | goto label_17;
| }
| label_1:
0x0004280c ldr r0, [pc, 0x2dc] | r0 = *(0x42aec);
0x00042810 add r0, pc, r0 | r0 = pc + r0;
0x00042814 bl 0x183e0 | basename (r0);
0x00042818 ldr r3, [pc, 0x2d4] | r3 = *(0x42af0);
0x0004281c ldr r1, [pc, 0x2d4] | r1 = *(0x42af4);
0x00042820 add r3, pc, r3 | r3 = pc + r3;
0x00042824 mov r2, 4 | r2 = 4;
0x00042828 add r1, pc, r1 | r1 = pc + r1;
| label_2:
0x0004282c add r1, r1, 0x63 | r1 += 0x63;
0x00042830 bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x00042834 b 0x428a8 | goto label_18;
0x00042838 mov r0, r4 | r0 = r4;
0x0004283c bl 0x3abec | fcn_0003abec ();
0x00042840 b 0x42800 |
| }
| label_17:
0x00042844 bl 0x66ce8 | r0 = fcn_00066ce8 (r0);
0x00042848 cmp r0, 0 |
| if (r0 != 0) {
0x0004284c bne 0x4280c | goto label_1;
| }
0x00042850 ldrb r3, [r4, 0x12] | r3 = *((r4 + 0x12));
0x00042854 ldr r0, [pc, 0x2a0] | r0 = *(0x42af8);
0x00042858 orr r3, r3, 0x80 | r3 |= 0x80;
0x0004285c strb r3, [r4, 0x12] | *((r4 + 0x12)) = r3;
0x00042860 ldrb r3, [sp, 0x32] | r3 = var_32h;
0x00042864 add r0, pc, r0 | r0 = pc + r0;
0x00042868 orr r3, r3, 0x80 | r3 |= 0x80;
0x0004286c bic r3, r3, 0x40 | r3 = BIT_MASK (r3, 0x40);
0x00042870 strb r3, [sp, 0x32] | var_32h = r3;
0x00042874 bl 0x183e0 | basename (r0);
0x00042878 ldr r3, [pc, 0x280] | r3 = *(0x42afc);
0x0004287c ldr r1, [pc, 0x280] | r1 = *(0x42b00);
0x00042880 add r3, pc, r3 | r3 = pc + r3;
0x00042884 mov r2, 4 | r2 = 4;
0x00042888 add r1, pc, r1 | r1 = pc + r1;
0x0004288c b 0x4282c | goto label_2;
| label_12:
0x00042890 ldrb r3, [r4, 0x13] | r3 = *((r4 + 0x13));
0x00042894 orr r3, r3, 2 | r3 |= 2;
0x00042898 strb r3, [r4, 0x13] | *((r4 + 0x13)) = r3;
0x0004289c ldrb r3, [sp, 0x33] | r3 = var_33h;
0x000428a0 orr r3, r3, 2 | r3 |= 2;
| do {
| label_3:
0x000428a4 strb r3, [sp, 0x33] | var_33h = r3;
| label_18:
0x000428a8 ldrb r3, [r4, 0x141] | r3 = *((r4 + 0x141));
0x000428ac cmp r3, 0 |
| if (r3 != 0) {
0x000428b0 bne 0x42940 | goto label_19;
| }
0x000428b4 mov r1, r5 | r1 = r5;
0x000428b8 ldr r0, [r6, 0x8e4] | r0 = *((r6 + 0x8e4));
0x000428bc bl 0x64120 | fcn_00064120 (r0);
0x000428c0 b 0x4290c | goto label_20;
| label_10:
0x000428c4 ldrb r3, [r4, 0x13] | r3 = *((r4 + 0x13));
0x000428c8 orr r3, r3, 8 | r3 |= 8;
0x000428cc strb r3, [r4, 0x13] | *((r4 + 0x13)) = r3;
0x000428d0 ldrb r3, [sp, 0x33] | r3 = var_33h;
0x000428d4 orr r3, r3, 8 | r3 |= 8;
0x000428d8 b 0x428a4 |
| } while (1);
| label_13:
0x000428dc ldrb r3, [r4, 0x13] | r3 = *((r4 + 0x13));
0x000428e0 orr r3, r3, 4 | r3 |= 4;
0x000428e4 strb r3, [r4, 0x13] | *((r4 + 0x13)) = r3;
0x000428e8 ldrb r3, [sp, 0x33] | r3 = var_33h;
0x000428ec orr r3, r3, 4 | r3 |= 4;
0x000428f0 b 0x428a4 | goto label_3;
| label_14:
0x000428f4 ldrb r3, [r4, 0x13] | r3 = *((r4 + 0x13));
0x000428f8 orr r3, r3, 0x10 | r3 |= 0x10;
0x000428fc strb r3, [r4, 0x13] | *((r4 + 0x13)) = r3;
0x00042900 ldrb r3, [sp, 0x33] | r3 = var_33h;
0x00042904 orr r3, r3, 0x10 | r3 |= 0x10;
0x00042908 b 0x428a4 | goto label_3;
| label_20:
0x0004290c ldr r0, [r6, 0x8e4] | r0 = *((r6 + 0x8e4));
0x00042910 bl 0x641ec | fcn_000641ec (r0);
0x00042914 ldrb r3, [sp, 0x61] | r3 = var_61h;
0x00042918 cmp r3, 0 |
| if (r3 == 0) {
0x0004291c bne 0x42940 |
0x00042920 ldr r0, [r6, 0x8e4] | r0 = *((r6 + 0x8e4));
0x00042924 bl 0x6427c | fcn_0006427c (r0);
0x00042928 ldrb r3, [r4, 0x11] | r3 = *((r4 + 0x11));
0x0004292c orr r3, r3, 0x80 | r3 |= 0x80;
0x00042930 strb r3, [r4, 0x11] | *((r4 + 0x11)) = r3;
0x00042934 ldrb r3, [sp, 0x31] | r3 = var_31h;
0x00042938 orr r3, r3, 0x80 | r3 |= 0x80;
0x0004293c strb r3, [sp, 0x31] | var_31h = r3;
| }
| label_19:
0x00042940 mov r0, 0x10 | r0 = 0x10;
0x00042944 bl 0x3c23c | r0 = fcn_0003c23c (r0);
0x00042948 cmp r0, 0 |
| if (r0 == 0) {
0x0004294c ldrbne r3, [r4, 0x13] | r3 = *((r4 + 0x13));
| }
0x00042950 mov r2, 0 | r2 = 0;
| if (r0 == 0) {
0x00042954 orrne r3, r3, 1 | r3 |= 1;
| }
| if (r0 == 0) {
0x00042958 strbne r3, [r4, 0x13] | *((r4 + 0x13)) = r3;
| }
| if (r0 == 0) {
0x0004295c ldrbne r3, [sp, 0x33] | r3 = var_33h;
| }
0x00042960 mov r0, r5 | r0 = r5;
| if (r0 == 0) {
0x00042964 orrne r3, r3, 1 | r3 |= 1;
| }
| if (r0 == 0) {
0x00042968 strbne r3, [sp, 0x33] | var_33h = r3;
| }
0x0004296c mov r3, 0x30 | r3 = 0x30;
0x00042970 mov r1, r3 | r1 = r3;
0x00042974 bl 0xb9f54 | fcn_000b9f54 (r0, r1);
0x00042978 mov r3, 0x18 | r3 = 0x18;
0x0004297c strh r3, [sp, 0x58] | var_58h = r3;
0x00042980 ldrd r2, r3, [sp, 0x30] | __asm ("ldrd r2, r3, [var_30h]");
0x00042984 add ip, sp, 0x88 |
0x00042988 strd r2, r3, [ip, -0x28]! | __asm ("strd r2, r3, [var_5ch]!");
0x0004298c ldm ip!, {r0, r1, r2, r3} | r0 = *(ip!);
| r1 = *((ip! + 4));
| r2 = *((ip! + 8));
| r3 = *((ip! + 12));
0x00042990 mov lr, sp | lr = sp;
0x00042994 stm lr!, {r0, r1, r2, r3} | *(lr!) = r0;
| *((lr! + 4)) = r1;
| *((lr! + 8)) = r2;
| *((lr! + 12)) = r3;
0x00042998 ldm ip!, {r0, r1, r2, r3} | r0 = *(ip!);
| r1 = *((ip! + 4));
| r2 = *((ip! + 8));
| r3 = *((ip! + 12));
0x0004299c stm lr!, {r0, r1, r2, r3} | *(lr!) = r0;
| *((lr! + 4)) = r1;
| *((lr! + 8)) = r2;
| *((lr! + 12)) = r3;
0x000429a0 ldm ip, {r0, r1} | r0 = *(ip);
| r1 = *((ip + 4));
0x000429a4 stm lr, {r0, r1} | *(lr) = r0;
| *((lr + 4)) = r1;
0x000429a8 ldr r0, [r6, 0x8ec] | r0 = *((r6 + 0x8ec));
0x000429ac ldm r5, {r2, r3} | r2 = *(r5);
| r3 = *((r5 + 4));
0x000429b0 bl 0x87328 | fcn_00087328 (r0, r1);
0x000429b4 mov r0, r4 | r0 = r4;
0x000429b8 bl 0x3acc0 | fcn_0003acc0 (r0);
0x000429bc mov r0, r4 | r0 = r4;
0x000429c0 bl 0x3afcc | fcn_0003afcc (r0);
0x000429c4 mov r0, r4 | r0 = r4;
0x000429c8 bl 0x3bb78 | fcn_0003bb78 (r0);
0x000429cc mov r0, r4 | r0 = r4;
0x000429d0 bl 0x41190 | fcn_00041190 (r0, r1);
0x000429d4 mov r3, 1 | r3 = 1;
0x000429d8 mov r2, 0 | r2 = 0;
0x000429dc strb r2, [r4, 0x2f] | *((r4 + 0x2f)) = r2;
0x000429e0 strb r3, [r4, 0x30] | *((r4 + 0x30)) = r3;
0x000429e4 strb r3, [r4, 0x31] | *((r4 + 0x31)) = r3;
0x000429e8 strb r3, [r4, 0x32] | *((r4 + 0x32)) = r3;
0x000429ec strb r3, [r4, 0x39] | *((r4 + 0x39)) = r3;
0x000429f0 strb r3, [r4, 0x33] | *((r4 + 0x33)) = r3;
0x000429f4 strb r3, [r4, 0x34] | *((r4 + 0x34)) = r3;
0x000429f8 strb r3, [r4, 0x35] | *((r4 + 0x35)) = r3;
0x000429fc strb r3, [r4, 0x36] | *((r4 + 0x36)) = r3;
0x00042a00 strb r2, [r4, 0x37] | *((r4 + 0x37)) = r2;
0x00042a04 strb r3, [r4, 0x38] | *((r4 + 0x38)) = r3;
0x00042a08 strb r3, [r4, 0x3a] | *((r4 + 0x3a)) = r3;
0x00042a0c strb r3, [r4, 0x2c] | *((r4 + 0x2c)) = r3;
0x00042a10 mov r0, r4 | r0 = r4;
0x00042a14 bl 0x3b618 | fcn_0003b618 (r0);
0x00042a18 ldr r0, [r7, 0xf50] | r0 = *((r7 + 0xf50));
0x00042a1c cmp r0, 0 |
0x00042a20 bne 0x42a64 |
| while (1) {
0x00042a24 ldr r0, [r7, 0xf54] | r0 = *((r7 + 0xf54));
0x00042a28 cmp r0, 0 |
| if (r0 != 0) {
0x00042a2c bne 0x42a6c | goto label_21;
| }
| label_4:
0x00042a30 ldr r0, [r7, 0xf58] | r0 = *((r7 + 0xf58));
0x00042a34 cmp r0, 0 |
| if (r0 != 0) {
0x00042a38 bne 0x42a74 | goto label_22;
| }
| label_5:
0x00042a3c ldr r0, [r6, 0x900] | r0 = *((r6 + 0x900));
0x00042a40 cmp r0, 0 |
| if (r0 != 0) {
0x00042a44 bne 0x42a7c | goto label_23;
| }
| label_6:
0x00042a48 ldr r0, [r7, 0xf5c] | r0 = *((r7 + 0xf5c));
0x00042a4c cmp r0, 0 |
| if (r0 != 0) {
0x00042a50 bne 0x42a84 | goto label_24;
| }
| label_7:
0x00042a54 mov r0, r8 | r0 = r8;
0x00042a58 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x00042a5c add sp, sp, 0x88 |
0x00042a60 pop {r4, r5, r6, r7, r8, sb, sl, pc} |
0x00042a64 bl 0x4d4e4 | fcn_0004d4e4 (r0);
0x00042a68 b 0x42a24 |
| }
| label_21:
0x00042a6c bl 0x4d4e4 | fcn_0004d4e4 (r0);
0x00042a70 b 0x42a30 | goto label_4;
| label_22:
0x00042a74 bl 0x52018 | fcn_00052018 (r0);
0x00042a78 b 0x42a3c | goto label_5;
| label_23:
0x00042a7c bl 0x67594 | fcn_00067594 ();
0x00042a80 b 0x42a48 | goto label_6;
| label_24:
0x00042a84 bl 0xc5768 | fcn_000c5768 (r0);
0x00042a88 b 0x42a54 | goto label_7;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x5c614 */
| #include <stdint.h>
|
| #define BIT_MASK(t,v) ((t)(-((v)!= 0)))&(((t)-1)>>((sizeof(t)*CHAR_BIT)-(v)))
|
; (fcn) fcn.0005c614 () | void fcn_0005c614 (int32_t arg1, int32_t arg2) {
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_10h;
| int32_t var_11h;
| int32_t var_12h;
| int32_t var_13h;
| int32_t var_18h;
| int32_t var_19h;
| int32_t var_1ah;
| int32_t var_1bh;
| int32_t var_20h;
| int32_t var_28h;
| int32_t var_38h;
| int32_t var_3ah;
| int32_t var_3eh;
| int32_t var_40h;
| int32_t var_42h;
| int32_t var_44h;
| int32_t var_50h;
| r0 = arg1;
| r1 = arg2;
0x0005c614 push {r4, r5, r6, r7, r8, sb, sl, lr} |
0x0005c618 ldr r7, [pc, 0x6a4] | r7 = *(0x5ccc0);
0x0005c61c mov r4, r1 | r4 = r1;
0x0005c620 ldr r1, [pc, 0x6a0] | r1 = *(0x5ccc4);
0x0005c624 sub sp, sp, 0x50 |
0x0005c628 add r5, sp, 0x38 | r5 += var_38h;
0x0005c62c add r1, pc, r1 | r1 = pc + r1;
0x0005c630 mov r8, r0 | r8 = r0;
0x0005c634 mov r0, r5 | r0 = r5;
0x0005c638 bl 0x5c414 | fcn_0005c414 (r0, r1);
0x0005c63c mov r1, r5 | r1 = r5;
0x0005c640 add r0, sp, 0x20 | r0 += var_20h;
0x0005c644 add r7, pc, r7 | r7 = pc + r7;
0x0005c648 bl 0xb855c | fcn_000b855c (r0, r1);
0x0005c64c mov r0, r5 | r0 = r5;
0x0005c650 bl 0x1b9a0 | method (r0);
0x0005c654 add r0, sp, 8 | r0 += var_8h;
0x0005c658 ldr sl, [sp, 0x20] | sl = var_20h;
0x0005c65c ldr sb, [sp, 0x28] | sb = var_28h;
0x0005c660 bl 0xc19e8 | fcn_000c19e8 (r0);
0x0005c664 mov r2, 0 | r2 = 0;
0x0005c668 mov r1, 0xe | r1 = 0xe;
0x0005c66c mov r0, r8 | r0 = r8;
0x0005c670 bl 0x548f4 | fcn_000548f4 (r0);
0x0005c674 mov r2, 0 | r2 = 0;
0x0005c678 mov r1, 0xe | r1 = 0xe;
0x0005c67c mov r6, r0 | r6 = r0;
0x0005c680 mov r0, r8 | r0 = r8;
0x0005c684 bl 0x548f4 | fcn_000548f4 (r0);
0x0005c688 mov r1, r6 | r1 = r6;
0x0005c68c mov r2, 0 | r2 = 0;
0x0005c690 add r6, sp, 0x50 | r6 += var_50h;
0x0005c694 mov r3, r0 | r3 = r0;
0x0005c698 add r0, r4, 1 | r0 = r4 + 1;
0x0005c69c bl 0xb9f54 | fcn_000b9f54 (r0, r1);
0x0005c6a0 mov r2, r4 | r2 = r4;
0x0005c6a4 mov r1, 0xe | r1 = 0xe;
0x0005c6a8 mov r0, r8 | r0 = r8;
0x0005c6ac bl 0x54958 | fcn_00054958 (r0);
0x0005c6b0 ldr r3, [pc, 0x614] | r3 = *(0x5ccc8);
0x0005c6b4 ldr r1, [pc, 0x614] | r1 = *(0x5cccc);
0x0005c6b8 ldr r3, [r7, r3] |
0x0005c6bc add r1, pc, r1 | r1 = pc + r1;
0x0005c6c0 ldr r3, [r3] | r3 = *(0x5ccc0);
0x0005c6c4 mov r0, r5 | r0 = r5;
0x0005c6c8 cmp r3, 0 |
0x0005c6cc ldrb r3, [r4, 9] | r3 = *((r4 + 9));
0x0005c6d0 bicne r3, r3, 0x10 | __asm ("bicne r3, r3, 0x10");
| if (r3 != 0) {
0x0005c6d4 orreq r3, r3, 0x10 | r3 |= 0x10;
| }
0x0005c6d8 strb r3, [r4, 9] | *((r4 + 9)) = r3;
0x0005c6dc ldr r3, [pc, 0x5f0] | r3 = *(0x5ccd0);
0x0005c6e0 ldr r3, [r7, r3] | r3 = *(0x5ccc0);
0x0005c6e4 ldrb r3, [r3] | r3 = *(r3);
0x0005c6e8 strb r3, [r4, 2] | *((r4 + 2)) = r3;
0x0005c6ec bl 0x5c414 | fcn_0005c414 (r0, r1);
0x0005c6f0 mov r3, 0 | r3 = 0;
0x0005c6f4 str r3, [r6, -0x4c]! | *((r6 -= 0x4c)) = r3;
0x0005c6f8 mov r0, r5 | r0 = r5;
0x0005c6fc mov r1, r6 | r1 = r6;
0x0005c700 bl 0x6895c | r0 = fcn_0006895c (r0, r1);
0x0005c704 lsr r3, r0, 8 | r3 = r0 >> 8;
0x0005c708 strb r0, [r4, 0x10] | *((r4 + 0x10)) = r0;
0x0005c70c strb r3, [r4, 0x11] | *((r4 + 0x11)) = r3;
0x0005c710 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x0005c714 lsr r0, r0, 0x18 | r0 >>= 0x18;
0x0005c718 strb r3, [r4, 0x12] | *((r4 + 0x12)) = r3;
0x0005c71c strb r0, [r4, 0x13] | *((r4 + 0x13)) = r0;
0x0005c720 mov r0, r5 | r0 = r5;
0x0005c724 bl 0x1b9a0 | method (r0);
0x0005c728 ldr r1, [pc, 0x5a8] | r1 = *(0x5ccd4);
0x0005c72c mov r0, r5 | r0 = r5;
0x0005c730 add r1, pc, r1 | r1 = pc + r1;
0x0005c734 bl 0x5c414 | fcn_0005c414 (r0, r1);
0x0005c738 mov r3, 1 | r3 = 1;
0x0005c73c mov r1, r6 | r1 = r6;
0x0005c740 mov r0, r5 | r0 = r5;
0x0005c744 str r3, [sp, 4] | var_4h = r3;
0x0005c748 bl 0x6895c | r0 = fcn_0006895c (r0, r1);
0x0005c74c lsr r3, r0, 8 | r3 = r0 >> 8;
0x0005c750 strb r0, [r4, 0x14] | *((r4 + 0x14)) = r0;
0x0005c754 strb r3, [r4, 0x15] | *((r4 + 0x15)) = r3;
0x0005c758 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x0005c75c lsr r0, r0, 0x18 | r0 >>= 0x18;
0x0005c760 strb r3, [r4, 0x16] | *((r4 + 0x16)) = r3;
0x0005c764 strb r0, [r4, 0x17] | *((r4 + 0x17)) = r0;
0x0005c768 mov r0, r5 | r0 = r5;
0x0005c76c bl 0x1b9a0 | method (r0);
0x0005c770 ldr r1, [pc, 0x564] | r1 = *(0x5ccd8);
0x0005c774 mov r0, r5 | r0 = r5;
0x0005c778 add r1, pc, r1 | r1 = pc + r1;
0x0005c77c bl 0x5c414 | fcn_0005c414 (r0, r1);
0x0005c780 mov r3, 0 | r3 = 0;
0x0005c784 mov r1, r6 | r1 = r6;
0x0005c788 mov r0, r5 | r0 = r5;
0x0005c78c str r3, [sp, 4] | var_4h = r3;
0x0005c790 bl 0x6895c | r0 = fcn_0006895c (r0, r1);
0x0005c794 lsr r3, r0, 8 | r3 = r0 >> 8;
0x0005c798 strb r0, [r4, 0x18] | *((r4 + 0x18)) = r0;
0x0005c79c strb r3, [r4, 0x19] | *((r4 + 0x19)) = r3;
0x0005c7a0 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x0005c7a4 lsr r0, r0, 0x18 | r0 >>= 0x18;
0x0005c7a8 strb r3, [r4, 0x1a] | *((r4 + 0x1a)) = r3;
0x0005c7ac strb r0, [r4, 0x1b] | *((r4 + 0x1b)) = r0;
0x0005c7b0 mov r0, r5 | r0 = r5;
0x0005c7b4 bl 0x1b9a0 | method (r0);
0x0005c7b8 ldr r1, [pc, 0x520] | r1 = *(0x5ccdc);
0x0005c7bc mov r0, r5 | r0 = r5;
0x0005c7c0 add r1, pc, r1 | r1 = pc + r1;
0x0005c7c4 bl 0x5c414 | fcn_0005c414 (r0, r1);
0x0005c7c8 mov r3, 1 | r3 = 1;
0x0005c7cc mov r1, r6 | r1 = r6;
0x0005c7d0 mov r0, r5 | r0 = r5;
0x0005c7d4 str r3, [sp, 4] | var_4h = r3;
0x0005c7d8 bl 0x6895c | r0 = fcn_0006895c (r0, r1);
0x0005c7dc lsr r3, r0, 8 | r3 = r0 >> 8;
0x0005c7e0 strb r0, [r4, 0x1c] | *((r4 + 0x1c)) = r0;
0x0005c7e4 strb r3, [r4, 0x1d] | *((r4 + 0x1d)) = r3;
0x0005c7e8 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x0005c7ec lsr r0, r0, 0x18 | r0 >>= 0x18;
0x0005c7f0 strb r3, [r4, 0x1e] | *((r4 + 0x1e)) = r3;
0x0005c7f4 strb r0, [r4, 0x1f] | *((r4 + 0x1f)) = r0;
0x0005c7f8 mov r0, r5 | r0 = r5;
0x0005c7fc bl 0x1b9a0 | method (r0);
0x0005c800 ldr r3, [pc, 0x4dc] | r3 = *(0x5cce0);
0x0005c804 ldr r6, [r7, r3] | r6 = *(0x5ccc0);
0x0005c808 ldr r3, [r6] |
0x0005c80c add r3, r3, 0x43000 | r3 = 0x9fcc0;
0x0005c810 ldr r0, [r3, 0x8e8] | r0 = *(0xa05a8);
0x0005c814 bl 0x34f34 | r0 = fcn_00034f34 (r0);
0x0005c818 lsr r3, r0, 8 | r3 = r0 >> 8;
0x0005c81c strb r0, [r4, 0xb] | *((r4 + 0xb)) = r0;
0x0005c820 strb r3, [r4, 0xc] | *((r4 + 0xc)) = r3;
0x0005c824 lsr r3, r0, 0x10 | r3 = r0 >> 0x10;
0x0005c828 lsr r0, r0, 0x18 | r0 >>= 0x18;
0x0005c82c strb r0, [r4, 0xe] | *((r4 + 0xe)) = r0;
0x0005c830 ldr r0, [r6] | r0 = *(0x5ccc0);
0x0005c834 strb r3, [r4, 0xd] | *((r4 + 0xd)) = r3;
0x0005c838 ldrb r3, [r0, 0x142] | r3 = *((r0 + 0x142));
0x0005c83c strb r3, [r4, 0xa] | *((r4 + 0xa)) = r3;
0x0005c840 ldrb r3, [r0, 0x142] | r3 = *((r0 + 0x142));
0x0005c844 cmp r3, 3 |
| if (r3 == 3) {
0x0005c848 bne 0x5c864 |
0x0005c84c bl 0x3a850 | fcn_0003a850 ();
0x0005c850 ldrb r3, [r4, 0x38] | r3 = *((r4 + 0x38));
0x0005c854 bic r3, r3, 0x80 | r3 = BIT_MASK (r3, 0x80);
0x0005c858 and r0, r0, 1 | r0 &= 1;
0x0005c85c orr r3, r3, r0, lsl 7 | r3 |= (r0 << 7);
0x0005c860 strb r3, [r4, 0x38] | *((r4 + 0x38)) = r3;
| }
0x0005c864 ldrb r3, [sp, 0x10] | r3 = var_10h;
0x0005c868 strb sl, [r4, 0x2f] | *((r4 + 0x2f)) = sl;
0x0005c86c strb r3, [r4, 0x27] | *((r4 + 0x27)) = r3;
0x0005c870 ldrb r3, [sp, 0x11] | r3 = var_11h;
0x0005c874 strb sb, [r4, 0x33] | *((r4 + 0x33)) = sb;
0x0005c878 strb r3, [r4, 0x28] | *((r4 + 0x28)) = r3;
0x0005c87c ldrb r3, [sp, 0x12] | r3 = var_12h;
0x0005c880 ldr r0, [r6] | r0 = *(r6);
0x0005c884 strb r3, [r4, 0x29] | *((r4 + 0x29)) = r3;
0x0005c888 ldrb r3, [sp, 0x13] | r3 = var_13h;
0x0005c88c strb r3, [r4, 0x2a] | *((r4 + 0x2a)) = r3;
0x0005c890 ldrb r3, [sp, 0x18] | r3 = var_18h;
0x0005c894 strb r3, [r4, 0x2b] | *((r4 + 0x2b)) = r3;
0x0005c898 ldrb r3, [sp, 0x19] | r3 = var_19h;
0x0005c89c strb r3, [r4, 0x2c] | *((r4 + 0x2c)) = r3;
0x0005c8a0 ldrb r3, [sp, 0x1a] | r3 = var_1ah;
0x0005c8a4 strb r3, [r4, 0x2d] | *((r4 + 0x2d)) = r3;
0x0005c8a8 ldrb r3, [sp, 0x1b] | r3 = var_1bh;
0x0005c8ac strb r3, [r4, 0x2e] | *((r4 + 0x2e)) = r3;
0x0005c8b0 lsr r3, sl, 8 | r3 = sl >> 8;
0x0005c8b4 strb r3, [r4, 0x30] | *((r4 + 0x30)) = r3;
0x0005c8b8 lsr r3, sl, 0x10 | r3 = sl >> 0x10;
0x0005c8bc strb r3, [r4, 0x31] | *((r4 + 0x31)) = r3;
0x0005c8c0 lsr r3, sb, 8 | r3 = sb >> 8;
0x0005c8c4 strb r3, [r4, 0x34] | *((r4 + 0x34)) = r3;
0x0005c8c8 lsr sl, sl, 0x18 | sl >>= 0x18;
0x0005c8cc lsr r3, sb, 0x10 | r3 = sb >> 0x10;
0x0005c8d0 lsr sb, sb, 0x18 | sb >>= 0x18;
0x0005c8d4 strb r3, [r4, 0x35] | *((r4 + 0x35)) = r3;
0x0005c8d8 strb sl, [r4, 0x32] | *((r4 + 0x32)) = sl;
0x0005c8dc strb sb, [r4, 0x36] | *((r4 + 0x36)) = sb;
0x0005c8e0 bl 0x3a85c | fcn_0003a85c (r0);
0x0005c8e4 ldrb r3, [r4, 3] | r3 = *((r4 + 3));
0x0005c8e8 ldr r2, [r6] | r2 = *(r6);
0x0005c8ec bic r3, r3, 0x7f | r3 = BIT_MASK (r3, 0x7f);
0x0005c8f0 and r0, r0, 0x7f | r0 &= 0x7f;
0x0005c8f4 orr r0, r0, r3 | r0 |= r3;
0x0005c8f8 strb r0, [r4, 3] | *((r4 + 3)) = r0;
0x0005c8fc ldrb r3, [r4, 9] | r3 = *((r4 + 9));
0x0005c900 ldrb r1, [r2, 0x155] | r1 = *((r2 + 0x155));
0x0005c904 bic r3, r3, 0x60 | r3 = BIT_MASK (r3, 0x60);
0x0005c908 and r1, r1, 3 | r1 &= 3;
0x0005c90c orr r3, r3, r1, lsl 5 | r3 |= (r1 << 5);
0x0005c910 add r2, r2, 0x42000 | r2 += 0x42000;
0x0005c914 strb r3, [r4, 9] | *((r4 + 9)) = r3;
0x0005c918 ldr r0, [r2, 0xf40] | r0 = *((r2 + 0xf40));
0x0005c91c bl 0x69a78 | r0 = fcn_00069a78 (r0);
0x0005c920 mvn r0, r0 | r0 = ~r0;
0x0005c924 tst r0, 0x20 |
| if ((r0 & 0x20) == 0) {
0x0005c928 ldrbne r3, [r4, 0x37] | r3 = *((r4 + 0x37));
| }
0x0005c92c and r2, r0, 0xff | r2 = r0 & 0xff;
| if ((r0 & 0x20) == 0) {
0x0005c930 orrne r3, r3, 1 | r3 |= 1;
| }
| if ((r0 & 0x20) == 0) {
0x0005c934 strbne r3, [r4, 0x37] | *((r4 + 0x37)) = r3;
| }
0x0005c938 tst r2, 0x10 |
| if ((r2 & 0x10) == 0) {
0x0005c93c ldrbne r3, [r4, 0x37] | r3 = *((r4 + 0x37));
| }
0x0005c940 ldr r0, [pc, 0x3a0] | r0 = *(0x5cce4);
| if ((r2 & 0x10) == 0) {
0x0005c944 orrne r3, r3, 2 | r3 |= 2;
| }
| if ((r2 & 0x10) == 0) {
0x0005c948 strbne r3, [r4, 0x37] | *((r4 + 0x37)) = r3;
| }
0x0005c94c ldrb r3, [r4, 0x37] | r3 = *((r4 + 0x37));
0x0005c950 add r0, pc, r0 | r0 = pc + r0;
0x0005c954 orr r3, r3, 0x80 | r3 |= 0x80;
0x0005c958 strb r3, [r4, 0x37] | *((r4 + 0x37)) = r3;
0x0005c95c ldrb r2, [r8, 0x27] | r2 = *((r8 + 0x27));
0x0005c960 and r3, r3, 0xff | r3 &= 0xff;
0x0005c964 and r2, r2, 1 | r2 &= 1;
0x0005c968 bic r3, r3, 0x40 | r3 = BIT_MASK (r3, 0x40);
0x0005c96c orr r3, r3, r2, lsl 6 | r3 |= (r2 << 6);
0x0005c970 strb r3, [r4, 0x37] | *((r4 + 0x37)) = r3;
0x0005c974 ldrb r2, [r8, 0x28] | r2 = *((r8 + 0x28));
0x0005c978 and r3, r3, 0xff | r3 &= 0xff;
0x0005c97c and r2, r2, 1 | r2 &= 1;
0x0005c980 bic r3, r3, 0x20 | r3 = BIT_MASK (r3, 0x20);
0x0005c984 orr r3, r3, r2, lsl 5 | r3 |= (r2 << 5);
0x0005c988 strb r3, [r4, 0x37] | *((r4 + 0x37)) = r3;
0x0005c98c ldrb r2, [r8, 0x27] | r2 = *((r8 + 0x27));
0x0005c990 ldrb r1, [r8, 0x28] | r1 = *((r8 + 0x28));
0x0005c994 bl 0x17750 | printf (r0, r1, r2, r3)
0x0005c998 ldrb r3, [r4, 0x38] | r3 = *((r4 + 0x38));
0x0005c99c orr r3, r3, 0xf | r3 |= 0xf;
0x0005c9a0 strb r3, [r4, 0x38] | *((r4 + 0x38)) = r3;
0x0005c9a4 ldrb r3, [r4, 0x37] | r3 = *((r4 + 0x37));
0x0005c9a8 ldr r0, [r6] | r0 = *(r6);
0x0005c9ac orr r3, r3, 0x10 | r3 |= 0x10;
0x0005c9b0 strb r3, [r4, 0x37] | *((r4 + 0x37)) = r3;
0x0005c9b4 ldrb r3, [r0, 0x10] | r3 = *((r0 + 0x10));
0x0005c9b8 lsl r2, r3, 0x1d | r2 = r3 << 0x1d;
0x0005c9bc ldrb r3, [r4, 7] | r3 = *((r4 + 7));
0x0005c9c0 bic r3, r3, 1 | r3 = BIT_MASK (r3, 1);
0x0005c9c4 orr r3, r3, r2, lsr 31 | r3 |= (r2 >> 31);
0x0005c9c8 strb r3, [r4, 7] | *((r4 + 7)) = r3;
0x0005c9cc ldrb r3, [r0, 0x10] | r3 = *((r0 + 0x10));
0x0005c9d0 ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x0005c9d4 lsr r3, r3, 3 | r3 >>= 3;
0x0005c9d8 bic r2, r2, 2 | r2 = BIT_MASK (r2, 2);
0x0005c9dc and r3, r3, 2 | r3 &= 2;
0x0005c9e0 orr r3, r3, r2 | r3 |= r2;
0x0005c9e4 strb r3, [r4, 7] | *((r4 + 7)) = r3;
0x0005c9e8 ldrb r3, [r0, 0x10] | r3 = *((r0 + 0x10));
0x0005c9ec ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x0005c9f0 lsr r3, r3, 2 | r3 >>= 2;
0x0005c9f4 bic r2, r2, 8 | r2 = BIT_MASK (r2, 8);
0x0005c9f8 and r3, r3, 8 | r3 &= 8;
0x0005c9fc orr r3, r3, r2 | r3 |= r2;
0x0005ca00 strb r3, [r4, 7] | *((r4 + 7)) = r3;
0x0005ca04 ldrb r3, [r0, 0x10] | r3 = *((r0 + 0x10));
0x0005ca08 ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x0005ca0c lsr r3, r3, 2 | r3 >>= 2;
0x0005ca10 bic r2, r2, 0x10 | r2 = BIT_MASK (r2, 0x10);
0x0005ca14 and r3, r3, 0x10 | r3 &= 0x10;
0x0005ca18 orr r3, r3, r2 | r3 |= r2;
0x0005ca1c strb r3, [r4, 7] | *((r4 + 7)) = r3;
0x0005ca20 ldrb r2, [r0, 0x10] | r2 = *((r0 + 0x10));
0x0005ca24 and r3, r3, 0xff | r3 &= 0xff;
0x0005ca28 lsr r2, r2, 7 | r2 >>= 7;
0x0005ca2c bic r3, r3, 0x20 | r3 = BIT_MASK (r3, 0x20);
0x0005ca30 orr r3, r3, r2, lsl 5 | r3 |= (r2 << 5);
0x0005ca34 strb r3, [r4, 7] | *((r4 + 7)) = r3;
0x0005ca38 add r3, r0, 0x43000 | r3 = r0 + 0x43000;
0x0005ca3c ldr r3, [r3, 0x904] | r3 = *((r3 + 0x904));
0x0005ca40 cmp r3, 0 |
| if (r3 != 0) {
0x0005ca44 ldrbeq r3, [r4, 7] | r3 = *((r4 + 7));
| }
| if (r3 != 0) {
0x0005ca48 orreq r3, r3, 0x40 | r3 |= 0x40;
| }
| if (r3 != 0) {
0x0005ca4c strbeq r3, [r4, 7] | *((r4 + 7)) = r3;
| }
0x0005ca50 ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005ca54 lsl r2, r3, 0x1e | r2 = r3 << 0x1e;
0x0005ca58 ldrb r3, [r4, 8] | r3 = *((r4 + 8));
0x0005ca5c bic r3, r3, 1 | r3 = BIT_MASK (r3, 1);
0x0005ca60 orr r3, r3, r2, lsr 31 | r3 |= (r2 >> 31);
0x0005ca64 strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005ca68 ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005ca6c ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0005ca70 lsr r3, r3, 1 | r3 >>= 1;
0x0005ca74 bic r2, r2, 2 | r2 = BIT_MASK (r2, 2);
0x0005ca78 and r3, r3, 2 | r3 &= 2;
0x0005ca7c orr r3, r3, r2 | r3 |= r2;
0x0005ca80 strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005ca84 ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005ca88 ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0005ca8c lsr r3, r3, 1 | r3 >>= 1;
0x0005ca90 bic r2, r2, 4 | r2 = BIT_MASK (r2, 4);
0x0005ca94 and r3, r3, 4 | r3 &= 4;
0x0005ca98 orr r3, r3, r2 | r3 |= r2;
0x0005ca9c strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005caa0 ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005caa4 ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0005caa8 lsr r3, r3, 1 | r3 >>= 1;
0x0005caac bic r2, r2, 8 | r2 = BIT_MASK (r2, 8);
0x0005cab0 and r3, r3, 8 | r3 &= 8;
0x0005cab4 orr r3, r3, r2 | r3 |= r2;
0x0005cab8 strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005cabc ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005cac0 ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0005cac4 lsr r3, r3, 1 | r3 >>= 1;
0x0005cac8 bic r2, r2, 0x10 | r2 = BIT_MASK (r2, 0x10);
0x0005cacc and r3, r3, 0x10 | r3 &= 0x10;
0x0005cad0 orr r3, r3, r2 | r3 |= r2;
0x0005cad4 strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005cad8 ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005cadc ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0005cae0 lsr r3, r3, 1 | r3 >>= 1;
0x0005cae4 bic r2, r2, 0x20 | r2 = BIT_MASK (r2, 0x20);
0x0005cae8 and r3, r3, 0x20 | r3 &= 0x20;
0x0005caec orr r3, r3, r2 | r3 |= r2;
0x0005caf0 strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005caf4 ldrb r3, [r0, 0x10] | r3 = *((r0 + 0x10));
0x0005caf8 ldrb r2, [r4, 8] | r2 = *((r4 + 8));
0x0005cafc lsl r3, r3, 3 | r3 <<= 3;
0x0005cb00 bic r2, r2, 0x40 | r2 = BIT_MASK (r2, 0x40);
0x0005cb04 and r3, r3, 0x40 | r3 &= 0x40;
0x0005cb08 orr r3, r3, r2 | r3 |= r2;
0x0005cb0c strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005cb10 ldrb r3, [r0, 0x13] | r3 = *((r0 + 0x13));
0x0005cb14 lsr r3, r3, 5 | r3 >>= 5;
0x0005cb18 strb r3, [r4, 5] | *((r4 + 5)) = r3;
0x0005cb1c ldrb r3, [r0, 0x11] | r3 = *((r0 + 0x11));
0x0005cb20 tst r3, 1 |
| if ((r3 & 1) == 0) {
0x0005cb24 movne r3, 2 | r3 = 2;
| }
| if ((r3 & 1) == 0) {
0x0005cb28 strbne r3, [r4, 6] | *((r4 + 6)) = r3;
| }
0x0005cb2c ldrb r3, [r4, 9] | r3 = *((r4 + 9));
0x0005cb30 ldrb r2, [r0, 0x11] | r2 = *((r0 + 0x11));
0x0005cb34 bic r3, r3, 1 | r3 = BIT_MASK (r3, 1);
0x0005cb38 orr r3, r3, r2, lsr 7 | r3 |= (r2 >> 7);
0x0005cb3c strb r3, [r4, 9] | *((r4 + 9)) = r3;
0x0005cb40 ldrb r3, [r0, 0x12] | r3 = *((r0 + 0x12));
0x0005cb44 and r2, r3, 1 | r2 = r3 & 1;
0x0005cb48 ldrb r3, [r4, 9] | r3 = *((r4 + 9));
0x0005cb4c bic r3, r3, 2 | r3 = BIT_MASK (r3, 2);
0x0005cb50 orr r3, r3, r2, lsl 1 | r3 |= (r2 << 1);
0x0005cb54 strb r3, [r4, 9] | *((r4 + 9)) = r3;
0x0005cb58 ldrb r3, [r0, 0x12] | r3 = *((r0 + 0x12));
0x0005cb5c ldrb r2, [r4, 9] | r2 = *((r4 + 9));
0x0005cb60 lsl r3, r3, 1 | r3 <<= 1;
0x0005cb64 bic r2, r2, 4 | r2 = BIT_MASK (r2, 4);
0x0005cb68 and r3, r3, 4 | r3 &= 4;
0x0005cb6c orr r3, r3, r2 | r3 |= r2;
0x0005cb70 strb r3, [r4, 9] | *((r4 + 9)) = r3;
0x0005cb74 ldrb r2, [r4, 7] | r2 = *((r4 + 7));
0x0005cb78 ldrb r3, [r0, 0x12] | r3 = *((r0 + 0x12));
0x0005cb7c bic r2, r2, 4 | r2 = BIT_MASK (r2, 4);
0x0005cb80 and r3, r3, 4 | r3 &= 4;
0x0005cb84 orr r3, r3, r2 | r3 |= r2;
0x0005cb88 strb r3, [r4, 7] | *((r4 + 7)) = r3;
0x0005cb8c ldrb r2, [r4, 9] | r2 = *((r4 + 9));
0x0005cb90 ldrb r3, [r0, 0x12] | r3 = *((r0 + 0x12));
0x0005cb94 bic r2, r2, 8 | r2 = BIT_MASK (r2, 8);
0x0005cb98 and r3, r3, 8 | r3 &= 8;
0x0005cb9c orr r3, r3, r2 | r3 |= r2;
0x0005cba0 strb r3, [r4, 9] | *((r4 + 9)) = r3;
0x0005cba4 bl 0x39994 | fcn_00039994 (r0);
0x0005cba8 ldr r3, [pc, 0x13c] | r3 = *(0x5cce8);
0x0005cbac strb r0, [r4, 4] | *((r4 + 4)) = r0;
0x0005cbb0 ldr r3, [r7, r3] | r3 = *((r7 + r3));
0x0005cbb4 ldr r0, [r3] | r0 = *(0x5cce8);
0x0005cbb8 cmp r0, 0 |
| if (r0 != 0) {
0x0005cbbc beq 0x5cbc8 |
0x0005cbc0 bl 0xd3674 | fcn_000d3674 (r0);
0x0005cbc4 strb r0, [r4, 0xf] | *((r4 + 0xf)) = r0;
| }
0x0005cbc8 mov r0, r5 | r0 = r5;
0x0005cbcc bl 0xc486c | fcn_000c486c (r0);
0x0005cbd0 ldrh r3, [sp, 0x38] | r3 = var_38h;
0x0005cbd4 ldr r2, [pc, 0x114] | r2 = *(0x5ccec);
0x0005cbd8 umull r0, r1, r3, r2 | r0:r1 = r3 * r2;
0x0005cbdc lsr r0, r1, 5 | r0 = r1 >> 5;
0x0005cbe0 mov r1, 0x64 | r1 = 0x64;
0x0005cbe4 mul r2, r1, r0 | r2 = r1 * r0;
0x0005cbe8 strb r0, [r4, 0x20] | *((r4 + 0x20)) = r0;
0x0005cbec sub r3, r3, r2 | r3 -= r2;
0x0005cbf0 strb r3, [r4, 0x21] | *((r4 + 0x21)) = r3;
0x0005cbf4 ldrh r3, [sp, 0x3a] | r3 = var_3ah;
0x0005cbf8 ldr r2, [r6] | r2 = *(r6);
0x0005cbfc strb r3, [r4, 0x22] | *((r4 + 0x22)) = r3;
0x0005cc00 ldrh r3, [sp, 0x3e] | r3 = var_3eh;
0x0005cc04 strb r3, [r4, 0x23] | *((r4 + 0x23)) = r3;
0x0005cc08 ldrh r3, [sp, 0x40] | r3 = var_40h;
0x0005cc0c strb r3, [r4, 0x24] | *((r4 + 0x24)) = r3;
0x0005cc10 ldrh r3, [sp, 0x42] | r3 = var_42h;
0x0005cc14 strb r3, [r4, 0x25] | *((r4 + 0x25)) = r3;
0x0005cc18 ldrh r3, [sp, 0x44] | r3 = var_44h;
0x0005cc1c strb r3, [r4, 0x26] | *((r4 + 0x26)) = r3;
0x0005cc20 add r3, r2, 0x43000 | r3 = r2 + 0x43000;
0x0005cc24 ldr r1, [r3, 0x900] | r1 = *((r3 + 0x900));
0x0005cc28 ldrb r3, [r4, 8] | r3 = *((r4 + 8));
0x0005cc2c cmp r1, 0 |
| if (r1 == 0) {
0x0005cc30 ldrbne r1, [r1, 8] | r1 = *((r1 + 8));
| }
0x0005cc34 bicne r3, r3, 0x80 | __asm ("bicne r3, r3, 0x80");
| if (r1 == 0) {
0x0005cc38 andne r1, r1, 1 | r1 &= 1;
| }
| if (r1 == 0) {
0x0005cc3c orrne r3, r3, r1, lsl 7 | r3 |= (r1 << 7);
| }
0x0005cc40 biceq r3, r3, 0x80 | __asm ("biceq r3, r3, 0x80");
0x0005cc44 strb r3, [r4, 8] | *((r4 + 8)) = r3;
0x0005cc48 ldrb r3, [r2, 0x3e] | r3 = *((r2 + 0x3e));
0x0005cc4c cmp r3, 0 |
| if (r3 != 0) {
0x0005cc50 beq 0x5cc74 |
0x0005cc54 ldr r3, [r2, 0x18] | r3 = *((r2 + 0x18));
0x0005cc58 lsr r2, r3, 8 | r2 = r3 >> 8;
0x0005cc5c strb r3, [r4, 0x39] | *((r4 + 0x39)) = r3;
0x0005cc60 strb r2, [r4, 0x3a] | *((r4 + 0x3a)) = r2;
0x0005cc64 lsr r2, r3, 0x10 | r2 = r3 >> 0x10;
0x0005cc68 lsr r3, r3, 0x18 | r3 >>= 0x18;
0x0005cc6c strb r2, [r4, 0x3b] | *((r4 + 0x3b)) = r2;
0x0005cc70 strb r3, [r4, 0x3c] | *((r4 + 0x3c)) = r3;
| }
0x0005cc74 ldr r0, [pc, 0x78] | r0 = *(0x5ccf0);
0x0005cc78 add r0, pc, r0 | r0 = pc + r0;
0x0005cc7c bl 0x183e0 | basename (r0);
0x0005cc80 ldr r1, [pc, 0x70] |
0x0005cc84 ldr r3, [pc, 0x70] | r3 = *(0x5ccf8);
0x0005cc88 add r1, pc, r1 | r1 = pc + r1;
0x0005cc8c add r1, r1, 0x520 | r1 = 0x5d214;
0x0005cc90 add r3, pc, r3 | r3 = pc + r3;
0x0005cc94 mov r2, 5 | r2 = 5;
0x0005cc98 add r1, r1, 3 | r1 += 3;
0x0005cc9c bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x0005cca0 add sp, sp, 0x50 |
0x0005cca4 pop {r4, r5, r6, r7, r8, sb, sl, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x5eaf0 */
| #include <stdint.h>
|
; (fcn) fcn.0005eaf0 () | void fcn_0005eaf0 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_0h_2;
| int32_t var_8h;
| int32_t var_10h;
| int32_t var_2ch;
| int32_t var_48h;
| r0 = arg1;
| r1 = arg2;
0x0005eaf0 push {r4, r5, r6, r7, r8, sb, sl, lr} |
0x0005eaf4 ldr sb, [pc, 0x178] | sb = *(0x5ec70);
0x0005eaf8 sub sp, sp, 0x48 |
0x0005eafc add r7, sp, 0x10 | r7 += var_10h;
0x0005eb00 mov r5, r0 | r5 = r0;
0x0005eb04 mov r8, r1 | r8 = r1;
0x0005eb08 add sl, sp, 0x2c | sl += var_2ch;
0x0005eb0c mov r1, r0 | r1 = r0;
0x0005eb10 mov r0, r7 | r0 = r7;
0x0005eb14 bl 0x5e9fc | fcn_0005e9fc (r0, r1);
0x0005eb18 mov r1, r7 | r1 = r7;
0x0005eb1c mov r0, sl | r0 = sl;
0x0005eb20 add sb, pc, sb | sb = pc + sb;
0x0005eb24 bl 0x2913c | fcn_0002913c (r0, r1);
0x0005eb28 b 0x5eb3c |
0x0005eb3c ldr r0, [pc, 0x134] | r0 = *(0x5ec74);
0x0005eb40 bl 0x1769c | sym ();
0x0005eb44 mov r3, 1 | r3 = 1;
0x0005eb48 ldr r2, [pc, 0x12c] | r2 = *(0x5ec78);
0x0005eb4c mov r1, sl | r1 = sl;
0x0005eb50 mov r4, r0 | r4 = r0;
0x0005eb54 bl 0xc2768 | fcn_000c2768 (r0, r1);
0x0005eb58 mov r0, sl | r0 = sl;
0x0005eb5c bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x0005eb60 mov r0, r4 | r0 = r4;
0x0005eb64 bl 0xc2498 | r0 = fcn_000c2498 (r0);
0x0005eb68 cmp r0, 0 |
| if (r0 != 0) {
0x0005eb6c moveq r6, 1 | r6 = 1;
| }
| if (r0 != 0) {
0x0005eb70 beq 0x5eba0 |
0x0005eb74 mov r2, 0 | r2 = 0;
0x0005eb78 mov r1, r2 | r1 = r2;
0x0005eb7c mov r0, r4 | r0 = r4;
0x0005eb80 bl 0xc26d8 | fcn_000c26d8 (r0);
0x0005eb84 ldr r2, [r5, 0x2c] | r2 = *((r5 + 0x2c));
0x0005eb88 ldr r1, [r5] | r1 = *(r5);
0x0005eb8c mov r0, r4 | r0 = r4;
0x0005eb90 bl 0xc25b0 | fcn_000c25b0 (r0, r1);
0x0005eb94 mov r6, 1 | r6 = 1;
0x0005eb98 cmp r4, 0 |
| if (r4 == 0) {
0x0005eb9c beq 0x5ebb4 | goto label_0;
| }
| }
0x0005eba0 mov r0, r4 | r0 = r4;
0x0005eba4 bl 0xc253c | fcn_000c253c (r0);
0x0005eba8 ldr r1, [pc, 0xc8] | r1 = *(0x5ec74);
0x0005ebac mov r0, r4 | r0 = r4;
0x0005ebb0 bl 0x17c48 | sym ();
| label_0:
0x0005ebb4 mov r0, r5 | r0 = r5;
0x0005ebb8 bl 0x5608c | fcn_0005608c (r0);
0x0005ebbc b 0x5ebc8 |
0x0005ebc8 cmp r8, 0x1a |
| if (r8 != 0x1a) {
0x0005ebcc moveq r3, 1 | r3 = 1;
| }
| if (r8 != 0x1a) {
0x0005ebd0 strbeq r3, [r5, 0x28] | *((r5 + 0x28)) = r3;
| }
| if (r8 != 0x1a) {
0x0005ebd4 beq 0x5ebe4 |
0x0005ebd8 cmp r8, 0x1b |
| if (r8 != 0x1b) {
0x0005ebdc moveq r3, 1 | r3 = 1;
| }
| if (r8 == 0x1b) {
0x0005ebe0 strbeq r3, [r5, 0x27] | *((r5 + 0x27)) = r3;
| goto label_1;
| }
| }
| label_1:
0x0005ebe4 ldr r3, [pc, 0x94] | r3 = *(0x5ec7c);
0x0005ebe8 mov r2, 0 | r2 = 0;
0x0005ebec ldr r3, [sb, r3] | r3 = *((sb + r3));
0x0005ebf0 mov r0, 0 | r0 = 0;
0x0005ebf4 mov r1, 0 | r1 = 0;
0x0005ebf8 str r2, [sp, 8] | var_8h = r2;
0x0005ebfc strd r0, r1, [sp] | __asm ("strd r0, r1, [sp]");
0x0005ec00 ldr r0, [r3] | r0 = *(0x5ec7c);
0x0005ec04 mov r2, 0x14 | r2 = 0x14;
0x0005ec08 mov r1, 0x1a | r1 = 0x1a;
0x0005ec0c bl 0x3b718 | fcn_0003b718 (r0, r1, r2, r3);
0x0005ec10 ldr r0, [pc, 0x6c] | r0 = *(0x5ec80);
0x0005ec14 ldrb r2, [r5, 0x27] | r2 = *((r5 + 0x27));
0x0005ec18 ldrb r1, [r5, 0x28] | r1 = *((r5 + 0x28));
0x0005ec1c add r0, pc, r0 | r0 = pc + r0;
0x0005ec20 bl 0x17750 | printf (r0, r1, r2)
0x0005ec24 b 0x5ec60 |
0x0005ec60 mov r0, r7 | r0 = r7;
0x0005ec64 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x0005ec68 mov r0, r6 | r0 = r6;
0x0005ec6c add sp, sp, 0x48 |
0x0005ec70 pop {r4, r5, r6, r7, r8, sb, sl, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x5f3f4 */
| #include <stdint.h>
|
; (fcn) fcn.0005f3f4 () | void fcn_0005f3f4 (int32_t arg1) {
| int32_t var_0h;
| int32_t var_0h_2;
| int32_t var_8h;
| int32_t var_10h;
| r0 = arg1;
0x0005f3f4 push {r0, r1, r2, r3, r4, r5, r6, lr} |
0x0005f3f8 ldr r6, [pc, 0x58] | r6 = *(0x5f454);
0x0005f3fc mov r5, 0 | r5 = 0;
0x0005f400 strb r5, [r0, 0x27] | *((r0 + 0x27)) = r5;
0x0005f404 strb r5, [r0, 0x28] | *((r0 + 0x28)) = r5;
0x0005f408 mov r4, r0 | r4 = r0;
0x0005f40c bl 0x5f1a8 | fcn_0005f1a8 ();
0x0005f410 ldr r3, [pc, 0x44] | r3 = *(0x5f458);
0x0005f414 add r6, pc, r6 | r6 = pc + r6;
0x0005f418 ldr r3, [r6, r3] | r3 = *(0x5f454);
0x0005f41c mov r0, 0 | r0 = 0;
0x0005f420 mov r1, 0 | r1 = 0;
0x0005f424 strd r0, r1, [sp] | __asm ("strd r0, r1, [sp]");
0x0005f428 str r5, [sp, 8] | var_8h = r5;
0x0005f42c mov r2, 0x14 | r2 = 0x14;
0x0005f430 ldr r0, [r3] | r0 = *(0x5f454);
0x0005f434 mov r1, 0x1a | r1 = 0x1a;
0x0005f438 bl 0x3b718 | fcn_0003b718 (r0, r1, r2, r3);
0x0005f43c ldr r0, [pc, 0x1c] | r0 = *(0x5f45c);
0x0005f440 ldrb r2, [r4, 0x27] | r2 = *((r4 + 0x27));
0x0005f444 ldrb r1, [r4, 0x28] | r1 = *((r4 + 0x28));
0x0005f448 add r0, pc, r0 | r0 = pc + r0;
0x0005f44c add sp, sp, 0x10 |
0x0005f450 pop {r4, r5, r6, lr} |
0x0005f454 b 0x17750 | return void (*0x17750)() ();
| }
r2dec has crashed (info: /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0x60bac).
Please report the bug at https://github.com/radareorg/r2dec-js/issues
Use the option '--issue' or the command 'pddi' to generate
the needed data for the issue.
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc2cf8 */
| #include <stdint.h>
|
; (fcn) fcn.000c2cf8 () | void fcn_000c2cf8 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_20h;
| int32_t var_28h;
| int32_t var_2ch;
| int32_t var_44h;
| r0 = arg1;
| r1 = arg2;
0x000c2cf8 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000c2cfc mov sl, r1 | sl = r1;
0x000c2d00 sub sp, sp, 0x44 |
0x000c2d04 mov r1, 2 | r1 = 2;
0x000c2d08 mov r5, r0 | r5 = r0;
0x000c2d0c mov r4, r2 | r4 = r2;
0x000c2d10 bl 0x17d80 | r0 = open64 ();
0x000c2d14 cmn r0, 1 |
| if (r0 == 1) {
0x000c2d18 bne 0xc2d44 |
0x000c2d1c bl 0x17e58 | errno_location ();
0x000c2d20 mov r2, r5 | r2 = r5;
0x000c2d24 mov r5, 0 | r5 = 0;
0x000c2d28 ldr r1, [r0] | r1 = *(r0);
0x000c2d2c ldr r0, [pc, 0x1b4] | r0 = *(0xc2ee4);
0x000c2d30 add r0, pc, r0 | r0 = pc + r0;
0x000c2d34 bl 0x17750 | printf (r0, r1, r2, r3, r4, r5)
| label_0:
0x000c2d38 mov r0, r5 | r0 = r5;
0x000c2d3c add sp, sp, 0x44 |
0x000c2d40 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x000c2d44 add r2, sp, 0x20 | r2 += var_20h;
0x000c2d48 ldr r1, [pc, 0x19c] | r1 = *(0xc2ee8);
0x000c2d4c ldr sb, [pc, 0x19c] | sb = *(0xc2eec);
0x000c2d50 mov r6, r0 | r6 = r0;
0x000c2d54 ldr r8, [pc, 0x198] | r8 = *(0xc2ef0);
0x000c2d58 bl 0x17a8c | ioctl (r0, r1);
0x000c2d5c ldr fp, [pc, 0x194] | fp = *(0x000c2ef8);
0x000c2d60 ldr r7, [sp, 0x2c] | r7 = var_2ch;
0x000c2d64 mov r3, 0 | r3 = 0;
0x000c2d68 add sb, pc, sb | sb = pc + sb;
0x000c2d6c str r7, [sp, 0x1c] | var_1ch = r7;
0x000c2d70 str r3, [sp, 0x18] | var_18h = r3;
| label_1:
0x000c2d74 ldr r3, [sp, 0x18] | r3 = var_18h;
0x000c2d78 ldr r2, [sp, 0x28] | r2 = var_28h;
0x000c2d7c mov r5, 0 | r5 = 0;
0x000c2d80 cmp r3, r2 |
| if (r3 <= r2) {
0x000c2d84 blo 0xc2ddc | goto label_4;
| }
0x000c2d88 ldr fp, [pc, 0x16c] | fp = *(0x000c2efc);
0x000c2d8c add r3, sp, 0x10 | r3 += var_10h;
0x000c2d90 add fp, pc, fp |
0x000c2d94 str r3, [sp, 0xc] | var_ch = r3;
| do {
0x000c2d98 ldr r3, [sp, 0x28] | r3 = var_28h;
0x000c2d9c cmp r3, r5 |
| if (r3 <= r5) {
0x000c2da0 ble 0xc2ec4 | goto label_5;
| }
0x000c2da4 mov r8, r5 | r8 = r5;
0x000c2da8 asr sb, r5, 0x1f | sb = r5 >> 0x1f;
0x000c2dac ldr r2, [sp, 0xc] | r2 = var_ch;
0x000c2db0 ldr r1, [pc, 0x13c] | r1 = *(0xc2ef0);
0x000c2db4 mov r0, r6 | r0 = r6;
0x000c2db8 strd r8, sb, [sp, 0x10] | __asm ("strd r8, sb, [var_10h]");
0x000c2dbc bl 0x17a8c | r0 = ioctl (r0, r1);
0x000c2dc0 cmp r0, 0 |
| if (r0 == 0) {
0x000c2dc4 beq 0xc2e5c | goto label_6;
| }
0x000c2dc8 mov r1, r5 | r1 = r5;
0x000c2dcc mov r0, fp | r0 = fp;
0x000c2dd0 bl 0x17750 | printf (r0, r1)
| label_2:
0x000c2dd4 add r5, r5, r7 | r5 += r7;
0x000c2dd8 b 0xc2d98 |
| } while (1);
| label_4:
0x000c2ddc add r2, sp, 0x10 | r2 += var_10h;
0x000c2de0 mov r1, r8 | r1 = r8;
0x000c2de4 mov r0, r6 | r0 = r6;
0x000c2de8 str r5, [sp, 0x14] | var_14h = r5;
0x000c2dec str r3, [sp, 0x10] | var_10h = r3;
0x000c2df0 bl 0x17a8c | r0 = ioctl (r0, r1);
0x000c2df4 subs r5, r0, 0 | r5 = r0 - 0;
| if (r5 == r0) {
0x000c2df8 bne 0xc2e3c |
0x000c2dfc add r2, sp, 0x18 | r2 += var_18h;
0x000c2e00 mov r1, fp | r1 = fp;
0x000c2e04 mov r0, r6 | r0 = r6;
0x000c2e08 bl 0x17a8c | r0 = ioctl (r0, r1);
0x000c2e0c subs r2, r0, 0 | r2 = r0 - 0;
| if (r2 == r0) {
0x000c2e10 beq 0xc2e4c | goto label_7;
| }
0x000c2e14 str r2, [sp, 0xc] | var_ch = r2;
0x000c2e18 bl 0x17e58 | errno_location ();
0x000c2e1c ldr r2, [sp, 0xc] | r2 = var_ch;
0x000c2e20 ldr r1, [r0] | r1 = *(r0);
0x000c2e24 ldr r0, [pc, 0xd4] | r0 = *(0xc2efc);
0x000c2e28 add r0, pc, r0 | r0 = pc + r0;
0x000c2e2c bl 0x17750 | printf (r0, r1, r2)
| label_3:
0x000c2e30 mov r0, r6 | r0 = r6;
0x000c2e34 bl 0x184c4 | close (r0);
0x000c2e38 b 0xc2d38 | goto label_0;
| }
0x000c2e3c mov r2, r5 | r2 = r5;
0x000c2e40 ldr r1, [sp, 0x18] | r1 = var_18h;
0x000c2e44 mov r0, sb | r0 = sb;
0x000c2e48 bl 0x17750 | printf (r0, r1, r2)
| label_7:
0x000c2e4c ldrd r2, r3, [sp, 0x18] | __asm ("ldrd r2, r3, [var_1ch]");
0x000c2e50 add r3, r3, r2 | r3 += r2;
0x000c2e54 str r3, [sp, 0x18] | var_18h = r3;
0x000c2e58 b 0xc2d74 | goto label_1;
| label_6:
0x000c2e5c mov r3, sb | r3 = sb;
0x000c2e60 str r0, [sp] | *(sp) = r0;
0x000c2e64 mov r2, r5 | r2 = r5;
0x000c2e68 mov r0, r6 | r0 = r6;
0x000c2e6c bl 0x1829c | lseek64 ();
0x000c2e70 cmp r4, r7 |
| if (r4 >= r7) {
0x000c2e74 movlt r8, r4 | r8 = r4;
| }
| if (r4 < r7) {
0x000c2e78 movge r8, r7 | r8 = r7;
| }
0x000c2e7c mov r2, r8 | r2 = r8;
0x000c2e80 mov r1, sl | r1 = sl;
0x000c2e84 mov r0, r6 | r0 = r6;
0x000c2e88 bl 0x17e94 | r0 = write (r0, r1, r2);
0x000c2e8c cmp r8, r0 |
0x000c2e90 mov sb, r0 | sb = r0;
| if (r8 != r0) {
0x000c2e94 bne 0xc2eac | goto label_8;
| }
0x000c2e98 subs r4, r4, r8 | r4 -= r8;
0x000c2e9c add sl, sl, r8 | sl += r8;
| if (r4 != r4) {
0x000c2ea0 bne 0xc2dd4 | goto label_2;
| }
0x000c2ea4 mov r5, 1 | r5 = 1;
0x000c2ea8 b 0xc2e30 | goto label_3;
| label_8:
0x000c2eac bl 0x17e58 | errno_location ();
0x000c2eb0 mov r2, sb | r2 = sb;
0x000c2eb4 ldr r1, [r0] | r1 = *(r0);
0x000c2eb8 ldr r0, [pc, 0x44] | r0 = *(0xc2f00);
0x000c2ebc add r0, pc, r0 | r0 = pc + r0;
0x000c2ec0 bl 0x17750 | printf (r0, r1, r2)
| label_5:
0x000c2ec4 ldr r0, [pc, 0x3c] | r0 = *(0xc2f04);
0x000c2ec8 mov r1, r4 | r1 = r4;
0x000c2ecc add r0, pc, r0 | r0 = pc + r0;
0x000c2ed0 bl 0x17750 | printf (r0, r1)
0x000c2ed4 ldr r0, [pc, 0x30] | r0 = *(0xc2f08);
0x000c2ed8 mov r5, 0 | r5 = 0;
0x000c2edc add r0, pc, r0 | r0 = pc + r0;
0x000c2ee0 bl 0x179b4 | puts (r0);
0x000c2ee4 b 0xc2e30 | goto label_3;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc2f38 */
| #include <stdint.h>
|
; (fcn) fcn.000c2f38 () | void fcn_000c2f38 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_8h;
| char * format;
| int32_t var_10h;
| int32_t var_18h;
| int32_t var_20h;
| int32_t var_24h;
| r0 = arg1;
| r1 = arg2;
0x000c2f38 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000c2f3c mov fp, r1 |
0x000c2f40 sub sp, sp, 0x3c |
0x000c2f44 mov r1, 2 | r1 = 2;
0x000c2f48 mov r5, r0 | r5 = r0;
0x000c2f4c mov r4, r2 | r4 = r2;
0x000c2f50 bl 0x17d80 | r0 = open64 ();
0x000c2f54 cmn r0, 1 |
| if (r0 == 1) {
0x000c2f58 bne 0xc2f84 |
0x000c2f5c bl 0x17e58 | errno_location ();
0x000c2f60 mov r2, r5 | r2 = r5;
0x000c2f64 mov r5, 0 | r5 = 0;
0x000c2f68 ldr r1, [r0] | r1 = *(r0);
0x000c2f6c ldr r0, [pc, 0xf8] | r0 = *(0xc3068);
0x000c2f70 add r0, pc, r0 | r0 = pc + r0;
0x000c2f74 bl 0x17750 | printf (r0, r1, r2, r3, r4, r5)
| label_1:
0x000c2f78 mov r0, r5 | r0 = r5;
0x000c2f7c add sp, sp, 0x3c |
0x000c2f80 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
0x000c2f84 add r2, sp, 0x18 | r2 += var_18h;
0x000c2f88 ldr r1, [pc, 0xe0] | r1 = *(0xc306c);
0x000c2f8c mov r6, r0 | r6 = r0;
0x000c2f90 bl 0x17a8c | r0 = ioctl (r0, r1);
0x000c2f94 subs r7, r0, 0 | r7 = r0 - 0;
| if (r7 != r0) {
0x000c2f98 bne 0xc3064 | goto label_2;
| }
0x000c2f9c add r3, sp, 0x10 | r3 += var_10h;
0x000c2fa0 str r3, [sp, 8] | var_8h = r3;
0x000c2fa4 ldr r3, [pc, 0xc8] | r3 = *(0xc3070);
0x000c2fa8 ldr sl, [sp, 0x24] | sl = var_24h;
0x000c2fac add r3, pc, r3 | r3 = pc + r3;
0x000c2fb0 str r3, [sp, 0xc] | format = r3;
| do {
0x000c2fb4 ldr r3, [sp, 0x20] | r3 = var_20h;
0x000c2fb8 cmp r3, r7 |
| if (r3 <= r7) {
0x000c2fbc ble 0xc3064 | goto label_2;
| }
0x000c2fc0 mov r8, r7 | r8 = r7;
0x000c2fc4 asr sb, r7, 0x1f | sb = r7 >> 0x1f;
0x000c2fc8 ldr r2, [sp, 8] | r2 = var_8h;
0x000c2fcc ldr r1, [pc, 0xa4] | r1 = *(0xc3074);
0x000c2fd0 mov r0, r6 | r0 = r6;
0x000c2fd4 strd r8, sb, [sp, 0x10] | __asm ("strd r8, sb, [var_10h]");
0x000c2fd8 bl 0x17a8c | r0 = ioctl (r0, r1);
0x000c2fdc subs r5, r0, 0 | r5 = r0 - 0;
| if (r5 == r0) {
0x000c2fe0 beq 0xc2ff8 | goto label_3;
| }
0x000c2fe4 mov r1, r7 | r1 = r7;
0x000c2fe8 ldr r0, [sp, 0xc] | r0 = format;
0x000c2fec bl 0x17750 | printf (r0, r1)
| label_0:
0x000c2ff0 add r7, r7, sl | r7 += sl;
0x000c2ff4 b 0xc2fb4 |
| } while (1);
| label_3:
0x000c2ff8 mov r2, r7 | r2 = r7;
0x000c2ffc mov r3, sb | r3 = sb;
0x000c3000 str r5, [sp] | *(sp) = r5;
0x000c3004 mov r0, r6 | r0 = r6;
0x000c3008 bl 0x1829c | lseek64 ();
0x000c300c cmp r4, sl |
| if (r4 >= sl) {
0x000c3010 movlt r8, r4 | r8 = r4;
| }
| if (r4 < sl) {
0x000c3014 movge r8, sl | r8 = sl;
| }
0x000c3018 mov r2, r8 | r2 = r8;
0x000c301c mov r1, fp | r1 = fp;
0x000c3020 mov r0, r6 | r0 = r6;
0x000c3024 bl 0x17dd4 | r0 = read (r0, r1, r2);
0x000c3028 cmp r8, r0 |
| if (r8 != r0) {
0x000c302c bne 0xc3044 | goto label_4;
| }
0x000c3030 subs r4, r4, r8 | r4 -= r8;
0x000c3034 add fp, fp, r8 |
| if (r4 != r4) {
0x000c3038 bne 0xc2ff0 | goto label_0;
| }
0x000c303c mov r5, 1 | r5 = 1;
0x000c3040 b 0xc3058 | goto label_5;
| label_4:
0x000c3044 bl 0x17e58 | r0 = errno_location ();
0x000c3048 ldr r1, [r0] | r1 = *(r0);
0x000c304c ldr r0, [pc, 0x28] | r0 = *(0xc3078);
0x000c3050 add r0, pc, r0 | r0 = pc + r0;
0x000c3054 bl 0x17750 | printf (r0, r1)
| do {
| label_5:
0x000c3058 mov r0, r6 | r0 = r6;
0x000c305c bl 0x184c4 | close (r0);
0x000c3060 b 0xc2f78 | goto label_1;
| label_2:
0x000c3064 mov r5, 0 | r5 = 0;
0x000c3068 b 0xc3058 |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc3080 */
| #include <stdint.h>
|
; (fcn) fcn.000c3080 () | void fcn_000c3080 (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_8h;
| int32_t var_ch;
| int32_t var_14h;
| r0 = arg1;
| r1 = arg2;
0x000c3080 push {r4, r5, lr} |
0x000c3084 mov r5, r0 | r5 = r0;
0x000c3088 ldr r0, [pc, 0x70] | r0 = *(0xc30fc);
0x000c308c mov r2, 0 | r2 = 0;
0x000c3090 sub sp, sp, 0x14 |
0x000c3094 mov r4, r1 | r4 = r1;
0x000c3098 add r0, pc, r0 | r0 = pc + r0;
0x000c309c mov r1, 2 | r1 = 2;
0x000c30a0 bl 0x17d80 | open64 ();
0x000c30a4 ldr r2, [pc, 0x58] | r2 = *(0xc3100);
0x000c30a8 add r2, pc, r2 | r2 = pc + r2;
0x000c30ac cmp r0, 0 |
0x000c30b0 str r0, [r2] | *(r2) = r0;
| if (r0 >= 0) {
0x000c30b4 bge 0xc30d8 | goto label_0;
| }
0x000c30b8 bl 0x17e58 | r0 = errno_location ();
0x000c30bc ldr r1, [r0] | r1 = *(r0);
0x000c30c0 ldr r0, [pc, 0x40] | r0 = *(0xc3104);
0x000c30c4 add r0, pc, r0 | r0 = pc + r0;
0x000c30c8 bl 0x17750 | printf (r0, r1)
0x000c30cc mov r0, 0 | r0 = 0;
| do {
0x000c30d0 add sp, sp, 0x14 |
0x000c30d4 pop {r4, r5, pc} |
| label_0:
0x000c30d8 mov r3, r0 | r3 = r0;
0x000c30dc mov r0, 0 | r0 = 0;
0x000c30e0 str r3, [sp] | *(sp) = r3;
0x000c30e4 str r5, [sp, 8] | var_8h = r5;
0x000c30e8 str r0, [sp, 0xc] | var_ch = r0;
0x000c30ec mov r3, 1 | r3 = 1;
0x000c30f0 mov r2, 3 | r2 = 3;
0x000c30f4 mov r1, r4 | r1 = r4;
0x000c30f8 bl 0x17e64 | mmap64 ();
0x000c30fc b 0xc30d0 |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc31f8 */
| #include <stdint.h>
|
; (fcn) fcn.000c31f8 () | void fcn_000c31f8 (int32_t arg_20h, uint32_t arg1, int32_t arg2) {
| int32_t var_0h;
| r0 = arg1;
| r1 = arg2;
0x000c31f8 push {r4, r5, r6, r7, r8, sb, sl, lr} |
0x000c31fc ldr r8, [sp, 0x20] | r8 = *(arg_20h);
0x000c3200 mov r7, r3 | r7 = r3;
0x000c3204 ldr r3, [pc, 0x84c] | r3 = *(0xc3a54);
0x000c3208 cmp r0, r3 |
| if (r0 == r3) {
0x000c320c beq 0xc380c | goto label_16;
| }
| if (r0 > r3) {
0x000c3210 bhi 0xc3358 | goto label_17;
| }
0x000c3214 sub r3, r3, 0x18 | r3 -= 0x18;
0x000c3218 cmp r0, r3 |
| if (r0 == r3) {
0x000c321c beq 0xc36e8 | goto label_18;
| }
0x000c3220 mov r6, r1 | r6 = r1;
0x000c3224 mov r5, r2 | r5 = r2;
| if (r0 <= r3) {
0x000c3228 bhi 0xc32c8 |
0x000c322c sub r3, r3, 8 | r3 -= 8;
0x000c3230 cmp r0, r3 |
| if (r0 == r3) {
0x000c3234 beq 0xc34a0 | goto label_19;
| }
0x000c3238 add r3, r3, 4 | r3 += 4;
0x000c323c cmp r0, r3 |
| if (r0 == r3) {
0x000c3240 beq 0xc3680 | goto label_20;
| }
0x000c3244 sub r3, r3, 0x1fc0 | r3 -= 0x1fc0;
0x000c3248 sub r3, r3, 8 | r3 -= 8;
0x000c324c cmp r0, r3 |
| if (r0 != r3) {
0x000c3250 bne 0xc32e4 | goto label_0;
| }
0x000c3254 ldr r0, [pc, 0x800] | r0 = *(0xc3a58);
0x000c3258 sub r5, r5, 4 | r5 -= 4;
0x000c325c add r0, pc, r0 | r0 = pc + r0;
0x000c3260 bl 0x179b4 | puts (r0);
0x000c3264 cmp r6, 0 |
0x000c3268 clz r5, r5 | r5 &= r5;
0x000c326c lsr r5, r5, 5 | r5 >>= 5;
| if (r6 != 0) {
0x000c3270 moveq r5, 0 | r5 = 0;
| }
0x000c3274 cmp r5, 0 |
| if (r5 != 0) {
0x000c3278 beq 0xc3298 |
0x000c327c ldr r3, [r6] | r3 = *(r6);
0x000c3280 cmp r3, 2 |
| if (r3 == 2) {
0x000c3284 beq 0xc3a3c | goto label_21;
| }
0x000c3288 cmp r3, 3 |
| if (r3 == 3) {
0x000c328c beq 0xc3a4c | goto label_22;
| }
0x000c3290 cmp r3, 1 |
| if (r3 != 1) {
0x000c3294 bne 0xc32b0 | goto label_15;
| }
| }
0x000c3298 ldr r0, [pc, 0x7c0] | r0 = *(0xc3a5c);
0x000c329c add r0, pc, r0 | r0 = pc + r0;
0x000c32a0 bl 0x179b4 | puts (r0);
0x000c32a4 ldr r0, [pc, 0x7b8] | r0 = *(0xc3a60);
0x000c32a8 add r0, pc, r0 | r0 = pc + r0;
0x000c32ac bl 0x18680 | system (r0);
| label_15:
0x000c32b0 ldr r1, [pc, 0x7b0] | r1 = *(0xc3a64);
0x000c32b4 ldr r0, [pc, 0x7b0] | r0 = *(0xc3a68);
0x000c32b8 add r1, pc, r1 | r1 = pc + r1;
0x000c32bc add r0, pc, r0 | r0 = pc + r0;
0x000c32c0 bl 0x17750 | printf (r0, r1)
0x000c32c4 b 0xc32e4 |
| } else {
0x000c32c8 ldr r3, [pc, 0x7a0] | r3 = *(0xc3a6c);
0x000c32cc cmp r0, r3 |
| if (r0 == r3) {
0x000c32d0 beq 0xc3738 | goto label_23;
| }
| if (r0 > r3) {
0x000c32d4 bhi 0xc32ec | goto label_24;
| }
0x000c32d8 sub r3, r3, 4 | r3 -= 4;
0x000c32dc cmp r0, r3 |
| if (r0 == r3) {
0x000c32e0 beq 0xc3718 | goto label_25;
| }
| }
| do {
| label_0:
0x000c32e4 mov r4, 0 | r4 = 0;
0x000c32e8 b 0xc3730 | goto label_9;
| label_24:
0x000c32ec ldr r3, [pc, 0x780] | r3 = *(0xc3a70);
0x000c32f0 cmp r0, r3 |
| if (r0 == r3) {
0x000c32f4 beq 0xc37c8 | goto label_26;
| }
0x000c32f8 add r3, r3, 8 | r3 += 8;
0x000c32fc cmp r0, r3 |
0x000c3300 bne 0xc32e4 |
| } while (r0 != r3);
0x000c3304 ldr r1, [pc, 0x76c] | r1 = *(0xc3a74);
0x000c3308 ldr r0, [pc, 0x76c] | r0 = *(0xc3a78);
0x000c330c bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c3310 subs sb, r0, 0 | sb = r0 - 0;
| if (sb == r0) {
0x000c3314 beq 0xc32e4 | goto label_0;
| }
0x000c3318 ldr r0, [pc, 0x760] | r0 = *(0xc3a7c);
0x000c331c add r0, pc, r0 | r0 = pc + r0;
0x000c3320 bl 0x179b4 | puts (r0);
0x000c3324 subs r5, r5, 1 | r5--;
| if (r5 == r5) {
0x000c3328 movne r5, 1 | r5 = 1;
| }
0x000c332c cmp r6, 0 |
| if (r6 != 0) {
0x000c3330 moveq r5, 1 | r5 = 1;
| }
0x000c3334 cmp r5, 0 |
| if (r5 == 0) {
0x000c3338 beq 0xc383c | goto label_27;
| }
| label_11:
0x000c333c bl 0x17e58 | errno_location ();
0x000c3340 mov r4, 0 | r4 = 0;
0x000c3344 mov r3, 0x16 | r3 = 0x16;
0x000c3348 str r3, [r0] | *(r0) = r3;
| label_12:
0x000c334c ldr r1, [pc, 0x724] | r1 = *(0xc3a74);
0x000c3350 mov r0, sb | r0 = sb;
0x000c3354 b 0xc36c4 | goto label_6;
| label_17:
0x000c3358 ldr r3, [pc, 0x724] | r3 = *(0xc3a80);
0x000c335c cmp r0, r3 |
| if (r0 == r3) {
0x000c3360 beq 0xc3994 | goto label_28;
| }
| if (r0 > r3) {
0x000c3364 bhi 0xc3410 | goto label_29;
| }
0x000c3368 sub r3, r3, 0xc | r3 -= 0xc;
0x000c336c cmp r0, r3 |
| if (r0 == r3) {
0x000c3370 beq 0xc38a4 | goto label_30;
| }
| if (r0 > r3) {
0x000c3374 bhi 0xc33a0 | goto label_31;
| }
0x000c3378 sub r3, r3, 0x38 | r3 -= 0x38;
0x000c337c cmp r0, r3 |
| if (r0 != r3) {
0x000c3380 bne 0xc32e4 | goto label_0;
| }
0x000c3384 ldr r0, [pc, 0x6fc] | r0 = *(0xc3a84);
0x000c3388 add r0, pc, r0 | r0 = pc + r0;
0x000c338c bl 0x18680 | system (r0);
0x000c3390 ldr r0, [pc, 0x6f4] | r0 = *(0xc3a88);
0x000c3394 add r0, pc, r0 | r0 = pc + r0;
0x000c3398 bl 0x179b4 | puts (r0);
0x000c339c b 0xc3604 | goto label_5;
| label_31:
0x000c33a0 ldr r3, [pc, 0x6e8] | r3 = *(0xc3a8c);
0x000c33a4 cmp r0, r3 |
| if (r0 == r3) {
0x000c33a8 beq 0xc38d0 | goto label_32;
| }
0x000c33ac add r3, r3, 4 | r3 += 4;
0x000c33b0 cmp r0, r3 |
| if (r0 != r3) {
0x000c33b4 bne 0xc32e4 | goto label_0;
| }
0x000c33b8 clz r3, r7 | r3 &= r7;
0x000c33bc lsr r3, r3, 5 | r3 >>= 5;
0x000c33c0 cmp r8, 0x200 |
| if (r8 >= 0x200) {
0x000c33c4 orrlo r3, r3, 1 | r3 |= 1;
| }
0x000c33c8 cmp r3, 0 |
| if (r3 != 0) {
0x000c33cc bne 0xc34b8 | goto label_1;
| }
0x000c33d0 ldr r0, [pc, 0x6bc] | r0 = *(0xc3a90);
0x000c33d4 mov r2, 0x200 | r2 = 0x200;
0x000c33d8 mov r1, r7 | r1 = r7;
0x000c33dc add r0, pc, r0 | r0 = pc + r0;
0x000c33e0 bl 0xc2f38 | r0 = fcn_000c2f38 (r0, r1);
0x000c33e4 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 != r0) {
0x000c33e8 bne 0xc3920 | goto label_33;
| }
0x000c33ec bl 0x17e58 | errno_location ();
0x000c33f0 mov r3, 0x16 | r3 = 0x16;
0x000c33f4 str r3, [r0] | *(r0) = r3;
| label_14:
0x000c33f8 ldr r0, [pc, 0x698] | r0 = *(0xc3a94);
0x000c33fc add r0, pc, r0 | r0 = pc + r0;
0x000c3400 bl 0x179b4 | puts (r0);
0x000c3404 ldr r0, [pc, 0x690] | r0 = *(0xc3a98);
0x000c3408 add r0, pc, r0 | r0 = pc + r0;
0x000c340c b 0xc3804 | goto label_13;
| label_29:
0x000c3410 ldr r3, [pc, 0x688] | r3 = *(0xc3a9c);
0x000c3414 cmp r0, r3 |
| if (r0 == r3) {
0x000c3418 beq 0xc39e4 | goto label_34;
| }
| if (r0 > r3) {
0x000c341c bhi 0xc3464 | goto label_35;
| }
0x000c3420 sub r3, r3, 4 | r3 -= 4;
0x000c3424 cmp r0, r3 |
| if (r0 != r3) {
0x000c3428 bne 0xc32e4 | goto label_0;
| }
0x000c342c subs r4, r8, 4 | r4 = r8 - 4;
| if (r4 == r8) {
0x000c3430 movne r4, 1 | r4 = 1;
| }
0x000c3434 cmp r7, 0 |
| if (r7 != 0) {
0x000c3438 moveq r4, 1 | r4 = 1;
| }
0x000c343c cmp r4, 0 |
| if (r4 != 0) {
0x000c3440 bne 0xc34b8 | goto label_1;
| }
0x000c3444 ldr r0, [pc, 0x658] | r0 = *(0xc3aa0);
0x000c3448 add r0, pc, r0 | r0 = pc + r0;
0x000c344c bl 0x179b4 | puts (r0);
0x000c3450 ldr r0, [pc, 0x650] | r0 = *(0xc3aa4);
0x000c3454 mov r1, r4 | r1 = r4;
0x000c3458 add r0, pc, r0 | r0 = pc + r0;
0x000c345c bl 0x17750 | printf (r0, r1)
0x000c3460 b 0xc3730 | goto label_9;
| label_35:
0x000c3464 ldr r3, [pc, 0x640] | r3 = *(0xc3aa8);
0x000c3468 cmp r0, r3 |
| if (r0 == r3) {
0x000c346c beq 0xc3a24 | goto label_36;
| }
0x000c3470 add r3, r3, 8 | r3 += 8;
0x000c3474 cmp r0, r3 |
| if (r0 != r3) {
0x000c3478 bne 0xc32e4 | goto label_0;
| }
0x000c347c ldr r1, [pc, 0x5f4] | r1 = *(0xc3a74);
0x000c3480 ldr r0, [pc, 0x5f4] | r0 = *(0xc3a78);
0x000c3484 bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c3488 subs r3, r0, 0 | r3 = r0 - 0;
| if (r3 == r0) {
0x000c348c beq 0xc32e4 | goto label_0;
| }
0x000c3490 mov r4, 1 | r4 = 1;
0x000c3494 str r4, [r3, 0x418] | *((r3 + 0x418)) = r4;
0x000c3498 ldr r1, [pc, 0x5d8] | r1 = *(0xc3a74);
0x000c349c b 0xc36c4 | goto label_6;
| label_19:
0x000c34a0 subs r5, r2, 0xc | r5 = r2 - 0xc;
| if (r5 == r2) {
0x000c34a4 movne r5, 1 | r5 = 1;
| }
0x000c34a8 cmp r1, 0 |
| if (r1 != 0) {
0x000c34ac moveq r5, 1 | r5 = 1;
| }
0x000c34b0 cmp r5, 0 |
0x000c34b4 beq 0xc34c8 |
| while (r5 == 0) {
| label_1:
0x000c34b8 bl 0x17e58 | errno_location ();
0x000c34bc mov r3, 0x16 | r3 = 0x16;
0x000c34c0 str r3, [r0] | *(r0) = r3;
0x000c34c4 b 0xc32e4 | goto label_0;
0x000c34c8 ldr r5, [r1, 8] | r5 = *((r1 + 8));
0x000c34cc cmp r5, 0 |
0x000c34d0 beq 0xc34b8 |
| }
0x000c34d4 ldr r3, [r1] | r3 = *(r1);
0x000c34d8 ldr r2, [pc, 0x5d0] | r2 = *(0xc3aac);
0x000c34dc cmp r3, r2 |
| if (r3 == r2) {
0x000c34e0 beq 0xc366c | goto label_37;
| }
| if (r3 > r2) {
0x000c34e4 bhi 0xc3578 | goto label_38;
| }
0x000c34e8 add r2, r2, 0xf8000002 | r2 += 0xf8000002;
0x000c34ec add r2, r2, 0xfe0000 | r2 += 0xfe0000;
0x000c34f0 add r2, r2, 0xff00 | r2 += 0xff00;
0x000c34f4 cmp r3, r2 |
| if (r3 == r2) {
0x000c34f8 beq 0xc360c | goto label_39;
| }
0x000c34fc add r2, r2, 0xf50000 | r2 += 0xf50000;
0x000c3500 add r2, r2, 0xf900 | r2 += 0xf900;
0x000c3504 add r2, r2, 0xf9 | r2 += 0xf9;
0x000c3508 cmp r3, r2 |
| if (r3 != r2) {
0x000c350c bne 0xc34b8 | goto label_1;
| }
0x000c3510 ldr r1, [r5, 8] | r1 = *((r5 + 8));
0x000c3514 cmp r1, 0x1500000 |
| if (r1 > 0x1500000) {
0x000c3518 bhi 0xc34b8 | goto label_1;
| }
0x000c351c ldr r0, [pc, 0x590] | r0 = *(0xc3ab0);
0x000c3520 add r0, pc, r0 | r0 = pc + r0;
0x000c3524 bl 0x17750 | printf (r0)
0x000c3528 ldr r2, [r5, 0x18] | r2 = *((r5 + 0x18));
0x000c352c cmp r2, 0 |
| if (r2 == 0) {
0x000c3530 beq 0xc34b8 | goto label_1;
| }
0x000c3534 ldr r3, [r5, 0x20] | r3 = *((r5 + 0x20));
0x000c3538 cmp r3, 0 |
| if (r3 == 0) {
0x000c353c beq 0xc34b8 | goto label_1;
| }
0x000c3540 ldr r0, [pc, 0x570] | r0 = *(0xc3ab4);
0x000c3544 add r2, r2, 0x200 | r2 += 0x200;
0x000c3548 mov r1, r5 | r1 = r5;
0x000c354c add r0, pc, r0 | r0 = pc + r0;
0x000c3550 bl 0xc2cf8 | r0 = fcn_000c2cf8 (r0, r1);
0x000c3554 cmp r0, 0 |
| if (r0 == 0) {
0x000c3558 beq 0xc34b8 | goto label_1;
| }
0x000c355c ldr r1, [r5, 0x1c] | r1 = *((r5 + 0x1c));
0x000c3560 ldr r0, [pc, 0x554] | r0 = *(0xc3ab8);
0x000c3564 add r1, r1, 0x200 | r1 += 0x200;
0x000c3568 ldr r2, [r5, 0x20] | r2 = *((r5 + 0x20));
0x000c356c add r1, r5, r1 | r1 = r5 + r1;
0x000c3570 add r0, pc, r0 | r0 = pc + r0;
0x000c3574 b 0xc3634 | goto label_4;
| label_38:
0x000c3578 ldr r2, [pc, 0x540] | r2 = *(0xc3abc);
0x000c357c cmp r3, r2 |
| if (r3 == r2) {
0x000c3580 beq 0xc3658 | goto label_40;
| }
0x000c3584 add r2, r2, 0x7000000 | r2 += 0x7000000;
0x000c3588 sub r2, r2, 0xd1000 | r2 -= 0xd1000;
0x000c358c sub r2, r2, 0xff | r2 -= 0xff;
0x000c3590 cmp r3, r2 |
| if (r3 != r2) {
0x000c3594 bne 0xc34b8 | goto label_1;
| }
0x000c3598 bl 0x17e58 | errno_location ();
0x000c359c ldr r2, [r6, 4] | r2 = *((r6 + 4));
0x000c35a0 ldr r3, [pc, 0x51c] | r3 = *(0xc3ac0);
0x000c35a4 cmp r2, r3 |
0x000c35a8 mov r7, r0 | r7 = r0;
| if (r2 != r3) {
0x000c35ac bne 0xc34b8 | goto label_1;
| }
0x000c35b0 ldr r1, [pc, 0x4c0] | r1 = *(0xc3a74);
0x000c35b4 ldr r0, [pc, 0x4c0] | r0 = *(0xc3a78);
0x000c35b8 bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c35bc subs r6, r0, 0 | r6 = r0 - 0;
| if (r6 == r0) {
0x000c35c0 beq 0xc34b8 | goto label_1;
| }
0x000c35c4 mov r4, 0 | r4 = 0;
0x000c35c8 str r4, [r7] | *(r7) = r4;
0x000c35cc ldr r3, [r6, 0x3c] | r3 = *((r6 + 0x3c));
0x000c35d0 tst r3, 2 |
| if ((r3 & 2) != 0) {
0x000c35d4 bne 0xc3640 | goto label_41;
| }
0x000c35d8 ldr r0, [pc, 0x4e8] | r0 = *(0xc3ac4);
0x000c35dc mov r2, 0x400 | r2 = 0x400;
0x000c35e0 mov r1, r5 | r1 = r5;
0x000c35e4 add r0, pc, r0 | r0 = pc + r0;
0x000c35e8 bl 0xc2cf8 | r0 = fcn_000c2cf8 (r0, r1);
0x000c35ec mov r4, r0 | r4 = r0;
| label_3:
0x000c35f0 ldr r1, [pc, 0x480] | r1 = *(0xc3a74);
0x000c35f4 mov r0, r6 | r0 = r6;
0x000c35f8 bl 0xc2f10 | fcn_000c2f10 (r0, r1);
| label_2:
0x000c35fc cmp r4, 0 |
| if (r4 == 0) {
0x000c3600 beq 0xc34b8 | goto label_1;
| }
| label_5:
0x000c3604 mov r4, 1 | r4 = 1;
0x000c3608 b 0xc3730 | goto label_9;
| label_39:
0x000c360c ldr r0, [pc, 0x4b8] | r0 = *(0xc3ac8);
0x000c3610 add r0, pc, r0 | r0 = pc + r0;
0x000c3614 bl 0x179b4 | puts (r0);
0x000c3618 ldr r2, [r5, 8] | r2 = *((r5 + 8));
0x000c361c cmp r2, 0xc0000 |
| if (r2 > 0xc0000) {
0x000c3620 bhi 0xc34b8 | goto label_1;
| }
0x000c3624 ldr r0, [pc, 0x4a4] | r0 = *(0xc3acc);
0x000c3628 add r2, r2, 0x200 | r2 += 0x200;
0x000c362c mov r1, r5 | r1 = r5;
0x000c3630 add r0, pc, r0 | r0 = pc + r0;
| do {
| label_4:
0x000c3634 bl 0xc2cf8 | r0 = fcn_000c2cf8 (r0, r1);
0x000c3638 mov r4, r0 | r4 = r0;
0x000c363c b 0xc35fc | goto label_2;
| label_41:
0x000c3640 ldr r0, [pc, 0x48c] | r0 = *(0xc3ad0);
0x000c3644 mov r3, 0x80000021 | r3 = 0x80000021;
0x000c3648 str r3, [r7] | *(r7) = r3;
0x000c364c add r0, pc, r0 | r0 = pc + r0;
0x000c3650 bl 0x179b4 | puts (r0);
0x000c3654 b 0xc35f0 | goto label_3;
| label_40:
0x000c3658 ldr r0, [pc, 0x478] | r0 = *(0xc3ad4);
0x000c365c mov r2, 0x20000 | r2 = 0x20000;
0x000c3660 mov r1, r5 | r1 = r5;
0x000c3664 add r0, pc, r0 | r0 = pc + r0;
0x000c3668 b 0xc3634 |
| } while (1);
| label_37:
0x000c366c ldr r0, [pc, 0x468] | r0 = *(0xc3ad8);
0x000c3670 mov r2, 0x10000 | r2 = 0x10000;
0x000c3674 mov r1, r5 | r1 = r5;
0x000c3678 add r0, pc, r0 | r0 = pc + r0;
0x000c367c b 0xc3634 | goto label_4;
| label_20:
0x000c3680 ldr r1, [pc, 0x3f0] | r1 = *(0xc3a74);
0x000c3684 ldr r0, [pc, 0x3f0] | r0 = *(0xc3a78);
0x000c3688 bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c368c subs r5, r0, 0 | r5 = r0 - 0;
| if (r5 == r0) {
0x000c3690 beq 0xc32e4 | goto label_0;
| }
0x000c3694 subs r4, r8, 0x400 | r4 = r8 - 0x400;
| if (r4 == r8) {
0x000c3698 movne r4, 1 | r4 = 1;
| }
0x000c369c cmp r7, 0 |
| if (r7 != 0) {
0x000c36a0 moveq r4, 1 | r4 = 1;
| }
0x000c36a4 cmp r4, 0 |
| if (r4 == 0) {
0x000c36a8 beq 0xc36cc | goto label_42;
| }
0x000c36ac bl 0x17e58 | errno_location ();
0x000c36b0 mov r4, 0 | r4 = 0;
0x000c36b4 mov r3, 0x16 | r3 = 0x16;
0x000c36b8 str r3, [r0] | *(r0) = r3;
| do {
0x000c36bc ldr r1, [pc, 0x3b4] | r1 = *(0xc3a74);
0x000c36c0 mov r0, r5 | r0 = r5;
| label_6:
0x000c36c4 bl 0xc2f10 | fcn_000c2f10 (r0, r1);
0x000c36c8 b 0xc3730 | goto label_9;
| label_42:
0x000c36cc mov r3, 0x400 | r3 = 0x400;
0x000c36d0 add r2, r5, 4 | r2 = r5 + 4;
0x000c36d4 mov r1, r3 | r1 = r3;
0x000c36d8 mov r0, r7 | r0 = r7;
0x000c36dc bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000c36e0 mov r4, 1 | r4 = 1;
0x000c36e4 b 0xc36bc |
| } while (1);
| label_18:
0x000c36e8 subs r4, r8, 0x400 | r4 = r8 - 0x400;
| if (r4 == r8) {
0x000c36ec movne r4, 1 | r4 = 1;
| }
0x000c36f0 cmp r7, 0 |
| if (r7 != 0) {
0x000c36f4 moveq r4, 1 | r4 = 1;
| }
0x000c36f8 cmp r4, 0 |
| if (r4 != 0) {
0x000c36fc bne 0xc34b8 | goto label_1;
| }
0x000c3700 ldr r0, [pc, 0x3d8] | r0 = *(0xc3adc);
0x000c3704 mov r2, 0x400 | r2 = 0x400;
0x000c3708 mov r1, r7 | r1 = r7;
0x000c370c add r0, pc, r0 | r0 = pc + r0;
| label_10:
0x000c3710 pop {r4, r5, r6, r7, r8, sb, sl, lr} |
0x000c3714 b 0xc2f38 | void (*0xc2f38)() ();
| label_25:
0x000c3718 bl 0xc310c | r0 = fcn_000c310c ();
0x000c371c subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 != r0) {
0x000c3720 bne 0xc3604 | goto label_5;
| }
0x000c3724 bl 0x17e58 | errno_location ();
0x000c3728 mov r3, 0x16 | r3 = 0x16;
0x000c372c str r3, [r0] | *(r0) = r3;
| label_9:
0x000c3730 mov r0, r4 | r0 = r4;
0x000c3734 pop {r4, r5, r6, r7, r8, sb, sl, pc} |
| label_23:
0x000c3738 ldr r1, [pc, 0x338] | r1 = *(0xc3a74);
0x000c373c ldr r0, [pc, 0x338] | r0 = *(0xc3a78);
0x000c3740 bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c3744 subs r7, r0, 0 | r7 = r0 - 0;
| if (r7 == r0) {
0x000c3748 beq 0xc32e4 | goto label_0;
| }
0x000c374c subs r4, r5, 1 | r4 = r5 - 1;
| if (r4 == r5) {
0x000c3750 movne r4, 1 | r4 = 1;
| }
0x000c3754 cmp r6, 0 |
| if (r6 != 0) {
0x000c3758 moveq r4, 1 | r4 = 1;
| }
0x000c375c cmp r4, 0 |
| if (r4 == 0) {
0x000c3760 beq 0xc3780 | goto label_43;
| }
0x000c3764 bl 0x17e58 | errno_location ();
0x000c3768 mov r4, 0 | r4 = 0;
0x000c376c mov r3, 0x16 | r3 = 0x16;
0x000c3770 str r3, [r0] | *(r0) = r3;
| do {
| label_8:
0x000c3774 ldr r1, [pc, 0x2fc] | r1 = *(0xc3a74);
0x000c3778 mov r0, r7 | r0 = r7;
0x000c377c b 0xc36c4 | goto label_6;
| label_43:
0x000c3780 ldrb r5, [r6] | r5 = *(r6);
0x000c3784 cmp r5, 1 |
| if (r5 != 1) {
0x000c3788 bne 0xc37a0 | goto label_44;
| }
0x000c378c ldr r0, [pc, 0x350] | r0 = *(0xc3ae0);
0x000c3790 add r0, pc, r0 | r0 = pc + r0;
0x000c3794 bl 0x18680 | system (r0);
| label_7:
0x000c3798 mov r4, 1 | r4 = 1;
0x000c379c b 0xc3774 |
| } while (1);
| label_44:
0x000c37a0 cmp r5, 2 |
| if (r5 == 2) {
0x000c37a4 bne 0xc37b8 |
0x000c37a8 ldr r0, [pc, 0x338] | r0 = *(0xc3ae4);
0x000c37ac add r0, pc, r0 | r0 = pc + r0;
0x000c37b0 bl 0x179b4 | puts (r0);
0x000c37b4 b 0xc3798 | goto label_7;
| }
0x000c37b8 bl 0x17e58 | errno_location ();
0x000c37bc mov r3, 0x16 | r3 = 0x16;
0x000c37c0 str r3, [r0] | *(r0) = r3;
0x000c37c4 b 0xc3774 | goto label_8;
| label_26:
0x000c37c8 sub r3, r8, 1 | r3 = r8 - 1;
0x000c37cc cmp r7, 0 |
0x000c37d0 cmpne r3, 0x20000 | __asm ("cmpne r3, 0x20000");
| if (r7 >= 0) {
0x000c37d4 bhs 0xc34b8 | goto label_1;
| }
0x000c37d8 ldr r0, [pc, 0x30c] | r0 = *(0xc3ae8);
0x000c37dc add r0, pc, r0 | r0 = pc + r0;
0x000c37e0 bl 0x179b4 | puts (r0);
0x000c37e4 ldr r0, [pc, 0x304] | r0 = *(0xc3aec);
0x000c37e8 mov r2, r8 | r2 = r8;
0x000c37ec mov r1, r7 | r1 = r7;
0x000c37f0 add r0, pc, r0 | r0 = pc + r0;
0x000c37f4 bl 0xc2f38 | r0 = fcn_000c2f38 (r0, r1);
0x000c37f8 mov r4, r0 | r4 = r0;
0x000c37fc ldr r0, [pc, 0x2f0] | r0 = *(0xc3af0);
0x000c3800 add r0, pc, r0 | r0 = pc + r0;
| label_13:
0x000c3804 bl 0x179b4 | puts (r0);
0x000c3808 b 0xc3730 | goto label_9;
| label_16:
0x000c380c sub r3, r8, 1 | r3 = r8 - 1;
0x000c3810 cmp r7, 0 |
0x000c3814 cmpne r3, 0x10000 | __asm ("cmpne r3, 0x10000");
| if (r7 >= 0) {
0x000c3818 bhs 0xc34b8 | goto label_1;
| }
0x000c381c ldr r0, [pc, 0x2d4] | r0 = *(0xc3af4);
0x000c3820 add r0, pc, r0 | r0 = pc + r0;
0x000c3824 bl 0x179b4 | puts (r0);
0x000c3828 ldr r0, [pc, 0x2cc] | r0 = *(0xc3af8);
0x000c382c mov r2, r8 | r2 = r8;
0x000c3830 mov r1, r7 | r1 = r7;
0x000c3834 add r0, pc, r0 | r0 = pc + r0;
0x000c3838 b 0xc3710 | goto label_10;
| label_27:
0x000c383c cmp r8, 1 |
| if (r8 <= 1) {
0x000c3840 movhi r4, 0 | r4 = 0;
| }
| if (r8 > 1) {
0x000c3844 movls r4, 1 | r4 = 1;
| }
0x000c3848 cmp r7, 0 |
| if (r7 != 0) {
0x000c384c moveq r4, 1 | r4 = 1;
| }
0x000c3850 cmp r4, 0 |
| if (r4 != 0) {
0x000c3854 bne 0xc333c | goto label_11;
| }
0x000c3858 ldrb r5, [r6] | r5 = *(r6);
0x000c385c cmp r5, 1 |
| if (r5 != 1) {
0x000c3860 moveq r3, 2 | r3 = 2;
| }
| if (r5 != 1) {
0x000c3864 addeq r2, sb, 0x420 | r2 = sb + 0x420;
| }
| if (r5 != 1) {
0x000c3868 beq 0xc3880 |
0x000c386c cmp r5, 2 |
| if (r5 != 2) {
0x000c3870 bne 0xc3894 | goto label_45;
| }
0x000c3874 add r2, sb, 0x420 | r2 = sb + 0x420;
0x000c3878 mov r3, r5 | r3 = r5;
0x000c387c add r2, r2, 4 | r2 += 4;
| }
0x000c3880 mov r1, r3 | r1 = r3;
0x000c3884 mov r0, r7 | r0 = r7;
0x000c3888 bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000c388c mov r4, 1 | r4 = 1;
0x000c3890 b 0xc334c | goto label_12;
| label_45:
0x000c3894 bl 0x17e58 | errno_location ();
0x000c3898 mov r3, 0x16 | r3 = 0x16;
0x000c389c str r3, [r0] | *(r0) = r3;
0x000c38a0 b 0xc334c | goto label_12;
| label_30:
0x000c38a4 mov r1, 0x30 | r1 = 0x30;
0x000c38a8 ldr r0, [pc, 0x250] | r0 = *(0xc3afc);
0x000c38ac bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c38b0 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 == r0) {
0x000c38b4 beq 0xc3730 | goto label_9;
| }
0x000c38b8 ldr r3, [pc, 0x244] | r3 = *(0xc3b00);
0x000c38bc mov r1, 0x30 | r1 = 0x30;
0x000c38c0 str r3, [r4, 0xdc4] | *((r4 + 0xdc4)) = r3;
0x000c38c4 add r0, r4, 0xdb0 | r0 = r4 + 0xdb0;
0x000c38c8 bl 0xc2f10 | fcn_000c2f10 (r0, r1);
0x000c38cc b 0xc3604 | goto label_5;
| label_32:
0x000c38d0 sub r3, r8, 1 | r3 = r8 - 1;
0x000c38d4 cmp r7, 0 |
0x000c38d8 cmpne r3, 0x200 | __asm ("cmpne r3, 0x200");
| if (r7 >= 0) {
0x000c38dc bhs 0xc34b8 | goto label_1;
| }
0x000c38e0 ldr r0, [pc, 0x220] | r0 = *(0xc3b04);
0x000c38e4 add r0, pc, r0 | r0 = pc + r0;
0x000c38e8 bl 0x179b4 | puts (r0);
0x000c38ec ldr r0, [pc, 0x218] | r0 = *(0xc3b08);
0x000c38f0 mov r2, r8 | r2 = r8;
0x000c38f4 mov r1, r7 | r1 = r7;
0x000c38f8 add r0, pc, r0 | r0 = pc + r0;
0x000c38fc bl 0xc2f38 | r0 = fcn_000c2f38 (r0, r1);
0x000c3900 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 == r0) {
0x000c3904 bne 0xc3914 |
0x000c3908 bl 0x17e58 | errno_location ();
0x000c390c mov r3, 0x16 | r3 = 0x16;
0x000c3910 str r3, [r0] | *(r0) = r3;
| }
0x000c3914 ldr r0, [pc, 0x1f4] | r0 = *(0xc3b0c);
0x000c3918 add r0, pc, r0 | r0 = pc + r0;
0x000c391c b 0xc3804 | goto label_13;
| label_33:
0x000c3920 ldr r3, [r7, 8] | r3 = *((r7 + 8));
0x000c3924 add r3, r3, 0x200 | r3 += 0x200;
0x000c3928 cmp r8, r3 |
| if (r8 > r3) {
0x000c392c bhi 0xc34b8 | goto label_1;
| }
0x000c3930 ldr r2, [r7, 0x18] | r2 = *((r7 + 0x18));
0x000c3934 ldr r1, [r7, 0x14] | r1 = *((r7 + 0x14));
0x000c3938 ldr r0, [pc, 0x1d4] | r0 = *(0xc3b10);
0x000c393c add r2, r2, 0x200 | r2 += 0x200;
0x000c3940 add r1, r7, r1 | r1 = r7 + r1;
0x000c3944 add r0, pc, r0 | r0 = pc + r0;
0x000c3948 bl 0xc2f38 | r0 = fcn_000c2f38 (r0, r1);
0x000c394c cmp r0, 0 |
0x000c3950 bne 0xc3968 |
| while (r0 == 0) {
0x000c3954 bl 0x17e58 | errno_location ();
0x000c3958 mov r3, 0x16 | r3 = 0x16;
0x000c395c mov r4, 0 | r4 = 0;
0x000c3960 str r3, [r0] | *(r0) = r3;
0x000c3964 b 0xc33f8 | goto label_14;
0x000c3968 ldr r1, [r7, 0x1c] | r1 = *((r7 + 0x1c));
0x000c396c ldr r0, [pc, 0x1a4] | r0 = *(0xc3b14);
0x000c3970 add r1, r1, 0x200 | r1 += 0x200;
0x000c3974 ldr r2, [r7, 0x20] | r2 = *((r7 + 0x20));
0x000c3978 add r1, r7, r1 | r1 = r7 + r1;
0x000c397c add r0, pc, r0 | r0 = pc + r0;
0x000c3980 bl 0xc2f38 | r0 = fcn_000c2f38 (r0, r1);
0x000c3984 cmp r0, 0 |
0x000c3988 beq 0xc3954 |
| }
0x000c398c mov r4, 1 | r4 = 1;
0x000c3990 b 0xc33f8 | goto label_14;
| label_28:
0x000c3994 ldr r1, [pc, 0x180] | r1 = *(0xc3b18);
0x000c3998 clz r3, r7 | r3 &= r7;
0x000c399c sub r2, r8, 1 | r2 = r8 - 1;
0x000c39a0 lsr r3, r3, 5 | r3 >>= 5;
0x000c39a4 cmp r2, r1 |
| if (r2 <= r1) {
0x000c39a8 orrhi r3, r3, 1 | r3 |= 1;
| }
0x000c39ac cmp r3, 0 |
| if (r3 != 0) {
0x000c39b0 bne 0xc34b8 | goto label_1;
| }
0x000c39b4 ldr r0, [pc, 0x164] | r0 = *(0xc3b1c);
0x000c39b8 add r0, pc, r0 | r0 = pc + r0;
0x000c39bc bl 0x179b4 | puts (r0);
0x000c39c0 ldr r0, [pc, 0x15c] | r0 = *(0xc3b20);
0x000c39c4 mov r2, r8 | r2 = r8;
0x000c39c8 mov r1, r7 | r1 = r7;
0x000c39cc add r0, pc, r0 | r0 = pc + r0;
0x000c39d0 bl 0xc2f38 | r0 = fcn_000c2f38 (r0, r1);
0x000c39d4 mov r4, r0 | r4 = r0;
0x000c39d8 ldr r0, [pc, 0x148] | r0 = *(0xc3b24);
0x000c39dc add r0, pc, r0 | r0 = pc + r0;
0x000c39e0 b 0xc3804 | goto label_13;
| label_34:
0x000c39e4 ldr r1, [pc, 0x8c] | r1 = *(0xc3a74);
0x000c39e8 ldr r0, [pc, 0x8c] | r0 = *(0xc3a78);
0x000c39ec bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c39f0 mov r4, r0 | r4 = r0;
0x000c39f4 ldr r0, [pc, 0x130] | r0 = *(0xc3b28);
0x000c39f8 add r0, pc, r0 | r0 = pc + r0;
0x000c39fc bl 0x179b4 | puts (r0);
0x000c3a00 cmp r4, 0 |
| if (r4 != 0) {
0x000c3a04 beq 0xc3a14 |
0x000c3a08 ldr r1, [pc, 0x68] | r1 = *(0xc3a74);
0x000c3a0c mov r0, r4 | r0 = r4;
0x000c3a10 bl 0xc2f10 | fcn_000c2f10 (r0, r1);
| }
0x000c3a14 ldr r0, [pc, 0x114] | r0 = *(0xc3b2c);
0x000c3a18 add r0, pc, r0 | r0 = pc + r0;
| do {
0x000c3a1c bl 0x179b4 | puts (r0);
0x000c3a20 b 0xc32e4 | goto label_0;
| label_36:
0x000c3a24 ldr r0, [pc, 0x108] | r0 = *(0xc3b30);
0x000c3a28 add r0, pc, r0 | r0 = pc + r0;
0x000c3a2c bl 0x179b4 | puts (r0);
0x000c3a30 ldr r0, [pc, 0x100] | r0 = *(0xc3b34);
0x000c3a34 add r0, pc, r0 | r0 = pc + r0;
0x000c3a38 b 0xc3a1c |
| } while (1);
| label_21:
0x000c3a3c ldr r0, [pc, 0xf8] | r0 = *(0xc3b38);
0x000c3a40 add r0, pc, r0 | r0 = pc + r0;
| do {
0x000c3a44 bl 0x179b4 | puts (r0);
0x000c3a48 b 0xc32b0 | goto label_15;
| label_22:
0x000c3a4c ldr r0, [pc, 0xec] | r0 = *(0xc3b3c);
0x000c3a50 add r0, pc, r0 | r0 = pc + r0;
0x000c3a54 b 0xc3a44 |
| } while (1);
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc3b44 */
| #include <stdint.h>
|
; (fcn) fcn.000c3b44 () | void fcn_000c3b44 (int32_t arg2) {
| r1 = arg2;
0x000c3b44 ldr r0, [pc, 0x74] | r0 = *(0xc3bbc);
0x000c3b48 push {r4, lr} |
0x000c3b4c add r0, pc, r0 | r0 = pc + r0;
0x000c3b50 mov r4, r1 | r4 = r1;
0x000c3b54 bl 0x17c18 | r0 = strcmp (r0, r1);
0x000c3b58 cmp r0, 0 |
0x000c3b5c bne 0xc3b68 |
| while (r4 == 0x7b) {
0x000c3b60 mov r0, 0 | r0 = 0;
0x000c3b64 pop {r4, pc} |
0x000c3b68 ldr r0, [pc, 0x54] | r0 = *(0xc3bc0);
0x000c3b6c mov r1, r4 | r1 = r4;
0x000c3b70 add r0, pc, r0 | r0 = pc + r0;
0x000c3b74 bl 0x17c18 | r0 = strcmp (r0, r1);
0x000c3b78 cmp r0, 0 |
| if (r0 != 0) {
0x000c3b7c bne 0xc3bb8 | goto label_0;
| }
0x000c3b80 ldr r1, [pc, 0x40] | r1 = *(0xc3bc4);
0x000c3b84 ldr r0, [pc, 0x40] | r0 = *(0xc3bc8);
0x000c3b88 bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c3b8c subs r3, r0, 0 | r3 = r0 - 0;
| if (r3 == r0) {
0x000c3b90 beq 0xc3bb8 | goto label_0;
| }
0x000c3b94 ldr r1, [pc, 0x2c] | r1 = *(0xc3bc4);
0x000c3b98 ldrb r4, [r3, 0x805] | r4 = *((r3 + 0x805));
0x000c3b9c bl 0xc2f10 | fcn_000c2f10 (r0, r1);
0x000c3ba0 ldr r0, [pc, 0x28] | r0 = *(0xc3bcc);
0x000c3ba4 mov r1, r4 | r1 = r4;
0x000c3ba8 add r0, pc, r0 | r0 = pc + r0;
0x000c3bac bl 0x17750 | printf (r0, r1)
0x000c3bb0 cmp r4, 0x7b |
0x000c3bb4 beq 0xc3b60 |
| }
| label_0:
0x000c3bb8 mov r0, 0xcb | r0 = 0xcb;
0x000c3bbc pop {r4, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc3bd4 */
| #include <stdint.h>
|
; (fcn) fcn.000c3bd4 () | void fcn_000c3bd4 (const char * s2) {
| r1 = s2;
0x000c3bd4 ldr r0, [pc, 0x58] | r0 = *(0xc3c30);
0x000c3bd8 push {r4, r5, r6, lr} |
0x000c3bdc add r0, pc, r0 | r0 = pc + r0;
0x000c3be0 bl 0x17c18 | r0 = strcmp (r0, r1);
0x000c3be4 subs r4, r0, 0 | r4 = r0 - 0;
0x000c3be8 beq 0xc3bf4 |
| while (r5 == r0) {
0x000c3bec mov r0, 1 | r0 = 1;
0x000c3bf0 pop {r4, r5, r6, pc} |
0x000c3bf4 ldr r1, [pc, 0x3c] | r1 = *(0xc3c34);
0x000c3bf8 ldr r0, [pc, 0x3c] | r0 = *(0xc3c38);
0x000c3bfc bl 0xc3080 | r0 = fcn_000c3080 (r0, r1);
0x000c3c00 subs r5, r0, 0 | r5 = r0 - 0;
0x000c3c04 beq 0xc3bec |
| }
0x000c3c08 ldr r0, [pc, 0x30] | r0 = *(0xc3c3c);
0x000c3c0c ldrb r1, [r5, 0x805] | r1 = *((r5 + 0x805));
0x000c3c10 add r0, pc, r0 | r0 = pc + r0;
0x000c3c14 bl 0x17750 | printf (r0, r1)
0x000c3c18 mov r3, 0x7b | r3 = 0x7b;
0x000c3c1c mov r0, r5 | r0 = r5;
0x000c3c20 strb r3, [r5, 0x805] | *((r5 + 0x805)) = r3;
0x000c3c24 ldr r1, [pc, 0xc] | r1 = *(0xc3c34);
0x000c3c28 bl 0xc2f10 | fcn_000c2f10 (r0, r1);
0x000c3c2c mov r0, r4 | r0 = r4;
0x000c3c30 pop {r4, r5, r6, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc3f94 */
| #include <stdint.h>
|
; (fcn) fcn.000c3f94 () | void fcn_000c3f94 (int32_t arg_2ch, int32_t arg_30h, int32_t arg1, int32_t arg2) {
| int32_t var_4h_2;
| time_t * timer;
| int32_t var_ch_2;
| int32_t var_ch;
| int32_t var_10h;
| int32_t var_2ch;
| r0 = arg1;
| r1 = arg2;
0x000c3f94 str r3, [sp, -4]! | *((sp -= 4)) = r3;
0x000c3f98 ldr r3, [pc, 0x170] | r3 = *(0xc410c);
0x000c3f9c push {r4, r5, r6, r7, r8, lr} |
0x000c3fa0 sub sp, sp, 0x14 |
0x000c3fa4 ldr r8, [sp, 0x2c] | r8 = *(arg_2ch);
0x000c3fa8 add r3, pc, r3 | r3 = pc + r3;
0x000c3fac cmp r8, 0 |
| if (r8 != 0) {
0x000c3fb0 beq 0xc4100 |
0x000c3fb4 mov r4, r2 | r4 = r2;
0x000c3fb8 ldr r2, [pc, 0x154] | r2 = *(0xc4110);
0x000c3fbc mov r7, r0 | r7 = r0;
0x000c3fc0 ldr r3, [r3, r2] | r3 = *((r3 + r2));
0x000c3fc4 mov r6, r1 | r6 = r1;
0x000c3fc8 mov r0, r3 | r0 = r3;
0x000c3fcc str r3, [sp, 4] | timer = r3;
0x000c3fd0 bl 0xc3e60 | r0 = fcn_000c3e60 (r0);
0x000c3fd4 cmp r0, r4 |
| if (r0 < r4) {
0x000c3fd8 blt 0xc4100 | goto label_0;
| }
0x000c3fdc ldr r0, [sp, 4] | r0 = timer;
0x000c3fe0 bl 0xc3f5c | fcn_000c3f5c (r0);
0x000c3fe4 mov r3, 0x800 | r3 = 0x800;
0x000c3fe8 mov r1, r3 | r1 = r3;
0x000c3fec mov r2, 0 | r2 = 0;
0x000c3ff0 mov r5, r0 | r5 = r0;
0x000c3ff4 bl 0xb9f54 | fcn_000b9f54 (r0, r1);
0x000c3ff8 mov r0, 0 | r0 = 0;
0x000c3ffc bl 0x17ec4 | time (r0);
0x000c4000 add r3, sp, 0x10 | r3 += var_10h;
0x000c4004 str r0, [r3, -8]! | *((r3 -= 8)) = r0;
0x000c4008 mov r0, r3 | r0 = r3;
0x000c400c bl 0x181d0 | localtime (r0);
0x000c4010 subs r3, r0, 0 | r3 -= timer;
| if (r3 != timer) {
0x000c4014 moveq r4, r3 | r4 = r3;
| }
| if (r3 != timer) {
0x000c4018 beq 0xc403c |
0x000c401c ldr r2, [pc, 0xf4] | r2 = *(0xc4114);
0x000c4020 mov r1, 0x800 | r1 = 0x800;
0x000c4024 add r2, pc, r2 | r2 = pc + r2;
0x000c4028 mov r0, r5 | r0 = r5;
0x000c402c bl 0x17fa8 | strftime (r0, r1, r2, r3);
0x000c4030 mov r0, r5 | r0 = r5;
0x000c4034 bl 0x1772c | r0 = strlen (r0);
0x000c4038 mov r4, r0 | r4 = r0;
| }
0x000c403c cmp r7, 0 |
| if (r7 != 0) {
0x000c4040 beq 0xc4088 |
0x000c4044 mov r0, r7 | r0 = r7;
0x000c4048 bl 0x1772c | strlen (r0);
0x000c404c mov r2, r7 | r2 = r7;
0x000c4050 mov r3, r0 | r3 = r0;
0x000c4054 mov r1, r0 | r1 = r0;
0x000c4058 add r0, r5, r4 | r0 = r5 + r4;
0x000c405c bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000c4060 mov r0, r7 | r0 = r7;
0x000c4064 bl 0x1772c | strlen (r0);
0x000c4068 ldr r2, [pc, 0xac] | r2 = *(0xc4118);
0x000c406c mov r3, 2 | r3 = 2;
0x000c4070 add r2, pc, r2 | r2 = pc + r2;
0x000c4074 mov r1, r3 | r1 = r3;
0x000c4078 add r4, r0, r4 | r4 = r0 + r4;
0x000c407c add r0, r5, r4 | r0 = r5 + r4;
0x000c4080 bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000c4084 add r4, r4, 2 | r4 += 2;
| }
0x000c4088 cmp r6, 0 |
| if (r6 != 0) {
0x000c408c beq 0xc40b8 |
0x000c4090 mov r0, r6 | r0 = r6;
0x000c4094 bl 0x1772c | strlen (r0);
0x000c4098 mov r2, r6 | r2 = r6;
0x000c409c mov r3, r0 | r3 = r0;
0x000c40a0 mov r1, r0 | r1 = r0;
0x000c40a4 add r0, r5, r4 | r0 = r5 + r4;
0x000c40a8 bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000c40ac mov r0, r6 | r0 = r6;
0x000c40b0 bl 0x1772c | r0 = strlen (r0);
0x000c40b4 add r4, r4, r0 | r4 += r0;
| }
0x000c40b8 ldr r2, [pc, 0x60] | r2 = *(0xc411c);
0x000c40bc mov r3, 4 | r3 = 4;
0x000c40c0 mov r1, r3 | r1 = r3;
0x000c40c4 add r2, pc, r2 | r2 = pc + r2;
0x000c40c8 add r0, r5, r4 | r0 = r5 + r4;
0x000c40cc bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000c40d0 add r0, r4, 4 | r0 = r4 + 4;
0x000c40d4 add r2, sp, 0x30 | r2 += arg_30h;
0x000c40d8 mov r1, r8 | r1 = r8;
0x000c40dc add r0, r5, r0 | r0 = r5 + r0;
0x000c40e0 str r2, [sp, 0xc] | var_ch = r2;
0x000c40e4 bl 0x17b34 | vsprintf (r0, r1, r2)
0x000c40e8 ldr r0, [pc, 0x34] | r0 = *(0xc4120);
0x000c40ec mov r1, r5 | r1 = r5;
0x000c40f0 add r0, pc, r0 | r0 = pc + r0;
0x000c40f4 bl 0x17750 | printf (r0, r1)
0x000c40f8 ldr r0, [sp, 4] | r0 = timer;
0x000c40fc bl 0xc3e68 | fcn_000c3e68 (r0);
| }
| label_0:
0x000c4100 add sp, sp, 0x14 |
0x000c4104 pop {r4, r5, r6, r7, r8, lr} |
0x000c4108 add sp, sp, 4 |
0x000c410c bx lr | return;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc4754 */
| #include <stdint.h>
|
; (fcn) fcn.000c4754 () | void fcn_000c4754 (int32_t arg_10h, int32_t arg1, uint32_t arg2) {
| r0 = arg1;
| r1 = arg2;
0x000c4754 cmp r1, 0x80000000 |
0x000c4758 push {r4, r5, r6, lr} |
0x000c475c mov r5, r0 | r5 = r0;
| if (r1 != 0x80000000) {
0x000c4760 moveq r4, 0 | r4 = 0;
| }
| if (r1 != 0x80000000) {
0x000c4764 beq 0xc4774 |
0x000c4768 cmp r1, 0x40000000 |
| if (r1 != 0x40000000) {
0x000c476c moveq r4, 1 | r4 = 1;
| }
| if (r1 != 0x40000000) {
0x000c4770 movne r4, 2 | r4 = 2;
| goto label_0;
| }
| }
| label_0:
0x000c4774 ldr r3, [sp, 0x10] | r3 = *(arg_10h);
0x000c4778 mov r2, 0x1a4 | r2 = 0x1a4;
0x000c477c cmp r3, 2 |
| if (r3 != 2) {
0x000c4780 orreq r4, r4, 0x240 | r4 |= 0x240;
| }
| if (r3 != 2) {
0x000c4784 orreq r4, r4, 1 | r4 |= 1;
| }
0x000c4788 mov r1, r4 | r1 = r4;
0x000c478c mov r0, r5 | r0 = r5;
0x000c4790 bl 0x17d80 | r0 = open64 ();
0x000c4794 cmp r0, 0 |
| if (r0 < 0) {
0x000c4798 popge {r4, r5, r6, pc} |
| }
0x000c479c bl 0x17e58 | errno_location ();
0x000c47a0 mov r3, r4 | r3 = r4;
0x000c47a4 mov r2, r5 | r2 = r5;
0x000c47a8 ldr r1, [r0] | r1 = *(r0);
0x000c47ac ldr r0, [pc, 0xc] | r0 = *(0xc47bc);
0x000c47b0 add r0, pc, r0 | r0 = pc + r0;
0x000c47b4 bl 0x17750 | printf (r0, r1, r2, r3)
0x000c47b8 mvn r0, 0 | r0 = ~0;
0x000c47bc pop {r4, r5, r6, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xc5254 */
| #include <stdint.h>
|
; (fcn) fcn.000c5254 () | void fcn_000c5254 (int32_t arg_38h, int32_t arg_3ch, int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_4h;
| int32_t var_8h;
| int32_t var_14h;
| r0 = arg1;
| r1 = arg2;
0x000c5254 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000c5258 ldr fp, [pc, 0x154] | fp = *(0xc53b0);
0x000c525c mov r5, r0 | r5 = r0;
0x000c5260 ldr r0, [pc, 0x150] | r0 = *(0xc53b4);
0x000c5264 sub sp, sp, 0x14 |
0x000c5268 add r0, pc, r0 | r0 = pc + r0;
0x000c526c mov r6, r2 | r6 = r2;
0x000c5270 ldr r4, [sp, 0x38] | r4 = *(arg_38h);
0x000c5274 mov sb, r1 | sb = r1;
0x000c5278 mov r7, r3 | r7 = r3;
0x000c527c bl 0x183e0 | basename (r0);
0x000c5280 ldr r1, [pc, 0x134] |
0x000c5284 ldr r3, [pc, 0x134] | r3 = *(0xc53bc);
0x000c5288 add r1, pc, r1 | r1 = pc + r1;
0x000c528c add r3, pc, r3 | r3 = pc + r3;
0x000c5290 mov r2, 5 | r2 = 5;
0x000c5294 add r1, r1, 0x7c | r1 = 0xc5434;
0x000c5298 str r6, [sp] | *(sp) = r6;
0x000c529c bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
0x000c52a0 ldr r1, [sp, 0x3c] | r1 = *(arg_3ch);
0x000c52a4 mov r0, r5 | r0 = r5;
0x000c52a8 bl 0xc5200 | fcn_000c5200 (r0);
0x000c52ac ldr r8, [pc, 0x110] | r8 = *(0xc53c0);
0x000c52b0 sub r5, r4, 1 | r5 = r4 - 1;
0x000c52b4 add sl, r4, 7 | sl = r4 + 7;
0x000c52b8 add fp, pc, fp |
0x000c52bc add r8, pc, r8 | r8 = pc + r8;
0x000c52c0 mov r1, r0 | r1 = r0;
0x000c52c4 ldr r0, [pc, 0xfc] | r0 = *(0xc53c4);
0x000c52c8 add r0, pc, r0 | r0 = pc + r0;
0x000c52cc bl 0x17750 | printf (r0, r1, r2, r3, r4, r5)
0x000c52d0 ldr r0, [pc, 0xf4] | r0 = *(0xc53c8);
0x000c52d4 add r0, pc, r0 | r0 = pc + r0;
0x000c52d8 bl 0x17750 | printf (r0)
| do {
0x000c52dc ldrb r1, [r5, 1]! | r1 = *((r5 += 1));
0x000c52e0 mov r0, fp | r0 = fp;
0x000c52e4 bl 0x17750 | printf (r0, r1)
0x000c52e8 cmp r5, sl |
0x000c52ec bne 0xc52dc |
| } while (r5 != sl);
0x000c52f0 ldr r0, [pc, 0xd8] | r0 = *(0xc53cc);
0x000c52f4 ldr sl, [pc, 0xd8] | sl = *(0xc53d0);
0x000c52f8 add r0, pc, r0 | r0 = pc + r0;
0x000c52fc bl 0x179b4 | puts (r0);
0x000c5300 add r5, r4, 8 | r5 = r4 + 8;
0x000c5304 add sl, pc, sl | sl = pc + sl;
| do {
0x000c5308 sub r3, r5, r4 | r3 = r5 - r4;
0x000c530c cmp r7, r3 |
| if (r7 < r3) {
0x000c5310 bls 0xc5324 | goto label_0;
| }
0x000c5314 ldrb r1, [r5], 1 | r1 = *(r5);
| r5++;
0x000c5318 mov r0, sl | r0 = sl;
0x000c531c bl 0x17750 | printf (r0, r1)
0x000c5320 b 0xc5308 |
| } while (1);
| label_0:
0x000c5324 ldr r0, [pc, 0xac] | r0 = *(0xc53d4);
0x000c5328 add r0, pc, r0 | r0 = pc + r0;
0x000c532c bl 0x179b4 | puts (r0);
0x000c5330 ldr r3, [pc, 0xa4] |
0x000c5334 mov r1, r6 | r1 = r6;
0x000c5338 ldr r3, [r8, r3] | r3 = *((r8 + r3));
0x000c533c mov r0, sb | r0 = sb;
0x000c5340 add r2, r3, 0x31c | r2 = r3 + 0x31c;
0x000c5344 str r2, [sp, 8] | var_8h = r2;
0x000c5348 ldr r2, [r3, 0x108] | r2 = *(0xc54e0);
0x000c534c str r2, [sp, 4] | var_4h = r2;
0x000c5350 ldr r3, [r3, 0x104] | r3 = *(0xc54dc);
0x000c5354 mov r2, r7 | r2 = r7;
0x000c5358 str r3, [sp] | *(sp) = r3;
0x000c535c mov r3, r4 | r3 = r4;
0x000c5360 bl 0x17f9c | r0 = MQTTAsync_send ();
0x000c5364 subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 != r0) {
0x000c5368 beq 0xc53a8 |
0x000c536c ldr r0, [pc, 0x6c] | r0 = *(0xc53dc);
0x000c5370 add r0, pc, r0 | r0 = pc + r0;
0x000c5374 bl 0x183e0 | r0 = basename (r0);
0x000c5378 mov r5, r0 | r5 = r0;
0x000c537c mov r0, r4 | r0 = r4;
0x000c5380 bl 0x18044 | MQTTAsync_strerror ();
0x000c5384 ldr r1, [pc, 0x58] |
0x000c5388 ldr r3, [pc, 0x58] | r3 = *(0xc53e4);
0x000c538c add r1, pc, r1 | r1 = pc + r1;
0x000c5390 add r3, pc, r3 | r3 = pc + r3;
0x000c5394 mov r2, 5 | r2 = 5;
0x000c5398 add r1, r1, 0x7c | r1 = 0xc545c;
0x000c539c str r0, [sp] | *(sp) = r0;
0x000c53a0 mov r0, r5 | r0 = r5;
0x000c53a4 bl 0xc3f94 | fcn_000c3f94 (r0, r1, r2, r3);
| }
0x000c53a8 mov r0, r4 | r0 = r4;
0x000c53ac add sp, sp, 0x14 |
0x000c53b0 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xd7a4c */
| #include <stdint.h>
|
; (fcn) fcn.000d7a4c () | void fcn_000d7a4c (int32_t arg1, int32_t arg2) {
| int32_t var_0h;
| int32_t var_8h;
| int32_t var_24h;
| int32_t var_40h;
| int32_t var_48h;
| int32_t var_60h;
| int32_t var_70h;
| int32_t var_264h;
| r0 = arg1;
| r1 = arg2;
0x000d7a4c push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000d7a50 ldr sb, [pc, 0x210] | sb = *(0xd7c64);
0x000d7a54 sub sp, sp, 0x264 |
0x000d7a58 add r5, sp, 8 | r5 += var_8h;
0x000d7a5c mov r8, r0 | r8 = r0;
0x000d7a60 mov r0, r5 | r0 = r5;
0x000d7a64 mov sl, r1 | sl = r1;
0x000d7a68 bl 0x1bae8 | fcn_0001bae8 (r0);
0x000d7a6c ldr r1, [pc, 0x1f8] | r1 = *(0xd7c68);
0x000d7a70 mov r0, r5 | r0 = r5;
0x000d7a74 add r1, pc, r1 | r1 = pc + r1;
0x000d7a78 add sb, pc, sb | sb = pc + sb;
0x000d7a7c bl 0x1c880 | fcn_0001c880 (r0, r1);
0x000d7a80 ldr r1, [pc, 0x1e8] | r1 = *(0xd7c6c);
0x000d7a84 mov r0, r5 | r0 = r5;
0x000d7a88 add r1, pc, r1 | r1 = pc + r1;
0x000d7a8c bl 0x1c880 | fcn_0001c880 (r0, r1);
0x000d7a90 cmp r8, 0 |
0x000d7a94 bne 0xd7ab0 |
| while (fp == 0) {
0x000d7a98 mov r6, 0 | r6 = 0;
| label_0:
0x000d7a9c mov r0, r5 | r0 = r5;
0x000d7aa0 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d7aa4 mov r0, r6 | r0 = r6;
0x000d7aa8 add sp, sp, 0x264 |
0x000d7aac pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
0x000d7ab0 add r6, sp, 0x24 | r6 += var_24h;
0x000d7ab4 mov r1, r5 | r1 = r5;
0x000d7ab8 mov r0, r6 | r0 = r6;
0x000d7abc bl 0x2913c | fcn_0002913c (r0, r1);
0x000d7ac0 ldr r1, [pc, 0x1ac] | r1 = *(0xd7c70);
0x000d7ac4 add r7, sp, 0x40 | r7 += var_40h;
0x000d7ac8 add r1, pc, r1 | r1 = pc + r1;
0x000d7acc mov r0, r7 | r0 = r7;
0x000d7ad0 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d7ad4 ldr r1, [pc, 0x19c] | r1 = *(0xd7c74);
0x000d7ad8 add r4, sp, 0x60 | r4 += var_60h;
0x000d7adc add r1, pc, r1 | r1 = pc + r1;
0x000d7ae0 mov r0, r4 | r0 = r4;
0x000d7ae4 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d7ae8 str r4, [sp] | *(sp) = r4;
0x000d7aec mov r3, r7 | r3 = r7;
0x000d7af0 mov r2, r6 | r2 = r6;
0x000d7af4 mov r1, sl | r1 = sl;
0x000d7af8 mov r0, r8 | r0 = r8;
0x000d7afc bl 0xd7874 | r0 = fcn_000d7874 (r0, r1, r2);
0x000d7b00 mov fp, r0 |
0x000d7b04 mov r0, r4 | r0 = r4;
0x000d7b08 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d7b0c mov r0, r7 | r0 = r7;
0x000d7b10 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d7b14 mov r0, r6 | r0 = r6;
0x000d7b18 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d7b1c cmp fp, 0 |
0x000d7b20 beq 0xd7a98 |
| }
0x000d7b24 ldr r1, [pc, 0x150] | r1 = *(0xd7c78);
0x000d7b28 mov r0, r4 | r0 = r4;
0x000d7b2c add r1, pc, r1 | r1 = pc + r1;
0x000d7b30 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d7b34 mov r2, r4 | r2 = r4;
0x000d7b38 mov r1, sl | r1 = sl;
0x000d7b3c mov r0, r8 | r0 = r8;
0x000d7b40 bl 0x3e5bc | r0 = fcn_0003e5bc (r0, r1);
0x000d7b44 mov r6, r0 | r6 = r0;
0x000d7b48 mov r0, r4 | r0 = r4;
0x000d7b4c bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d7b50 mov r3, 0x20 | r3 = 0x20;
0x000d7b54 mov r2, r8 | r2 = r8;
0x000d7b58 mov r1, r3 | r1 = r3;
0x000d7b5c mov r0, r7 | r0 = r7;
0x000d7b60 bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000d7b64 add r1, sp, 0x48 | r1 += var_48h;
0x000d7b68 mov r0, r4 | r0 = r4;
0x000d7b6c bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d7b70 mov r0, r4 | r0 = r4;
0x000d7b74 bl 0x1d624 | r0 = fcn_0001d624 (r0);
0x000d7b78 mov r7, r0 | r7 = r0;
0x000d7b7c mov r0, r4 | r0 = r4;
0x000d7b80 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d7b84 ldr r3, [pc, 0xf4] | r3 = *(0xd7c7c);
0x000d7b88 ldr r8, [sb, r3] | r8 = *((sb + r3));
0x000d7b8c ldr r3, [r8] | r3 = *(r8);
0x000d7b90 cmp r3, 0 |
| if (r3 != 0) {
0x000d7b94 beq 0xd7bd4 |
0x000d7b98 and r2, r7, 0xf | r2 = r7 & 0xf;
0x000d7b9c add r2, r2, 0x30 | r2 += 0x30;
0x000d7ba0 strb r2, [r3, 0x23] | *((r3 + 0x23)) = r2;
0x000d7ba4 lsr r2, r7, 4 | r2 = r7 >> 4;
0x000d7ba8 and r2, r2, 0xf | r2 &= 0xf;
0x000d7bac add r2, r2, 0x30 | r2 += 0x30;
0x000d7bb0 strb r2, [r3, 0x22] | *((r3 + 0x22)) = r2;
0x000d7bb4 lsr r2, r7, 8 | r2 = r7 >> 8;
0x000d7bb8 and r2, r2, 0xf | r2 &= 0xf;
0x000d7bbc add r2, r2, 0x30 | r2 += 0x30;
0x000d7bc0 strb r2, [r3, 0x21] | *((r3 + 0x21)) = r2;
0x000d7bc4 lsr r2, r7, 0xc | r2 = r7 >> 0xc;
0x000d7bc8 and r2, r2, 0xf | r2 &= 0xf;
0x000d7bcc add r2, r2, 0x30 | r2 += 0x30;
0x000d7bd0 strb r2, [r3, 0x20] | *((r3 + 0x20)) = r2;
| }
0x000d7bd4 mov r3, 0x200 | r3 = 0x200;
0x000d7bd8 mov r2, r6 | r2 = r6;
0x000d7bdc mov r1, r3 | r1 = r3;
0x000d7be0 mov r0, r4 | r0 = r4;
0x000d7be4 bl 0xb9ec8 | fcn_000b9ec8 (r0, r1);
0x000d7be8 ldr r3, [sp, 0x70] | r3 = var_70h;
0x000d7bec ldr r0, [r8] | r0 = *(r8);
0x000d7bf0 sub r1, r6, 1 | r1 = r6 - 1;
0x000d7bf4 str r3, [r0, 0x24] | *((r0 + 0x24)) = r3;
0x000d7bf8 add r3, r6, 0x1fc | r3 = r6 + 0x1fc;
0x000d7bfc add r3, r3, 3 | r3 += 3;
| do {
0x000d7c00 ldrb r2, [r1, 1]! | r2 = *((r1 += 1));
0x000d7c04 ldr ip, [r0, 0x24] | ip = *((r0 + 0x24));
0x000d7c08 cmp r1, r3 |
0x000d7c0c add r2, r2, ip | r2 += ip;
0x000d7c10 str r2, [r0, 0x24] | *((r0 + 0x24)) = r2;
0x000d7c14 bne 0xd7c00 |
| } while (r1 != r3);
0x000d7c18 ldr r0, [pc, 0x64] | r0 = *(0xd7c80);
0x000d7c1c mov r1, r7 | r1 = r7;
0x000d7c20 add r0, pc, r0 | r0 = pc + r0;
0x000d7c24 bl 0x17750 | printf (r0, r1)
0x000d7c28 b 0xd7a9c | goto label_0;
| }
; assembly | /* r2dec pseudo code output */
| /* /logs/firmware/unblob_extracted/firmware_extract/56048-12514271.gzip_extract/gzip.uncompressed_extract/5243916-15068666.gzip_extract/gzip.uncompressed_extract/windows/KT-1 @ 0xd8190 */
| #include <stdint.h>
|
; (fcn) fcn.000d8190 () | void fcn_000d8190 () {
| int32_t var_0h;
| int32_t var_ch;
| void * s1;
| int32_t var_14h;
| int32_t var_18h;
| int32_t var_1ch;
| int32_t var_34h;
| int32_t var_50h;
| int32_t var_6ch;
| int32_t var_70h;
| int32_t var_8ch;
0x000d8190 push {r4, r5, r6, r7, r8, sb, sl, fp, lr} |
0x000d8194 ldr sl, [pc, 0x4e8] | sl = *(0xd8680);
0x000d8198 sub sp, sp, 0x8c |
0x000d819c add r6, sp, 0x18 | r6 += var_18h;
0x000d81a0 mov r0, r6 | r0 = r6;
0x000d81a4 bl 0x1bae8 | fcn_0001bae8 (r0);
0x000d81a8 mov r0, 0xc | r0 = 0xc;
0x000d81ac add sl, pc, sl | sl = pc + sl;
0x000d81b0 bl 0x1769c | r0 = sym ();
0x000d81b4 mov r7, r0 | r7 = r0;
0x000d81b8 bl 0x8580c | fcn_0008580c ();
0x000d81bc bl 0xc4634 | fcn_000c4634 ();
0x000d81c0 ldr r1, [pc, 0x4c0] | r1 = *(0xd8684);
0x000d81c4 add r4, sp, 0x6c | r4 += var_6ch;
0x000d81c8 str r0, [sp, 0x14] | var_14h = r0;
0x000d81cc add r1, pc, r1 | r1 = pc + r1;
0x000d81d0 mov r0, r4 | r0 = r4;
0x000d81d4 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d81d8 add r1, sp, 0x70 | r1 += var_70h;
0x000d81dc add r0, sp, 0x1c | r0 += var_1ch;
0x000d81e0 bl 0x1d84c | method (r0, r1);
0x000d81e4 mov r0, r4 | r0 = r4;
0x000d81e8 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d81ec ldr r1, [pc, 0x498] | r1 = *(0xd8688);
0x000d81f0 mov r0, r6 | r0 = r6;
0x000d81f4 add r1, pc, r1 | r1 = pc + r1;
0x000d81f8 bl 0x1c880 | fcn_0001c880 (r0, r1);
0x000d81fc add r5, sp, 0x50 | r5 += var_50h;
0x000d8200 mov r1, r6 | r1 = r6;
0x000d8204 mov r0, r5 | r0 = r5;
0x000d8208 bl 0x2913c | fcn_0002913c (r0, r1);
0x000d820c ldr r1, [pc, 0x47c] | r1 = *(0xd868c);
0x000d8210 mov r0, r4 | r0 = r4;
0x000d8214 add r1, pc, r1 | r1 = pc + r1;
0x000d8218 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d821c mov r1, r4 | r1 = r4;
0x000d8220 mov r0, r5 | r0 = r5;
0x000d8224 bl 0xc2a4c | r0 = fcn_000c2a4c (r0, r1);
0x000d8228 mov sb, r0 | sb = r0;
0x000d822c mov r0, r4 | r0 = r4;
0x000d8230 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d8234 mov r0, r5 | r0 = r5;
0x000d8238 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d823c ldr r3, [pc, 0x450] | r3 = *(0xd8690);
0x000d8240 mov r1, sb | r1 = sb;
0x000d8244 ldr r3, [sl, r3] | r3 = *(0xd8680);
0x000d8248 mov r0, r3 | r0 = r3;
0x000d824c str r3, [sp, 0xc] | var_ch = r3;
0x000d8250 bl 0x6f02c | r0 = fcn_0006f02c (r0, r1);
0x000d8254 subs r3, r0, 0 | r3 = r0 - 0;
0x000d8258 str r3, [sp, 0x10] | s1 = r3;
| if (r3 == r0) {
0x000d825c bne 0xd826c |
| label_1:
0x000d8260 mov r8, 0 | r8 = 0;
0x000d8264 mov r5, 0 | r5 = 0;
0x000d8268 b 0xd83b4 | goto label_3;
| }
0x000d826c mov r2, sb | r2 = sb;
0x000d8270 ldr r1, [sp, 0x10] | r1 = s1;
0x000d8274 mov r0, r7 | r0 = r7;
0x000d8278 bl 0x85ac0 | r0 = fcn_00085ac0 (r0);
0x000d827c cmp r0, 0 |
| if (r0 != 0) {
0x000d8280 bne 0xd83a0 | goto label_4;
| }
0x000d8284 mov r1, sb | r1 = sb;
0x000d8288 ldr r0, [sp, 0xc] | r0 = var_ch;
0x000d828c bl 0x6f02c | r0 = fcn_0006f02c (r0, r1);
0x000d8290 subs r8, r0, 0 | r8 = r0 - 0;
| if (r8 == r0) {
0x000d8294 beq 0xd838c | goto label_5;
| }
0x000d8298 ldr r1, [pc, 0x3f8] | r1 = *(0xd8694);
0x000d829c add fp, sp, 0x34 |
0x000d82a0 add r1, pc, r1 | r1 = pc + r1;
0x000d82a4 mov r0, fp | r0 = fp;
0x000d82a8 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d82ac ldr r1, [pc, 0x3e8] | r1 = *(0xd8698);
0x000d82b0 mov r0, r5 | r0 = r5;
0x000d82b4 add r1, pc, r1 | r1 = pc + r1;
0x000d82b8 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d82bc ldr r1, [pc, 0x3dc] | r1 = *(0xd869c);
0x000d82c0 mov r0, r4 | r0 = r4;
0x000d82c4 add r1, pc, r1 | r1 = pc + r1;
0x000d82c8 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d82cc str r4, [sp] | *(sp) = r4;
0x000d82d0 mov r3, r5 | r3 = r5;
0x000d82d4 mov r2, fp | r2 = fp;
0x000d82d8 mov r1, sb | r1 = sb;
0x000d82dc mov r0, r8 | r0 = r8;
0x000d82e0 bl 0xd7874 | r0 = fcn_000d7874 (r0, r1, r2);
0x000d82e4 mov fp, r0 |
0x000d82e8 mov r0, r4 | r0 = r4;
0x000d82ec bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d82f0 mov r0, r5 | r0 = r5;
0x000d82f4 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d82f8 add r0, sp, 0x34 | r0 += var_34h;
0x000d82fc bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d8300 cmp fp, 0 |
| if (fp == 0) {
0x000d8304 beq 0xd8380 | goto label_6;
| }
0x000d8308 mov r2, sb | r2 = sb;
0x000d830c mov r1, r8 | r1 = r8;
0x000d8310 ldr r0, [sp, 0x10] | r0 = s1;
0x000d8314 bl 0x17f00 | r0 = memcmp (r0, r1, r2);
0x000d8318 cmp r0, 0 |
| if (r0 == 0) {
0x000d831c beq 0xd836c | goto label_7;
| }
0x000d8320 ldr r0, [pc, 0x37c] | r0 = *(0xd86a0);
0x000d8324 add r0, pc, r0 | r0 = pc + r0;
0x000d8328 bl 0x179b4 | puts (r0);
0x000d832c mov r1, r8 | r1 = r8;
0x000d8330 mov r0, r7 | r0 = r7;
0x000d8334 bl 0x85b60 | r0 = fcn_00085b60 (r0);
0x000d8338 cmp r0, 0 |
| if (r0 != 0) {
0x000d833c bne 0xd8360 | goto label_8;
| }
0x000d8340 ldr r0, [pc, 0x360] | r0 = "EPKcRKS3_";
0x000d8344 add r0, pc, r0 | r0 = pc + r0;
| do {
0x000d8348 bl 0x179b4 | puts (r0);
0x000d834c mov r5, 1 | r5 = 1;
| label_0:
0x000d8350 mov r1, r8 | r1 = r8;
0x000d8354 ldr r0, [sp, 0xc] | r0 = var_ch;
0x000d8358 bl 0x6f1e8 | fcn_0006f1e8 (r0, r1);
0x000d835c b 0xd8390 | goto label_9;
| label_8:
0x000d8360 ldr r0, [pc, 0x344] | r0 = "NSt14basic_ofstreamIcSt11char_traitsIcEE4openEPKcSt13_Ios_Openmode";
0x000d8364 add r0, pc, r0 | r0 = pc + r0;
0x000d8368 b 0xd8348 |
| } while (1);
| label_7:
0x000d836c ldr r0, [pc, 0x33c] | r0 = *(0xd86ac);
0x000d8370 add r0, pc, r0 | r0 = pc + r0;
| do {
0x000d8374 bl 0x179b4 | puts (r0);
0x000d8378 mov r5, 0 | r5 = 0;
0x000d837c b 0xd8350 | goto label_0;
| label_6:
0x000d8380 ldr r0, [pc, 0x32c] | r0 = *(0xd86b0);
0x000d8384 add r0, pc, r0 | r0 = pc + r0;
0x000d8388 b 0xd8374 |
| } while (1);
| label_5:
0x000d838c mov r5, r8 | r5 = r8;
| label_9:
0x000d8390 ldr r1, [sp, 0x10] | r1 = s1;
0x000d8394 ldr r0, [sp, 0xc] | r0 = var_ch;
0x000d8398 bl 0x6f1e8 | fcn_0006f1e8 (r0, r1);
0x000d839c b 0xd83b0 | goto label_10;
| label_4:
0x000d83a0 ldr r0, [pc, 0x310] | r0 = "__Ios_Openmode";
0x000d83a4 add r0, pc, r0 | r0 = pc + r0;
0x000d83a8 bl 0x179b4 | puts (r0);
0x000d83ac b 0xd8260 | goto label_1;
| label_10:
0x000d83b0 mov r8, 0 | r8 = 0;
| label_3:
0x000d83b4 ldr r1, [pc, 0x300] | r1 = *(0xd86b8);
0x000d83b8 mov r0, r4 | r0 = r4;
0x000d83bc add r1, pc, r1 | r1 = pc + r1;
0x000d83c0 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d83c4 b 0xd83d0 |
0x000d83d0 add r1, sp, 0x70 | r1 += var_70h;
0x000d83d4 add r0, sp, 0x1c | r0 += var_1ch;
0x000d83d8 bl 0x1d84c | method (r0, r1);
0x000d83dc mov r0, r4 | r0 = r4;
0x000d83e0 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d83e4 ldr r1, [pc, 0x2d4] | r1 = *(0xd86bc);
0x000d83e8 mov r0, r6 | r0 = r6;
0x000d83ec add r1, pc, r1 | r1 = pc + r1;
0x000d83f0 bl 0x1c880 | fcn_0001c880 (r0, r1);
0x000d83f4 add fp, sp, 0x50 |
0x000d83f8 mov r1, r6 | r1 = r6;
0x000d83fc mov r0, fp | r0 = fp;
0x000d8400 bl 0x2913c | fcn_0002913c (r0, r1);
0x000d8404 ldr r1, [pc, 0x2b8] | r1 = *(0xd86c0);
0x000d8408 mov r0, r4 | r0 = r4;
0x000d840c add r1, pc, r1 | r1 = pc + r1;
0x000d8410 bl 0x1bd9c | fcn_0001bd9c (r0, r1);
0x000d8414 mov r1, r4 | r1 = r4;
0x000d8418 mov r0, fp | r0 = fp;
0x000d841c bl 0xc2a4c | r0 = fcn_000c2a4c (r0, r1);
0x000d8420 mov sb, r0 | sb = r0;
0x000d8424 mov r0, r4 | r0 = r4;
0x000d8428 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d842c mov r0, fp | r0 = fp;
0x000d8430 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d8434 ldr r3, [pc, 0x258] | r3 = *(0xd8690);
0x000d8438 mov r1, sb | r1 = sb;
0x000d843c ldr r3, [sl, r3] | r3 = *((sl + r3));
0x000d8440 mov r0, r3 | r0 = r3;
0x000d8444 str r3, [sp, 0xc] | var_ch = r3;
0x000d8448 bl 0x6f02c | r0 = fcn_0006f02c (r0, r1);
0x000d844c subs r4, r0, 0 | r4 = r0 - 0;
| if (r4 == r0) {
0x000d8450 beq 0xd853c | goto label_11;
| }
0x000d8454 mov r2, sb | r2 = sb;
0x000d8458 mov r1, r4 | r1 = r4;
0x000d845c mov r0, r7 | r0 = r7;
0x000d8460 bl 0x85bfc | r0 = fcn_00085bfc (r0);
0x000d8464 cmp r0, 0 |
| if (r0 != 0) {
0x000d8468 bne 0xd8524 | goto label_12;
| }
0x000d846c mov r1, sb | r1 = sb;
0x000d8470 ldr r0, [sp, 0xc] | r0 = var_ch;
0x000d8474 bl 0x6f02c | r0 = fcn_0006f02c (r0, r1);
0x000d8478 subs fp, r0, 0 |
| if (fp == r0) {
0x000d847c beq 0xd8514 | goto label_13;
| }
0x000d8480 mov r1, sb | r1 = sb;
0x000d8484 bl 0xd7a4c | r0 = fcn_000d7a4c (r0, r1);
0x000d8488 subs sl, r0, 0 | sl = r0 - 0;
| if (sl == r0) {
0x000d848c beq 0xd84fc | goto label_14;
| }
0x000d8490 sub r2, sl, fp | r2 = sl - fp;
0x000d8494 sub r2, sb, r2 | r2 = sb - r2;
0x000d8498 mov r1, sl | r1 = sl;
0x000d849c mov r0, r4 | r0 = r4;
0x000d84a0 bl 0x17f00 | r0 = memcmp (r0, r1, r2);
0x000d84a4 cmp r0, 0 |
| if (r0 == 0) {
0x000d84a8 beq 0xd84f0 | goto label_15;
| }
0x000d84ac ldr r0, [pc, 0x214] | r0 = *(0xd86c4);
0x000d84b0 add r0, pc, r0 | r0 = pc + r0;
0x000d84b4 bl 0x179b4 | puts (r0);
0x000d84b8 add r5, r5, 1 | r5++;
0x000d84bc mov r1, sl | r1 = sl;
0x000d84c0 mov r0, r7 | r0 = r7;
0x000d84c4 and r5, r5, 0xff | r5 &= 0xff;
0x000d84c8 bl 0x85878 | r0 = fcn_00085878 (r0);
0x000d84cc cmp r0, 0 |
| if (r0 != 0) {
0x000d84d0 bne 0xd84e4 | goto label_16;
| }
0x000d84d4 ldr r0, [pc, 0x1f0] | r0 = "sIcEEC2Ev";
0x000d84d8 add r0, pc, r0 | r0 = pc + r0;
| do {
| label_2:
0x000d84dc bl 0x179b4 | puts (r0);
0x000d84e0 b 0xd8508 | goto label_17;
| label_16:
0x000d84e4 ldr r0, [pc, 0x1e4] | r0 = "sIcEEC2Ev";
0x000d84e8 add r0, pc, r0 | r0 = pc + r0;
0x000d84ec b 0xd84dc |
| } while (1);
| label_15:
0x000d84f0 ldr r0, [pc, 0x1dc] | r0 = *(0xd86d0);
0x000d84f4 add r0, pc, r0 | r0 = pc + r0;
0x000d84f8 b 0xd84dc | goto label_2;
| label_14:
0x000d84fc ldr r0, [pc, 0x1d4] | r0 = "ingIcSt11char_traitsIcESaIcEE10_M_replaceEjjPKcj";
0x000d8500 add r0, pc, r0 | r0 = pc + r0;
0x000d8504 b 0xd84dc | goto label_2;
| label_17:
0x000d8508 mov r1, fp | r1 = fp;
0x000d850c ldr r0, [sp, 0xc] | r0 = var_ch;
0x000d8510 bl 0x6f1e8 | fcn_0006f1e8 (r0, r1);
| label_13:
0x000d8514 mov r1, r4 | r1 = r4;
0x000d8518 ldr r0, [sp, 0xc] | r0 = var_ch;
0x000d851c bl 0x6f1e8 | fcn_0006f1e8 (r0, r1);
0x000d8520 b 0xd853c | goto label_11;
| label_12:
0x000d8524 ldr r0, [pc, 0x1b0] | r0 = *(0xd86d8);
0x000d8528 add r0, pc, r0 | r0 = pc + r0;
0x000d852c bl 0x179b4 | puts (r0);
0x000d8530 b 0xd853c |
| label_11:
0x000d853c mov r0, r7 | r0 = r7;
0x000d8540 bl 0x85810 | fcn_00085810 ();
0x000d8544 mov r1, 0xc | r1 = 0xc;
0x000d8548 mov r0, r7 | r0 = r7;
0x000d854c bl 0x17c48 | sym ();
0x000d8550 bl 0xc4634 | fcn_000c4634 ();
0x000d8554 ldr r3, [sp, 0x14] | r3 = var_14h;
0x000d8558 sub r1, r0, r3 | r1 = r0 - r3;
0x000d855c ldr r0, [pc, 0x17c] | r0 = "M_replaceEjjPKcj";
0x000d8560 add r0, pc, r0 | r0 = pc + r0;
0x000d8564 bl 0x17750 | printf ("M_replaceEjjPKcj", r1, r2, r3)
0x000d8568 b 0xd8664 |
0x000d8664 cmp r5, 0 |
0x000d8668 mov r0, r6 | r0 = r6;
| if (r5 != 0) {
0x000d866c moveq r5, r8 | r5 = r8;
| }
| if (r5 == 0) {
0x000d8670 movne r5, 1 | r5 = 1;
| }
0x000d8674 bl 0x1bcc4 | fcn_0001bcc4 (r0);
0x000d8678 mov r0, r5 | r0 = r5;
0x000d867c add sp, sp, 0x8c |
0x000d8680 pop {r4, r5, r6, r7, r8, sb, sl, fp, pc} |
| }
[*] Function printf used 33 times KT-1