
int demangle_qualified(work_stuff *work,char **mangled,string *result,int isfuncname,int append)

{
  int index;
  char *pcVar1;
  int iVar2;
  code *pcVar3;
  code *pcVar4;
  char cVar5;
  char *pcVar6;
  int options;
  int iVar7;
  int iVar8;
  uint local_resc;
  string last_name;
  string temp;
  char num [2];
  
  index = register_Btype(work);
  local_resc = isfuncname;
  if ((isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0)) {
    local_resc = work->destructor & 1;
  }
  pcVar1 = *mangled;
  temp.e = (char *)0x0;
  temp.p = (char *)0x0;
  temp.b = (char *)0x0;
  last_name.e = (char *)0x0;
  last_name.p = (char *)0x0;
  last_name.b = (char *)0x0;
  if (*pcVar1 == 'K') {
    *mangled = pcVar1 + 1;
    iVar8 = consume_count_with_underscores(mangled);
    if (iVar8 == -1) {
      return 0;
    }
    if (work->numk <= iVar8) {
      return 0;
    }
    pcVar1 = work->ktypevec[iVar8];
    iVar8 = 1;
    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {
      iVar8 = 1;
      string_append(&temp,pcVar1);
    }
  }
  else {
    cVar5 = pcVar1[1];
    if (cVar5 < '1') {
      return 0;
    }
    if (cVar5 < ':') {
      num[1] = '\0';
      num[0] = cVar5;
      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);
      pcVar1 = *mangled;
      if (pcVar1[2] == '_') {
        *mangled = pcVar1 + 3;
      }
      else {
        *mangled = pcVar1 + 2;
      }
    }
    else {
      if (cVar5 != '_') {
        return 0;
      }
      *mangled = pcVar1 + 1;
      iVar2 = consume_count_with_underscores(mangled);
      if (iVar2 == -1) {
        return 0;
      }
    }
    iVar8 = 1;
    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);
    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);
    for (; 0 < iVar2; iVar2 = iVar2 + -1) {
      pcVar6 = *mangled;
      last_name.p = last_name.b;
      cVar5 = *pcVar6;
      pcVar1 = pcVar6;
      if (cVar5 == '_') {
        pcVar1 = pcVar6 + 1;
        *mangled = pcVar1;
        cVar5 = pcVar6[1];
      }
      if (cVar5 == 't') {
        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);
        if (iVar8 != 0) goto LAB_003174e0;
LAB_003176e8:
        iVar8 = 0;
        break;
      }
      if (cVar5 == 'K') {
        *mangled = pcVar1 + 1;
        iVar7 = consume_count_with_underscores(mangled);
        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;
        pcVar1 = work->ktypevec[iVar7];
        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {
          string_append(&temp,pcVar1);
        }
      }
      else {
        if ((work->options & 0x2000U) == 0) {
          if (last_name.b != (char *)0x0) {
            (*(code *)PTR_free_004c5c18)();
            last_name.p = (char *)0x0;
            last_name.e = (char *)0x0;
          }
          last_name.b = last_name.p;
          iVar8 = (*pcVar3)(work,mangled,&last_name);
          if (iVar8 == 0) goto LAB_003176e8;
          string_appends(&temp,&last_name,(string *)last_name.p);
        }
        else {
          iVar7 = (*pcVar4)(mangled);
          if (iVar7 == -1) goto LAB_003176e8;
          pcVar1 = (char *)xmalloc(iVar7 + 1);
          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);
          options = work->options;
          pcVar1[iVar7] = '\0';
          pcVar6 = cplus_demangle(pcVar1,options);
          if (pcVar6 == (char *)0x0) {
            pcVar6 = *mangled;
            if (iVar7 != 0) {
              string_appendn(&temp,pcVar6,iVar7);
              pcVar6 = *mangled;
            }
          }
          else {
            if (*pcVar6 != '\0') {
              string_append(&temp,pcVar6);
            }
            (*(code *)PTR_free_004c5c18)(pcVar6);
            pcVar6 = *mangled;
          }
          (*(code *)PTR_free_004c5c18)(pcVar1);
          *mangled = pcVar6 + iVar7;
        }
LAB_003174e0:
        if (temp.b == temp.p) {
          iVar7 = 0;
        }
        else {
          iVar7 = (int)temp.p - (int)temp.b;
        }
        remember_Ktype(work,temp.b,iVar7);
      }
      if (iVar2 != 1) {
        if ((work->options & 4U) == 0) {
          pcVar1 = PTR_s__s_004c1a50 + 0x208;
        }
        else {
          pcVar1 = PTR_UINT_004c12dc + -0x5450;
        }
        string_append(&temp,pcVar1);
      }
    }
  }
  if (temp.b == temp.p) {
    iVar2 = 0;
  }
  else {
    iVar2 = (int)temp.p - (int)temp.b;
  }
  remember_Btype((work_stuff *)&work->btypevec,temp.b,iVar2,index);
  if (local_resc != 0) {
    if ((work->options & 4U) == 0) {
      pcVar1 = PTR_s__s_004c1a50 + 0x208;
    }
    else {
      pcVar1 = PTR_UINT_004c12dc + -0x5450;
    }
    string_append(&temp,pcVar1);
    if ((work->destructor & 1U) != 0) {
      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);
    }
    string_appends(&temp,&last_name,(string *)last_name.p);
  }
  if (append == 0) {
    if (result->b != result->p) {
      if ((work->options & 4U) == 0) {
        pcVar1 = PTR_s__s_004c1a50 + 0x208;
      }
      else {
        pcVar1 = PTR_UINT_004c12dc + -0x5450;
      }
      string_append(&temp,pcVar1);
    }
    if (temp.b != temp.p) {
      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);
    }
  }
  else {
    string_appends(result,&temp,(string *)temp.p);
  }
  if (last_name.b != (char *)0x0) {
    (*(code *)PTR_free_004c5c18)();
    last_name.p = (char *)0x0;
    last_name.e = (char *)0x0;
    last_name.b = (char *)0x0;
  }
  if (temp.b != (char *)0x0) {
    (*(code *)PTR_free_004c5c18)();
    return iVar8;
  }
  return iVar8;
}



int FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)

{
  char *pcVar1;
  int iVar2;
  char cVar4;
  int iVar3;
  char *pcVar5;
  undefined *puVar6;
  uint uVar7;
  int iVar8;
  int iVar9;
  int iVar10;
  uint local_resc;
  int local_60;
  int local_5c;
  undefined4 local_58;
  int local_54;
  int local_50;
  undefined4 local_4c;
  char local_48 [8];
  code *local_40;
  code *local_3c;
  char *local_38;
  undefined4 local_34;
  undefined *local_30;
  
  local_34 = FUN_00311bac();
  local_resc = param_4;
  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {
    local_resc = param_1[0xb] & 1;
  }
  pcVar1 = (char *)*param_2;
  local_4c = 0;
  local_50 = 0;
  local_54 = 0;
  local_58 = 0;
  local_5c = 0;
  local_60 = 0;
  if (*pcVar1 == 'K') {
    *param_2 = (int)(pcVar1 + 1);
    iVar9 = FUN_00312010(param_2);
    if (iVar9 == -1) {
      return 0;
    }
    if ((int)param_1[4] <= iVar9) {
      return 0;
    }
    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);
    iVar9 = 1;
    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {
      iVar9 = 1;
      FUN_00312594(&local_54);
    }
  }
  else {
    cVar4 = pcVar1[1];
    if (cVar4 < '1') {
      return 0;
    }
    if (cVar4 < ':') {
      local_48[1] = 0;
      local_48[0] = cVar4;
      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);
      iVar9 = *param_2;
      if (*(char *)(iVar9 + 2) == '_') {
        *param_2 = iVar9 + 3;
      }
      else {
        *param_2 = iVar9 + 2;
      }
    }
    else {
      if (cVar4 != '_') {
        return 0;
      }
      *param_2 = (int)(pcVar1 + 1);
      iVar2 = FUN_00312010(param_2);
      if (iVar2 == -1) {
        return 0;
      }
    }
    iVar9 = 1;
    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);
    local_30 = PTR_LAB_004c4fd8;
    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);
    for (; 0 < iVar2; iVar2 = iVar2 + -1) {
      pcVar5 = (char *)*param_2;
      local_5c = local_60;
      cVar4 = *pcVar5;
      pcVar1 = pcVar5;
      if (cVar4 == '_') {
        pcVar1 = pcVar5 + 1;
        *param_2 = (int)pcVar1;
        cVar4 = pcVar5[1];
      }
      if (cVar4 == 't') {
        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);
        if (iVar9 != 0) goto LAB_003174e0;
LAB_003176e8:
        iVar9 = 0;
        break;
      }
      if (cVar4 == 'K') {
        *param_2 = (int)(pcVar1 + 1);
        iVar8 = FUN_00312010(param_2);
        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;
        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);
        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {
          FUN_00312594(&local_54);
        }
      }
      else {
        if ((*param_1 & 0x2000) == 0) {
          if (local_60 != 0) {
            (*(code *)PTR_free_004c5c18)();
            local_5c = 0;
            local_58 = 0;
          }
          local_60 = local_5c;
          iVar9 = (*local_40)(param_1,param_2,&local_60);
          if (iVar9 == 0) goto LAB_003176e8;
          FUN_003127e8(&local_54,&local_60,local_5c);
        }
        else {
          iVar8 = (*local_3c)(param_2);
          if (iVar8 == -1) goto LAB_003176e8;
          iVar3 = xmalloc(iVar8 + 1);
          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);
          uVar7 = *param_1;
          *(undefined1 *)(iVar3 + iVar8) = 0;
          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);
          if (pcVar1 == (char *)0x0) {
            iVar10 = *param_2;
            if (iVar8 != 0) {
              FUN_003123f4(&local_54,iVar10,iVar8);
              iVar10 = *param_2;
            }
          }
          else {
            if (*pcVar1 != '\0') {
              local_38 = pcVar1;
              FUN_00312594(&local_54,pcVar1);
              pcVar1 = local_38;
            }
            (*(code *)PTR_free_004c5c18)(pcVar1);
            iVar10 = *param_2;
          }
          (*(code *)PTR_free_004c5c18)(iVar3);
          *param_2 = iVar10 + iVar8;
        }
LAB_003174e0:
        if (local_54 == local_50) {
          iVar8 = 0;
        }
        else {
          iVar8 = local_50 - local_54;
        }
        FUN_00311cb4(param_1,local_54,iVar8);
      }
      if (iVar2 != 1) {
        if ((*param_1 & 4) == 0) {
          puVar6 = PTR_s__s_004c1a50 + 0x208;
        }
        else {
          puVar6 = PTR_UINT_004c12dc + -0x5450;
        }
        FUN_00312594(&local_54,puVar6);
      }
    }
  }
  if (local_54 == local_50) {
    iVar2 = 0;
  }
  else {
    iVar2 = local_50 - local_54;
  }
  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);
  if (local_resc != 0) {
    if ((*param_1 & 4) == 0) {
      puVar6 = PTR_s__s_004c1a50 + 0x208;
    }
    else {
      puVar6 = PTR_UINT_004c12dc + -0x5450;
    }
    FUN_00312594(&local_54,puVar6);
    if ((param_1[0xb] & 1) != 0) {
      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);
    }
    FUN_003127e8(&local_54,&local_60,local_5c);
  }
  if (param_5 == 0) {
    if (*param_3 != param_3[1]) {
      if ((*param_1 & 4) == 0) {
        puVar6 = PTR_s__s_004c1a50 + 0x208;
      }
      else {
        puVar6 = PTR_UINT_004c12dc + -0x5450;
      }
      FUN_00312594(&local_54,puVar6);
    }
    if (local_54 != local_50) {
      FUN_00312470(param_3,local_54,local_50 - local_54);
    }
  }
  else {
    FUN_003127e8(param_3,&local_54,local_50);
  }
  if (local_60 != 0) {
    (*(code *)PTR_free_004c5c18)();
    local_5c = 0;
    local_58 = 0;
    local_60 = 0;
  }
  if (local_54 != 0) {
    (*(code *)PTR_free_004c5c18)();
    return iVar9;
  }
  return iVar9;
}


