
/* WARNING: Unknown calling convention */

void percent_rankValueFunc(sqlite3_context *pCtx)

{
  Mem *pMVar1;
  uint uVar2;
  double dVar3;
  int *piVar4;
  ushort uVar5;
  undefined8 local_34;
  
  pMVar1 = pCtx->pMem;
  if ((pMVar1->flags & 0x2000) == 0) {
    piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,
                                     (sqlite3_context *)0x18);
  }
  else {
    piVar4 = (int *)pMVar1->z;
  }
  if (piVar4 != (int *)0x0) {
    pMVar1 = pCtx->pOut;
    uVar2 = piVar4[4];
    uVar5 = pMVar1->flags & 0x2400;
    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {
      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);
      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /
              (double)local_34;
      if (uVar5 == 0) {
        pMVar1->flags = 1;
      }
      else {
        vdbeMemClearExternAndSetNull(pMVar1);
      }
      if (!NAN(dVar3)) {
        (pMVar1->u).r = dVar3;
        pMVar1->flags = 8;
      }
    }
    else {
      if (uVar5 != 0) {
        vdbeMemClearExternAndSetNull(pMVar1);
      }
      pMVar1->flags = 8;
      (pMVar1->u).r = 0.0;
    }
    *piVar4 = 0;
    piVar4[1] = 0;
  }
  return;
}



void FUN_0006eed0(undefined4 *param_1)

{
  double *pdVar1;
  uint uVar2;
  double dVar3;
  int *piVar4;
  undefined8 local_34;
  
  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {
    piVar4 = (int *)FUN_0006eb30();
  }
  else {
    piVar4 = *(int **)(param_1[2] + 0x10);
  }
  if (piVar4 != (int *)0x0) {
    pdVar1 = (double *)*param_1;
    uVar2 = piVar4[4];
    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {
      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);
      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /
              (double)local_34;
      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {
        *(undefined2 *)(pdVar1 + 1) = 1;
      }
      else {
        FUN_0004c150();
      }
      if (!NAN(dVar3)) {
        *pdVar1 = dVar3;
        *(undefined2 *)(pdVar1 + 1) = 8;
      }
    }
    else {
      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {
        FUN_0004c150();
      }
      *(undefined2 *)(pdVar1 + 1) = 8;
      *pdVar1 = 0.0;
    }
    *piVar4 = 0;
    piVar4[1] = 0;
  }
  return;
}


