
void hist_write_hist(FILE *ofp,char *filename)

{
  int iVar1;
  size_t sVar2;
  uint uVar3;
  ulong uVar4;
  uint uVar5;
  histogram *phVar6;
  UNIT count;
  
  if (num_histograms == 0) {
    return;
  }
  uVar5 = 0;
  while( true ) {
    phVar6 = histograms + uVar5;
    iVar1 = gmon_io_write_8(ofp,0);
    if (iVar1 != 0) break;
    iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);
    if (iVar1 != 0) break;
    iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);
    if (iVar1 != 0) break;
    iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);
    if (iVar1 != 0) break;
    iVar1 = gmon_io_write_32(ofp,(uint)hz);
    if (iVar1 != 0) break;
    iVar1 = gmon_io_write(ofp,hist_dimension,0xf);
    if (iVar1 != 0) break;
    iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);
    if (iVar1 != 0) break;
    uVar4 = 0;
    if (phVar6->num_bins != 0) {
      do {
        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);
        sVar2 = fwrite(count,2,1,(FILE *)ofp);
        if (sVar2 != 1) goto LAB_0010a6cf;
        uVar3 = (int)uVar4 + 1;
        uVar4 = (ulong)uVar3;
      } while (uVar3 < phVar6->num_bins);
    }
    uVar5 = uVar5 + 1;
    if (num_histograms <= uVar5) {
      return;
    }
  }
LAB_0010a6cf:
  perror(filename);
                    /* WARNING: Subroutine does not return */
  done(1);
}



void FUN_0010a590(FILE *param_1,char *param_2)

{
  int iVar1;
  size_t sVar2;
  uint uVar3;
  ulong uVar4;
  uint uVar5;
  undefined8 *puVar6;
  undefined1 local_3a [10];
  
  if (DAT_00119b20 == 0) {
    return;
  }
  uVar5 = 0;
  while( true ) {
    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);
    iVar1 = FUN_001096f0(param_1,0);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109680(param_1,*puVar6);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109680(param_1,puVar6[1]);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));
    if (iVar1 != 0) break;
    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);
    if (iVar1 != 0) break;
    uVar4 = 0;
    if (*(int *)(puVar6 + 2) != 0) {
      do {
        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))
                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);
        sVar2 = fwrite(local_3a,2,1,param_1);
        if (sVar2 != 1) goto LAB_0010a6cf;
        uVar3 = (int)uVar4 + 1;
        uVar4 = (ulong)uVar3;
      } while (uVar3 < *(uint *)(puVar6 + 2));
    }
    uVar5 = uVar5 + 1;
    if (DAT_00119b20 <= uVar5) {
      return;
    }
  }
LAB_0010a6cf:
  perror(param_2);
                    /* WARNING: Subroutine does not return */
  FUN_0010a4c0(1);
}


MOV EDX,dword ptr [0x00119b20]
TEST EDX,EDX
JZ 0x0010a6e1
PUSH R15
PUSH R14
MOV R14,RSI
PUSH R13
XOR R13D,R13D
PUSH R12
MOV R12,RDI
PUSH RBP
PUSH RBX
SUB RSP,0x18
LEA RBP,[RSP + 0xe]
NOP word ptr [RAX + RAX*0x1]
MOV R15D,R13D
XOR ESI,ESI
MOV RDI,R12
SHL R15,0x5
ADD R15,qword ptr [0x00119b18]
CALL 0x001096f0
TEST EAX,EAX
JNZ 0x0010a6cf
MOV RSI,qword ptr [R15]
MOV RDI,R12
CALL 0x00109680
TEST EAX,EAX
JNZ 0x0010a6cf
MOV RSI,qword ptr [R15 + 0x8]
MOV RDI,R12
CALL 0x00109680
TEST EAX,EAX
JNZ 0x0010a6cf
MOV ESI,dword ptr [R15 + 0x10]
MOV RDI,R12
CALL 0x00109630
TEST EAX,EAX
JNZ 0x0010a6cf
MOV ESI,dword ptr [0x001195e8]
MOV RDI,R12
CALL 0x00109630
TEST EAX,EAX
JNZ 0x0010a6cf
MOV EDX,0xf
LEA RSI,[0x1188a0]
MOV RDI,R12
CALL 0x00109720
TEST EAX,EAX
JNZ 0x0010a6cf
MOV EDX,0x1
LEA RSI,[0x118890]
MOV RDI,R12
CALL 0x00109720
TEST EAX,EAX
JNZ 0x0010a6cf
MOV EAX,dword ptr [R15 + 0x10]
XOR EBX,EBX
TEST EAX,EAX
JZ 0x0010a6af
NOP
MOV RDX,qword ptr [R15 + 0x18]
MOV EAX,EBX
MOV RSI,RBP
MOVSXD RDI,dword ptr [RDX + RAX*0x4]
MOV RAX,qword ptr [0x00119ad8]
MOV RAX,qword ptr [RAX + 0x8]
CALL qword ptr [RAX + 0x60]
MOV RCX,R12
MOV EDX,0x1
MOV ESI,0x2
MOV RDI,RBP
CALL 0x00102460
CMP RAX,0x1
JNZ 0x0010a6cf
ADD EBX,0x1
CMP dword ptr [R15 + 0x10],EBX
JA 0x0010a670
ADD R13D,0x1
CMP dword ptr [0x00119b20],R13D
JA 0x0010a5c0
ADD RSP,0x18
POP RBX
POP RBP
POP R12
POP R13
POP R14
POP R15
RET
MOV RDI,R14
CALL 0x00102400
MOV EDI,0x1
CALL 0x0010a4c0
RET
(translation_unit "void FUN_0010a590(FILE *param_1,char *param_2)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    /* WARNING: Subroutine does not return */\n  FUN_0010a4c0(1);\n}\n\n" (function_definition "void FUN_0010a590(FILE *param_1,char *param_2)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    /* WARNING: Subroutine does not return */\n  FUN_0010a4c0(1);\n}" primitive_type (function_declarator "FUN_0010a590(FILE *param_1,char *param_2)" identifier (parameter_list "(FILE *param_1,char *param_2)" ( (parameter_declaration "FILE *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    /* WARNING: Subroutine does not return */\n  FUN_0010a4c0(1);\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "size_t sVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "ulong uVar4;" type_identifier identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "undefined8 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "undefined1 local_3a [10];" type_identifier (array_declarator "local_3a [10]" identifier [ number_literal ]) ;) (if_statement "if (DAT_00119b20 == 0) {\n    return;\n  }" if (parenthesized_expression "(DAT_00119b20 == 0)" ( (binary_expression "DAT_00119b20 == 0" identifier == number_literal) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }" { (expression_statement "puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);" (assignment_expression "puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18)" identifier = (cast_expression "(undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulong)uVar5 * 0x20 + DAT_00119b18)" ( (binary_expression "(ulong)uVar5 * 0x20 + DAT_00119b18" (binary_expression "(ulong)uVar5 * 0x20" (cast_expression "(ulong)uVar5" ( (type_descriptor "ulong" type_identifier) ) identifier) * number_literal) + identifier) )))) ;) (expression_statement "iVar1 = FUN_001096f0(param_1,0);" (assignment_expression "iVar1 = FUN_001096f0(param_1,0)" identifier = (call_expression "FUN_001096f0(param_1,0)" identifier (argument_list "(param_1,0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109680(param_1,*puVar6);" (assignment_expression "iVar1 = FUN_00109680(param_1,*puVar6)" identifier = (call_expression "FUN_00109680(param_1,*puVar6)" identifier (argument_list "(param_1,*puVar6)" ( identifier , (pointer_expression "*puVar6" * identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109680(param_1,puVar6[1]);" (assignment_expression "iVar1 = FUN_00109680(param_1,puVar6[1])" identifier = (call_expression "FUN_00109680(param_1,puVar6[1])" identifier (argument_list "(param_1,puVar6[1])" ( identifier , (subscript_expression "puVar6[1]" identifier [ number_literal ]) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));" (assignment_expression "iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2))" identifier = (call_expression "FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2))" identifier (argument_list "(param_1,*(undefined4 *)(puVar6 + 2))" ( identifier , (pointer_expression "*(undefined4 *)(puVar6 + 2)" * (cast_expression "(undefined4 *)(puVar6 + 2)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 2)" ( (binary_expression "puVar6 + 2" identifier + number_literal) )))) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);" (assignment_expression "iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8)" identifier = (call_expression "FUN_00109630(param_1,(undefined4)DAT_001195e8)" identifier (argument_list "(param_1,(undefined4)DAT_001195e8)" ( identifier , (cast_expression "(undefined4)DAT_001195e8" ( (type_descriptor "undefined4" type_identifier) ) identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);" (assignment_expression "iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf)" identifier = (call_expression "FUN_00109720(param_1,s_seconds_001188a0,0xf)" identifier (argument_list "(param_1,s_seconds_001188a0,0xf)" ( identifier , identifier , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109720(param_1,&DAT_00118890,1);" (assignment_expression "iVar1 = FUN_00109720(param_1,&DAT_00118890,1)" identifier = (call_expression "FUN_00109720(param_1,&DAT_00118890,1)" identifier (argument_list "(param_1,&DAT_00118890,1)" ( identifier , (pointer_expression "&DAT_00118890" & identifier) , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (if_statement "if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }" if (parenthesized_expression "(*(int *)(puVar6 + 2) != 0)" ( (binary_expression "*(int *)(puVar6 + 2) != 0" (pointer_expression "*(int *)(puVar6 + 2)" * (cast_expression "(int *)(puVar6 + 2)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 2)" ( (binary_expression "puVar6 + 2" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }" { (do_statement "do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));" do (compound_statement "{\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      }" { (expression_statement "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);" (call_expression "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a)" (parenthesized_expression "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))" ( (pointer_expression "**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" * (pointer_expression "*(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" * (cast_expression "(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(*(long *)(DAT_00119ad8 + 8) + 0x60)" ( (binary_expression "*(long *)(DAT_00119ad8 + 8) + 0x60" (pointer_expression "*(long *)(DAT_00119ad8 + 8)" * (cast_expression "(long *)(DAT_00119ad8 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(DAT_00119ad8 + 8)" ( (binary_expression "DAT_00119ad8 + 8" identifier + number_literal) )))) + number_literal) ))))) )) (argument_list "((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a)" ( (cast_expression "(long)*(int *)(puVar6[3] + uVar4 * 4)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (pointer_expression "*(int *)(puVar6[3] + uVar4 * 4)" * (cast_expression "(int *)(puVar6[3] + uVar4 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6[3] + uVar4 * 4)" ( (binary_expression "puVar6[3] + uVar4 * 4" (subscript_expression "puVar6[3]" identifier [ number_literal ]) + (binary_expression "uVar4 * 4" identifier * number_literal)) ))))) , identifier ))) ;) (expression_statement "sVar2 = fwrite(local_3a,2,1,param_1);" (assignment_expression "sVar2 = fwrite(local_3a,2,1,param_1)" identifier = (call_expression "fwrite(local_3a,2,1,param_1)" identifier (argument_list "(local_3a,2,1,param_1)" ( identifier , number_literal , number_literal , identifier )))) ;) (if_statement "if (sVar2 != 1) goto LAB_0010a6cf;" if (parenthesized_expression "(sVar2 != 1)" ( (binary_expression "sVar2 != 1" identifier != number_literal) )) (goto_statement "goto LAB_0010a6cf;" goto statement_identifier ;)) (expression_statement "uVar3 = (int)uVar4 + 1;" (assignment_expression "uVar3 = (int)uVar4 + 1" identifier = (binary_expression "(int)uVar4 + 1" (cast_expression "(int)uVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal)) ;) (expression_statement "uVar4 = (ulong)uVar3;" (assignment_expression "uVar4 = (ulong)uVar3" identifier = (cast_expression "(ulong)uVar3" ( (type_descriptor "ulong" type_identifier) ) identifier)) ;) }) while (parenthesized_expression "(uVar3 < *(uint *)(puVar6 + 2))" ( (binary_expression "uVar3 < *(uint *)(puVar6 + 2)" identifier < (pointer_expression "*(uint *)(puVar6 + 2)" * (cast_expression "(uint *)(puVar6 + 2)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 2)" ( (binary_expression "puVar6 + 2" identifier + number_literal) ))))) )) ;) })) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" identifier = (binary_expression "uVar5 + 1" identifier + number_literal)) ;) (if_statement "if (DAT_00119b20 <= uVar5) {\n      return;\n    }" if (parenthesized_expression "(DAT_00119b20 <= uVar5)" ( (binary_expression "DAT_00119b20 <= uVar5" identifier <= identifier) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) })) (labeled_statement "LAB_0010a6cf:\n  perror(param_2);" statement_identifier : (expression_statement "perror(param_2);" (call_expression "perror(param_2)" identifier (argument_list "(param_2)" ( identifier ))) ;)) comment (expression_statement "FUN_0010a4c0(1);" (call_expression "FUN_0010a4c0(1)" identifier (argument_list "(1)" ( number_literal ))) ;) })))
(translation_unit "void hist_write_hist(FILE *ofp,char *filename)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  histogram *phVar6;\n  UNIT count;\n  \n  if (num_histograms == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    phVar6 = histograms + uVar5;\n    iVar1 = gmon_io_write_8(ofp,0);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,(uint)hz);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,hist_dimension,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (phVar6->num_bins != 0) {\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }\n    uVar5 = uVar5 + 1;\n    if (num_histograms <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(filename);\n                    /* WARNING: Subroutine does not return */\n  done(1);\n}\n\n" (function_definition "void hist_write_hist(FILE *ofp,char *filename)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  histogram *phVar6;\n  UNIT count;\n  \n  if (num_histograms == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    phVar6 = histograms + uVar5;\n    iVar1 = gmon_io_write_8(ofp,0);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,(uint)hz);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,hist_dimension,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (phVar6->num_bins != 0) {\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }\n    uVar5 = uVar5 + 1;\n    if (num_histograms <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(filename);\n                    /* WARNING: Subroutine does not return */\n  done(1);\n}" primitive_type (function_declarator "hist_write_hist(FILE *ofp,char *filename)" identifier (parameter_list "(FILE *ofp,char *filename)" ( (parameter_declaration "FILE *ofp" type_identifier (pointer_declarator "*ofp" * identifier)) , (parameter_declaration "char *filename" primitive_type (pointer_declarator "*filename" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  histogram *phVar6;\n  UNIT count;\n  \n  if (num_histograms == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    phVar6 = histograms + uVar5;\n    iVar1 = gmon_io_write_8(ofp,0);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,(uint)hz);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,hist_dimension,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (phVar6->num_bins != 0) {\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }\n    uVar5 = uVar5 + 1;\n    if (num_histograms <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(filename);\n                    /* WARNING: Subroutine does not return */\n  done(1);\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "size_t sVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "ulong uVar4;" type_identifier identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "histogram *phVar6;" type_identifier (pointer_declarator "*phVar6" * identifier) ;) (declaration "UNIT count;" type_identifier identifier ;) (if_statement "if (num_histograms == 0) {\n    return;\n  }" if (parenthesized_expression "(num_histograms == 0)" ( (binary_expression "num_histograms == 0" identifier == number_literal) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n    phVar6 = histograms + uVar5;\n    iVar1 = gmon_io_write_8(ofp,0);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,(uint)hz);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,hist_dimension,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (phVar6->num_bins != 0) {\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }\n    uVar5 = uVar5 + 1;\n    if (num_histograms <= uVar5) {\n      return;\n    }\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    phVar6 = histograms + uVar5;\n    iVar1 = gmon_io_write_8(ofp,0);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write_32(ofp,(uint)hz);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,hist_dimension,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (phVar6->num_bins != 0) {\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }\n    uVar5 = uVar5 + 1;\n    if (num_histograms <= uVar5) {\n      return;\n    }\n  }" { (expression_statement "phVar6 = histograms + uVar5;" (assignment_expression "phVar6 = histograms + uVar5" identifier = (binary_expression "histograms + uVar5" identifier + identifier)) ;) (expression_statement "iVar1 = gmon_io_write_8(ofp,0);" (assignment_expression "iVar1 = gmon_io_write_8(ofp,0)" identifier = (call_expression "gmon_io_write_8(ofp,0)" identifier (argument_list "(ofp,0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc);" (assignment_expression "iVar1 = gmon_io_write_vma(ofp,phVar6->lowpc)" identifier = (call_expression "gmon_io_write_vma(ofp,phVar6->lowpc)" identifier (argument_list "(ofp,phVar6->lowpc)" ( identifier , (field_expression "phVar6->lowpc" identifier -> field_identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = gmon_io_write_vma(ofp,phVar6->highpc);" (assignment_expression "iVar1 = gmon_io_write_vma(ofp,phVar6->highpc)" identifier = (call_expression "gmon_io_write_vma(ofp,phVar6->highpc)" identifier (argument_list "(ofp,phVar6->highpc)" ( identifier , (field_expression "phVar6->highpc" identifier -> field_identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = gmon_io_write_32(ofp,phVar6->num_bins);" (assignment_expression "iVar1 = gmon_io_write_32(ofp,phVar6->num_bins)" identifier = (call_expression "gmon_io_write_32(ofp,phVar6->num_bins)" identifier (argument_list "(ofp,phVar6->num_bins)" ( identifier , (field_expression "phVar6->num_bins" identifier -> field_identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = gmon_io_write_32(ofp,(uint)hz);" (assignment_expression "iVar1 = gmon_io_write_32(ofp,(uint)hz)" identifier = (call_expression "gmon_io_write_32(ofp,(uint)hz)" identifier (argument_list "(ofp,(uint)hz)" ( identifier , (cast_expression "(uint)hz" ( (type_descriptor "uint" type_identifier) ) identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = gmon_io_write(ofp,hist_dimension,0xf);" (assignment_expression "iVar1 = gmon_io_write(ofp,hist_dimension,0xf)" identifier = (call_expression "gmon_io_write(ofp,hist_dimension,0xf)" identifier (argument_list "(ofp,hist_dimension,0xf)" ( identifier , identifier , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1);" (assignment_expression "iVar1 = gmon_io_write(ofp,&hist_dimension_abbrev,1)" identifier = (call_expression "gmon_io_write(ofp,&hist_dimension_abbrev,1)" identifier (argument_list "(ofp,&hist_dimension_abbrev,1)" ( identifier , (pointer_expression "&hist_dimension_abbrev" & identifier) , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (if_statement "if (phVar6->num_bins != 0) {\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }" if (parenthesized_expression "(phVar6->num_bins != 0)" ( (binary_expression "phVar6->num_bins != 0" (field_expression "phVar6->num_bins" identifier -> field_identifier) != number_literal) )) (compound_statement "{\n      do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);\n    }" { (do_statement "do {\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < phVar6->num_bins);" do (compound_statement "{\n        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);\n        sVar2 = fwrite(count,2,1,(FILE *)ofp);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      }" { (expression_statement "(*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);" (call_expression "(*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count)" (parenthesized_expression "(*core_bfd->xvec->bfd_putx16)" ( (pointer_expression "*core_bfd->xvec->bfd_putx16" * (field_expression "core_bfd->xvec->bfd_putx16" (field_expression "core_bfd->xvec" identifier -> field_identifier) -> field_identifier)) )) (argument_list "((long)phVar6->sample[uVar4],count)" ( (cast_expression "(long)phVar6->sample[uVar4]" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (subscript_expression "phVar6->sample[uVar4]" (field_expression "phVar6->sample" identifier -> field_identifier) [ identifier ])) , identifier ))) ;) (expression_statement "sVar2 = fwrite(count,2,1,(FILE *)ofp);" (assignment_expression "sVar2 = fwrite(count,2,1,(FILE *)ofp)" identifier = (call_expression "fwrite(count,2,1,(FILE *)ofp)" identifier (argument_list "(count,2,1,(FILE *)ofp)" ( identifier , number_literal , number_literal , (cast_expression "(FILE *)ofp" ( (type_descriptor "FILE *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier) )))) ;) (if_statement "if (sVar2 != 1) goto LAB_0010a6cf;" if (parenthesized_expression "(sVar2 != 1)" ( (binary_expression "sVar2 != 1" identifier != number_literal) )) (goto_statement "goto LAB_0010a6cf;" goto statement_identifier ;)) (expression_statement "uVar3 = (int)uVar4 + 1;" (assignment_expression "uVar3 = (int)uVar4 + 1" identifier = (binary_expression "(int)uVar4 + 1" (cast_expression "(int)uVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal)) ;) (expression_statement "uVar4 = (ulong)uVar3;" (assignment_expression "uVar4 = (ulong)uVar3" identifier = (cast_expression "(ulong)uVar3" ( (type_descriptor "ulong" type_identifier) ) identifier)) ;) }) while (parenthesized_expression "(uVar3 < phVar6->num_bins)" ( (binary_expression "uVar3 < phVar6->num_bins" identifier < (field_expression "phVar6->num_bins" identifier -> field_identifier)) )) ;) })) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" identifier = (binary_expression "uVar5 + 1" identifier + number_literal)) ;) (if_statement "if (num_histograms <= uVar5) {\n      return;\n    }" if (parenthesized_expression "(num_histograms <= uVar5)" ( (binary_expression "num_histograms <= uVar5" identifier <= identifier) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) })) (labeled_statement "LAB_0010a6cf:\n  perror(filename);" statement_identifier : (expression_statement "perror(filename);" (call_expression "perror(filename)" identifier (argument_list "(filename)" ( identifier ))) ;)) comment (expression_statement "done(1);" (call_expression "done(1)" identifier (argument_list "(1)" ( number_literal ))) ;) })))
(translation_unit "void FUN_0010a590(FILE *param_1,char *param_2)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    \n  FUN_0010a4c0(1);\n}\n\n" (function_definition "void FUN_0010a590(FILE *param_1,char *param_2)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    \n  FUN_0010a4c0(1);\n}" primitive_type (function_declarator "FUN_0010a590(FILE *param_1,char *param_2)" identifier (parameter_list "(FILE *param_1,char *param_2)" ( (parameter_declaration "FILE *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "char *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) ))) (compound_statement "{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    \n  FUN_0010a4c0(1);\n}" { (declaration "int iVar1;" primitive_type identifier ;) (declaration "size_t sVar2;" primitive_type identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "ulong uVar4;" type_identifier identifier ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "undefined8 *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "undefined1 local_3a [10];" type_identifier (array_declarator "local_3a [10]" identifier [ number_literal ]) ;) (if_statement "if (DAT_00119b20 == 0) {\n    return;\n  }" if (parenthesized_expression "(DAT_00119b20 == 0)" ( (binary_expression "DAT_00119b20 == 0" identifier == number_literal) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (while_statement "while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }" while (parenthesized_expression "( true )" ( true )) (compound_statement "{\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }" { (expression_statement "puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);" (assignment_expression "puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18)" identifier = (cast_expression "(undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18)" ( (type_descriptor "undefined8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "((ulong)uVar5 * 0x20 + DAT_00119b18)" ( (binary_expression "(ulong)uVar5 * 0x20 + DAT_00119b18" (binary_expression "(ulong)uVar5 * 0x20" (cast_expression "(ulong)uVar5" ( (type_descriptor "ulong" type_identifier) ) identifier) * number_literal) + identifier) )))) ;) (expression_statement "iVar1 = FUN_001096f0(param_1,0);" (assignment_expression "iVar1 = FUN_001096f0(param_1,0)" identifier = (call_expression "FUN_001096f0(param_1,0)" identifier (argument_list "(param_1,0)" ( identifier , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109680(param_1,*puVar6);" (assignment_expression "iVar1 = FUN_00109680(param_1,*puVar6)" identifier = (call_expression "FUN_00109680(param_1,*puVar6)" identifier (argument_list "(param_1,*puVar6)" ( identifier , (pointer_expression "*puVar6" * identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109680(param_1,puVar6[1]);" (assignment_expression "iVar1 = FUN_00109680(param_1,puVar6[1])" identifier = (call_expression "FUN_00109680(param_1,puVar6[1])" identifier (argument_list "(param_1,puVar6[1])" ( identifier , (subscript_expression "puVar6[1]" identifier [ number_literal ]) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));" (assignment_expression "iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2))" identifier = (call_expression "FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2))" identifier (argument_list "(param_1,*(undefined4 *)(puVar6 + 2))" ( identifier , (pointer_expression "*(undefined4 *)(puVar6 + 2)" * (cast_expression "(undefined4 *)(puVar6 + 2)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 2)" ( (binary_expression "puVar6 + 2" identifier + number_literal) )))) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);" (assignment_expression "iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8)" identifier = (call_expression "FUN_00109630(param_1,(undefined4)DAT_001195e8)" identifier (argument_list "(param_1,(undefined4)DAT_001195e8)" ( identifier , (cast_expression "(undefined4)DAT_001195e8" ( (type_descriptor "undefined4" type_identifier) ) identifier) )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);" (assignment_expression "iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf)" identifier = (call_expression "FUN_00109720(param_1,s_seconds_001188a0,0xf)" identifier (argument_list "(param_1,s_seconds_001188a0,0xf)" ( identifier , identifier , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "iVar1 = FUN_00109720(param_1,&DAT_00118890,1);" (assignment_expression "iVar1 = FUN_00109720(param_1,&DAT_00118890,1)" identifier = (call_expression "FUN_00109720(param_1,&DAT_00118890,1)" identifier (argument_list "(param_1,&DAT_00118890,1)" ( identifier , (pointer_expression "&DAT_00118890" & identifier) , number_literal )))) ;) (if_statement "if (iVar1 != 0) break;" if (parenthesized_expression "(iVar1 != 0)" ( (binary_expression "iVar1 != 0" identifier != number_literal) )) (break_statement "break;" break ;)) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" identifier = number_literal) ;) (if_statement "if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }" if (parenthesized_expression "(*(int *)(puVar6 + 2) != 0)" ( (binary_expression "*(int *)(puVar6 + 2) != 0" (pointer_expression "*(int *)(puVar6 + 2)" * (cast_expression "(int *)(puVar6 + 2)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 2)" ( (binary_expression "puVar6 + 2" identifier + number_literal) )))) != number_literal) )) (compound_statement "{\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }" { (do_statement "do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));" do (compound_statement "{\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      }" { (expression_statement "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);" (call_expression "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a)" (parenthesized_expression "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))" ( (pointer_expression "**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" * (pointer_expression "*(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" * (cast_expression "(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(*(long *)(DAT_00119ad8 + 8) + 0x60)" ( (binary_expression "*(long *)(DAT_00119ad8 + 8) + 0x60" (pointer_expression "*(long *)(DAT_00119ad8 + 8)" * (cast_expression "(long *)(DAT_00119ad8 + 8)" ( (type_descriptor "long *" (sized_type_specifier "long" long) (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(DAT_00119ad8 + 8)" ( (binary_expression "DAT_00119ad8 + 8" identifier + number_literal) )))) + number_literal) ))))) )) (argument_list "((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a)" ( (cast_expression "(long)*(int *)(puVar6[3] + uVar4 * 4)" ( (type_descriptor "long" (sized_type_specifier "long" long)) ) (pointer_expression "*(int *)(puVar6[3] + uVar4 * 4)" * (cast_expression "(int *)(puVar6[3] + uVar4 * 4)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6[3] + uVar4 * 4)" ( (binary_expression "puVar6[3] + uVar4 * 4" (subscript_expression "puVar6[3]" identifier [ number_literal ]) + (binary_expression "uVar4 * 4" identifier * number_literal)) ))))) , identifier ))) ;) (expression_statement "sVar2 = fwrite(local_3a,2,1,param_1);" (assignment_expression "sVar2 = fwrite(local_3a,2,1,param_1)" identifier = (call_expression "fwrite(local_3a,2,1,param_1)" identifier (argument_list "(local_3a,2,1,param_1)" ( identifier , number_literal , number_literal , identifier )))) ;) (if_statement "if (sVar2 != 1) goto LAB_0010a6cf;" if (parenthesized_expression "(sVar2 != 1)" ( (binary_expression "sVar2 != 1" identifier != number_literal) )) (goto_statement "goto LAB_0010a6cf;" goto statement_identifier ;)) (expression_statement "uVar3 = (int)uVar4 + 1;" (assignment_expression "uVar3 = (int)uVar4 + 1" identifier = (binary_expression "(int)uVar4 + 1" (cast_expression "(int)uVar4" ( (type_descriptor "int" primitive_type) ) identifier) + number_literal)) ;) (expression_statement "uVar4 = (ulong)uVar3;" (assignment_expression "uVar4 = (ulong)uVar3" identifier = (cast_expression "(ulong)uVar3" ( (type_descriptor "ulong" type_identifier) ) identifier)) ;) }) while (parenthesized_expression "(uVar3 < *(uint *)(puVar6 + 2))" ( (binary_expression "uVar3 < *(uint *)(puVar6 + 2)" identifier < (pointer_expression "*(uint *)(puVar6 + 2)" * (cast_expression "(uint *)(puVar6 + 2)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(puVar6 + 2)" ( (binary_expression "puVar6 + 2" identifier + number_literal) ))))) )) ;) })) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" identifier = (binary_expression "uVar5 + 1" identifier + number_literal)) ;) (if_statement "if (DAT_00119b20 <= uVar5) {\n      return;\n    }" if (parenthesized_expression "(DAT_00119b20 <= uVar5)" ( (binary_expression "DAT_00119b20 <= uVar5" identifier <= identifier) )) (compound_statement "{\n      return;\n    }" { (return_statement "return;" return ;) })) })) (labeled_statement "LAB_0010a6cf:\n  perror(param_2);" statement_identifier : (expression_statement "perror(param_2);" (call_expression "perror(param_2)" identifier (argument_list "(param_2)" ( identifier ))) ;)) (expression_statement "FUN_0010a4c0(1);" (call_expression "FUN_0010a4c0(1)" identifier (argument_list "(1)" ( number_literal ))) ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (return_statement return ;) })) (expression_statement (assignment_expression IDENT = LIT) ;) (while_statement while (parenthesized_expression ( BOOL )) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) * LIT) + IDENT) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (subscript_expression IDENT [ LIT ]) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (cast_expression ( (type_descriptor TYPE) ) IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (break_statement break ;)) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT) )) (compound_statement { (do_statement do (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor (sized_type_specifier long) (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT) ))))) )) (argument_list ( (cast_expression ( (type_descriptor (sized_type_specifier long)) ) (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + (binary_expression IDENT * LIT)) ))))) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , LIT , LIT , IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) + LIT)) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) }) while (parenthesized_expression ( (binary_expression IDENT < (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) ;) })) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT <= IDENT) )) (compound_statement { (return_statement return ;) })) })) (labeled_statement statement_identifier : (expression_statement (call_expression IDENT (argument_list ( IDENT ))) ;)) (expression_statement (call_expression IDENT (argument_list ( LIT ))) ;) })))
(function_definition "void FUN_0010a590(FILE *param_1,char *param_2)\n\n{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    \n  FUN_0010a4c0(1);\n}" (primitive_type "void") (function_declarator "FUN_0010a590(FILE *param_1,char *param_2)" (identifier "FUN_0010a590") (parameter_list "(FILE *param_1,char *param_2)" (( "(") (parameter_declaration "FILE *param_1" (type_identifier "FILE") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "char *param_2" (primitive_type "char") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) () ")"))) (compound_statement "{\n  int iVar1;\n  size_t sVar2;\n  uint uVar3;\n  ulong uVar4;\n  uint uVar5;\n  undefined8 *puVar6;\n  undefined1 local_3a [10];\n  \n  if (DAT_00119b20 == 0) {\n    return;\n  }\n  uVar5 = 0;\n  while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }\nLAB_0010a6cf:\n  perror(param_2);\n                    \n  FUN_0010a4c0(1);\n}" ({ "{") (declaration "int iVar1;" (primitive_type "int") (identifier "iVar1") (; ";")) (declaration "size_t sVar2;" (primitive_type "size_t") (identifier "sVar2") (; ";")) (declaration "uint uVar3;" (type_identifier "uint") (identifier "uVar3") (; ";")) (declaration "ulong uVar4;" (type_identifier "ulong") (identifier "uVar4") (; ";")) (declaration "uint uVar5;" (type_identifier "uint") (identifier "uVar5") (; ";")) (declaration "undefined8 *puVar6;" (type_identifier "undefined8") (pointer_declarator "*puVar6" (* "*") (identifier "puVar6")) (; ";")) (declaration "undefined1 local_3a [10];" (type_identifier "undefined1") (array_declarator "local_3a [10]" (identifier "local_3a") ([ "[") (number_literal "10") (] "]")) (; ";")) (if_statement "if (DAT_00119b20 == 0) {\n    return;\n  }" (if "if") (parenthesized_expression "(DAT_00119b20 == 0)" (( "(") (binary_expression "DAT_00119b20 == 0" (identifier "DAT_00119b20") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    return;\n  }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" (identifier "uVar5") (= "=") (number_literal "0")) (; ";")) (while_statement "while( true ) {\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }" (while "while") (parenthesized_expression "( true )" (( "(") (true "true") () ")")) (compound_statement "{\n    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);\n    iVar1 = FUN_001096f0(param_1,0);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,*puVar6);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109680(param_1,puVar6[1]);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);\n    if (iVar1 != 0) break;\n    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);\n    if (iVar1 != 0) break;\n    uVar4 = 0;\n    if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }\n    uVar5 = uVar5 + 1;\n    if (DAT_00119b20 <= uVar5) {\n      return;\n    }\n  }" ({ "{") (expression_statement "puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);" (assignment_expression "puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18)" (identifier "puVar6") (= "=") (cast_expression "(undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18)" (( "(") (type_descriptor "undefined8 *" (type_identifier "undefined8") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "((ulong)uVar5 * 0x20 + DAT_00119b18)" (( "(") (binary_expression "(ulong)uVar5 * 0x20 + DAT_00119b18" (binary_expression "(ulong)uVar5 * 0x20" (cast_expression "(ulong)uVar5" (( "(") (type_descriptor "ulong" (type_identifier "ulong")) () ")") (identifier "uVar5")) (* "*") (number_literal "0x20")) (+ "+") (identifier "DAT_00119b18")) () ")")))) (; ";")) (expression_statement "iVar1 = FUN_001096f0(param_1,0);" (assignment_expression "iVar1 = FUN_001096f0(param_1,0)" (identifier "iVar1") (= "=") (call_expression "FUN_001096f0(param_1,0)" (identifier "FUN_001096f0") (argument_list "(param_1,0)" (( "(") (identifier "param_1") (, ",") (number_literal "0") () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar1 = FUN_00109680(param_1,*puVar6);" (assignment_expression "iVar1 = FUN_00109680(param_1,*puVar6)" (identifier "iVar1") (= "=") (call_expression "FUN_00109680(param_1,*puVar6)" (identifier "FUN_00109680") (argument_list "(param_1,*puVar6)" (( "(") (identifier "param_1") (, ",") (pointer_expression "*puVar6" (* "*") (identifier "puVar6")) () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar1 = FUN_00109680(param_1,puVar6[1]);" (assignment_expression "iVar1 = FUN_00109680(param_1,puVar6[1])" (identifier "iVar1") (= "=") (call_expression "FUN_00109680(param_1,puVar6[1])" (identifier "FUN_00109680") (argument_list "(param_1,puVar6[1])" (( "(") (identifier "param_1") (, ",") (subscript_expression "puVar6[1]" (identifier "puVar6") ([ "[") (number_literal "1") (] "]")) () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));" (assignment_expression "iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2))" (identifier "iVar1") (= "=") (call_expression "FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2))" (identifier "FUN_00109630") (argument_list "(param_1,*(undefined4 *)(puVar6 + 2))" (( "(") (identifier "param_1") (, ",") (pointer_expression "*(undefined4 *)(puVar6 + 2)" (* "*") (cast_expression "(undefined4 *)(puVar6 + 2)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar6 + 2)" (( "(") (binary_expression "puVar6 + 2" (identifier "puVar6") (+ "+") (number_literal "2")) () ")")))) () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);" (assignment_expression "iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8)" (identifier "iVar1") (= "=") (call_expression "FUN_00109630(param_1,(undefined4)DAT_001195e8)" (identifier "FUN_00109630") (argument_list "(param_1,(undefined4)DAT_001195e8)" (( "(") (identifier "param_1") (, ",") (cast_expression "(undefined4)DAT_001195e8" (( "(") (type_descriptor "undefined4" (type_identifier "undefined4")) () ")") (identifier "DAT_001195e8")) () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);" (assignment_expression "iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf)" (identifier "iVar1") (= "=") (call_expression "FUN_00109720(param_1,s_seconds_001188a0,0xf)" (identifier "FUN_00109720") (argument_list "(param_1,s_seconds_001188a0,0xf)" (( "(") (identifier "param_1") (, ",") (identifier "s_seconds_001188a0") (, ",") (number_literal "0xf") () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "iVar1 = FUN_00109720(param_1,&DAT_00118890,1);" (assignment_expression "iVar1 = FUN_00109720(param_1,&DAT_00118890,1)" (identifier "iVar1") (= "=") (call_expression "FUN_00109720(param_1,&DAT_00118890,1)" (identifier "FUN_00109720") (argument_list "(param_1,&DAT_00118890,1)" (( "(") (identifier "param_1") (, ",") (pointer_expression "&DAT_00118890" (& "&") (identifier "DAT_00118890")) (, ",") (number_literal "1") () ")")))) (; ";")) (if_statement "if (iVar1 != 0) break;" (if "if") (parenthesized_expression "(iVar1 != 0)" (( "(") (binary_expression "iVar1 != 0" (identifier "iVar1") (!= "!=") (number_literal "0")) () ")")) (break_statement "break;" (break "break") (; ";"))) (expression_statement "uVar4 = 0;" (assignment_expression "uVar4 = 0" (identifier "uVar4") (= "=") (number_literal "0")) (; ";")) (if_statement "if (*(int *)(puVar6 + 2) != 0) {\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }" (if "if") (parenthesized_expression "(*(int *)(puVar6 + 2) != 0)" (( "(") (binary_expression "*(int *)(puVar6 + 2) != 0" (pointer_expression "*(int *)(puVar6 + 2)" (* "*") (cast_expression "(int *)(puVar6 + 2)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar6 + 2)" (( "(") (binary_expression "puVar6 + 2" (identifier "puVar6") (+ "+") (number_literal "2")) () ")")))) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));\n    }" ({ "{") (do_statement "do {\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      } while (uVar3 < *(uint *)(puVar6 + 2));" (do "do") (compound_statement "{\n        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);\n        sVar2 = fwrite(local_3a,2,1,param_1);\n        if (sVar2 != 1) goto LAB_0010a6cf;\n        uVar3 = (int)uVar4 + 1;\n        uVar4 = (ulong)uVar3;\n      }" ({ "{") (expression_statement "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);" (call_expression "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))\n                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a)" (parenthesized_expression "(**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))" (( "(") (pointer_expression "**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" (* "*") (pointer_expression "*(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" (* "*") (cast_expression "(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60)" (( "(") (type_descriptor "code **" (type_identifier "code") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(*(long *)(DAT_00119ad8 + 8) + 0x60)" (( "(") (binary_expression "*(long *)(DAT_00119ad8 + 8) + 0x60" (pointer_expression "*(long *)(DAT_00119ad8 + 8)" (* "*") (cast_expression "(long *)(DAT_00119ad8 + 8)" (( "(") (type_descriptor "long *" (sized_type_specifier "long" (long "long")) (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(DAT_00119ad8 + 8)" (( "(") (binary_expression "DAT_00119ad8 + 8" (identifier "DAT_00119ad8") (+ "+") (number_literal "8")) () ")")))) (+ "+") (number_literal "0x60")) () ")"))))) () ")")) (argument_list "((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a)" (( "(") (cast_expression "(long)*(int *)(puVar6[3] + uVar4 * 4)" (( "(") (type_descriptor "long" (sized_type_specifier "long" (long "long"))) () ")") (pointer_expression "*(int *)(puVar6[3] + uVar4 * 4)" (* "*") (cast_expression "(int *)(puVar6[3] + uVar4 * 4)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar6[3] + uVar4 * 4)" (( "(") (binary_expression "puVar6[3] + uVar4 * 4" (subscript_expression "puVar6[3]" (identifier "puVar6") ([ "[") (number_literal "3") (] "]")) (+ "+") (binary_expression "uVar4 * 4" (identifier "uVar4") (* "*") (number_literal "4"))) () ")"))))) (, ",") (identifier "local_3a") () ")"))) (; ";")) (expression_statement "sVar2 = fwrite(local_3a,2,1,param_1);" (assignment_expression "sVar2 = fwrite(local_3a,2,1,param_1)" (identifier "sVar2") (= "=") (call_expression "fwrite(local_3a,2,1,param_1)" (identifier "fwrite") (argument_list "(local_3a,2,1,param_1)" (( "(") (identifier "local_3a") (, ",") (number_literal "2") (, ",") (number_literal "1") (, ",") (identifier "param_1") () ")")))) (; ";")) (if_statement "if (sVar2 != 1) goto LAB_0010a6cf;" (if "if") (parenthesized_expression "(sVar2 != 1)" (( "(") (binary_expression "sVar2 != 1" (identifier "sVar2") (!= "!=") (number_literal "1")) () ")")) (goto_statement "goto LAB_0010a6cf;" (goto "goto") (statement_identifier "LAB_0010a6cf") (; ";"))) (expression_statement "uVar3 = (int)uVar4 + 1;" (assignment_expression "uVar3 = (int)uVar4 + 1" (identifier "uVar3") (= "=") (binary_expression "(int)uVar4 + 1" (cast_expression "(int)uVar4" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar4")) (+ "+") (number_literal "1"))) (; ";")) (expression_statement "uVar4 = (ulong)uVar3;" (assignment_expression "uVar4 = (ulong)uVar3" (identifier "uVar4") (= "=") (cast_expression "(ulong)uVar3" (( "(") (type_descriptor "ulong" (type_identifier "ulong")) () ")") (identifier "uVar3"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "(uVar3 < *(uint *)(puVar6 + 2))" (( "(") (binary_expression "uVar3 < *(uint *)(puVar6 + 2)" (identifier "uVar3") (< "<") (pointer_expression "*(uint *)(puVar6 + 2)" (* "*") (cast_expression "(uint *)(puVar6 + 2)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(puVar6 + 2)" (( "(") (binary_expression "puVar6 + 2" (identifier "puVar6") (+ "+") (number_literal "2")) () ")"))))) () ")")) (; ";")) (} "}"))) (expression_statement "uVar5 = uVar5 + 1;" (assignment_expression "uVar5 = uVar5 + 1" (identifier "uVar5") (= "=") (binary_expression "uVar5 + 1" (identifier "uVar5") (+ "+") (number_literal "1"))) (; ";")) (if_statement "if (DAT_00119b20 <= uVar5) {\n      return;\n    }" (if "if") (parenthesized_expression "(DAT_00119b20 <= uVar5)" (( "(") (binary_expression "DAT_00119b20 <= uVar5" (identifier "DAT_00119b20") (<= "<=") (identifier "uVar5")) () ")")) (compound_statement "{\n      return;\n    }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (} "}"))) (labeled_statement "LAB_0010a6cf:\n  perror(param_2);" (statement_identifier "LAB_0010a6cf") (: ":") (expression_statement "perror(param_2);" (call_expression "perror(param_2)" (identifier "perror") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")"))) (; ";"))) (expression_statement "FUN_0010a4c0(1);" (call_expression "FUN_0010a4c0(1)" (identifier "FUN_0010a4c0") (argument_list "(1)" (( "(") (number_literal "1") () ")"))) (; ";")) (} "}")))

void function_1(type_1 *ofp,char *filename)

{
  int var_5;
  size_t var_10;
  type_2 var_11;
  type_3 uVar4;
  type_2 var_3;
  type_4 *phVar6;
  type_5 count;
  
  if (var_1 == 0) {
    return;
  }
  var_3 = 0;
  while( true ) {
    phVar6 = var_2 + var_3;
    var_5 = var_4(ofp,0);
    if (var_5 != 0) break;
    var_5 = var_6(ofp,phVar6->lowpc);
    if (var_5 != 0) break;
    var_5 = var_6(ofp,phVar6->highpc);
    if (var_5 != 0) break;
    var_5 = var_7(ofp,phVar6->num_bins);
    if (var_5 != 0) break;
    var_5 = var_7(ofp,(type_2)hz);
    if (var_5 != 0) break;
    var_5 = var_8(ofp,hist_dimension,0xf);
    if (var_5 != 0) break;
    var_5 = var_8(ofp,&hist_dimension_abbrev,1);
    if (var_5 != 0) break;
    uVar4 = 0;
    if (phVar6->num_bins != 0) {
      do {
        (*core_bfd->xvec->bfd_putx16)((long)phVar6->sample[uVar4],count);
        var_10 = var_9(count,2,1,(type_1 *)ofp);
        if (var_10 != 1) goto LAB_0010a6cf;
        var_11 = (int)uVar4 + 1;
        uVar4 = (type_3)var_11;
      } while (var_11 < phVar6->num_bins);
    }
    var_3 = var_3 + 1;
    if (var_1 <= var_3) {
      return;
    }
  }
LAB_0010a6cf:
  var_12(filename);
                    /* WARNING: Subroutine does not return */
  var_13(1);
}


(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))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))))) body: (compound_statement (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (while_statement condition: (parenthesized_expression (true)) body: (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: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)) right: (number_literal)) right: (identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (subscript_expression argument: (identifier) index: (number_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (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))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (break_statement)) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) consequence: (compound_statement (do_statement body: (compound_statement (expression_statement (call_expression function: (parenthesized_expression (pointer_expression argument: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (sized_type_specifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))))))) arguments: (argument_list (cast_expression type: (type_descriptor type: (sized_type_specifier)) value: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal))))))) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (number_literal) (number_literal) (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier)) value: (identifier))))) condition: (parenthesized_expression (binary_expression left: (identifier) right: (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)))))))))) (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))))) (labeled_statement label: (statement_identifier) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (number_literal)))))))