lui gp,0x1b
addiu gp,gp,0x1f20
addu gp,gp,t9
lw t9,-0x4268(gp)
addiu sp,sp,-0x80
addiu t9,t9,0x1bac
sw gp,0x18(sp)
sw s1,0x5c(sp)
or s1,a1,zero
sw s0,0x58(sp)
or s0,a0,zero
sw ra,0x7c(sp)
sw s8,0x78(sp)
sw s7,0x74(sp)
sw s6,0x70(sp)
sw s5,0x6c(sp)
sw s4,0x68(sp)
sw s3,0x64(sp)
sw s2,0x60(sp)
sw a2,0x88(sp)
bal 0x00311bac
_sw a3,0x8c(sp)
lw gp,0x18(sp)
sw v0,0x4c(sp)
lw v0,0x8c(sp)
beq v0,zero,0x0031739c
_nop
lw s8,0x28(s0)
andi v0,s8,0x1
beq v0,zero,0x003175d8
_sw v0,0x8c(sp)
lw v0,0x0(s1)
li v1,0x4b
sw zero,0x34(sp)
sw zero,0x30(sp)
sw zero,0x2c(sp)
sw zero,0x28(sp)
sw zero,0x24(sp)
sw zero,0x20(sp)
lb a0,0x0(v0)
beq a0,v1,0x00317544
_lw t9,-0x4268(gp)
lb v1,0x1(v0)
slti a0,v1,0x31
bne a0,zero,0x00317564
_slti a0,v1,0x3a
bne a0,zero,0x0031759c
_li a0,0x5f
bne v1,a0,0x00317564
_addiu v0,v0,0x1
or a0,s1,zero
addiu t9,t9,0x2010
bal 0x00312010
_sw v0,0x0(s1)
li v1,-0x1
beq v0,v1,0x00317564
_lw gp,0x18(sp)
or s2,v0,zero
lw v0,-0x4268(gp)
lw s6,-0x4268(gp)
li s3,0x1
lw s7,-0x4268(gp)
addiu v0,v0,0x439c
addiu s6,s6,0x1cb4
sw v0,0x40(sp)
lw v0,-0x4268(gp)
sw v0,0x50(sp)
lw v0,-0x4268(gp)
addiu v0,v0,0x1f28
sw v0,0x44(sp)
blez s2,0x003176ec
_lw a0,0x20(sp)
li a1,0x5f
lw v1,0x0(s1)
sw a0,0x24(sp)
lb v0,0x0(v1)
bne v0,a1,0x0031746c
_li a1,0x74
addiu a1,v1,0x1
sw a1,0x0(s1)
lb v0,0x1(v1)
or v1,a1,zero
li a1,0x74
beq v0,a1,0x003176b4
_li a1,0x4b
beq v0,a1,0x00317854
_lw t9,-0x4268(gp)
lw v0,0x0(s0)
andi v0,v0,0x2000
bne v0,zero,0x003175f8
_lw t9,0x44(sp)
beq a0,zero,0x003174a8
_lw t9,-0x3628(gp)
jalr t9
_nop
sw zero,0x24(sp)
sw zero,0x28(sp)
sw zero,0x20(sp)
addiu s4,sp,0x20
lw t9,0x40(sp)
or a1,s1,zero
or a2,s4,zero
jalr t9
_or a0,s0,zero
lw gp,0x18(sp)
beq v0,zero,0x003176e8
_or s3,v0,zero
lw a2,0x24(sp)
addiu a0,sp,0x2c
addiu t9,s7,0x27e8
bal 0x003127e8
_or a1,s4,zero
lw a1,0x2c(sp)
lw a2,0x30(sp)
beq a1,a2,0x003175f0
_nop
subu a2,a2,a1
or t9,s6,zero
bal 0x00311cb4
_or a0,s0,zero
lw gp,0x18(sp)
li v0,0x1
beq s2,v0,0x0031753c
_nop
lw v0,0x0(s0)
andi v0,v0,0x4
beq v0,zero,0x003175e8
_lw a1,-0x77f0(gp)
lw a1,-0x7f64(gp)
addiu a1,a1,-0x5450
lw t9,-0x4268(gp)
addiu t9,t9,0x2594
bal 0x00312594
_addiu a0,sp,0x2c
lw gp,0x18(sp)
b 0x00317438
_addiu s2,s2,-0x1
addiu v0,v0,0x1
or a0,s1,zero
addiu t9,t9,0x2010
bal 0x00312010
_sw v0,0x0(s1)
li v1,-0x1
bne v0,v1,0x003178e8
_lw gp,0x18(sp)
or s3,zero,zero
lw ra,0x7c(sp)
or v0,s3,zero
lw s8,0x78(sp)
lw s7,0x74(sp)
lw s6,0x70(sp)
lw s5,0x6c(sp)
lw s4,0x68(sp)
lw s3,0x64(sp)
lw s2,0x60(sp)
lw s1,0x5c(sp)
lw s0,0x58(sp)
jr ra
_addiu sp,sp,0x80
lw t9,-0x3624(gp)
or a1,zero,zero
addiu a0,sp,0x38
sb v1,0x38(sp)
li a2,0xa
jalr t9
_sb zero,0x39(sp)
li a0,0x5f
lw v1,0x0(s1)
lb a1,0x2(v1)
beq a1,a0,0x00317930
_lw gp,0x18(sp)
addiu v1,v1,0x2
b 0x00317404
_sw v1,0x0(s1)
lw s8,0x2c(s0)
andi v0,s8,0x1
b 0x0031739c
_sw v0,0x8c(sp)
b 0x00317528
_addiu a1,a1,0x208
b 0x003174f4
_or a2,zero,zero
jalr t9
_or a0,s1,zero
li v1,-0x1
lw gp,0x18(sp)
beq v0,v1,0x003176e8
_or s4,v0,zero
lw t9,-0x4220(gp)
bal 0x0032e348
_addiu a0,v0,0x1
or a2,s4,zero
lw gp,0x18(sp)
or a0,v0,zero
lw a1,0x0(s1)
lw t9,-0x3698(gp)
jalr t9
_or s5,v0,zero
addu v0,s5,s4
lw gp,0x18(sp)
or a0,s5,zero
lw a1,0x0(s0)
lw t9,-0x6a34(gp)
bal 0x00313764
_sb zero,0x0(v0)
beq v0,zero,0x003178bc
_lw gp,0x18(sp)
lb v1,0x0(v0)
beq v1,zero,0x0031768c
_lw t9,-0x3628(gp)
lw t9,-0x4268(gp)
addiu a0,sp,0x2c
or a1,v0,zero
addiu t9,t9,0x2594
bal 0x00312594
_sw v0,0x48(sp)
lw gp,0x18(sp)
lw v0,0x48(sp)
lw t9,-0x3628(gp)
jalr t9
_or a0,v0,zero
lw gp,0x18(sp)
lw s8,0x0(s1)
lw t9,-0x3628(gp)
jalr t9
_or a0,s5,zero
addu a1,s8,s4
b 0x003174e0
_sw a1,0x0(s1)
lw t9,-0x4268(gp)
li v0,0x1
addiu a3,sp,0x20
sw zero,0x14(sp)
addiu a2,sp,0x2c
sw v0,0x10(sp)
addiu t9,t9,0x6a98
or a1,s1,zero
bal 0x00316a98
_or a0,s0,zero
lw gp,0x18(sp)
bne v0,zero,0x003174e0
_or s3,v0,zero
or s3,zero,zero
lw a1,0x2c(sp)
lw a2,0x30(sp)
beq a1,a2,0x00317960
_nop
subu a2,a2,a1
lw t9,-0x4268(gp)
addiu a0,s0,0xc
addiu t9,t9,0x2278
bal 0x00312278
_lw a3,0x4c(sp)
lw v0,0x8c(sp)
beq v0,zero,0x0031777c
_lw gp,0x18(sp)
lw v0,0x0(s0)
andi v0,v0,0x4
bne v0,zero,0x00317920
_lw a1,-0x7f64(gp)
lw a1,-0x77f0(gp)
addiu a1,a1,0x208
lw s1,-0x4268(gp)
addiu s2,sp,0x2c
addiu s1,s1,0x2594
or t9,s1,zero
bal 0x00312594
_or a0,s2,zero
lw v0,0x2c(s0)
andi v0,v0,0x1
bne v0,zero,0x00317968
_lw gp,0x18(sp)
lw t9,-0x4268(gp)
addiu a1,sp,0x20
lw a2,0x24(sp)
addiu t9,t9,0x27e8
bal 0x003127e8
_or a0,s2,zero
lw gp,0x18(sp)
lw v0,0x90(sp)
bne v0,zero,0x00317940
_lw v0,0x88(sp)
lw v1,0x0(v0)
lw v0,0x4(v0)
beq v1,v0,0x003177c8
_lw a1,0x2c(sp)
lw v0,0x0(s0)
andi v0,v0,0x4
bne v0,zero,0x00317928
_lw a1,-0x7f64(gp)
lw a1,-0x77f0(gp)
addiu a1,a1,0x208
lw t9,-0x4268(gp)
addiu t9,t9,0x2594
bal 0x00312594
_addiu a0,sp,0x2c
lw gp,0x18(sp)
lw a1,0x2c(sp)
lw a2,0x30(sp)
beq a1,a2,0x003177e8
_lw t9,-0x4268(gp)
subu a2,a2,a1
addiu t9,t9,0x2470
bal 0x00312470
_lw a0,0x88(sp)
lw gp,0x18(sp)
lw a0,0x20(sp)
beq a0,zero,0x0031780c
_lw t9,-0x3628(gp)
jalr t9
_nop
lw gp,0x18(sp)
sw zero,0x24(sp)
sw zero,0x28(sp)
sw zero,0x20(sp)
lw a0,0x2c(sp)
beq a0,zero,0x00317568
_lw t9,-0x3628(gp)
jalr t9
_nop
or v0,s3,zero
lw ra,0x7c(sp)
lw s8,0x78(sp)
lw s7,0x74(sp)
lw s6,0x70(sp)
lw s5,0x6c(sp)
lw s4,0x68(sp)
lw s3,0x64(sp)
lw s2,0x60(sp)
lw s1,0x5c(sp)
lw s0,0x58(sp)
jr ra
_addiu sp,sp,0x80
addiu v1,v1,0x1
or a0,s1,zero
addiu t9,t9,0x2010
bal 0x00312010
_sw v1,0x0(s1)
li v1,-0x1
beq v0,v1,0x003176e8
_lw gp,0x18(sp)
lw v1,0x10(s0)
slt v1,v0,v1
beq v1,zero,0x003176e8
_sll v0,v0,0x2
lw v1,0x8(s0)
addu v0,v1,v0
lw a1,0x0(v0)
beq a1,zero,0x00317508
_li v0,0x1
lb v0,0x0(a1)
beq v0,zero,0x00317508
_li v0,0x1
lw t9,-0x4268(gp)
addiu t9,t9,0x2594
bal 0x00312594
_addiu a0,sp,0x2c
b 0x00317504
_lw gp,0x18(sp)
beq s4,zero,0x0031769c
_lw s8,0x0(s1)
lw v0,0x50(sp)
addiu a0,sp,0x2c
or a1,s8,zero
addiu t9,v0,0x23f4
bal 0x003123f4
_or a2,s4,zero
lw gp,0x18(sp)
b 0x0031769c
_lw s8,0x0(s1)
lw v1,0x10(s0)
slt v1,v0,v1
beq v1,zero,0x00317564
_sll v0,v0,0x2
lw v1,0x8(s0)
addu v0,v1,v0
lw a1,0x0(v0)
beq a1,zero,0x003176ec
_li s3,0x1
lb v0,0x0(a1)
bne v0,zero,0x00317984
_lw t9,-0x4268(gp)
b 0x003176f0
_lw a1,0x2c(sp)
b 0x00317738
_addiu a1,a1,-0x5450
b 0x003177b0
_addiu a1,a1,-0x5450
addiu v1,v1,0x1
addiu v1,v1,0x2
b 0x00317404
_sw v1,0x0(s1)
lw t9,-0x4268(gp)
addiu a1,sp,0x2c
lw a2,0x30(sp)
addiu t9,t9,0x27e8
bal 0x003127e8
_lw a0,0x88(sp)
b 0x003177e8
_lw gp,0x18(sp)
b 0x00317700
_or a2,zero,zero
lw a1,-0x7924(gp)
or a0,s2,zero
or t9,s1,zero
bal 0x00312594
_addiu a1,a1,0x78e4
b 0x00317760
_lw gp,0x18(sp)
addiu a0,sp,0x2c
addiu t9,t9,0x2594
bal 0x00312594
_li s3,0x1
b 0x003176ec
_lw gp,0x18(sp)
(translation_unit "int FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)\n\n{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}\n\n" (function_definition "int FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)\n\n{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}" primitive_type (function_declarator "FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)" identifier (parameter_list "(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)" ( (parameter_declaration "uint *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "int *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "uint param_4" type_identifier identifier) , (parameter_declaration "int param_5" primitive_type identifier) ))) (compound_statement "{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}" { (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "char cVar4;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "char *pcVar5;" primitive_type (pointer_declarator "*pcVar5" * identifier) ;) (declaration "undefined *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "uint uVar7;" type_identifier identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "int iVar9;" primitive_type identifier ;) (declaration "int iVar10;" primitive_type identifier ;) (declaration "uint local_resc;" type_identifier identifier ;) (declaration "int local_60;" primitive_type identifier ;) (declaration "int local_5c;" primitive_type identifier ;) (declaration "undefined4 local_58;" type_identifier identifier ;) (declaration "int local_54;" primitive_type identifier ;) (declaration "int local_50;" primitive_type identifier ;) (declaration "undefined4 local_4c;" type_identifier identifier ;) (declaration "char local_48 [8];" primitive_type (array_declarator "local_48 [8]" identifier [ number_literal ]) ;) (declaration "code *local_40;" type_identifier (pointer_declarator "*local_40" * identifier) ;) (declaration "code *local_3c;" type_identifier (pointer_declarator "*local_3c" * identifier) ;) (declaration "char *local_38;" primitive_type (pointer_declarator "*local_38" * identifier) ;) (declaration "undefined4 local_34;" type_identifier identifier ;) (declaration "undefined *local_30;" type_identifier (pointer_declarator "*local_30" * identifier) ;) (expression_statement "local_34 = FUN_00311bac();" (assignment_expression "local_34 = FUN_00311bac()" identifier = (call_expression "FUN_00311bac()" identifier (argument_list "()" ( )))) ;) (expression_statement "local_resc = param_4;" (assignment_expression "local_resc = param_4" identifier = identifier) ;) (if_statement "if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }" if (parenthesized_expression "((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0))" ( (binary_expression "(param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)" (parenthesized_expression "(param_4 != 0)" ( (binary_expression "param_4 != 0" identifier != number_literal) )) && (parenthesized_expression "(local_resc = param_1[10] & 1, local_resc == 0)" ( (comma_expression "local_resc = param_1[10] & 1, local_resc == 0" (assignment_expression "local_resc = param_1[10] & 1" identifier = (binary_expression "param_1[10] & 1" (subscript_expression "param_1[10]" identifier [ number_literal ]) & number_literal)) , (binary_expression "local_resc == 0" identifier == number_literal)) ))) )) (compound_statement "{\n    local_resc = param_1[0xb] & 1;\n  }" { (expression_statement "local_resc = param_1[0xb] & 1;" (assignment_expression "local_resc = param_1[0xb] & 1" identifier = (binary_expression "param_1[0xb] & 1" (subscript_expression "param_1[0xb]" identifier [ number_literal ]) & number_literal)) ;) })) (expression_statement "pcVar1 = (char *)*param_2;" (assignment_expression "pcVar1 = (char *)*param_2" identifier = (cast_expression "(char *)*param_2" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) ;) (expression_statement "local_4c = 0;" (assignment_expression "local_4c = 0" identifier = number_literal) ;) (expression_statement "local_50 = 0;" (assignment_expression "local_50 = 0" identifier = number_literal) ;) (expression_statement "local_54 = 0;" (assignment_expression "local_54 = 0" identifier = number_literal) ;) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" identifier = number_literal) ;) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" identifier = number_literal) ;) (expression_statement "local_60 = 0;" (assignment_expression "local_60 = 0" identifier = number_literal) ;) (if_statement "if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" if (parenthesized_expression "(*pcVar1 == 'K')" ( (binary_expression "*pcVar1 == 'K'" (pointer_expression "*pcVar1" * identifier) == (char_literal "'K'" ' character ')) )) (compound_statement "{\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }" { (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(pcVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar1 + 1)" ( (binary_expression "pcVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "iVar9 = FUN_00312010(param_2);" (assignment_expression "iVar9 = FUN_00312010(param_2)" identifier = (call_expression "FUN_00312010(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar9 == -1) {\n      return 0;\n    }" if (parenthesized_expression "(iVar9 == -1)" ( (binary_expression "iVar9 == -1" identifier == number_literal) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }" if (parenthesized_expression "((int)param_1[4] <= iVar9)" ( (binary_expression "(int)param_1[4] <= iVar9" (cast_expression "(int)param_1[4]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "param_1[4]" identifier [ number_literal ])) <= identifier) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "pcVar1 = *(char **)(param_1[2] + iVar9 * 4);" (assignment_expression "pcVar1 = *(char **)(param_1[2] + iVar9 * 4)" identifier = (pointer_expression "*(char **)(param_1[2] + iVar9 * 4)" * (cast_expression "(char **)(param_1[2] + iVar9 * 4)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1[2] + iVar9 * 4)" ( (binary_expression "param_1[2] + iVar9 * 4" (subscript_expression "param_1[2]" identifier [ number_literal ]) + (binary_expression "iVar9 * 4" identifier * number_literal)) ))))) ;) (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" identifier = number_literal) ;) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }" if (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" ( (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" ( (binary_expression "pcVar1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }" { (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" identifier = number_literal) ;) (expression_statement "FUN_00312594(&local_54);" (call_expression "FUN_00312594(&local_54)" identifier (argument_list "(&local_54)" ( (pointer_expression "&local_54" & identifier) ))) ;) })) }) (else_clause "else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" else (compound_statement "{\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" { (expression_statement "cVar4 = pcVar1[1];" (assignment_expression "cVar4 = pcVar1[1]" identifier = (subscript_expression "pcVar1[1]" identifier [ number_literal ])) ;) (if_statement "if (cVar4 < '1') {\n      return 0;\n    }" if (parenthesized_expression "(cVar4 < '1')" ( (binary_expression "cVar4 < '1'" identifier < (char_literal "'1'" ' character ')) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" if (parenthesized_expression "(cVar4 < ':')" ( (binary_expression "cVar4 < ':'" identifier < (char_literal "':'" ' character ')) )) (compound_statement "{\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }" { (expression_statement "local_48[1] = 0;" (assignment_expression "local_48[1] = 0" (subscript_expression "local_48[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "local_48[0] = cVar4;" (assignment_expression "local_48[0] = cVar4" (subscript_expression "local_48[0]" identifier [ number_literal ]) = identifier) ;) (expression_statement "iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);" (assignment_expression "iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10)" identifier = (call_expression "(*(code *)PTR_strtol_004c5c1c)(local_48,0,10)" (parenthesized_expression "(*(code *)PTR_strtol_004c5c1c)" ( (pointer_expression "*(code *)PTR_strtol_004c5c1c" * (cast_expression "(code *)PTR_strtol_004c5c1c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(local_48,0,10)" ( identifier , number_literal , number_literal )))) ;) (expression_statement "iVar9 = *param_2;" (assignment_expression "iVar9 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (if_statement "if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }" if (parenthesized_expression "(*(char *)(iVar9 + 2) == '_')" ( (binary_expression "*(char *)(iVar9 + 2) == '_'" (pointer_expression "*(char *)(iVar9 + 2)" * (cast_expression "(char *)(iVar9 + 2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar9 + 2)" ( (binary_expression "iVar9 + 2" identifier + number_literal) )))) == (char_literal "'_'" ' character ')) )) (compound_statement "{\n        *param_2 = iVar9 + 3;\n      }" { (expression_statement "*param_2 = iVar9 + 3;" (assignment_expression "*param_2 = iVar9 + 3" (pointer_expression "*param_2" * identifier) = (binary_expression "iVar9 + 3" identifier + number_literal)) ;) }) (else_clause "else {\n        *param_2 = iVar9 + 2;\n      }" else (compound_statement "{\n        *param_2 = iVar9 + 2;\n      }" { (expression_statement "*param_2 = iVar9 + 2;" (assignment_expression "*param_2 = iVar9 + 2" (pointer_expression "*param_2" * identifier) = (binary_expression "iVar9 + 2" identifier + number_literal)) ;) }))) }) (else_clause "else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" else (compound_statement "{\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" { (if_statement "if (cVar4 != '_') {\n        return 0;\n      }" if (parenthesized_expression "(cVar4 != '_')" ( (binary_expression "cVar4 != '_'" identifier != (char_literal "'_'" ' character ')) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(pcVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar1 + 1)" ( (binary_expression "pcVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "iVar2 = FUN_00312010(param_2);" (assignment_expression "iVar2 = FUN_00312010(param_2)" identifier = (call_expression "FUN_00312010(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar2 == -1) {\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == -1)" ( (binary_expression "iVar2 == -1" identifier == number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) }))) (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" identifier = number_literal) ;) (expression_statement "local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);" (assignment_expression "local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c)" identifier = (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x439c)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x439c)" ( (binary_expression "PTR_LAB_004c4fd8 + 0x439c" identifier + number_literal) )))) ;) (expression_statement "local_30 = PTR_LAB_004c4fd8;" (assignment_expression "local_30 = PTR_LAB_004c4fd8" identifier = identifier) ;) (expression_statement "local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);" (assignment_expression "local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28)" identifier = (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x1f28)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x1f28)" ( (binary_expression "PTR_LAB_004c4fd8 + 0x1f28" identifier + number_literal) )))) ;) (for_statement "for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }" for ( ; (binary_expression "0 < iVar2" number_literal < identifier) ; (assignment_expression "iVar2 = iVar2 + -1" identifier = (binary_expression "iVar2 + -1" identifier + number_literal)) ) (compound_statement "{\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }" { (expression_statement "pcVar5 = (char *)*param_2;" (assignment_expression "pcVar5 = (char *)*param_2" identifier = (cast_expression "(char *)*param_2" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) ;) (expression_statement "local_5c = local_60;" (assignment_expression "local_5c = local_60" identifier = identifier) ;) (expression_statement "cVar4 = *pcVar5;" (assignment_expression "cVar4 = *pcVar5" identifier = (pointer_expression "*pcVar5" * identifier)) ;) (expression_statement "pcVar1 = pcVar5;" (assignment_expression "pcVar1 = pcVar5" identifier = identifier) ;) (if_statement "if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }" if (parenthesized_expression "(cVar4 == '_')" ( (binary_expression "cVar4 == '_'" identifier == (char_literal "'_'" ' character ')) )) (compound_statement "{\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }" { (expression_statement "pcVar1 = pcVar5 + 1;" (assignment_expression "pcVar1 = pcVar5 + 1" identifier = (binary_expression "pcVar5 + 1" identifier + number_literal)) ;) (expression_statement "*param_2 = (int)pcVar1;" (assignment_expression "*param_2 = (int)pcVar1" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)pcVar1" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "cVar4 = pcVar5[1];" (assignment_expression "cVar4 = pcVar5[1]" identifier = (subscript_expression "pcVar5[1]" identifier [ number_literal ])) ;) })) (if_statement "if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }" if (parenthesized_expression "(cVar4 == 't')" ( (binary_expression "cVar4 == 't'" identifier == (char_literal "'t'" ' character ')) )) (compound_statement "{\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }" { (expression_statement "iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);" (assignment_expression "iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0)" identifier = (call_expression "FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0)" identifier (argument_list "(param_1,param_2,&local_54,&local_60,1,0)" ( identifier , identifier , (pointer_expression "&local_54" & identifier) , (pointer_expression "&local_60" & identifier) , number_literal , number_literal )))) ;) (if_statement "if (iVar9 != 0) goto LAB_003174e0;" if (parenthesized_expression "(iVar9 != 0)" ( (binary_expression "iVar9 != 0" identifier != number_literal) )) (goto_statement "goto LAB_003174e0;" goto statement_identifier ;)) (labeled_statement "LAB_003176e8:\n        iVar9 = 0;" statement_identifier : (expression_statement "iVar9 = 0;" (assignment_expression "iVar9 = 0" identifier = number_literal) ;)) (break_statement "break;" break ;) })) (if_statement "if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" if (parenthesized_expression "(cVar4 == 'K')" ( (binary_expression "cVar4 == 'K'" identifier == (char_literal "'K'" ' character ')) )) (compound_statement "{\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }" { (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(pcVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar1 + 1)" ( (binary_expression "pcVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "iVar8 = FUN_00312010(param_2);" (assignment_expression "iVar8 = FUN_00312010(param_2)" identifier = (call_expression "FUN_00312010(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;" if (parenthesized_expression "((iVar8 == -1) || ((int)param_1[4] <= iVar8))" ( (binary_expression "(iVar8 == -1) || ((int)param_1[4] <= iVar8)" (parenthesized_expression "(iVar8 == -1)" ( (binary_expression "iVar8 == -1" identifier == number_literal) )) || (parenthesized_expression "((int)param_1[4] <= iVar8)" ( (binary_expression "(int)param_1[4] <= iVar8" (cast_expression "(int)param_1[4]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "param_1[4]" identifier [ number_literal ])) <= identifier) ))) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "pcVar1 = *(char **)(param_1[2] + iVar8 * 4);" (assignment_expression "pcVar1 = *(char **)(param_1[2] + iVar8 * 4)" identifier = (pointer_expression "*(char **)(param_1[2] + iVar8 * 4)" * (cast_expression "(char **)(param_1[2] + iVar8 * 4)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1[2] + iVar8 * 4)" ( (binary_expression "param_1[2] + iVar8 * 4" (subscript_expression "param_1[2]" identifier [ number_literal ]) + (binary_expression "iVar8 * 4" identifier * number_literal)) ))))) ;) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }" if (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" ( (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" ( (binary_expression "pcVar1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n          FUN_00312594(&local_54);\n        }" { (expression_statement "FUN_00312594(&local_54);" (call_expression "FUN_00312594(&local_54)" identifier (argument_list "(&local_54)" ( (pointer_expression "&local_54" & identifier) ))) ;) })) }) (else_clause "else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" else (compound_statement "{\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" { (if_statement "if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" if (parenthesized_expression "((*param_1 & 0x2000) == 0)" ( (binary_expression "(*param_1 & 0x2000) == 0" (parenthesized_expression "(*param_1 & 0x2000)" ( (binary_expression "*param_1 & 0x2000" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }" { (if_statement "if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }" if (parenthesized_expression "(local_60 != 0)" ( (binary_expression "local_60 != 0" identifier != number_literal) )) (compound_statement "{\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" identifier = number_literal) ;) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" identifier = number_literal) ;) })) (expression_statement "local_60 = local_5c;" (assignment_expression "local_60 = local_5c" identifier = identifier) ;) (expression_statement "iVar9 = (*local_40)(param_1,param_2,&local_60);" (assignment_expression "iVar9 = (*local_40)(param_1,param_2,&local_60)" identifier = (call_expression "(*local_40)(param_1,param_2,&local_60)" (parenthesized_expression "(*local_40)" ( (pointer_expression "*local_40" * identifier) )) (argument_list "(param_1,param_2,&local_60)" ( identifier , identifier , (pointer_expression "&local_60" & identifier) )))) ;) (if_statement "if (iVar9 == 0) goto LAB_003176e8;" if (parenthesized_expression "(iVar9 == 0)" ( (binary_expression "iVar9 == 0" identifier == number_literal) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "FUN_003127e8(&local_54,&local_60,local_5c);" (call_expression "FUN_003127e8(&local_54,&local_60,local_5c)" identifier (argument_list "(&local_54,&local_60,local_5c)" ( (pointer_expression "&local_54" & identifier) , (pointer_expression "&local_60" & identifier) , identifier ))) ;) }) (else_clause "else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" else (compound_statement "{\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" { (expression_statement "iVar8 = (*local_3c)(param_2);" (assignment_expression "iVar8 = (*local_3c)(param_2)" identifier = (call_expression "(*local_3c)(param_2)" (parenthesized_expression "(*local_3c)" ( (pointer_expression "*local_3c" * identifier) )) (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar8 == -1) goto LAB_003176e8;" if (parenthesized_expression "(iVar8 == -1)" ( (binary_expression "iVar8 == -1" identifier == number_literal) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "iVar3 = xmalloc(iVar8 + 1);" (assignment_expression "iVar3 = xmalloc(iVar8 + 1)" identifier = (call_expression "xmalloc(iVar8 + 1)" identifier (argument_list "(iVar8 + 1)" ( (binary_expression "iVar8 + 1" identifier + number_literal) )))) ;) (expression_statement "(*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);" (call_expression "(*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8)" (parenthesized_expression "(*(code *)PTR_memcpy_004c5ba8)" ( (pointer_expression "*(code *)PTR_memcpy_004c5ba8" * (cast_expression "(code *)PTR_memcpy_004c5ba8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar3,*param_2,iVar8)" ( identifier , (pointer_expression "*param_2" * identifier) , identifier ))) ;) (expression_statement "uVar7 = *param_1;" (assignment_expression "uVar7 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "*(undefined1 *)(iVar3 + iVar8) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar8) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar8)" * (cast_expression "(undefined1 *)(iVar3 + iVar8)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar8)" ( (binary_expression "iVar3 + iVar8" identifier + identifier) )))) = number_literal) ;) (expression_statement "pcVar1 = (char *)cplus_demangle(iVar3,uVar7);" (assignment_expression "pcVar1 = (char *)cplus_demangle(iVar3,uVar7)" identifier = (cast_expression "(char *)cplus_demangle(iVar3,uVar7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "cplus_demangle(iVar3,uVar7)" identifier (argument_list "(iVar3,uVar7)" ( identifier , identifier ))))) ;) (if_statement "if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" if (parenthesized_expression "(pcVar1 == (char *)0x0)" ( (binary_expression "pcVar1 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }" { (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (if_statement "if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }" if (parenthesized_expression "(iVar8 != 0)" ( (binary_expression "iVar8 != 0" identifier != number_literal) )) (compound_statement "{\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }" { (expression_statement "FUN_003123f4(&local_54,iVar10,iVar8);" (call_expression "FUN_003123f4(&local_54,iVar10,iVar8)" identifier (argument_list "(&local_54,iVar10,iVar8)" ( (pointer_expression "&local_54" & identifier) , identifier , identifier ))) ;) (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) })) }) (else_clause "else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" else (compound_statement "{\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" { (if_statement "if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }" if (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }" { (expression_statement "local_38 = pcVar1;" (assignment_expression "local_38 = pcVar1" identifier = identifier) ;) (expression_statement "FUN_00312594(&local_54,pcVar1);" (call_expression "FUN_00312594(&local_54,pcVar1)" identifier (argument_list "(&local_54,pcVar1)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) (expression_statement "pcVar1 = local_38;" (assignment_expression "pcVar1 = local_38" identifier = identifier) ;) })) (expression_statement "(*(code *)PTR_free_004c5c18)(pcVar1);" (call_expression "(*(code *)PTR_free_004c5c18)(pcVar1)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) }))) (expression_statement "(*(code *)PTR_free_004c5c18)(iVar3);" (call_expression "(*(code *)PTR_free_004c5c18)(iVar3)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar3)" ( identifier ))) ;) (expression_statement "*param_2 = iVar10 + iVar8;" (assignment_expression "*param_2 = iVar10 + iVar8" (pointer_expression "*param_2" * identifier) = (binary_expression "iVar10 + iVar8" identifier + identifier)) ;) }))) (labeled_statement "LAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }" statement_identifier : (if_statement "if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }" if (parenthesized_expression "(local_54 == local_50)" ( (binary_expression "local_54 == local_50" identifier == identifier) )) (compound_statement "{\n          iVar8 = 0;\n        }" { (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" identifier = number_literal) ;) }) (else_clause "else {\n          iVar8 = local_50 - local_54;\n        }" else (compound_statement "{\n          iVar8 = local_50 - local_54;\n        }" { (expression_statement "iVar8 = local_50 - local_54;" (assignment_expression "iVar8 = local_50 - local_54" identifier = (binary_expression "local_50 - local_54" identifier - identifier)) ;) })))) (expression_statement "FUN_00311cb4(param_1,local_54,iVar8);" (call_expression "FUN_00311cb4(param_1,local_54,iVar8)" identifier (argument_list "(param_1,local_54,iVar8)" ( identifier , identifier , identifier ))) ;) }))) (if_statement "if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }" if (parenthesized_expression "(iVar2 != 1)" ( (binary_expression "iVar2 != 1" identifier != number_literal) )) (compound_statement "{\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }" { (if_statement "if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" if (parenthesized_expression "((*param_1 & 4) == 0)" ( (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" ( (binary_expression "*param_1 & 4" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }" { (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" else (compound_statement "{\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" { (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" identifier (argument_list "(&local_54,puVar6)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) })) })) }))) (if_statement "if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }" if (parenthesized_expression "(local_54 == local_50)" ( (binary_expression "local_54 == local_50" identifier == identifier) )) (compound_statement "{\n    iVar2 = 0;\n  }" { (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    iVar2 = local_50 - local_54;\n  }" else (compound_statement "{\n    iVar2 = local_50 - local_54;\n  }" { (expression_statement "iVar2 = local_50 - local_54;" (assignment_expression "iVar2 = local_50 - local_54" identifier = (binary_expression "local_50 - local_54" identifier - identifier)) ;) }))) (expression_statement "FUN_00312278(param_1 + 3,local_54,iVar2,local_34);" (call_expression "FUN_00312278(param_1 + 3,local_54,iVar2,local_34)" identifier (argument_list "(param_1 + 3,local_54,iVar2,local_34)" ( (binary_expression "param_1 + 3" identifier + number_literal) , identifier , identifier , identifier ))) ;) (if_statement "if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }" if (parenthesized_expression "(local_resc != 0)" ( (binary_expression "local_resc != 0" identifier != number_literal) )) (compound_statement "{\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }" { (if_statement "if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" if (parenthesized_expression "((*param_1 & 4) == 0)" ( (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" ( (binary_expression "*param_1 & 4" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }" { (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" else (compound_statement "{\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" { (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" identifier (argument_list "(&local_54,puVar6)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) (if_statement "if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" if (parenthesized_expression "((param_1[0xb] & 1) != 0)" ( (binary_expression "(param_1[0xb] & 1) != 0" (parenthesized_expression "(param_1[0xb] & 1)" ( (binary_expression "param_1[0xb] & 1" (subscript_expression "param_1[0xb]" identifier [ number_literal ]) & number_literal) )) != number_literal) )) (compound_statement "{\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" { (expression_statement "FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);" (call_expression "FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4)" identifier (argument_list "(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4)" ( (pointer_expression "&local_54" & identifier) , (binary_expression "PTR_s_in_a_linker_script_004c191c + 0x78e4" identifier + number_literal) ))) ;) })) (expression_statement "FUN_003127e8(&local_54,&local_60,local_5c);" (call_expression "FUN_003127e8(&local_54,&local_60,local_5c)" identifier (argument_list "(&local_54,&local_60,local_5c)" ( (pointer_expression "&local_54" & identifier) , (pointer_expression "&local_60" & identifier) , identifier ))) ;) })) (if_statement "if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" if (parenthesized_expression "(param_5 == 0)" ( (binary_expression "param_5 == 0" identifier == number_literal) )) (compound_statement "{\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }" { (if_statement "if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }" if (parenthesized_expression "(*param_3 != param_3[1])" ( (binary_expression "*param_3 != param_3[1]" (pointer_expression "*param_3" * identifier) != (subscript_expression "param_3[1]" identifier [ number_literal ])) )) (compound_statement "{\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }" { (if_statement "if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" if (parenthesized_expression "((*param_1 & 4) == 0)" ( (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" ( (binary_expression "*param_1 & 4" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }" { (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" else (compound_statement "{\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" { (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" identifier (argument_list "(&local_54,puVar6)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) })) (if_statement "if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }" if (parenthesized_expression "(local_54 != local_50)" ( (binary_expression "local_54 != local_50" identifier != identifier) )) (compound_statement "{\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }" { (expression_statement "FUN_00312470(param_3,local_54,local_50 - local_54);" (call_expression "FUN_00312470(param_3,local_54,local_50 - local_54)" identifier (argument_list "(param_3,local_54,local_50 - local_54)" ( identifier , identifier , (binary_expression "local_50 - local_54" identifier - identifier) ))) ;) })) }) (else_clause "else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" else (compound_statement "{\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" { (expression_statement "FUN_003127e8(param_3,&local_54,local_50);" (call_expression "FUN_003127e8(param_3,&local_54,local_50)" identifier (argument_list "(param_3,&local_54,local_50)" ( identifier , (pointer_expression "&local_54" & identifier) , identifier ))) ;) }))) (if_statement "if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }" if (parenthesized_expression "(local_60 != 0)" ( (binary_expression "local_60 != 0" identifier != number_literal) )) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" identifier = number_literal) ;) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" identifier = number_literal) ;) (expression_statement "local_60 = 0;" (assignment_expression "local_60 = 0" identifier = number_literal) ;) })) (if_statement "if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }" if (parenthesized_expression "(local_54 != 0)" ( (binary_expression "local_54 != 0" identifier != number_literal) )) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (return_statement "return iVar9;" return identifier ;) })) (return_statement "return iVar9;" return identifier ;) })))
(translation_unit "int demangle_qualified(work_stuff *work,char **mangled,string *result,int isfuncname,int append)\n\n{\n  int index;\n  char *pcVar1;\n  int iVar2;\n  code *pcVar3;\n  code *pcVar4;\n  char cVar5;\n  char *pcVar6;\n  int options;\n  int iVar7;\n  int iVar8;\n  uint local_resc;\n  string last_name;\n  string temp;\n  char num [2];\n  \n  index = register_Btype(work);\n  local_resc = isfuncname;\n  if ((isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0)) {\n    local_resc = work->destructor & 1;\n  }\n  pcVar1 = *mangled;\n  temp.e = (char *)0x0;\n  temp.p = (char *)0x0;\n  temp.b = (char *)0x0;\n  last_name.e = (char *)0x0;\n  last_name.p = (char *)0x0;\n  last_name.b = (char *)0x0;\n  if (*pcVar1 == 'K') {\n    *mangled = pcVar1 + 1;\n    iVar8 = consume_count_with_underscores(mangled);\n    if (iVar8 == -1) {\n      return 0;\n    }\n    if (work->numk <= iVar8) {\n      return 0;\n    }\n    pcVar1 = work->ktypevec[iVar8];\n    iVar8 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }\n  }\n  else {\n    cVar5 = pcVar1[1];\n    if (cVar5 < '1') {\n      return 0;\n    }\n    if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar8 = 1;\n    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }\n  }\n  if (temp.b == temp.p) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = (int)temp.p - (int)temp.b;\n  }\n  remember_Btype((work_stuff *)&work->btypevec,temp.b,iVar2,index);\n  if (local_resc != 0) {\n    if ((work->options & 4U) == 0) {\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }\n    string_append(&temp,pcVar1);\n    if ((work->destructor & 1U) != 0) {\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    string_appends(&temp,&last_name,(string *)last_name.p);\n  }\n  if (append == 0) {\n    if (result->b != result->p) {\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }\n    if (temp.b != temp.p) {\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }\n  }\n  else {\n    string_appends(result,&temp,(string *)temp.p);\n  }\n  if (last_name.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    last_name.p = (char *)0x0;\n    last_name.e = (char *)0x0;\n    last_name.b = (char *)0x0;\n  }\n  if (temp.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar8;\n  }\n  return iVar8;\n}\n\n" (function_definition "int demangle_qualified(work_stuff *work,char **mangled,string *result,int isfuncname,int append)\n\n{\n  int index;\n  char *pcVar1;\n  int iVar2;\n  code *pcVar3;\n  code *pcVar4;\n  char cVar5;\n  char *pcVar6;\n  int options;\n  int iVar7;\n  int iVar8;\n  uint local_resc;\n  string last_name;\n  string temp;\n  char num [2];\n  \n  index = register_Btype(work);\n  local_resc = isfuncname;\n  if ((isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0)) {\n    local_resc = work->destructor & 1;\n  }\n  pcVar1 = *mangled;\n  temp.e = (char *)0x0;\n  temp.p = (char *)0x0;\n  temp.b = (char *)0x0;\n  last_name.e = (char *)0x0;\n  last_name.p = (char *)0x0;\n  last_name.b = (char *)0x0;\n  if (*pcVar1 == 'K') {\n    *mangled = pcVar1 + 1;\n    iVar8 = consume_count_with_underscores(mangled);\n    if (iVar8 == -1) {\n      return 0;\n    }\n    if (work->numk <= iVar8) {\n      return 0;\n    }\n    pcVar1 = work->ktypevec[iVar8];\n    iVar8 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }\n  }\n  else {\n    cVar5 = pcVar1[1];\n    if (cVar5 < '1') {\n      return 0;\n    }\n    if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar8 = 1;\n    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }\n  }\n  if (temp.b == temp.p) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = (int)temp.p - (int)temp.b;\n  }\n  remember_Btype((work_stuff *)&work->btypevec,temp.b,iVar2,index);\n  if (local_resc != 0) {\n    if ((work->options & 4U) == 0) {\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }\n    string_append(&temp,pcVar1);\n    if ((work->destructor & 1U) != 0) {\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    string_appends(&temp,&last_name,(string *)last_name.p);\n  }\n  if (append == 0) {\n    if (result->b != result->p) {\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }\n    if (temp.b != temp.p) {\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }\n  }\n  else {\n    string_appends(result,&temp,(string *)temp.p);\n  }\n  if (last_name.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    last_name.p = (char *)0x0;\n    last_name.e = (char *)0x0;\n    last_name.b = (char *)0x0;\n  }\n  if (temp.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar8;\n  }\n  return iVar8;\n}" primitive_type (function_declarator "demangle_qualified(work_stuff *work,char **mangled,string *result,int isfuncname,int append)" identifier (parameter_list "(work_stuff *work,char **mangled,string *result,int isfuncname,int append)" ( (parameter_declaration "work_stuff *work" type_identifier (pointer_declarator "*work" * identifier)) , (parameter_declaration "char **mangled" primitive_type (pointer_declarator "**mangled" * (pointer_declarator "*mangled" * identifier))) , (parameter_declaration "string *result" type_identifier (pointer_declarator "*result" * identifier)) , (parameter_declaration "int isfuncname" primitive_type identifier) , (parameter_declaration "int append" primitive_type identifier) ))) (compound_statement "{\n  int index;\n  char *pcVar1;\n  int iVar2;\n  code *pcVar3;\n  code *pcVar4;\n  char cVar5;\n  char *pcVar6;\n  int options;\n  int iVar7;\n  int iVar8;\n  uint local_resc;\n  string last_name;\n  string temp;\n  char num [2];\n  \n  index = register_Btype(work);\n  local_resc = isfuncname;\n  if ((isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0)) {\n    local_resc = work->destructor & 1;\n  }\n  pcVar1 = *mangled;\n  temp.e = (char *)0x0;\n  temp.p = (char *)0x0;\n  temp.b = (char *)0x0;\n  last_name.e = (char *)0x0;\n  last_name.p = (char *)0x0;\n  last_name.b = (char *)0x0;\n  if (*pcVar1 == 'K') {\n    *mangled = pcVar1 + 1;\n    iVar8 = consume_count_with_underscores(mangled);\n    if (iVar8 == -1) {\n      return 0;\n    }\n    if (work->numk <= iVar8) {\n      return 0;\n    }\n    pcVar1 = work->ktypevec[iVar8];\n    iVar8 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }\n  }\n  else {\n    cVar5 = pcVar1[1];\n    if (cVar5 < '1') {\n      return 0;\n    }\n    if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar8 = 1;\n    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }\n  }\n  if (temp.b == temp.p) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = (int)temp.p - (int)temp.b;\n  }\n  remember_Btype((work_stuff *)&work->btypevec,temp.b,iVar2,index);\n  if (local_resc != 0) {\n    if ((work->options & 4U) == 0) {\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }\n    string_append(&temp,pcVar1);\n    if ((work->destructor & 1U) != 0) {\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    string_appends(&temp,&last_name,(string *)last_name.p);\n  }\n  if (append == 0) {\n    if (result->b != result->p) {\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }\n    if (temp.b != temp.p) {\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }\n  }\n  else {\n    string_appends(result,&temp,(string *)temp.p);\n  }\n  if (last_name.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    last_name.p = (char *)0x0;\n    last_name.e = (char *)0x0;\n    last_name.b = (char *)0x0;\n  }\n  if (temp.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar8;\n  }\n  return iVar8;\n}" { (declaration "int index;" primitive_type identifier ;) (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "code *pcVar3;" type_identifier (pointer_declarator "*pcVar3" * identifier) ;) (declaration "code *pcVar4;" type_identifier (pointer_declarator "*pcVar4" * identifier) ;) (declaration "char cVar5;" primitive_type identifier ;) (declaration "char *pcVar6;" primitive_type (pointer_declarator "*pcVar6" * identifier) ;) (declaration "int options;" primitive_type identifier ;) (declaration "int iVar7;" primitive_type identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "uint local_resc;" type_identifier identifier ;) (declaration "string last_name;" type_identifier identifier ;) (declaration "string temp;" type_identifier identifier ;) (declaration "char num [2];" primitive_type (array_declarator "num [2]" identifier [ number_literal ]) ;) (expression_statement "index = register_Btype(work);" (assignment_expression "index = register_Btype(work)" identifier = (call_expression "register_Btype(work)" identifier (argument_list "(work)" ( identifier )))) ;) (expression_statement "local_resc = isfuncname;" (assignment_expression "local_resc = isfuncname" identifier = identifier) ;) (if_statement "if ((isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0)) {\n    local_resc = work->destructor & 1;\n  }" if (parenthesized_expression "((isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0))" ( (binary_expression "(isfuncname != 0) && (local_resc = work->constructor & 1, local_resc == 0)" (parenthesized_expression "(isfuncname != 0)" ( (binary_expression "isfuncname != 0" identifier != number_literal) )) && (parenthesized_expression "(local_resc = work->constructor & 1, local_resc == 0)" ( (comma_expression "local_resc = work->constructor & 1, local_resc == 0" (assignment_expression "local_resc = work->constructor & 1" identifier = (binary_expression "work->constructor & 1" (field_expression "work->constructor" identifier -> field_identifier) & number_literal)) , (binary_expression "local_resc == 0" identifier == number_literal)) ))) )) (compound_statement "{\n    local_resc = work->destructor & 1;\n  }" { (expression_statement "local_resc = work->destructor & 1;" (assignment_expression "local_resc = work->destructor & 1" identifier = (binary_expression "work->destructor & 1" (field_expression "work->destructor" identifier -> field_identifier) & number_literal)) ;) })) (expression_statement "pcVar1 = *mangled;" (assignment_expression "pcVar1 = *mangled" identifier = (pointer_expression "*mangled" * identifier)) ;) (expression_statement "temp.e = (char *)0x0;" (assignment_expression "temp.e = (char *)0x0" (field_expression "temp.e" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "temp.p = (char *)0x0;" (assignment_expression "temp.p = (char *)0x0" (field_expression "temp.p" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "temp.b = (char *)0x0;" (assignment_expression "temp.b = (char *)0x0" (field_expression "temp.b" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "last_name.e = (char *)0x0;" (assignment_expression "last_name.e = (char *)0x0" (field_expression "last_name.e" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "last_name.p = (char *)0x0;" (assignment_expression "last_name.p = (char *)0x0" (field_expression "last_name.p" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "last_name.b = (char *)0x0;" (assignment_expression "last_name.b = (char *)0x0" (field_expression "last_name.b" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (if_statement "if (*pcVar1 == 'K') {\n    *mangled = pcVar1 + 1;\n    iVar8 = consume_count_with_underscores(mangled);\n    if (iVar8 == -1) {\n      return 0;\n    }\n    if (work->numk <= iVar8) {\n      return 0;\n    }\n    pcVar1 = work->ktypevec[iVar8];\n    iVar8 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }\n  }\n  else {\n    cVar5 = pcVar1[1];\n    if (cVar5 < '1') {\n      return 0;\n    }\n    if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar8 = 1;\n    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }\n  }" if (parenthesized_expression "(*pcVar1 == 'K')" ( (binary_expression "*pcVar1 == 'K'" (pointer_expression "*pcVar1" * identifier) == (char_literal "'K'" ' character ')) )) (compound_statement "{\n    *mangled = pcVar1 + 1;\n    iVar8 = consume_count_with_underscores(mangled);\n    if (iVar8 == -1) {\n      return 0;\n    }\n    if (work->numk <= iVar8) {\n      return 0;\n    }\n    pcVar1 = work->ktypevec[iVar8];\n    iVar8 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }\n  }" { (expression_statement "*mangled = pcVar1 + 1;" (assignment_expression "*mangled = pcVar1 + 1" (pointer_expression "*mangled" * identifier) = (binary_expression "pcVar1 + 1" identifier + number_literal)) ;) (expression_statement "iVar8 = consume_count_with_underscores(mangled);" (assignment_expression "iVar8 = consume_count_with_underscores(mangled)" identifier = (call_expression "consume_count_with_underscores(mangled)" identifier (argument_list "(mangled)" ( identifier )))) ;) (if_statement "if (iVar8 == -1) {\n      return 0;\n    }" if (parenthesized_expression "(iVar8 == -1)" ( (binary_expression "iVar8 == -1" identifier == number_literal) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if (work->numk <= iVar8) {\n      return 0;\n    }" if (parenthesized_expression "(work->numk <= iVar8)" ( (binary_expression "work->numk <= iVar8" (field_expression "work->numk" identifier -> field_identifier) <= identifier) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "pcVar1 = work->ktypevec[iVar8];" (assignment_expression "pcVar1 = work->ktypevec[iVar8]" identifier = (subscript_expression "work->ktypevec[iVar8]" (field_expression "work->ktypevec" identifier -> field_identifier) [ identifier ])) ;) (expression_statement "iVar8 = 1;" (assignment_expression "iVar8 = 1" identifier = number_literal) ;) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }" if (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" ( (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" ( (binary_expression "pcVar1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n      iVar8 = 1;\n      string_append(&temp,pcVar1);\n    }" { (expression_statement "iVar8 = 1;" (assignment_expression "iVar8 = 1" identifier = number_literal) ;) (expression_statement "string_append(&temp,pcVar1);" (call_expression "string_append(&temp,pcVar1)" identifier (argument_list "(&temp,pcVar1)" ( (pointer_expression "&temp" & identifier) , identifier ))) ;) })) }) (else_clause "else {\n    cVar5 = pcVar1[1];\n    if (cVar5 < '1') {\n      return 0;\n    }\n    if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar8 = 1;\n    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }\n  }" else (compound_statement "{\n    cVar5 = pcVar1[1];\n    if (cVar5 < '1') {\n      return 0;\n    }\n    if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar8 = 1;\n    pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }\n  }" { (expression_statement "cVar5 = pcVar1[1];" (assignment_expression "cVar5 = pcVar1[1]" identifier = (subscript_expression "pcVar1[1]" identifier [ number_literal ])) ;) (if_statement "if (cVar5 < '1') {\n      return 0;\n    }" if (parenthesized_expression "(cVar5 < '1')" ( (binary_expression "cVar5 < '1'" identifier < (char_literal "'1'" ' character ')) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if (cVar5 < ':') {\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }\n    else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" if (parenthesized_expression "(cVar5 < ':')" ( (binary_expression "cVar5 < ':'" identifier < (char_literal "':'" ' character ')) )) (compound_statement "{\n      num[1] = '\0';\n      num[0] = cVar5;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);\n      pcVar1 = *mangled;\n      if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }\n    }" { (expression_statement "num[1] = '\0';" (assignment_expression "num[1] = '\0'" (subscript_expression "num[1]" identifier [ number_literal ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "num[0] = cVar5;" (assignment_expression "num[0] = cVar5" (subscript_expression "num[0]" identifier [ number_literal ]) = identifier) ;) (expression_statement "iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10);" (assignment_expression "iVar2 = (*(code *)PTR_strtol_004c5c1c)(num,0,10)" identifier = (call_expression "(*(code *)PTR_strtol_004c5c1c)(num,0,10)" (parenthesized_expression "(*(code *)PTR_strtol_004c5c1c)" ( (pointer_expression "*(code *)PTR_strtol_004c5c1c" * (cast_expression "(code *)PTR_strtol_004c5c1c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(num,0,10)" ( identifier , number_literal , number_literal )))) ;) (expression_statement "pcVar1 = *mangled;" (assignment_expression "pcVar1 = *mangled" identifier = (pointer_expression "*mangled" * identifier)) ;) (if_statement "if (pcVar1[2] == '_') {\n        *mangled = pcVar1 + 3;\n      }\n      else {\n        *mangled = pcVar1 + 2;\n      }" if (parenthesized_expression "(pcVar1[2] == '_')" ( (binary_expression "pcVar1[2] == '_'" (subscript_expression "pcVar1[2]" identifier [ number_literal ]) == (char_literal "'_'" ' character ')) )) (compound_statement "{\n        *mangled = pcVar1 + 3;\n      }" { (expression_statement "*mangled = pcVar1 + 3;" (assignment_expression "*mangled = pcVar1 + 3" (pointer_expression "*mangled" * identifier) = (binary_expression "pcVar1 + 3" identifier + number_literal)) ;) }) (else_clause "else {\n        *mangled = pcVar1 + 2;\n      }" else (compound_statement "{\n        *mangled = pcVar1 + 2;\n      }" { (expression_statement "*mangled = pcVar1 + 2;" (assignment_expression "*mangled = pcVar1 + 2" (pointer_expression "*mangled" * identifier) = (binary_expression "pcVar1 + 2" identifier + number_literal)) ;) }))) }) (else_clause "else {\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" else (compound_statement "{\n      if (cVar5 != '_') {\n        return 0;\n      }\n      *mangled = pcVar1 + 1;\n      iVar2 = consume_count_with_underscores(mangled);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" { (if_statement "if (cVar5 != '_') {\n        return 0;\n      }" if (parenthesized_expression "(cVar5 != '_')" ( (binary_expression "cVar5 != '_'" identifier != (char_literal "'_'" ' character ')) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*mangled = pcVar1 + 1;" (assignment_expression "*mangled = pcVar1 + 1" (pointer_expression "*mangled" * identifier) = (binary_expression "pcVar1 + 1" identifier + number_literal)) ;) (expression_statement "iVar2 = consume_count_with_underscores(mangled);" (assignment_expression "iVar2 = consume_count_with_underscores(mangled)" identifier = (call_expression "consume_count_with_underscores(mangled)" identifier (argument_list "(mangled)" ( identifier )))) ;) (if_statement "if (iVar2 == -1) {\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == -1)" ( (binary_expression "iVar2 == -1" identifier == number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) }))) (expression_statement "iVar8 = 1;" (assignment_expression "iVar8 = 1" identifier = number_literal) ;) (expression_statement "pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c);" (assignment_expression "pcVar3 = (code *)(PTR_LAB_004c4fd8 + 0x439c)" identifier = (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x439c)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x439c)" ( (binary_expression "PTR_LAB_004c4fd8 + 0x439c" identifier + number_literal) )))) ;) (expression_statement "pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28);" (assignment_expression "pcVar4 = (code *)(PTR_LAB_004c4fd8 + 0x1f28)" identifier = (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x1f28)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x1f28)" ( (binary_expression "PTR_LAB_004c4fd8 + 0x1f28" identifier + number_literal) )))) ;) (for_statement "for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }" for ( ; (binary_expression "0 < iVar2" number_literal < identifier) ; (assignment_expression "iVar2 = iVar2 + -1" identifier = (binary_expression "iVar2 + -1" identifier + number_literal)) ) (compound_statement "{\n      pcVar6 = *mangled;\n      last_name.p = last_name.b;\n      cVar5 = *pcVar6;\n      pcVar1 = pcVar6;\n      if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }\n      if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }\n      if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }\n      if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }\n    }" { (expression_statement "pcVar6 = *mangled;" (assignment_expression "pcVar6 = *mangled" identifier = (pointer_expression "*mangled" * identifier)) ;) (expression_statement "last_name.p = last_name.b;" (assignment_expression "last_name.p = last_name.b" (field_expression "last_name.p" identifier . field_identifier) = (field_expression "last_name.b" identifier . field_identifier)) ;) (expression_statement "cVar5 = *pcVar6;" (assignment_expression "cVar5 = *pcVar6" identifier = (pointer_expression "*pcVar6" * identifier)) ;) (expression_statement "pcVar1 = pcVar6;" (assignment_expression "pcVar1 = pcVar6" identifier = identifier) ;) (if_statement "if (cVar5 == '_') {\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }" if (parenthesized_expression "(cVar5 == '_')" ( (binary_expression "cVar5 == '_'" identifier == (char_literal "'_'" ' character ')) )) (compound_statement "{\n        pcVar1 = pcVar6 + 1;\n        *mangled = pcVar1;\n        cVar5 = pcVar6[1];\n      }" { (expression_statement "pcVar1 = pcVar6 + 1;" (assignment_expression "pcVar1 = pcVar6 + 1" identifier = (binary_expression "pcVar6 + 1" identifier + number_literal)) ;) (expression_statement "*mangled = pcVar1;" (assignment_expression "*mangled = pcVar1" (pointer_expression "*mangled" * identifier) = identifier) ;) (expression_statement "cVar5 = pcVar6[1];" (assignment_expression "cVar5 = pcVar6[1]" identifier = (subscript_expression "pcVar6[1]" identifier [ number_literal ])) ;) })) (if_statement "if (cVar5 == 't') {\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }" if (parenthesized_expression "(cVar5 == 't')" ( (binary_expression "cVar5 == 't'" identifier == (char_literal "'t'" ' character ')) )) (compound_statement "{\n        iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);\n        if (iVar8 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar8 = 0;\n        break;\n      }" { (expression_statement "iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0);" (assignment_expression "iVar8 = demangle_template(work,mangled,&temp,&last_name,1,0)" identifier = (call_expression "demangle_template(work,mangled,&temp,&last_name,1,0)" identifier (argument_list "(work,mangled,&temp,&last_name,1,0)" ( identifier , identifier , (pointer_expression "&temp" & identifier) , (pointer_expression "&last_name" & identifier) , number_literal , number_literal )))) ;) (if_statement "if (iVar8 != 0) goto LAB_003174e0;" if (parenthesized_expression "(iVar8 != 0)" ( (binary_expression "iVar8 != 0" identifier != number_literal) )) (goto_statement "goto LAB_003174e0;" goto statement_identifier ;)) (labeled_statement "LAB_003176e8:\n        iVar8 = 0;" statement_identifier : (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" identifier = number_literal) ;)) (break_statement "break;" break ;) })) (if_statement "if (cVar5 == 'K') {\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }\n      else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }" if (parenthesized_expression "(cVar5 == 'K')" ( (binary_expression "cVar5 == 'K'" identifier == (char_literal "'K'" ' character ')) )) (compound_statement "{\n        *mangled = pcVar1 + 1;\n        iVar7 = consume_count_with_underscores(mangled);\n        if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;\n        pcVar1 = work->ktypevec[iVar7];\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }\n      }" { (expression_statement "*mangled = pcVar1 + 1;" (assignment_expression "*mangled = pcVar1 + 1" (pointer_expression "*mangled" * identifier) = (binary_expression "pcVar1 + 1" identifier + number_literal)) ;) (expression_statement "iVar7 = consume_count_with_underscores(mangled);" (assignment_expression "iVar7 = consume_count_with_underscores(mangled)" identifier = (call_expression "consume_count_with_underscores(mangled)" identifier (argument_list "(mangled)" ( identifier )))) ;) (if_statement "if ((iVar7 == -1) || (work->numk <= iVar7)) goto LAB_003176e8;" if (parenthesized_expression "((iVar7 == -1) || (work->numk <= iVar7))" ( (binary_expression "(iVar7 == -1) || (work->numk <= iVar7)" (parenthesized_expression "(iVar7 == -1)" ( (binary_expression "iVar7 == -1" identifier == number_literal) )) || (parenthesized_expression "(work->numk <= iVar7)" ( (binary_expression "work->numk <= iVar7" (field_expression "work->numk" identifier -> field_identifier) <= identifier) ))) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "pcVar1 = work->ktypevec[iVar7];" (assignment_expression "pcVar1 = work->ktypevec[iVar7]" identifier = (subscript_expression "work->ktypevec[iVar7]" (field_expression "work->ktypevec" identifier -> field_identifier) [ identifier ])) ;) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          string_append(&temp,pcVar1);\n        }" if (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" ( (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" ( (binary_expression "pcVar1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n          string_append(&temp,pcVar1);\n        }" { (expression_statement "string_append(&temp,pcVar1);" (call_expression "string_append(&temp,pcVar1)" identifier (argument_list "(&temp,pcVar1)" ( (pointer_expression "&temp" & identifier) , identifier ))) ;) })) }) (else_clause "else {\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }" else (compound_statement "{\n        if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }\nLAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }\n        remember_Ktype(work,temp.b,iVar7);\n      }" { (if_statement "if ((work->options & 0x2000U) == 0) {\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }\n        else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }" if (parenthesized_expression "((work->options & 0x2000U) == 0)" ( (binary_expression "(work->options & 0x2000U) == 0" (parenthesized_expression "(work->options & 0x2000U)" ( (binary_expression "work->options & 0x2000U" (field_expression "work->options" identifier -> field_identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n          if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }\n          last_name.b = last_name.p;\n          iVar8 = (*pcVar3)(work,mangled,&last_name);\n          if (iVar8 == 0) goto LAB_003176e8;\n          string_appends(&temp,&last_name,(string *)last_name.p);\n        }" { (if_statement "if (last_name.b != (char *)0x0) {\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }" if (parenthesized_expression "(last_name.b != (char *)0x0)" ( (binary_expression "last_name.b != (char *)0x0" (field_expression "last_name.b" identifier . field_identifier) != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            (*(code *)PTR_free_004c5c18)();\n            last_name.p = (char *)0x0;\n            last_name.e = (char *)0x0;\n          }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "last_name.p = (char *)0x0;" (assignment_expression "last_name.p = (char *)0x0" (field_expression "last_name.p" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "last_name.e = (char *)0x0;" (assignment_expression "last_name.e = (char *)0x0" (field_expression "last_name.e" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) })) (expression_statement "last_name.b = last_name.p;" (assignment_expression "last_name.b = last_name.p" (field_expression "last_name.b" identifier . field_identifier) = (field_expression "last_name.p" identifier . field_identifier)) ;) (expression_statement "iVar8 = (*pcVar3)(work,mangled,&last_name);" (assignment_expression "iVar8 = (*pcVar3)(work,mangled,&last_name)" identifier = (call_expression "(*pcVar3)(work,mangled,&last_name)" (parenthesized_expression "(*pcVar3)" ( (pointer_expression "*pcVar3" * identifier) )) (argument_list "(work,mangled,&last_name)" ( identifier , identifier , (pointer_expression "&last_name" & identifier) )))) ;) (if_statement "if (iVar8 == 0) goto LAB_003176e8;" if (parenthesized_expression "(iVar8 == 0)" ( (binary_expression "iVar8 == 0" identifier == number_literal) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "string_appends(&temp,&last_name,(string *)last_name.p);" (call_expression "string_appends(&temp,&last_name,(string *)last_name.p)" identifier (argument_list "(&temp,&last_name,(string *)last_name.p)" ( (pointer_expression "&temp" & identifier) , (pointer_expression "&last_name" & identifier) , (cast_expression "(string *)last_name.p" ( (type_descriptor "string *" type_identifier (abstract_pointer_declarator "*" *)) ) (field_expression "last_name.p" identifier . field_identifier)) ))) ;) }) (else_clause "else {\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }" else (compound_statement "{\n          iVar7 = (*pcVar4)(mangled);\n          if (iVar7 == -1) goto LAB_003176e8;\n          pcVar1 = (char *)xmalloc(iVar7 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);\n          options = work->options;\n          pcVar1[iVar7] = '\0';\n          pcVar6 = cplus_demangle(pcVar1,options);\n          if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }\n          (*(code *)PTR_free_004c5c18)(pcVar1);\n          *mangled = pcVar6 + iVar7;\n        }" { (expression_statement "iVar7 = (*pcVar4)(mangled);" (assignment_expression "iVar7 = (*pcVar4)(mangled)" identifier = (call_expression "(*pcVar4)(mangled)" (parenthesized_expression "(*pcVar4)" ( (pointer_expression "*pcVar4" * identifier) )) (argument_list "(mangled)" ( identifier )))) ;) (if_statement "if (iVar7 == -1) goto LAB_003176e8;" if (parenthesized_expression "(iVar7 == -1)" ( (binary_expression "iVar7 == -1" identifier == number_literal) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "pcVar1 = (char *)xmalloc(iVar7 + 1);" (assignment_expression "pcVar1 = (char *)xmalloc(iVar7 + 1)" identifier = (cast_expression "(char *)xmalloc(iVar7 + 1)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "xmalloc(iVar7 + 1)" identifier (argument_list "(iVar7 + 1)" ( (binary_expression "iVar7 + 1" identifier + number_literal) ))))) ;) (expression_statement "(*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7);" (call_expression "(*(code *)PTR_memcpy_004c5ba8)(pcVar1,*mangled,iVar7)" (parenthesized_expression "(*(code *)PTR_memcpy_004c5ba8)" ( (pointer_expression "*(code *)PTR_memcpy_004c5ba8" * (cast_expression "(code *)PTR_memcpy_004c5ba8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1,*mangled,iVar7)" ( identifier , (pointer_expression "*mangled" * identifier) , identifier ))) ;) (expression_statement "options = work->options;" (assignment_expression "options = work->options" identifier = (field_expression "work->options" identifier -> field_identifier)) ;) (expression_statement "pcVar1[iVar7] = '\0';" (assignment_expression "pcVar1[iVar7] = '\0'" (subscript_expression "pcVar1[iVar7]" identifier [ identifier ]) = (char_literal "'\0'" ' escape_sequence ')) ;) (expression_statement "pcVar6 = cplus_demangle(pcVar1,options);" (assignment_expression "pcVar6 = cplus_demangle(pcVar1,options)" identifier = (call_expression "cplus_demangle(pcVar1,options)" identifier (argument_list "(pcVar1,options)" ( identifier , identifier )))) ;) (if_statement "if (pcVar6 == (char *)0x0) {\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }\n          else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }" if (parenthesized_expression "(pcVar6 == (char *)0x0)" ( (binary_expression "pcVar6 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            pcVar6 = *mangled;\n            if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }\n          }" { (expression_statement "pcVar6 = *mangled;" (assignment_expression "pcVar6 = *mangled" identifier = (pointer_expression "*mangled" * identifier)) ;) (if_statement "if (iVar7 != 0) {\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }" if (parenthesized_expression "(iVar7 != 0)" ( (binary_expression "iVar7 != 0" identifier != number_literal) )) (compound_statement "{\n              string_appendn(&temp,pcVar6,iVar7);\n              pcVar6 = *mangled;\n            }" { (expression_statement "string_appendn(&temp,pcVar6,iVar7);" (call_expression "string_appendn(&temp,pcVar6,iVar7)" identifier (argument_list "(&temp,pcVar6,iVar7)" ( (pointer_expression "&temp" & identifier) , identifier , identifier ))) ;) (expression_statement "pcVar6 = *mangled;" (assignment_expression "pcVar6 = *mangled" identifier = (pointer_expression "*mangled" * identifier)) ;) })) }) (else_clause "else {\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }" else (compound_statement "{\n            if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar6);\n            pcVar6 = *mangled;\n          }" { (if_statement "if (*pcVar6 != '\0') {\n              string_append(&temp,pcVar6);\n            }" if (parenthesized_expression "(*pcVar6 != '\0')" ( (binary_expression "*pcVar6 != '\0'" (pointer_expression "*pcVar6" * identifier) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n              string_append(&temp,pcVar6);\n            }" { (expression_statement "string_append(&temp,pcVar6);" (call_expression "string_append(&temp,pcVar6)" identifier (argument_list "(&temp,pcVar6)" ( (pointer_expression "&temp" & identifier) , identifier ))) ;) })) (expression_statement "(*(code *)PTR_free_004c5c18)(pcVar6);" (call_expression "(*(code *)PTR_free_004c5c18)(pcVar6)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar6)" ( identifier ))) ;) (expression_statement "pcVar6 = *mangled;" (assignment_expression "pcVar6 = *mangled" identifier = (pointer_expression "*mangled" * identifier)) ;) }))) (expression_statement "(*(code *)PTR_free_004c5c18)(pcVar1);" (call_expression "(*(code *)PTR_free_004c5c18)(pcVar1)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "*mangled = pcVar6 + iVar7;" (assignment_expression "*mangled = pcVar6 + iVar7" (pointer_expression "*mangled" * identifier) = (binary_expression "pcVar6 + iVar7" identifier + identifier)) ;) }))) (labeled_statement "LAB_003174e0:\n        if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }" statement_identifier : (if_statement "if (temp.b == temp.p) {\n          iVar7 = 0;\n        }\n        else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }" if (parenthesized_expression "(temp.b == temp.p)" ( (binary_expression "temp.b == temp.p" (field_expression "temp.b" identifier . field_identifier) == (field_expression "temp.p" identifier . field_identifier)) )) (compound_statement "{\n          iVar7 = 0;\n        }" { (expression_statement "iVar7 = 0;" (assignment_expression "iVar7 = 0" identifier = number_literal) ;) }) (else_clause "else {\n          iVar7 = (int)temp.p - (int)temp.b;\n        }" else (compound_statement "{\n          iVar7 = (int)temp.p - (int)temp.b;\n        }" { (expression_statement "iVar7 = (int)temp.p - (int)temp.b;" (assignment_expression "iVar7 = (int)temp.p - (int)temp.b" identifier = (binary_expression "(int)temp.p - (int)temp.b" (cast_expression "(int)temp.p" ( (type_descriptor "int" primitive_type) ) (field_expression "temp.p" identifier . field_identifier)) - (cast_expression "(int)temp.b" ( (type_descriptor "int" primitive_type) ) (field_expression "temp.b" identifier . field_identifier)))) ;) })))) (expression_statement "remember_Ktype(work,temp.b,iVar7);" (call_expression "remember_Ktype(work,temp.b,iVar7)" identifier (argument_list "(work,temp.b,iVar7)" ( identifier , (field_expression "temp.b" identifier . field_identifier) , identifier ))) ;) }))) (if_statement "if (iVar2 != 1) {\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }" if (parenthesized_expression "(iVar2 != 1)" ( (binary_expression "iVar2 != 1" identifier != number_literal) )) (compound_statement "{\n        if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }\n        string_append(&temp,pcVar1);\n      }" { (if_statement "if ((work->options & 4U) == 0) {\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }" if (parenthesized_expression "((work->options & 4U) == 0)" ( (binary_expression "(work->options & 4U) == 0" (parenthesized_expression "(work->options & 4U)" ( (binary_expression "work->options & 4U" (field_expression "work->options" identifier -> field_identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n          pcVar1 = PTR_s__s_004c1a50 + 0x208;\n        }" { (expression_statement "pcVar1 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "pcVar1 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }" else (compound_statement "{\n          pcVar1 = PTR_UINT_004c12dc + -0x5450;\n        }" { (expression_statement "pcVar1 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "pcVar1 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "string_append(&temp,pcVar1);" (call_expression "string_append(&temp,pcVar1)" identifier (argument_list "(&temp,pcVar1)" ( (pointer_expression "&temp" & identifier) , identifier ))) ;) })) })) }))) (if_statement "if (temp.b == temp.p) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = (int)temp.p - (int)temp.b;\n  }" if (parenthesized_expression "(temp.b == temp.p)" ( (binary_expression "temp.b == temp.p" (field_expression "temp.b" identifier . field_identifier) == (field_expression "temp.p" identifier . field_identifier)) )) (compound_statement "{\n    iVar2 = 0;\n  }" { (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    iVar2 = (int)temp.p - (int)temp.b;\n  }" else (compound_statement "{\n    iVar2 = (int)temp.p - (int)temp.b;\n  }" { (expression_statement "iVar2 = (int)temp.p - (int)temp.b;" (assignment_expression "iVar2 = (int)temp.p - (int)temp.b" identifier = (binary_expression "(int)temp.p - (int)temp.b" (cast_expression "(int)temp.p" ( (type_descriptor "int" primitive_type) ) (field_expression "temp.p" identifier . field_identifier)) - (cast_expression "(int)temp.b" ( (type_descriptor "int" primitive_type) ) (field_expression "temp.b" identifier . field_identifier)))) ;) }))) (expression_statement "remember_Btype((work_stuff *)&work->btypevec,temp.b,iVar2,index);" (call_expression "remember_Btype((work_stuff *)&work->btypevec,temp.b,iVar2,index)" identifier (argument_list "((work_stuff *)&work->btypevec,temp.b,iVar2,index)" ( (cast_expression "(work_stuff *)&work->btypevec" ( (type_descriptor "work_stuff *" type_identifier (abstract_pointer_declarator "*" *)) ) (pointer_expression "&work->btypevec" & (field_expression "work->btypevec" identifier -> field_identifier))) , (field_expression "temp.b" identifier . field_identifier) , identifier , identifier ))) ;) (if_statement "if (local_resc != 0) {\n    if ((work->options & 4U) == 0) {\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }\n    string_append(&temp,pcVar1);\n    if ((work->destructor & 1U) != 0) {\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    string_appends(&temp,&last_name,(string *)last_name.p);\n  }" if (parenthesized_expression "(local_resc != 0)" ( (binary_expression "local_resc != 0" identifier != number_literal) )) (compound_statement "{\n    if ((work->options & 4U) == 0) {\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }\n    string_append(&temp,pcVar1);\n    if ((work->destructor & 1U) != 0) {\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    string_appends(&temp,&last_name,(string *)last_name.p);\n  }" { (if_statement "if ((work->options & 4U) == 0) {\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }" if (parenthesized_expression "((work->options & 4U) == 0)" ( (binary_expression "(work->options & 4U) == 0" (parenthesized_expression "(work->options & 4U)" ( (binary_expression "work->options & 4U" (field_expression "work->options" identifier -> field_identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n      pcVar1 = PTR_s__s_004c1a50 + 0x208;\n    }" { (expression_statement "pcVar1 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "pcVar1 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }" else (compound_statement "{\n      pcVar1 = PTR_UINT_004c12dc + -0x5450;\n    }" { (expression_statement "pcVar1 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "pcVar1 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "string_append(&temp,pcVar1);" (call_expression "string_append(&temp,pcVar1)" identifier (argument_list "(&temp,pcVar1)" ( (pointer_expression "&temp" & identifier) , identifier ))) ;) (if_statement "if ((work->destructor & 1U) != 0) {\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" if (parenthesized_expression "((work->destructor & 1U) != 0)" ( (binary_expression "(work->destructor & 1U) != 0" (parenthesized_expression "(work->destructor & 1U)" ( (binary_expression "work->destructor & 1U" (field_expression "work->destructor" identifier -> field_identifier) & number_literal) )) != number_literal) )) (compound_statement "{\n      string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" { (expression_statement "string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4);" (call_expression "string_append(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4)" identifier (argument_list "(&temp,PTR_s_in_a_linker_script_004c191c + 0x78e4)" ( (pointer_expression "&temp" & identifier) , (binary_expression "PTR_s_in_a_linker_script_004c191c + 0x78e4" identifier + number_literal) ))) ;) })) (expression_statement "string_appends(&temp,&last_name,(string *)last_name.p);" (call_expression "string_appends(&temp,&last_name,(string *)last_name.p)" identifier (argument_list "(&temp,&last_name,(string *)last_name.p)" ( (pointer_expression "&temp" & identifier) , (pointer_expression "&last_name" & identifier) , (cast_expression "(string *)last_name.p" ( (type_descriptor "string *" type_identifier (abstract_pointer_declarator "*" *)) ) (field_expression "last_name.p" identifier . field_identifier)) ))) ;) })) (if_statement "if (append == 0) {\n    if (result->b != result->p) {\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }\n    if (temp.b != temp.p) {\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }\n  }\n  else {\n    string_appends(result,&temp,(string *)temp.p);\n  }" if (parenthesized_expression "(append == 0)" ( (binary_expression "append == 0" identifier == number_literal) )) (compound_statement "{\n    if (result->b != result->p) {\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }\n    if (temp.b != temp.p) {\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }\n  }" { (if_statement "if (result->b != result->p) {\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }" if (parenthesized_expression "(result->b != result->p)" ( (binary_expression "result->b != result->p" (field_expression "result->b" identifier -> field_identifier) != (field_expression "result->p" identifier -> field_identifier)) )) (compound_statement "{\n      if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }\n      string_append(&temp,pcVar1);\n    }" { (if_statement "if ((work->options & 4U) == 0) {\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }" if (parenthesized_expression "((work->options & 4U) == 0)" ( (binary_expression "(work->options & 4U) == 0" (parenthesized_expression "(work->options & 4U)" ( (binary_expression "work->options & 4U" (field_expression "work->options" identifier -> field_identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n        pcVar1 = PTR_s__s_004c1a50 + 0x208;\n      }" { (expression_statement "pcVar1 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "pcVar1 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }" else (compound_statement "{\n        pcVar1 = PTR_UINT_004c12dc + -0x5450;\n      }" { (expression_statement "pcVar1 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "pcVar1 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "string_append(&temp,pcVar1);" (call_expression "string_append(&temp,pcVar1)" identifier (argument_list "(&temp,pcVar1)" ( (pointer_expression "&temp" & identifier) , identifier ))) ;) })) (if_statement "if (temp.b != temp.p) {\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }" if (parenthesized_expression "(temp.b != temp.p)" ( (binary_expression "temp.b != temp.p" (field_expression "temp.b" identifier . field_identifier) != (field_expression "temp.p" identifier . field_identifier)) )) (compound_statement "{\n      string_prependn(result,temp.b,(int)temp.p - (int)temp.b);\n    }" { (expression_statement "string_prependn(result,temp.b,(int)temp.p - (int)temp.b);" (call_expression "string_prependn(result,temp.b,(int)temp.p - (int)temp.b)" identifier (argument_list "(result,temp.b,(int)temp.p - (int)temp.b)" ( identifier , (field_expression "temp.b" identifier . field_identifier) , (binary_expression "(int)temp.p - (int)temp.b" (cast_expression "(int)temp.p" ( (type_descriptor "int" primitive_type) ) (field_expression "temp.p" identifier . field_identifier)) - (cast_expression "(int)temp.b" ( (type_descriptor "int" primitive_type) ) (field_expression "temp.b" identifier . field_identifier))) ))) ;) })) }) (else_clause "else {\n    string_appends(result,&temp,(string *)temp.p);\n  }" else (compound_statement "{\n    string_appends(result,&temp,(string *)temp.p);\n  }" { (expression_statement "string_appends(result,&temp,(string *)temp.p);" (call_expression "string_appends(result,&temp,(string *)temp.p)" identifier (argument_list "(result,&temp,(string *)temp.p)" ( identifier , (pointer_expression "&temp" & identifier) , (cast_expression "(string *)temp.p" ( (type_descriptor "string *" type_identifier (abstract_pointer_declarator "*" *)) ) (field_expression "temp.p" identifier . field_identifier)) ))) ;) }))) (if_statement "if (last_name.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    last_name.p = (char *)0x0;\n    last_name.e = (char *)0x0;\n    last_name.b = (char *)0x0;\n  }" if (parenthesized_expression "(last_name.b != (char *)0x0)" ( (binary_expression "last_name.b != (char *)0x0" (field_expression "last_name.b" identifier . field_identifier) != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    last_name.p = (char *)0x0;\n    last_name.e = (char *)0x0;\n    last_name.b = (char *)0x0;\n  }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "last_name.p = (char *)0x0;" (assignment_expression "last_name.p = (char *)0x0" (field_expression "last_name.p" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "last_name.e = (char *)0x0;" (assignment_expression "last_name.e = (char *)0x0" (field_expression "last_name.e" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) (expression_statement "last_name.b = (char *)0x0;" (assignment_expression "last_name.b = (char *)0x0" (field_expression "last_name.b" identifier . field_identifier) = (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) ;) })) (if_statement "if (temp.b != (char *)0x0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar8;\n  }" if (parenthesized_expression "(temp.b != (char *)0x0)" ( (binary_expression "temp.b != (char *)0x0" (field_expression "temp.b" identifier . field_identifier) != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    return iVar8;\n  }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (return_statement "return iVar8;" return identifier ;) })) (return_statement "return iVar8;" return identifier ;) })))
(translation_unit "int FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)\n\n{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}\n\n" (function_definition "int FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)\n\n{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}" primitive_type (function_declarator "FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)" identifier (parameter_list "(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)" ( (parameter_declaration "uint *param_1" type_identifier (pointer_declarator "*param_1" * identifier)) , (parameter_declaration "int *param_2" primitive_type (pointer_declarator "*param_2" * identifier)) , (parameter_declaration "int *param_3" primitive_type (pointer_declarator "*param_3" * identifier)) , (parameter_declaration "uint param_4" type_identifier identifier) , (parameter_declaration "int param_5" primitive_type identifier) ))) (compound_statement "{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}" { (declaration "char *pcVar1;" primitive_type (pointer_declarator "*pcVar1" * identifier) ;) (declaration "int iVar2;" primitive_type identifier ;) (declaration "char cVar4;" primitive_type identifier ;) (declaration "int iVar3;" primitive_type identifier ;) (declaration "char *pcVar5;" primitive_type (pointer_declarator "*pcVar5" * identifier) ;) (declaration "undefined *puVar6;" type_identifier (pointer_declarator "*puVar6" * identifier) ;) (declaration "uint uVar7;" type_identifier identifier ;) (declaration "int iVar8;" primitive_type identifier ;) (declaration "int iVar9;" primitive_type identifier ;) (declaration "int iVar10;" primitive_type identifier ;) (declaration "uint local_resc;" type_identifier identifier ;) (declaration "int local_60;" primitive_type identifier ;) (declaration "int local_5c;" primitive_type identifier ;) (declaration "undefined4 local_58;" type_identifier identifier ;) (declaration "int local_54;" primitive_type identifier ;) (declaration "int local_50;" primitive_type identifier ;) (declaration "undefined4 local_4c;" type_identifier identifier ;) (declaration "char local_48 [8];" primitive_type (array_declarator "local_48 [8]" identifier [ number_literal ]) ;) (declaration "code *local_40;" type_identifier (pointer_declarator "*local_40" * identifier) ;) (declaration "code *local_3c;" type_identifier (pointer_declarator "*local_3c" * identifier) ;) (declaration "char *local_38;" primitive_type (pointer_declarator "*local_38" * identifier) ;) (declaration "undefined4 local_34;" type_identifier identifier ;) (declaration "undefined *local_30;" type_identifier (pointer_declarator "*local_30" * identifier) ;) (expression_statement "local_34 = FUN_00311bac();" (assignment_expression "local_34 = FUN_00311bac()" identifier = (call_expression "FUN_00311bac()" identifier (argument_list "()" ( )))) ;) (expression_statement "local_resc = param_4;" (assignment_expression "local_resc = param_4" identifier = identifier) ;) (if_statement "if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }" if (parenthesized_expression "((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0))" ( (binary_expression "(param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)" (parenthesized_expression "(param_4 != 0)" ( (binary_expression "param_4 != 0" identifier != number_literal) )) && (parenthesized_expression "(local_resc = param_1[10] & 1, local_resc == 0)" ( (comma_expression "local_resc = param_1[10] & 1, local_resc == 0" (assignment_expression "local_resc = param_1[10] & 1" identifier = (binary_expression "param_1[10] & 1" (subscript_expression "param_1[10]" identifier [ number_literal ]) & number_literal)) , (binary_expression "local_resc == 0" identifier == number_literal)) ))) )) (compound_statement "{\n    local_resc = param_1[0xb] & 1;\n  }" { (expression_statement "local_resc = param_1[0xb] & 1;" (assignment_expression "local_resc = param_1[0xb] & 1" identifier = (binary_expression "param_1[0xb] & 1" (subscript_expression "param_1[0xb]" identifier [ number_literal ]) & number_literal)) ;) })) (expression_statement "pcVar1 = (char *)*param_2;" (assignment_expression "pcVar1 = (char *)*param_2" identifier = (cast_expression "(char *)*param_2" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) ;) (expression_statement "local_4c = 0;" (assignment_expression "local_4c = 0" identifier = number_literal) ;) (expression_statement "local_50 = 0;" (assignment_expression "local_50 = 0" identifier = number_literal) ;) (expression_statement "local_54 = 0;" (assignment_expression "local_54 = 0" identifier = number_literal) ;) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" identifier = number_literal) ;) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" identifier = number_literal) ;) (expression_statement "local_60 = 0;" (assignment_expression "local_60 = 0" identifier = number_literal) ;) (if_statement "if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" if (parenthesized_expression "(*pcVar1 == 'K')" ( (binary_expression "*pcVar1 == 'K'" (pointer_expression "*pcVar1" * identifier) == (char_literal "'K'" ' character ')) )) (compound_statement "{\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }" { (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(pcVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar1 + 1)" ( (binary_expression "pcVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "iVar9 = FUN_00312010(param_2);" (assignment_expression "iVar9 = FUN_00312010(param_2)" identifier = (call_expression "FUN_00312010(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar9 == -1) {\n      return 0;\n    }" if (parenthesized_expression "(iVar9 == -1)" ( (binary_expression "iVar9 == -1" identifier == number_literal) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }" if (parenthesized_expression "((int)param_1[4] <= iVar9)" ( (binary_expression "(int)param_1[4] <= iVar9" (cast_expression "(int)param_1[4]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "param_1[4]" identifier [ number_literal ])) <= identifier) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "pcVar1 = *(char **)(param_1[2] + iVar9 * 4);" (assignment_expression "pcVar1 = *(char **)(param_1[2] + iVar9 * 4)" identifier = (pointer_expression "*(char **)(param_1[2] + iVar9 * 4)" * (cast_expression "(char **)(param_1[2] + iVar9 * 4)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1[2] + iVar9 * 4)" ( (binary_expression "param_1[2] + iVar9 * 4" (subscript_expression "param_1[2]" identifier [ number_literal ]) + (binary_expression "iVar9 * 4" identifier * number_literal)) ))))) ;) (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" identifier = number_literal) ;) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }" if (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" ( (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" ( (binary_expression "pcVar1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }" { (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" identifier = number_literal) ;) (expression_statement "FUN_00312594(&local_54);" (call_expression "FUN_00312594(&local_54)" identifier (argument_list "(&local_54)" ( (pointer_expression "&local_54" & identifier) ))) ;) })) }) (else_clause "else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" else (compound_statement "{\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" { (expression_statement "cVar4 = pcVar1[1];" (assignment_expression "cVar4 = pcVar1[1]" identifier = (subscript_expression "pcVar1[1]" identifier [ number_literal ])) ;) (if_statement "if (cVar4 < '1') {\n      return 0;\n    }" if (parenthesized_expression "(cVar4 < '1')" ( (binary_expression "cVar4 < '1'" identifier < (char_literal "'1'" ' character ')) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" if (parenthesized_expression "(cVar4 < ':')" ( (binary_expression "cVar4 < ':'" identifier < (char_literal "':'" ' character ')) )) (compound_statement "{\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }" { (expression_statement "local_48[1] = 0;" (assignment_expression "local_48[1] = 0" (subscript_expression "local_48[1]" identifier [ number_literal ]) = number_literal) ;) (expression_statement "local_48[0] = cVar4;" (assignment_expression "local_48[0] = cVar4" (subscript_expression "local_48[0]" identifier [ number_literal ]) = identifier) ;) (expression_statement "iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);" (assignment_expression "iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10)" identifier = (call_expression "(*(code *)PTR_strtol_004c5c1c)(local_48,0,10)" (parenthesized_expression "(*(code *)PTR_strtol_004c5c1c)" ( (pointer_expression "*(code *)PTR_strtol_004c5c1c" * (cast_expression "(code *)PTR_strtol_004c5c1c" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(local_48,0,10)" ( identifier , number_literal , number_literal )))) ;) (expression_statement "iVar9 = *param_2;" (assignment_expression "iVar9 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (if_statement "if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }" if (parenthesized_expression "(*(char *)(iVar9 + 2) == '_')" ( (binary_expression "*(char *)(iVar9 + 2) == '_'" (pointer_expression "*(char *)(iVar9 + 2)" * (cast_expression "(char *)(iVar9 + 2)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar9 + 2)" ( (binary_expression "iVar9 + 2" identifier + number_literal) )))) == (char_literal "'_'" ' character ')) )) (compound_statement "{\n        *param_2 = iVar9 + 3;\n      }" { (expression_statement "*param_2 = iVar9 + 3;" (assignment_expression "*param_2 = iVar9 + 3" (pointer_expression "*param_2" * identifier) = (binary_expression "iVar9 + 3" identifier + number_literal)) ;) }) (else_clause "else {\n        *param_2 = iVar9 + 2;\n      }" else (compound_statement "{\n        *param_2 = iVar9 + 2;\n      }" { (expression_statement "*param_2 = iVar9 + 2;" (assignment_expression "*param_2 = iVar9 + 2" (pointer_expression "*param_2" * identifier) = (binary_expression "iVar9 + 2" identifier + number_literal)) ;) }))) }) (else_clause "else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" else (compound_statement "{\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" { (if_statement "if (cVar4 != '_') {\n        return 0;\n      }" if (parenthesized_expression "(cVar4 != '_')" ( (binary_expression "cVar4 != '_'" identifier != (char_literal "'_'" ' character ')) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(pcVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar1 + 1)" ( (binary_expression "pcVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "iVar2 = FUN_00312010(param_2);" (assignment_expression "iVar2 = FUN_00312010(param_2)" identifier = (call_expression "FUN_00312010(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar2 == -1) {\n        return 0;\n      }" if (parenthesized_expression "(iVar2 == -1)" ( (binary_expression "iVar2 == -1" identifier == number_literal) )) (compound_statement "{\n        return 0;\n      }" { (return_statement "return 0;" return number_literal ;) })) }))) (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" identifier = number_literal) ;) (expression_statement "local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);" (assignment_expression "local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c)" identifier = (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x439c)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x439c)" ( (binary_expression "PTR_LAB_004c4fd8 + 0x439c" identifier + number_literal) )))) ;) (expression_statement "local_30 = PTR_LAB_004c4fd8;" (assignment_expression "local_30 = PTR_LAB_004c4fd8" identifier = identifier) ;) (expression_statement "local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);" (assignment_expression "local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28)" identifier = (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x1f28)" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x1f28)" ( (binary_expression "PTR_LAB_004c4fd8 + 0x1f28" identifier + number_literal) )))) ;) (for_statement "for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }" for ( ; (binary_expression "0 < iVar2" number_literal < identifier) ; (assignment_expression "iVar2 = iVar2 + -1" identifier = (binary_expression "iVar2 + -1" identifier + number_literal)) ) (compound_statement "{\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }" { (expression_statement "pcVar5 = (char *)*param_2;" (assignment_expression "pcVar5 = (char *)*param_2" identifier = (cast_expression "(char *)*param_2" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (pointer_expression "*param_2" * identifier))) ;) (expression_statement "local_5c = local_60;" (assignment_expression "local_5c = local_60" identifier = identifier) ;) (expression_statement "cVar4 = *pcVar5;" (assignment_expression "cVar4 = *pcVar5" identifier = (pointer_expression "*pcVar5" * identifier)) ;) (expression_statement "pcVar1 = pcVar5;" (assignment_expression "pcVar1 = pcVar5" identifier = identifier) ;) (if_statement "if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }" if (parenthesized_expression "(cVar4 == '_')" ( (binary_expression "cVar4 == '_'" identifier == (char_literal "'_'" ' character ')) )) (compound_statement "{\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }" { (expression_statement "pcVar1 = pcVar5 + 1;" (assignment_expression "pcVar1 = pcVar5 + 1" identifier = (binary_expression "pcVar5 + 1" identifier + number_literal)) ;) (expression_statement "*param_2 = (int)pcVar1;" (assignment_expression "*param_2 = (int)pcVar1" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)pcVar1" ( (type_descriptor "int" primitive_type) ) identifier)) ;) (expression_statement "cVar4 = pcVar5[1];" (assignment_expression "cVar4 = pcVar5[1]" identifier = (subscript_expression "pcVar5[1]" identifier [ number_literal ])) ;) })) (if_statement "if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }" if (parenthesized_expression "(cVar4 == 't')" ( (binary_expression "cVar4 == 't'" identifier == (char_literal "'t'" ' character ')) )) (compound_statement "{\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }" { (expression_statement "iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);" (assignment_expression "iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0)" identifier = (call_expression "FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0)" identifier (argument_list "(param_1,param_2,&local_54,&local_60,1,0)" ( identifier , identifier , (pointer_expression "&local_54" & identifier) , (pointer_expression "&local_60" & identifier) , number_literal , number_literal )))) ;) (if_statement "if (iVar9 != 0) goto LAB_003174e0;" if (parenthesized_expression "(iVar9 != 0)" ( (binary_expression "iVar9 != 0" identifier != number_literal) )) (goto_statement "goto LAB_003174e0;" goto statement_identifier ;)) (labeled_statement "LAB_003176e8:\n        iVar9 = 0;" statement_identifier : (expression_statement "iVar9 = 0;" (assignment_expression "iVar9 = 0" identifier = number_literal) ;)) (break_statement "break;" break ;) })) (if_statement "if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" if (parenthesized_expression "(cVar4 == 'K')" ( (binary_expression "cVar4 == 'K'" identifier == (char_literal "'K'" ' character ')) )) (compound_statement "{\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }" { (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" * identifier) = (cast_expression "(int)(pcVar1 + 1)" ( (type_descriptor "int" primitive_type) ) (parenthesized_expression "(pcVar1 + 1)" ( (binary_expression "pcVar1 + 1" identifier + number_literal) )))) ;) (expression_statement "iVar8 = FUN_00312010(param_2);" (assignment_expression "iVar8 = FUN_00312010(param_2)" identifier = (call_expression "FUN_00312010(param_2)" identifier (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;" if (parenthesized_expression "((iVar8 == -1) || ((int)param_1[4] <= iVar8))" ( (binary_expression "(iVar8 == -1) || ((int)param_1[4] <= iVar8)" (parenthesized_expression "(iVar8 == -1)" ( (binary_expression "iVar8 == -1" identifier == number_literal) )) || (parenthesized_expression "((int)param_1[4] <= iVar8)" ( (binary_expression "(int)param_1[4] <= iVar8" (cast_expression "(int)param_1[4]" ( (type_descriptor "int" primitive_type) ) (subscript_expression "param_1[4]" identifier [ number_literal ])) <= identifier) ))) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "pcVar1 = *(char **)(param_1[2] + iVar8 * 4);" (assignment_expression "pcVar1 = *(char **)(param_1[2] + iVar8 * 4)" identifier = (pointer_expression "*(char **)(param_1[2] + iVar8 * 4)" * (cast_expression "(char **)(param_1[2] + iVar8 * 4)" ( (type_descriptor "char **" primitive_type (abstract_pointer_declarator "**" * (abstract_pointer_declarator "*" *))) ) (parenthesized_expression "(param_1[2] + iVar8 * 4)" ( (binary_expression "param_1[2] + iVar8 * 4" (subscript_expression "param_1[2]" identifier [ number_literal ]) + (binary_expression "iVar8 * 4" identifier * number_literal)) ))))) ;) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }" if (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" ( (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" ( (binary_expression "pcVar1 != (char *)0x0" identifier != (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) && (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) ))) )) (compound_statement "{\n          FUN_00312594(&local_54);\n        }" { (expression_statement "FUN_00312594(&local_54);" (call_expression "FUN_00312594(&local_54)" identifier (argument_list "(&local_54)" ( (pointer_expression "&local_54" & identifier) ))) ;) })) }) (else_clause "else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" else (compound_statement "{\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" { (if_statement "if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" if (parenthesized_expression "((*param_1 & 0x2000) == 0)" ( (binary_expression "(*param_1 & 0x2000) == 0" (parenthesized_expression "(*param_1 & 0x2000)" ( (binary_expression "*param_1 & 0x2000" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }" { (if_statement "if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }" if (parenthesized_expression "(local_60 != 0)" ( (binary_expression "local_60 != 0" identifier != number_literal) )) (compound_statement "{\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" identifier = number_literal) ;) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" identifier = number_literal) ;) })) (expression_statement "local_60 = local_5c;" (assignment_expression "local_60 = local_5c" identifier = identifier) ;) (expression_statement "iVar9 = (*local_40)(param_1,param_2,&local_60);" (assignment_expression "iVar9 = (*local_40)(param_1,param_2,&local_60)" identifier = (call_expression "(*local_40)(param_1,param_2,&local_60)" (parenthesized_expression "(*local_40)" ( (pointer_expression "*local_40" * identifier) )) (argument_list "(param_1,param_2,&local_60)" ( identifier , identifier , (pointer_expression "&local_60" & identifier) )))) ;) (if_statement "if (iVar9 == 0) goto LAB_003176e8;" if (parenthesized_expression "(iVar9 == 0)" ( (binary_expression "iVar9 == 0" identifier == number_literal) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "FUN_003127e8(&local_54,&local_60,local_5c);" (call_expression "FUN_003127e8(&local_54,&local_60,local_5c)" identifier (argument_list "(&local_54,&local_60,local_5c)" ( (pointer_expression "&local_54" & identifier) , (pointer_expression "&local_60" & identifier) , identifier ))) ;) }) (else_clause "else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" else (compound_statement "{\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" { (expression_statement "iVar8 = (*local_3c)(param_2);" (assignment_expression "iVar8 = (*local_3c)(param_2)" identifier = (call_expression "(*local_3c)(param_2)" (parenthesized_expression "(*local_3c)" ( (pointer_expression "*local_3c" * identifier) )) (argument_list "(param_2)" ( identifier )))) ;) (if_statement "if (iVar8 == -1) goto LAB_003176e8;" if (parenthesized_expression "(iVar8 == -1)" ( (binary_expression "iVar8 == -1" identifier == number_literal) )) (goto_statement "goto LAB_003176e8;" goto statement_identifier ;)) (expression_statement "iVar3 = xmalloc(iVar8 + 1);" (assignment_expression "iVar3 = xmalloc(iVar8 + 1)" identifier = (call_expression "xmalloc(iVar8 + 1)" identifier (argument_list "(iVar8 + 1)" ( (binary_expression "iVar8 + 1" identifier + number_literal) )))) ;) (expression_statement "(*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);" (call_expression "(*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8)" (parenthesized_expression "(*(code *)PTR_memcpy_004c5ba8)" ( (pointer_expression "*(code *)PTR_memcpy_004c5ba8" * (cast_expression "(code *)PTR_memcpy_004c5ba8" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar3,*param_2,iVar8)" ( identifier , (pointer_expression "*param_2" * identifier) , identifier ))) ;) (expression_statement "uVar7 = *param_1;" (assignment_expression "uVar7 = *param_1" identifier = (pointer_expression "*param_1" * identifier)) ;) (expression_statement "*(undefined1 *)(iVar3 + iVar8) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar8) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar8)" * (cast_expression "(undefined1 *)(iVar3 + iVar8)" ( (type_descriptor "undefined1 *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(iVar3 + iVar8)" ( (binary_expression "iVar3 + iVar8" identifier + identifier) )))) = number_literal) ;) (expression_statement "pcVar1 = (char *)cplus_demangle(iVar3,uVar7);" (assignment_expression "pcVar1 = (char *)cplus_demangle(iVar3,uVar7)" identifier = (cast_expression "(char *)cplus_demangle(iVar3,uVar7)" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) (call_expression "cplus_demangle(iVar3,uVar7)" identifier (argument_list "(iVar3,uVar7)" ( identifier , identifier ))))) ;) (if_statement "if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" if (parenthesized_expression "(pcVar1 == (char *)0x0)" ( (binary_expression "pcVar1 == (char *)0x0" identifier == (cast_expression "(char *)0x0" ( (type_descriptor "char *" primitive_type (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }" { (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) (if_statement "if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }" if (parenthesized_expression "(iVar8 != 0)" ( (binary_expression "iVar8 != 0" identifier != number_literal) )) (compound_statement "{\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }" { (expression_statement "FUN_003123f4(&local_54,iVar10,iVar8);" (call_expression "FUN_003123f4(&local_54,iVar10,iVar8)" identifier (argument_list "(&local_54,iVar10,iVar8)" ( (pointer_expression "&local_54" & identifier) , identifier , identifier ))) ;) (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) })) }) (else_clause "else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" else (compound_statement "{\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" { (if_statement "if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }" if (parenthesized_expression "(*pcVar1 != '\0')" ( (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" * identifier) != (char_literal "'\0'" ' escape_sequence ')) )) (compound_statement "{\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }" { (expression_statement "local_38 = pcVar1;" (assignment_expression "local_38 = pcVar1" identifier = identifier) ;) (expression_statement "FUN_00312594(&local_54,pcVar1);" (call_expression "FUN_00312594(&local_54,pcVar1)" identifier (argument_list "(&local_54,pcVar1)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) (expression_statement "pcVar1 = local_38;" (assignment_expression "pcVar1 = local_38" identifier = identifier) ;) })) (expression_statement "(*(code *)PTR_free_004c5c18)(pcVar1);" (call_expression "(*(code *)PTR_free_004c5c18)(pcVar1)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(pcVar1)" ( identifier ))) ;) (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" identifier = (pointer_expression "*param_2" * identifier)) ;) }))) (expression_statement "(*(code *)PTR_free_004c5c18)(iVar3);" (call_expression "(*(code *)PTR_free_004c5c18)(iVar3)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "(iVar3)" ( identifier ))) ;) (expression_statement "*param_2 = iVar10 + iVar8;" (assignment_expression "*param_2 = iVar10 + iVar8" (pointer_expression "*param_2" * identifier) = (binary_expression "iVar10 + iVar8" identifier + identifier)) ;) }))) (labeled_statement "LAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }" statement_identifier : (if_statement "if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }" if (parenthesized_expression "(local_54 == local_50)" ( (binary_expression "local_54 == local_50" identifier == identifier) )) (compound_statement "{\n          iVar8 = 0;\n        }" { (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" identifier = number_literal) ;) }) (else_clause "else {\n          iVar8 = local_50 - local_54;\n        }" else (compound_statement "{\n          iVar8 = local_50 - local_54;\n        }" { (expression_statement "iVar8 = local_50 - local_54;" (assignment_expression "iVar8 = local_50 - local_54" identifier = (binary_expression "local_50 - local_54" identifier - identifier)) ;) })))) (expression_statement "FUN_00311cb4(param_1,local_54,iVar8);" (call_expression "FUN_00311cb4(param_1,local_54,iVar8)" identifier (argument_list "(param_1,local_54,iVar8)" ( identifier , identifier , identifier ))) ;) }))) (if_statement "if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }" if (parenthesized_expression "(iVar2 != 1)" ( (binary_expression "iVar2 != 1" identifier != number_literal) )) (compound_statement "{\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }" { (if_statement "if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" if (parenthesized_expression "((*param_1 & 4) == 0)" ( (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" ( (binary_expression "*param_1 & 4" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }" { (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" else (compound_statement "{\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" { (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" identifier (argument_list "(&local_54,puVar6)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) })) })) }))) (if_statement "if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }" if (parenthesized_expression "(local_54 == local_50)" ( (binary_expression "local_54 == local_50" identifier == identifier) )) (compound_statement "{\n    iVar2 = 0;\n  }" { (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" identifier = number_literal) ;) }) (else_clause "else {\n    iVar2 = local_50 - local_54;\n  }" else (compound_statement "{\n    iVar2 = local_50 - local_54;\n  }" { (expression_statement "iVar2 = local_50 - local_54;" (assignment_expression "iVar2 = local_50 - local_54" identifier = (binary_expression "local_50 - local_54" identifier - identifier)) ;) }))) (expression_statement "FUN_00312278(param_1 + 3,local_54,iVar2,local_34);" (call_expression "FUN_00312278(param_1 + 3,local_54,iVar2,local_34)" identifier (argument_list "(param_1 + 3,local_54,iVar2,local_34)" ( (binary_expression "param_1 + 3" identifier + number_literal) , identifier , identifier , identifier ))) ;) (if_statement "if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }" if (parenthesized_expression "(local_resc != 0)" ( (binary_expression "local_resc != 0" identifier != number_literal) )) (compound_statement "{\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }" { (if_statement "if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" if (parenthesized_expression "((*param_1 & 4) == 0)" ( (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" ( (binary_expression "*param_1 & 4" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }" { (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" else (compound_statement "{\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" { (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" identifier (argument_list "(&local_54,puVar6)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) (if_statement "if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" if (parenthesized_expression "((param_1[0xb] & 1) != 0)" ( (binary_expression "(param_1[0xb] & 1) != 0" (parenthesized_expression "(param_1[0xb] & 1)" ( (binary_expression "param_1[0xb] & 1" (subscript_expression "param_1[0xb]" identifier [ number_literal ]) & number_literal) )) != number_literal) )) (compound_statement "{\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" { (expression_statement "FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);" (call_expression "FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4)" identifier (argument_list "(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4)" ( (pointer_expression "&local_54" & identifier) , (binary_expression "PTR_s_in_a_linker_script_004c191c + 0x78e4" identifier + number_literal) ))) ;) })) (expression_statement "FUN_003127e8(&local_54,&local_60,local_5c);" (call_expression "FUN_003127e8(&local_54,&local_60,local_5c)" identifier (argument_list "(&local_54,&local_60,local_5c)" ( (pointer_expression "&local_54" & identifier) , (pointer_expression "&local_60" & identifier) , identifier ))) ;) })) (if_statement "if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" if (parenthesized_expression "(param_5 == 0)" ( (binary_expression "param_5 == 0" identifier == number_literal) )) (compound_statement "{\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }" { (if_statement "if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }" if (parenthesized_expression "(*param_3 != param_3[1])" ( (binary_expression "*param_3 != param_3[1]" (pointer_expression "*param_3" * identifier) != (subscript_expression "param_3[1]" identifier [ number_literal ])) )) (compound_statement "{\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }" { (if_statement "if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" if (parenthesized_expression "((*param_1 & 4) == 0)" ( (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" ( (binary_expression "*param_1 & 4" (pointer_expression "*param_1" * identifier) & number_literal) )) == number_literal) )) (compound_statement "{\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }" { (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" identifier = (binary_expression "PTR_s__s_004c1a50 + 0x208" identifier + number_literal)) ;) }) (else_clause "else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" else (compound_statement "{\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" { (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" identifier = (binary_expression "PTR_UINT_004c12dc + -0x5450" identifier + number_literal)) ;) }))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" identifier (argument_list "(&local_54,puVar6)" ( (pointer_expression "&local_54" & identifier) , identifier ))) ;) })) (if_statement "if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }" if (parenthesized_expression "(local_54 != local_50)" ( (binary_expression "local_54 != local_50" identifier != identifier) )) (compound_statement "{\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }" { (expression_statement "FUN_00312470(param_3,local_54,local_50 - local_54);" (call_expression "FUN_00312470(param_3,local_54,local_50 - local_54)" identifier (argument_list "(param_3,local_54,local_50 - local_54)" ( identifier , identifier , (binary_expression "local_50 - local_54" identifier - identifier) ))) ;) })) }) (else_clause "else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" else (compound_statement "{\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" { (expression_statement "FUN_003127e8(param_3,&local_54,local_50);" (call_expression "FUN_003127e8(param_3,&local_54,local_50)" identifier (argument_list "(param_3,&local_54,local_50)" ( identifier , (pointer_expression "&local_54" & identifier) , identifier ))) ;) }))) (if_statement "if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }" if (parenthesized_expression "(local_60 != 0)" ( (binary_expression "local_60 != 0" identifier != number_literal) )) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" identifier = number_literal) ;) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" identifier = number_literal) ;) (expression_statement "local_60 = 0;" (assignment_expression "local_60 = 0" identifier = number_literal) ;) })) (if_statement "if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }" if (parenthesized_expression "(local_54 != 0)" ( (binary_expression "local_54 != 0" identifier != number_literal) )) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }" { (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" ( (pointer_expression "*(code *)PTR_free_004c5c18" * (cast_expression "(code *)PTR_free_004c5c18" ( (type_descriptor "code *" type_identifier (abstract_pointer_declarator "*" *)) ) identifier)) )) (argument_list "()" ( ))) ;) (return_statement "return iVar9;" return identifier ;) })) (return_statement "return iVar9;" return identifier ;) })))
(translation_unit (function_definition TYPE (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE (pointer_declarator * IDENT)) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE (array_declarator IDENT [ LIT ]) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE (pointer_declarator * IDENT) ;) (declaration TYPE IDENT ;) (declaration TYPE (pointer_declarator * IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( )))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != LIT) )) && (parenthesized_expression ( (comma_expression (assignment_expression IDENT = (binary_expression (subscript_expression IDENT [ LIT ]) & LIT)) , (binary_expression IDENT == LIT)) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (subscript_expression IDENT [ LIT ]) & LIT)) ;) })) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (return_statement return LIT ;) })) (if_statement if (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ])) <= IDENT) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + (binary_expression IDENT * LIT)) ))))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != (char_literal ' escape_sequence ')) ))) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) ))) ;) })) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < (char_literal ' character ')) )) (compound_statement { (return_statement return LIT ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT < (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = LIT) ;) (expression_statement (assignment_expression (subscript_expression IDENT [ LIT ]) = IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , LIT , LIT )))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression IDENT + LIT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression IDENT + LIT)) ;) }))) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != (char_literal ' character ')) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (return_statement return LIT ;) })) }))) (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) )))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (for_statement for ( ; (binary_expression LIT < IDENT) ; (assignment_expression IDENT = (binary_expression IDENT + LIT)) ) (compound_statement { (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (pointer_expression * IDENT))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) IDENT)) ;) (expression_statement (assignment_expression IDENT = (subscript_expression IDENT [ LIT ])) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT , IDENT , (pointer_expression & IDENT) , (pointer_expression & IDENT) , LIT , LIT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (goto_statement goto statement_identifier ;)) (labeled_statement statement_identifier : (expression_statement (assignment_expression IDENT = LIT) ;)) (break_statement break ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (char_literal ' character ')) )) (compound_statement { (expression_statement (assignment_expression (pointer_expression * IDENT) = (cast_expression ( (type_descriptor TYPE) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT == LIT) )) || (parenthesized_expression ( (binary_expression (cast_expression ( (type_descriptor TYPE) ) (subscript_expression IDENT [ LIT ])) <= IDENT) ))) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator * (abstract_pointer_declarator *))) ) (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) + (binary_expression IDENT * LIT)) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT != (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) && (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != (char_literal ' escape_sequence ')) ))) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) ))) ;) })) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) & LIT) )) == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) })) (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT , IDENT , (pointer_expression & IDENT) )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , (pointer_expression & IDENT) , IDENT ))) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (call_expression (parenthesized_expression ( (pointer_expression * IDENT) )) (argument_list ( IDENT )))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (goto_statement goto statement_identifier ;)) (expression_statement (assignment_expression IDENT = (call_expression IDENT (argument_list ( (binary_expression IDENT + LIT) )))) ;) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT , (pointer_expression * IDENT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (expression_statement (assignment_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + IDENT) )))) = LIT) ;) (expression_statement (assignment_expression IDENT = (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (call_expression IDENT (argument_list ( IDENT , IDENT ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) LIT)) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT , IDENT ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) })) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != (char_literal ' escape_sequence ')) )) (compound_statement { (expression_statement (assignment_expression IDENT = IDENT) ;) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT ))) ;) (expression_statement (assignment_expression IDENT = IDENT) ;) })) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * IDENT)) ;) }))) (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( IDENT ))) ;) (expression_statement (assignment_expression (pointer_expression * IDENT) = (binary_expression IDENT + IDENT)) ;) }))) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression IDENT == IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT - IDENT)) ;) })))) (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , IDENT ))) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_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 = (binary_expression IDENT + LIT)) ;) }))) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT ))) ;) })) })) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT == IDENT) )) (compound_statement { (expression_statement (assignment_expression IDENT = LIT) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT - IDENT)) ;) }))) (expression_statement (call_expression IDENT (argument_list ( (binary_expression IDENT + LIT) , IDENT , IDENT , IDENT ))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_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 = (binary_expression IDENT + LIT)) ;) }))) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT ))) ;) (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (subscript_expression IDENT [ LIT ]) & LIT) )) != LIT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , (binary_expression IDENT + LIT) ))) ;) })) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , (pointer_expression & IDENT) , IDENT ))) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * IDENT) != (subscript_expression IDENT [ LIT ])) )) (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_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 = (binary_expression IDENT + LIT)) ;) }))) (expression_statement (call_expression IDENT (argument_list ( (pointer_expression & IDENT) , IDENT ))) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != IDENT) )) (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , IDENT , (binary_expression IDENT - IDENT) ))) ;) })) }) (else_clause else (compound_statement { (expression_statement (call_expression IDENT (argument_list ( IDENT , (pointer_expression & IDENT) , IDENT ))) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( ))) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) (expression_statement (assignment_expression IDENT = LIT) ;) })) (if_statement if (parenthesized_expression ( (binary_expression IDENT != LIT) )) (compound_statement { (expression_statement (call_expression (parenthesized_expression ( (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) IDENT)) )) (argument_list ( ))) ;) (return_statement return IDENT ;) })) (return_statement return IDENT ;) })))
(function_definition "int FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)\n\n{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}" (primitive_type "int") (function_declarator "FUN_00317320(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)" (identifier "FUN_00317320") (parameter_list "(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)" (( "(") (parameter_declaration "uint *param_1" (type_identifier "uint") (pointer_declarator "*param_1" (* "*") (identifier "param_1"))) (, ",") (parameter_declaration "int *param_2" (primitive_type "int") (pointer_declarator "*param_2" (* "*") (identifier "param_2"))) (, ",") (parameter_declaration "int *param_3" (primitive_type "int") (pointer_declarator "*param_3" (* "*") (identifier "param_3"))) (, ",") (parameter_declaration "uint param_4" (type_identifier "uint") (identifier "param_4")) (, ",") (parameter_declaration "int param_5" (primitive_type "int") (identifier "param_5")) () ")"))) (compound_statement "{\n  char *pcVar1;\n  int iVar2;\n  char cVar4;\n  int iVar3;\n  char *pcVar5;\n  undefined *puVar6;\n  uint uVar7;\n  int iVar8;\n  int iVar9;\n  int iVar10;\n  uint local_resc;\n  int local_60;\n  int local_5c;\n  undefined4 local_58;\n  int local_54;\n  int local_50;\n  undefined4 local_4c;\n  char local_48 [8];\n  code *local_40;\n  code *local_3c;\n  char *local_38;\n  undefined4 local_34;\n  undefined *local_30;\n  \n  local_34 = FUN_00311bac();\n  local_resc = param_4;\n  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }\n  pcVar1 = (char *)*param_2;\n  local_4c = 0;\n  local_50 = 0;\n  local_54 = 0;\n  local_58 = 0;\n  local_5c = 0;\n  local_60 = 0;\n  if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }\n  if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }\n  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);\n  if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }\n  if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }\n  if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }\n  if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }\n  return iVar9;\n}" ({ "{") (declaration "char *pcVar1;" (primitive_type "char") (pointer_declarator "*pcVar1" (* "*") (identifier "pcVar1")) (; ";")) (declaration "int iVar2;" (primitive_type "int") (identifier "iVar2") (; ";")) (declaration "char cVar4;" (primitive_type "char") (identifier "cVar4") (; ";")) (declaration "int iVar3;" (primitive_type "int") (identifier "iVar3") (; ";")) (declaration "char *pcVar5;" (primitive_type "char") (pointer_declarator "*pcVar5" (* "*") (identifier "pcVar5")) (; ";")) (declaration "undefined *puVar6;" (type_identifier "undefined") (pointer_declarator "*puVar6" (* "*") (identifier "puVar6")) (; ";")) (declaration "uint uVar7;" (type_identifier "uint") (identifier "uVar7") (; ";")) (declaration "int iVar8;" (primitive_type "int") (identifier "iVar8") (; ";")) (declaration "int iVar9;" (primitive_type "int") (identifier "iVar9") (; ";")) (declaration "int iVar10;" (primitive_type "int") (identifier "iVar10") (; ";")) (declaration "uint local_resc;" (type_identifier "uint") (identifier "local_resc") (; ";")) (declaration "int local_60;" (primitive_type "int") (identifier "local_60") (; ";")) (declaration "int local_5c;" (primitive_type "int") (identifier "local_5c") (; ";")) (declaration "undefined4 local_58;" (type_identifier "undefined4") (identifier "local_58") (; ";")) (declaration "int local_54;" (primitive_type "int") (identifier "local_54") (; ";")) (declaration "int local_50;" (primitive_type "int") (identifier "local_50") (; ";")) (declaration "undefined4 local_4c;" (type_identifier "undefined4") (identifier "local_4c") (; ";")) (declaration "char local_48 [8];" (primitive_type "char") (array_declarator "local_48 [8]" (identifier "local_48") ([ "[") (number_literal "8") (] "]")) (; ";")) (declaration "code *local_40;" (type_identifier "code") (pointer_declarator "*local_40" (* "*") (identifier "local_40")) (; ";")) (declaration "code *local_3c;" (type_identifier "code") (pointer_declarator "*local_3c" (* "*") (identifier "local_3c")) (; ";")) (declaration "char *local_38;" (primitive_type "char") (pointer_declarator "*local_38" (* "*") (identifier "local_38")) (; ";")) (declaration "undefined4 local_34;" (type_identifier "undefined4") (identifier "local_34") (; ";")) (declaration "undefined *local_30;" (type_identifier "undefined") (pointer_declarator "*local_30" (* "*") (identifier "local_30")) (; ";")) (expression_statement "local_34 = FUN_00311bac();" (assignment_expression "local_34 = FUN_00311bac()" (identifier "local_34") (= "=") (call_expression "FUN_00311bac()" (identifier "FUN_00311bac") (argument_list "()" (( "(") () ")")))) (; ";")) (expression_statement "local_resc = param_4;" (assignment_expression "local_resc = param_4" (identifier "local_resc") (= "=") (identifier "param_4")) (; ";")) (if_statement "if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {\n    local_resc = param_1[0xb] & 1;\n  }" (if "if") (parenthesized_expression "((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0))" (( "(") (binary_expression "(param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)" (parenthesized_expression "(param_4 != 0)" (( "(") (binary_expression "param_4 != 0" (identifier "param_4") (!= "!=") (number_literal "0")) () ")")) (&& "&&") (parenthesized_expression "(local_resc = param_1[10] & 1, local_resc == 0)" (( "(") (comma_expression "local_resc = param_1[10] & 1, local_resc == 0" (assignment_expression "local_resc = param_1[10] & 1" (identifier "local_resc") (= "=") (binary_expression "param_1[10] & 1" (subscript_expression "param_1[10]" (identifier "param_1") ([ "[") (number_literal "10") (] "]")) (& "&") (number_literal "1"))) (, ",") (binary_expression "local_resc == 0" (identifier "local_resc") (== "==") (number_literal "0"))) () ")"))) () ")")) (compound_statement "{\n    local_resc = param_1[0xb] & 1;\n  }" ({ "{") (expression_statement "local_resc = param_1[0xb] & 1;" (assignment_expression "local_resc = param_1[0xb] & 1" (identifier "local_resc") (= "=") (binary_expression "param_1[0xb] & 1" (subscript_expression "param_1[0xb]" (identifier "param_1") ([ "[") (number_literal "0xb") (] "]")) (& "&") (number_literal "1"))) (; ";")) (} "}"))) (expression_statement "pcVar1 = (char *)*param_2;" (assignment_expression "pcVar1 = (char *)*param_2" (identifier "pcVar1") (= "=") (cast_expression "(char *)*param_2" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_2" (* "*") (identifier "param_2")))) (; ";")) (expression_statement "local_4c = 0;" (assignment_expression "local_4c = 0" (identifier "local_4c") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_50 = 0;" (assignment_expression "local_50 = 0" (identifier "local_50") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_54 = 0;" (assignment_expression "local_54 = 0" (identifier "local_54") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" (identifier "local_58") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" (identifier "local_5c") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_60 = 0;" (assignment_expression "local_60 = 0" (identifier "local_60") (= "=") (number_literal "0")) (; ";")) (if_statement "if (*pcVar1 == 'K') {\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }\n  else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" (if "if") (parenthesized_expression "(*pcVar1 == 'K')" (( "(") (binary_expression "*pcVar1 == 'K'" (pointer_expression "*pcVar1" (* "*") (identifier "pcVar1")) (== "==") (char_literal "'K'" (' "'") (character "K") (' "'"))) () ")")) (compound_statement "{\n    *param_2 = (int)(pcVar1 + 1);\n    iVar9 = FUN_00312010(param_2);\n    if (iVar9 == -1) {\n      return 0;\n    }\n    if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }\n    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);\n    iVar9 = 1;\n    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }\n  }" ({ "{") (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (cast_expression "(int)(pcVar1 + 1)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(pcVar1 + 1)" (( "(") (binary_expression "pcVar1 + 1" (identifier "pcVar1") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "iVar9 = FUN_00312010(param_2);" (assignment_expression "iVar9 = FUN_00312010(param_2)" (identifier "iVar9") (= "=") (call_expression "FUN_00312010(param_2)" (identifier "FUN_00312010") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (if_statement "if (iVar9 == -1) {\n      return 0;\n    }" (if "if") (parenthesized_expression "(iVar9 == -1)" (( "(") (binary_expression "iVar9 == -1" (identifier "iVar9") (== "==") (number_literal "-1")) () ")")) (compound_statement "{\n      return 0;\n    }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (if_statement "if ((int)param_1[4] <= iVar9) {\n      return 0;\n    }" (if "if") (parenthesized_expression "((int)param_1[4] <= iVar9)" (( "(") (binary_expression "(int)param_1[4] <= iVar9" (cast_expression "(int)param_1[4]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "param_1[4]" (identifier "param_1") ([ "[") (number_literal "4") (] "]"))) (<= "<=") (identifier "iVar9")) () ")")) (compound_statement "{\n      return 0;\n    }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "pcVar1 = *(char **)(param_1[2] + iVar9 * 4);" (assignment_expression "pcVar1 = *(char **)(param_1[2] + iVar9 * 4)" (identifier "pcVar1") (= "=") (pointer_expression "*(char **)(param_1[2] + iVar9 * 4)" (* "*") (cast_expression "(char **)(param_1[2] + iVar9 * 4)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1[2] + iVar9 * 4)" (( "(") (binary_expression "param_1[2] + iVar9 * 4" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (+ "+") (binary_expression "iVar9 * 4" (identifier "iVar9") (* "*") (number_literal "4"))) () ")"))))) (; ";")) (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" (identifier "iVar9") (= "=") (number_literal "1")) (; ";")) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }" (if "if") (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" (( "(") (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" (( "(") (binary_expression "pcVar1 != (char *)0x0" (identifier "pcVar1") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(*pcVar1 != '\0')" (( "(") (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" (* "*") (identifier "pcVar1")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")"))) () ")")) (compound_statement "{\n      iVar9 = 1;\n      FUN_00312594(&local_54);\n    }" ({ "{") (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" (identifier "iVar9") (= "=") (number_literal "1")) (; ";")) (expression_statement "FUN_00312594(&local_54);" (call_expression "FUN_00312594(&local_54)" (identifier "FUN_00312594") (argument_list "(&local_54)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) () ")"))) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" (else "else") (compound_statement "{\n    cVar4 = pcVar1[1];\n    if (cVar4 < '1') {\n      return 0;\n    }\n    if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }\n    iVar9 = 1;\n    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);\n    local_30 = PTR_LAB_004c4fd8;\n    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);\n    for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }\n  }" ({ "{") (expression_statement "cVar4 = pcVar1[1];" (assignment_expression "cVar4 = pcVar1[1]" (identifier "cVar4") (= "=") (subscript_expression "pcVar1[1]" (identifier "pcVar1") ([ "[") (number_literal "1") (] "]"))) (; ";")) (if_statement "if (cVar4 < '1') {\n      return 0;\n    }" (if "if") (parenthesized_expression "(cVar4 < '1')" (( "(") (binary_expression "cVar4 < '1'" (identifier "cVar4") (< "<") (char_literal "'1'" (' "'") (character "1") (' "'"))) () ")")) (compound_statement "{\n      return 0;\n    }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (if_statement "if (cVar4 < ':') {\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }\n    else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" (if "if") (parenthesized_expression "(cVar4 < ':')" (( "(") (binary_expression "cVar4 < ':'" (identifier "cVar4") (< "<") (char_literal "':'" (' "'") (character ":") (' "'"))) () ")")) (compound_statement "{\n      local_48[1] = 0;\n      local_48[0] = cVar4;\n      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);\n      iVar9 = *param_2;\n      if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }\n    }" ({ "{") (expression_statement "local_48[1] = 0;" (assignment_expression "local_48[1] = 0" (subscript_expression "local_48[1]" (identifier "local_48") ([ "[") (number_literal "1") (] "]")) (= "=") (number_literal "0")) (; ";")) (expression_statement "local_48[0] = cVar4;" (assignment_expression "local_48[0] = cVar4" (subscript_expression "local_48[0]" (identifier "local_48") ([ "[") (number_literal "0") (] "]")) (= "=") (identifier "cVar4")) (; ";")) (expression_statement "iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);" (assignment_expression "iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10)" (identifier "iVar2") (= "=") (call_expression "(*(code *)PTR_strtol_004c5c1c)(local_48,0,10)" (parenthesized_expression "(*(code *)PTR_strtol_004c5c1c)" (( "(") (pointer_expression "*(code *)PTR_strtol_004c5c1c" (* "*") (cast_expression "(code *)PTR_strtol_004c5c1c" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_strtol_004c5c1c"))) () ")")) (argument_list "(local_48,0,10)" (( "(") (identifier "local_48") (, ",") (number_literal "0") (, ",") (number_literal "10") () ")")))) (; ";")) (expression_statement "iVar9 = *param_2;" (assignment_expression "iVar9 = *param_2" (identifier "iVar9") (= "=") (pointer_expression "*param_2" (* "*") (identifier "param_2"))) (; ";")) (if_statement "if (*(char *)(iVar9 + 2) == '_') {\n        *param_2 = iVar9 + 3;\n      }\n      else {\n        *param_2 = iVar9 + 2;\n      }" (if "if") (parenthesized_expression "(*(char *)(iVar9 + 2) == '_')" (( "(") (binary_expression "*(char *)(iVar9 + 2) == '_'" (pointer_expression "*(char *)(iVar9 + 2)" (* "*") (cast_expression "(char *)(iVar9 + 2)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar9 + 2)" (( "(") (binary_expression "iVar9 + 2" (identifier "iVar9") (+ "+") (number_literal "2")) () ")")))) (== "==") (char_literal "'_'" (' "'") (character "_") (' "'"))) () ")")) (compound_statement "{\n        *param_2 = iVar9 + 3;\n      }" ({ "{") (expression_statement "*param_2 = iVar9 + 3;" (assignment_expression "*param_2 = iVar9 + 3" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (binary_expression "iVar9 + 3" (identifier "iVar9") (+ "+") (number_literal "3"))) (; ";")) (} "}")) (else_clause "else {\n        *param_2 = iVar9 + 2;\n      }" (else "else") (compound_statement "{\n        *param_2 = iVar9 + 2;\n      }" ({ "{") (expression_statement "*param_2 = iVar9 + 2;" (assignment_expression "*param_2 = iVar9 + 2" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (binary_expression "iVar9 + 2" (identifier "iVar9") (+ "+") (number_literal "2"))) (; ";")) (} "}")))) (} "}")) (else_clause "else {\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" (else "else") (compound_statement "{\n      if (cVar4 != '_') {\n        return 0;\n      }\n      *param_2 = (int)(pcVar1 + 1);\n      iVar2 = FUN_00312010(param_2);\n      if (iVar2 == -1) {\n        return 0;\n      }\n    }" ({ "{") (if_statement "if (cVar4 != '_') {\n        return 0;\n      }" (if "if") (parenthesized_expression "(cVar4 != '_')" (( "(") (binary_expression "cVar4 != '_'" (identifier "cVar4") (!= "!=") (char_literal "'_'" (' "'") (character "_") (' "'"))) () ")")) (compound_statement "{\n        return 0;\n      }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (cast_expression "(int)(pcVar1 + 1)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(pcVar1 + 1)" (( "(") (binary_expression "pcVar1 + 1" (identifier "pcVar1") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "iVar2 = FUN_00312010(param_2);" (assignment_expression "iVar2 = FUN_00312010(param_2)" (identifier "iVar2") (= "=") (call_expression "FUN_00312010(param_2)" (identifier "FUN_00312010") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (if_statement "if (iVar2 == -1) {\n        return 0;\n      }" (if "if") (parenthesized_expression "(iVar2 == -1)" (( "(") (binary_expression "iVar2 == -1" (identifier "iVar2") (== "==") (number_literal "-1")) () ")")) (compound_statement "{\n        return 0;\n      }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (} "}")))) (expression_statement "iVar9 = 1;" (assignment_expression "iVar9 = 1" (identifier "iVar9") (= "=") (number_literal "1")) (; ";")) (expression_statement "local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);" (assignment_expression "local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c)" (identifier "local_40") (= "=") (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x439c)" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x439c)" (( "(") (binary_expression "PTR_LAB_004c4fd8 + 0x439c" (identifier "PTR_LAB_004c4fd8") (+ "+") (number_literal "0x439c")) () ")")))) (; ";")) (expression_statement "local_30 = PTR_LAB_004c4fd8;" (assignment_expression "local_30 = PTR_LAB_004c4fd8" (identifier "local_30") (= "=") (identifier "PTR_LAB_004c4fd8")) (; ";")) (expression_statement "local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);" (assignment_expression "local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28)" (identifier "local_3c") (= "=") (cast_expression "(code *)(PTR_LAB_004c4fd8 + 0x1f28)" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(PTR_LAB_004c4fd8 + 0x1f28)" (( "(") (binary_expression "PTR_LAB_004c4fd8 + 0x1f28" (identifier "PTR_LAB_004c4fd8") (+ "+") (number_literal "0x1f28")) () ")")))) (; ";")) (for_statement "for (; 0 < iVar2; iVar2 = iVar2 + -1) {\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }" (for "for") (( "(") (; ";") (binary_expression "0 < iVar2" (number_literal "0") (< "<") (identifier "iVar2")) (; ";") (assignment_expression "iVar2 = iVar2 + -1" (identifier "iVar2") (= "=") (binary_expression "iVar2 + -1" (identifier "iVar2") (+ "+") (number_literal "-1"))) () ")") (compound_statement "{\n      pcVar5 = (char *)*param_2;\n      local_5c = local_60;\n      cVar4 = *pcVar5;\n      pcVar1 = pcVar5;\n      if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }\n      if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }\n      if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }\n      if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }\n    }" ({ "{") (expression_statement "pcVar5 = (char *)*param_2;" (assignment_expression "pcVar5 = (char *)*param_2" (identifier "pcVar5") (= "=") (cast_expression "(char *)*param_2" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (pointer_expression "*param_2" (* "*") (identifier "param_2")))) (; ";")) (expression_statement "local_5c = local_60;" (assignment_expression "local_5c = local_60" (identifier "local_5c") (= "=") (identifier "local_60")) (; ";")) (expression_statement "cVar4 = *pcVar5;" (assignment_expression "cVar4 = *pcVar5" (identifier "cVar4") (= "=") (pointer_expression "*pcVar5" (* "*") (identifier "pcVar5"))) (; ";")) (expression_statement "pcVar1 = pcVar5;" (assignment_expression "pcVar1 = pcVar5" (identifier "pcVar1") (= "=") (identifier "pcVar5")) (; ";")) (if_statement "if (cVar4 == '_') {\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }" (if "if") (parenthesized_expression "(cVar4 == '_')" (( "(") (binary_expression "cVar4 == '_'" (identifier "cVar4") (== "==") (char_literal "'_'" (' "'") (character "_") (' "'"))) () ")")) (compound_statement "{\n        pcVar1 = pcVar5 + 1;\n        *param_2 = (int)pcVar1;\n        cVar4 = pcVar5[1];\n      }" ({ "{") (expression_statement "pcVar1 = pcVar5 + 1;" (assignment_expression "pcVar1 = pcVar5 + 1" (identifier "pcVar1") (= "=") (binary_expression "pcVar5 + 1" (identifier "pcVar5") (+ "+") (number_literal "1"))) (; ";")) (expression_statement "*param_2 = (int)pcVar1;" (assignment_expression "*param_2 = (int)pcVar1" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (cast_expression "(int)pcVar1" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (identifier "pcVar1"))) (; ";")) (expression_statement "cVar4 = pcVar5[1];" (assignment_expression "cVar4 = pcVar5[1]" (identifier "cVar4") (= "=") (subscript_expression "pcVar5[1]" (identifier "pcVar5") ([ "[") (number_literal "1") (] "]"))) (; ";")) (} "}"))) (if_statement "if (cVar4 == 't') {\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }" (if "if") (parenthesized_expression "(cVar4 == 't')" (( "(") (binary_expression "cVar4 == 't'" (identifier "cVar4") (== "==") (char_literal "'t'" (' "'") (character "t") (' "'"))) () ")")) (compound_statement "{\n        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);\n        if (iVar9 != 0) goto LAB_003174e0;\nLAB_003176e8:\n        iVar9 = 0;\n        break;\n      }" ({ "{") (expression_statement "iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);" (assignment_expression "iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0)" (identifier "iVar9") (= "=") (call_expression "FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0)" (identifier "FUN_00316a98") (argument_list "(param_1,param_2,&local_54,&local_60,1,0)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (pointer_expression "&local_60" (& "&") (identifier "local_60")) (, ",") (number_literal "1") (, ",") (number_literal "0") () ")")))) (; ";")) (if_statement "if (iVar9 != 0) goto LAB_003174e0;" (if "if") (parenthesized_expression "(iVar9 != 0)" (( "(") (binary_expression "iVar9 != 0" (identifier "iVar9") (!= "!=") (number_literal "0")) () ")")) (goto_statement "goto LAB_003174e0;" (goto "goto") (statement_identifier "LAB_003174e0") (; ";"))) (labeled_statement "LAB_003176e8:\n        iVar9 = 0;" (statement_identifier "LAB_003176e8") (: ":") (expression_statement "iVar9 = 0;" (assignment_expression "iVar9 = 0" (identifier "iVar9") (= "=") (number_literal "0")) (; ";"))) (break_statement "break;" (break "break") (; ";")) (} "}"))) (if_statement "if (cVar4 == 'K') {\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }\n      else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" (if "if") (parenthesized_expression "(cVar4 == 'K')" (( "(") (binary_expression "cVar4 == 'K'" (identifier "cVar4") (== "==") (char_literal "'K'" (' "'") (character "K") (' "'"))) () ")")) (compound_statement "{\n        *param_2 = (int)(pcVar1 + 1);\n        iVar8 = FUN_00312010(param_2);\n        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;\n        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);\n        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }\n      }" ({ "{") (expression_statement "*param_2 = (int)(pcVar1 + 1);" (assignment_expression "*param_2 = (int)(pcVar1 + 1)" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (cast_expression "(int)(pcVar1 + 1)" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (parenthesized_expression "(pcVar1 + 1)" (( "(") (binary_expression "pcVar1 + 1" (identifier "pcVar1") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "iVar8 = FUN_00312010(param_2);" (assignment_expression "iVar8 = FUN_00312010(param_2)" (identifier "iVar8") (= "=") (call_expression "FUN_00312010(param_2)" (identifier "FUN_00312010") (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (if_statement "if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;" (if "if") (parenthesized_expression "((iVar8 == -1) || ((int)param_1[4] <= iVar8))" (( "(") (binary_expression "(iVar8 == -1) || ((int)param_1[4] <= iVar8)" (parenthesized_expression "(iVar8 == -1)" (( "(") (binary_expression "iVar8 == -1" (identifier "iVar8") (== "==") (number_literal "-1")) () ")")) (|| "||") (parenthesized_expression "((int)param_1[4] <= iVar8)" (( "(") (binary_expression "(int)param_1[4] <= iVar8" (cast_expression "(int)param_1[4]" (( "(") (type_descriptor "int" (primitive_type "int")) () ")") (subscript_expression "param_1[4]" (identifier "param_1") ([ "[") (number_literal "4") (] "]"))) (<= "<=") (identifier "iVar8")) () ")"))) () ")")) (goto_statement "goto LAB_003176e8;" (goto "goto") (statement_identifier "LAB_003176e8") (; ";"))) (expression_statement "pcVar1 = *(char **)(param_1[2] + iVar8 * 4);" (assignment_expression "pcVar1 = *(char **)(param_1[2] + iVar8 * 4)" (identifier "pcVar1") (= "=") (pointer_expression "*(char **)(param_1[2] + iVar8 * 4)" (* "*") (cast_expression "(char **)(param_1[2] + iVar8 * 4)" (( "(") (type_descriptor "char **" (primitive_type "char") (abstract_pointer_declarator "**" (* "*") (abstract_pointer_declarator "*" (* "*")))) () ")") (parenthesized_expression "(param_1[2] + iVar8 * 4)" (( "(") (binary_expression "param_1[2] + iVar8 * 4" (subscript_expression "param_1[2]" (identifier "param_1") ([ "[") (number_literal "2") (] "]")) (+ "+") (binary_expression "iVar8 * 4" (identifier "iVar8") (* "*") (number_literal "4"))) () ")"))))) (; ";")) (if_statement "if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {\n          FUN_00312594(&local_54);\n        }" (if "if") (parenthesized_expression "((pcVar1 != (char *)0x0) && (*pcVar1 != '\0'))" (( "(") (binary_expression "(pcVar1 != (char *)0x0) && (*pcVar1 != '\0')" (parenthesized_expression "(pcVar1 != (char *)0x0)" (( "(") (binary_expression "pcVar1 != (char *)0x0" (identifier "pcVar1") (!= "!=") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (&& "&&") (parenthesized_expression "(*pcVar1 != '\0')" (( "(") (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" (* "*") (identifier "pcVar1")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")"))) () ")")) (compound_statement "{\n          FUN_00312594(&local_54);\n        }" ({ "{") (expression_statement "FUN_00312594(&local_54);" (call_expression "FUN_00312594(&local_54)" (identifier "FUN_00312594") (argument_list "(&local_54)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) () ")"))) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" (else "else") (compound_statement "{\n        if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }\nLAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }\n        FUN_00311cb4(param_1,local_54,iVar8);\n      }" ({ "{") (if_statement "if ((*param_1 & 0x2000) == 0) {\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }\n        else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" (if "if") (parenthesized_expression "((*param_1 & 0x2000) == 0)" (( "(") (binary_expression "(*param_1 & 0x2000) == 0" (parenthesized_expression "(*param_1 & 0x2000)" (( "(") (binary_expression "*param_1 & 0x2000" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (& "&") (number_literal "0x2000")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }\n          local_60 = local_5c;\n          iVar9 = (*local_40)(param_1,param_2,&local_60);\n          if (iVar9 == 0) goto LAB_003176e8;\n          FUN_003127e8(&local_54,&local_60,local_5c);\n        }" ({ "{") (if_statement "if (local_60 != 0) {\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }" (if "if") (parenthesized_expression "(local_60 != 0)" (( "(") (binary_expression "local_60 != 0" (identifier "local_60") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n            (*(code *)PTR_free_004c5c18)();\n            local_5c = 0;\n            local_58 = 0;\n          }" ({ "{") (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" (( "(") (pointer_expression "*(code *)PTR_free_004c5c18" (* "*") (cast_expression "(code *)PTR_free_004c5c18" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_free_004c5c18"))) () ")")) (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" (identifier "local_5c") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" (identifier "local_58") (= "=") (number_literal "0")) (; ";")) (} "}"))) (expression_statement "local_60 = local_5c;" (assignment_expression "local_60 = local_5c" (identifier "local_60") (= "=") (identifier "local_5c")) (; ";")) (expression_statement "iVar9 = (*local_40)(param_1,param_2,&local_60);" (assignment_expression "iVar9 = (*local_40)(param_1,param_2,&local_60)" (identifier "iVar9") (= "=") (call_expression "(*local_40)(param_1,param_2,&local_60)" (parenthesized_expression "(*local_40)" (( "(") (pointer_expression "*local_40" (* "*") (identifier "local_40")) () ")")) (argument_list "(param_1,param_2,&local_60)" (( "(") (identifier "param_1") (, ",") (identifier "param_2") (, ",") (pointer_expression "&local_60" (& "&") (identifier "local_60")) () ")")))) (; ";")) (if_statement "if (iVar9 == 0) goto LAB_003176e8;" (if "if") (parenthesized_expression "(iVar9 == 0)" (( "(") (binary_expression "iVar9 == 0" (identifier "iVar9") (== "==") (number_literal "0")) () ")")) (goto_statement "goto LAB_003176e8;" (goto "goto") (statement_identifier "LAB_003176e8") (; ";"))) (expression_statement "FUN_003127e8(&local_54,&local_60,local_5c);" (call_expression "FUN_003127e8(&local_54,&local_60,local_5c)" (identifier "FUN_003127e8") (argument_list "(&local_54,&local_60,local_5c)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (pointer_expression "&local_60" (& "&") (identifier "local_60")) (, ",") (identifier "local_5c") () ")"))) (; ";")) (} "}")) (else_clause "else {\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" (else "else") (compound_statement "{\n          iVar8 = (*local_3c)(param_2);\n          if (iVar8 == -1) goto LAB_003176e8;\n          iVar3 = xmalloc(iVar8 + 1);\n          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);\n          uVar7 = *param_1;\n          *(undefined1 *)(iVar3 + iVar8) = 0;\n          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);\n          if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }\n          (*(code *)PTR_free_004c5c18)(iVar3);\n          *param_2 = iVar10 + iVar8;\n        }" ({ "{") (expression_statement "iVar8 = (*local_3c)(param_2);" (assignment_expression "iVar8 = (*local_3c)(param_2)" (identifier "iVar8") (= "=") (call_expression "(*local_3c)(param_2)" (parenthesized_expression "(*local_3c)" (( "(") (pointer_expression "*local_3c" (* "*") (identifier "local_3c")) () ")")) (argument_list "(param_2)" (( "(") (identifier "param_2") () ")")))) (; ";")) (if_statement "if (iVar8 == -1) goto LAB_003176e8;" (if "if") (parenthesized_expression "(iVar8 == -1)" (( "(") (binary_expression "iVar8 == -1" (identifier "iVar8") (== "==") (number_literal "-1")) () ")")) (goto_statement "goto LAB_003176e8;" (goto "goto") (statement_identifier "LAB_003176e8") (; ";"))) (expression_statement "iVar3 = xmalloc(iVar8 + 1);" (assignment_expression "iVar3 = xmalloc(iVar8 + 1)" (identifier "iVar3") (= "=") (call_expression "xmalloc(iVar8 + 1)" (identifier "xmalloc") (argument_list "(iVar8 + 1)" (( "(") (binary_expression "iVar8 + 1" (identifier "iVar8") (+ "+") (number_literal "1")) () ")")))) (; ";")) (expression_statement "(*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);" (call_expression "(*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8)" (parenthesized_expression "(*(code *)PTR_memcpy_004c5ba8)" (( "(") (pointer_expression "*(code *)PTR_memcpy_004c5ba8" (* "*") (cast_expression "(code *)PTR_memcpy_004c5ba8" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_memcpy_004c5ba8"))) () ")")) (argument_list "(iVar3,*param_2,iVar8)" (( "(") (identifier "iVar3") (, ",") (pointer_expression "*param_2" (* "*") (identifier "param_2")) (, ",") (identifier "iVar8") () ")"))) (; ";")) (expression_statement "uVar7 = *param_1;" (assignment_expression "uVar7 = *param_1" (identifier "uVar7") (= "=") (pointer_expression "*param_1" (* "*") (identifier "param_1"))) (; ";")) (expression_statement "*(undefined1 *)(iVar3 + iVar8) = 0;" (assignment_expression "*(undefined1 *)(iVar3 + iVar8) = 0" (pointer_expression "*(undefined1 *)(iVar3 + iVar8)" (* "*") (cast_expression "(undefined1 *)(iVar3 + iVar8)" (( "(") (type_descriptor "undefined1 *" (type_identifier "undefined1") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(iVar3 + iVar8)" (( "(") (binary_expression "iVar3 + iVar8" (identifier "iVar3") (+ "+") (identifier "iVar8")) () ")")))) (= "=") (number_literal "0")) (; ";")) (expression_statement "pcVar1 = (char *)cplus_demangle(iVar3,uVar7);" (assignment_expression "pcVar1 = (char *)cplus_demangle(iVar3,uVar7)" (identifier "pcVar1") (= "=") (cast_expression "(char *)cplus_demangle(iVar3,uVar7)" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (call_expression "cplus_demangle(iVar3,uVar7)" (identifier "cplus_demangle") (argument_list "(iVar3,uVar7)" (( "(") (identifier "iVar3") (, ",") (identifier "uVar7") () ")"))))) (; ";")) (if_statement "if (pcVar1 == (char *)0x0) {\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }\n          else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" (if "if") (parenthesized_expression "(pcVar1 == (char *)0x0)" (( "(") (binary_expression "pcVar1 == (char *)0x0" (identifier "pcVar1") (== "==") (cast_expression "(char *)0x0" (( "(") (type_descriptor "char *" (primitive_type "char") (abstract_pointer_declarator "*" (* "*"))) () ")") (number_literal "0x0"))) () ")")) (compound_statement "{\n            iVar10 = *param_2;\n            if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }\n          }" ({ "{") (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" (identifier "iVar10") (= "=") (pointer_expression "*param_2" (* "*") (identifier "param_2"))) (; ";")) (if_statement "if (iVar8 != 0) {\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }" (if "if") (parenthesized_expression "(iVar8 != 0)" (( "(") (binary_expression "iVar8 != 0" (identifier "iVar8") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n              FUN_003123f4(&local_54,iVar10,iVar8);\n              iVar10 = *param_2;\n            }" ({ "{") (expression_statement "FUN_003123f4(&local_54,iVar10,iVar8);" (call_expression "FUN_003123f4(&local_54,iVar10,iVar8)" (identifier "FUN_003123f4") (argument_list "(&local_54,iVar10,iVar8)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (identifier "iVar10") (, ",") (identifier "iVar8") () ")"))) (; ";")) (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" (identifier "iVar10") (= "=") (pointer_expression "*param_2" (* "*") (identifier "param_2"))) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" (else "else") (compound_statement "{\n            if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }\n            (*(code *)PTR_free_004c5c18)(pcVar1);\n            iVar10 = *param_2;\n          }" ({ "{") (if_statement "if (*pcVar1 != '\0') {\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }" (if "if") (parenthesized_expression "(*pcVar1 != '\0')" (( "(") (binary_expression "*pcVar1 != '\0'" (pointer_expression "*pcVar1" (* "*") (identifier "pcVar1")) (!= "!=") (char_literal "'\0'" (' "'") (escape_sequence "\0") (' "'"))) () ")")) (compound_statement "{\n              local_38 = pcVar1;\n              FUN_00312594(&local_54,pcVar1);\n              pcVar1 = local_38;\n            }" ({ "{") (expression_statement "local_38 = pcVar1;" (assignment_expression "local_38 = pcVar1" (identifier "local_38") (= "=") (identifier "pcVar1")) (; ";")) (expression_statement "FUN_00312594(&local_54,pcVar1);" (call_expression "FUN_00312594(&local_54,pcVar1)" (identifier "FUN_00312594") (argument_list "(&local_54,pcVar1)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (identifier "pcVar1") () ")"))) (; ";")) (expression_statement "pcVar1 = local_38;" (assignment_expression "pcVar1 = local_38" (identifier "pcVar1") (= "=") (identifier "local_38")) (; ";")) (} "}"))) (expression_statement "(*(code *)PTR_free_004c5c18)(pcVar1);" (call_expression "(*(code *)PTR_free_004c5c18)(pcVar1)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" (( "(") (pointer_expression "*(code *)PTR_free_004c5c18" (* "*") (cast_expression "(code *)PTR_free_004c5c18" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_free_004c5c18"))) () ")")) (argument_list "(pcVar1)" (( "(") (identifier "pcVar1") () ")"))) (; ";")) (expression_statement "iVar10 = *param_2;" (assignment_expression "iVar10 = *param_2" (identifier "iVar10") (= "=") (pointer_expression "*param_2" (* "*") (identifier "param_2"))) (; ";")) (} "}")))) (expression_statement "(*(code *)PTR_free_004c5c18)(iVar3);" (call_expression "(*(code *)PTR_free_004c5c18)(iVar3)" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" (( "(") (pointer_expression "*(code *)PTR_free_004c5c18" (* "*") (cast_expression "(code *)PTR_free_004c5c18" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_free_004c5c18"))) () ")")) (argument_list "(iVar3)" (( "(") (identifier "iVar3") () ")"))) (; ";")) (expression_statement "*param_2 = iVar10 + iVar8;" (assignment_expression "*param_2 = iVar10 + iVar8" (pointer_expression "*param_2" (* "*") (identifier "param_2")) (= "=") (binary_expression "iVar10 + iVar8" (identifier "iVar10") (+ "+") (identifier "iVar8"))) (; ";")) (} "}")))) (labeled_statement "LAB_003174e0:\n        if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }" (statement_identifier "LAB_003174e0") (: ":") (if_statement "if (local_54 == local_50) {\n          iVar8 = 0;\n        }\n        else {\n          iVar8 = local_50 - local_54;\n        }" (if "if") (parenthesized_expression "(local_54 == local_50)" (( "(") (binary_expression "local_54 == local_50" (identifier "local_54") (== "==") (identifier "local_50")) () ")")) (compound_statement "{\n          iVar8 = 0;\n        }" ({ "{") (expression_statement "iVar8 = 0;" (assignment_expression "iVar8 = 0" (identifier "iVar8") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n          iVar8 = local_50 - local_54;\n        }" (else "else") (compound_statement "{\n          iVar8 = local_50 - local_54;\n        }" ({ "{") (expression_statement "iVar8 = local_50 - local_54;" (assignment_expression "iVar8 = local_50 - local_54" (identifier "iVar8") (= "=") (binary_expression "local_50 - local_54" (identifier "local_50") (- "-") (identifier "local_54"))) (; ";")) (} "}"))))) (expression_statement "FUN_00311cb4(param_1,local_54,iVar8);" (call_expression "FUN_00311cb4(param_1,local_54,iVar8)" (identifier "FUN_00311cb4") (argument_list "(param_1,local_54,iVar8)" (( "(") (identifier "param_1") (, ",") (identifier "local_54") (, ",") (identifier "iVar8") () ")"))) (; ";")) (} "}")))) (if_statement "if (iVar2 != 1) {\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }" (if "if") (parenthesized_expression "(iVar2 != 1)" (( "(") (binary_expression "iVar2 != 1" (identifier "iVar2") (!= "!=") (number_literal "1")) () ")")) (compound_statement "{\n        if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }\n        FUN_00312594(&local_54,puVar6);\n      }" ({ "{") (if_statement "if ((*param_1 & 4) == 0) {\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }\n        else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" (if "if") (parenthesized_expression "((*param_1 & 4) == 0)" (( "(") (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" (( "(") (binary_expression "*param_1 & 4" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (& "&") (number_literal "4")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n          puVar6 = PTR_s__s_004c1a50 + 0x208;\n        }" ({ "{") (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" (identifier "puVar6") (= "=") (binary_expression "PTR_s__s_004c1a50 + 0x208" (identifier "PTR_s__s_004c1a50") (+ "+") (number_literal "0x208"))) (; ";")) (} "}")) (else_clause "else {\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" (else "else") (compound_statement "{\n          puVar6 = PTR_UINT_004c12dc + -0x5450;\n        }" ({ "{") (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" (identifier "puVar6") (= "=") (binary_expression "PTR_UINT_004c12dc + -0x5450" (identifier "PTR_UINT_004c12dc") (+ "+") (number_literal "-0x5450"))) (; ";")) (} "}")))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" (identifier "FUN_00312594") (argument_list "(&local_54,puVar6)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (identifier "puVar6") () ")"))) (; ";")) (} "}"))) (} "}"))) (} "}")))) (if_statement "if (local_54 == local_50) {\n    iVar2 = 0;\n  }\n  else {\n    iVar2 = local_50 - local_54;\n  }" (if "if") (parenthesized_expression "(local_54 == local_50)" (( "(") (binary_expression "local_54 == local_50" (identifier "local_54") (== "==") (identifier "local_50")) () ")")) (compound_statement "{\n    iVar2 = 0;\n  }" ({ "{") (expression_statement "iVar2 = 0;" (assignment_expression "iVar2 = 0" (identifier "iVar2") (= "=") (number_literal "0")) (; ";")) (} "}")) (else_clause "else {\n    iVar2 = local_50 - local_54;\n  }" (else "else") (compound_statement "{\n    iVar2 = local_50 - local_54;\n  }" ({ "{") (expression_statement "iVar2 = local_50 - local_54;" (assignment_expression "iVar2 = local_50 - local_54" (identifier "iVar2") (= "=") (binary_expression "local_50 - local_54" (identifier "local_50") (- "-") (identifier "local_54"))) (; ";")) (} "}")))) (expression_statement "FUN_00312278(param_1 + 3,local_54,iVar2,local_34);" (call_expression "FUN_00312278(param_1 + 3,local_54,iVar2,local_34)" (identifier "FUN_00312278") (argument_list "(param_1 + 3,local_54,iVar2,local_34)" (( "(") (binary_expression "param_1 + 3" (identifier "param_1") (+ "+") (number_literal "3")) (, ",") (identifier "local_54") (, ",") (identifier "iVar2") (, ",") (identifier "local_34") () ")"))) (; ";")) (if_statement "if (local_resc != 0) {\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }" (if "if") (parenthesized_expression "(local_resc != 0)" (( "(") (binary_expression "local_resc != 0" (identifier "local_resc") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }\n    FUN_00312594(&local_54,puVar6);\n    if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }\n    FUN_003127e8(&local_54,&local_60,local_5c);\n  }" ({ "{") (if_statement "if ((*param_1 & 4) == 0) {\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }\n    else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" (if "if") (parenthesized_expression "((*param_1 & 4) == 0)" (( "(") (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" (( "(") (binary_expression "*param_1 & 4" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (& "&") (number_literal "4")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      puVar6 = PTR_s__s_004c1a50 + 0x208;\n    }" ({ "{") (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" (identifier "puVar6") (= "=") (binary_expression "PTR_s__s_004c1a50 + 0x208" (identifier "PTR_s__s_004c1a50") (+ "+") (number_literal "0x208"))) (; ";")) (} "}")) (else_clause "else {\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" (else "else") (compound_statement "{\n      puVar6 = PTR_UINT_004c12dc + -0x5450;\n    }" ({ "{") (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" (identifier "puVar6") (= "=") (binary_expression "PTR_UINT_004c12dc + -0x5450" (identifier "PTR_UINT_004c12dc") (+ "+") (number_literal "-0x5450"))) (; ";")) (} "}")))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" (identifier "FUN_00312594") (argument_list "(&local_54,puVar6)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (identifier "puVar6") () ")"))) (; ";")) (if_statement "if ((param_1[0xb] & 1) != 0) {\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" (if "if") (parenthesized_expression "((param_1[0xb] & 1) != 0)" (( "(") (binary_expression "(param_1[0xb] & 1) != 0" (parenthesized_expression "(param_1[0xb] & 1)" (( "(") (binary_expression "param_1[0xb] & 1" (subscript_expression "param_1[0xb]" (identifier "param_1") ([ "[") (number_literal "0xb") (] "]")) (& "&") (number_literal "1")) () ")")) (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);\n    }" ({ "{") (expression_statement "FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);" (call_expression "FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4)" (identifier "FUN_00312594") (argument_list "(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (binary_expression "PTR_s_in_a_linker_script_004c191c + 0x78e4" (identifier "PTR_s_in_a_linker_script_004c191c") (+ "+") (number_literal "0x78e4")) () ")"))) (; ";")) (} "}"))) (expression_statement "FUN_003127e8(&local_54,&local_60,local_5c);" (call_expression "FUN_003127e8(&local_54,&local_60,local_5c)" (identifier "FUN_003127e8") (argument_list "(&local_54,&local_60,local_5c)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (pointer_expression "&local_60" (& "&") (identifier "local_60")) (, ",") (identifier "local_5c") () ")"))) (; ";")) (} "}"))) (if_statement "if (param_5 == 0) {\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }\n  else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" (if "if") (parenthesized_expression "(param_5 == 0)" (( "(") (binary_expression "param_5 == 0" (identifier "param_5") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }\n    if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }\n  }" ({ "{") (if_statement "if (*param_3 != param_3[1]) {\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }" (if "if") (parenthesized_expression "(*param_3 != param_3[1])" (( "(") (binary_expression "*param_3 != param_3[1]" (pointer_expression "*param_3" (* "*") (identifier "param_3")) (!= "!=") (subscript_expression "param_3[1]" (identifier "param_3") ([ "[") (number_literal "1") (] "]"))) () ")")) (compound_statement "{\n      if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }\n      FUN_00312594(&local_54,puVar6);\n    }" ({ "{") (if_statement "if ((*param_1 & 4) == 0) {\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }\n      else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" (if "if") (parenthesized_expression "((*param_1 & 4) == 0)" (( "(") (binary_expression "(*param_1 & 4) == 0" (parenthesized_expression "(*param_1 & 4)" (( "(") (binary_expression "*param_1 & 4" (pointer_expression "*param_1" (* "*") (identifier "param_1")) (& "&") (number_literal "4")) () ")")) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n        puVar6 = PTR_s__s_004c1a50 + 0x208;\n      }" ({ "{") (expression_statement "puVar6 = PTR_s__s_004c1a50 + 0x208;" (assignment_expression "puVar6 = PTR_s__s_004c1a50 + 0x208" (identifier "puVar6") (= "=") (binary_expression "PTR_s__s_004c1a50 + 0x208" (identifier "PTR_s__s_004c1a50") (+ "+") (number_literal "0x208"))) (; ";")) (} "}")) (else_clause "else {\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" (else "else") (compound_statement "{\n        puVar6 = PTR_UINT_004c12dc + -0x5450;\n      }" ({ "{") (expression_statement "puVar6 = PTR_UINT_004c12dc + -0x5450;" (assignment_expression "puVar6 = PTR_UINT_004c12dc + -0x5450" (identifier "puVar6") (= "=") (binary_expression "PTR_UINT_004c12dc + -0x5450" (identifier "PTR_UINT_004c12dc") (+ "+") (number_literal "-0x5450"))) (; ";")) (} "}")))) (expression_statement "FUN_00312594(&local_54,puVar6);" (call_expression "FUN_00312594(&local_54,puVar6)" (identifier "FUN_00312594") (argument_list "(&local_54,puVar6)" (( "(") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (identifier "puVar6") () ")"))) (; ";")) (} "}"))) (if_statement "if (local_54 != local_50) {\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }" (if "if") (parenthesized_expression "(local_54 != local_50)" (( "(") (binary_expression "local_54 != local_50" (identifier "local_54") (!= "!=") (identifier "local_50")) () ")")) (compound_statement "{\n      FUN_00312470(param_3,local_54,local_50 - local_54);\n    }" ({ "{") (expression_statement "FUN_00312470(param_3,local_54,local_50 - local_54);" (call_expression "FUN_00312470(param_3,local_54,local_50 - local_54)" (identifier "FUN_00312470") (argument_list "(param_3,local_54,local_50 - local_54)" (( "(") (identifier "param_3") (, ",") (identifier "local_54") (, ",") (binary_expression "local_50 - local_54" (identifier "local_50") (- "-") (identifier "local_54")) () ")"))) (; ";")) (} "}"))) (} "}")) (else_clause "else {\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" (else "else") (compound_statement "{\n    FUN_003127e8(param_3,&local_54,local_50);\n  }" ({ "{") (expression_statement "FUN_003127e8(param_3,&local_54,local_50);" (call_expression "FUN_003127e8(param_3,&local_54,local_50)" (identifier "FUN_003127e8") (argument_list "(param_3,&local_54,local_50)" (( "(") (identifier "param_3") (, ",") (pointer_expression "&local_54" (& "&") (identifier "local_54")) (, ",") (identifier "local_50") () ")"))) (; ";")) (} "}")))) (if_statement "if (local_60 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }" (if "if") (parenthesized_expression "(local_60 != 0)" (( "(") (binary_expression "local_60 != 0" (identifier "local_60") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    local_5c = 0;\n    local_58 = 0;\n    local_60 = 0;\n  }" ({ "{") (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" (( "(") (pointer_expression "*(code *)PTR_free_004c5c18" (* "*") (cast_expression "(code *)PTR_free_004c5c18" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_free_004c5c18"))) () ")")) (argument_list "()" (( "(") () ")"))) (; ";")) (expression_statement "local_5c = 0;" (assignment_expression "local_5c = 0" (identifier "local_5c") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_58 = 0;" (assignment_expression "local_58 = 0" (identifier "local_58") (= "=") (number_literal "0")) (; ";")) (expression_statement "local_60 = 0;" (assignment_expression "local_60 = 0" (identifier "local_60") (= "=") (number_literal "0")) (; ";")) (} "}"))) (if_statement "if (local_54 != 0) {\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }" (if "if") (parenthesized_expression "(local_54 != 0)" (( "(") (binary_expression "local_54 != 0" (identifier "local_54") (!= "!=") (number_literal "0")) () ")")) (compound_statement "{\n    (*(code *)PTR_free_004c5c18)();\n    return iVar9;\n  }" ({ "{") (expression_statement "(*(code *)PTR_free_004c5c18)();" (call_expression "(*(code *)PTR_free_004c5c18)()" (parenthesized_expression "(*(code *)PTR_free_004c5c18)" (( "(") (pointer_expression "*(code *)PTR_free_004c5c18" (* "*") (cast_expression "(code *)PTR_free_004c5c18" (( "(") (type_descriptor "code *" (type_identifier "code") (abstract_pointer_declarator "*" (* "*"))) () ")") (identifier "PTR_free_004c5c18"))) () ")")) (argument_list "()" (( "(") () ")"))) (; ";")) (return_statement "return iVar9;" (return "return") (identifier "iVar9") (; ";")) (} "}"))) (return_statement "return iVar9;" (return "return") (identifier "iVar9") (; ";")) (} "}")))
(translation_unit (function_definition type: (primitive_type) declarator: (function_declarator declarator: (identifier) parameters: (parameter_list (parameter_declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (parameter_declaration type: (type_identifier) declarator: (identifier)) (parameter_declaration type: (primitive_type) declarator: (identifier)))) body: (compound_statement (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (primitive_type) declarator: (identifier)) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (primitive_type) declarator: (array_declarator declarator: (identifier) size: (number_literal))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (primitive_type) declarator: (pointer_declarator declarator: (identifier))) (declaration type: (type_identifier) declarator: (identifier)) (declaration type: (type_identifier) declarator: (pointer_declarator declarator: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (comma_expression left: (assignment_expression left: (identifier) right: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) right: (binary_expression left: (identifier) right: (number_literal)))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))) right: (identifier))) consequence: (compound_statement (return_statement (number_literal)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))))))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) right: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (escape_sequence)))))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)))))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (return_statement (number_literal)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) (expression_statement (assignment_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (identifier))) (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 (identifier) (number_literal) (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (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: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (identifier) right: (number_literal))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (identifier) right: (number_literal)))))))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (return_statement (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (return_statement (number_literal))))))) (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)))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (for_statement condition: (binary_expression left: (number_literal) right: (identifier)) update: (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal))) body: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (pointer_expression argument: (identifier))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (number_literal)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (subscript_expression argument: (identifier) index: (number_literal)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (pointer_expression argument: (identifier)) (pointer_expression argument: (identifier)) (number_literal) (number_literal))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (labeled_statement label: (statement_identifier) (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) (break_statement))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (char_literal (character)))) consequence: (compound_statement (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (cast_expression type: (type_descriptor type: (primitive_type)) value: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal)))))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) right: (parenthesized_expression (binary_expression left: (cast_expression type: (type_descriptor type: (primitive_type)) value: (subscript_expression argument: (identifier) index: (number_literal))) right: (identifier))))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator declarator: (abstract_pointer_declarator))) value: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (binary_expression left: (identifier) right: (number_literal)))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) right: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (escape_sequence)))))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)))))))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (number_literal))) right: (number_literal))) consequence: (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: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))))) (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (identifier))) arguments: (argument_list (identifier) (identifier) (pointer_expression argument: (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (pointer_expression argument: (identifier)) (identifier))))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (parenthesized_expression (pointer_expression argument: (identifier))) arguments: (argument_list (identifier))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (goto_statement label: (statement_identifier))) (expression_statement (assignment_expression left: (identifier) right: (call_expression function: (identifier) arguments: (argument_list (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 (identifier) (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (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: (identifier))))) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (cast_expression type: (type_descriptor type: (primitive_type) declarator: (abstract_pointer_declarator)) value: (number_literal)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (identifier) (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (identifier))))))) alternative: (else_clause (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (char_literal (escape_sequence)))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (identifier))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (identifier)))) (expression_statement (assignment_expression left: (identifier) 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 (identifier)))) (expression_statement (assignment_expression left: (identifier) right: (pointer_expression argument: (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 (identifier)))) (expression_statement (assignment_expression left: (pointer_expression argument: (identifier)) right: (binary_expression left: (identifier) right: (identifier))))))) (labeled_statement label: (statement_identifier) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier)))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (identifier))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (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: (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (identifier))))))))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (expression_statement (assignment_expression left: (identifier) right: (number_literal)))) alternative: (else_clause (compound_statement (expression_statement (assignment_expression left: (identifier) right: (binary_expression left: (identifier) right: (identifier))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (binary_expression left: (identifier) right: (number_literal)) (identifier) (identifier) (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (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: (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (identifier)))) (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (subscript_expression argument: (identifier) index: (number_literal)) right: (number_literal))) right: (number_literal))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (pointer_expression argument: (identifier)) (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (number_literal))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (pointer_expression argument: (identifier)) right: (subscript_expression argument: (identifier) index: (number_literal)))) consequence: (compound_statement (if_statement condition: (parenthesized_expression (binary_expression left: (parenthesized_expression (binary_expression left: (pointer_expression argument: (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: (binary_expression left: (identifier) right: (number_literal))))))) (expression_statement (call_expression function: (identifier) arguments: (argument_list (pointer_expression argument: (identifier)) (identifier)))))) (if_statement condition: (parenthesized_expression (binary_expression left: (identifier) right: (identifier))) consequence: (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (identifier) (binary_expression left: (identifier) right: (identifier)))))))) alternative: (else_clause (compound_statement (expression_statement (call_expression function: (identifier) arguments: (argument_list (identifier) (pointer_expression argument: (identifier)) (identifier))))))) (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: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))) (expression_statement (assignment_expression left: (identifier) right: (number_literal))))) (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: (cast_expression type: (type_descriptor type: (type_identifier) declarator: (abstract_pointer_declarator)) value: (identifier)))) arguments: (argument_list))) (return_statement (identifier)))) (return_statement (identifier)))))