PUSH EBP
PUSH EDI
PUSH ESI
PUSH EBX
SUB ESP,0x2c
MOV EBX,dword ptr [ESP + 0x40]
MOV EDX,dword ptr [EBX + 0x8]
TEST byte ptr [EDX + 0x9],0x20
JZ 0x0006efb0
MOV EDI,dword ptr [EDX + 0x10]
TEST EDI,EDI
JZ 0x0006ef4d
MOV EBX,dword ptr [EBX]
MOV EAX,dword ptr [EDI + 0x10]
MOV EBP,0x1
MOV EDX,dword ptr [EDI + 0x14]
MOVZX ECX,word ptr [EBX + 0x8]
MOV dword ptr [ESP + 0x8],EAX
MOV dword ptr [ESP + 0xc],EDX
AND CX,0x2400
CMP EBP,EAX
MOV EBP,0x0
SBB EBP,dword ptr [ESP + 0xc]
JL 0x0006ef58
TEST CX,CX
JNZ 0x0006efe0
MOV EAX,0x8
FLDZ
MOV word ptr [EBX + 0x8],AX
FSTP qword ptr [EBX]
JMP 0x0006ef40
FSTP ST0
LEA ESI,[ESI]
MOV dword ptr [EDI],0x0
MOV dword ptr [EDI + 0x4],0x0
ADD ESP,0x2c
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV EAX,dword ptr [EDI]
MOV EDX,dword ptr [EDI + 0x4]
ADD EAX,-0x1
ADC EDX,-0x1
MOV dword ptr [ESP + 0x10],EAX
MOV EAX,dword ptr [ESP + 0x8]
MOV dword ptr [ESP + 0x14],EDX
MOV EDX,dword ptr [ESP + 0xc]
ADD EAX,-0x1
FILD qword ptr [ESP + 0x10]
ADC EDX,-0x1
MOV dword ptr [ESP + 0x8],EAX
MOV dword ptr [ESP + 0xc],EDX
FILD qword ptr [ESP + 0x8]
FDIVP
TEST CX,CX
JNZ 0x0006efc8
MOV ECX,0x1
MOV word ptr [EBX + 0x8],CX
FUCOMI ST0,ST0
JP 0x0006ef38
MOV EDX,0x8
FSTP qword ptr [EBX]
MOV word ptr [EBX + 0x8],DX
JMP 0x0006ef40
LEA EAX,[EBX + 0x4]
MOV ECX,0x18
CALL 0x0006eb30
MOV EDI,EAX
JMP 0x0006eeeb
MOV EAX,EBX
FSTP qword ptr [ESP + 0x8]
CALL 0x0004c150
FLD qword ptr [ESP + 0x8]
JMP 0x0006ef99
MOV EAX,EBX
CALL 0x0004c150
JMP 0x0006ef23
(translation_unit "void FUN_0006eed0(undefined4 *param_1)\n\n{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}\n\n" (function_definition "void FUN_0006eed0(undefined4 *param_1)\n\n{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" primitive_type (function_declarator "FUN_0006eed0(undefined4 *param_1)" identifier (parameter_list "(undefined4 *param_1)" ( (parameter_declaration "undefined4 *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" { (declaration "double *pdVar1;" primitive_type (pointer_declarator "*pdVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "double dVar3;" primitive_type identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "undefined8 local_34;" type_identifier identifier ;) (if_statement "if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" if (parenthesized_expression "((*(byte *)(param_1[2] + 9) & 0x20) == 0)" ( (binary_expression "(*(byte *)(param_1[2] + 9) & 0x20) == 0" (parenthesized_expression "(*(byte *)(param_1[2] + 9) & 0x20)" ( (binary_expression "*(byte *)(param_1[2] + 9) & 0x20" (pointer_expression "*(byte *)(param_1[2] + 9)" * (cast_expression "(byte *)(param_1[2] + 9)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1[2] + 9)" ( (binary_expression "param_1[2] + 9" (subscript_expression "param_1[2]" identifier [ number_literal ]) + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n    piVar4 = (int *)FUN_0006eb30();\n  }" { (expression_statement "piVar4 = (int *)FUN_0006eb30();" (assignment_expression "piVar4 = (int *)FUN_0006eb30()" identifier = (cast_expression "(int *)FUN_0006eb30()" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0006eb30()" identifier (argument_list "()" ( ))))) ;) }) (else_clause "else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" else (compound_statement "{\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" { (expression_statement "piVar4 = *(int **)(param_1[2] + 0x10);" (assignment_expression "piVar4 = *(int **)(param_1[2] + 0x10)" identifier = (pointer_expression "*(int **)(param_1[2] + 0x10)" * (cast_expression "(int **)(param_1[2] + 0x10)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1[2] + 0x10)" ( (binary_expression "param_1[2] + 0x10" (subscript_expression "param_1[2]" identifier [ number_literal ]) + number_literal) ))))) ;) }))) (if_statement "if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" if (parenthesized_expression "(piVar4 != (int *)0x0)" ( (binary_expression "piVar4 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" { (expression_statement "pdVar1 = (double *)*param_1;" (assignment_expression "pdVar1 = (double *)*param_1" identifier = (cast_expression "(double *)*param_1" ( (type_descriptor "double *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "uVar2 = piVar4[4];" (assignment_expression "uVar2 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (if_statement "if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" if (parenthesized_expression "(-piVar4[5] < (int)(uint)(1 < uVar2))" ( (binary_expression "-piVar4[5] < (int)(uint)(1 < uVar2)" (unary_expression "-piVar4[5]" - (subscript_expression "piVar4[5]" identifier [ number_literal ])) < (cast_expression "(int)(uint)(1 < uVar2)" ( (type_descriptor "int" primitive_type) ) (call_expression "(uint)(1 < uVar2)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(1 < uVar2)" ( (binary_expression "1 < uVar2" number_literal < identifier) ))))) )) (compound_statement "{\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }" { (expression_statement "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);" (assignment_expression "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" identifier = (call_expression "CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" identifier (argument_list "(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" ( (binary_expression "piVar4[5] + -1 + (uint)(uVar2 != 0)" (binary_expression "piVar4[5] + -1" (subscript_expression "piVar4[5]" identifier [ number_literal ]) + number_literal) + (call_expression "(uint)(uVar2 != 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(uVar2 != 0)" ( (binary_expression "uVar2 != 0" identifier != number_literal) )))) , (binary_expression "uVar2 - 1" identifier - number_literal) )))) ;) (expression_statement "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;" (assignment_expression "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" identifier = (binary_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" (cast_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" ( (type_descriptor "double" primitive_type) ) (call_expression "CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" identifier (argument_list "(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" ( (binary_expression "piVar4[1] + -1 + (uint)(*piVar4 != 0)" (binary_expression "piVar4[1] + -1" (subscript_expression "piVar4[1]" identifier [ number_literal ]) + number_literal) + (call_expression "(uint)(*piVar4 != 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(*piVar4 != 0)" ( (binary_expression "*piVar4 != 0" (pointer_expression "*piVar4" * identifier) != number_literal) )))) , (binary_expression "*piVar4 + -1" (pointer_expression "*piVar4" * identifier) + number_literal) )))) / (cast_expression "(double)local_34" ( (type_descriptor "double" primitive_type) ) identifier))) ;) (if_statement "if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }" if (parenthesized_expression "((*(ushort *)(pdVar1 + 1) & 0x2400) == 0)" ( (binary_expression "(*(ushort *)(pdVar1 + 1) & 0x2400) == 0" (parenthesized_expression "(*(ushort *)(pdVar1 + 1) & 0x2400)" ( (binary_expression "*(ushort *)(pdVar1 + 1) & 0x2400" (pointer_expression "*(ushort *)(pdVar1 + 1)" * (cast_expression "(ushort *)(pdVar1 + 1)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }" { (expression_statement "*(undefined2 *)(pdVar1 + 1) = 1;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 1" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" * (cast_expression "(undefined2 *)(pdVar1 + 1)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) = number_literal) ;) }) (else_clause "else {\n        FUN_0004c150();\n      }" else (compound_statement "{\n        FUN_0004c150();\n      }" { (expression_statement "FUN_0004c150();" (call_expression "FUN_0004c150()" identifier (argument_list "()" ( ))) ;) }))) (if_statement "if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }" if (parenthesized_expression "(!NAN(dVar3))" ( (unary_expression "!NAN(dVar3)" ! (call_expression "NAN(dVar3)" identifier (argument_list "(dVar3)" ( identifier )))) )) (compound_statement "{\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }" { (expression_statement "*pdVar1 = dVar3;" (assignment_expression "*pdVar1 = dVar3" (pointer_expression "*pdVar1" * identifier) = identifier) ;) (expression_statement "*(undefined2 *)(pdVar1 + 1) = 8;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 8" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" * (cast_expression "(undefined2 *)(pdVar1 + 1)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) = number_literal) ;) })) }) (else_clause "else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" else (compound_statement "{\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" { (if_statement "if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }" if (parenthesized_expression "((*(ushort *)(pdVar1 + 1) & 0x2400) != 0)" ( (binary_expression "(*(ushort *)(pdVar1 + 1) & 0x2400) != 0" (parenthesized_expression "(*(ushort *)(pdVar1 + 1) & 0x2400)" ( (binary_expression "*(ushort *)(pdVar1 + 1) & 0x2400" (pointer_expression "*(ushort *)(pdVar1 + 1)" * (cast_expression "(ushort *)(pdVar1 + 1)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n        FUN_0004c150();\n      }" { (expression_statement "FUN_0004c150();" (call_expression "FUN_0004c150()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "*(undefined2 *)(pdVar1 + 1) = 8;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 8" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" * (cast_expression "(undefined2 *)(pdVar1 + 1)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*pdVar1 = 0.0;" (assignment_expression "*pdVar1 = 0.0" (pointer_expression "*pdVar1" * identifier) = number_literal) ;) }))) (expression_statement "*piVar4 = 0;" (assignment_expression "*piVar4 = 0" (pointer_expression "*piVar4" * identifier) = number_literal) ;) (expression_statement "piVar4[1] = 0;" (assignment_expression "piVar4[1] = 0" (subscript_expression "piVar4[1]" identifier [ number_literal ]) = number_literal) ;) })) (return_statement "return;" return ;) })))
(translation_unit "/* WARNING: Unknown calling convention */\n\nvoid percent_rankValueFunc(sqlite3_context *pCtx)\n\n{\n  Mem *pMVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  ushort uVar5;\n  undefined8 local_34;\n  \n  pMVar1 = pCtx->pMem;\n  if ((pMVar1->flags & 0x2000) == 0) {\n    piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18);\n  }\n  else {\n    piVar4 = (int *)pMVar1->z;\n  }\n  if (piVar4 != (int *)0x0) {\n    pMVar1 = pCtx->pOut;\n    uVar2 = piVar4[4];\n    uVar5 = pMVar1->flags & 0x2400;\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }\n    else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}\n\n" comment (function_definition "void percent_rankValueFunc(sqlite3_context *pCtx)\n\n{\n  Mem *pMVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  ushort uVar5;\n  undefined8 local_34;\n  \n  pMVar1 = pCtx->pMem;\n  if ((pMVar1->flags & 0x2000) == 0) {\n    piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18);\n  }\n  else {\n    piVar4 = (int *)pMVar1->z;\n  }\n  if (piVar4 != (int *)0x0) {\n    pMVar1 = pCtx->pOut;\n    uVar2 = piVar4[4];\n    uVar5 = pMVar1->flags & 0x2400;\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }\n    else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" primitive_type (function_declarator "percent_rankValueFunc(sqlite3_context *pCtx)" identifier (parameter_list "(sqlite3_context *pCtx)" ( (parameter_declaration "sqlite3_context *pCtx" type_identifier (pointer_declarator "*pCtx" * identifier)) ))) (compound_statement "{\n  Mem *pMVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  ushort uVar5;\n  undefined8 local_34;\n  \n  pMVar1 = pCtx->pMem;\n  if ((pMVar1->flags & 0x2000) == 0) {\n    piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18);\n  }\n  else {\n    piVar4 = (int *)pMVar1->z;\n  }\n  if (piVar4 != (int *)0x0) {\n    pMVar1 = pCtx->pOut;\n    uVar2 = piVar4[4];\n    uVar5 = pMVar1->flags & 0x2400;\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }\n    else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" { (declaration "Mem *pMVar1;" type_identifier (pointer_declarator "*pMVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "double dVar3;" primitive_type identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "ushort uVar5;" type_identifier identifier ;) (declaration "undefined8 local_34;" type_identifier identifier ;) (expression_statement "pMVar1 = pCtx->pMem;" (assignment_expression "pMVar1 = pCtx->pMem" identifier = (field_expression "pCtx->pMem" identifier -> field_identifier)) ;) (if_statement "if ((pMVar1->flags & 0x2000) == 0) {\n    piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18);\n  }\n  else {\n    piVar4 = (int *)pMVar1->z;\n  }" if (parenthesized_expression "((pMVar1->flags & 0x2000) == 0)" ( (binary_expression "(pMVar1->flags & 0x2000) == 0" (parenthesized_expression "(pMVar1->flags & 0x2000)" ( (binary_expression "pMVar1->flags & 0x2000" (field_expression "pMVar1->flags" identifier -> field_identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n    piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18);\n  }" { (expression_statement "piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18);" (assignment_expression "piVar4 = (int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18)" identifier = (cast_expression "(int *)createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "createAggContext((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18)" identifier (argument_list "((sqlite3_context *)&pCtx->pFunc,(int)pMVar1,\n                                     (sqlite3_context *)0x18)" ( (cast_expression "(sqlite3_context *)&pCtx->pFunc" ( (type_descriptor "sqlite3_context *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&pCtx->pFunc" & (field_expression "pCtx->pFunc" identifier -> field_identifier))) , (cast_expression "(int)pMVar1" ( (type_descriptor "int" primitive_type) ) identifier) , (cast_expression "(sqlite3_context *)0x18" ( (type_descriptor "sqlite3_context *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ))))) ;) }) (else_clause "else {\n    piVar4 = (int *)pMVar1->z;\n  }" else (compound_statement "{\n    piVar4 = (int *)pMVar1->z;\n  }" { (expression_statement "piVar4 = (int *)pMVar1->z;" (assignment_expression "piVar4 = (int *)pMVar1->z" identifier = (cast_expression "(int *)pMVar1->z" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (field_expression "pMVar1->z" identifier -> field_identifier))) ;) }))) (if_statement "if (piVar4 != (int *)0x0) {\n    pMVar1 = pCtx->pOut;\n    uVar2 = piVar4[4];\n    uVar5 = pMVar1->flags & 0x2400;\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }\n    else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" if (parenthesized_expression "(piVar4 != (int *)0x0)" ( (binary_expression "piVar4 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    pMVar1 = pCtx->pOut;\n    uVar2 = piVar4[4];\n    uVar5 = pMVar1->flags & 0x2400;\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }\n    else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" { (expression_statement "pMVar1 = pCtx->pOut;" (assignment_expression "pMVar1 = pCtx->pOut" identifier = (field_expression "pCtx->pOut" identifier -> field_identifier)) ;) (expression_statement "uVar2 = piVar4[4];" (assignment_expression "uVar2 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (expression_statement "uVar5 = pMVar1->flags & 0x2400;" (assignment_expression "uVar5 = pMVar1->flags & 0x2400" identifier = (binary_expression "pMVar1->flags & 0x2400" (field_expression "pMVar1->flags" identifier -> field_identifier) & number_literal)) ;) (if_statement "if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }\n    else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }" if (parenthesized_expression "(-piVar4[5] < (int)(uint)(1 < uVar2))" ( (binary_expression "-piVar4[5] < (int)(uint)(1 < uVar2)" (unary_expression "-piVar4[5]" - (subscript_expression "piVar4[5]" identifier [ number_literal ])) < (cast_expression "(int)(uint)(1 < uVar2)" ( (type_descriptor "int" primitive_type) ) (call_expression "(uint)(1 < uVar2)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(1 < uVar2)" ( (binary_expression "1 < uVar2" number_literal < identifier) ))))) )) (compound_statement "{\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }\n    }" { (expression_statement "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);" (assignment_expression "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" identifier = (call_expression "CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" identifier (argument_list "(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" ( (binary_expression "piVar4[5] + -1 + (uint)(uVar2 != 0)" (binary_expression "piVar4[5] + -1" (subscript_expression "piVar4[5]" identifier [ number_literal ]) + number_literal) + (call_expression "(uint)(uVar2 != 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(uVar2 != 0)" ( (binary_expression "uVar2 != 0" identifier != number_literal) )))) , (binary_expression "uVar2 - 1" identifier - number_literal) )))) ;) (expression_statement "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;" (assignment_expression "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" identifier = (binary_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" (cast_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" ( (type_descriptor "double" primitive_type) ) (call_expression "CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" identifier (argument_list "(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" ( (binary_expression "piVar4[1] + -1 + (uint)(*piVar4 != 0)" (binary_expression "piVar4[1] + -1" (subscript_expression "piVar4[1]" identifier [ number_literal ]) + number_literal) + (call_expression "(uint)(*piVar4 != 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(*piVar4 != 0)" ( (binary_expression "*piVar4 != 0" (pointer_expression "*piVar4" * identifier) != number_literal) )))) , (binary_expression "*piVar4 + -1" (pointer_expression "*piVar4" * identifier) + number_literal) )))) / (cast_expression "(double)local_34" ( (type_descriptor "double" primitive_type) ) identifier))) ;) (if_statement "if (uVar5 == 0) {\n        pMVar1->flags = 1;\n      }\n      else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }" if (parenthesized_expression "(uVar5 == 0)" ( (binary_expression "uVar5 == 0" identifier == number_literal) )) (compound_statement "{\n        pMVar1->flags = 1;\n      }" { (expression_statement "pMVar1->flags = 1;" (assignment_expression "pMVar1->flags = 1" (field_expression "pMVar1->flags" identifier -> field_identifier) = number_literal) ;) }) (else_clause "else {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }" else (compound_statement "{\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }" { (expression_statement "vdbeMemClearExternAndSetNull(pMVar1);" (call_expression "vdbeMemClearExternAndSetNull(pMVar1)" identifier (argument_list "(pMVar1)" ( identifier ))) ;) }))) (if_statement "if (!NAN(dVar3)) {\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }" if (parenthesized_expression "(!NAN(dVar3))" ( (unary_expression "!NAN(dVar3)" ! (call_expression "NAN(dVar3)" identifier (argument_list "(dVar3)" ( identifier )))) )) (compound_statement "{\n        (pMVar1->u).r = dVar3;\n        pMVar1->flags = 8;\n      }" { (expression_statement "(pMVar1->u).r = dVar3;" (assignment_expression "(pMVar1->u).r = dVar3" (field_expression "(pMVar1->u).r" (parenthesized_expression "(pMVar1->u)" ( (field_expression "pMVar1->u" identifier -> field_identifier) )) . field_identifier) = identifier) ;) (expression_statement "pMVar1->flags = 8;" (assignment_expression "pMVar1->flags = 8" (field_expression "pMVar1->flags" identifier -> field_identifier) = number_literal) ;) })) }) (else_clause "else {\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }" else (compound_statement "{\n      if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }\n      pMVar1->flags = 8;\n      (pMVar1->u).r = 0.0;\n    }" { (if_statement "if (uVar5 != 0) {\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }" if (parenthesized_expression "(uVar5 != 0)" ( (binary_expression "uVar5 != 0" identifier != number_literal) )) (compound_statement "{\n        vdbeMemClearExternAndSetNull(pMVar1);\n      }" { (expression_statement "vdbeMemClearExternAndSetNull(pMVar1);" (call_expression "vdbeMemClearExternAndSetNull(pMVar1)" identifier (argument_list "(pMVar1)" ( identifier ))) ;) })) (expression_statement "pMVar1->flags = 8;" (assignment_expression "pMVar1->flags = 8" (field_expression "pMVar1->flags" identifier -> field_identifier) = number_literal) ;) (expression_statement "(pMVar1->u).r = 0.0;" (assignment_expression "(pMVar1->u).r = 0.0" (field_expression "(pMVar1->u).r" (parenthesized_expression "(pMVar1->u)" ( (field_expression "pMVar1->u" identifier -> field_identifier) )) . field_identifier) = number_literal) ;) }))) (expression_statement "*piVar4 = 0;" (assignment_expression "*piVar4 = 0" (pointer_expression "*piVar4" * identifier) = number_literal) ;) (expression_statement "piVar4[1] = 0;" (assignment_expression "piVar4[1] = 0" (subscript_expression "piVar4[1]" identifier [ number_literal ]) = number_literal) ;) })) (return_statement "return;" return ;) })))
(translation_unit "void FUN_0006eed0(undefined4 *param_1)\n\n{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}\n\n" (function_definition "void FUN_0006eed0(undefined4 *param_1)\n\n{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" primitive_type (function_declarator "FUN_0006eed0(undefined4 *param_1)" identifier (parameter_list "(undefined4 *param_1)" ( (parameter_declaration "undefined4 *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) ))) (compound_statement "{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" { (declaration "double *pdVar1;" primitive_type (pointer_declarator "*pdVar1" * identifier) ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "double dVar3;" primitive_type identifier ;) (declaration "int *piVar4;" primitive_type (pointer_declarator "*piVar4" * identifier) ;) (declaration "undefined8 local_34;" type_identifier identifier ;) (if_statement "if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" if (parenthesized_expression "((*(byte *)(param_1[2] + 9) & 0x20) == 0)" ( (binary_expression "(*(byte *)(param_1[2] + 9) & 0x20) == 0" (parenthesized_expression "(*(byte *)(param_1[2] + 9) & 0x20)" ( (binary_expression "*(byte *)(param_1[2] + 9) & 0x20" (pointer_expression "*(byte *)(param_1[2] + 9)" * (cast_expression "(byte *)(param_1[2] + 9)" ( (type_descriptor "byte *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1[2] + 9)" ( (binary_expression "param_1[2] + 9" (subscript_expression "param_1[2]" identifier [ number_literal ]) + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n    piVar4 = (int *)FUN_0006eb30();\n  }" { (expression_statement "piVar4 = (int *)FUN_0006eb30();" (assignment_expression "piVar4 = (int *)FUN_0006eb30()" identifier = (cast_expression "(int *)FUN_0006eb30()" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "FUN_0006eb30()" identifier (argument_list "()" ( ))))) ;) }) (else_clause "else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" else (compound_statement "{\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" { (expression_statement "piVar4 = *(int **)(param_1[2] + 0x10);" (assignment_expression "piVar4 = *(int **)(param_1[2] + 0x10)" identifier = (pointer_expression "*(int **)(param_1[2] + 0x10)" * (cast_expression "(int **)(param_1[2] + 0x10)" ( (type_descriptor "int **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1[2] + 0x10)" ( (binary_expression "param_1[2] + 0x10" (subscript_expression "param_1[2]" identifier [ number_literal ]) + number_literal) ))))) ;) }))) (if_statement "if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" if (parenthesized_expression "(piVar4 != (int *)0x0)" ( (binary_expression "piVar4 != (int *)0x0" identifier != (cast_expression "(int *)0x0" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" { (expression_statement "pdVar1 = (double *)*param_1;" (assignment_expression "pdVar1 = (double *)*param_1" identifier = (cast_expression "(double *)*param_1" ( (type_descriptor "double *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_1" * identifier))) ;) (expression_statement "uVar2 = piVar4[4];" (assignment_expression "uVar2 = piVar4[4]" identifier = (subscript_expression "piVar4[4]" identifier [ number_literal ])) ;) (if_statement "if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" if (parenthesized_expression "(-piVar4[5] < (int)(uint)(1 < uVar2))" ( (binary_expression "-piVar4[5] < (int)(uint)(1 < uVar2)" (unary_expression "-piVar4[5]" - (subscript_expression "piVar4[5]" identifier [ number_literal ])) < (cast_expression "(int)(uint)(1 < uVar2)" ( (type_descriptor "int" primitive_type) ) (call_expression "(uint)(1 < uVar2)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(1 < uVar2)" ( (binary_expression "1 < uVar2" number_literal < identifier) ))))) )) (compound_statement "{\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }" { (expression_statement "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);" (assignment_expression "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" identifier = (call_expression "CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" identifier (argument_list "(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" ( (binary_expression "piVar4[5] + -1 + (uint)(uVar2 != 0)" (binary_expression "piVar4[5] + -1" (subscript_expression "piVar4[5]" identifier [ number_literal ]) + number_literal) + (call_expression "(uint)(uVar2 != 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(uVar2 != 0)" ( (binary_expression "uVar2 != 0" identifier != number_literal) )))) , (binary_expression "uVar2 - 1" identifier - number_literal) )))) ;) (expression_statement "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;" (assignment_expression "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" identifier = (binary_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" (cast_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" ( (type_descriptor "double" primitive_type) ) (call_expression "CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" identifier (argument_list "(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" ( (binary_expression "piVar4[1] + -1 + (uint)(*piVar4 != 0)" (binary_expression "piVar4[1] + -1" (subscript_expression "piVar4[1]" identifier [ number_literal ]) + number_literal) + (call_expression "(uint)(*piVar4 != 0)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(*piVar4 != 0)" ( (binary_expression "*piVar4 != 0" (pointer_expression "*piVar4" * identifier) != number_literal) )))) , (binary_expression "*piVar4 + -1" (pointer_expression "*piVar4" * identifier) + number_literal) )))) / (cast_expression "(double)local_34" ( (type_descriptor "double" primitive_type) ) identifier))) ;) (if_statement "if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }" if (parenthesized_expression "((*(ushort *)(pdVar1 + 1) & 0x2400) == 0)" ( (binary_expression "(*(ushort *)(pdVar1 + 1) & 0x2400) == 0" (parenthesized_expression "(*(ushort *)(pdVar1 + 1) & 0x2400)" ( (binary_expression "*(ushort *)(pdVar1 + 1) & 0x2400" (pointer_expression "*(ushort *)(pdVar1 + 1)" * (cast_expression "(ushort *)(pdVar1 + 1)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) & number_literal) )) == number_literal) )) (compound_statement "{\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }" { (expression_statement "*(undefined2 *)(pdVar1 + 1) = 1;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 1" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" * (cast_expression "(undefined2 *)(pdVar1 + 1)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) = number_literal) ;) }) (else_clause "else {\n        FUN_0004c150();\n      }" else (compound_statement "{\n        FUN_0004c150();\n      }" { (expression_statement "FUN_0004c150();" (call_expression "FUN_0004c150()" identifier (argument_list "()" ( ))) ;) }))) (if_statement "if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }" if (parenthesized_expression "(!NAN(dVar3))" ( (unary_expression "!NAN(dVar3)" ! (call_expression "NAN(dVar3)" identifier (argument_list "(dVar3)" ( identifier )))) )) (compound_statement "{\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }" { (expression_statement "*pdVar1 = dVar3;" (assignment_expression "*pdVar1 = dVar3" (pointer_expression "*pdVar1" * identifier) = identifier) ;) (expression_statement "*(undefined2 *)(pdVar1 + 1) = 8;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 8" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" * (cast_expression "(undefined2 *)(pdVar1 + 1)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) = number_literal) ;) })) }) (else_clause "else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" else (compound_statement "{\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" { (if_statement "if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }" if (parenthesized_expression "((*(ushort *)(pdVar1 + 1) & 0x2400) != 0)" ( (binary_expression "(*(ushort *)(pdVar1 + 1) & 0x2400) != 0" (parenthesized_expression "(*(ushort *)(pdVar1 + 1) & 0x2400)" ( (binary_expression "*(ushort *)(pdVar1 + 1) & 0x2400" (pointer_expression "*(ushort *)(pdVar1 + 1)" * (cast_expression "(ushort *)(pdVar1 + 1)" ( (type_descriptor "ushort *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) & number_literal) )) != number_literal) )) (compound_statement "{\n        FUN_0004c150();\n      }" { (expression_statement "FUN_0004c150();" (call_expression "FUN_0004c150()" identifier (argument_list "()" ( ))) ;) })) (expression_statement "*(undefined2 *)(pdVar1 + 1) = 8;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 8" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" * (cast_expression "(undefined2 *)(pdVar1 + 1)" ( (type_descriptor "undefined2 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(pdVar1 + 1)" ( (binary_expression "pdVar1 + 1" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*pdVar1 = 0.0;" (assignment_expression "*pdVar1 = 0.0" (pointer_expression "*pdVar1" * identifier) = number_literal) ;) }))) (expression_statement "*piVar4 = 0;" (assignment_expression "*piVar4 = 0" (pointer_expression "*piVar4" * identifier) = number_literal) ;) (expression_statement "piVar4[1] = 0;" (assignment_expression "piVar4[1] = 0" (subscript_expression "piVar4[1]" identifier [ number_literal ]) = number_literal) ;) })) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + LIT) )))) & LIT) )) == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( ))))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + LIT) ))))) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression (unary_expression - (subscript_expression IDENT [ LIT ])) < (cast_expression ( (type_descriptor TYPE) ) (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression LIT < IDENT) ))))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (binary_expression (binary_expression (subscript_expression IDENT [ LIT ]) + LIT) + (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression IDENT != LIT) )))) , (binary_expression IDENT - LIT) )))) ;) (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) (call_expression IDENT (argument_list ( (binary_expression (binary_expression (subscript_expression IDENT [ LIT ]) + LIT) + (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (pointer_expression * IDENT) != LIT) )))) , (binary_expression (pointer_expression * IDENT) + LIT) )))) / (cast_expression ( (type_descriptor TYPE) ) IDENT))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT) )) == LIT) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) }))) (if_statement if (parenthesized_expression ( (unary_expression ! (call_expression IDENT (argument_list ( IDENT )))) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) })) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) & LIT) )) != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( ))) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) }))) (expression_statement (assignment_expression (pointer_expression * IDENT) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) })) (return_statement return ;) })))
(function_definition "void FUN_0006eed0(undefined4 *param_1)\n\n{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" (primitive_type "void") (function_declarator "FUN_0006eed0(undefined4 *param_1)" (identifier "FUN_0006eed0") (parameter_list "(undefined4 *param_1)" (( "(") (parameter_declaration "undefined4 *param_1" (type_identifier "undefined4") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) () ")"))) (compound_statement "{\n  double *pdVar1;\n  uint uVar2;\n  double dVar3;\n  int *piVar4;\n  undefined8 local_34;\n  \n  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }\n  if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }\n  return;\n}" ({ "{") (declaration "double *pdVar1;" (primitive_type "double") (pointer_declarator "*pdVar1" (* "*") (identifier "pdVar1")) (; ";")) (declaration "uint uVar2;" (type_identifier "uint") (identifier "uVar2") (; ";")) (declaration "double dVar3;" (primitive_type "double") (identifier "dVar3") (; ";")) (declaration "int *piVar4;" (primitive_type "int") (pointer_declarator "*piVar4" (* "*") (identifier "piVar4")) (; ";")) (declaration "undefined8 local_34;" (type_identifier "undefined8") (identifier "local_34") (; ";")) (if_statement "if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {\n    piVar4 = (int *)FUN_0006eb30();\n  }\n  else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" (if "if") (parenthesized_expression "((*(byte *)(param_1[2] + 9) & 0x20) == 0)" (( "(") (binary_expression "(*(byte *)(param_1[2] + 9) & 0x20) == 0" (parenthesized_expression "(*(byte *)(param_1[2] + 9) & 0x20)" (( "(") (binary_expression "*(byte *)(param_1[2] + 9) & 0x20" (pointer_expression "*(byte *)(param_1[2] + 9)" (* "*") (cast_expression "(byte *)(param_1[2] + 9)" (( "(") (type_descriptor "byte *" (type_identifier "byte") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1[2] + 9)" (( "(") (binary_expression "param_1[2] + 9" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (+ "+") (number_literal "9")) () ")")))) (& "&") (number_literal "0x20")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    piVar4 = (int *)FUN_0006eb30();\n  }" ({ "{") (expression_statement "piVar4 = (int *)FUN_0006eb30();" (assignment_expression "piVar4 = (int *)FUN_0006eb30()" (identifier "piVar4") (= "=") (cast_expression "(int *)FUN_0006eb30()" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "FUN_0006eb30()" (identifier "FUN_0006eb30") (argument_list "()" (( "(") () ")"))))) (; ";")) (} "}")) (else_clause "else {\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" (else "else") (compound_statement "{\n    piVar4 = *(int **)(param_1[2] + 0x10);\n  }" ({ "{") (expression_statement "piVar4 = *(int **)(param_1[2] + 0x10);" (assignment_expression "piVar4 = *(int **)(param_1[2] + 0x10)" (identifier "piVar4") (= "=") (pointer_expression "*(int **)(param_1[2] + 0x10)" (* "*") (cast_expression "(int **)(param_1[2] + 0x10)" (( "(") (type_descriptor "int **" (primitive_type "int") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1[2] + 0x10)" (( "(") (binary_expression "param_1[2] + 0x10" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (+ "+") (number_literal "0x10")) () ")"))))) (; ";")) (} "}")))) (if_statement "if (piVar4 != (int *)0x0) {\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" (if "if") (parenthesized_expression "(piVar4 != (int *)0x0)" (( "(") (binary_expression "piVar4 != (int *)0x0" (identifier "piVar4") (!= "!=") (cast_expression "(int *)0x0" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n    pdVar1 = (double *)*param_1;\n    uVar2 = piVar4[4];\n    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }\n    *piVar4 = 0;\n    piVar4[1] = 0;\n  }" ({ "{") (expression_statement "pdVar1 = (double *)*param_1;" (assignment_expression "pdVar1 = (double *)*param_1" (identifier "pdVar1") (= "=") (cast_expression "(double *)*param_1" (( "(") (type_descriptor "double *" (primitive_type "double") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_1" (* "*") (identifier "param_1")))) (; ";")) (expression_statement "uVar2 = piVar4[4];" (assignment_expression "uVar2 = piVar4[4]" (identifier "uVar2") (= "=") (subscript_expression "piVar4[4]" (identifier "piVar4") ([ "[") (number_literal "4") (] "]"))) (; ";")) (if_statement "if (-piVar4[5] < (int)(uint)(1 < uVar2)) {\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }\n    else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" (if "if") (parenthesized_expression "(-piVar4[5] < (int)(uint)(1 < uVar2))" (( "(") (binary_expression "-piVar4[5] < (int)(uint)(1 < uVar2)" (unary_expression "-piVar4[5]" (- "-") (subscript_expression "piVar4[5]" (identifier "piVar4") ([ "[") (number_literal "5") (] "]"))) (< "<") (cast_expression "(int)(uint)(1 < uVar2)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (call_expression "(uint)(1 < uVar2)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "(1 < uVar2)" (( "(") (binary_expression "1 < uVar2" (number_literal "1") (< "<") (identifier "uVar2")) () ")"))))) () ")")) (compound_statement "{\n      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);\n      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }\n      if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }\n    }" ({ "{") (expression_statement "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);" (assignment_expression "local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" (identifier "local_34") (= "=") (call_expression "CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" (identifier "CONCAT44") (argument_list "(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1)" (( "(") (binary_expression "piVar4[5] + -1 + (uint)(uVar2 != 0)" (binary_expression "piVar4[5] + -1" (subscript_expression "piVar4[5]" (identifier "piVar4") ([ "[") (number_literal "5") (] "]")) (+ "+") (number_literal "-1")) (+ "+") (call_expression "(uint)(uVar2 != 0)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "(uVar2 != 0)" (( "(") (binary_expression "uVar2 != 0" (identifier "uVar2") (!= "!=") (number_literal "0")) () ")")))) (, ",") (binary_expression "uVar2 - 1" (identifier "uVar2") (- "-") (number_literal "1")) () ")")))) (; ";")) (expression_statement "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34;" (assignment_expression "dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" (identifier "dVar3") (= "=") (binary_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /\n              (double)local_34" (cast_expression "(double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" (( "(") (type_descriptor "double" (primitive_type "double")) () ")") (call_expression "CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" (identifier "CONCAT44") (argument_list "(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1)" (( "(") (binary_expression "piVar4[1] + -1 + (uint)(*piVar4 != 0)" (binary_expression "piVar4[1] + -1" (subscript_expression "piVar4[1]" (identifier "piVar4") ([ "[") (number_literal "1") (] "]")) (+ "+") (number_literal "-1")) (+ "+") (call_expression "(uint)(*piVar4 != 0)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "(*piVar4 != 0)" (( "(") (binary_expression "*piVar4 != 0" (pointer_expression "*piVar4" (* "*") (identifier "piVar4")) (!= "!=") (number_literal "0")) () ")")))) (, ",") (binary_expression "*piVar4 + -1" (pointer_expression "*piVar4" (* "*") (identifier "piVar4")) (+ "+") (number_literal "-1")) () ")")))) (/ "/") (cast_expression "(double)local_34" (( "(") (type_descriptor "double" (primitive_type "double")) () ")") (identifier "local_34")))) (; ";")) (if_statement "if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }\n      else {\n        FUN_0004c150();\n      }" (if "if") (parenthesized_expression "((*(ushort *)(pdVar1 + 1) & 0x2400) == 0)" (( "(") (binary_expression "(*(ushort *)(pdVar1 + 1) & 0x2400) == 0" (parenthesized_expression "(*(ushort *)(pdVar1 + 1) & 0x2400)" (( "(") (binary_expression "*(ushort *)(pdVar1 + 1) & 0x2400" (pointer_expression "*(ushort *)(pdVar1 + 1)" (* "*") (cast_expression "(ushort *)(pdVar1 + 1)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(pdVar1 + 1)" (( "(") (binary_expression "pdVar1 + 1" (identifier "pdVar1") (+ "+") (number_literal "1")) () ")")))) (& "&") (number_literal "0x2400")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        *(undefined2 *)(pdVar1 + 1) = 1;\n      }" ({ "{") (expression_statement "*(undefined2 *)(pdVar1 + 1) = 1;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 1" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" (* "*") (cast_expression "(undefined2 *)(pdVar1 + 1)" (( "(") (type_descriptor "undefined2 *" (type_identifier "undefined2") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(pdVar1 + 1)" (( "(") (binary_expression "pdVar1 + 1" (identifier "pdVar1") (+ "+") (number_literal "1")) () ")")))) (= "=") (number_literal "1")) (; ";")) (} "}")) (else_clause "else {\n        FUN_0004c150();\n      }" (else "else") (compound_statement "{\n        FUN_0004c150();\n      }" ({ "{") (expression_statement "FUN_0004c150();" (call_expression "FUN_0004c150()" (identifier "FUN_0004c150") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}")))) (if_statement "if (!NAN(dVar3)) {\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }" (if "if") (parenthesized_expression "(!NAN(dVar3))" (( "(") (unary_expression "!NAN(dVar3)" (! "!") (call_expression "NAN(dVar3)" (identifier "NAN") (argument_list "(dVar3)" (( "(") (identifier "dVar3") () ")")))) () ")")) (compound_statement "{\n        *pdVar1 = dVar3;\n        *(undefined2 *)(pdVar1 + 1) = 8;\n      }" ({ "{") (expression_statement "*pdVar1 = dVar3;" (assignment_expression "*pdVar1 = dVar3" (pointer_expression "*pdVar1" (* "*") (identifier "pdVar1")) (= "=") (identifier "dVar3")) (; ";")) (expression_statement "*(undefined2 *)(pdVar1 + 1) = 8;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 8" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" (* "*") (cast_expression "(undefined2 *)(pdVar1 + 1)" (( "(") (type_descriptor "undefined2 *" (type_identifier "undefined2") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(pdVar1 + 1)" (( "(") (binary_expression "pdVar1 + 1" (identifier "pdVar1") (+ "+") (number_literal "1")) () ")")))) (= "=") (number_literal "8")) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" (else "else") (compound_statement "{\n      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }\n      *(undefined2 *)(pdVar1 + 1) = 8;\n      *pdVar1 = 0.0;\n    }" ({ "{") (if_statement "if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {\n        FUN_0004c150();\n      }" (if "if") (parenthesized_expression "((*(ushort *)(pdVar1 + 1) & 0x2400) != 0)" (( "(") (binary_expression "(*(ushort *)(pdVar1 + 1) & 0x2400) != 0" (parenthesized_expression "(*(ushort *)(pdVar1 + 1) & 0x2400)" (( "(") (binary_expression "*(ushort *)(pdVar1 + 1) & 0x2400" (pointer_expression "*(ushort *)(pdVar1 + 1)" (* "*") (cast_expression "(ushort *)(pdVar1 + 1)" (( "(") (type_descriptor "ushort *" (type_identifier "ushort") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(pdVar1 + 1)" (( "(") (binary_expression "pdVar1 + 1" (identifier "pdVar1") (+ "+") (number_literal "1")) () ")")))) (& "&") (number_literal "0x2400")) () ")")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n        FUN_0004c150();\n      }" ({ "{") (expression_statement "FUN_0004c150();" (call_expression "FUN_0004c150()" (identifier "FUN_0004c150") (argument_list "()" (( "(") () ")"))) (; ";")) (} "}"))) (expression_statement "*(undefined2 *)(pdVar1 + 1) = 8;" (assignment_expression "*(undefined2 *)(pdVar1 + 1) = 8" (pointer_expression "*(undefined2 *)(pdVar1 + 1)" (* "*") (cast_expression "(undefined2 *)(pdVar1 + 1)" (( "(") (type_descriptor "undefined2 *" (type_identifier "undefined2") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(pdVar1 + 1)" (( "(") (binary_expression "pdVar1 + 1" (identifier "pdVar1") (+ "+") (number_literal "1")) () ")")))) (= "=") (number_literal "8")) (; ";")) (expression_statement "*pdVar1 = 0.0;" (assignment_expression "*pdVar1 = 0.0" (pointer_expression "*pdVar1" (* "*") (identifier "pdVar1")) (= "=") (number_literal "0.0")) (; ";")) (} "}")))) (expression_statement "*piVar4 = 0;" (assignment_expression "*piVar4 = 0" (pointer_expression "*piVar4" (* "*") (identifier "piVar4")) (= "=") (number_literal "0")) (; ";")) (expression_statement "piVar4[1] = 0;" (assignment_expression "piVar4[1] = 0" (subscript_expression "piVar4[1]" (identifier "piVar4") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0")) (; ";")) (} "}"))) (return_statement "return;" (return "return") (; ";")) (} "}")))

/* WARNING: Unknown calling convention */

void function_1(type_1 *pCtx)

{
  type_2 *pMVar1;
  type_3 var_3;
  double dVar3;
  int *var_2;
  type_4 var_5;
  type_5 local_34;
  
  pMVar1 = pCtx->pMem;
  if ((pMVar1->flags & 0x2000) == 0) {
    var_2 = (int *)var_1((type_1 *)&pCtx->pFunc,(int)pMVar1,
                                     (type_1 *)0x18);
  }
  else {
    var_2 = (int *)pMVar1->z;
  }
  if (var_2 != (int *)0x0) {
    pMVar1 = pCtx->pOut;
    var_3 = var_2[4];
    var_5 = pMVar1->flags & 0x2400;
    if (-var_2[5] < (int)(type_3)(1 < var_3)) {
      local_34 = var_4(var_2[5] + -1 + (type_3)(var_3 != 0),var_3 - 1);
      dVar3 = (double)var_4(var_2[1] + -1 + (type_3)(*var_2 != 0),*var_2 + -1) /
              (double)local_34;
      if (var_5 == 0) {
        pMVar1->flags = 1;
      }
      else {
        var_6(pMVar1);
      }
      if (!var_7(dVar3)) {
        (pMVar1->u).r = dVar3;
        pMVar1->flags = 8;
      }
    }
    else {
      if (var_5 != 0) {
        var_6(pMVar1);
      }
      pMVar1->flags = 8;
      (pMVar1->u).r = 0.0;
    }
    *var_2 = 0;
    var_2[1] = 0;
  }
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))))) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list)))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (unary_expression argument: (subscript_expression argument: (identifier) index: (number_literal))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (number_literal) right: (identifier))))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)) right: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (identifier) right: (number_literal))))) (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)) right: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))))) (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))))) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list)))))) (if_statement condition: (parenthesized_expression (unary_expression argument: (call_expression function: (identifier) arguments: (argument_list (identifier))))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (identifier))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (number_literal)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))))) (return_statement))))

void MASKED(undefined4 *param_1)

{
  double *pdVar1;
  uint uVar2;
  double dVar3;
  int *piVar4;
  undefined8 local_34;
  
  if ((*(byte *)(param_1[2] + 9) & 0x20) == 0) {
    piVar4 = (int *)FUN_0006eb30();
  }
  else {
    piVar4 = *(int **)(param_1[2] + 0x10);
  }
  if (piVar4 != (int *)0x0) {
    pdVar1 = (double *)*param_1;
    uVar2 = piVar4[4];
    if (-piVar4[5] < (int)(uint)(1 < uVar2)) {
      local_34 = CONCAT44(piVar4[5] + -1 + (uint)(uVar2 != 0),uVar2 - 1);
      dVar3 = (double)CONCAT44(piVar4[1] + -1 + (uint)(*piVar4 != 0),*piVar4 + -1) /
              (double)local_34;
      if ((*(ushort *)(pdVar1 + 1) & 0x2400) == 0) {
        *(undefined2 *)(pdVar1 + 1) = 1;
      }
      else {
        FUN_0004c150();
      }
      if (!NAN(dVar3)) {
        *pdVar1 = dVar3;
        *(undefined2 *)(pdVar1 + 1) = 8;
      }
    }
    else {
      if ((*(ushort *)(pdVar1 + 1) & 0x2400) != 0) {
        FUN_0004c150();
      }
      *(undefined2 *)(pdVar1 + 1) = 8;
      *pdVar1 = 0.0;
    }
    *piVar4 = 0;
    piVar4[1] = 0;
  }
  return;
}

