
void fts5WriteFlushBtree(Fts5Index *p,Fts5SegWriter *pWriter)

{
  uint uVar1;
  int iVar2;
  u8 *puVar3;
  Fts5DlidxWriter *pFVar4;
  uint uVar5;
  int iVar6;
  int in_t9;
  
  if (pWriter->iBtPage == 0) {
    return;
  }
  pFVar4 = pWriter->aDlidx;
  iVar2 = (pFVar4->buf).n;
  if (iVar2 < 1) {
    uVar5 = 0;
    if (pWriter->nDlidx < 1) goto LAB_0012d680;
    if (iVar2 == 0) {
      uVar5 = 0;
      goto LAB_0012d680;
    }
  }
  else {
    uVar5 = pWriter->nEmpty < 4 ^ 1;
    if (pWriter->nDlidx < 1) goto LAB_0012d680;
  }
  iVar2 = 0;
  iVar6 = *(int *)(in_t9 + 0x626d0);
  do {
    if (uVar5 != 0) {
      (*(code *)(iVar6 + -0x3898))(p);
    }
    (pFVar4->buf).n = 0;
    pFVar4->bPrevValid = 0;
    iVar2 = iVar2 + 1;
  } while ((iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0));
LAB_0012d680:
  pWriter->nEmpty = 0;
  if (p->rc == 0) {
    iVar2 = (pWriter->btterm).n;
    if (iVar2 < 1) {
      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);
    }
    else {
      puVar3 = (pWriter->btterm).p;
    }
    (**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);
    uVar1 = pWriter->iBtPage;
    (**(code **)(in_t9 + 0x625ac))
              (p->pIdxWriter,3,
               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));
    (**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);
    iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);
    p->rc = iVar2;
    (**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);
  }
  pWriter->iBtPage = 0;
  return;
}



void FUN_0012d518(int param_1,int param_2)

{
  uint uVar1;
  undefined4 uVar2;
  undefined *puVar3;
  int iVar4;
  int iVar5;
  uint uVar6;
  code *pcVar7;
  
  if (*(int *)(param_2 + 0x58) == 0) {
    return;
  }
  iVar4 = *(int *)(param_2 + 0x48);
  if (*(int *)(iVar4 + 0x14) < 1) {
    uVar6 = 0;
    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;
    if (*(int *)(iVar4 + 0x14) == 0) {
      uVar6 = 0;
      goto LAB_0012d680;
    }
  }
  else {
    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;
    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;
  }
  iVar5 = 0;
  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);
  do {
    if (uVar6 != 0) {
      (*pcVar7)(param_1);
    }
    *(undefined4 *)(iVar4 + 0x14) = 0;
    *(undefined4 *)(iVar4 + 4) = 0;
    iVar5 = iVar5 + 1;
  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&
          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));
LAB_0012d680:
  *(undefined4 *)(param_2 + 0x40) = 0;
  if (*(int *)(param_1 + 0x24) == 0) {
    if (*(int *)(param_2 + 0x50) < 1) {
      puVar3 = PTR_LAB_0018f958 + 0x2d20;
    }
    else {
      puVar3 = *(undefined **)(param_2 + 0x4c);
    }
    (*(code *)PTR_sqlite3_bind_blob_0018facc)
              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);
    uVar1 = *(uint *)(param_2 + 0x58);
    (*(code *)PTR_sqlite3_bind_int64_0018fac4)
              (*(undefined4 *)(param_1 + 0x34),3,
               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));
    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));
    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));
    *(undefined4 *)(param_1 + 0x24) = uVar2;
    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);
  }
  *(undefined4 *)(param_2 + 0x58) = 0;
  return;
}


