// File: /workspace/github_cpp_makefile_star2_O2/millanek[P]Dsuite/./Dsuite_utils.h
// Function: QuartetDinfo::assignQuartetTreeArrangement(std::vector<int, std::allocator<int>> const&, int, int, int, int)
int assignQuartetTreeArrangement(const std::vector<int>& treeLevels, const int loc1, const int loc2, const int loc3, const int loc4) {
        int firstThreeArranged = assignTreeArrangement(treeLevels, loc1, loc2, loc3);
        int withFourthArranged = 0; int overallTreeArrangment = 0;
        switch (firstThreeArranged) {
            case P3isTrios2_Dpositive:
            case P3isTrios2_Dnegative:
                withFourthArranged = assignTreeArrangement(treeLevels, loc1, loc2, loc4);
                switch (withFourthArranged) {
                    case P3isTrios2_Dpositive:
                    case P3isTrios2_Dnegative:
                        overallTreeArrangment = P3isTrios2; break;
                    case P3isTrios1_Dpositive:
                    case P3isTrios1_Dnegative:
                        overallTreeArrangment = P3isTrios0; break;
                    case P3isTrios0_Dpositive:
                    case P3isTrios0_Dnegative:
                        overallTreeArrangment = P3isTrios1; break;
                } break;
            case P3isTrios1_Dpositive:
            case P3isTrios1_Dnegative:
                withFourthArranged = assignTreeArrangement(treeLevels, loc1, loc3, loc4);
                switch (withFourthArranged) {
                    case P3isTrios2_Dpositive:
                    case P3isTrios2_Dnegative:
                        overallTreeArrangment = P3isTrios1; break;
                    case P3isTrios1_Dpositive:
                    case P3isTrios1_Dnegative:
                        overallTreeArrangment = P3isTrios0; break;
                    case P3isTrios0_Dpositive:
                    case P3isTrios0_Dnegative:
                        overallTreeArrangment = P3isTrios2; break;
                } break;
            case P3isTrios0_Dpositive:
            case P3isTrios0_Dnegative:
            withFourthArranged = assignTreeArrangement(treeLevels, loc2, loc3, loc4);
            switch (withFourthArranged) {
                case P3isTrios2_Dpositive:
                case P3isTrios2_Dnegative:
                    overallTreeArrangment = P3isTrios0; break;
                case P3isTrios1_Dpositive:
                case P3isTrios1_Dnegative:
                    overallTreeArrangment = P3isTrios1; break;
                case P3isTrios0_Dpositive:
                case P3isTrios0_Dnegative:
                    overallTreeArrangment = P3isTrios2; break;
            } break;
        }
        return overallTreeArrangment;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r9d, %ebp
movl %r8d, %r14d
movl %ecx, %r15d
movl %edx, %ebx
movq %rsi, %r12
movq %rdi, %r13
callq 0x1a424
xorl %edx, %edx
cmpl $0x6, %eax
ja 0x30dc8
pushq $0x6
popq %rcx
btl %eax, %ecx
jb 0x30d9d
pushq $0x18
popq %rcx
btl %eax, %ecx
jb 0x30d76
pushq $0x60
popq %rcx
btl %eax, %ecx
jae 0x30dc8
movq %r13, %rdi
movq %r12, %rsi
movl %r15d, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x1a424
xorl %edx, %edx
decl %eax
cmpl $0x6, %eax
jae 0x30dc8
movl %eax, %eax
leaq 0x96e8(%rip), %rcx      # 0x3a45c
jmp 0x30dc2
movq %r13, %rdi
movq %r12, %rsi
movl %ebx, %edx
movl %r14d, %ecx
movl %ebp, %r8d
callq 0x1a424
xorl %edx, %edx
decl %eax
cmpl $0x6, %eax
jae 0x30dc8
movl %eax, %eax
leaq 0x96a9(%rip), %rcx      # 0x3a444
jmp 0x30dc2
movq %r13, %rdi
movq %r12, %rsi
movl %ebx, %edx
movl %r15d, %ecx
movl %ebp, %r8d
callq 0x1a424
xorl %edx, %edx
decl %eax
cmpl $0x6, %eax
jae 0x30dc8
movl %eax, %eax
leaq 0x966a(%rip), %rcx      # 0x3a42c
leaq (%rcx,%rax,4), %rax
movl (%rax), %edx
movl %edx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop