// File: /workspace/github_c_makefile_star2_O0/jondurbin[P]dre2/src/dre2_match.c
// Function: dre2_sn_mc
struct dre2_match_value dre2_sn_mc( struct dre2 *graph, unsigned char *input, int length, int *r_temp, int *reachable, int *state )
{
  unsigned char *pch;
  struct dre2_single_match result;
  struct dre2_match_value ret_val;
  int assertion_match;

  assertion_match = false;
  result.assertion_match = false;

  pch = input + graph->initial_skip;
  while ( pch - input <= length && *pch != '\0' && !graph->starting_chars[*pch] )
    *pch++;
  while ( pch - input <= length && *pch != '\0' )
  {
    if ( graph->starting_point == 0 )
    {
      result = dre2_matcher( graph, input, pch, graph->starting_point, DRE2_RIGHT, length, r_temp, reachable, state );
      if ( result.match != NULL )
      {
        ret_val.matched = true;
        ret_val.start_pos = pch - input;
        ret_val.end_pos = result.match - input + 1;
        return ret_val;
      }
      if ( result.skip_to != DRE2_INFINITE )
        pch = input + result.skip_to;
    } else
    {
      result = dre2_matcher( graph, input, pch, graph->starting_point, DRE2_LEFT, length, r_temp, reachable, state );
      if ( result.match != NULL )
      {
        assertion_match = result.assertion_match;
        ret_val.start_pos = result.match - input;
        result = dre2_matcher( graph, input, pch, graph->starting_point, DRE2_RIGHT, length, r_temp, reachable, state );
        if ( result.match != NULL )
        {
          ret_val.matched = true;
          ret_val.end_pos = result.match - input + 1;
          return ret_val;
        }
        if ( assertion_match )
          pch = input + length;
        else if( result.skip_to != DRE2_INFINITE )
          pch = input + result.skip_to;
      }
      if ( result.assertion_match )
        pch = input + length;
      if ( result.skip_to != DRE2_INFINITE )
        pch = input + result.skip_to;
    }
    *pch++;
    while ( pch - input <= length && *pch != 0 && !graph->starting_chars[*pch] )
      *pch++;
  }
  ret_val.matched = false;
  return ret_val;
}