lui gp,0x7
addiu gp,gp,-0x5bf8
addu gp,gp,t9
addiu sp,sp,-0x48
sw ra,0x44(sp)
sw s8,0x40(sp)
sw s7,0x3c(sp)
sw s6,0x38(sp)
sw s5,0x34(sp)
sw s4,0x30(sp)
sw s3,0x2c(sp)
sw s2,0x28(sp)
sw s1,0x24(sp)
sw s0,0x20(sp)
sw gp,0x18(sp)
lw v0,0x58(a1)
bne v0,zero,0x0012d590
_or s1,a1,zero
lw ra,0x44(sp)
lw s8,0x40(sp)
lw s7,0x3c(sp)
lw s6,0x38(sp)
lw s5,0x34(sp)
lw s4,0x30(sp)
lw s3,0x2c(sp)
lw s2,0x28(sp)
lw s1,0x24(sp)
lw s0,0x20(sp)
jr ra
_addiu sp,sp,0x48
lw s0,0x48(a1)
lw v1,0x14(s0)
blez v1,0x0012d5d0
_or s3,a0,zero
lw s5,0x40(a1)
slti s5,s5,0x4
lw v0,0x44(a1)
blez v0,0x0012d680
_xori s5,s5,0x1
or s6,zero,zero
or s2,zero,zero
or s4,zero,zero
lw s7,-0x7d38(gp)
addiu s7,s7,-0x3898
b 0x0012d66c
_lui s8,0x8000
lw v0,0x44(a1)
blez v0,0x0012d680
_or s5,zero,zero
beq v1,zero,0x0012d67c
_nop
b 0x0012d5b8
_or s6,zero,zero
sll v0,v0,0x5
addiu v0,v0,0x10
addu v0,v0,s6
lw a3,0x0(s0)
sra a0,a3,0x1f
addu a3,s2,a3
sltu a2,a3,s2
addu v0,v0,a0
sw v1,0x14(sp)
lw v1,0x10(s0)
sw v1,0x10(sp)
addu a2,a2,v0
or a0,s3,zero
or t9,s7,zero
jalr t9
_nop
lw gp,0x18(sp)
sw zero,0x14(s0)
sw zero,0x4(s0)
addiu s4,s4,0x1
lw v0,0x44(s1)
slt v0,s4,v0
beq v0,zero,0x0012d680
_sll s0,s4,0x5
lw v0,0x48(s1)
addu s0,v0,s0
lw v1,0x14(s0)
addu v0,s2,s8
sltu s2,v0,s2
addu s6,s2,s6
beq v1,zero,0x0012d680
_or s2,v0,zero
beq s5,zero,0x0012d630
_nop
b 0x0012d5ec
_lw v0,0x0(s1)
or s5,v1,zero
sw zero,0x40(s1)
lw v0,0x24(s3)
bne v0,zero,0x0012d744
_nop
lw a3,0x50(s1)
blez a3,0x0012d74c
_lw a2,-0x7fc8(gp)
lw a2,0x4c(s1)
sw zero,0x10(sp)
li a1,0x2
lw a0,0x34(s3)
lw t9,-0x7e54(gp)
jalr t9
_nop
lw gp,0x18(sp)
lw v0,0x58(s1)
sra a2,v0,0x1f
srl v1,v0,0x1f
sll a2,a2,0x1
or a2,v1,a2
sll v0,v0,0x1
sra v1,s5,0x1f
addu a3,v0,s5
sltu v0,a3,v0
addu a2,a2,v1
addu a2,v0,a2
li a1,0x3
lw a0,0x34(s3)
lw t9,-0x7e5c(gp)
jalr t9
_nop
lw gp,0x18(sp)
lw a0,0x34(s3)
lw t9,-0x7f9c(gp)
jalr t9
_nop
lw gp,0x18(sp)
lw a0,0x34(s3)
lw t9,-0x7eb0(gp)
jalr t9
_nop
lw gp,0x18(sp)
sw v0,0x24(s3)
li a1,0x2
lw a0,0x34(s3)
lw t9,-0x7e60(gp)
jalr t9
_nop
lw gp,0x18(sp)
b 0x0012d560
_sw zero,0x58(s1)
b 0x0012d6a0
_addiu a2,a2,0x2d20
(translation_unit "void FUN_0012d518(int param_1,int param_2)\n\n{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}\n\n" (function_definition "void FUN_0012d518(int param_1,int param_2)\n\n{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}" primitive_type (function_declarator "FUN_0012d518(int param_1,int param_2)" identifier (parameter_list "(int param_1,int param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "undefined *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "uint uVar6;" type_identifier identifier ;) (declaration "code *pcVar7;" type_identifier (pointer_declarator "*pcVar7" * identifier) ;) (if_statement "if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }" if (parenthesized_expression "(*(int *)(param_2 + 0x58) == 0)" ( (binary_expression "*(int *)(param_2 + 0x58) == 0" (pointer_expression "*(int *)(param_2 + 0x58)" * (cast_expression "(int *)(param_2 + 0x58)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x58)" ( (binary_expression "param_2 + 0x58" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "iVar4 = *(int *)(param_2 + 0x48);" (assignment_expression "iVar4 = *(int *)(param_2 + 0x48)" identifier = (pointer_expression "*(int *)(param_2 + 0x48)" * (cast_expression "(int *)(param_2 + 0x48)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x48)" ( (binary_expression "param_2 + 0x48" identifier + number_literal) ))))) ;) (if_statement "if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" if (parenthesized_expression "(*(int *)(iVar4 + 0x14) < 1)" ( (binary_expression "*(int *)(iVar4 + 0x14) < 1" (pointer_expression "*(int *)(iVar4 + 0x14)" * (cast_expression "(int *)(iVar4 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) < number_literal) )) (compound_statement "{\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }" { (expression_statement "uVar6 = 0;" (assignment_expression "uVar6 = 0" identifier = number_literal) ;) (if_statement "if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;" if (parenthesized_expression "(*(int *)(param_2 + 0x44) < 1)" ( (binary_expression "*(int *)(param_2 + 0x44) < 1" (pointer_expression "*(int *)(param_2 + 0x44)" * (cast_expression "(int *)(param_2 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x44)" ( (binary_expression "param_2 + 0x44" identifier + number_literal) )))) < number_literal) )) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;)) (if_statement "if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }" if (parenthesized_expression "(*(int *)(iVar4 + 0x14) == 0)" ( (binary_expression "*(int *)(iVar4 + 0x14) == 0" (pointer_expression "*(int *)(iVar4 + 0x14)" * (cast_expression "(int *)(iVar4 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }" { (expression_statement "uVar6 = 0;" (assignment_expression "uVar6 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;) })) }) (else_clause "else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" else (compound_statement "{\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" { (expression_statement "uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;" (assignment_expression "uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1" identifier = (binary_expression "*(int *)(param_2 + 0x40) < 4 ^ 1" (binary_expression "*(int *)(param_2 + 0x40) < 4" (pointer_expression "*(int *)(param_2 + 0x40)" * (cast_expression "(int *)(param_2 + 0x40)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x40)" ( (binary_expression "param_2 + 0x40" identifier + number_literal) )))) < number_literal) ^ number_literal)) ;) (if_statement "if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;" if (parenthesized_expression "(*(int *)(param_2 + 0x44) < 1)" ( (binary_expression "*(int *)(param_2 + 0x44) < 1" (pointer_expression "*(int *)(param_2 + 0x44)" * (cast_expression "(int *)(param_2 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x44)" ( (binary_expression "param_2 + 0x44" identifier + number_literal) )))) < number_literal) )) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;)) }))) (expression_statement "iVar5 = 0;" (assignment_expression "iVar5 = 0" identifier = number_literal) ;) (expression_statement "pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);" (assignment_expression "pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898)" identifier = (cast_expression "(code *)(PTR_LAB_0018fbe8 + -0x3898)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_0018fbe8 + -0x3898)" ( (binary_expression "PTR_LAB_0018fbe8 + -0x3898" identifier + number_literal) )))) ;) (do_statement "do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));" do (compound_statement "{\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  }" { (if_statement "if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }" if (parenthesized_expression "(uVar6 != 0)" ( (binary_expression "uVar6 != 0" identifier != number_literal) )) (compound_statement "{\n      (*pcVar7)(param_1);\n    }" { (expression_statement "(*pcVar7)(param_1);" (call_expression "(*pcVar7)(param_1)" (parenthesized_expression "(*pcVar7)" ( (pointer_expression "*pcVar7" * identifier) )) (argument_list "(param_1)" ( identifier ))) ;) })) (expression_statement "*(undefined4 *)(iVar4 + 0x14) = 0;" (assignment_expression "*(undefined4 *)(iVar4 + 0x14) = 0" (pointer_expression "*(undefined4 *)(iVar4 + 0x14)" * (cast_expression "(undefined4 *)(iVar4 + 0x14)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined4 *)(iVar4 + 4) = 0;" (assignment_expression "*(undefined4 *)(iVar4 + 4) = 0" (pointer_expression "*(undefined4 *)(iVar4 + 4)" * (cast_expression "(undefined4 *)(iVar4 + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 4)" ( (binary_expression "iVar4 + 4" identifier + number_literal) )))) = number_literal) ;) (expression_statement "iVar5 = iVar5 + 1;" (assignment_expression "iVar5 = iVar5 + 1" identifier = (binary_expression "iVar5 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0))" ( (binary_expression "(iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0)" (parenthesized_expression "(iVar5 < *(int *)(param_2 + 0x44))" ( (binary_expression "iVar5 < *(int *)(param_2 + 0x44)" identifier < (pointer_expression "*(int *)(param_2 + 0x44)" * (cast_expression "(int *)(param_2 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x44)" ( (binary_expression "param_2 + 0x44" identifier + number_literal) ))))) )) && (parenthesized_expression "(iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0)" ( (comma_expression "iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0" (assignment_expression "iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20" identifier = (binary_expression "*(int *)(param_2 + 0x48) + iVar5 * 0x20" (pointer_expression "*(int *)(param_2 + 0x48)" * (cast_expression "(int *)(param_2 + 0x48)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x48)" ( (binary_expression "param_2 + 0x48" identifier + number_literal) )))) + (binary_expression "iVar5 * 0x20" identifier * number_literal))) , (binary_expression "*(int *)(iVar4 + 0x14) != 0" (pointer_expression "*(int *)(iVar4 + 0x14)" * (cast_expression "(int *)(iVar4 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) != number_literal)) ))) )) ;) (labeled_statement "LAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;" statement_identifier : (expression_statement "*(undefined4 *)(param_2 + 0x40) = 0;" (assignment_expression "*(undefined4 *)(param_2 + 0x40) = 0" (pointer_expression "*(undefined4 *)(param_2 + 0x40)" * (cast_expression "(undefined4 *)(param_2 + 0x40)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x40)" ( (binary_expression "param_2 + 0x40" identifier + number_literal) )))) = number_literal) ;)) (if_statement "if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x24) == 0)" ( (binary_expression "*(int *)(param_1 + 0x24) == 0" (pointer_expression "*(int *)(param_1 + 0x24)" * (cast_expression "(int *)(param_1 + 0x24)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x24)" ( (binary_expression "param_1 + 0x24" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }" { (if_statement "if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" if (parenthesized_expression "(*(int *)(param_2 + 0x50) < 1)" ( (binary_expression "*(int *)(param_2 + 0x50) < 1" (pointer_expression "*(int *)(param_2 + 0x50)" * (cast_expression "(int *)(param_2 + 0x50)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x50)" ( (binary_expression "param_2 + 0x50" identifier + number_literal) )))) < number_literal) )) (compound_statement "{\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }" { (expression_statement "puVar3 = PTR_LAB_0018f958 + 0x2d20;" (assignment_expression "puVar3 = PTR_LAB_0018f958 + 0x2d20" identifier = (binary_expression "PTR_LAB_0018f958 + 0x2d20" identifier + number_literal)) ;) }) (else_clause "else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" else (compound_statement "{\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" { (expression_statement "puVar3 = *(undefined **)(param_2 + 0x4c);" (assignment_expression "puVar3 = *(undefined **)(param_2 + 0x4c)" identifier = (pointer_expression "*(undefined **)(param_2 + 0x4c)" * (cast_expression "(undefined **)(param_2 + 0x4c)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_2 + 0x4c)" ( (binary_expression "param_2 + 0x4c" identifier + number_literal) ))))) ;) }))) (expression_statement "(*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);" (call_expression "(*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0)" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_blob_0018facc)" ( (pointer_expression "*(code *)PTR_sqlite3_bind_blob_0018facc" * (cast_expression "(code *)PTR_sqlite3_bind_blob_0018facc" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0)" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) , number_literal , identifier , (pointer_expression "*(int *)(param_2 + 0x50)" * (cast_expression "(int *)(param_2 + 0x50)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x50)" ( (binary_expression "param_2 + 0x50" identifier + number_literal) )))) , number_literal ))) ;) (expression_statement "uVar1 = *(uint *)(param_2 + 0x58);" (assignment_expression "uVar1 = *(uint *)(param_2 + 0x58)" identifier = (pointer_expression "*(uint *)(param_2 + 0x58)" * (cast_expression "(uint *)(param_2 + 0x58)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x58)" ( (binary_expression "param_2 + 0x58" identifier + number_literal) ))))) ;) (expression_statement "(*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));" (call_expression "(*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_int64_0018fac4)" ( (pointer_expression "*(code *)PTR_sqlite3_bind_int64_0018fac4" * (cast_expression "(code *)PTR_sqlite3_bind_int64_0018fac4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) , number_literal , (binary_expression "(uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" (call_expression "(uint)(uVar1 * 2 + uVar6 < uVar1 * 2)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(uVar1 * 2 + uVar6 < uVar1 * 2)" ( (binary_expression "uVar1 * 2 + uVar6 < uVar1 * 2" (binary_expression "uVar1 * 2 + uVar6" (binary_expression "uVar1 * 2" identifier * number_literal) + identifier) < (binary_expression "uVar1 * 2" identifier * number_literal)) ))) + (parenthesized_expression "(uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" ( (binary_expression "uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1" (binary_expression "uVar1 >> 0x1f" identifier >> number_literal) | (binary_expression "((int)uVar1 >> 0x1f) << 1" (parenthesized_expression "((int)uVar1 >> 0x1f)" ( (binary_expression "(int)uVar1 >> 0x1f" (cast_expression "(int)uVar1" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) << number_literal)) ))) ))) ;) (expression_statement "(*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));" (call_expression "(*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34))" (parenthesized_expression "(*(code *)PTR_sqlite3_step_0018f984)" ( (pointer_expression "*(code *)PTR_sqlite3_step_0018f984" * (cast_expression "(code *)PTR_sqlite3_step_0018f984" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34))" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) ))) ;) (expression_statement "uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));" (assignment_expression "uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34))" identifier = (call_expression "(*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34))" (parenthesized_expression "(*(code *)PTR_sqlite3_reset_0018fa70)" ( (pointer_expression "*(code *)PTR_sqlite3_reset_0018fa70" * (cast_expression "(code *)PTR_sqlite3_reset_0018fa70" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34))" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) )))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x24) = uVar2;" (assignment_expression "*(undefined4 *)(param_1 + 0x24) = uVar2" (pointer_expression "*(undefined4 *)(param_1 + 0x24)" * (cast_expression "(undefined4 *)(param_1 + 0x24)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x24)" ( (binary_expression "param_1 + 0x24" identifier + number_literal) )))) = identifier) ;) (expression_statement "(*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);" (call_expression "(*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2)" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_null_0018fac0)" ( (pointer_expression "*(code *)PTR_sqlite3_bind_null_0018fac0" * (cast_expression "(code *)PTR_sqlite3_bind_null_0018fac0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34),2)" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) , number_literal ))) ;) })) (expression_statement "*(undefined4 *)(param_2 + 0x58) = 0;" (assignment_expression "*(undefined4 *)(param_2 + 0x58) = 0" (pointer_expression "*(undefined4 *)(param_2 + 0x58)" * (cast_expression "(undefined4 *)(param_2 + 0x58)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x58)" ( (binary_expression "param_2 + 0x58" identifier + number_literal) )))) = number_literal) ;) (return_statement "return;" return ;) })))
(translation_unit "void fts5WriteFlushBtree(Fts5Index *p,Fts5SegWriter *pWriter)\n\n{\n  uint uVar1;\n  int iVar2;\n  u8 *puVar3;\n  Fts5DlidxWriter *pFVar4;\n  uint uVar5;\n  int iVar6;\n  int in_t9;\n  \n  if (pWriter->iBtPage == 0) {\n    return;\n  }\n  pFVar4 = pWriter->aDlidx;\n  iVar2 = (pFVar4->buf).n;\n  if (iVar2 < 1) {\n    uVar5 = 0;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n    if (iVar2 == 0) {\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar5 = pWriter->nEmpty < 4 ^ 1;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n  }\n  iVar2 = 0;\n  iVar6 = *(int *)(in_t9 + 0x626d0);\n  do {\n    if (uVar5 != 0) {\n      (*(code *)(iVar6 + -0x3898))(p);\n    }\n    (pFVar4->buf).n = 0;\n    pFVar4->bPrevValid = 0;\n    iVar2 = iVar2 + 1;\n  } while ((iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0));\nLAB_0012d680:\n  pWriter->nEmpty = 0;\n  if (p->rc == 0) {\n    iVar2 = (pWriter->btterm).n;\n    if (iVar2 < 1) {\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }\n    else {\n      puVar3 = (pWriter->btterm).p;\n    }\n    (**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);\n    uVar1 = pWriter->iBtPage;\n    (**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);\n    iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);\n    p->rc = iVar2;\n    (**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);\n  }\n  pWriter->iBtPage = 0;\n  return;\n}\n\n" (function_definition "void fts5WriteFlushBtree(Fts5Index *p,Fts5SegWriter *pWriter)\n\n{\n  uint uVar1;\n  int iVar2;\n  u8 *puVar3;\n  Fts5DlidxWriter *pFVar4;\n  uint uVar5;\n  int iVar6;\n  int in_t9;\n  \n  if (pWriter->iBtPage == 0) {\n    return;\n  }\n  pFVar4 = pWriter->aDlidx;\n  iVar2 = (pFVar4->buf).n;\n  if (iVar2 < 1) {\n    uVar5 = 0;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n    if (iVar2 == 0) {\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar5 = pWriter->nEmpty < 4 ^ 1;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n  }\n  iVar2 = 0;\n  iVar6 = *(int *)(in_t9 + 0x626d0);\n  do {\n    if (uVar5 != 0) {\n      (*(code *)(iVar6 + -0x3898))(p);\n    }\n    (pFVar4->buf).n = 0;\n    pFVar4->bPrevValid = 0;\n    iVar2 = iVar2 + 1;\n  } while ((iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0));\nLAB_0012d680:\n  pWriter->nEmpty = 0;\n  if (p->rc == 0) {\n    iVar2 = (pWriter->btterm).n;\n    if (iVar2 < 1) {\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }\n    else {\n      puVar3 = (pWriter->btterm).p;\n    }\n    (**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);\n    uVar1 = pWriter->iBtPage;\n    (**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);\n    iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);\n    p->rc = iVar2;\n    (**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);\n  }\n  pWriter->iBtPage = 0;\n  return;\n}" primitive_type (function_declarator "fts5WriteFlushBtree(Fts5Index *p,Fts5SegWriter *pWriter)" identifier (parameter_list "(Fts5Index *p,Fts5SegWriter *pWriter)" ( (parameter_declaration "Fts5Index *p" type_identifier (pointer_declarator "*p" * identifier)) , (parameter_declaration "Fts5SegWriter *pWriter" type_identifier (pointer_declarator "*pWriter" * identifier)) ))) (compound_statement "{\n  uint uVar1;\n  int iVar2;\n  u8 *puVar3;\n  Fts5DlidxWriter *pFVar4;\n  uint uVar5;\n  int iVar6;\n  int in_t9;\n  \n  if (pWriter->iBtPage == 0) {\n    return;\n  }\n  pFVar4 = pWriter->aDlidx;\n  iVar2 = (pFVar4->buf).n;\n  if (iVar2 < 1) {\n    uVar5 = 0;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n    if (iVar2 == 0) {\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar5 = pWriter->nEmpty < 4 ^ 1;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n  }\n  iVar2 = 0;\n  iVar6 = *(int *)(in_t9 + 0x626d0);\n  do {\n    if (uVar5 != 0) {\n      (*(code *)(iVar6 + -0x3898))(p);\n    }\n    (pFVar4->buf).n = 0;\n    pFVar4->bPrevValid = 0;\n    iVar2 = iVar2 + 1;\n  } while ((iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0));\nLAB_0012d680:\n  pWriter->nEmpty = 0;\n  if (p->rc == 0) {\n    iVar2 = (pWriter->btterm).n;\n    if (iVar2 < 1) {\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }\n    else {\n      puVar3 = (pWriter->btterm).p;\n    }\n    (**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);\n    uVar1 = pWriter->iBtPage;\n    (**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);\n    iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);\n    p->rc = iVar2;\n    (**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);\n  }\n  pWriter->iBtPage = 0;\n  return;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "u8 *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "Fts5DlidxWriter *pFVar4;" type_identifier (pointer_declarator "*pFVar4" * identifier) ;) (declaration "uint uVar5;" type_identifier identifier ;) (declaration "int iVar6;" primitive_type identifier ;) (declaration "int in_t9;" primitive_type identifier ;) (if_statement "if (pWriter->iBtPage == 0) {\n    return;\n  }" if (parenthesized_expression "(pWriter->iBtPage == 0)" ( (binary_expression "pWriter->iBtPage == 0" (field_expression "pWriter->iBtPage" identifier -> field_identifier) == number_literal) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "pFVar4 = pWriter->aDlidx;" (assignment_expression "pFVar4 = pWriter->aDlidx" identifier = (field_expression "pWriter->aDlidx" identifier -> field_identifier)) ;) (expression_statement "iVar2 = (pFVar4->buf).n;" (assignment_expression "iVar2 = (pFVar4->buf).n" identifier = (field_expression "(pFVar4->buf).n" (parenthesized_expression "(pFVar4->buf)" ( (field_expression "pFVar4->buf" identifier -> field_identifier) )) . field_identifier)) ;) (if_statement "if (iVar2 < 1) {\n    uVar5 = 0;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n    if (iVar2 == 0) {\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar5 = pWriter->nEmpty < 4 ^ 1;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n  }" if (parenthesized_expression "(iVar2 < 1)" ( (binary_expression "iVar2 < 1" identifier < number_literal) )) (compound_statement "{\n    uVar5 = 0;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n    if (iVar2 == 0) {\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }\n  }" { (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (if_statement "if (pWriter->nDlidx < 1) goto LAB_0012d680;" if (parenthesized_expression "(pWriter->nDlidx < 1)" ( (binary_expression "pWriter->nDlidx < 1" (field_expression "pWriter->nDlidx" identifier -> field_identifier) < number_literal) )) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;)) (if_statement "if (iVar2 == 0) {\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }" if (parenthesized_expression "(iVar2 == 0)" ( (binary_expression "iVar2 == 0" identifier == number_literal) )) (compound_statement "{\n      uVar5 = 0;\n      goto LAB_0012d680;\n    }" { (expression_statement "uVar5 = 0;" (assignment_expression "uVar5 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;) })) }) (else_clause "else {\n    uVar5 = pWriter->nEmpty < 4 ^ 1;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n  }" else (compound_statement "{\n    uVar5 = pWriter->nEmpty < 4 ^ 1;\n    if (pWriter->nDlidx < 1) goto LAB_0012d680;\n  }" { (expression_statement "uVar5 = pWriter->nEmpty < 4 ^ 1;" (assignment_expression "uVar5 = pWriter->nEmpty < 4 ^ 1" identifier = (binary_expression "pWriter->nEmpty < 4 ^ 1" (binary_expression "pWriter->nEmpty < 4" (field_expression "pWriter->nEmpty" identifier -> field_identifier) < number_literal) ^ number_literal)) ;) (if_statement "if (pWriter->nDlidx < 1) goto LAB_0012d680;" if (parenthesized_expression "(pWriter->nDlidx < 1)" ( (binary_expression "pWriter->nDlidx < 1" (field_expression "pWriter->nDlidx" identifier -> field_identifier) < number_literal) )) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;)) }))) (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) (expression_statement "iVar6 = *(int *)(in_t9 + 0x626d0);" (assignment_expression "iVar6 = *(int *)(in_t9 + 0x626d0)" identifier = (pointer_expression "*(int *)(in_t9 + 0x626d0)" * (cast_expression "(int *)(in_t9 + 0x626d0)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_t9 + 0x626d0)" ( (binary_expression "in_t9 + 0x626d0" identifier + number_literal) ))))) ;) (do_statement "do {\n    if (uVar5 != 0) {\n      (*(code *)(iVar6 + -0x3898))(p);\n    }\n    (pFVar4->buf).n = 0;\n    pFVar4->bPrevValid = 0;\n    iVar2 = iVar2 + 1;\n  } while ((iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0));" do (compound_statement "{\n    if (uVar5 != 0) {\n      (*(code *)(iVar6 + -0x3898))(p);\n    }\n    (pFVar4->buf).n = 0;\n    pFVar4->bPrevValid = 0;\n    iVar2 = iVar2 + 1;\n  }" { (if_statement "if (uVar5 != 0) {\n      (*(code *)(iVar6 + -0x3898))(p);\n    }" if (parenthesized_expression "(uVar5 != 0)" ( (binary_expression "uVar5 != 0" identifier != number_literal) )) (compound_statement "{\n      (*(code *)(iVar6 + -0x3898))(p);\n    }" { (expression_statement "(*(code *)(iVar6 + -0x3898))(p);" (call_expression "(*(code *)(iVar6 + -0x3898))(p)" (parenthesized_expression "(*(code *)(iVar6 + -0x3898))" ( (pointer_expression "*(code *)(iVar6 + -0x3898)" * (cast_expression "(code *)(iVar6 + -0x3898)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar6 + -0x3898)" ( (binary_expression "iVar6 + -0x3898" identifier + number_literal) )))) )) (argument_list "(p)" ( identifier ))) ;) })) (expression_statement "(pFVar4->buf).n = 0;" (assignment_expression "(pFVar4->buf).n = 0" (field_expression "(pFVar4->buf).n" (parenthesized_expression "(pFVar4->buf)" ( (field_expression "pFVar4->buf" identifier -> field_identifier) )) . field_identifier) = number_literal) ;) (expression_statement "pFVar4->bPrevValid = 0;" (assignment_expression "pFVar4->bPrevValid = 0" (field_expression "pFVar4->bPrevValid" identifier -> field_identifier) = number_literal) ;) (expression_statement "iVar2 = iVar2 + 1;" (assignment_expression "iVar2 = iVar2 + 1" identifier = (binary_expression "iVar2 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "((iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0))" ( (binary_expression "(iVar2 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0)" (parenthesized_expression "(iVar2 < pWriter->nDlidx)" ( (binary_expression "iVar2 < pWriter->nDlidx" identifier < (field_expression "pWriter->nDlidx" identifier -> field_identifier)) )) && (parenthesized_expression "(pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0)" ( (comma_expression "pFVar4 = pWriter->aDlidx + iVar2, (pFVar4->buf).n != 0" (assignment_expression "pFVar4 = pWriter->aDlidx + iVar2" identifier = (binary_expression "pWriter->aDlidx + iVar2" (field_expression "pWriter->aDlidx" identifier -> field_identifier) + identifier)) , (binary_expression "(pFVar4->buf).n != 0" (field_expression "(pFVar4->buf).n" (parenthesized_expression "(pFVar4->buf)" ( (field_expression "pFVar4->buf" identifier -> field_identifier) )) . field_identifier) != number_literal)) ))) )) ;) (labeled_statement "LAB_0012d680:\n  pWriter->nEmpty = 0;" statement_identifier : (expression_statement "pWriter->nEmpty = 0;" (assignment_expression "pWriter->nEmpty = 0" (field_expression "pWriter->nEmpty" identifier -> field_identifier) = number_literal) ;)) (if_statement "if (p->rc == 0) {\n    iVar2 = (pWriter->btterm).n;\n    if (iVar2 < 1) {\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }\n    else {\n      puVar3 = (pWriter->btterm).p;\n    }\n    (**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);\n    uVar1 = pWriter->iBtPage;\n    (**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);\n    iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);\n    p->rc = iVar2;\n    (**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);\n  }" if (parenthesized_expression "(p->rc == 0)" ( (binary_expression "p->rc == 0" (field_expression "p->rc" identifier -> field_identifier) == number_literal) )) (compound_statement "{\n    iVar2 = (pWriter->btterm).n;\n    if (iVar2 < 1) {\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }\n    else {\n      puVar3 = (pWriter->btterm).p;\n    }\n    (**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);\n    uVar1 = pWriter->iBtPage;\n    (**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);\n    iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);\n    p->rc = iVar2;\n    (**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);\n  }" { (expression_statement "iVar2 = (pWriter->btterm).n;" (assignment_expression "iVar2 = (pWriter->btterm).n" identifier = (field_expression "(pWriter->btterm).n" (parenthesized_expression "(pWriter->btterm)" ( (field_expression "pWriter->btterm" identifier -> field_identifier) )) . field_identifier)) ;) (if_statement "if (iVar2 < 1) {\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }\n    else {\n      puVar3 = (pWriter->btterm).p;\n    }" if (parenthesized_expression "(iVar2 < 1)" ( (binary_expression "iVar2 < 1" identifier < number_literal) )) (compound_statement "{\n      puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);\n    }" { (expression_statement "puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20);" (assignment_expression "puVar3 = (u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20)" identifier = (cast_expression "(u8 *)(*(int *)(in_t9 + 0x62440) + 0x2d20)" ( (type_descriptor "u8 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(*(int *)(in_t9 + 0x62440) + 0x2d20)" ( (binary_expression "*(int *)(in_t9 + 0x62440) + 0x2d20" (pointer_expression "*(int *)(in_t9 + 0x62440)" * (cast_expression "(int *)(in_t9 + 0x62440)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(in_t9 + 0x62440)" ( (binary_expression "in_t9 + 0x62440" identifier + number_literal) )))) + number_literal) )))) ;) }) (else_clause "else {\n      puVar3 = (pWriter->btterm).p;\n    }" else (compound_statement "{\n      puVar3 = (pWriter->btterm).p;\n    }" { (expression_statement "puVar3 = (pWriter->btterm).p;" (assignment_expression "puVar3 = (pWriter->btterm).p" identifier = (field_expression "(pWriter->btterm).p" (parenthesized_expression "(pWriter->btterm)" ( (field_expression "pWriter->btterm" identifier -> field_identifier) )) . field_identifier)) ;) }))) (expression_statement "(**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0);" (call_expression "(**(code **)(in_t9 + 0x625b4))(p->pIdxWriter,2,puVar3,iVar2,0)" (parenthesized_expression "(**(code **)(in_t9 + 0x625b4))" ( (pointer_expression "**(code **)(in_t9 + 0x625b4)" * (pointer_expression "*(code **)(in_t9 + 0x625b4)" * (cast_expression "(code **)(in_t9 + 0x625b4)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(in_t9 + 0x625b4)" ( (binary_expression "in_t9 + 0x625b4" identifier + number_literal) ))))) )) (argument_list "(p->pIdxWriter,2,puVar3,iVar2,0)" ( (field_expression "p->pIdxWriter" identifier -> field_identifier) , number_literal , identifier , identifier , number_literal ))) ;) (expression_statement "uVar1 = pWriter->iBtPage;" (assignment_expression "uVar1 = pWriter->iBtPage" identifier = (field_expression "pWriter->iBtPage" identifier -> field_identifier)) ;) (expression_statement "(**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));" (call_expression "(**(code **)(in_t9 + 0x625ac))\n              (p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" (parenthesized_expression "(**(code **)(in_t9 + 0x625ac))" ( (pointer_expression "**(code **)(in_t9 + 0x625ac)" * (pointer_expression "*(code **)(in_t9 + 0x625ac)" * (cast_expression "(code **)(in_t9 + 0x625ac)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(in_t9 + 0x625ac)" ( (binary_expression "in_t9 + 0x625ac" identifier + number_literal) ))))) )) (argument_list "(p->pIdxWriter,3,\n               (uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" ( (field_expression "p->pIdxWriter" identifier -> field_identifier) , number_literal , (binary_expression "(uint)(uVar1 * 2 + uVar5 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" (call_expression "(uint)(uVar1 * 2 + uVar5 < uVar1 * 2)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(uVar1 * 2 + uVar5 < uVar1 * 2)" ( (binary_expression "uVar1 * 2 + uVar5 < uVar1 * 2" (binary_expression "uVar1 * 2 + uVar5" (binary_expression "uVar1 * 2" identifier * number_literal) + identifier) < (binary_expression "uVar1 * 2" identifier * number_literal)) ))) + (parenthesized_expression "(uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" ( (binary_expression "uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1" (binary_expression "uVar1 >> 0x1f" identifier >> number_literal) | (binary_expression "((int)uVar1 >> 0x1f) << 1" (parenthesized_expression "((int)uVar1 >> 0x1f)" ( (binary_expression "(int)uVar1 >> 0x1f" (cast_expression "(int)uVar1" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) << number_literal)) ))) ))) ;) (expression_statement "(**(code **)(in_t9 + 0x6246c))(p->pIdxWriter);" (call_expression "(**(code **)(in_t9 + 0x6246c))(p->pIdxWriter)" (parenthesized_expression "(**(code **)(in_t9 + 0x6246c))" ( (pointer_expression "**(code **)(in_t9 + 0x6246c)" * (pointer_expression "*(code **)(in_t9 + 0x6246c)" * (cast_expression "(code **)(in_t9 + 0x6246c)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(in_t9 + 0x6246c)" ( (binary_expression "in_t9 + 0x6246c" identifier + number_literal) ))))) )) (argument_list "(p->pIdxWriter)" ( (field_expression "p->pIdxWriter" identifier -> field_identifier) ))) ;) (expression_statement "iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter);" (assignment_expression "iVar2 = (**(code **)(in_t9 + 0x62558))(p->pIdxWriter)" identifier = (call_expression "(**(code **)(in_t9 + 0x62558))(p->pIdxWriter)" (parenthesized_expression "(**(code **)(in_t9 + 0x62558))" ( (pointer_expression "**(code **)(in_t9 + 0x62558)" * (pointer_expression "*(code **)(in_t9 + 0x62558)" * (cast_expression "(code **)(in_t9 + 0x62558)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(in_t9 + 0x62558)" ( (binary_expression "in_t9 + 0x62558" identifier + number_literal) ))))) )) (argument_list "(p->pIdxWriter)" ( (field_expression "p->pIdxWriter" identifier -> field_identifier) )))) ;) (expression_statement "p->rc = iVar2;" (assignment_expression "p->rc = iVar2" (field_expression "p->rc" identifier -> field_identifier) = identifier) ;) (expression_statement "(**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2);" (call_expression "(**(code **)(in_t9 + 0x625a8))(p->pIdxWriter,2)" (parenthesized_expression "(**(code **)(in_t9 + 0x625a8))" ( (pointer_expression "**(code **)(in_t9 + 0x625a8)" * (pointer_expression "*(code **)(in_t9 + 0x625a8)" * (cast_expression "(code **)(in_t9 + 0x625a8)" ( (type_descriptor "code **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(in_t9 + 0x625a8)" ( (binary_expression "in_t9 + 0x625a8" identifier + number_literal) ))))) )) (argument_list "(p->pIdxWriter,2)" ( (field_expression "p->pIdxWriter" identifier -> field_identifier) , number_literal ))) ;) })) (expression_statement "pWriter->iBtPage = 0;" (assignment_expression "pWriter->iBtPage = 0" (field_expression "pWriter->iBtPage" identifier -> field_identifier) = number_literal) ;) (return_statement "return;" return ;) })))
(translation_unit "void FUN_0012d518(int param_1,int param_2)\n\n{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}\n\n" (function_definition "void FUN_0012d518(int param_1,int param_2)\n\n{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}" primitive_type (function_declarator "FUN_0012d518(int param_1,int param_2)" identifier (parameter_list "(int param_1,int param_2)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "int param_2" primitive_type identifier) ))) (compound_statement "{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "undefined4 uVar2;" type_identifier identifier ;) (declaration "undefined *puVar3;" type_identifier (pointer_declarator "*puVar3" * identifier) ;) (declaration "int iVar4;" primitive_type identifier ;) (declaration "int iVar5;" primitive_type identifier ;) (declaration "uint uVar6;" type_identifier identifier ;) (declaration "code *pcVar7;" type_identifier (pointer_declarator "*pcVar7" * identifier) ;) (if_statement "if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }" if (parenthesized_expression "(*(int *)(param_2 + 0x58) == 0)" ( (binary_expression "*(int *)(param_2 + 0x58) == 0" (pointer_expression "*(int *)(param_2 + 0x58)" * (cast_expression "(int *)(param_2 + 0x58)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x58)" ( (binary_expression "param_2 + 0x58" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n    return;\n  }" { (return_statement "return;" return ;) })) (expression_statement "iVar4 = *(int *)(param_2 + 0x48);" (assignment_expression "iVar4 = *(int *)(param_2 + 0x48)" identifier = (pointer_expression "*(int *)(param_2 + 0x48)" * (cast_expression "(int *)(param_2 + 0x48)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x48)" ( (binary_expression "param_2 + 0x48" identifier + number_literal) ))))) ;) (if_statement "if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" if (parenthesized_expression "(*(int *)(iVar4 + 0x14) < 1)" ( (binary_expression "*(int *)(iVar4 + 0x14) < 1" (pointer_expression "*(int *)(iVar4 + 0x14)" * (cast_expression "(int *)(iVar4 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) < number_literal) )) (compound_statement "{\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }" { (expression_statement "uVar6 = 0;" (assignment_expression "uVar6 = 0" identifier = number_literal) ;) (if_statement "if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;" if (parenthesized_expression "(*(int *)(param_2 + 0x44) < 1)" ( (binary_expression "*(int *)(param_2 + 0x44) < 1" (pointer_expression "*(int *)(param_2 + 0x44)" * (cast_expression "(int *)(param_2 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x44)" ( (binary_expression "param_2 + 0x44" identifier + number_literal) )))) < number_literal) )) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;)) (if_statement "if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }" if (parenthesized_expression "(*(int *)(iVar4 + 0x14) == 0)" ( (binary_expression "*(int *)(iVar4 + 0x14) == 0" (pointer_expression "*(int *)(iVar4 + 0x14)" * (cast_expression "(int *)(iVar4 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }" { (expression_statement "uVar6 = 0;" (assignment_expression "uVar6 = 0" identifier = number_literal) ;) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;) })) }) (else_clause "else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" else (compound_statement "{\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" { (expression_statement "uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;" (assignment_expression "uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1" identifier = (binary_expression "*(int *)(param_2 + 0x40) < 4 ^ 1" (binary_expression "*(int *)(param_2 + 0x40) < 4" (pointer_expression "*(int *)(param_2 + 0x40)" * (cast_expression "(int *)(param_2 + 0x40)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x40)" ( (binary_expression "param_2 + 0x40" identifier + number_literal) )))) < number_literal) ^ number_literal)) ;) (if_statement "if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;" if (parenthesized_expression "(*(int *)(param_2 + 0x44) < 1)" ( (binary_expression "*(int *)(param_2 + 0x44) < 1" (pointer_expression "*(int *)(param_2 + 0x44)" * (cast_expression "(int *)(param_2 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x44)" ( (binary_expression "param_2 + 0x44" identifier + number_literal) )))) < number_literal) )) (goto_statement "goto LAB_0012d680;" goto statement_identifier ;)) }))) (expression_statement "iVar5 = 0;" (assignment_expression "iVar5 = 0" identifier = number_literal) ;) (expression_statement "pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);" (assignment_expression "pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898)" identifier = (cast_expression "(code *)(PTR_LAB_0018fbe8 + -0x3898)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_0018fbe8 + -0x3898)" ( (binary_expression "PTR_LAB_0018fbe8 + -0x3898" identifier + number_literal) )))) ;) (do_statement "do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));" do (compound_statement "{\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  }" { (if_statement "if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }" if (parenthesized_expression "(uVar6 != 0)" ( (binary_expression "uVar6 != 0" identifier != number_literal) )) (compound_statement "{\n      (*pcVar7)(param_1);\n    }" { (expression_statement "(*pcVar7)(param_1);" (call_expression "(*pcVar7)(param_1)" (parenthesized_expression "(*pcVar7)" ( (pointer_expression "*pcVar7" * identifier) )) (argument_list "(param_1)" ( identifier ))) ;) })) (expression_statement "*(undefined4 *)(iVar4 + 0x14) = 0;" (assignment_expression "*(undefined4 *)(iVar4 + 0x14) = 0" (pointer_expression "*(undefined4 *)(iVar4 + 0x14)" * (cast_expression "(undefined4 *)(iVar4 + 0x14)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) = number_literal) ;) (expression_statement "*(undefined4 *)(iVar4 + 4) = 0;" (assignment_expression "*(undefined4 *)(iVar4 + 4) = 0" (pointer_expression "*(undefined4 *)(iVar4 + 4)" * (cast_expression "(undefined4 *)(iVar4 + 4)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 4)" ( (binary_expression "iVar4 + 4" identifier + number_literal) )))) = number_literal) ;) (expression_statement "iVar5 = iVar5 + 1;" (assignment_expression "iVar5 = iVar5 + 1" identifier = (binary_expression "iVar5 + 1" identifier + number_literal)) ;) }) while (parenthesized_expression "((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0))" ( (binary_expression "(iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0)" (parenthesized_expression "(iVar5 < *(int *)(param_2 + 0x44))" ( (binary_expression "iVar5 < *(int *)(param_2 + 0x44)" identifier < (pointer_expression "*(int *)(param_2 + 0x44)" * (cast_expression "(int *)(param_2 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x44)" ( (binary_expression "param_2 + 0x44" identifier + number_literal) ))))) )) && (parenthesized_expression "(iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0)" ( (comma_expression "iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0" (assignment_expression "iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20" identifier = (binary_expression "*(int *)(param_2 + 0x48) + iVar5 * 0x20" (pointer_expression "*(int *)(param_2 + 0x48)" * (cast_expression "(int *)(param_2 + 0x48)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x48)" ( (binary_expression "param_2 + 0x48" identifier + number_literal) )))) + (binary_expression "iVar5 * 0x20" identifier * number_literal))) , (binary_expression "*(int *)(iVar4 + 0x14) != 0" (pointer_expression "*(int *)(iVar4 + 0x14)" * (cast_expression "(int *)(iVar4 + 0x14)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar4 + 0x14)" ( (binary_expression "iVar4 + 0x14" identifier + number_literal) )))) != number_literal)) ))) )) ;) (labeled_statement "LAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;" statement_identifier : (expression_statement "*(undefined4 *)(param_2 + 0x40) = 0;" (assignment_expression "*(undefined4 *)(param_2 + 0x40) = 0" (pointer_expression "*(undefined4 *)(param_2 + 0x40)" * (cast_expression "(undefined4 *)(param_2 + 0x40)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x40)" ( (binary_expression "param_2 + 0x40" identifier + number_literal) )))) = number_literal) ;)) (if_statement "if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x24) == 0)" ( (binary_expression "*(int *)(param_1 + 0x24) == 0" (pointer_expression "*(int *)(param_1 + 0x24)" * (cast_expression "(int *)(param_1 + 0x24)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x24)" ( (binary_expression "param_1 + 0x24" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }" { (if_statement "if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" if (parenthesized_expression "(*(int *)(param_2 + 0x50) < 1)" ( (binary_expression "*(int *)(param_2 + 0x50) < 1" (pointer_expression "*(int *)(param_2 + 0x50)" * (cast_expression "(int *)(param_2 + 0x50)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x50)" ( (binary_expression "param_2 + 0x50" identifier + number_literal) )))) < number_literal) )) (compound_statement "{\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }" { (expression_statement "puVar3 = PTR_LAB_0018f958 + 0x2d20;" (assignment_expression "puVar3 = PTR_LAB_0018f958 + 0x2d20" identifier = (binary_expression "PTR_LAB_0018f958 + 0x2d20" identifier + number_literal)) ;) }) (else_clause "else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" else (compound_statement "{\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" { (expression_statement "puVar3 = *(undefined **)(param_2 + 0x4c);" (assignment_expression "puVar3 = *(undefined **)(param_2 + 0x4c)" identifier = (pointer_expression "*(undefined **)(param_2 + 0x4c)" * (cast_expression "(undefined **)(param_2 + 0x4c)" ( (type_descriptor "undefined **" type_identifier (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_2 + 0x4c)" ( (binary_expression "param_2 + 0x4c" identifier + number_literal) ))))) ;) }))) (expression_statement "(*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);" (call_expression "(*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0)" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_blob_0018facc)" ( (pointer_expression "*(code *)PTR_sqlite3_bind_blob_0018facc" * (cast_expression "(code *)PTR_sqlite3_bind_blob_0018facc" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0)" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) , number_literal , identifier , (pointer_expression "*(int *)(param_2 + 0x50)" * (cast_expression "(int *)(param_2 + 0x50)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x50)" ( (binary_expression "param_2 + 0x50" identifier + number_literal) )))) , number_literal ))) ;) (expression_statement "uVar1 = *(uint *)(param_2 + 0x58);" (assignment_expression "uVar1 = *(uint *)(param_2 + 0x58)" identifier = (pointer_expression "*(uint *)(param_2 + 0x58)" * (cast_expression "(uint *)(param_2 + 0x58)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x58)" ( (binary_expression "param_2 + 0x58" identifier + number_literal) ))))) ;) (expression_statement "(*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));" (call_expression "(*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_int64_0018fac4)" ( (pointer_expression "*(code *)PTR_sqlite3_bind_int64_0018fac4" * (cast_expression "(code *)PTR_sqlite3_bind_int64_0018fac4" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) , number_literal , (binary_expression "(uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" (call_expression "(uint)(uVar1 * 2 + uVar6 < uVar1 * 2)" (parenthesized_expression "(uint)" ( identifier )) (argument_list "(uVar1 * 2 + uVar6 < uVar1 * 2)" ( (binary_expression "uVar1 * 2 + uVar6 < uVar1 * 2" (binary_expression "uVar1 * 2 + uVar6" (binary_expression "uVar1 * 2" identifier * number_literal) + identifier) < (binary_expression "uVar1 * 2" identifier * number_literal)) ))) + (parenthesized_expression "(uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" ( (binary_expression "uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1" (binary_expression "uVar1 >> 0x1f" identifier >> number_literal) | (binary_expression "((int)uVar1 >> 0x1f) << 1" (parenthesized_expression "((int)uVar1 >> 0x1f)" ( (binary_expression "(int)uVar1 >> 0x1f" (cast_expression "(int)uVar1" ( (type_descriptor "int" primitive_type) ) identifier) >> number_literal) )) << number_literal)) ))) ))) ;) (expression_statement "(*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));" (call_expression "(*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34))" (parenthesized_expression "(*(code *)PTR_sqlite3_step_0018f984)" ( (pointer_expression "*(code *)PTR_sqlite3_step_0018f984" * (cast_expression "(code *)PTR_sqlite3_step_0018f984" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34))" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) ))) ;) (expression_statement "uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));" (assignment_expression "uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34))" identifier = (call_expression "(*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34))" (parenthesized_expression "(*(code *)PTR_sqlite3_reset_0018fa70)" ( (pointer_expression "*(code *)PTR_sqlite3_reset_0018fa70" * (cast_expression "(code *)PTR_sqlite3_reset_0018fa70" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34))" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) )))) ;) (expression_statement "*(undefined4 *)(param_1 + 0x24) = uVar2;" (assignment_expression "*(undefined4 *)(param_1 + 0x24) = uVar2" (pointer_expression "*(undefined4 *)(param_1 + 0x24)" * (cast_expression "(undefined4 *)(param_1 + 0x24)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x24)" ( (binary_expression "param_1 + 0x24" identifier + number_literal) )))) = identifier) ;) (expression_statement "(*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);" (call_expression "(*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2)" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_null_0018fac0)" ( (pointer_expression "*(code *)PTR_sqlite3_bind_null_0018fac0" * (cast_expression "(code *)PTR_sqlite3_bind_null_0018fac0" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(*(undefined4 *)(param_1 + 0x34),2)" ( (pointer_expression "*(undefined4 *)(param_1 + 0x34)" * (cast_expression "(undefined4 *)(param_1 + 0x34)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x34)" ( (binary_expression "param_1 + 0x34" identifier + number_literal) )))) , number_literal ))) ;) })) (expression_statement "*(undefined4 *)(param_2 + 0x58) = 0;" (assignment_expression "*(undefined4 *)(param_2 + 0x58) = 0" (pointer_expression "*(undefined4 *)(param_2 + 0x58)" * (cast_expression "(undefined4 *)(param_2 + 0x58)" ( (type_descriptor "undefined4 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_2 + 0x58)" ( (binary_expression "param_2 + 0x58" identifier + number_literal) )))) = number_literal) ;) (return_statement "return;" return ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (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 { (return_statement return ;) })) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_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 { (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) )) (goto_statement goto statement_identifier ;)) (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 { (expression_statement (assignment_expression IDENT = LIT) ;) (goto_statement goto statement_identifier ;) })) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) < LIT) ^ 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) )) (goto_statement goto statement_identifier ;)) }))) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (do_statement do (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT ))) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) while (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT < (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + (binary_expression IDENT * LIT))) , (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) != LIT)) ))) )) ;) (labeled_statement statement_identifier : (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = 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 { (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 { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) }))) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT , IDENT , (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT , (binary_expression (call_expression (parenthesized_expression ( IDENT )) (argument_list ( (binary_expression (binary_expression (binary_expression IDENT * LIT) + IDENT) < (binary_expression IDENT * LIT)) ))) + (parenthesized_expression ( (binary_expression (binary_expression IDENT >> LIT) | (binary_expression (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) IDENT) >> LIT) )) << LIT)) ))) ))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ))) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) )))) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = IDENT) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) , LIT ))) ;) })) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) = LIT) ;) (return_statement return ;) })))
(function_definition "void FUN_0012d518(int param_1,int param_2)\n\n{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}" (primitive_type "void") (function_declarator "FUN_0012d518(int param_1,int param_2)" (identifier "FUN_0012d518") (parameter_list "(int param_1,int param_2)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "int param_2" (primitive_type "int") (identifier "param_2")) () ")"))) (compound_statement "{\n  uint uVar1;\n  undefined4 uVar2;\n  undefined *puVar3;\n  int iVar4;\n  int iVar5;\n  uint uVar6;\n  code *pcVar7;\n  \n  if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }\n  iVar4 = *(int *)(param_2 + 0x48);\n  if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }\n  iVar5 = 0;\n  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);\n  do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));\nLAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;\n  if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }\n  *(undefined4 *)(param_2 + 0x58) = 0;\n  return;\n}" ({ "{") (declaration "uint uVar1;" (type_identifier "uint") (identifier "uVar1") (; ";")) (declaration "undefined4 uVar2;" (type_identifier "undefined4") (identifier "uVar2") (; ";")) (declaration "undefined *puVar3;" (type_identifier "undefined") (pointer_declarator "*puVar3" (* "*") (identifier "puVar3")) (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (declaration "int iVar5;" (primitive_type "int") (identifier "iVar5") (; ";")) (declaration "uint uVar6;" (type_identifier "uint") (identifier "uVar6") (; ";")) (declaration "code *pcVar7;" (type_identifier "code") (pointer_declarator "*pcVar7" (* "*") (identifier "pcVar7")) (; ";")) (if_statement "if (*(int *)(param_2 + 0x58) == 0) {\n    return;\n  }" (if "if") (parenthesized_expression "(*(int *)(param_2 + 0x58) == 0)" (( "(") (binary_expression "*(int *)(param_2 + 0x58) == 0" (pointer_expression "*(int *)(param_2 + 0x58)" (* "*") (cast_expression "(int *)(param_2 + 0x58)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x58)" (( "(") (binary_expression "param_2 + 0x58" (identifier "param_2") (+ "+") (number_literal "0x58")) () ")")))) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    return;\n  }" ({ "{") (return_statement "return;" (return "return") (; ";")) (} "}"))) (expression_statement "iVar4 = *(int *)(param_2 + 0x48);" (assignment_expression "iVar4 = *(int *)(param_2 + 0x48)" (identifier "iVar4") (= "=") (pointer_expression "*(int *)(param_2 + 0x48)" (* "*") (cast_expression "(int *)(param_2 + 0x48)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x48)" (( "(") (binary_expression "param_2 + 0x48" (identifier "param_2") (+ "+") (number_literal "0x48")) () ")"))))) (; ";")) (if_statement "if (*(int *)(iVar4 + 0x14) < 1) {\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }\n  else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" (if "if") (parenthesized_expression "(*(int *)(iVar4 + 0x14) < 1)" (( "(") (binary_expression "*(int *)(iVar4 + 0x14) < 1" (pointer_expression "*(int *)(iVar4 + 0x14)" (* "*") (cast_expression "(int *)(iVar4 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x14)" (( "(") (binary_expression "iVar4 + 0x14" (identifier "iVar4") (+ "+") (number_literal "0x14")) () ")")))) (< "<") (number_literal "1")) () ")")) (compound_statement "{\n    uVar6 = 0;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n    if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }\n  }" ({ "{") (expression_statement "uVar6 = 0;" (assignment_expression "uVar6 = 0" (identifier "uVar6") (= "=") (number_literal "0")) (; ";")) (if_statement "if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;" (if "if") (parenthesized_expression "(*(int *)(param_2 + 0x44) < 1)" (( "(") (binary_expression "*(int *)(param_2 + 0x44) < 1" (pointer_expression "*(int *)(param_2 + 0x44)" (* "*") (cast_expression "(int *)(param_2 + 0x44)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x44)" (( "(") (binary_expression "param_2 + 0x44" (identifier "param_2") (+ "+") (number_literal "0x44")) () ")")))) (< "<") (number_literal "1")) () ")")) (goto_statement "goto LAB_0012d680;" (goto "goto") (statement_identifier "LAB_0012d680") (; ";"))) (if_statement "if (*(int *)(iVar4 + 0x14) == 0) {\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }" (if "if") (parenthesized_expression "(*(int *)(iVar4 + 0x14) == 0)" (( "(") (binary_expression "*(int *)(iVar4 + 0x14) == 0" (pointer_expression "*(int *)(iVar4 + 0x14)" (* "*") (cast_expression "(int *)(iVar4 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x14)" (( "(") (binary_expression "iVar4 + 0x14" (identifier "iVar4") (+ "+") (number_literal "0x14")) () ")")))) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      uVar6 = 0;\n      goto LAB_0012d680;\n    }" ({ "{") (expression_statement "uVar6 = 0;" (assignment_expression "uVar6 = 0" (identifier "uVar6") (= "=") (number_literal "0")) (; ";")) (goto_statement "goto LAB_0012d680;" (goto "goto") (statement_identifier "LAB_0012d680") (; ";")) (} "}"))) (} "}")) (else_clause "else {\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" (else "else") (compound_statement "{\n    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;\n    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;\n  }" ({ "{") (expression_statement "uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;" (assignment_expression "uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1" (identifier "uVar6") (= "=") (binary_expression "*(int *)(param_2 + 0x40) < 4 ^ 1" (binary_expression "*(int *)(param_2 + 0x40) < 4" (pointer_expression "*(int *)(param_2 + 0x40)" (* "*") (cast_expression "(int *)(param_2 + 0x40)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x40)" (( "(") (binary_expression "param_2 + 0x40" (identifier "param_2") (+ "+") (number_literal "0x40")) () ")")))) (< "<") (number_literal "4")) (^ "^") (number_literal "1"))) (; ";")) (if_statement "if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;" (if "if") (parenthesized_expression "(*(int *)(param_2 + 0x44) < 1)" (( "(") (binary_expression "*(int *)(param_2 + 0x44) < 1" (pointer_expression "*(int *)(param_2 + 0x44)" (* "*") (cast_expression "(int *)(param_2 + 0x44)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x44)" (( "(") (binary_expression "param_2 + 0x44" (identifier "param_2") (+ "+") (number_literal "0x44")) () ")")))) (< "<") (number_literal "1")) () ")")) (goto_statement "goto LAB_0012d680;" (goto "goto") (statement_identifier "LAB_0012d680") (; ";"))) (} "}")))) (expression_statement "iVar5 = 0;" (assignment_expression "iVar5 = 0" (identifier "iVar5") (= "=") (number_literal "0")) (; ";")) (expression_statement "pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);" (assignment_expression "pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898)" (identifier "pcVar7") (= "=") (cast_expression "(code *)(PTR_LAB_0018fbe8 + -0x3898)" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(PTR_LAB_0018fbe8 + -0x3898)" (( "(") (binary_expression "PTR_LAB_0018fbe8 + -0x3898" (identifier "PTR_LAB_0018fbe8") (+ "+") (number_literal "-0x3898")) () ")")))) (; ";")) (do_statement "do {\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));" (do "do") (compound_statement "{\n    if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }\n    *(undefined4 *)(iVar4 + 0x14) = 0;\n    *(undefined4 *)(iVar4 + 4) = 0;\n    iVar5 = iVar5 + 1;\n  }" ({ "{") (if_statement "if (uVar6 != 0) {\n      (*pcVar7)(param_1);\n    }" (if "if") (parenthesized_expression "(uVar6 != 0)" (( "(") (binary_expression "uVar6 != 0" (identifier "uVar6") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      (*pcVar7)(param_1);\n    }" ({ "{") (expression_statement "(*pcVar7)(param_1);" (call_expression "(*pcVar7)(param_1)" (parenthesized_expression "(*pcVar7)" (( "(") (pointer_expression "*pcVar7" (* "*") (identifier "pcVar7")) () ")")) (argument_list "(param_1)" (( "(") (identifier "param_1") () ")"))) (; ";")) (} "}"))) (expression_statement "*(undefined4 *)(iVar4 + 0x14) = 0;" (assignment_expression "*(undefined4 *)(iVar4 + 0x14) = 0" (pointer_expression "*(undefined4 *)(iVar4 + 0x14)" (* "*") (cast_expression "(undefined4 *)(iVar4 + 0x14)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x14)" (( "(") (binary_expression "iVar4 + 0x14" (identifier "iVar4") (+ "+") (number_literal "0x14")) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "*(undefined4 *)(iVar4 + 4) = 0;" (assignment_expression "*(undefined4 *)(iVar4 + 4) = 0" (pointer_expression "*(undefined4 *)(iVar4 + 4)" (* "*") (cast_expression "(undefined4 *)(iVar4 + 4)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 4)" (( "(") (binary_expression "iVar4 + 4" (identifier "iVar4") (+ "+") (number_literal "4")) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "iVar5 = iVar5 + 1;" (assignment_expression "iVar5 = iVar5 + 1" (identifier "iVar5") (= "=") (binary_expression "iVar5 + 1" (identifier "iVar5") (+ "+") (number_literal "1"))) (; ";")) (} "}")) (while "while") (parenthesized_expression "((iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0))" (( "(") (binary_expression "(iVar5 < *(int *)(param_2 + 0x44)) &&\n          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0)" (parenthesized_expression "(iVar5 < *(int *)(param_2 + 0x44))" (( "(") (binary_expression "iVar5 < *(int *)(param_2 + 0x44)" (identifier "iVar5") (< "<") (pointer_expression "*(int *)(param_2 + 0x44)" (* "*") (cast_expression "(int *)(param_2 + 0x44)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x44)" (( "(") (binary_expression "param_2 + 0x44" (identifier "param_2") (+ "+") (number_literal "0x44")) () ")"))))) () ")")) (&& "&&") (parenthesized_expression "(iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0)" (( "(") (comma_expression "iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0" (assignment_expression "iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20" (identifier "iVar4") (= "=") (binary_expression "*(int *)(param_2 + 0x48) + iVar5 * 0x20" (pointer_expression "*(int *)(param_2 + 0x48)" (* "*") (cast_expression "(int *)(param_2 + 0x48)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x48)" (( "(") (binary_expression "param_2 + 0x48" (identifier "param_2") (+ "+") (number_literal "0x48")) () ")")))) (+ "+") (binary_expression "iVar5 * 0x20" (identifier "iVar5") (* "*") (number_literal "0x20")))) (, ",") (binary_expression "*(int *)(iVar4 + 0x14) != 0" (pointer_expression "*(int *)(iVar4 + 0x14)" (* "*") (cast_expression "(int *)(iVar4 + 0x14)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar4 + 0x14)" (( "(") (binary_expression "iVar4 + 0x14" (identifier "iVar4") (+ "+") (number_literal "0x14")) () ")")))) (!= "!=") (number_literal "0"))) () ")"))) () ")")) (; ";")) (labeled_statement "LAB_0012d680:\n  *(undefined4 *)(param_2 + 0x40) = 0;" (statement_identifier "LAB_0012d680") (: ":") (expression_statement "*(undefined4 *)(param_2 + 0x40) = 0;" (assignment_expression "*(undefined4 *)(param_2 + 0x40) = 0" (pointer_expression "*(undefined4 *)(param_2 + 0x40)" (* "*") (cast_expression "(undefined4 *)(param_2 + 0x40)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x40)" (( "(") (binary_expression "param_2 + 0x40" (identifier "param_2") (+ "+") (number_literal "0x40")) () ")")))) (= "=") (number_literal "0")) (; ";"))) (if_statement "if (*(int *)(param_1 + 0x24) == 0) {\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0x24) == 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x24) == 0" (pointer_expression "*(int *)(param_1 + 0x24)" (* "*") (cast_expression "(int *)(param_1 + 0x24)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x24)" (( "(") (binary_expression "param_1 + 0x24" (identifier "param_1") (+ "+") (number_literal "0x24")) () ")")))) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }\n    (*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);\n    uVar1 = *(uint *)(param_2 + 0x58);\n    (*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));\n    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));\n    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));\n    *(undefined4 *)(param_1 + 0x24) = uVar2;\n    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);\n  }" ({ "{") (if_statement "if (*(int *)(param_2 + 0x50) < 1) {\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }\n    else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" (if "if") (parenthesized_expression "(*(int *)(param_2 + 0x50) < 1)" (( "(") (binary_expression "*(int *)(param_2 + 0x50) < 1" (pointer_expression "*(int *)(param_2 + 0x50)" (* "*") (cast_expression "(int *)(param_2 + 0x50)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x50)" (( "(") (binary_expression "param_2 + 0x50" (identifier "param_2") (+ "+") (number_literal "0x50")) () ")")))) (< "<") (number_literal "1")) () ")")) (compound_statement "{\n      puVar3 = PTR_LAB_0018f958 + 0x2d20;\n    }" ({ "{") (expression_statement "puVar3 = PTR_LAB_0018f958 + 0x2d20;" (assignment_expression "puVar3 = PTR_LAB_0018f958 + 0x2d20" (identifier "puVar3") (= "=") (binary_expression "PTR_LAB_0018f958 + 0x2d20" (identifier "PTR_LAB_0018f958") (+ "+") (number_literal "0x2d20"))) (; ";")) (} "}")) (else_clause "else {\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" (else "else") (compound_statement "{\n      puVar3 = *(undefined **)(param_2 + 0x4c);\n    }" ({ "{") (expression_statement "puVar3 = *(undefined **)(param_2 + 0x4c);" (assignment_expression "puVar3 = *(undefined **)(param_2 + 0x4c)" (identifier "puVar3") (= "=") (pointer_expression "*(undefined **)(param_2 + 0x4c)" (* "*") (cast_expression "(undefined **)(param_2 + 0x4c)" (( "(") (type_descriptor "undefined **" (type_identifier "undefined") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_2 + 0x4c)" (( "(") (binary_expression "param_2 + 0x4c" (identifier "param_2") (+ "+") (number_literal "0x4c")) () ")"))))) (; ";")) (} "}")))) (expression_statement "(*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);" (call_expression "(*(code *)PTR_sqlite3_bind_blob_0018facc)\n              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0)" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_blob_0018facc)" (( "(") (pointer_expression "*(code *)PTR_sqlite3_bind_blob_0018facc" (* "*") (cast_expression "(code *)PTR_sqlite3_bind_blob_0018facc" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_sqlite3_bind_blob_0018facc"))) () ")")) (argument_list "(*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0)" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0x34)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x34)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x34)" (( "(") (binary_expression "param_1 + 0x34" (identifier "param_1") (+ "+") (number_literal "0x34")) () ")")))) (, ",") (number_literal "2") (, ",") (identifier "puVar3") (, ",") (pointer_expression "*(int *)(param_2 + 0x50)" (* "*") (cast_expression "(int *)(param_2 + 0x50)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x50)" (( "(") (binary_expression "param_2 + 0x50" (identifier "param_2") (+ "+") (number_literal "0x50")) () ")")))) (, ",") (number_literal "0") () ")"))) (; ";")) (expression_statement "uVar1 = *(uint *)(param_2 + 0x58);" (assignment_expression "uVar1 = *(uint *)(param_2 + 0x58)" (identifier "uVar1") (= "=") (pointer_expression "*(uint *)(param_2 + 0x58)" (* "*") (cast_expression "(uint *)(param_2 + 0x58)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x58)" (( "(") (binary_expression "param_2 + 0x58" (identifier "param_2") (+ "+") (number_literal "0x58")) () ")"))))) (; ";")) (expression_statement "(*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));" (call_expression "(*(code *)PTR_sqlite3_bind_int64_0018fac4)\n              (*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_int64_0018fac4)" (( "(") (pointer_expression "*(code *)PTR_sqlite3_bind_int64_0018fac4" (* "*") (cast_expression "(code *)PTR_sqlite3_bind_int64_0018fac4" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_sqlite3_bind_int64_0018fac4"))) () ")")) (argument_list "(*(undefined4 *)(param_1 + 0x34),3,\n               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0x34)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x34)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x34)" (( "(") (binary_expression "param_1 + 0x34" (identifier "param_1") (+ "+") (number_literal "0x34")) () ")")))) (, ",") (number_literal "3") (, ",") (binary_expression "(uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" (call_expression "(uint)(uVar1 * 2 + uVar6 < uVar1 * 2)" (parenthesized_expression "(uint)" (( "(") (identifier "uint") () ")")) (argument_list "(uVar1 * 2 + uVar6 < uVar1 * 2)" (( "(") (binary_expression "uVar1 * 2 + uVar6 < uVar1 * 2" (binary_expression "uVar1 * 2 + uVar6" (binary_expression "uVar1 * 2" (identifier "uVar1") (* "*") (number_literal "2")) (+ "+") (identifier "uVar6")) (< "<") (binary_expression "uVar1 * 2" (identifier "uVar1") (* "*") (number_literal "2"))) () ")"))) (+ "+") (parenthesized_expression "(uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1)" (( "(") (binary_expression "uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1" (binary_expression "uVar1 >> 0x1f" (identifier "uVar1") (>> ">>") (number_literal "0x1f")) (| "|") (binary_expression "((int)uVar1 >> 0x1f) << 1" (parenthesized_expression "((int)uVar1 >> 0x1f)" (( "(") (binary_expression "(int)uVar1 >> 0x1f" (cast_expression "(int)uVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "uVar1")) (>> ">>") (number_literal "0x1f")) () ")")) (<< "<<") (number_literal "1"))) () ")"))) () ")"))) (; ";")) (expression_statement "(*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));" (call_expression "(*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34))" (parenthesized_expression "(*(code *)PTR_sqlite3_step_0018f984)" (( "(") (pointer_expression "*(code *)PTR_sqlite3_step_0018f984" (* "*") (cast_expression "(code *)PTR_sqlite3_step_0018f984" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_sqlite3_step_0018f984"))) () ")")) (argument_list "(*(undefined4 *)(param_1 + 0x34))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0x34)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x34)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x34)" (( "(") (binary_expression "param_1 + 0x34" (identifier "param_1") (+ "+") (number_literal "0x34")) () ")")))) () ")"))) (; ";")) (expression_statement "uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));" (assignment_expression "uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34))" (identifier "uVar2") (= "=") (call_expression "(*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34))" (parenthesized_expression "(*(code *)PTR_sqlite3_reset_0018fa70)" (( "(") (pointer_expression "*(code *)PTR_sqlite3_reset_0018fa70" (* "*") (cast_expression "(code *)PTR_sqlite3_reset_0018fa70" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_sqlite3_reset_0018fa70"))) () ")")) (argument_list "(*(undefined4 *)(param_1 + 0x34))" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0x34)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x34)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x34)" (( "(") (binary_expression "param_1 + 0x34" (identifier "param_1") (+ "+") (number_literal "0x34")) () ")")))) () ")")))) (; ";")) (expression_statement "*(undefined4 *)(param_1 + 0x24) = uVar2;" (assignment_expression "*(undefined4 *)(param_1 + 0x24) = uVar2" (pointer_expression "*(undefined4 *)(param_1 + 0x24)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x24)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x24)" (( "(") (binary_expression "param_1 + 0x24" (identifier "param_1") (+ "+") (number_literal "0x24")) () ")")))) (= "=") (identifier "uVar2")) (; ";")) (expression_statement "(*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);" (call_expression "(*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2)" (parenthesized_expression "(*(code *)PTR_sqlite3_bind_null_0018fac0)" (( "(") (pointer_expression "*(code *)PTR_sqlite3_bind_null_0018fac0" (* "*") (cast_expression "(code *)PTR_sqlite3_bind_null_0018fac0" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_sqlite3_bind_null_0018fac0"))) () ")")) (argument_list "(*(undefined4 *)(param_1 + 0x34),2)" (( "(") (pointer_expression "*(undefined4 *)(param_1 + 0x34)" (* "*") (cast_expression "(undefined4 *)(param_1 + 0x34)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x34)" (( "(") (binary_expression "param_1 + 0x34" (identifier "param_1") (+ "+") (number_literal "0x34")) () ")")))) (, ",") (number_literal "2") () ")"))) (; ";")) (} "}"))) (expression_statement "*(undefined4 *)(param_2 + 0x58) = 0;" (assignment_expression "*(undefined4 *)(param_2 + 0x58) = 0" (pointer_expression "*(undefined4 *)(param_2 + 0x58)" (* "*") (cast_expression "(undefined4 *)(param_2 + 0x58)" (( "(") (type_descriptor "undefined4 *" (type_identifier "undefined4") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_2 + 0x58)" (( "(") (binary_expression "param_2 + 0x58" (identifier "param_2") (+ "+") (number_literal "0x58")) () ")")))) (= "=") (number_literal "0")) (; ";")) (return_statement "return;" (return "return") (; ";")) (} "}")))

void function_1(type_1 *p,type_2 *pWriter)

{
  type_3 var_5;
  int var_1;
  type_4 *puVar3;
  type_5 *pFVar4;
  type_3 var_3;
  int var_4;
  int var_2;
  
  if (pWriter->iBtPage == 0) {
    return;
  }
  pFVar4 = pWriter->aDlidx;
  var_1 = (pFVar4->buf).n;
  if (var_1 < 1) {
    var_3 = 0;
    if (pWriter->nDlidx < 1) goto LAB_0012d680;
    if (var_1 == 0) {
      var_3 = 0;
      goto LAB_0012d680;
    }
  }
  else {
    var_3 = pWriter->nEmpty < 4 ^ 1;
    if (pWriter->nDlidx < 1) goto LAB_0012d680;
  }
  var_1 = 0;
  var_4 = *(int *)(var_2 + 0x626d0);
  do {
    if (var_3 != 0) {
      (*(type_6 *)(var_4 + -0x3898))(p);
    }
    (pFVar4->buf).n = 0;
    pFVar4->bPrevValid = 0;
    var_1 = var_1 + 1;
  } while ((var_1 < pWriter->nDlidx) && (pFVar4 = pWriter->aDlidx + var_1, (pFVar4->buf).n != 0));
LAB_0012d680:
  pWriter->nEmpty = 0;
  if (p->rc == 0) {
    var_1 = (pWriter->btterm).n;
    if (var_1 < 1) {
      puVar3 = (type_4 *)(*(int *)(var_2 + 0x62440) + 0x2d20);
    }
    else {
      puVar3 = (pWriter->btterm).p;
    }
    (**(type_6 **)(var_2 + 0x625b4))(p->pIdxWriter,2,puVar3,var_1,0);
    var_5 = pWriter->iBtPage;
    (**(type_6 **)(var_2 + 0x625ac))
              (p->pIdxWriter,3,
               (type_3)(var_5 * 2 + var_3 < var_5 * 2) + (var_5 >> 0x1f | ((int)var_5 >> 0x1f) << 1));
    (**(type_6 **)(var_2 + 0x6246c))(p->pIdxWriter);
    var_1 = (**(type_6 **)(var_2 + 0x62558))(p->pIdxWriter);
    p->rc = var_1;
    (**(type_6 **)(var_2 + 0x625a8))(p->pIdxWriter,2);
  }
  pWriter->iBtPage = 0;
  return;
}


(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (primitive_type) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (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 (return_statement))) (expression_statement (assignment_expression left: (identifier) right: (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))))))) (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 (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: (goto_statement label: (statement_identifier))) (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 (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (goto_statement label: (statement_identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (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)) 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: (goto_statement label: (statement_identifier)))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (do_statement body: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (parenthesized_expression (pointer_expression argument: (identifier))) arguments: (argument_list (identifier)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))) condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (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: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (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: (binary_expression left: (identifier) right: (number_literal)))) right: (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))))))) (labeled_statement label: (statement_identifier) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal)))) (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 (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 (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))))))) (expression_statement (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (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))))) (number_literal) (identifier) (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))))) (number_literal)))) (expression_statement (assignment_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 (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (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))))) (number_literal) (binary_expression left: (call_expression function: (parenthesized_expression (identifier)) arguments: (argument_list (binary_expression left: (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (identifier)) right: (binary_expression left: (identifier) right: (number_literal))))) right: (parenthesized_expression (binary_expression left: (binary_expression left: (identifier) right: (number_literal)) right: (binary_expression left: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)) right: (number_literal))) right: (number_literal)))))))) (expression_statement (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (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: (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (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: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (identifier))) (expression_statement (call_expression function: (parenthesized_expression (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list (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))))) (number_literal)))))) (expression_statement (assignment_expression left: (pointer_expression argument: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))))) right: (number_literal))) (return_statement))))