void MASKED(FILE *param_1,char *param_2)

{
  int iVar1;
  size_t sVar2;
  uint uVar3;
  ulong uVar4;
  uint uVar5;
  undefined8 *puVar6;
  undefined1 local_3a [10];
  
  if (DAT_00119b20 == 0) {
    return;
  }
  uVar5 = 0;
  while( true ) {
    puVar6 = (undefined8 *)((ulong)uVar5 * 0x20 + DAT_00119b18);
    iVar1 = FUN_001096f0(param_1,0);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109680(param_1,*puVar6);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109680(param_1,puVar6[1]);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109630(param_1,*(undefined4 *)(puVar6 + 2));
    if (iVar1 != 0) break;
    iVar1 = FUN_00109630(param_1,(undefined4)DAT_001195e8);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109720(param_1,s_seconds_001188a0,0xf);
    if (iVar1 != 0) break;
    iVar1 = FUN_00109720(param_1,&DAT_00118890,1);
    if (iVar1 != 0) break;
    uVar4 = 0;
    if (*(int *)(puVar6 + 2) != 0) {
      do {
        (**(code **)(*(long *)(DAT_00119ad8 + 8) + 0x60))
                  ((long)*(int *)(puVar6[3] + uVar4 * 4),local_3a);
        sVar2 = fwrite(local_3a,2,1,param_1);
        if (sVar2 != 1) goto LAB_0010a6cf;
        uVar3 = (int)uVar4 + 1;
        uVar4 = (ulong)uVar3;
      } while (uVar3 < *(uint *)(puVar6 + 2));
    }
    uVar5 = uVar5 + 1;
    if (DAT_00119b20 <= uVar5) {
      return;
    }
  }
LAB_0010a6cf:
  perror(param_2);
                    /* WARNING: Subroutine does not return */
  FUN_0010a4c0(1);
}