int MASKED(uint *param_1,int *param_2,int *param_3,uint param_4,int param_5)

{
  char *pcVar1;
  int iVar2;
  char cVar4;
  int iVar3;
  char *pcVar5;
  undefined *puVar6;
  uint uVar7;
  int iVar8;
  int iVar9;
  int iVar10;
  uint local_resc;
  int local_60;
  int local_5c;
  undefined4 local_58;
  int local_54;
  int local_50;
  undefined4 local_4c;
  char local_48 [8];
  code *local_40;
  code *local_3c;
  char *local_38;
  undefined4 local_34;
  undefined *local_30;
  
  local_34 = FUN_00311bac();
  local_resc = param_4;
  if ((param_4 != 0) && (local_resc = param_1[10] & 1, local_resc == 0)) {
    local_resc = param_1[0xb] & 1;
  }
  pcVar1 = (char *)*param_2;
  local_4c = 0;
  local_50 = 0;
  local_54 = 0;
  local_58 = 0;
  local_5c = 0;
  local_60 = 0;
  if (*pcVar1 == 'K') {
    *param_2 = (int)(pcVar1 + 1);
    iVar9 = FUN_00312010(param_2);
    if (iVar9 == -1) {
      return 0;
    }
    if ((int)param_1[4] <= iVar9) {
      return 0;
    }
    pcVar1 = *(char **)(param_1[2] + iVar9 * 4);
    iVar9 = 1;
    if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {
      iVar9 = 1;
      FUN_00312594(&local_54);
    }
  }
  else {
    cVar4 = pcVar1[1];
    if (cVar4 < '1') {
      return 0;
    }
    if (cVar4 < ':') {
      local_48[1] = 0;
      local_48[0] = cVar4;
      iVar2 = (*(code *)PTR_strtol_004c5c1c)(local_48,0,10);
      iVar9 = *param_2;
      if (*(char *)(iVar9 + 2) == '_') {
        *param_2 = iVar9 + 3;
      }
      else {
        *param_2 = iVar9 + 2;
      }
    }
    else {
      if (cVar4 != '_') {
        return 0;
      }
      *param_2 = (int)(pcVar1 + 1);
      iVar2 = FUN_00312010(param_2);
      if (iVar2 == -1) {
        return 0;
      }
    }
    iVar9 = 1;
    local_40 = (code *)(PTR_LAB_004c4fd8 + 0x439c);
    local_30 = PTR_LAB_004c4fd8;
    local_3c = (code *)(PTR_LAB_004c4fd8 + 0x1f28);
    for (; 0 < iVar2; iVar2 = iVar2 + -1) {
      pcVar5 = (char *)*param_2;
      local_5c = local_60;
      cVar4 = *pcVar5;
      pcVar1 = pcVar5;
      if (cVar4 == '_') {
        pcVar1 = pcVar5 + 1;
        *param_2 = (int)pcVar1;
        cVar4 = pcVar5[1];
      }
      if (cVar4 == 't') {
        iVar9 = FUN_00316a98(param_1,param_2,&local_54,&local_60,1,0);
        if (iVar9 != 0) goto LAB_003174e0;
LAB_003176e8:
        iVar9 = 0;
        break;
      }
      if (cVar4 == 'K') {
        *param_2 = (int)(pcVar1 + 1);
        iVar8 = FUN_00312010(param_2);
        if ((iVar8 == -1) || ((int)param_1[4] <= iVar8)) goto LAB_003176e8;
        pcVar1 = *(char **)(param_1[2] + iVar8 * 4);
        if ((pcVar1 != (char *)0x0) && (*pcVar1 != '\0')) {
          FUN_00312594(&local_54);
        }
      }
      else {
        if ((*param_1 & 0x2000) == 0) {
          if (local_60 != 0) {
            (*(code *)PTR_free_004c5c18)();
            local_5c = 0;
            local_58 = 0;
          }
          local_60 = local_5c;
          iVar9 = (*local_40)(param_1,param_2,&local_60);
          if (iVar9 == 0) goto LAB_003176e8;
          FUN_003127e8(&local_54,&local_60,local_5c);
        }
        else {
          iVar8 = (*local_3c)(param_2);
          if (iVar8 == -1) goto LAB_003176e8;
          iVar3 = xmalloc(iVar8 + 1);
          (*(code *)PTR_memcpy_004c5ba8)(iVar3,*param_2,iVar8);
          uVar7 = *param_1;
          *(undefined1 *)(iVar3 + iVar8) = 0;
          pcVar1 = (char *)cplus_demangle(iVar3,uVar7);
          if (pcVar1 == (char *)0x0) {
            iVar10 = *param_2;
            if (iVar8 != 0) {
              FUN_003123f4(&local_54,iVar10,iVar8);
              iVar10 = *param_2;
            }
          }
          else {
            if (*pcVar1 != '\0') {
              local_38 = pcVar1;
              FUN_00312594(&local_54,pcVar1);
              pcVar1 = local_38;
            }
            (*(code *)PTR_free_004c5c18)(pcVar1);
            iVar10 = *param_2;
          }
          (*(code *)PTR_free_004c5c18)(iVar3);
          *param_2 = iVar10 + iVar8;
        }
LAB_003174e0:
        if (local_54 == local_50) {
          iVar8 = 0;
        }
        else {
          iVar8 = local_50 - local_54;
        }
        FUN_00311cb4(param_1,local_54,iVar8);
      }
      if (iVar2 != 1) {
        if ((*param_1 & 4) == 0) {
          puVar6 = PTR_s__s_004c1a50 + 0x208;
        }
        else {
          puVar6 = PTR_UINT_004c12dc + -0x5450;
        }
        FUN_00312594(&local_54,puVar6);
      }
    }
  }
  if (local_54 == local_50) {
    iVar2 = 0;
  }
  else {
    iVar2 = local_50 - local_54;
  }
  FUN_00312278(param_1 + 3,local_54,iVar2,local_34);
  if (local_resc != 0) {
    if ((*param_1 & 4) == 0) {
      puVar6 = PTR_s__s_004c1a50 + 0x208;
    }
    else {
      puVar6 = PTR_UINT_004c12dc + -0x5450;
    }
    FUN_00312594(&local_54,puVar6);
    if ((param_1[0xb] & 1) != 0) {
      FUN_00312594(&local_54,PTR_s_in_a_linker_script_004c191c + 0x78e4);
    }
    FUN_003127e8(&local_54,&local_60,local_5c);
  }
  if (param_5 == 0) {
    if (*param_3 != param_3[1]) {
      if ((*param_1 & 4) == 0) {
        puVar6 = PTR_s__s_004c1a50 + 0x208;
      }
      else {
        puVar6 = PTR_UINT_004c12dc + -0x5450;
      }
      FUN_00312594(&local_54,puVar6);
    }
    if (local_54 != local_50) {
      FUN_00312470(param_3,local_54,local_50 - local_54);
    }
  }
  else {
    FUN_003127e8(param_3,&local_54,local_50);
  }
  if (local_60 != 0) {
    (*(code *)PTR_free_004c5c18)();
    local_5c = 0;
    local_58 = 0;
    local_60 = 0;
  }
  if (local_54 != 0) {
    (*(code *)PTR_free_004c5c18)();
    return iVar9;
  }
  return iVar9;
}

