
void frame_downheap(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)

{
  undefined8 *puVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  undefined8 uVar5;
  undefined8 *puVar6;
  
  iVar3 = param_4 * 2;
  while( true ) {
    iVar4 = iVar3 + 1;
    if (param_5 <= iVar4) {
      return;
    }
    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);
    uVar5 = *puVar6;
    if (iVar3 + 2 < param_5) {
      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);
      iVar2 = (*param_2)(param_1,uVar5,*puVar1);
      if (iVar2 < 0) {
        uVar5 = *puVar1;
        puVar6 = puVar1;
        iVar4 = iVar3 + 2;
      }
      else {
        uVar5 = *puVar6;
      }
    }
    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);
    iVar3 = (*param_2)(param_1,*puVar1,uVar5);
    if (-1 < iVar3) break;
    uVar5 = *puVar1;
    *puVar1 = *puVar6;
    iVar3 = iVar4 * 2;
    *puVar6 = uVar5;
    param_4 = iVar4;
  }
  return;
}



void FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)

{
  undefined8 *puVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  undefined8 uVar5;
  undefined8 *puVar6;
  
  iVar3 = param_4 * 2;
  while( true ) {
    iVar4 = iVar3 + 1;
    if (param_5 <= iVar4) {
      return;
    }
    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);
    uVar5 = *puVar6;
    if (iVar3 + 2 < param_5) {
      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);
      iVar2 = (*param_2)(param_1,uVar5,*puVar1);
      if (iVar2 < 0) {
        uVar5 = *puVar1;
        puVar6 = puVar1;
        iVar4 = iVar3 + 2;
      }
      else {
        uVar5 = *puVar6;
      }
    }
    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);
    iVar3 = (*param_2)(param_1,*puVar1,uVar5);
    if (-1 < iVar3) break;
    uVar5 = *puVar1;
    *puVar1 = *puVar6;
    iVar3 = iVar4 * 2;
    *puVar6 = uVar5;
    param_4 = iVar4;
  }
  return;
}


PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
LEA EBX,[RCX + RCX*0x1 + 0x1]
SUB RSP,0x28
MOV qword ptr [RSP + 0x8],RDI
CMP EBX,R8D
JGE 0x00368da0
MOV R14,RSI
MOV R12,RDX
MOV R13D,R8D
JMP 0x00368d7b
LEA R9,[R12 + RAX*0x1 + 0x8]
MOV dword ptr [RSP + 0x1c],ECX
MOV RDI,qword ptr [RSP + 0x8]
MOV RDX,qword ptr [R9]
MOV qword ptr [RSP + 0x10],R9
CALL R14
MOV R9,qword ptr [RSP + 0x10]
MOV ECX,dword ptr [RSP + 0x1c]
TEST EAX,EAX
JS 0x00368d98
MOV RSI,qword ptr [R15]
MOV EBP,EBX
MOVSXD RCX,ECX
MOV RDX,RSI
MOV RDI,qword ptr [RSP + 0x8]
LEA RBX,[R12 + RCX*0x8]
MOV RSI,qword ptr [RBX]
CALL R14
TEST EAX,EAX
JNS 0x00368da0
MOV RDX,qword ptr [R15]
MOV RAX,qword ptr [RBX]
MOV ECX,EBP
MOV qword ptr [RBX],RDX
LEA EBX,[RBP + RBP*0x1 + 0x1]
MOV qword ptr [R15],RAX
CMP R13D,EBX
JLE 0x00368da0
MOVSXD RAX,EBX
LEA EBP,[RBX + 0x1]
SHL RAX,0x3
LEA R15,[R12 + RAX*0x1]
MOV RSI,qword ptr [R15]
CMP EBP,R13D
JL 0x00368d20
MOV EBP,EBX
JMP 0x00368d4b
MOV RSI,qword ptr [R9]
MOV R15,R9
JMP 0x00368d4b
ADD RSP,0x28
POP RBX
POP RBP
POP R12
POP R13
POP R14
POP R15
RET
(translation_unit "void FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}\n\n" (function_definition "void FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" primitive_type (function_declarator "FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" identifier (parameter_list "(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" ( (parameter_declaration "undefined8 param_1" type_identifier identifier) , (parameter_declaration "code *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) , (parameter_declaration "int param_4" primitive_type identifier) , (parameter_declaration "int param_5" primitive_type identifier) ))) (compound_statement "{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" { (declaration "undefined8 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (declaration "undefined8 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (expression_statement "iVar3 = param_4 * 2;" (assignment_expression "iVar3 = param_4 * 2" identifier = (binary_expression "param_4 * 2" identifier * number_literal)) ;) (while_statement "while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" { (expression_statement "iVar4 = iVar3 + 1;" (assignment_expression "iVar4 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (if_statement "if (param_5 <= iVar4) {\n      return;\n    }" if (parenthesized_expression "(param_5 <= iVar4)" ( (binary_expression "param_5 <= iVar4" identifier <= identifier) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) (expression_statement "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);" (assignment_expression "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + (long)iVar4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + (long)iVar4 * 8)" ( (binary_expression "param_3 + (long)iVar4 * 8" identifier + (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" identifier = (pointer_expression "*puVar6" * identifier)) ;) (if_statement "if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" if (parenthesized_expression "(iVar3 + 2 < param_5)" ( (binary_expression "iVar3 + 2 < param_5" (binary_expression "iVar3 + 2" identifier + number_literal) < identifier) )) (compound_statement "{\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" { (expression_statement "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + 8 + (long)iVar4 * 8)" ( (binary_expression "param_3 + 8 + (long)iVar4 * 8" (binary_expression "param_3 + 8" identifier + number_literal) + (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "iVar2 = (*param_2)(param_1,uVar5,*puVar1);" (assignment_expression "iVar2 = (*param_2)(param_1,uVar5,*puVar1)" identifier = (call_expression "(*param_2)(param_1,uVar5,*puVar1)" (parenthesized_expression "(*param_2)" ( (pointer_expression "*param_2" * identifier) )) (argument_list "(param_1,uVar5,*puVar1)" ( identifier , identifier , (pointer_expression "*puVar1" * identifier) )))) ;) (if_statement "if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }" { (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" identifier = (pointer_expression "*puVar1" * identifier)) ;) (expression_statement "puVar6 = puVar1;" (assignment_expression "puVar6 = puVar1" identifier = identifier) ;) (expression_statement "iVar4 = iVar3 + 2;" (assignment_expression "iVar4 = iVar3 + 2" identifier = (binary_expression "iVar3 + 2" identifier + number_literal)) ;) }) (else_clause "else {\n        uVar5 = *puVar6;\n      }" else (compound_statement "{\n        uVar5 = *puVar6;\n      }" { (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" identifier = (pointer_expression "*puVar6" * identifier)) ;) }))) })) (expression_statement "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + (long)param_4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + (long)param_4 * 8)" ( (binary_expression "param_3 + (long)param_4 * 8" identifier + (binary_expression "(long)param_4 * 8" (cast_expression "(long)param_4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "iVar3 = (*param_2)(param_1,*puVar1,uVar5);" (assignment_expression "iVar3 = (*param_2)(param_1,*puVar1,uVar5)" identifier = (call_expression "(*param_2)(param_1,*puVar1,uVar5)" (parenthesized_expression "(*param_2)" ( (pointer_expression "*param_2" * identifier) )) (argument_list "(param_1,*puVar1,uVar5)" ( identifier , (pointer_expression "*puVar1" * identifier) , identifier )))) ;) (if_statement "if (-1 < iVar3) break;" if (parenthesized_expression "(-1 < iVar3)" ( (binary_expression "-1 < iVar3" number_literal < identifier) )) (break_statement "break;" break ;)) (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" identifier = (pointer_expression "*puVar1" * identifier)) ;) (expression_statement "*puVar1 = *puVar6;" (assignment_expression "*puVar1 = *puVar6" (pointer_expression "*puVar1" * identifier) = (pointer_expression "*puVar6" * identifier)) ;) (expression_statement "iVar3 = iVar4 * 2;" (assignment_expression "iVar3 = iVar4 * 2" identifier = (binary_expression "iVar4 * 2" identifier * number_literal)) ;) (expression_statement "*puVar6 = uVar5;" (assignment_expression "*puVar6 = uVar5" (pointer_expression "*puVar6" * identifier) = identifier) ;) (expression_statement "param_4 = iVar4;" (assignment_expression "param_4 = iVar4" identifier = identifier) ;) })) (return_statement "return;" return ;) })))
(translation_unit "void frame_downheap(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}\n\n" (function_definition "void frame_downheap(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" primitive_type (function_declarator "frame_downheap(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" identifier (parameter_list "(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" ( (parameter_declaration "undefined8 param_1" type_identifier identifier) , (parameter_declaration "code *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) , (parameter_declaration "int param_4" primitive_type identifier) , (parameter_declaration "int param_5" primitive_type identifier) ))) (compound_statement "{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" { (declaration "undefined8 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (declaration "undefined8 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (expression_statement "iVar3 = param_4 * 2;" (assignment_expression "iVar3 = param_4 * 2" identifier = (binary_expression "param_4 * 2" identifier * number_literal)) ;) (while_statement "while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" { (expression_statement "iVar4 = iVar3 + 1;" (assignment_expression "iVar4 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (if_statement "if (param_5 <= iVar4) {\n      return;\n    }" if (parenthesized_expression "(param_5 <= iVar4)" ( (binary_expression "param_5 <= iVar4" identifier <= identifier) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) (expression_statement "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);" (assignment_expression "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + (long)iVar4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + (long)iVar4 * 8)" ( (binary_expression "param_3 + (long)iVar4 * 8" identifier + (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" identifier = (pointer_expression "*puVar6" * identifier)) ;) (if_statement "if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" if (parenthesized_expression "(iVar3 + 2 < param_5)" ( (binary_expression "iVar3 + 2 < param_5" (binary_expression "iVar3 + 2" identifier + number_literal) < identifier) )) (compound_statement "{\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" { (expression_statement "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + 8 + (long)iVar4 * 8)" ( (binary_expression "param_3 + 8 + (long)iVar4 * 8" (binary_expression "param_3 + 8" identifier + number_literal) + (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "iVar2 = (*param_2)(param_1,uVar5,*puVar1);" (assignment_expression "iVar2 = (*param_2)(param_1,uVar5,*puVar1)" identifier = (call_expression "(*param_2)(param_1,uVar5,*puVar1)" (parenthesized_expression "(*param_2)" ( (pointer_expression "*param_2" * identifier) )) (argument_list "(param_1,uVar5,*puVar1)" ( identifier , identifier , (pointer_expression "*puVar1" * identifier) )))) ;) (if_statement "if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }" { (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" identifier = (pointer_expression "*puVar1" * identifier)) ;) (expression_statement "puVar6 = puVar1;" (assignment_expression "puVar6 = puVar1" identifier = identifier) ;) (expression_statement "iVar4 = iVar3 + 2;" (assignment_expression "iVar4 = iVar3 + 2" identifier = (binary_expression "iVar3 + 2" identifier + number_literal)) ;) }) (else_clause "else {\n        uVar5 = *puVar6;\n      }" else (compound_statement "{\n        uVar5 = *puVar6;\n      }" { (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" identifier = (pointer_expression "*puVar6" * identifier)) ;) }))) })) (expression_statement "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + (long)param_4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + (long)param_4 * 8)" ( (binary_expression "param_3 + (long)param_4 * 8" identifier + (binary_expression "(long)param_4 * 8" (cast_expression "(long)param_4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "iVar3 = (*param_2)(param_1,*puVar1,uVar5);" (assignment_expression "iVar3 = (*param_2)(param_1,*puVar1,uVar5)" identifier = (call_expression "(*param_2)(param_1,*puVar1,uVar5)" (parenthesized_expression "(*param_2)" ( (pointer_expression "*param_2" * identifier) )) (argument_list "(param_1,*puVar1,uVar5)" ( identifier , (pointer_expression "*puVar1" * identifier) , identifier )))) ;) (if_statement "if (-1 < iVar3) break;" if (parenthesized_expression "(-1 < iVar3)" ( (binary_expression "-1 < iVar3" number_literal < identifier) )) (break_statement "break;" break ;)) (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" identifier = (pointer_expression "*puVar1" * identifier)) ;) (expression_statement "*puVar1 = *puVar6;" (assignment_expression "*puVar1 = *puVar6" (pointer_expression "*puVar1" * identifier) = (pointer_expression "*puVar6" * identifier)) ;) (expression_statement "iVar3 = iVar4 * 2;" (assignment_expression "iVar3 = iVar4 * 2" identifier = (binary_expression "iVar4 * 2" identifier * number_literal)) ;) (expression_statement "*puVar6 = uVar5;" (assignment_expression "*puVar6 = uVar5" (pointer_expression "*puVar6" * identifier) = identifier) ;) (expression_statement "param_4 = iVar4;" (assignment_expression "param_4 = iVar4" identifier = identifier) ;) })) (return_statement "return;" return ;) })))
(translation_unit "void FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}\n\n" (function_definition "void FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" primitive_type (function_declarator "FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" identifier (parameter_list "(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" ( (parameter_declaration "undefined8 param_1" type_identifier identifier) , (parameter_declaration "code *param_2" type_identifier (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "long param_3" (sized_type_specifier "long" long) identifier) , (parameter_declaration "int param_4" primitive_type identifier) , (parameter_declaration "int param_5" primitive_type identifier) ))) (compound_statement "{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" { (declaration "undefined8 *puVar1;" type_identifier (pointer_declarator "*puVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "undefined8 uVar5;" type_identifier identifier ;) (declaration "undefined8 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (expression_statement "iVar3 = param_4 * 2;" (assignment_expression "iVar3 = param_4 * 2" identifier = (binary_expression "param_4 * 2" identifier * number_literal)) ;) (while_statement "while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" { (expression_statement "iVar4 = iVar3 + 1;" (assignment_expression "iVar4 = iVar3 + 1" identifier = (binary_expression "iVar3 + 1" identifier + number_literal)) ;) (if_statement "if (param_5 <= iVar4) {\n      return;\n    }" if (parenthesized_expression "(param_5 <= iVar4)" ( (binary_expression "param_5 <= iVar4" identifier <= identifier) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) (expression_statement "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);" (assignment_expression "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + (long)iVar4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + (long)iVar4 * 8)" ( (binary_expression "param_3 + (long)iVar4 * 8" identifier + (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" identifier = (pointer_expression "*puVar6" * identifier)) ;) (if_statement "if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" if (parenthesized_expression "(iVar3 + 2 < param_5)" ( (binary_expression "iVar3 + 2 < param_5" (binary_expression "iVar3 + 2" identifier + number_literal) < identifier) )) (compound_statement "{\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" { (expression_statement "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + 8 + (long)iVar4 * 8)" ( (binary_expression "param_3 + 8 + (long)iVar4 * 8" (binary_expression "param_3 + 8" identifier + number_literal) + (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "iVar2 = (*param_2)(param_1,uVar5,*puVar1);" (assignment_expression "iVar2 = (*param_2)(param_1,uVar5,*puVar1)" identifier = (call_expression "(*param_2)(param_1,uVar5,*puVar1)" (parenthesized_expression "(*param_2)" ( (pointer_expression "*param_2" * identifier) )) (argument_list "(param_1,uVar5,*puVar1)" ( identifier , identifier , (pointer_expression "*puVar1" * identifier) )))) ;) (if_statement "if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }" if (parenthesized_expression "(iVar2 < 0)" ( (binary_expression "iVar2 < 0" identifier < number_literal) )) (compound_statement "{\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }" { (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" identifier = (pointer_expression "*puVar1" * identifier)) ;) (expression_statement "puVar6 = puVar1;" (assignment_expression "puVar6 = puVar1" identifier = identifier) ;) (expression_statement "iVar4 = iVar3 + 2;" (assignment_expression "iVar4 = iVar3 + 2" identifier = (binary_expression "iVar3 + 2" identifier + number_literal)) ;) }) (else_clause "else {\n        uVar5 = *puVar6;\n      }" else (compound_statement "{\n        uVar5 = *puVar6;\n      }" { (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" identifier = (pointer_expression "*puVar6" * identifier)) ;) }))) })) (expression_statement "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8)" identifier = (cast_expression "(undefined8 *)(param_3 + (long)param_4 * 8)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_3 + (long)param_4 * 8)" ( (binary_expression "param_3 + (long)param_4 * 8" identifier + (binary_expression "(long)param_4 * 8" (cast_expression "(long)param_4" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) identifier) * number_literal)) )))) ;) (expression_statement "iVar3 = (*param_2)(param_1,*puVar1,uVar5);" (assignment_expression "iVar3 = (*param_2)(param_1,*puVar1,uVar5)" identifier = (call_expression "(*param_2)(param_1,*puVar1,uVar5)" (parenthesized_expression "(*param_2)" ( (pointer_expression "*param_2" * identifier) )) (argument_list "(param_1,*puVar1,uVar5)" ( identifier , (pointer_expression "*puVar1" * identifier) , identifier )))) ;) (if_statement "if (-1 < iVar3) break;" if (parenthesized_expression "(-1 < iVar3)" ( (binary_expression "-1 < iVar3" number_literal < identifier) )) (break_statement "break;" break ;)) (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" identifier = (pointer_expression "*puVar1" * identifier)) ;) (expression_statement "*puVar1 = *puVar6;" (assignment_expression "*puVar1 = *puVar6" (pointer_expression "*puVar1" * identifier) = (pointer_expression "*puVar6" * identifier)) ;) (expression_statement "iVar3 = iVar4 * 2;" (assignment_expression "iVar3 = iVar4 * 2" identifier = (binary_expression "iVar4 * 2" identifier * number_literal)) ;) (expression_statement "*puVar6 = uVar5;" (assignment_expression "*puVar6 = uVar5" (pointer_expression "*puVar6" * identifier) = identifier) ;) (expression_statement "param_4 = iVar4;" (assignment_expression "param_4 = iVar4" identifier = identifier) ;) })) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration (sized_type_specifier long) IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT * LIT)) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (compound_statement { (return_statement return ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT) * LIT)) )))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (binary_expression IDENT + LIT) < IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression IDENT + LIT) + (binary_expression (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT) * LIT)) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT , IDENT , (pointer_expression * IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) }))) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + (binary_expression (cast_expression ( (type_descriptor (sized_type_specifier long)) ) IDENT) * LIT)) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT , (pointer_expression * IDENT) , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression LIT < IDENT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT * LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = IDENT) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (return_statement return ;) })))
(function_definition "void FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)\n\n{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" (primitive_type "void") (function_declarator "FUN_00368cf0(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" (identifier "FUN_00368cf0") (parameter_list "(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)" (( "(") (parameter_declaration "undefined8 param_1" (type_identifier "undefined8") (identifier "param_1")) (, ",") (parameter_declaration "code *param_2" (type_identifier "code") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "long param_3" (sized_type_specifier "long" (long "long")) (identifier "param_3")) (, ",") (parameter_declaration "int param_4" (primitive_type "int") (identifier "param_4")) (, ",") (parameter_declaration "int param_5" (primitive_type "int") (identifier "param_5")) () ")"))) (compound_statement "{\n  undefined8 *puVar1;\n  int iVar2;\n  int iVar3;\n  int iVar4;\n  undefined8 uVar5;\n  undefined8 *puVar6;\n  \n  iVar3 = param_4 * 2;\n  while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }\n  return;\n}" ({ "{") (declaration "undefined8 *puVar1;" (type_identifier "undefined8") (pointer_declarator "*puVar1" (* "*") (identifier "puVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "undefined8 uVar5;" (type_identifier "undefined8") (identifier "uVar5") (; ";")) (declaration "undefined8 *puVar6;" (type_identifier "undefined8") (pointer_declarator "*puVar6" (* "*") (identifier "puVar6")) (; ";")) (expression_statement "iVar3 = param_4 * 2;" (assignment_expression "iVar3 = param_4 * 2" (identifier "iVar3") (= "=") (binary_expression "param_4 * 2" (identifier "param_4") (* "*") (number_literal "2"))) (; ";")) (while_statement "while( true ) {\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n    iVar4 = iVar3 + 1;\n    if (param_5 <= iVar4) {\n      return;\n    }\n    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);\n    uVar5 = *puVar6;\n    if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }\n    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);\n    iVar3 = (*param_2)(param_1,*puVar1,uVar5);\n    if (-1 < iVar3) break;\n    uVar5 = *puVar1;\n    *puVar1 = *puVar6;\n    iVar3 = iVar4 * 2;\n    *puVar6 = uVar5;\n    param_4 = iVar4;\n  }" ({ "{") (expression_statement "iVar4 = iVar3 + 1;" (assignment_expression "iVar4 = iVar3 + 1" (identifier "iVar4") (= "=") (binary_expression "iVar3 + 1" (identifier "iVar3") (+ "+") (number_literal "1"))) (; ";")) (if_statement "if (param_5 <= iVar4) {\n      return;\n    }" (if "if") (parenthesized_expression "(param_5 <= iVar4)" (( "(") (binary_expression "param_5 <= iVar4" (identifier "param_5") (<= "<=") (identifier "iVar4")) () ")")) (compound_statement "{\n      return;\n    }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);" (assignment_expression "puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8)" (identifier "puVar6") (= "=") (cast_expression "(undefined8 *)(param_3 + (long)iVar4 * 8)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_3 + (long)iVar4 * 8)" (( "(") (binary_expression "param_3 + (long)iVar4 * 8" (identifier "param_3") (+ "+") (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "iVar4")) (* "*") (number_literal "8"))) () ")")))) (; ";")) (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" (identifier "uVar5") (= "=") (pointer_expression "*puVar6" (* "*") (identifier "puVar6"))) (; ";")) (if_statement "if (iVar3 + 2 < param_5) {\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" (if "if") (parenthesized_expression "(iVar3 + 2 < param_5)" (( "(") (binary_expression "iVar3 + 2 < param_5" (binary_expression "iVar3 + 2" (identifier "iVar3") (+ "+") (number_literal "2")) (< "<") (identifier "param_5")) () ")")) (compound_statement "{\n      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);\n      iVar2 = (*param_2)(param_1,uVar5,*puVar1);\n      if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }\n    }" ({ "{") (expression_statement "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" (identifier "puVar1") (= "=") (cast_expression "(undefined8 *)(param_3 + 8 + (long)iVar4 * 8)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_3 + 8 + (long)iVar4 * 8)" (( "(") (binary_expression "param_3 + 8 + (long)iVar4 * 8" (binary_expression "param_3 + 8" (identifier "param_3") (+ "+") (number_literal "8")) (+ "+") (binary_expression "(long)iVar4 * 8" (cast_expression "(long)iVar4" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "iVar4")) (* "*") (number_literal "8"))) () ")")))) (; ";")) (expression_statement "iVar2 = (*param_2)(param_1,uVar5,*puVar1);" (assignment_expression "iVar2 = (*param_2)(param_1,uVar5,*puVar1)" (identifier "iVar2") (= "=") (call_expression "(*param_2)(param_1,uVar5,*puVar1)" (parenthesized_expression "(*param_2)" (( "(") (pointer_expression "*param_2" (* "*") (identifier "param_2")) () ")")) (argument_list "(param_1,uVar5,*puVar1)" (( "(") (identifier "param_1") (, ",") (identifier "uVar5") (, ",") (pointer_expression "*puVar1" (* "*") (identifier "puVar1")) () ")")))) (; ";")) (if_statement "if (iVar2 < 0) {\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }\n      else {\n        uVar5 = *puVar6;\n      }" (if "if") (parenthesized_expression "(iVar2 < 0)" (( "(") (binary_expression "iVar2 < 0" (identifier "iVar2") (< "<") (number_literal "0")) () ")")) (compound_statement "{\n        uVar5 = *puVar1;\n        puVar6 = puVar1;\n        iVar4 = iVar3 + 2;\n      }" ({ "{") (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" (identifier "uVar5") (= "=") (pointer_expression "*puVar1" (* "*") (identifier "puVar1"))) (; ";")) (expression_statement "puVar6 = puVar1;" (assignment_expression "puVar6 = puVar1" (identifier "puVar6") (= "=") (identifier "puVar1")) (; ";")) (expression_statement "iVar4 = iVar3 + 2;" (assignment_expression "iVar4 = iVar3 + 2" (identifier "iVar4") (= "=") (binary_expression "iVar3 + 2" (identifier "iVar3") (+ "+") (number_literal "2"))) (; ";")) (} "}")) (else_clause "else {\n        uVar5 = *puVar6;\n      }" (else "else") (compound_statement "{\n        uVar5 = *puVar6;\n      }" ({ "{") (expression_statement "uVar5 = *puVar6;" (assignment_expression "uVar5 = *puVar6" (identifier "uVar5") (= "=") (pointer_expression "*puVar6" (* "*") (identifier "puVar6"))) (; ";")) (} "}")))) (} "}"))) (expression_statement "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);" (assignment_expression "puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8)" (identifier "puVar1") (= "=") (cast_expression "(undefined8 *)(param_3 + (long)param_4 * 8)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_3 + (long)param_4 * 8)" (( "(") (binary_expression "param_3 + (long)param_4 * 8" (identifier "param_3") (+ "+") (binary_expression "(long)param_4 * 8" (cast_expression "(long)param_4" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (identifier "param_4")) (* "*") (number_literal "8"))) () ")")))) (; ";")) (expression_statement "iVar3 = (*param_2)(param_1,*puVar1,uVar5);" (assignment_expression "iVar3 = (*param_2)(param_1,*puVar1,uVar5)" (identifier "iVar3") (= "=") (call_expression "(*param_2)(param_1,*puVar1,uVar5)" (parenthesized_expression "(*param_2)" (( "(") (pointer_expression "*param_2" (* "*") (identifier "param_2")) () ")")) (argument_list "(param_1,*puVar1,uVar5)" (( "(") (identifier "param_1") (, ",") (pointer_expression "*puVar1" (* "*") (identifier "puVar1")) (, ",") (identifier "uVar5") () ")")))) (; ";")) (if_statement "if (-1 < iVar3) break;" (if "if") (parenthesized_expression "(-1 < iVar3)" (( "(") (binary_expression "-1 < iVar3" (number_literal "-1") (< "<") (identifier "iVar3")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "uVar5 = *puVar1;" (assignment_expression "uVar5 = *puVar1" (identifier "uVar5") (= "=") (pointer_expression "*puVar1" (* "*") (identifier "puVar1"))) (; ";")) (expression_statement "*puVar1 = *puVar6;" (assignment_expression "*puVar1 = *puVar6" (pointer_expression "*puVar1" (* "*") (identifier "puVar1")) (= "=") (pointer_expression "*puVar6" (* "*") (identifier "puVar6"))) (; ";")) (expression_statement "iVar3 = iVar4 * 2;" (assignment_expression "iVar3 = iVar4 * 2" (identifier "iVar3") (= "=") (binary_expression "iVar4 * 2" (identifier "iVar4") (* "*") (number_literal "2"))) (; ";")) (expression_statement "*puVar6 = uVar5;" (assignment_expression "*puVar6 = uVar5" (pointer_expression "*puVar6" (* "*") (identifier "puVar6")) (= "=") (identifier "uVar5")) (; ";")) (expression_statement "param_4 = iVar4;" (assignment_expression "param_4 = iVar4" (identifier "param_4") (= "=") (identifier "iVar4")) (; ";")) (} "}"))) (return_statement "return;" (return "return") (; ";")) (} "}")))

void function_1(type_1 param_1,type_2 *param_2,long var_5,int var_1,int var_3)

{
  type_1 *puVar1;
  int var_6;
  int var_2;
  int var_4;
  type_1 uVar5;
  type_1 *puVar6;
  
  var_2 = var_1 * 2;
  while( true ) {
    var_4 = var_2 + 1;
    if (var_3 <= var_4) {
      return;
    }
    puVar6 = (type_1 *)(var_5 + (long)var_4 * 8);
    uVar5 = *puVar6;
    if (var_2 + 2 < var_3) {
      puVar1 = (type_1 *)(var_5 + 8 + (long)var_4 * 8);
      var_6 = (*param_2)(param_1,uVar5,*puVar1);
      if (var_6 < 0) {
        uVar5 = *puVar1;
        puVar6 = puVar1;
        var_4 = var_2 + 2;
      }
      else {
        uVar5 = *puVar6;
      }
    }
    puVar1 = (type_1 *)(var_5 + (long)var_1 * 8);
    var_2 = (*param_2)(param_1,*puVar1,uVar5);
    if (-1 < var_2) break;
    uVar5 = *puVar1;
    *puVar1 = *puVar6;
    var_2 = var_4 * 2;
    *puVar6 = uVar5;
    var_1 = var_4;
  }
  return;
}


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

void MASKED(undefined8 param_1,code *param_2,long param_3,int param_4,int param_5)

{
  undefined8 *puVar1;
  int iVar2;
  int iVar3;
  int iVar4;
  undefined8 uVar5;
  undefined8 *puVar6;
  
  iVar3 = param_4 * 2;
  while( true ) {
    iVar4 = iVar3 + 1;
    if (param_5 <= iVar4) {
      return;
    }
    puVar6 = (undefined8 *)(param_3 + (long)iVar4 * 8);
    uVar5 = *puVar6;
    if (iVar3 + 2 < param_5) {
      puVar1 = (undefined8 *)(param_3 + 8 + (long)iVar4 * 8);
      iVar2 = (*param_2)(param_1,uVar5,*puVar1);
      if (iVar2 < 0) {
        uVar5 = *puVar1;
        puVar6 = puVar1;
        iVar4 = iVar3 + 2;
      }
      else {
        uVar5 = *puVar6;
      }
    }
    puVar1 = (undefined8 *)(param_3 + (long)param_4 * 8);
    iVar3 = (*param_2)(param_1,*puVar1,uVar5);
    if (-1 < iVar3) break;
    uVar5 = *puVar1;
    *puVar1 = *puVar6;
    iVar3 = iVar4 * 2;
    *puVar6 = uVar5;
    param_4 = iVar4;
  }
  return;
}

