
XCharStruct * __regparm3 x11_char_struct(XFontStruct *xfs,uchar byte1,uchar byte2)

{
  uint uVar1;
  uint uVar2;
  uint uVar3;
  uint uVar4;
  XCharStruct *pXVar5;
  int iVar6;
  
  uVar3 = (uint)byte2;
  uVar1 = xfs->min_char_or_byte2;
  if (uVar3 < uVar1) {
    return (XCharStruct *)0x0;
  }
  if (xfs->max_char_or_byte2 < uVar3) {
    return (XCharStruct *)0x0;
  }
  uVar2 = xfs->min_byte1;
  if (uVar2 == 0) {
    uVar4 = xfs->max_byte1;
    if (uVar4 == 0) {
      iVar6 = uVar3 - uVar1;
      goto LAB_0005002c;
    }
  }
  else {
    if (byte1 < uVar2) {
      return (XCharStruct *)0x0;
    }
    uVar4 = xfs->max_byte1;
  }
  if (uVar4 < byte1) {
    return (XCharStruct *)0x0;
  }
  iVar6 = (uVar3 - uVar1) + ((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2);
LAB_0005002c:
  if (xfs->per_char == (XCharStruct *)0x0) {
    pXVar5 = &xfs->max_bounds;
  }
  else {
    pXVar5 = xfs->per_char + iVar6;
  }
  return pXVar5;
}



int __regparm3 FUN_0004fff0(int param_1,uint param_2,uint param_3)

{
  uint uVar1;
  uint uVar2;
  uint uVar3;
  int iVar4;
  
  param_3 = param_3 & 0xff;
  uVar1 = *(uint *)(param_1 + 0xc);
  if (param_3 < uVar1) {
    return 0;
  }
  if (*(uint *)(param_1 + 0x10) < param_3) {
    return 0;
  }
  uVar2 = *(uint *)(param_1 + 0x14);
  if (uVar2 == 0) {
    uVar3 = *(uint *)(param_1 + 0x18);
    if (uVar3 == 0) {
      iVar4 = param_3 - uVar1;
      goto LAB_0005002c;
    }
  }
  else {
    if ((param_2 & 0xff) < uVar2) {
      return 0;
    }
    uVar3 = *(uint *)(param_1 + 0x18);
  }
  if (uVar3 < (param_2 & 0xff)) {
    return 0;
  }
  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)
  ;
LAB_0005002c:
  if (*(int *)(param_1 + 0x44) == 0) {
    param_1 = param_1 + 0x38;
  }
  else {
    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;
  }
  return param_1;
}


