// File: /workspace/github_c_makefile_star2_O0/heltilda[P]cicada/intrpt.c
// Function: searchMember
void searchMember(ccInt soughtMemberID, member **stemMember, ccInt *stemMemberNumber, ccBool allowAddMember, ccBool ifHiddenMember)
{
    searchPath *searchPosition;
    ccInt rtrn;
    
    searchPosition = pcSearchPath;
    searchView = baseView;
    
    do  {
        searchView.windowPtr = searchPosition->jamb;
        rtrn = findMemberID(searchView.windowPtr->variable_ptr, soughtMemberID, stemMember, stemMemberNumber, allowAddMember, ifHiddenMember);
        if (rtrn == passed)  {
            return;    }
        else if (rtrn != member_not_found_err)  {
            setError(rtrn, pcCodePtr);
            return;    }
        
        if (searchPosition->stem == NULL)  break;
        else if (searchPosition->stemIndices == 0)
            searchView.offset = 0;
        else
            searchView.offset = (searchView.offset - searchView.windowPtr->offset) / searchPosition->stemIndices;
        
        if (searchView.width > 1)  searchView.width /= searchPosition->stemIndices;
        else if (searchPosition->stemIndices == 0)  {           // if we stepped through a 0-sized member, recalculate indices
            searchView.width = 1;
            searchPath *SP2 = searchPosition->stem;
            while (SP2->stem != NULL)  {
                searchView.width *= SP2->stemIndices;
                SP2 = SP2->stem;
        }   }
        if (searchView.multipleIndices)  searchView.multipleIndices = (searchView.width != 1);
        
        searchPosition = searchPosition->stem;
    }  while (ccTrue);
    
    setError(member_not_found_err, pcCodePtr);
    return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movb %r8b, %al
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movb %cl, -0x19(%rbp)
movb %al, -0x1a(%rbp)
leaq 0x1a2dd(%rip), %rax     # 0x2c750
movq 0x170(%rax), %rax
movq %rax, -0x28(%rbp)
leaq 0x1a2cb(%rip), %rax     # 0x2c750
movq 0x140(%rax), %rcx
movq %rcx, 0x158(%rax)
movq 0x148(%rax), %rcx
movq %rcx, 0x160(%rax)
movq 0x150(%rax), %rcx
movq %rcx, 0x168(%rax)
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rcx
leaq 0x1a292(%rip), %rax     # 0x2c750
movq %rcx, 0x158(%rax)
leaq 0x1a284(%rip), %rax     # 0x2c750
movq 0x158(%rax), %rax
movq 0x10(%rax), %rdi
movl -0x4(%rbp), %esi
movq -0x10(%rbp), %rdx
movq -0x18(%rbp), %rcx
movb -0x19(%rbp), %al
movsbl %al, %r8d
movsbl -0x1a(%rbp), %r9d
callq 0x12690
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
jne 0x12501
jmp 0x12687
cmpl $0x17, -0x2c(%rbp)
je 0x12522
movl -0x2c(%rbp), %edi
leaq 0x1a23f(%rip), %rax     # 0x2c750
movq 0xb8(%rax), %rsi
callq 0xf740
jmp 0x12687
jmp 0x12524
movq -0x28(%rbp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x12534
jmp 0x1266f
movq -0x28(%rbp), %rax
cmpl $0x0, 0x28(%rax)
jne 0x12551
leaq 0x1a20b(%rip), %rax     # 0x2c750
movl $0x0, 0x160(%rax)
jmp 0x12586
leaq 0x1a1f8(%rip), %rax     # 0x2c750
movl 0x160(%rax), %eax
leaq 0x1a1eb(%rip), %rcx     # 0x2c750
movq 0x158(%rcx), %rcx
subl 0x18(%rcx), %eax
movq -0x28(%rbp), %rcx
cltd
idivl 0x28(%rcx)
movl %eax, %ecx
leaq 0x1a1d0(%rip), %rax     # 0x2c750
movl %ecx, 0x160(%rax)
jmp 0x12588
leaq 0x1a1c1(%rip), %rax     # 0x2c750
cmpl $0x1, 0x164(%rax)
jle 0x125c0
movq -0x28(%rbp), %rax
movl 0x28(%rax), %ecx
leaq 0x1a1aa(%rip), %rax     # 0x2c750
movl 0x164(%rax), %eax
cltd
idivl %ecx
movl %eax, %ecx
leaq 0x1a198(%rip), %rax     # 0x2c750
movl %ecx, 0x164(%rax)
jmp 0x12626
movq -0x28(%rbp), %rax
cmpl $0x0, 0x28(%rax)
jne 0x12624
leaq 0x1a17f(%rip), %rax     # 0x2c750
movl $0x1, 0x164(%rax)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
cmpq $0x0, 0x20(%rax)
je 0x12622
movq -0x38(%rbp), %rax
movl 0x28(%rax), %ecx
leaq 0x1a150(%rip), %rax     # 0x2c750
imull 0x164(%rax), %ecx
leaq 0x1a142(%rip), %rax     # 0x2c750
movl %ecx, 0x164(%rax)
movq -0x38(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x38(%rbp)
jmp 0x125e7
jmp 0x12624
jmp 0x12626
leaq 0x1a123(%rip), %rax     # 0x2c750
cmpb $0x0, 0x168(%rax)
je 0x12657
leaq 0x1a113(%rip), %rax     # 0x2c750
cmpl $0x1, 0x164(%rax)
setne %cl
andb $0x1, %cl
leaq 0x1a0ff(%rip), %rax     # 0x2c750
movb %cl, 0x168(%rax)
movq -0x28(%rbp), %rax
movq 0x20(%rax), %rax
movq %rax, -0x28(%rbp)
movb $0x1, %al
testb $0x1, %al
jne 0x124af
jmp 0x1266f
leaq 0x1a0da(%rip), %rax     # 0x2c750
movq 0xb8(%rax), %rsi
movl $0x17, %edi
callq 0xf740
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)