LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/combination.cpp
// Function: pictcore::Combination::ApplyExclusion(pictcore::Exclusion&)
void Combination::ApplyExclusion( Exclusion& excl )
{
    // only if this exclusion's parameters exist in the combo
    for( Exclusion::iterator it = excl.begin(); it != excl.end(); ++it )
    {
        ParamCollection::iterator ip = find( m_params.begin(), m_params.end(), it->first );
        if( ip == m_params.end() ) return;
    }

    applyExclusion( excl, 0, m_params.begin() );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq 0x18(%rsi), %r15
leaq 0x8(%rsi), %r12
cmpq %r12, %r15
sete %bpl
je 0x620e
movq 0x8(%r14), %rdi
movq 0x10(%r14), %rsi
leaq 0x20(%r15), %rdx
callq 0x6317
cmpq 0x10(%r14), %rax
je 0x6209
movq %r15, %rdi
callq 0x54b0
cmpq %r12, %rax
sete %bpl
je 0x620e
movq %rax, %r15
movq 0x8(%r14), %rdi
movq 0x10(%r14), %rsi
movq %rax, %rdx
addq $0x20, %rdx
jmp 0x61d9
testb %bpl, %bpl
je 0x6227
movq 0x8(%r14), %rcx
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x60dc
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/combination.cpp
// Function: pictcore::Combination::ViolatesExclusion()
bool Combination::ViolatesExclusion()
{
    size_t nKey = 0;
    for( ParamCollection::iterator iter = m_params.begin(); iter != m_params.end(); ++iter )
    {
        nKey *= ( *iter )->GetValueCount();
        size_t nCurrentVal = ( *iter )->GetLast();
        assert( ( *iter )->GetBoundCount() );
        nKey += nCurrentVal;
    }

    return ( EXCLUDED == m_bitvec[ nKey ] );
}

// Assembly:
pushq %rax
movq 0x8(%rdi), %rcx
movq 0x10(%rdi), %rdx
xorl %eax, %eax
cmpq %rdx, %rcx
je 0x625b
movq (%rcx), %rsi
cmpb $0x0, 0x3d(%rsi)
je 0x6268
movslq 0x38(%rsi), %r8
imulq %r8, %rax
addq 0x30(%rsi), %rax
addq $0x8, %rcx
jmp 0x623b
movq 0x20(%rdi), %rcx
cmpb $-0x1, (%rcx,%rax)
sete %al
popq %rcx
retq
leaq 0x1fd95(%rip), %rdi     # 0x26004
leaq 0x1fda9(%rip), %rsi     # 0x2601f
leaq 0x1fe6c(%rip), %rcx     # 0x260e9
movl $0xeb, %edx
callq 0x52c0
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/combination.cpp
// Function: pictcore::Combination::SetOpen(int)
void Combination::SetOpen( int index )
{
    assert( index < m_range );
    if( OPEN != m_bitvec[ index ] )
    {
        m_bitvec[ index ] = OPEN;
        ++m_openCount;
        ++m_model->GlobalZerosCount;
    }
}

// Assembly:
cmpl %esi, 0x28(%rdi)
jle 0x62a8
movq 0x20(%rdi), %rax
movslq %esi, %rcx
cmpb $0x0, (%rax,%rcx)
je 0x62a7
movb $0x0, (%rax,%rcx)
incl 0x2c(%rdi)
movq 0x38(%rdi), %rax
incl (%rax)
retq
pushq %rax
leaq 0x1fe69(%rip), %rdi     # 0x26119
leaq 0x1fd68(%rip), %rsi     # 0x2601f
leaq 0x1fe6b(%rip), %rcx     # 0x26129
movl $0xf9, %edx
callq 0x52c0
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/deriver.cpp
// Function: pictcore::ExclusionDeriver::consistent(pictcore::Exclusion&, pictcore::Exclusion&)
bool ExclusionDeriver::consistent( Exclusion &aa, Exclusion &bb )
{
    // make sure the smaller one is in the outer loop
    Exclusion *a;
    Exclusion *b;
    if( aa.size() < bb.size() )
    {
        a = &aa;
        b = &bb;
    }
    else
    {
        a = &bb;
        b = &aa;
    }

    Exclusion::iterator ib = b->begin();
    for( Exclusion::iterator ia = a->begin(); ia != a->end(); ++ia )
    {
        if( m_currentParam == ia->first )
            continue;

        // move ib to see if we can find ia's parameter
        // ia and ib are sorted by (i->first)->GetSequence() asc then i->second
        while( ib != b->end() && ( ia->first )->GetSequence() > ( ib->first )->GetSequence() )
            ++ib;

        // end of b, return true
        if( ib == b->end() )
            return true;

        // see if params match; if not, move on
        if( ( ia->first )->GetSequence() != ( ib->first )->GetSequence() )
            continue;

        // params match, what about values
        if( ia->second != ib->second )
            return false;
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq 0x28(%rsi), %rax
movq 0x28(%rdx), %rcx
cmpq %rcx, %rax
movq %rdx, %rsi
cmovbq %rbx, %rsi
movq 0x18(%rsi), %r14
addq $0x8, %rsi
movq %rsi, 0x10(%rsp)
cmpq %rsi, %r14
sete %bpl
je 0x646b
cmpq %rcx, %rax
cmovbq %rdx, %rbx
movq 0x18(%rbx), %r15
movq 0x48(%rdi), %rax
movq %rax, 0x8(%rsp)
addq $0x8, %rbx
movq 0x20(%r14), %r13
cmpq %r13, 0x8(%rsp)
je 0x6453
cmpq %rbx, %r15
je 0x6437
movl 0x2c(%r13), %r12d
movq 0x20(%r15), %rax
cmpl 0x2c(%rax), %r12d
jle 0x6437
movq %r15, %rdi
callq 0x54b0
movq %rax, %r15
cmpq %rbx, %rax
jne 0x641d
cmpq %rbx, %r15
je 0x646d
movl 0x2c(%r13), %eax
movq 0x20(%r15), %rcx
cmpl 0x2c(%rcx), %eax
jne 0x6453
movl 0x28(%r14), %eax
cmpl 0x28(%r15), %eax
jne 0x6471
movq %r14, %rdi
callq 0x54b0
movq %rax, %r14
cmpq 0x10(%rsp), %r14
sete %bpl
jne 0x6409
jmp 0x6473
jmp 0x6473
movb $0x1, %al
jmp 0x6473
xorl %eax, %eax
orb %al, %bpl
andb $0x1, %bpl
movl %ebp, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/deriver.cpp
// Function: pictcore::ExclusionDeriver::AddExclusion(pictcore::Exclusion&, bool)
pair<ExclusionCollection::iterator, bool> ExclusionDeriver::AddExclusion( Exclusion& excl, bool checkIfInCollection )
{
    // if there's already an exclusion that's broader, do not add
    if( checkIfInCollection )
    {
        if( alreadyInCollection( excl ) )
        {
            return make_pair( m_exclusions.end(), false );
        }
    }

    // now add
    pair<ExclusionCollection::iterator, bool> result = m_exclusions.insert( excl );
    if( result.second )
    {
        // later, we will attempt to find sorted lists so 
        // the lookup structure should keep them sorted, too
        sort( excl.lbegin(), excl.lend() );
        m_lookup.insert( excl.GetList() );
    }

    return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
testl %edx, %edx
je 0x6532
leaq 0x30(%r14), %r15
movq 0x30(%r14), %r12
movq 0x38(%r14), %r13
cmpq %r13, %r12
je 0x64e3
movq %r13, %rax
subq %r12, %rax
sarq $0x4, %rax
bsrq %rax, %rdx
xorl $0x3f, %edx
addl %edx, %edx
xorq $0x7e, %rdx
movq %r12, %rdi
movq %r13, %rsi
callq 0x8232
movq %r12, %rdi
movq %r13, %rsi
callq 0x82e5
leaq 0xb0(%rbx), %r12
movq %r12, %rdi
movq %r15, %rsi
callq 0x72e4
testq %rax, %rax
je 0x651a
addq $0x20, %rbx
xorl %ebp, %ebp
movq %rbx, %r15
jmp 0x6598
movl %eax, %ebp
movq %r12, %rdi
movq %r15, %rsi
callq 0x72e4
testq %rax, %rax
jne 0x652d
movq 0x30(%r14), %rdi
movq 0x38(%r14), %rsi
callq 0x73c7
testb %al, %al
jne 0x6508
jmp 0x6532
testb %bpl, %bpl
jne 0x64fa
leaq 0x18(%rbx), %rdi
movq %r14, %rsi
callq 0x8066
movq %rax, %r15
movl %edx, %ebp
testb $0x1, %dl
je 0x6598
leaq 0x30(%r14), %r12
movq 0x30(%r14), %r13
movq 0x38(%r14), %r14
cmpq %r14, %r13
je 0x6586
movq %r14, %rax
subq %r13, %rax
sarq $0x4, %rax
bsrq %rax, %rdx
xorl $0x3f, %edx
addl %edx, %edx
xorq $0x7e, %rdx
movq %r13, %rdi
movq %r14, %rsi
callq 0x8232
movq %r13, %rdi
movq %r14, %rsi
callq 0x82e5
addq $0xb0, %rbx
movq %rbx, %rdi
movq %r12, %rsi
callq 0x6aa0
movq %r15, %rax
movl %ebp, %edx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/deriver.cpp
// Function: pictcore::ExclusionDeriver::peformDelete()
void ExclusionDeriver::peformDelete()
{
    if( !m_deletedAtLeastOne ) return;

    //
    // todo:
    // This approach must be changed, we should be removing unnecessary links instead of recreating them
    // For now however, the recreation seems safer and works fast enough
    //

    // actually delete all marked as deleted
    ExclusionCollection::iterator ie = m_exclusions.begin();
    while( ie != m_exclusions.end() )
    {
        if( ie->isDeleted() )
        {
            Exclusion* pExcl = const_cast<Exclusion*>( &*ie );
            m_lookup.erase( pExcl->GetList() );
            ie = __map_erase( m_exclusions, ie );
        }
        else
            ++ie;
    }

    // recreate links to params
    for( Parameter* param : m_parameters )
    {
        param->ClearExclusions();
    }

    for( ie = m_exclusions.begin(); ie != m_exclusions.end(); ++ie )
    {
        AddExclusionParamBackPtrs( ie );
    }

    // prepare for the next round
    m_deletedAtLeastOne = false;
    DOUT( L"obsolete exclusions removed, now have: " << static_cast<int>( m_exclusions.size() ) << L"\n" );
}

// Assembly:
cmpb $0x1, 0xb8(%rdi)
jne 0x6754
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x30(%rdi), %r12
leaq 0x20(%rdi), %rbp
cmpq %rbp, %r12
je 0x66e4
leaq 0x18(%rbx), %r14
leaq 0xb0(%rbx), %r15
cmpb $0x1, 0x68(%r12)
jne 0x66cf
leaq 0x50(%r12), %rsi
movq %r15, %rdi
callq 0x88ae
testq %rax, %rax
je 0x66af
movb $0x0, 0x30(%rax)
movq %rbp, %r13
cmpq %r12, %rbp
je 0x66da
movq %r12, %rdi
callq 0x54b0
movq %rax, %r13
movq %r14, %rdi
movq %r12, %rsi
callq 0x890e
jmp 0x66da
movq %r12, %rdi
callq 0x54b0
movq %rax, %r13
movq %r13, %r12
cmpq %rbp, %r13
jne 0x6691
jmp 0x66e7
movq %r12, %r13
movq %r13, (%rsp)
movq (%rbx), %r14
movq 0x8(%rbx), %r15
cmpq %r15, %r14
je 0x6713
movq (%r14), %rdi
movl $0x0, 0xc8(%rdi)
addq $0x58, %rdi
callq 0x727a
addq $0x8, %r14
jmp 0x66f2
movq 0x30(%rbx), %r14
movq %r14, (%rsp)
cmpq %rbp, %r14
je 0x673f
movq %rsp, %r15
movq %r15, %rdi
callq 0x661e
movq %r14, %rdi
callq 0x54b0
movq %rax, %r14
movq %rax, (%rsp)
cmpq %rbp, %rax
jne 0x6723
movb $0x0, 0xb8(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/trie.h
// Function: trie<std::vector<std::pair<pictcore::Parameter*, int>, std::allocator<std::pair<pictcore::Parameter*, int>>>>::insert(std::vector<std::pair<pictcore::Parameter*, int>, std::allocator<std::pair<pictcore::Parameter*, int>>>&)
bool insert( Col &t )
    {
        trienode<typename Col::value_type>* current = m_root;
        for( typename Col::iterator ic = t.begin(); ic != t.end(); ++ic )
        {
            typename TNodeCol::iterator found;
            found = current->children.find( *ic );
            if( found == current->children.end() )
            {
                trienode< typename Col::value_type > *node = NULL;

                try
                {
                    node = new trienode < typename Col::value_type >;
                }
                catch( std::bad_alloc e )
                {
                    return( false );
                }

                std::pair<typename TNodeCol::iterator, bool> ret = current->children.insert( make_pair( *ic, node ) );
                if( !ret.second ) return( false );

                found = ret.first;
            }
            current = found->second;
        }
        current->valid = true;

        return( true );
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq (%rdi), %r14
movq (%rsi), %r12
cmpq 0x8(%rsi), %r12
sete %bl
je 0x6b55
movq %rsi, %r15
movq %rsp, %r13
movq %r14, %rdi
movq %r12, %rsi
callq 0x735a
leaq 0x8(%r14), %rcx
cmpq %rcx, %rax
jne 0x6b27
movl $0x38, %edi
callq 0x53c0
movq %rax, %rcx
addq $0x8, %rcx
movl $0x0, 0x8(%rax)
xorl %ebp, %ebp
movq %rbp, 0x10(%rax)
movq %rcx, 0x18(%rax)
movq %rcx, 0x20(%rax)
movq %rbp, 0x28(%rax)
movb $0x0, 0x30(%rax)
movups (%r12), %xmm0
movaps %xmm0, (%rsp)
movq %rax, 0x10(%rsp)
movq %r14, %rdi
movq %r13, %rsi
callq 0x871e
testb $0x1, %dl
je 0x6b2e
movq 0x30(%rax), %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x6b55
addq $0x10, %r12
cmpq 0x8(%r15), %r12
sete %bl
jne 0x6ac7
jmp 0x6b55
movq %rax, %rdi
cmpl $0x1, %edx
jne 0x6b73
movl %edx, %esi
callq 0x5770
xorl %ebp, %ebp
jmp 0x6b2e
testb $0x1, %bl
je 0x6b5f
movb $0x1, 0x30(%r14)
andb $0x1, %bl
movl %ebx, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x56a0
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/trie.h
// Function: trie<std::vector<std::pair<pictcore::Parameter*, int>, std::allocator<std::pair<pictcore::Parameter*, int>>>>::pfind_prefix(std::vector<std::pair<pictcore::Parameter*, int>, std::allocator<std::pair<pictcore::Parameter*, int>>>&)
trienode<typename Col::value_type>* pfind_prefix( Col &t )
    {
        trienode<typename Col::value_type> *current = m_root;
        for( typename Col::iterator ic = t.begin(); ic != t.end(); ++ic )
        {
            typename TNodeCol::iterator found = current->children.find( *ic );
            if( found == current->children.end() ) return( NULL );

            current = found->second;

            if( current->valid ) return( current );
        }

        return( current->valid ? current : NULL );
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq (%rdi), %rbx
movq (%rsi), %r12
cmpq 0x8(%rsi), %r12
sete %bpl
je 0x733d
movq %rsi, %r15
movq %rbx, %rdi
movq %r12, %rsi
callq 0x735a
leaq 0x8(%rbx), %rcx
cmpq %rcx, %rax
je 0x7324
movq 0x30(%rax), %rbx
movb 0x30(%rbx), %al
testb %al, %al
cmovneq %rbx, %r14
xorb $0x1, %al
jmp 0x7329
xorl %r14d, %r14d
xorl %eax, %eax
testb %al, %al
je 0x733d
addq $0x10, %r12
cmpq 0x8(%r15), %r12
sete %bpl
jne 0x72ff
jmp 0x733d
testb $0x1, %bpl
je 0x734e
xorl %r14d, %r14d
cmpb $0x0, 0x30(%rbx)
cmovneq %rbx, %r14
movq %r14, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/generator.h
// Function: pictcore::Exclusion::insert(std::pair<pictcore::Parameter*, int> const&)
std::pair<iterator, bool> insert( const ExclusionTerm& Term )
    {
        std::pair<iterator, bool> ret = col.insert( Term );
        if( ret.second ) vec.push_back( Term );
        assert( col.size() == vec.size() );
        return ret;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r15
movq %rdi, %rbx
callq 0x792e
movq %rax, %r14
movl %edx, %ebp
testb $0x1, %dl
je 0x7550
movq 0x38(%rbx), %rsi
cmpq 0x40(%rbx), %rsi
je 0x7544
movups (%r15), %xmm0
movups %xmm0, (%rsi)
addq $0x10, 0x38(%rbx)
jmp 0x7550
leaq 0x30(%rbx), %rdi
movq %r15, %rdx
callq 0x7a68
movq 0x38(%rbx), %rax
subq 0x30(%rbx), %rax
sarq $0x4, %rax
cmpq %rax, 0x28(%rbx)
jne 0x7572
movq %r14, %rax
movl %ebp, %edx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1ecf5(%rip), %rdi     # 0x2626e
leaq 0x1ec62(%rip), %rsi     # 0x261e2
leaq 0x1ed00(%rip), %rcx     # 0x26287
movl $0x10a, %edx            # imm = 0x10A
callq 0x52c0
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/trie.h
// Function: trie<std::vector<std::pair<pictcore::Parameter*, int>, std::allocator<std::pair<pictcore::Parameter*, int>>>>::pfind(std::vector<std::pair<pictcore::Parameter*, int>, std::allocator<std::pair<pictcore::Parameter*, int>>>&)
trienode<typename Col::value_type>* pfind( Col &t )
    {
        trienode<typename Col::value_type> *current = m_root;
        for( typename Col::iterator ic = t.begin(); ic != t.end(); ++ic )
        {
            typename TNodeCol::iterator found = current->children.find( *ic );
            if( found == current->children.end() ) return( NULL );

            current = found->second;
        }
        return( current->valid ? current : NULL );
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq (%rdi), %rbx
movq (%rsi), %r15
cmpq 0x8(%rsi), %r15
sete %bpl
je 0x88f3
movq %rsi, %r14
movq %rbx, %rdi
movq %r15, %rsi
callq 0x735a
leaq 0x8(%rbx), %rcx
cmpq %rcx, %rax
je 0x88e0
movq 0x30(%rax), %rbx
cmpq %rcx, %rax
je 0x88f3
addq $0x10, %r15
cmpq 0x8(%r14), %r15
sete %bpl
jne 0x88c8
xorl %eax, %eax
testb $0x1, %bpl
je 0x8903
cmpb $0x0, 0x30(%rbx)
cmovneq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/exclusion.cpp
// Function: contained
bool contained( Exclusion &a, Exclusion &b )
{
    if( b.size() < a.size() ) return( false );

    Exclusion::iterator ib = b.begin();
    for( Exclusion::iterator ia = a.begin(); ia != a.end(); ++ia )
    {
        // move ib until pointers of ia and ib match
        while( ib != b.end() && ( ia->first )->GetSequence() != ( ib->first )->GetSequence() )
        {
            ++ib;
        }

        // end of b, return true only if also end of a
        if( ib == b.end() ) return ia == a.end();

        // pointers match, what about values
        if( ia->second != ib->second ) return false;
    }
    return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq 0x28(%rsi), %rax
cmpq 0x28(%rdi), %rax
jae 0x8af9
xorl %ebx, %ebx
jmp 0x8b6e
movq %rdi, %r14
movq 0x18(%rdi), %r12
addq $0x8, %r14
cmpq %r14, %r12
sete %bl
je 0x8b64
movq %rsi, %r15
movq 0x18(%rsi), %r13
addq $0x8, %r15
cmpq %r15, %r13
je 0x8b3d
movq 0x20(%r12), %rax
movl 0x2c(%rax), %ebp
movq 0x20(%r13), %rax
cmpl 0x2c(%rax), %ebp
je 0x8b3d
movq %r13, %rdi
callq 0x54b0
movq %rax, %r13
cmpq %r15, %rax
jne 0x8b24
cmpq %r15, %r13
je 0x8b66
movl 0x28(%r12), %eax
cmpl 0x28(%r13), %eax
jne 0x8b60
movq %r12, %rdi
callq 0x54b0
movq %rax, %r12
cmpq %r14, %rax
sete %bl
jne 0x8b17
xorl %eax, %eax
jmp 0x8b6c
jmp 0x8b6c
cmpq %r14, %r12
sete %al
orb %al, %bl
andb $0x1, %bl
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/exclusion.cpp
// Function: compareExclusionTerms
int compareExclusionTerms( const ExclusionTerm& op1, const ExclusionTerm& op2 )
{
    assert( (( op1.first == op2.first ) && ( ( op1.first )->GetSequence() == ( op2.first )->GetSequence() ))
         || (( op1.first != op2.first ) && ( ( op1.first )->GetSequence() != ( op2.first )->GetSequence() )) );

    if( op1.first != op2.first )
        // return op1.first < op2.first ? -1 : 1;
        return ( op1.first )->GetSequence() < ( op2.first )->GetSequence() ? -1 : 1;
    else
        if( op1.second != op2.second )
            return op1.second < op2.second ? -1 : 1;
        else
            return 0;
}

// Assembly:
movq (%rdi), %rcx
movq (%rsi), %rax
cmpq %rax, %rcx
jne 0x8b9a
movl 0x2c(%rcx), %edx
cmpl 0x2c(%rax), %edx
je 0x8ba2
cmpq %rax, %rcx
je 0x8bd2
movl 0x2c(%rcx), %edx
cmpl 0x2c(%rax), %edx
je 0x8bd2
cmpq %rax, %rcx
je 0x8bba
movl 0x2c(%rcx), %ecx
xorl %edx, %edx
cmpl 0x2c(%rax), %ecx
setge %dl
leal -0x1(,%rdx,2), %eax
retq
movl 0x8(%rsi), %ecx
xorl %eax, %eax
cmpl %ecx, 0x8(%rdi)
je 0x8bd1
setge %al
movzbl %al, %eax
leal -0x1(,%rax,2), %eax
retq
pushq %rax
leaq 0x1d7dc(%rip), %rdi     # 0x263b6
leaq 0x1d89a(%rip), %rsi     # 0x2647b
leaq 0x1d8b0(%rip), %rcx     # 0x26498
movl $0x29, %edx
callq 0x52c0
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/exclusion.cpp
// Function: compareExclusions
int compareExclusions(const Exclusion& op1, const Exclusion& op2)
{
    Exclusion::const_iterator i_op1 = op1.begin();
    Exclusion::const_iterator i_op2 = op2.begin();

    int comp = 0;
    while( i_op1 != op1.end() &&
           i_op2 != op2.end() )
    {
        comp = compareExclusionTerms( *i_op1, *i_op2 );
        if( comp != 0 ) break;
        ++i_op1;
        ++i_op2;
    }
    if( comp != 0 )
        return( comp );
    else
        if( op1.size() != op2.size() )
            return op1.size() < op2.size() ? -1 : 1;
        else
            return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x18(%rdi), %r15
movq 0x18(%rsi), %r12
leaq 0x8(%rdi), %r13
leaq 0x8(%rsi), %rbx
cmpq %r13, %r15
setne %al
cmpq %rbx, %r12
setne %cl
andb %al, %cl
xorl %ebp, %ebp
cmpb $0x1, %cl
jne 0x8c63
movq %rsi, (%rsp)
leaq 0x20(%r15), %rdi
leaq 0x20(%r12), %rsi
callq 0x8b82
testl %eax, %eax
jne 0x8c5d
movq %r15, %rdi
callq 0x54b0
movq %rax, %r15
movq %r12, %rdi
callq 0x54b0
cmpq %r13, %r15
je 0x8c5f
movq %rax, %r12
cmpq %rbx, %rax
jne 0x8c29
jmp 0x8c5f
movl %eax, %ebp
movq (%rsp), %rsi
testl %ebp, %ebp
jne 0x8c80
movq 0x28(%r14), %rax
movq 0x28(%rsi), %rcx
xorl %ebp, %ebp
cmpq %rcx, %rax
je 0x8c80
xorl %ebp, %ebp
cmpq %rcx, %rax
sbbl %ebp, %ebp
orl $0x1, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/exclusion.cpp
// Function: pictcore::Exclusion::ResultParamCount() const
size_t Exclusion::ResultParamCount() const
{
    size_t count = 0;
    for( auto & term : col )
    {
        if( term.first->IsExpectedResultParam() )
        {
            ++count;
        }
    }
    return( count );
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x18(%rdi), %rax
addq $0x8, %rbx
xorl %r14d, %r14d
cmpq %rbx, %rax
je 0x8cbe
movq 0x20(%rax), %rcx
movzbl 0x3c(%rcx), %ecx
addq %rcx, %r14
movq %rax, %rdi
callq 0x54b0
jmp 0x8ca4
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::Model::generateRandomRow()
Exclusion Model::generateRandomRow()
{
    Exclusion row;
    for( ParamCollection::iterator ip = m_parameters.begin(); ip != m_parameters.end(); ++ip )
    {
        int sum = 0;
        for( int i = 0; i < ( *ip )->GetValueCount(); ++i )
        {
            sum += ( *ip )->GetWeight( i );
        }
        int idx = rand() % sum;

        int n;
        int val = 0;
        for( n = 0; n < ( *ip )->GetValueCount(); ++n )
        {
            if( val < idx )
            {
                val += ( *ip )->GetWeight( n );
            }
            else
            {
                break;
            }
        }

        row.insert( make_pair( *ip, n ) );
    }
    return( row );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
leaq 0x8(%rdi), %rax
movl $0x0, 0x8(%rdi)
movq $0x0, 0x10(%rdi)
movq %rax, 0x18(%rdi)
movq %rax, 0x20(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rdi)
movups %xmm0, 0x38(%rdi)
movb $0x0, 0x48(%rdi)
movq 0x8(%rsi), %r12
cmpq 0x10(%rsi), %r12
je 0xa08e
movq %rsi, %r14
leaq 0x8(%rsp), %r15
movq (%r12), %rdx
movslq 0x38(%rdx), %rax
xorl %r13d, %r13d
movl $0x0, %ebp
testq %rax, %rax
jle 0xa013
movq 0xa8(%rdx), %rcx
movq 0xb0(%rdx), %rdx
subq %rcx, %rdx
shrq $0x2, %rdx
movslq %edx, %rdx
xorl %esi, %esi
xorl %ebp, %ebp
movl $0x1, %edi
cmpq %rdx, %rsi
jge 0xa009
movl (%rcx,%rsi,4), %edi
addl %edi, %ebp
incq %rsi
cmpq %rsi, %rax
jne 0x9ffc
callq 0x5100
cltd
idivl %ebp
movq (%r12), %rsi
movslq 0x38(%rsi), %rax
testq %rax, %rax
jle 0xa067
testl %edx, %edx
jle 0xa067
movq 0xa8(%rsi), %rcx
movq 0xb0(%rsi), %rsi
subq %rcx, %rsi
shrq $0x2, %rsi
movslq %esi, %rsi
xorl %r13d, %r13d
xorl %edi, %edi
movl $0x1, %r8d
cmpq %rsi, %r13
jge 0xa058
movl (%rcx,%r13,4), %r8d
incq %r13
cmpq %rax, %r13
jae 0xa067
addl %r8d, %edi
cmpl %edx, %edi
jl 0xa049
movq (%r12), %rax
movq %rax, 0x8(%rsp)
movl %r13d, 0x10(%rsp)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x7510
addq $0x8, %r12
cmpq 0x10(%r14), %r12
jne 0x9fcb
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x70e2
movq %r14, %rdi
callq 0x56a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::Model::rowViolatesExclusion(pictcore::Exclusion&)
bool Model::rowViolatesExclusion( Exclusion& row )
{
    for( ExclusionCollection::iterator ie = m_exclusions.begin(); ie != m_exclusions.end(); ++ie )
    {
        if( contained( const_cast<Exclusion&> ( *ie ), row ) )
        {
            return( true );
        }
    }
    return( false );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0x38(%rdi), %r15
addq $0x28, %r14
cmpq %r14, %r15
setne %bpl
je 0xa0ff
movq %rsi, %rbx
leaq 0x20(%r15), %rdi
movq %rbx, %rsi
callq 0x8ae0
testb %al, %al
jne 0xa0ff
movq %r15, %rdi
callq 0x54b0
cmpq %r14, %rax
setne %bpl
je 0xa0ff
movq %rax, %r15
movq %rax, %rdi
addq $0x20, %rdi
jmp 0xa0d6
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::Model::rowViolatesExclusion(std::vector<unsigned long, std::allocator<unsigned long>>&)
bool Model::rowViolatesExclusion( ResultRow& row )
{
    for( ExclusionCollection::iterator ie = m_exclusions.begin(); ie != m_exclusions.end(); ++ie )
    {
        bool matches = true;
        for( Exclusion::iterator it = ie->begin(); it != ie->end(); ++it )
        {
            if( row[ it->first->GetSequence() ] != it->second )
            {
                matches = false;
                break;
            }
        }
        if( matches ) return( true );
    }
    return( false );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq 0x38(%rdi), %r14
addq $0x28, %rbx
cmpq %rbx, %r14
setne %bpl
je 0xa306
movq (%rsi), %r15
movq 0x38(%r14), %rax
leaq 0x28(%r14), %r12
cmpq %r12, %rax
je 0xa306
movq 0x20(%rax), %rcx
movslq 0x2c(%rcx), %rcx
movslq 0x28(%rax), %rdx
cmpq %rdx, (%r15,%rcx,8)
jne 0xa2f2
movq %rax, %rdi
callq 0x54b0
jmp 0xa2d1
movq %r14, %rdi
callq 0x54b0
movq %rax, %r14
cmpq %rbx, %rax
setne %bpl
jne 0xa2c9
andb $0x1, %bpl
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::Model::generateFixedOrder()
void Model::generateFixedOrder()
{
    GlobalZerosCount = 0;
    
    // turn each submodel's output into a PseudoParameter and add to model
    for( SubmodelCollection::iterator im = m_submodels.begin(); im != m_submodels.end(); ++im )
    {
        // make a pseudo-parameter from the submodel, add to this model
        Parameter *pseudo = new PseudoParameter( m_order, ++m_lastParamId, *im );
        AddParameter( pseudo );
    }

    // initialize combinations based on contents of m_parameters
    vector<Combination*> vecCombo;

    for( ParamCollection::iterator ip = m_parameters.begin(); ip != m_parameters.end(); ++ip )
    {
        ( *ip )->SetOrder( m_order );
    }
    bool r1 = mapExclusionsToPseudoParameters();
    bool r2 = excludeConflictingParamValues();
    if( r1 || r2 ) deriveSubmodelExclusions();

    mapRowSeedsToPseudoParameters();

    Combination baseCombo( this );
    choose( m_parameters.begin(), m_parameters.end(), m_order, m_order, baseCombo, vecCombo );
    gcd( vecCombo );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x70, %rsp
movq %rdi, %rbx
movl $0x0, (%rdi)
leaq 0x50(%rdi), %r15
movq 0x50(%rdi), %r12
cmpq %r15, %r12
je 0xaba3
movl $0xd8, %edi
callq 0x53c0
movq %rax, %r14
movl 0x108(%rbx), %esi
movl 0x130(%rbx), %edx
incl %edx
movl %edx, 0x130(%rbx)
movq 0x10(%r12), %rcx
movq %rax, %rdi
callq 0xf24c
movq %rbx, %rdi
movq %r14, %rsi
callq 0xc1c4
movq (%r12), %r12
jmp 0xab5f
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%rsp)
movq $0x0, 0x20(%rsp)
movq 0x8(%rbx), %rax
movq 0x10(%rbx), %rcx
cmpq %rcx, %rax
je 0xabd6
movl 0x108(%rbx), %edx
movq (%rax), %rsi
movl %edx, 0x28(%rsi)
addq $0x8, %rax
cmpq %rcx, %rax
jne 0xabc7
movq %rbx, %rdi
callq 0xb62a
movl %eax, %ebp
movq %rbx, %rdi
callq 0xa5ec
orb %al, %bpl
cmpb $0x1, %bpl
jne 0xabf9
movq %rbx, %rdi
callq 0xba2c
movq %rbx, %rdi
callq 0xbb82
leaq 0x30(%rsp), %rdi
movq %rbx, %rsi
callq 0x62c8
movq 0x8(%rbx), %rsi
movq 0x10(%rbx), %rdx
movl 0x108(%rbx), %ecx
leaq 0x10(%rsp), %rax
movq %rax, (%rsp)
leaq 0x30(%rsp), %r9
movq %rbx, %rdi
movl %ecx, %r8d
callq 0x8d5c
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x8f5c
leaq 0x30(%rsp), %rdi
callq 0x62ec
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xac63
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x53e0
addq $0x70, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0xac83
jmp 0xac83
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x62ec
jmp 0xac86
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xacaa
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
jmp 0xaca5
movq %rax, %rbx
movl $0xd8, %esi
movq %r14, %rdi
callq 0x53e0
movq %rbx, %rdi
callq 0x56a0
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::Model::deriveSubmodelExclusions()
void Model::deriveSubmodelExclusions()
{
    ExclusionDeriver deriver( GetTask() );

    // the deriver must know about pseudo parameters
    ParamCollection params;
    GetAllParameters( params );
    for( ParamCollection::iterator ip = params.begin(); ip != params.end(); ++ip )
    {
        deriver.AddParameter( *ip );
    }

    // run the deriver on the newly created set of exclusions
    if( !deriver.GetParameters().empty() )
    {
        for( ExclusionCollection::iterator i_e = m_exclusions.begin(); i_e != m_exclusions.end(); ++i_e )
        {
            deriver.AddExclusion( const_cast<Exclusion&> ( *i_e ), true );
        }
        deriver.DeriveExclusions();

        // must clear because some initial exclusions may have been removed during derivation as obsolete
        m_exclusions.clear();
        __insert( m_exclusions, deriver.GetExclusions().begin(), deriver.GetExclusions().end() );
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rdi, %rbx
movq 0x148(%rdi), %rsi
leaq 0x18(%rsp), %rdi
callq 0xc232
xorps %xmm0, %xmm0
movq %rsp, %rsi
movaps %xmm0, (%rsi)
movq $0x0, 0x10(%rsi)
movq %rbx, %rdi
callq 0xc304
movq (%rsp), %r15
cmpq 0x8(%rsp), %r15
je 0xba8d
leaq 0x18(%rsp), %r14
movq (%r15), %rsi
movq %r14, %rdi
callq 0xc344
addq $0x8, %r15
cmpq 0x8(%rsp), %r15
jne 0xba77
movq 0x18(%rsp), %rax
cmpq 0x20(%rsp), %rax
je 0xbaf3
movq 0x38(%rbx), %r14
leaq 0x28(%rbx), %r12
cmpq %r12, %r14
je 0xbacc
leaq 0x18(%rsp), %r15
leaq 0x20(%r14), %rsi
movq %r15, %rdi
movl $0x1, %edx
callq 0x648c
movq %r14, %rdi
callq 0x54b0
movq %rax, %r14
cmpq %r12, %rax
jne 0xbaab
leaq 0x18(%rsp), %rdi
callq 0x6756
addq $0x20, %rbx
movq %rbx, %rdi
callq 0xecce
leaq 0x38(%rsp), %rdx
movq 0x10(%rdx), %rsi
movq %rbx, %rdi
callq 0xc1fc
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xbb09
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x53e0
leaq 0xc8(%rsp), %rdi
callq 0xcd0c
leaq 0x78(%rsp), %rdi
callq 0xd476
leaq 0x30(%rsp), %rbx
movq %rbx, %rdi
callq 0xcc6c
movq -0x18(%rbx), %rdi
testq %rdi, %rdi
je 0xbb43
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
callq 0x53e0
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0xbb56
jmp 0xbb56
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xbb6f
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x53e0
leaq 0x18(%rsp), %rdi
callq 0xc36a
movq %rbx, %rdi
callq 0x56a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::seedContained(std::set<std::pair<pictcore::Parameter*, int>, std::less<std::pair<pictcore::Parameter*, int>>, std::allocator<std::pair<pictcore::Parameter*, int>>>&, std::set<std::pair<pictcore::Parameter*, int>, std::less<std::pair<pictcore::Parameter*, int>>, std::allocator<std::pair<pictcore::Parameter*, int>>>&)
bool seedContained( RowSeed &container, RowSeed &containee )
{
    // containee has to have all its elements matching exacly some element in the container
    for( RowSeed::iterator ic = containee.begin(); ic != containee.end(); ++ic )
    {
        if( container.find( *ic ) == container.end() ) return( false );
    }
    return( true );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movq 0x18(%rsi), %r15
addq $0x8, %rbx
cmpq %rbx, %r15
sete %bpl
je 0xbead
movq %rdi, %r14
leaq 0x8(%rdi), %r12
leaq 0x20(%r15), %rsi
movq %r14, %rdi
callq 0xedbc
cmpq %r12, %rax
je 0xbead
movq %r15, %rdi
callq 0x54b0
cmpq %rbx, %rax
sete %bpl
je 0xbead
movq %rax, %r15
movq %rax, %rsi
addq $0x20, %rsi
jmp 0xbe83
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::seedViolatesExclusion(std::set<std::pair<pictcore::Parameter*, int>, std::less<std::pair<pictcore::Parameter*, int>>, std::allocator<std::pair<pictcore::Parameter*, int>>>&, pictcore::Exclusion&)
bool seedViolatesExclusion( RowSeed &seed, Exclusion &exclusion )
{
    // exclusion has to have all its elements matching exacly some element in the seed
    for( Exclusion::iterator ie = exclusion.begin(); ie != exclusion.end(); ++ie )
    {
        // translate exclusion item into seed item
        // currently they are the same thing
        RowSeedTerm term = make_pair( ie->first, ie->second );
        if( seed.find( term ) == seed.end() ) return( false );
    }
    return( true );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
movq 0x18(%rsi), %r15
addq $0x8, %rbx
cmpq %rbx, %r15
sete %bpl
je 0xbf38
movq %rdi, %r14
leaq 0x8(%rdi), %r13
movq 0x20(%r15), %rax
movl 0x28(%r15), %ecx
leaq 0x8(%rsp), %rsi
movq %rax, (%rsi)
movl %ecx, 0x8(%rsi)
callq 0xedbc
cmpq %r13, %rax
je 0xbf38
leaq 0x8(%rsp), %r12
movq %r15, %rdi
callq 0x54b0
cmpq %rbx, %rax
sete %bpl
je 0xbf38
movq %rax, %r15
movq 0x20(%rax), %rax
movl 0x28(%r15), %ecx
movq %rax, 0x8(%rsp)
movl %ecx, 0x10(%rsp)
movq %r14, %rdi
movq %r12, %rsi
callq 0xedbc
cmpq %r13, %rax
jne 0xbf03
movl %ebp, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/generator.h
// Function: pictcore::Model::AddParameter(pictcore::Parameter*)
void AddParameter( Parameter* param )
    {
        // parameter names should be unique but we can't assert it here
        // as there are cases where we add same name params to the collection
        // internally and delete the duplicate almost immediately
        param->WireTask( GetTask() );
        m_parameters.push_back( param );
    }

// Assembly:
pushq %rax
movq %rsi, %rax
movq %rsi, (%rsp)
movq 0x148(%rdi), %rcx
movq %rcx, 0xc0(%rsi)
movq 0x10(%rdi), %rsi
cmpq 0x18(%rdi), %rsi
je 0xc1ee
movq %rax, (%rsi)
addq $0x8, 0x10(%rdi)
jmp 0xc1fa
addq $0x8, %rdi
movq %rsp, %rdx
callq 0xc56e
popq %rax
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/parameter.cpp
// Function: pictcore::Parameter::CleanUp()
void Parameter::CleanUp()
{
    m_pending = false;
    m_bound   = false;

    m_combinations.clear();
    m_result.clear();
    m_exclusions.clear();
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movw $0x0, 0x3d(%rdi)
movq 0x40(%rdi), %rax
cmpq %rax, 0x48(%rdi)
je 0xee80
movq %rax, 0x48(%rbx)
leaq 0x90(%rbx), %rdi
callq 0xf3ee
addq $0x58, %rbx
movq %rbx, %rdi
popq %rbx
jmp 0x727a
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/parameter.cpp
// Function: pictcore::Parameter::Bind(int, pictcore::WorkList&)
bool Parameter::Bind(int value, WorkList& worklist)
{
    DOUT(L"Binding " << m_name << L" to value " << value << L".\n");
    assert(!m_bound);
    assert(value < m_valueCount);

    m_result.push_back(value);
    m_currentValue = value;
    m_bound = true;

    for( auto & combination : m_combinations )
    {
        if( combination->AddBinding() == combination->GetParameterCount() - 1 )
        {
            // Add any parameter that completes a combination to work list
            for( int n = 0; n < combination->GetParameterCount(); ++n )
            {
                if( !( (*combination)[ n ] ).GetBoundCount() )
                {
                    worklist.AddItem( &( *combination )[ n ] );
                }
            }
        }
    }

    worklist.Print();
    
    return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
cmpb $0x1, 0x3d(%rdi)
je 0xef7c
movq %rdi, %r14
cmpl %esi, 0x38(%rdi)
jle 0xef9b
movq %rdx, %rbx
leaq 0x90(%r14), %r15
movslq %esi, %r12
movl $0x18, %edi
callq 0x53c0
movq %r12, 0x10(%rax)
movq %rax, %rdi
movq %r15, %rsi
callq 0x5080
incq 0xa0(%r14)
movq %r12, 0x30(%r14)
movb $0x1, 0x3d(%r14)
movq 0x40(%r14), %r15
movq 0x48(%r14), %r14
cmpq %r14, %r15
je 0xef66
movq (%r15), %rdi
callq 0x6034
movq (%r15), %rcx
movq 0x10(%rcx), %rdx
subq 0x8(%rcx), %rdx
shrq $0x3, %rdx
decl %edx
cmpl %edx, %eax
jne 0xef60
movq (%r15), %rcx
movq 0x8(%rcx), %rax
movq 0x10(%rcx), %rcx
subq %rax, %rcx
shrq $0x3, %rcx
testl %ecx, %ecx
jle 0xef60
xorl %r12d, %r12d
movq (%rax,%r12,8), %rsi
cmpb $0x0, 0x3d(%rsi)
jne 0xef43
movq %rbx, %rdi
callq 0x106c8
incq %r12
movq (%r15), %rcx
movq 0x8(%rcx), %rax
movq 0x10(%rcx), %rcx
subq %rax, %rcx
shrq $0x3, %rcx
movslq %ecx, %rcx
cmpq %rcx, %r12
jl 0xef31
addq $0x8, %r15
jmp 0xeef6
movq %rbx, %rdi
callq 0x1075e
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0x1797c(%rip), %rdi     # 0x268ff
leaq 0x1797e(%rip), %rsi     # 0x26908
leaq 0x17994(%rip), %rcx     # 0x26925
movl $0x1d, %edx
callq 0x52c0
leaq 0x179b3(%rip), %rdi     # 0x26955
leaq 0x1795f(%rip), %rsi     # 0x26908
leaq 0x17975(%rip), %rcx     # 0x26925
movl $0x1e, %edx
callq 0x52c0
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/parameter.cpp
// Function: pictcore::PseudoParameter::PseudoParameter(int, unsigned int, pictcore::Model*)
PseudoParameter::PseudoParameter( int order, unsigned int sequence, Model *model ) :
        Parameter( order, sequence, static_cast<int>( model->GetResultCount() ), wstring(), false ),
        m_model( model )
{
    m_name = L"";
    for( vector<Parameter*>::iterator ip =  model->GetParameters().begin();
                                      ip != model->GetParameters().end();
                                    ++ip )
    {
        if( ip != model->GetParameters().begin() )
        {
            m_name += L" ";
        }
        m_name += ( *ip )->GetName();
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %r14
movl %edx, 0x4(%rsp)
movl %esi, (%rsp)
movq %rdi, %rbx
movq 0xd0(%rcx), %r13
movq 0xd8(%rcx), %rbp
leaq 0x18(%rsp), %r12
movq %r12, -0x10(%r12)
movq $0x0, -0x8(%r12)
movl $0x0, (%r12)
leaq 0x257f1(%rip), %rax     # 0x34a88
movq %rax, (%rdi)
leaq 0x8(%rdi), %r15
leaq 0x18(%rdi), %rax
movq %rax, 0x8(%rdi)
movq %r15, %rdi
movq %r12, %rsi
movq %r12, %rdx
callq 0xe5f8
subq %r13, %rbp
shrq $0x3, %rbp
imull $0xaaaaaaab, %ebp, %eax # imm = 0xAAAAAAAB
movl (%rsp), %ecx
movl %ecx, 0x28(%rbx)
movl 0x4(%rsp), %ecx
movl %ecx, 0x2c(%rbx)
movl %eax, 0x38(%rbx)
movb $0x0, 0x3c(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x40(%rbx)
xorl %eax, %eax
movq %rax, 0x50(%rbx)
leaq 0x60(%rbx), %rcx
movl $0x0, 0x60(%rbx)
movq %rax, 0x68(%rbx)
movq %rcx, 0x70(%rbx)
movq %rcx, 0x78(%rbx)
leaq 0x90(%rbx), %rax
movups %xmm0, 0x80(%rbx)
movq %rax, 0x98(%rbx)
movq %rax, 0x90(%rbx)
movups %xmm0, 0xa0(%rbx)
movups %xmm0, 0xb0(%rbx)
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0xf33f
movq 0x18(%rsp), %rax
leaq 0x4(,%rax,4), %rsi
callq 0x53e0
leaq 0x256ea(%rip), %rax     # 0x34a30
movq %rax, (%rbx)
movq %r14, 0xd0(%rbx)
movq 0x10(%rbx), %rdx
leaq 0x1769d(%rip), %rcx     # 0x269f8
movq %r15, %rdi
xorl %esi, %esi
xorl %r8d, %r8d
callq 0x56c0
movq 0x8(%r14), %r13
cmpq 0x10(%r14), %r13
je 0xf3a8
leaq 0x1767b(%rip), %r12     # 0x269f4
cmpq 0x8(%r14), %r13
je 0xf38a
movq %r15, %rdi
movq %r12, %rsi
callq 0x56e0
movq (%r13), %rax
movq 0x8(%rax), %rsi
movq 0x10(%rax), %rdx
movq %r15, %rdi
callq 0x5430
addq $0x8, %r13
cmpq 0x10(%r14), %r13
jne 0xf379
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xf3da
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r12, %rdi
je 0xf3e5
movq 0x18(%rsp), %rax
leaq 0x4(,%rax,4), %rsi
callq 0x53e0
jmp 0xf3e5
movq %rax, %r14
movq %rbx, %rdi
callq 0xf500
movq %r14, %rdi
callq 0x56a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/pictapi.cpp
// Function: PictAddExclusion
PICT_RET_CODE
API_SPEC
PictAddExclusion
    (
    IN const PICT_HANDLE         task,
    IN const PICT_EXCLUSION_ITEM exclusionItems[],
    IN       size_t              exclusionItemCount
    )
{
    Task* taskObj = static_cast<Task*>( NO_CONST_HANDLE( task ));
    
    try
    {
        Exclusion exclusion;
        for( size_t index = 0; index < exclusionItemCount; ++index )
        {
            exclusion.insert( make_pair( 
                static_cast<Parameter*> ( NO_CONST_HANDLE( exclusionItems[ index ].Parameter  )),
                static_cast<int>        (                  exclusionItems[ index ].ValueIndex ))
                );
        }
        bool ret = taskObj->AddExclusion( exclusion );
        return( ret ? PICT_SUCCESS : PICT_OUT_OF_MEMORY );
    }
    catch( ... )
    {
        return( PICT_OUT_OF_MEMORY );
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdi, %rbx
leaq 0x18(%rsp), %rax
movl $0x0, (%rax)
movq $0x0, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rax)
movups %xmm0, 0x30(%rax)
movb $0x0, 0x40(%rax)
testq %rdx, %rdx
je 0xf6b1
movq %rdx, %r14
movq %rsi, %r15
addq $0x8, %r15
leaq 0x10(%rsp), %r12
movq %rsp, %r13
movq -0x8(%r15), %rax
movl (%r15), %ecx
movq %rax, (%rsp)
movl %ecx, 0x8(%rsp)
movq %r12, %rdi
movq %r13, %rsi
callq 0x7510
addq $0x10, %r15
decq %r14
jne 0xf68e
addq $0x8, %rbx
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x8066
xorl %eax, %eax
testb $0x1, %dl
movl $0xc0000001, %ebx       # imm = 0xC0000001
cmovnel %eax, %ebx
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0xf6e6
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x53e0
leaq 0x10(%rsp), %rdi
callq 0x791a
movl %ebx, %eax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0xf702
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x70e2
movq %rbx, %rdi
callq 0x5190
callq 0x5650
movl $0xc0000001, %ebx       # imm = 0xC0000001
jmp 0xf6f0
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/pictapi.cpp
// Function: PictAddSeed
PICT_RET_CODE
API_SPEC
PictAddSeed
    (
    IN const PICT_HANDLE     task,
    IN const PICT_SEED_ITEM  seedItems[],
    IN       size_t          seedItemCount
    )
{
    Task* taskObj = static_cast<Task*>( NO_CONST_HANDLE( task ));
    
    try
    {
        RowSeed seed;
        for( size_t index = 0; index < seedItemCount; ++index )
        {
            seed.insert( make_pair( 
                static_cast<Parameter*> ( NO_CONST_HANDLE( seedItems[ index ].Parameter  )),
                static_cast<int>        (                  seedItems[ index ].ValueIndex ))
                );
        }
        taskObj->AddRowSeed( seed );
        return( PICT_SUCCESS );
    }
    catch( ... )
    {
        return( PICT_OUT_OF_MEMORY );
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdi, %rbx
leaq 0x18(%rsp), %rax
movl $0x0, (%rax)
xorl %ecx, %ecx
movq %rcx, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %rcx, 0x20(%rax)
testq %rdx, %rdx
je 0xf78a
movq %rdx, %r14
movq %rsi, %r15
addq $0x8, %r15
leaq 0x10(%rsp), %r12
movq %rsp, %r13
movq -0x8(%r15), %rax
movl (%r15), %ecx
movq %rax, (%rsp)
movl %ecx, 0x8(%rsp)
movq %r12, %rdi
movq %r13, %rsi
callq 0xeb74
addq $0x10, %r15
decq %r14
jne 0xf767
leaq 0x38(%rbx), %r14
leaq 0x10(%rsp), %rsi
movq %r14, %rdi
callq 0xd4c6
movq %rax, %rdi
movq %r14, %rsi
callq 0x5080
incq 0x48(%rbx)
leaq 0x10(%rsp), %rdi
callq 0xcc1c
xorl %eax, %eax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0xf7c6
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0xcc1c
movq %rbx, %rdi
callq 0x5190
callq 0x5650
movl $0xc0000001, %eax       # imm = 0xC0000001
jmp 0xf7b6
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/pictapi.cpp
// Function: PictGenerate
PICT_RET_CODE
API_SPEC
PictGenerate
    (
    IN const PICT_HANDLE task
    )
{
    Task* taskObj = static_cast<Task*>( NO_CONST_HANDLE( task ));
    try
    {
        taskObj->PrepareForGeneration();
    }
    catch( ... )
    {
        return( PICT_GENERATION_ERROR );
    }
    
    Model* root = taskObj->GetRootModel();
    try
    {
        generate( root );
    }
    catch( GenerationError e )
    {
        switch( e.GetErrorType() )
        {
        case OutOfMemory:
            return( PICT_OUT_OF_MEMORY );
        case GenerationCancelled:
        case TooManyRows:        
        case Unknown:
        case GenerationFailure:
        default:
            return( PICT_GENERATION_ERROR );
        }
    }
    return( PICT_SUCCESS );
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
callq 0x10352
movq (%rbx), %rdi
xorl %ebx, %ebx
callq 0xf8a8
movl %ebx, %eax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
cmpl $0x2, %edx
jne 0xf881
movq %rbx, %rdi
callq 0x54f0
movq %rax, %r14
movl (%rax), %eax
leaq 0x8(%rsp), %rdi
movl %eax, -0x8(%rdi)
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
movq 0x8(%r14), %rsi
movq 0x10(%r14), %rdx
addq %rsi, %rdx
callq 0x7622
movl 0x28(%r14), %eax
movl %eax, 0x28(%rsp)
movq %rbx, %rdi
callq 0x5190
xorl %ebx, %ebx
cmpl $0x3, (%rsp)
setne %bl
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0xf874
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x53e0
addl $0xc0000001, %ebx       # imm = 0xC0000001
callq 0x5650
jmp 0xf802
movq %rbx, %rdi
callq 0x56a0
movq %rax, %rdi
callq 0x726e
movq %rax, %rdi
callq 0x5190
callq 0x5650
movl $0xc0000002, %ebx       # imm = 0xC0000002
jmp 0xf802
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/pictapi.cpp
// Function: PictGetNextResultRow
size_t
API_SPEC
PictGetNextResultRow
    (
    IN  const PICT_HANDLE     task,
    OUT       PICT_RESULT_ROW resultRow
    )
{
    Task* taskObj = static_cast<Task*>( NO_CONST_HANDLE( task ));
    
    ResultCollection::iterator i_row = taskObj->GetNextResultRow();

    if( i_row != taskObj->GetResults().end() )
    {
        for( size_t index = 0; index < i_row->size(); ++index )
        {
            resultRow[ index ] = (*i_row)[ index ];
        }
    }
    
    return( distance( i_row, taskObj->GetResults().end() ));
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
callq 0x105ea
movq (%r14), %rcx
movq 0xd8(%rcx), %rcx
cmpq %rcx, %rax
je 0xf93a
movq (%rax), %rdx
movq 0x8(%rax), %rsi
subq %rdx, %rsi
je 0xf93a
sarq $0x3, %rsi
cmpq $0x1, %rsi
adcq $0x0, %rsi
xorl %edi, %edi
movq (%rdx,%rdi,8), %r8
movq %r8, (%rbx,%rdi,8)
incq %rdi
cmpq %rdi, %rsi
jne 0xf92a
subq %rax, %rcx
sarq $0x3, %rcx
movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB
imulq %rcx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/WShabti-Team[P]WShabtiPict/wshabtilib/api/pictapi.cpp
// Function: PictCreateModel
PICT_HANDLE
API_SPEC
PictCreateModel
    (
    IN OPT unsigned int randomSeed
    )
{
    Model* modelObj = new Model( L"",
                                 MixedOrder, 
                                 0,
                                 randomSeed );
    
    return( static_cast<PICT_HANDLE>( modelObj ));   
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movl %edi, %ebp
movl $0x150, %edi            # imm = 0x150
callq 0x53c0
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x1705b(%rip), %rdx     # 0x269f8
leaq 0x8(%rsp), %rdi
movq %rdx, %rsi
callq 0xffe6
movl %ebp, %r8d
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0xfd0a
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0xf9da
movq 0x18(%rsp), %rax
leaq 0x4(,%rax,4), %rsi
callq 0x53e0
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0xfa0c
movq 0x18(%rsp), %rax
leaq 0x4(,%rax,4), %rsi
callq 0x53e0
jmp 0xfa0c
movq %rax, %r14
movl $0x150, %esi            # imm = 0x150
movq %rbx, %rdi
callq 0x53e0
movq %r14, %rdi
callq 0x56a0