// // sub_C5B260 from 0xc5b260 to 0xc5b5d8 (888 bytes) // // 1 xrefs: // > sub_C5D078 @ 0xc5d284 // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // __int64 __fastcall sub_C5B260(__int64 a1, __int64 a2, __int64 a3) { __int64 v3; // x2 __int64 result; // x0 unsigned __int64 v5; // x3 __int64 v6; // x2 _WORD *v7; // x1 __int64 v8; // x6 __int64 v9; // x10 __int64 v10; // x9 unsigned __int64 v11; // x5 _WORD *v12; // x4 unsigned __int64 v13; // x14 unsigned __int64 v14; // x17 unsigned __int64 v15; // x15 __int64 v16; // x18 __int64 v17; // x5 int8x16_t *v18; // x16 int8x16_t *v19; // x5 int8x16_t *v20; // x20 unsigned __int64 v21; // x19 int8x16_t v22; // q1 int8x16_t v23; // q0 __int64 v24; // x4 v3 = a3 / 2; result = *(_QWORD *)(a1 + 848); v5 = *(_QWORD *)(result + 8); if ( (__int64)v5 < v3 ) { result = 2 * v5; v6 = v3 - v5; v7 = (_WORD *)(a2 + 2 * v6 - 2); v8 = v5 - 4; v9 = 2 * v5 - 14; v10 = -2LL * v5 + 8; do { if ( v5 <= 4 ) { switch ( (int)v5 ) { case 0: break; case 1: goto LABEL_32; case 2: goto LABEL_31; case 3: goto LABEL_30; case 4: goto LABEL_29; } } else { if ( v8 > 0 ) { if ( ((__int64)(2 * v5 + 2) < -13 || v7 + 1 <= (_WORD *)((char *)v7 + v9)) && (unsigned __int64)v8 > 9 ) { v11 = (((unsigned __int64)v7 + v9) >> 1) & 7; if ( v11 > v8 ) v11 = v5 - 4; if ( v11 ) { v12 = v7 - 1; v13 = v5 - 5; v7[v5] -= *v7; if ( v11 != 1 ) { v13 = v5 - 6; v12[v5] -= *(v7 - 1); v12 = v7 - 2; if ( v11 != 2 ) { v13 = v5 - 7; v12[v5] -= *(v7 - 2); v12 = v7 - 3; if ( v11 != 3 ) { v13 = v5 - 8; v12[v5] -= *(v7 - 3); v12 = v7 - 4; if ( v11 != 4 ) { v13 = v5 - 9; v12[v5] -= *(v7 - 4); v12 = v7 - 5; if ( v11 != 5 ) { v13 = v5 - 10; v12[v5] -= *(v7 - 5); v12 = v7 - 6; if ( v11 == 7 ) { v13 = v5 - 11; v12[v5] -= *(v7 - 6); v12 = v7 - 7; } } } } } } } else { v13 = v5 - 4; v12 = v7; } v14 = v8 - v11; v15 = ((v8 - v11 - 8) >> 3) + 1; v16 = 8 * v15; if ( v5 - 5 - v11 <= 6 ) goto LABEL_21; v17 = 0x7FFFFFFFFFFFFFFFLL * v11; v18 = (int8x16_t *)((char *)v7 + v9 + v17 * 2); v19 = (int8x16_t *)&v7[v17 - 7]; v20 = v18; v21 = 0; do { v22 = *v18; ++v21; v23 = *v19; --v18; --v19; *v20-- = vqtbl1q_s8( vsubq_s16( vqtbl1q_s8(v22, (int8x16_t)xmmword_C5B5E0), vqtbl1q_s8(v23, (int8x16_t)xmmword_C5B5E0)), (int8x16_t)xmmword_C5B5E0); } while ( v21 < v15 ); v12 -= 8 * v15; v13 -= v16; if ( v14 != v16 ) { LABEL_21: v12[v5] -= *v12; if ( (__int64)(v13 - 1) > 0 ) { v12[v5 - 1] -= *(v12 - 1); if ( v13 != 2 ) { v12[v5 - 2] -= *(v12 - 2); if ( v13 != 3 ) { v12[v5 - 3] -= *(v12 - 3); if ( v13 != 4 ) { v12[v5 - 4] -= *(v12 - 4); if ( v13 != 5 ) { v12[v5 - 5] -= *(v12 - 5); if ( v13 != 6 ) v12[v5 - 6] -= *(v12 - 6); } } } } } } v7 = (_WORD *)((char *)v7 + v10); } else { v24 = 0; do { *(_WORD *)((char *)&v7[v24] + result) -= v7[v24]; --v24; } while ( v24 != 4 - v5 ); v7 = (_WORD *)((char *)v7 + v10); } } LABEL_29: v7[v5] -= *v7; --v7; LABEL_30: v7[v5] -= *v7; --v7; LABEL_31: v7[v5] -= *v7; --v7; LABEL_32: v7[v5] -= *v7; --v7; } v6 -= v5; } while ( v6 > 0 ); } return result; }
GD Web Decomp Icon

GD Web Decomp

Raw Source