// File: WShabti-Team[P]WShabtiPict/wshabtilib/api/model.cpp
// Function: pictcore::Model::generateFull()
void Model::generateFull()
{
    // no support for result rows in this generation mode
    assert( 0 == GetResultParameterCount() );

    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
        // Ignore first arg (order) - it'll be reset below
        Parameter *pseudo = new PseudoParameter( 2, ++m_lastParamId, *im );
        AddParameter( pseudo );
    }

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

    // set all parameters to order = number of parameters
    // (include the pseudo-parameters)
    // let's estimate how many rows we'll produce
    long rows = 1;
    for( ParamCollection::iterator ip = m_parameters.begin(); ip != m_parameters.end(); ++ip )
    {
        ( *ip )->SetOrder( static_cast<int>( m_parameters.size() ) );
        rows *= ( *ip )->GetValueCount();
        if( rows > MaxRowsToGenerate )
        {
            throw GenerationError( __FILE__, __LINE__, TooManyRows );
        }
    }
    bool r1 = mapExclusionsToPseudoParameters();
    bool r2 = excludeConflictingParamValues();
    if( r1 || r2 ) deriveSubmodelExclusions();

    mapRowSeedsToPseudoParameters();

    Combination baseCombo( this );
    choose( m_parameters.begin(),
            m_parameters.end(),
            static_cast<int>( m_parameters.size() ),
            static_cast<int>( m_parameters.size() ),
            baseCombo, vecCombo );
    gcd( vecCombo );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x130, %rsp            # imm = 0x130
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0xe0(%rbp)
callq 0x1bf50
movq %rax, %rcx
xorl %eax, %eax
cmpq %rcx, %rax
jne 0x1907b
jmp 0x1909a
leaq 0x4b74c(%rip), %rdi     # 0x647ce
leaq 0x4b5b8(%rip), %rsi     # 0x64641
movl $0x34f, %edx            # imm = 0x34F
leaq 0x4b784(%rip), %rcx     # 0x64819
callq 0x7450
movq -0xe0(%rbp), %rdi
movl $0x0, (%rdi)
addq $0x50, %rdi
callq 0x1ca90
movq %rax, -0x10(%rbp)
movq -0xe0(%rbp), %rdi
addq $0x50, %rdi
callq 0x1caf0
movq %rax, -0x18(%rbp)
leaq -0x10(%rbp), %rdi
leaq -0x18(%rbp), %rsi
callq 0x1cac0
testb $0x1, %al
jne 0x190de
jmp 0x19184
movl $0xd8, %edi
callq 0x75e0
movq %rax, %rcx
movq -0xe0(%rbp), %rax
movq %rcx, -0xf0(%rbp)
movq %rcx, -0xf8(%rbp)
movl 0x130(%rax), %ecx
incl %ecx
movl %ecx, -0xe4(%rbp)
movl %ecx, 0x130(%rax)
leaq -0x10(%rbp), %rdi
callq 0x1cb20
movq -0xf0(%rbp), %rdi
movl -0xe4(%rbp), %edx
movq (%rax), %rcx
movl $0x2, %esi
callq 0x2d8b0
jmp 0x19139
movq -0xe0(%rbp), %rdi
movq -0xf8(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rsi
callq 0x1c940
leaq -0x10(%rbp), %rdi
callq 0x1cc90
jmp 0x190b4
movq -0xf8(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
movl $0xd8, %esi
callq 0x7600
jmp 0x1948f
leaq -0x48(%rbp), %rdi
callq 0x1ccd0
movq -0xe0(%rbp), %rdi
movq $0x1, -0x50(%rbp)
addq $0x8, %rdi
callq 0x8c90
movq %rax, -0x58(%rbp)
movq -0xe0(%rbp), %rdi
addq $0x8, %rdi
callq 0x8cc0
movq %rax, -0x60(%rbp)
leaq -0x58(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0x8cf0
testb $0x1, %al
jne 0x191d3
jmp 0x19330
leaq -0x58(%rbp), %rdi
callq 0x8d30
movq -0xe0(%rbp), %rdi
movq (%rax), %rax
movq %rax, -0x100(%rbp)
addq $0x8, %rdi
callq 0x8fd0
movq -0x100(%rbp), %rdi
movl %eax, %esi
callq 0x1ce00
jmp 0x19206
leaq -0x58(%rbp), %rdi
callq 0x8d30
movq (%rax), %rdi
callq 0x8eb0
movl %eax, -0x104(%rbp)
jmp 0x1921f
movl -0x104(%rbp), %eax
cltq
imulq -0x50(%rbp), %rax
movq %rax, -0x50(%rbp)
cmpq $0xf4240, -0x50(%rbp)   # imm = 0xF4240
jle 0x19320
movb $0x1, -0x82(%rbp)
movl $0x30, %edi
callq 0x7300
movq %rax, -0x118(%rbp)
leaq -0x81(%rbp), %rdi
movq %rdi, -0x110(%rbp)
callq 0x79e0
movq -0x110(%rbp), %rdx
leaq 0x4b3ca(%rip), %rsi     # 0x64641
leaq -0x80(%rbp), %rdi
callq 0xd700
jmp 0x19282
movq -0x118(%rbp), %rdi
leaq -0x80(%rbp), %rsi
movl $0x368, %edx            # imm = 0x368
movl $0x1, %ecx
callq 0xd7b0
jmp 0x1929e
movq -0x118(%rbp), %rdi
movb $0x0, -0x82(%rbp)
leaq 0x7873d(%rip), %rsi     # 0x919f0
leaq -0xbaca(%rip), %rdx     # 0xd7f0
callq 0x7980
jmp 0x19498
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x19486
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x192f8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x80(%rbp), %rdi
callq 0x73e0
leaq -0x81(%rbp), %rdi
callq 0x7660
testb $0x1, -0x82(%rbp)
jne 0x1930f
jmp 0x1931b
movq -0x118(%rbp), %rdi
callq 0x74a0
jmp 0x19486
jmp 0x19322
leaq -0x58(%rbp), %rdi
callq 0x8d70
jmp 0x191a9
movq -0xe0(%rbp), %rdi
callq 0x1a270
movb %al, -0x119(%rbp)
jmp 0x19344
movq -0xe0(%rbp), %rdi
movb -0x119(%rbp), %al
andb $0x1, %al
movb %al, -0x83(%rbp)
callq 0x18300
movb %al, -0x11a(%rbp)
jmp 0x19366
movb -0x11a(%rbp), %al
andb $0x1, %al
movb %al, -0x84(%rbp)
testb $0x1, -0x83(%rbp)
jne 0x19386
testb $0x1, -0x84(%rbp)
je 0x19396
movq -0xe0(%rbp), %rdi
callq 0x1aa10
jmp 0x19394
jmp 0x19396
movq -0xe0(%rbp), %rdi
callq 0x1ac90
jmp 0x193a4
movq -0xe0(%rbp), %rsi
leaq -0xc8(%rbp), %rdi
callq 0x8b60
jmp 0x193b9
movq -0xe0(%rbp), %rdi
addq $0x8, %rdi
movq %rdi, -0x128(%rbp)
callq 0x8c90
movq -0x128(%rbp), %rdi
movq %rax, -0xd0(%rbp)
callq 0x8cc0
movq -0x128(%rbp), %rdi
movq %rax, -0xd8(%rbp)
callq 0x8fd0
movq -0x128(%rbp), %rdi
movl %eax, -0x120(%rbp)
callq 0x8fd0
movq -0xe0(%rbp), %rdi
movl -0x120(%rbp), %ecx
movl %eax, %r8d
movq -0xd0(%rbp), %rsi
movq -0xd8(%rbp), %rdx
movq %rsp, %rax
leaq -0x48(%rbp), %r9
movq %r9, (%rax)
leaq -0xc8(%rbp), %r9
callq 0x15100
jmp 0x1943e
movq -0xe0(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x15380
jmp 0x19450
leaq -0xc8(%rbp), %rdi
callq 0x8bd0
leaq -0x48(%rbp), %rdi
callq 0x1cd40
addq $0x130, %rsp            # imm = 0x130
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0xc8(%rbp), %rdi
callq 0x8bd0
leaq -0x48(%rbp), %rdi
callq 0x1cd40
movq -0x28(%rbp), %rdi
callq 0x79d0
nopl (%rax,%rax)