// File: /workspace/github_c_makefile_star2_O3/WojciechMula[P]pyahocorasick/src/Automaton.c
// Function: automaton_iter_long
static PyObject*
automaton_iter_long(PyObject* self, PyObject* args) {
#define automaton ((Automaton*)self)

	PyObject* object;
	Py_ssize_t start;
	Py_ssize_t end;

	if (automaton->kind != AHOCORASICK) {
		PyErr_SetString(PyExc_AttributeError, "not an automaton yet; add some words and call make_automaton");
		return NULL;
	}

	object = PyTuple_GetItem(args, 0);
    if (object == NULL)
        return NULL;

    if (automaton->key_type == KEY_STRING) {
#ifdef PY3K
    #ifdef AHOCORASICK_UNICODE
        if (F(PyUnicode_Check)(object)) {
            start   = 0;
            #if PY_MINOR_VERSION >= 3
                end = PyUnicode_GET_LENGTH(object);
            #else
                end = PyUnicode_GET_SIZE(object);
            #endif
        }
        else {
            PyErr_SetString(PyExc_TypeError, "string required");
            return NULL;
        }
    #else
        if (F(PyBytes_Check)(object)) {
            start   = 0;
            end     = PyBytes_GET_SIZE(object);
        }
        else {
            PyErr_SetString(PyExc_TypeError, "bytes required");
            return NULL;
        }
    #endif
#else
        if (F(PyString_Check)(object)) {
            start   = 0;
            end     = PyString_GET_SIZE(object);
        } else {
            PyErr_SetString(PyExc_TypeError, "string required");
            return NULL;
        }
#endif
    }
    else {
        if (F(PyTuple_Check)(object)) {
            start = 0;
            end = PyTuple_GET_SIZE(object);
        } else {
            PyErr_SetString(PyExc_TypeError, "tuple required");
            return NULL;
        }
    }

	if (pymod_parse_start_end(args, 1, 2, start, end, &start, &end))
		return NULL;

	return automaton_search_iter_long_new(
		automaton,
		object,
		start,
		end
	);
#undef automaton
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x20, %rsp
cmpl $0x2, 0x10(%rdi)
jne 0x6c93
movq %rsi, %r12
movq %rdi, %rbx
xorl %r14d, %r14d
movq %rsi, %rdi
xorl %esi, %esi
callq 0x3140
testq %rax, %rax
je 0x6cac
movq %rax, %r15
cmpl $0x64, 0x18(%rbx)
movq 0x8(%rax), %rax
movq 0xa8(%rax), %rax
jne 0x6cbd
btl $0x1c, %eax
jb 0x6cd6
movq 0x9309(%rip), %rax      # 0xff90
movq (%rax), %rdi
leaq 0x4cb8(%rip), %rsi      # 0xb949
jmp 0x6ca4
movq 0x933e(%rip), %rax      # 0xffd8
movq (%rax), %rdi
leaq 0x4f72(%rip), %rsi      # 0xbc16
callq 0x3120
xorl %r14d, %r14d
movq %r14, %rax
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
btl $0x1a, %eax
jb 0x6d05
movq 0x92c6(%rip), %rax      # 0xff90
movq (%rax), %rdi
leaq 0x4c85(%rip), %rsi      # 0xb959
jmp 0x6ca4
movq $0x0, 0x10(%rsp)
testb $-0x80, 0x20(%r15)
jne 0x6d0e
leaq 0x4c41(%rip), %rdi      # 0xb92e
leaq 0x4a3e(%rip), %rsi      # 0xb732
leaq 0x4f58(%rip), %rcx      # 0xbc53
movl $0x3e0, %edx            # imm = 0x3E0
callq 0x3130
movq $0x0, 0x10(%rsp)
movq 0x10(%r15), %r8
leaq 0x18(%rsp), %rax
movq %r8, (%rax)
movq %rax, (%rsp)
xorl %r14d, %r14d
leaq 0x10(%rsp), %r9
movq %r12, %rdi
movl $0x1, %esi
movl $0x2, %edx
xorl %ecx, %ecx
callq 0x750c
testl %eax, %eax
jne 0x6cac
movq 0x10(%rsp), %r12
movq 0x18(%rsp), %r13
leaq 0x9d2d(%rip), %rdi      # 0x10a80
callq 0x32b0
testq %rax, %rax
je 0x6ca9
movq %rax, %r14
movq %rbx, 0x10(%rax)
movl 0x30(%rbx), %eax
movl %eax, 0x18(%r14)
movq %r15, 0x20(%r14)
movq 0x28(%rbx), %rax
movq %rax, 0x48(%r14)
movl $0x0, 0x60(%r14)
decl %r12d
movl %r12d, 0x5c(%r14)
movl %r13d, 0x64(%r14)
movl $0xffffffff, 0x58(%r14) # imm = 0xFFFFFFFF
movq $0x0, 0x50(%r14)
incq (%rbx)
incq (%r15)
movq %r14, %rdx
addq $0x28, %rdx
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%r14)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x45cd
testb %al, %al
jne 0x6cac
decq (%r14)
jne 0x6ca9
movq %r14, %rdi
callq 0x30d0
jmp 0x6ca9