// File: /workspace/github_cpp_makefile_star2_O3/lmclaramunt[P]AES-Crypto/Cipher.cpp
// Function: Cipher::setBlockRoundCombinations(int*, bool)
void Cipher::setBlockRoundCombinations(int* keyLength, bool setKeyPath) {
    switch (*keyLength) {
    case 128:
        Nk = 4, Nr = 10;
        break;
    case 192:
        Nk = 6, Nr = 12;
        break;
    case 256:
        Nk = 8, Nr = 14;
        break;
    default: 
        throw "Invalid Key Length -- Valid: 128, 192, 256"; 
        break;
    }
    if(setKeyPath){ 
        string length = to_string(*keyLength);              //Default AES and MAC keys location
        aesKeyPath = home + "/.AES-" + length + ".aes";
        macKeyPath = home + "/.MAC-" + length + ".aes";   
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rdi, %rbx
movl (%rsi), %eax
cmpl $0x80, %eax
je 0x3ef9
cmpl $0x100, %eax            # imm = 0x100
je 0x3eef
cmpl $0xc0, %eax
jne 0x4227
movsd 0x3533(%rip), %xmm0     # 0x7420
jmp 0x3f01
movsd 0x3519(%rip), %xmm0     # 0x7410
jmp 0x3f01
movsd 0x34ff(%rip), %xmm0     # 0x7400
movlps %xmm0, 0x18(%rbx)
testb %dl, %dl
je 0x4215
movl (%rsi), %r13d
movl %r13d, %ebp
negl %ebp
cmovsl %r13d, %ebp
movl $0x1, %r14d
cmpl $0xa, %ebp
jb 0x3f6d
movl $0x4, %r14d
movl $0xd1b71759, %eax       # imm = 0xD1B71759
movl %ebp, %ecx
cmpl $0x63, %ecx
jbe 0x3f64
cmpl $0x3e7, %ecx            # imm = 0x3E7
jbe 0x3f6a
cmpl $0x2710, %ecx           # imm = 0x2710
jb 0x3f6d
movl %ecx, %edx
imulq %rax, %rdx
shrq $0x2d, %rdx
addl $0x4, %r14d
cmpl $0x1869f, %ecx          # imm = 0x1869F
movl %edx, %ecx
ja 0x3f31
addl $-0x3, %r14d
jmp 0x3f6d
addl $-0x2, %r14d
jmp 0x3f6d
decl %r14d
shrl $0x1f, %r13d
movl %r13d, %esi
addl %r14d, %esi
leaq 0x78(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x68(%rsp), %r15
movq %r15, %rdi
movl $0x2d, %edx
callq 0x2270
movq (%r15), %rdi
addq %r13, %rdi
movl %r14d, %esi
movl %ebp, %edx
callq 0x63dd
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
movq 0x30(%rbx), %rsi
movq 0x38(%rbx), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x64c2
leaq 0x377f(%rip), %rsi      # 0x7747
leaq 0x8(%rsp), %rdi
callq 0x2430
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x20a0
leaq 0x38(%rsp), %r13
movq %r13, -0x10(%r13)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x400d
movq %rdx, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0x4015
movups (%rcx), %xmm0
movups %xmm0, (%r13)
movq 0x8(%rax), %rdx
leaq 0x28(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x3716(%rip), %rsi      # 0x774e
callq 0x2430
leaq 0x58(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4064
movq %rdx, 0x48(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x58(%rsp)
jmp 0x406b
movups (%rcx), %xmm0
movups %xmm0, (%rbp)
movq 0x8(%rax), %rdx
leaq 0x48(%rsp), %r14
movq %rdx, 0x8(%r14)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x50(%rbx), %rdi
movq %r14, %rsi
callq 0x22a0
movq (%r14), %rdi
cmpq %rbp, %rdi
je 0x40a8
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x2250
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x40bf
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x2250
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x40d6
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2250
leaq 0x8(%rsp), %rdi
movq %r15, (%rdi)
movq 0x30(%rbx), %rsi
movq 0x38(%rbx), %rdx
addq %rsi, %rdx
callq 0x64c2
leaq 0x365e(%rip), %rsi      # 0x7753
leaq 0x8(%rsp), %rdi
callq 0x2430
movq 0x68(%rsp), %rsi
movq 0x70(%rsp), %rdx
leaq 0x8(%rsp), %rdi
callq 0x20a0
movq %r13, 0x28(%rsp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4136
movq %rdx, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0x413e
movups (%rcx), %xmm0
movups %xmm0, (%r13)
movq 0x8(%rax), %rdx
leaq 0x28(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x35ed(%rip), %rsi      # 0x774e
callq 0x2430
movq %rbp, 0x48(%rsp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x4189
movq %rdx, 0x48(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x58(%rsp)
jmp 0x4190
movups (%rcx), %xmm0
movups %xmm0, (%rbp)
movq 0x8(%rax), %rdx
leaq 0x48(%rsp), %r14
movq %rdx, 0x8(%r14)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
addq $0x70, %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x22a0
movq (%r14), %rdi
cmpq %rbp, %rdi
je 0x41d0
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x2250
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x41e7
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x2250
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x41fe
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2250
movq 0x68(%rsp), %rdi
cmpq %r12, %rdi
je 0x4215
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2250
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x8, %edi
callq 0x2120
leaq 0x34e4(%rip), %rcx      # 0x771c
movq %rcx, (%rax)
movq 0x6d7e(%rip), %rsi      # 0xafc0
movq %rax, %rdi
xorl %edx, %edx
callq 0x23d0
jmp 0x4254
jmp 0x4272
jmp 0x4272
jmp 0x428e
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r13, %rdi
je 0x4275
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x2250
jmp 0x4275
jmp 0x4272
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x4291
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2250
jmp 0x4291
movq %rax, %rbx
movq 0x68(%rsp), %rdi
cmpq %r12, %rdi
je 0x42a8
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2250
movq %rbx, %rdi
callq 0x2400