PUSH EBP
MOVZX ECX,CL
PUSH EDI
PUSH ESI
PUSH EBX
MOV EDI,dword ptr [EAX + 0xc]
CMP ECX,EDI
JC 0x00050050
MOV EBX,dword ptr [EAX + 0x10]
MOV ESI,EAX
CMP ECX,EBX
JA 0x00050050
MOV EBP,dword ptr [EAX + 0x14]
TEST EBP,EBP
JZ 0x00050040
MOVZX EDX,DL
XOR EAX,EAX
CMP EBP,EDX
JA 0x00050039
MOV EAX,dword ptr [ESI + 0x18]
CMP EAX,EDX
JC 0x00050050
ADD EBX,0x1
SUB EDX,EBP
SUB ECX,EDI
SUB EBX,EDI
IMUL EBX,EDX
ADD ECX,EBX
MOV EAX,dword ptr [ESI + 0x44]
TEST EAX,EAX
JZ 0x00050068
LEA EDX,[ECX + ECX*0x2]
LEA EAX,[EAX + EDX*0x4]
POP EBX
POP ESI
POP EDI
POP EBP
RET
MOV EAX,dword ptr [EAX + 0x18]
TEST EAX,EAX
JNZ 0x00050060
SUB ECX,EDI
JMP 0x0005002c
POP EBX
XOR EAX,EAX
POP ESI
POP EDI
POP EBP
RET
MOVZX EDX,DL
JMP 0x0005001a
LEA EAX,[ESI + 0x38]
JMP 0x00050039
(translation_unit "int __regparm3 FUN_0004fff0(int param_1,uint param_2,uint param_3)\n\n{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}\n\n" (function_definition "int __regparm3 FUN_0004fff0(int param_1,uint param_2,uint param_3)\n\n{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "FUN_0004fff0(int param_1,uint param_2,uint param_3)" identifier (parameter_list "(int param_1,uint param_2,uint param_3)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "uint param_2" type_identifier identifier) , (parameter_declaration "uint param_3" type_identifier identifier) ))) (compound_statement "{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (expression_statement "param_3 = param_3 & 0xff;" (assignment_expression "param_3 = param_3 & 0xff" identifier = (binary_expression "param_3 & 0xff" identifier & number_literal)) ;) (expression_statement "uVar1 = *(uint *)(param_1 + 0xc);" (assignment_expression "uVar1 = *(uint *)(param_1 + 0xc)" identifier = (pointer_expression "*(uint *)(param_1 + 0xc)" * (cast_expression "(uint *)(param_1 + 0xc)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) ))))) ;) (if_statement "if (param_3 < uVar1) {\n    return 0;\n  }" if (parenthesized_expression "(param_3 < uVar1)" ( (binary_expression "param_3 < uVar1" identifier < identifier) )) (compound_statement "{\n    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }" if (parenthesized_expression "(*(uint *)(param_1 + 0x10) < param_3)" ( (binary_expression "*(uint *)(param_1 + 0x10) < param_3" (pointer_expression "*(uint *)(param_1 + 0x10)" * (cast_expression "(uint *)(param_1 + 0x10)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) < identifier) )) (compound_statement "{\n    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "uVar2 = *(uint *)(param_1 + 0x14);" (assignment_expression "uVar2 = *(uint *)(param_1 + 0x14)" identifier = (pointer_expression "*(uint *)(param_1 + 0x14)" * (cast_expression "(uint *)(param_1 + 0x14)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) ;) (if_statement "if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" if (parenthesized_expression "(uVar2 == 0)" ( (binary_expression "uVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }" { (expression_statement "uVar3 = *(uint *)(param_1 + 0x18);" (assignment_expression "uVar3 = *(uint *)(param_1 + 0x18)" identifier = (pointer_expression "*(uint *)(param_1 + 0x18)" * (cast_expression "(uint *)(param_1 + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) ))))) ;) (if_statement "if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }" if (parenthesized_expression "(uVar3 == 0)" ( (binary_expression "uVar3 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }" { (expression_statement "iVar4 = param_3 - uVar1;" (assignment_expression "iVar4 = param_3 - uVar1" identifier = (binary_expression "param_3 - uVar1" identifier - identifier)) ;) (goto_statement "goto LAB_0005002c;" goto statement_identifier ;) })) }) (else_clause "else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" else (compound_statement "{\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" { (if_statement "if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }" if (parenthesized_expression "((param_2 & 0xff) < uVar2)" ( (binary_expression "(param_2 & 0xff) < uVar2" (parenthesized_expression "(param_2 & 0xff)" ( (binary_expression "param_2 & 0xff" identifier & number_literal) )) < identifier) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "uVar3 = *(uint *)(param_1 + 0x18);" (assignment_expression "uVar3 = *(uint *)(param_1 + 0x18)" identifier = (pointer_expression "*(uint *)(param_1 + 0x18)" * (cast_expression "(uint *)(param_1 + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) ))))) ;) }))) (if_statement "if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }" if (parenthesized_expression "(uVar3 < (param_2 & 0xff))" ( (binary_expression "uVar3 < (param_2 & 0xff)" identifier < (parenthesized_expression "(param_2 & 0xff)" ( (binary_expression "param_2 & 0xff" identifier & number_literal) ))) )) (compound_statement "{\n    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;" (assignment_expression "iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" identifier = (binary_expression "(param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (parenthesized_expression "(param_3 - uVar1)" ( (binary_expression "param_3 - uVar1" identifier - identifier) )) + (binary_expression "((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (parenthesized_expression "((*(uint *)(param_1 + 0x10) + 1) - uVar1)" ( (binary_expression "(*(uint *)(param_1 + 0x10) + 1) - uVar1" (parenthesized_expression "(*(uint *)(param_1 + 0x10) + 1)" ( (binary_expression "*(uint *)(param_1 + 0x10) + 1" (pointer_expression "*(uint *)(param_1 + 0x10)" * (cast_expression "(uint *)(param_1 + 0x10)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) + number_literal) )) - identifier) )) * (parenthesized_expression "((param_2 & 0xff) - uVar2)" ( (binary_expression "(param_2 & 0xff) - uVar2" (parenthesized_expression "(param_2 & 0xff)" ( (binary_expression "param_2 & 0xff" identifier & number_literal) )) - identifier) ))))) ;) (labeled_statement "LAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" statement_identifier : (if_statement "if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x44) == 0)" ( (binary_expression "*(int *)(param_1 + 0x44) == 0" (pointer_expression "*(int *)(param_1 + 0x44)" * (cast_expression "(int *)(param_1 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x44)" ( (binary_expression "param_1 + 0x44" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n    param_1 = param_1 + 0x38;\n  }" { (expression_statement "param_1 = param_1 + 0x38;" (assignment_expression "param_1 = param_1 + 0x38" identifier = (binary_expression "param_1 + 0x38" identifier + number_literal)) ;) }) (else_clause "else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" else (compound_statement "{\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" { (expression_statement "param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;" (assignment_expression "param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc" identifier = (binary_expression "*(int *)(param_1 + 0x44) + iVar4 * 0xc" (pointer_expression "*(int *)(param_1 + 0x44)" * (cast_expression "(int *)(param_1 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x44)" ( (binary_expression "param_1 + 0x44" identifier + number_literal) )))) + (binary_expression "iVar4 * 0xc" identifier * number_literal))) ;) })))) (return_statement "return param_1;" return identifier ;) })))
(translation_unit "XCharStruct * __regparm3 x11_char_struct(XFontStruct *xfs,uchar byte1,uchar byte2)\n\n{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  uint uVar4;\n  XCharStruct *pXVar5;\n  int iVar6;\n  \n  uVar3 = (uint)byte2;\n  uVar1 = xfs->min_char_or_byte2;\n  if (uVar3 < uVar1) {\n    return (XCharStruct *)0x0;\n  }\n  if (xfs->max_char_or_byte2 < uVar3) {\n    return (XCharStruct *)0x0;\n  }\n  uVar2 = xfs->min_byte1;\n  if (uVar2 == 0) {\n    uVar4 = xfs->max_byte1;\n    if (uVar4 == 0) {\n      iVar6 = uVar3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if (byte1 < uVar2) {\n      return (XCharStruct *)0x0;\n    }\n    uVar4 = xfs->max_byte1;\n  }\n  if (uVar4 < byte1) {\n    return (XCharStruct *)0x0;\n  }\n  iVar6 = (uVar3 - uVar1) + ((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2);\nLAB_0005002c:\n  if (xfs->per_char == (XCharStruct *)0x0) {\n    pXVar5 = &xfs->max_bounds;\n  }\n  else {\n    pXVar5 = xfs->per_char + iVar6;\n  }\n  return pXVar5;\n}\n\n" (ERROR "XCharStruct * __regparm3 x11_char_struct(XFontStruct *xfs,uchar byte1,uchar byte2)" (binary_expression "XCharStruct * __regparm3 x11_char_struct(XFontStruct *xfs,uchar byte1,uchar byte2)" identifier * (ERROR "__regparm3" identifier) (call_expression "x11_char_struct(XFontStruct *xfs,uchar byte1,uchar byte2)" identifier (argument_list "(XFontStruct *xfs,uchar byte1,uchar byte2)" ( (binary_expression "XFontStruct *xfs" identifier * identifier) , identifier (ERROR "byte1" identifier) , identifier (ERROR "byte2" identifier) ))))) (compound_statement "{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  uint uVar4;\n  XCharStruct *pXVar5;\n  int iVar6;\n  \n  uVar3 = (uint)byte2;\n  uVar1 = xfs->min_char_or_byte2;\n  if (uVar3 < uVar1) {\n    return (XCharStruct *)0x0;\n  }\n  if (xfs->max_char_or_byte2 < uVar3) {\n    return (XCharStruct *)0x0;\n  }\n  uVar2 = xfs->min_byte1;\n  if (uVar2 == 0) {\n    uVar4 = xfs->max_byte1;\n    if (uVar4 == 0) {\n      iVar6 = uVar3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if (byte1 < uVar2) {\n      return (XCharStruct *)0x0;\n    }\n    uVar4 = xfs->max_byte1;\n  }\n  if (uVar4 < byte1) {\n    return (XCharStruct *)0x0;\n  }\n  iVar6 = (uVar3 - uVar1) + ((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2);\nLAB_0005002c:\n  if (xfs->per_char == (XCharStruct *)0x0) {\n    pXVar5 = &xfs->max_bounds;\n  }\n  else {\n    pXVar5 = xfs->per_char + iVar6;\n  }\n  return pXVar5;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "uint uVar4;" type_identifier identifier ;) (declaration "XCharStruct *pXVar5;" type_identifier (pointer_declarator "*pXVar5" * identifier) ;) (declaration "int iVar6;" primitive_type identifier ;) (expression_statement "uVar3 = (uint)byte2;" (assignment_expression "uVar3 = (uint)byte2" identifier = (cast_expression "(uint)byte2" ( (type_descriptor "uint" type_identifier) ) identifier)) ;) (expression_statement "uVar1 = xfs->min_char_or_byte2;" (assignment_expression "uVar1 = xfs->min_char_or_byte2" identifier = (field_expression "xfs->min_char_or_byte2" identifier -> field_identifier)) ;) (if_statement "if (uVar3 < uVar1) {\n    return (XCharStruct *)0x0;\n  }" if (parenthesized_expression "(uVar3 < uVar1)" ( (binary_expression "uVar3 < uVar1" identifier < identifier) )) (compound_statement "{\n    return (XCharStruct *)0x0;\n  }" { (return_statement "return (XCharStruct *)0x0;" return (cast_expression "(XCharStruct *)0x0" ( (type_descriptor "XCharStruct *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ;) })) (if_statement "if (xfs->max_char_or_byte2 < uVar3) {\n    return (XCharStruct *)0x0;\n  }" if (parenthesized_expression "(xfs->max_char_or_byte2 < uVar3)" ( (binary_expression "xfs->max_char_or_byte2 < uVar3" (field_expression "xfs->max_char_or_byte2" identifier -> field_identifier) < identifier) )) (compound_statement "{\n    return (XCharStruct *)0x0;\n  }" { (return_statement "return (XCharStruct *)0x0;" return (cast_expression "(XCharStruct *)0x0" ( (type_descriptor "XCharStruct *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ;) })) (expression_statement "uVar2 = xfs->min_byte1;" (assignment_expression "uVar2 = xfs->min_byte1" identifier = (field_expression "xfs->min_byte1" identifier -> field_identifier)) ;) (if_statement "if (uVar2 == 0) {\n    uVar4 = xfs->max_byte1;\n    if (uVar4 == 0) {\n      iVar6 = uVar3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if (byte1 < uVar2) {\n      return (XCharStruct *)0x0;\n    }\n    uVar4 = xfs->max_byte1;\n  }" if (parenthesized_expression "(uVar2 == 0)" ( (binary_expression "uVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    uVar4 = xfs->max_byte1;\n    if (uVar4 == 0) {\n      iVar6 = uVar3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }" { (expression_statement "uVar4 = xfs->max_byte1;" (assignment_expression "uVar4 = xfs->max_byte1" identifier = (field_expression "xfs->max_byte1" identifier -> field_identifier)) ;) (if_statement "if (uVar4 == 0) {\n      iVar6 = uVar3 - uVar1;\n      goto LAB_0005002c;\n    }" if (parenthesized_expression "(uVar4 == 0)" ( (binary_expression "uVar4 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar6 = uVar3 - uVar1;\n      goto LAB_0005002c;\n    }" { (expression_statement "iVar6 = uVar3 - uVar1;" (assignment_expression "iVar6 = uVar3 - uVar1" identifier = (binary_expression "uVar3 - uVar1" identifier - identifier)) ;) (goto_statement "goto LAB_0005002c;" goto statement_identifier ;) })) }) (else_clause "else {\n    if (byte1 < uVar2) {\n      return (XCharStruct *)0x0;\n    }\n    uVar4 = xfs->max_byte1;\n  }" else (compound_statement "{\n    if (byte1 < uVar2) {\n      return (XCharStruct *)0x0;\n    }\n    uVar4 = xfs->max_byte1;\n  }" { (if_statement "if (byte1 < uVar2) {\n      return (XCharStruct *)0x0;\n    }" if (parenthesized_expression "(byte1 < uVar2)" ( (binary_expression "byte1 < uVar2" identifier < identifier) )) (compound_statement "{\n      return (XCharStruct *)0x0;\n    }" { (return_statement "return (XCharStruct *)0x0;" return (cast_expression "(XCharStruct *)0x0" ( (type_descriptor "XCharStruct *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ;) })) (expression_statement "uVar4 = xfs->max_byte1;" (assignment_expression "uVar4 = xfs->max_byte1" identifier = (field_expression "xfs->max_byte1" identifier -> field_identifier)) ;) }))) (if_statement "if (uVar4 < byte1) {\n    return (XCharStruct *)0x0;\n  }" if (parenthesized_expression "(uVar4 < byte1)" ( (binary_expression "uVar4 < byte1" identifier < identifier) )) (compound_statement "{\n    return (XCharStruct *)0x0;\n  }" { (return_statement "return (XCharStruct *)0x0;" return (cast_expression "(XCharStruct *)0x0" ( (type_descriptor "XCharStruct *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal) ;) })) (expression_statement "iVar6 = (uVar3 - uVar1) + ((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2);" (assignment_expression "iVar6 = (uVar3 - uVar1) + ((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2)" identifier = (binary_expression "(uVar3 - uVar1) + ((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2)" (parenthesized_expression "(uVar3 - uVar1)" ( (binary_expression "uVar3 - uVar1" identifier - identifier) )) + (binary_expression "((xfs->max_char_or_byte2 + 1) - uVar1) * (byte1 - uVar2)" (parenthesized_expression "((xfs->max_char_or_byte2 + 1) - uVar1)" ( (binary_expression "(xfs->max_char_or_byte2 + 1) - uVar1" (parenthesized_expression "(xfs->max_char_or_byte2 + 1)" ( (binary_expression "xfs->max_char_or_byte2 + 1" (field_expression "xfs->max_char_or_byte2" identifier -> field_identifier) + number_literal) )) - identifier) )) * (parenthesized_expression "(byte1 - uVar2)" ( (binary_expression "byte1 - uVar2" identifier - identifier) ))))) ;) (labeled_statement "LAB_0005002c:\n  if (xfs->per_char == (XCharStruct *)0x0) {\n    pXVar5 = &xfs->max_bounds;\n  }\n  else {\n    pXVar5 = xfs->per_char + iVar6;\n  }" statement_identifier : (if_statement "if (xfs->per_char == (XCharStruct *)0x0) {\n    pXVar5 = &xfs->max_bounds;\n  }\n  else {\n    pXVar5 = xfs->per_char + iVar6;\n  }" if (parenthesized_expression "(xfs->per_char == (XCharStruct *)0x0)" ( (binary_expression "xfs->per_char == (XCharStruct *)0x0" (field_expression "xfs->per_char" identifier -> field_identifier) == (cast_expression "(XCharStruct *)0x0" ( (type_descriptor "XCharStruct *" type_identifier (abstract_pointer_declarator "*" *)) ) number_literal)) )) (compound_statement "{\n    pXVar5 = &xfs->max_bounds;\n  }" { (expression_statement "pXVar5 = &xfs->max_bounds;" (assignment_expression "pXVar5 = &xfs->max_bounds" identifier = (pointer_expression "&xfs->max_bounds" & (field_expression "xfs->max_bounds" identifier -> field_identifier))) ;) }) (else_clause "else {\n    pXVar5 = xfs->per_char + iVar6;\n  }" else (compound_statement "{\n    pXVar5 = xfs->per_char + iVar6;\n  }" { (expression_statement "pXVar5 = xfs->per_char + iVar6;" (assignment_expression "pXVar5 = xfs->per_char + iVar6" identifier = (binary_expression "xfs->per_char + iVar6" (field_expression "xfs->per_char" identifier -> field_identifier) + identifier)) ;) })))) (return_statement "return pXVar5;" return identifier ;) }))
(translation_unit "int __regparm3 FUN_0004fff0(int param_1,uint param_2,uint param_3)\n\n{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}\n\n" (function_definition "int __regparm3 FUN_0004fff0(int param_1,uint param_2,uint param_3)\n\n{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}" primitive_type (ERROR "__regparm3" identifier) (function_declarator "FUN_0004fff0(int param_1,uint param_2,uint param_3)" identifier (parameter_list "(int param_1,uint param_2,uint param_3)" ( (parameter_declaration "int param_1" primitive_type identifier) , (parameter_declaration "uint param_2" type_identifier identifier) , (parameter_declaration "uint param_3" type_identifier identifier) ))) (compound_statement "{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}" { (declaration "uint uVar1;" type_identifier identifier ;) (declaration "uint uVar2;" type_identifier identifier ;) (declaration "uint uVar3;" type_identifier identifier ;) (declaration "int iVar4;" primitive_type identifier ;) (expression_statement "param_3 = param_3 & 0xff;" (assignment_expression "param_3 = param_3 & 0xff" identifier = (binary_expression "param_3 & 0xff" identifier & number_literal)) ;) (expression_statement "uVar1 = *(uint *)(param_1 + 0xc);" (assignment_expression "uVar1 = *(uint *)(param_1 + 0xc)" identifier = (pointer_expression "*(uint *)(param_1 + 0xc)" * (cast_expression "(uint *)(param_1 + 0xc)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0xc)" ( (binary_expression "param_1 + 0xc" identifier + number_literal) ))))) ;) (if_statement "if (param_3 < uVar1) {\n    return 0;\n  }" if (parenthesized_expression "(param_3 < uVar1)" ( (binary_expression "param_3 < uVar1" identifier < identifier) )) (compound_statement "{\n    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (if_statement "if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }" if (parenthesized_expression "(*(uint *)(param_1 + 0x10) < param_3)" ( (binary_expression "*(uint *)(param_1 + 0x10) < param_3" (pointer_expression "*(uint *)(param_1 + 0x10)" * (cast_expression "(uint *)(param_1 + 0x10)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) < identifier) )) (compound_statement "{\n    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "uVar2 = *(uint *)(param_1 + 0x14);" (assignment_expression "uVar2 = *(uint *)(param_1 + 0x14)" identifier = (pointer_expression "*(uint *)(param_1 + 0x14)" * (cast_expression "(uint *)(param_1 + 0x14)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x14)" ( (binary_expression "param_1 + 0x14" identifier + number_literal) ))))) ;) (if_statement "if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" if (parenthesized_expression "(uVar2 == 0)" ( (binary_expression "uVar2 == 0" identifier == number_literal) )) (compound_statement "{\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }" { (expression_statement "uVar3 = *(uint *)(param_1 + 0x18);" (assignment_expression "uVar3 = *(uint *)(param_1 + 0x18)" identifier = (pointer_expression "*(uint *)(param_1 + 0x18)" * (cast_expression "(uint *)(param_1 + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) ))))) ;) (if_statement "if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }" if (parenthesized_expression "(uVar3 == 0)" ( (binary_expression "uVar3 == 0" identifier == number_literal) )) (compound_statement "{\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }" { (expression_statement "iVar4 = param_3 - uVar1;" (assignment_expression "iVar4 = param_3 - uVar1" identifier = (binary_expression "param_3 - uVar1" identifier - identifier)) ;) (goto_statement "goto LAB_0005002c;" goto statement_identifier ;) })) }) (else_clause "else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" else (compound_statement "{\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" { (if_statement "if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }" if (parenthesized_expression "((param_2 & 0xff) < uVar2)" ( (binary_expression "(param_2 & 0xff) < uVar2" (parenthesized_expression "(param_2 & 0xff)" ( (binary_expression "param_2 & 0xff" identifier & number_literal) )) < identifier) )) (compound_statement "{\n      return 0;\n    }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "uVar3 = *(uint *)(param_1 + 0x18);" (assignment_expression "uVar3 = *(uint *)(param_1 + 0x18)" identifier = (pointer_expression "*(uint *)(param_1 + 0x18)" * (cast_expression "(uint *)(param_1 + 0x18)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x18)" ( (binary_expression "param_1 + 0x18" identifier + number_literal) ))))) ;) }))) (if_statement "if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }" if (parenthesized_expression "(uVar3 < (param_2 & 0xff))" ( (binary_expression "uVar3 < (param_2 & 0xff)" identifier < (parenthesized_expression "(param_2 & 0xff)" ( (binary_expression "param_2 & 0xff" identifier & number_literal) ))) )) (compound_statement "{\n    return 0;\n  }" { (return_statement "return 0;" return number_literal ;) })) (expression_statement "iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;" (assignment_expression "iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" identifier = (binary_expression "(param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (parenthesized_expression "(param_3 - uVar1)" ( (binary_expression "param_3 - uVar1" identifier - identifier) )) + (binary_expression "((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (parenthesized_expression "((*(uint *)(param_1 + 0x10) + 1) - uVar1)" ( (binary_expression "(*(uint *)(param_1 + 0x10) + 1) - uVar1" (parenthesized_expression "(*(uint *)(param_1 + 0x10) + 1)" ( (binary_expression "*(uint *)(param_1 + 0x10) + 1" (pointer_expression "*(uint *)(param_1 + 0x10)" * (cast_expression "(uint *)(param_1 + 0x10)" ( (type_descriptor "uint *" type_identifier (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x10)" ( (binary_expression "param_1 + 0x10" identifier + number_literal) )))) + number_literal) )) - identifier) )) * (parenthesized_expression "((param_2 & 0xff) - uVar2)" ( (binary_expression "(param_2 & 0xff) - uVar2" (parenthesized_expression "(param_2 & 0xff)" ( (binary_expression "param_2 & 0xff" identifier & number_literal) )) - identifier) ))))) ;) (labeled_statement "LAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" statement_identifier : (if_statement "if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" if (parenthesized_expression "(*(int *)(param_1 + 0x44) == 0)" ( (binary_expression "*(int *)(param_1 + 0x44) == 0" (pointer_expression "*(int *)(param_1 + 0x44)" * (cast_expression "(int *)(param_1 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x44)" ( (binary_expression "param_1 + 0x44" identifier + number_literal) )))) == number_literal) )) (compound_statement "{\n    param_1 = param_1 + 0x38;\n  }" { (expression_statement "param_1 = param_1 + 0x38;" (assignment_expression "param_1 = param_1 + 0x38" identifier = (binary_expression "param_1 + 0x38" identifier + number_literal)) ;) }) (else_clause "else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" else (compound_statement "{\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" { (expression_statement "param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;" (assignment_expression "param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc" identifier = (binary_expression "*(int *)(param_1 + 0x44) + iVar4 * 0xc" (pointer_expression "*(int *)(param_1 + 0x44)" * (cast_expression "(int *)(param_1 + 0x44)" ( (type_descriptor "int *" primitive_type (abstract_pointer_declarator "*" *)) ) (parenthesized_expression "(param_1 + 0x44)" ( (binary_expression "param_1 + 0x44" identifier + number_literal) )))) + (binary_expression "iVar4 * 0xc" identifier * number_literal))) ;) })))) (return_statement "return param_1;" return identifier ;) })))
(translation_unit (function_definition TYPE (ERROR IDENT) (function_declarator IDENT (parameter_list ( (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) , (parameter_declaration TYPE IDENT) ))) (compound_statement { (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (declaration TYPE IDENT ;) (expression_statement (assignment_expression IDENT = (binary_expression IDENT & LIT)) ;) (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT < IDENT) )) (compound_statement { (return_statement return LIT ;) })) (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_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 *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) (if_statement if (parenthesized_expression ( (binary_expression IDENT == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT - IDENT)) ;) (goto_statement goto statement_identifier ;) })) }) (else_clause else (compound_statement { (if_statement if (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_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 *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) ))))) ;) }))) (if_statement if (parenthesized_expression ( (binary_expression IDENT < (parenthesized_expression ( (binary_expression IDENT & LIT) ))) )) (compound_statement { (return_statement return LIT ;) })) (expression_statement (assignment_expression IDENT = (binary_expression (parenthesized_expression ( (binary_expression IDENT - IDENT) )) + (binary_expression (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + LIT) )) - IDENT) )) * (parenthesized_expression ( (binary_expression (parenthesized_expression ( (binary_expression IDENT & LIT) )) - IDENT) ))))) ;) (labeled_statement statement_identifier : (if_statement if (parenthesized_expression ( (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) == LIT) )) (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression IDENT + LIT)) ;) }) (else_clause else (compound_statement { (expression_statement (assignment_expression IDENT = (binary_expression (pointer_expression * (cast_expression ( (type_descriptor TYPE (abstract_pointer_declarator *)) ) (parenthesized_expression ( (binary_expression IDENT + LIT) )))) + (binary_expression IDENT * LIT))) ;) })))) (return_statement return IDENT ;) })))
(function_definition "int __regparm3 FUN_0004fff0(int param_1,uint param_2,uint param_3)\n\n{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}" (primitive_type "int") (ERROR "__regparm3" (identifier "__regparm3")) (function_declarator "FUN_0004fff0(int param_1,uint param_2,uint param_3)" (identifier "FUN_0004fff0") (parameter_list "(int param_1,uint param_2,uint param_3)" (( "(") (parameter_declaration "int param_1" (primitive_type "int") (identifier "param_1")) (, ",") (parameter_declaration "uint param_2" (type_identifier "uint") (identifier "param_2")) (, ",") (parameter_declaration "uint param_3" (type_identifier "uint") (identifier "param_3")) () ")"))) (compound_statement "{\n  uint uVar1;\n  uint uVar2;\n  uint uVar3;\n  int iVar4;\n  \n  param_3 = param_3 & 0xff;\n  uVar1 = *(uint *)(param_1 + 0xc);\n  if (param_3 < uVar1) {\n    return 0;\n  }\n  if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }\n  uVar2 = *(uint *)(param_1 + 0x14);\n  if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }\n  if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }\n  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;\nLAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }\n  return param_1;\n}" ({ "{") (declaration "uint uVar1;" (type_identifier "uint") (identifier "uVar1") (; ";")) (declaration "uint uVar2;" (type_identifier "uint") (identifier "uVar2") (; ";")) (declaration "uint uVar3;" (type_identifier "uint") (identifier "uVar3") (; ";")) (declaration "int iVar4;" (primitive_type "int") (identifier "iVar4") (; ";")) (expression_statement "param_3 = param_3 & 0xff;" (assignment_expression "param_3 = param_3 & 0xff" (identifier "param_3") (= "=") (binary_expression "param_3 & 0xff" (identifier "param_3") (& "&") (number_literal "0xff"))) (; ";")) (expression_statement "uVar1 = *(uint *)(param_1 + 0xc);" (assignment_expression "uVar1 = *(uint *)(param_1 + 0xc)" (identifier "uVar1") (= "=") (pointer_expression "*(uint *)(param_1 + 0xc)" (* "*") (cast_expression "(uint *)(param_1 + 0xc)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0xc)" (( "(") (binary_expression "param_1 + 0xc" (identifier "param_1") (+ "+") (number_literal "0xc")) () ")"))))) (; ";")) (if_statement "if (param_3 < uVar1) {\n    return 0;\n  }" (if "if") (parenthesized_expression "(param_3 < uVar1)" (( "(") (binary_expression "param_3 < uVar1" (identifier "param_3") (< "<") (identifier "uVar1")) () ")")) (compound_statement "{\n    return 0;\n  }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (if_statement "if (*(uint *)(param_1 + 0x10) < param_3) {\n    return 0;\n  }" (if "if") (parenthesized_expression "(*(uint *)(param_1 + 0x10) < param_3)" (( "(") (binary_expression "*(uint *)(param_1 + 0x10) < param_3" (pointer_expression "*(uint *)(param_1 + 0x10)" (* "*") (cast_expression "(uint *)(param_1 + 0x10)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (< "<") (identifier "param_3")) () ")")) (compound_statement "{\n    return 0;\n  }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "uVar2 = *(uint *)(param_1 + 0x14);" (assignment_expression "uVar2 = *(uint *)(param_1 + 0x14)" (identifier "uVar2") (= "=") (pointer_expression "*(uint *)(param_1 + 0x14)" (* "*") (cast_expression "(uint *)(param_1 + 0x14)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x14)" (( "(") (binary_expression "param_1 + 0x14" (identifier "param_1") (+ "+") (number_literal "0x14")) () ")"))))) (; ";")) (if_statement "if (uVar2 == 0) {\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }\n  else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" (if "if") (parenthesized_expression "(uVar2 == 0)" (( "(") (binary_expression "uVar2 == 0" (identifier "uVar2") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    uVar3 = *(uint *)(param_1 + 0x18);\n    if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }\n  }" ({ "{") (expression_statement "uVar3 = *(uint *)(param_1 + 0x18);" (assignment_expression "uVar3 = *(uint *)(param_1 + 0x18)" (identifier "uVar3") (= "=") (pointer_expression "*(uint *)(param_1 + 0x18)" (* "*") (cast_expression "(uint *)(param_1 + 0x18)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")"))))) (; ";")) (if_statement "if (uVar3 == 0) {\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }" (if "if") (parenthesized_expression "(uVar3 == 0)" (( "(") (binary_expression "uVar3 == 0" (identifier "uVar3") (== "==") (number_literal "0")) () ")")) (compound_statement "{\n      iVar4 = param_3 - uVar1;\n      goto LAB_0005002c;\n    }" ({ "{") (expression_statement "iVar4 = param_3 - uVar1;" (assignment_expression "iVar4 = param_3 - uVar1" (identifier "iVar4") (= "=") (binary_expression "param_3 - uVar1" (identifier "param_3") (- "-") (identifier "uVar1"))) (; ";")) (goto_statement "goto LAB_0005002c;" (goto "goto") (statement_identifier "LAB_0005002c") (; ";")) (} "}"))) (} "}")) (else_clause "else {\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" (else "else") (compound_statement "{\n    if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }\n    uVar3 = *(uint *)(param_1 + 0x18);\n  }" ({ "{") (if_statement "if ((param_2 & 0xff) < uVar2) {\n      return 0;\n    }" (if "if") (parenthesized_expression "((param_2 & 0xff) < uVar2)" (( "(") (binary_expression "(param_2 & 0xff) < uVar2" (parenthesized_expression "(param_2 & 0xff)" (( "(") (binary_expression "param_2 & 0xff" (identifier "param_2") (& "&") (number_literal "0xff")) () ")")) (< "<") (identifier "uVar2")) () ")")) (compound_statement "{\n      return 0;\n    }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "uVar3 = *(uint *)(param_1 + 0x18);" (assignment_expression "uVar3 = *(uint *)(param_1 + 0x18)" (identifier "uVar3") (= "=") (pointer_expression "*(uint *)(param_1 + 0x18)" (* "*") (cast_expression "(uint *)(param_1 + 0x18)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x18)" (( "(") (binary_expression "param_1 + 0x18" (identifier "param_1") (+ "+") (number_literal "0x18")) () ")"))))) (; ";")) (} "}")))) (if_statement "if (uVar3 < (param_2 & 0xff)) {\n    return 0;\n  }" (if "if") (parenthesized_expression "(uVar3 < (param_2 & 0xff))" (( "(") (binary_expression "uVar3 < (param_2 & 0xff)" (identifier "uVar3") (< "<") (parenthesized_expression "(param_2 & 0xff)" (( "(") (binary_expression "param_2 & 0xff" (identifier "param_2") (& "&") (number_literal "0xff")) () ")"))) () ")")) (compound_statement "{\n    return 0;\n  }" ({ "{") (return_statement "return 0;" (return "return") (number_literal "0") (; ";")) (} "}"))) (expression_statement "iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)\n  ;" (assignment_expression "iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (identifier "iVar4") (= "=") (binary_expression "(param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (parenthesized_expression "(param_3 - uVar1)" (( "(") (binary_expression "param_3 - uVar1" (identifier "param_3") (- "-") (identifier "uVar1")) () ")")) (+ "+") (binary_expression "((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)" (parenthesized_expression "((*(uint *)(param_1 + 0x10) + 1) - uVar1)" (( "(") (binary_expression "(*(uint *)(param_1 + 0x10) + 1) - uVar1" (parenthesized_expression "(*(uint *)(param_1 + 0x10) + 1)" (( "(") (binary_expression "*(uint *)(param_1 + 0x10) + 1" (pointer_expression "*(uint *)(param_1 + 0x10)" (* "*") (cast_expression "(uint *)(param_1 + 0x10)" (( "(") (type_descriptor "uint *" (type_identifier "uint") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x10)" (( "(") (binary_expression "param_1 + 0x10" (identifier "param_1") (+ "+") (number_literal "0x10")) () ")")))) (+ "+") (number_literal "1")) () ")")) (- "-") (identifier "uVar1")) () ")")) (* "*") (parenthesized_expression "((param_2 & 0xff) - uVar2)" (( "(") (binary_expression "(param_2 & 0xff) - uVar2" (parenthesized_expression "(param_2 & 0xff)" (( "(") (binary_expression "param_2 & 0xff" (identifier "param_2") (& "&") (number_literal "0xff")) () ")")) (- "-") (identifier "uVar2")) () ")"))))) (; ";")) (labeled_statement "LAB_0005002c:\n  if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" (statement_identifier "LAB_0005002c") (: ":") (if_statement "if (*(int *)(param_1 + 0x44) == 0) {\n    param_1 = param_1 + 0x38;\n  }\n  else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" (if "if") (parenthesized_expression "(*(int *)(param_1 + 0x44) == 0)" (( "(") (binary_expression "*(int *)(param_1 + 0x44) == 0" (pointer_expression "*(int *)(param_1 + 0x44)" (* "*") (cast_expression "(int *)(param_1 + 0x44)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x44)" (( "(") (binary_expression "param_1 + 0x44" (identifier "param_1") (+ "+") (number_literal "0x44")) () ")")))) (== "==") (number_literal "0")) () ")")) (compound_statement "{\n    param_1 = param_1 + 0x38;\n  }" ({ "{") (expression_statement "param_1 = param_1 + 0x38;" (assignment_expression "param_1 = param_1 + 0x38" (identifier "param_1") (= "=") (binary_expression "param_1 + 0x38" (identifier "param_1") (+ "+") (number_literal "0x38"))) (; ";")) (} "}")) (else_clause "else {\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" (else "else") (compound_statement "{\n    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;\n  }" ({ "{") (expression_statement "param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;" (assignment_expression "param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc" (identifier "param_1") (= "=") (binary_expression "*(int *)(param_1 + 0x44) + iVar4 * 0xc" (pointer_expression "*(int *)(param_1 + 0x44)" (* "*") (cast_expression "(int *)(param_1 + 0x44)" (( "(") (type_descriptor "int *" (primitive_type "int") (abstract_pointer_declarator "*" (* "*"))) () ")") (parenthesized_expression "(param_1 + 0x44)" (( "(") (binary_expression "param_1 + 0x44" (identifier "param_1") (+ "+") (number_literal "0x44")) () ")")))) (+ "+") (binary_expression "iVar4 * 0xc" (identifier "iVar4") (* "*") (number_literal "0xc")))) (; ";")) (} "}"))))) (return_statement "return param_1;" (return "return") (identifier "param_1") (; ";")) (} "}")))

type_2 * __regparm3 x11_char_struct(XFontStruct *xfs,uchar var_5,uchar byte2)

{
  type_1 var_2;
  type_1 var_3;
  type_1 var_1;
  type_1 var_4;
  type_2 *pXVar5;
  int var_6;
  
  var_1 = (type_1)byte2;
  var_2 = xfs->min_char_or_byte2;
  if (var_1 < var_2) {
    return (type_2 *)0x0;
  }
  if (xfs->max_char_or_byte2 < var_1) {
    return (type_2 *)0x0;
  }
  var_3 = xfs->min_byte1;
  if (var_3 == 0) {
    var_4 = xfs->max_byte1;
    if (var_4 == 0) {
      var_6 = var_1 - var_2;
      goto LAB_0005002c;
    }
  }
  else {
    if (var_5 < var_3) {
      return (type_2 *)0x0;
    }
    var_4 = xfs->max_byte1;
  }
  if (var_4 < var_5) {
    return (type_2 *)0x0;
  }
  var_6 = (var_1 - var_2) + ((xfs->max_char_or_byte2 + 1) - var_2) * (var_5 - var_3);
LAB_0005002c:
  if (xfs->per_char == (type_2 *)0x0) {
    pXVar5 = &xfs->max_bounds;
  }
  else {
    pXVar5 = xfs->per_char + var_6;
  }
  return pXVar5;
}


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

int __regparm3 MASKED(int param_1,uint param_2,uint param_3)

{
  uint uVar1;
  uint uVar2;
  uint uVar3;
  int iVar4;
  
  param_3 = param_3 & 0xff;
  uVar1 = *(uint *)(param_1 + 0xc);
  if (param_3 < uVar1) {
    return 0;
  }
  if (*(uint *)(param_1 + 0x10) < param_3) {
    return 0;
  }
  uVar2 = *(uint *)(param_1 + 0x14);
  if (uVar2 == 0) {
    uVar3 = *(uint *)(param_1 + 0x18);
    if (uVar3 == 0) {
      iVar4 = param_3 - uVar1;
      goto LAB_0005002c;
    }
  }
  else {
    if ((param_2 & 0xff) < uVar2) {
      return 0;
    }
    uVar3 = *(uint *)(param_1 + 0x18);
  }
  if (uVar3 < (param_2 & 0xff)) {
    return 0;
  }
  iVar4 = (param_3 - uVar1) + ((*(uint *)(param_1 + 0x10) + 1) - uVar1) * ((param_2 & 0xff) - uVar2)
  ;
LAB_0005002c:
  if (*(int *)(param_1 + 0x44) == 0) {
    param_1 = param_1 + 0x38;
  }
  else {
    param_1 = *(int *)(param_1 + 0x44) + iVar4 * 0xc;
  }
  return param_1;
}

