// File: /workspace/github_c_makefile_star2_O0/genometools[P]genometools/src/external/expat-2.0.1/lib/xmlparse.c
// Function: externalEntityInitProcessor3
static enum XML_Error PTRCALL
externalEntityInitProcessor3(XML_Parser parser,
                             const char *start,
                             const char *end,
                             const char **endPtr)
{
  int tok;
  const char *next = start; /* XmlContentTok doesn't always set the last arg */
  eventPtr = start;
  tok = XmlContentTok(encoding, start, end, &next);
  eventEndPtr = next;

  switch (tok) {
  case XML_TOK_XML_DECL:
    {
      enum XML_Error result;
      result = processXmlDecl(parser, 1, start, next);
      if (result != XML_ERROR_NONE)
        return result;
      switch (ps_parsing) {
      case XML_SUSPENDED: 
        *endPtr = next;
        return XML_ERROR_NONE;
      case XML_FINISHED:
        return XML_ERROR_ABORTED;
      default:
        start = next;
      }
    }
    break;
  case XML_TOK_PARTIAL:
    if (!ps_finalBuffer) {
      *endPtr = start;
      return XML_ERROR_NONE;
    }
    return XML_ERROR_UNCLOSED_TOKEN;
  case XML_TOK_PARTIAL_CHAR:
    if (!ps_finalBuffer) {
      *endPtr = start;
      return XML_ERROR_NONE;
    }
    return XML_ERROR_PARTIAL_CHAR;
  }
  processor = externalEntityContentProcessor;
  tagLevel = 1;
  return externalEntityContentProcessor(parser, start, end, endPtr);
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movq %rdx, 0x28(%rsp)
movq %rcx, 0x20(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x30(%rsp), %rcx
movq 0x38(%rsp), %rax
movq %rcx, 0x210(%rax)
movq 0x38(%rsp), %rax
movq 0x120(%rax), %rdi
movq 0x8(%rdi), %rax
movq 0x30(%rsp), %rsi
movq 0x28(%rsp), %rdx
leaq 0x10(%rsp), %rcx
callq *%rax
movl %eax, 0x1c(%rsp)
movq 0x10(%rsp), %rcx
movq 0x38(%rsp), %rax
movq %rcx, 0x218(%rax)
movl 0x1c(%rsp), %eax
movl %eax, 0x8(%rsp)
subl $-0x2, %eax
je 0x38139e
jmp 0x3812cc
movl 0x8(%rsp), %eax
subl $-0x1, %eax
je 0x38136f
jmp 0x3812db
movl 0x8(%rsp), %eax
subl $0xc, %eax
jne 0x3813cd
jmp 0x3812ea
movq 0x38(%rsp), %rdi
movq 0x30(%rsp), %rdx
movq 0x10(%rsp), %rcx
movl $0x1, %esi
callq 0x3795c0
movl %eax, 0xc(%rsp)
cmpl $0x0, 0xc(%rsp)
je 0x38131b
movl 0xc(%rsp), %eax
movl %eax, 0x44(%rsp)
jmp 0x38140c
movq 0x38(%rsp), %rax
movl 0x378(%rax), %eax
movl %eax, 0x4(%rsp)
subl $0x2, %eax
je 0x381356
jmp 0x381331
movl 0x4(%rsp), %eax
subl $0x3, %eax
jne 0x381363
jmp 0x38133c
movq 0x10(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, (%rax)
movl $0x0, 0x44(%rsp)
jmp 0x38140c
movl $0x23, 0x44(%rsp)
jmp 0x38140c
movq 0x10(%rsp), %rax
movq %rax, 0x30(%rsp)
jmp 0x3813cd
movq 0x38(%rsp), %rax
cmpb $0x0, 0x37c(%rax)
jne 0x381394
movq 0x30(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, (%rax)
movl $0x0, 0x44(%rsp)
jmp 0x38140c
movl $0x5, 0x44(%rsp)
jmp 0x38140c
movq 0x38(%rsp), %rax
cmpb $0x0, 0x37c(%rax)
jne 0x3813c3
movq 0x30(%rsp), %rcx
movq 0x20(%rsp), %rax
movq %rcx, (%rax)
movl $0x0, 0x44(%rsp)
jmp 0x38140c
movl $0x6, 0x44(%rsp)
jmp 0x38140c
movq 0x38(%rsp), %rax
leaq -0xe09(%rip), %rcx      # 0x3805d0
movq %rcx, 0x200(%rax)
movq 0x38(%rsp), %rax
movl $0x1, 0x23c(%rax)
movq 0x38(%rsp), %rdi
movq 0x30(%rsp), %rsi
movq 0x28(%rsp), %rdx
movq 0x20(%rsp), %rcx
callq 0x3805d0
movl %eax, 0x44(%rsp)
movl 0x44(%rsp), %eax
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)