void MASKED(int param_1,int param_2)

{
  uint uVar1;
  undefined4 uVar2;
  undefined *puVar3;
  int iVar4;
  int iVar5;
  uint uVar6;
  code *pcVar7;
  
  if (*(int *)(param_2 + 0x58) == 0) {
    return;
  }
  iVar4 = *(int *)(param_2 + 0x48);
  if (*(int *)(iVar4 + 0x14) < 1) {
    uVar6 = 0;
    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;
    if (*(int *)(iVar4 + 0x14) == 0) {
      uVar6 = 0;
      goto LAB_0012d680;
    }
  }
  else {
    uVar6 = *(int *)(param_2 + 0x40) < 4 ^ 1;
    if (*(int *)(param_2 + 0x44) < 1) goto LAB_0012d680;
  }
  iVar5 = 0;
  pcVar7 = (code *)(PTR_LAB_0018fbe8 + -0x3898);
  do {
    if (uVar6 != 0) {
      (*pcVar7)(param_1);
    }
    *(undefined4 *)(iVar4 + 0x14) = 0;
    *(undefined4 *)(iVar4 + 4) = 0;
    iVar5 = iVar5 + 1;
  } while ((iVar5 < *(int *)(param_2 + 0x44)) &&
          (iVar4 = *(int *)(param_2 + 0x48) + iVar5 * 0x20, *(int *)(iVar4 + 0x14) != 0));
LAB_0012d680:
  *(undefined4 *)(param_2 + 0x40) = 0;
  if (*(int *)(param_1 + 0x24) == 0) {
    if (*(int *)(param_2 + 0x50) < 1) {
      puVar3 = PTR_LAB_0018f958 + 0x2d20;
    }
    else {
      puVar3 = *(undefined **)(param_2 + 0x4c);
    }
    (*(code *)PTR_sqlite3_bind_blob_0018facc)
              (*(undefined4 *)(param_1 + 0x34),2,puVar3,*(int *)(param_2 + 0x50),0);
    uVar1 = *(uint *)(param_2 + 0x58);
    (*(code *)PTR_sqlite3_bind_int64_0018fac4)
              (*(undefined4 *)(param_1 + 0x34),3,
               (uint)(uVar1 * 2 + uVar6 < uVar1 * 2) + (uVar1 >> 0x1f | ((int)uVar1 >> 0x1f) << 1));
    (*(code *)PTR_sqlite3_step_0018f984)(*(undefined4 *)(param_1 + 0x34));
    uVar2 = (*(code *)PTR_sqlite3_reset_0018fa70)(*(undefined4 *)(param_1 + 0x34));
    *(undefined4 *)(param_1 + 0x24) = uVar2;
    (*(code *)PTR_sqlite3_bind_null_0018fac0)(*(undefined4 *)(param_1 + 0x34),2);
  }
  *(undefined4 *)(param_2 + 0x58) = 0;
  return;
}