// Assembly:
pushq %rbx
subq $0xe0, %rsp
movq %rdi, 0xc8(%rsp)
movq %rsi, 0xc0(%rsp)
movl %edx, 0xbc(%rsp)
movq %rcx, 0xb0(%rsp)
movq %r8, 0xa8(%rsp)
movq %r9, 0xa0(%rsp)
movl $0x0, 0x7c(%rsp)
movl $0x0, 0x80(%rsp)
movq 0xc0(%rsp), %rax
movq 0xc8(%rsp), %rcx
movslq 0x864(%rcx), %rcx
addq %rcx, %rax
movq %rax, 0x98(%rsp)
movq 0x98(%rsp), %rcx
movq 0xc0(%rsp), %rax
subq %rax, %rcx
movslq 0xbc(%rsp), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
movb %al, 0x2f(%rsp)
jg 0xaa3f
movq 0x98(%rsp), %rax
movzbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, 0x2f(%rsp)
je 0xaa3f
movq 0xc8(%rsp), %rax
movq 0x418(%rax), %rax
movq 0x98(%rsp), %rcx
movzbl (%rcx), %ecx
cmpl $0x0, (%rax,%rcx,4)
setne %al
xorb $-0x1, %al
movb %al, 0x2f(%rsp)
movb 0x2f(%rsp), %al
testb $0x1, %al
jne 0xaa49
jmp 0xaa62
movq 0x98(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x98(%rsp)
jmp 0xa9dc
jmp 0xaa64
movq 0x98(%rsp), %rcx
movq 0xc0(%rsp), %rax
subq %rax, %rcx
movslq 0xbc(%rsp), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
movb %al, 0x2e(%rsp)
jg 0xaa9f
movq 0x98(%rsp), %rax
movzbl (%rax), %eax
cmpl $0x0, %eax
setne %al
movb %al, 0x2e(%rsp)
movb 0x2e(%rsp), %al
testb $0x1, %al
jne 0xaaac
jmp 0xae8d
movq 0xc8(%rsp), %rax
cmpl $0x0, 0x410(%rax)
jne 0xabcd
movq 0xc8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
movq 0x98(%rsp), %rcx
movq 0xc8(%rsp), %rax
movl 0x410(%rax), %r8d
movl 0xbc(%rsp), %ebx
movq 0xb0(%rsp), %r11
movq 0xa8(%rsp), %r10
movq 0xa0(%rsp), %rax
leaq 0x60(%rsp), %rdi
movl $0x1, %r9d
movl %ebx, (%rsp)
movq %r11, 0x8(%rsp)
movq %r10, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x2270
movq 0x60(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x68(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x90(%rsp)
cmpq $0x0, 0x90(%rsp)
je 0xaba3
movl $0x1, 0xd0(%rsp)
movq 0x98(%rsp), %rax
movq 0xc0(%rsp), %rcx
subq %rcx, %rax
movl %eax, 0xd8(%rsp)
movq 0x90(%rsp), %rax
movq 0xc0(%rsp), %rcx
subq %rcx, %rax
addq $0x1, %rax
movl %eax, 0xdc(%rsp)
jmp 0xae98
cmpl $-0x1, 0x88(%rsp)
je 0xabc8
movq 0xc0(%rsp), %rax
movslq 0x88(%rsp), %rcx
addq %rcx, %rax
movq %rax, 0x98(%rsp)
jmp 0xadee
movq 0xc8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
movq 0x98(%rsp), %rcx
movq 0xc8(%rsp), %rax
movl 0x410(%rax), %r8d
movl 0xbc(%rsp), %ebx
movq 0xb0(%rsp), %r11
movq 0xa8(%rsp), %r10
movq 0xa0(%rsp), %rax
leaq 0x48(%rsp), %rdi
xorl %r9d, %r9d
movl %ebx, (%rsp)
movq %r11, 0x8(%rsp)
movq %r10, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x2270
movq 0x48(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x58(%rsp), %rax
movq %rax, 0x90(%rsp)
cmpq $0x0, 0x90(%rsp)
je 0xada2
movl 0x80(%rsp), %eax
movl %eax, 0x7c(%rsp)
movq 0x90(%rsp), %rax
movq 0xc0(%rsp), %rcx
subq %rcx, %rax
movl %eax, 0xd8(%rsp)
movq 0xc8(%rsp), %rsi
movq 0xc0(%rsp), %rdx
movq 0x98(%rsp), %rcx
movq 0xc8(%rsp), %rax
movl 0x410(%rax), %r8d
movl 0xbc(%rsp), %ebx
movq 0xb0(%rsp), %r11
movq 0xa8(%rsp), %r10
movq 0xa0(%rsp), %rax
leaq 0x30(%rsp), %rdi
movl $0x1, %r9d
movl %ebx, (%rsp)
movq %r11, 0x8(%rsp)
movq %r10, 0x10(%rsp)
movq %rax, 0x18(%rsp)
callq 0x2270
movq 0x30(%rsp), %rax
movq %rax, 0x80(%rsp)
movq 0x38(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x90(%rsp)
cmpq $0x0, 0x90(%rsp)
je 0xad55
movl $0x1, 0xd0(%rsp)
movq 0x90(%rsp), %rax
movq 0xc0(%rsp), %rcx
subq %rcx, %rax
addq $0x1, %rax
movl %eax, 0xdc(%rsp)
jmp 0xae98
cmpl $0x0, 0x7c(%rsp)
je 0xad79
movq 0xc0(%rsp), %rax
movslq 0xbc(%rsp), %rcx
addq %rcx, %rax
movq %rax, 0x98(%rsp)
jmp 0xada0
cmpl $-0x1, 0x88(%rsp)
je 0xad9e
movq 0xc0(%rsp), %rax
movslq 0x88(%rsp), %rcx
addq %rcx, %rax
movq %rax, 0x98(%rsp)
jmp 0xada0
jmp 0xada2
cmpl $0x0, 0x80(%rsp)
je 0xadc7
movq 0xc0(%rsp), %rax
movslq 0xbc(%rsp), %rcx
addq %rcx, %rax
movq %rax, 0x98(%rsp)
cmpl $-0x1, 0x88(%rsp)
je 0xadec
movq 0xc0(%rsp), %rax
movslq 0x88(%rsp), %rcx
addq %rcx, %rax
movq %rax, 0x98(%rsp)
jmp 0xadee
movq 0x98(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x98(%rsp)
movq 0x98(%rsp), %rcx
movq 0xc0(%rsp), %rax
subq %rax, %rcx
movslq 0xbc(%rsp), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
movb %al, 0x2d(%rsp)
jg 0xae65
movq 0x98(%rsp), %rax
movzbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, 0x2d(%rsp)
je 0xae65
movq 0xc8(%rsp), %rax
movq 0x418(%rax), %rax
movq 0x98(%rsp), %rcx
movzbl (%rcx), %ecx
cmpl $0x0, (%rax,%rcx,4)
setne %al
xorb $-0x1, %al
movb %al, 0x2d(%rsp)
movb 0x2d(%rsp), %al
testb $0x1, %al
jne 0xae6f
jmp 0xae88
movq 0x98(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x98(%rsp)
jmp 0xae02
jmp 0xaa64
movl $0x0, 0xd0(%rsp)
movq 0xd0(%rsp), %rax
movq 0xd8(%rsp), %rdx
addq $0xe0, %rsp
popq %rbx
retq
nopw %cs:(%rax,%rax)