// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/external/expat-2.0.1/lib/xmlparse.c
// Function: defineAttribute
static int
defineAttribute(ELEMENT_TYPE *type, ATTRIBUTE_ID *attId, XML_Bool isCdata,
                XML_Bool isId, const XML_Char *value, XML_Parser parser)
{
  DEFAULT_ATTRIBUTE *att;
  if (value || isId) {
    /* The handling of default attributes gets messed up if we have
       a default which duplicates a non-default. */
    int i;
    for (i = 0; i < type->nDefaultAtts; i++)
      if (attId == type->defaultAtts[i].id)
        return 1;
    if (isId && !type->idAtt && !attId->xmlns)
      type->idAtt = attId;
  }
  if (type->nDefaultAtts == type->allocDefaultAtts) {
    if (type->allocDefaultAtts == 0) {
      type->allocDefaultAtts = 8;
      type->defaultAtts = (DEFAULT_ATTRIBUTE *)MALLOC(type->allocDefaultAtts
                            * sizeof(DEFAULT_ATTRIBUTE));
      if (!type->defaultAtts)
        return 0;
    }
    else {
      DEFAULT_ATTRIBUTE *temp;
      int count = type->allocDefaultAtts * 2;
      temp = (DEFAULT_ATTRIBUTE *)
        REALLOC(type->defaultAtts, (count * sizeof(DEFAULT_ATTRIBUTE)));
      if (temp == NULL)
        return 0;
      type->allocDefaultAtts = count;
      type->defaultAtts = temp;
    }
  }
  att = type->defaultAtts + type->nDefaultAtts;
  att->id = attId;
  att->value = value;
  att->isCdata = isCdata;
  if (!isCdata)
    attId->maybeTokenized = XML_TRUE;
  type->nDefaultAtts += 1;
  return 1;
}

// Assembly:
subq $0x58, %rsp
movb %cl, %al
movb %dl, %cl
movq %rdi, 0x48(%rsp)
movq %rsi, 0x40(%rsp)
movb %cl, 0x3f(%rsp)
movb %al, 0x3e(%rsp)
movq %r8, 0x30(%rsp)
movq %r9, 0x28(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x37a3aa
movzbl 0x3e(%rsp), %eax
cmpl $0x0, %eax
je 0x37a42c
movl $0x0, 0x1c(%rsp)
movl 0x1c(%rsp), %eax
movq 0x48(%rsp), %rcx
cmpl 0x18(%rcx), %eax
jge 0x37a3fb
movq 0x40(%rsp), %rax
movq 0x48(%rsp), %rcx
movq 0x20(%rcx), %rcx
movslq 0x1c(%rsp), %rdx
imulq $0x18, %rdx, %rdx
addq %rdx, %rcx
cmpq (%rcx), %rax
jne 0x37a3ec
movl $0x1, 0x54(%rsp)
jmp 0x37a564
jmp 0x37a3ee
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x37a3b2
movzbl 0x3e(%rsp), %eax
cmpl $0x0, %eax
je 0x37a42a
movq 0x48(%rsp), %rax
cmpq $0x0, 0x10(%rax)
jne 0x37a42a
movq 0x40(%rsp), %rax
cmpb $0x0, 0x11(%rax)
jne 0x37a42a
movq 0x40(%rsp), %rcx
movq 0x48(%rsp), %rax
movq %rcx, 0x10(%rax)
jmp 0x37a42c
movq 0x48(%rsp), %rax
movl 0x18(%rax), %eax
movq 0x48(%rsp), %rcx
cmpl 0x1c(%rcx), %eax
jne 0x37a4f9
movq 0x48(%rsp), %rax
cmpl $0x0, 0x1c(%rax)
jne 0x37a498
movq 0x48(%rsp), %rax
movl $0x8, 0x1c(%rax)
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rax
movq 0x48(%rsp), %rcx
movslq 0x1c(%rcx), %rcx
imulq $0x18, %rcx, %rdi
callq *%rax
movq %rax, %rcx
movq 0x48(%rsp), %rax
movq %rcx, 0x20(%rax)
movq 0x48(%rsp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x37a496
movl $0x0, 0x54(%rsp)
jmp 0x37a564
jmp 0x37a4f7
movq 0x48(%rsp), %rax
movl 0x1c(%rax), %eax
shll %eax
movl %eax, 0xc(%rsp)
movq 0x28(%rsp), %rax
movq 0x20(%rax), %rax
movq 0x48(%rsp), %rcx
movq 0x20(%rcx), %rdi
movslq 0xc(%rsp), %rcx
imulq $0x18, %rcx, %rsi
callq *%rax
movq %rax, 0x10(%rsp)
cmpq $0x0, 0x10(%rsp)
jne 0x37a4dd
movl $0x0, 0x54(%rsp)
jmp 0x37a564
movl 0xc(%rsp), %ecx
movq 0x48(%rsp), %rax
movl %ecx, 0x1c(%rax)
movq 0x10(%rsp), %rcx
movq 0x48(%rsp), %rax
movq %rcx, 0x20(%rax)
jmp 0x37a4f9
movq 0x48(%rsp), %rax
movq 0x20(%rax), %rax
movq 0x48(%rsp), %rcx
movslq 0x18(%rcx), %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, 0x20(%rsp)
movq 0x40(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, (%rax)
movq 0x30(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, 0x10(%rax)
movb 0x3f(%rsp), %cl
movq 0x20(%rsp), %rax
movb %cl, 0x8(%rax)
cmpb $0x0, 0x3f(%rsp)
jne 0x37a54e
movq 0x40(%rsp), %rax
movb $0x1, 0x10(%rax)
movq 0x48(%rsp), %rax
movl 0x18(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x18(%rax)
movl $0x1, 0x54(%rsp)
movl 0x54(%rsp), %eax
addq $0x58, %rsp
retq
nopl (%rax)