// File: /workspace/github_c_makefile_star2_O3/georgeweigt[P]sassafras/sassafras.c
// Function: proc_anova_create_interaction_level_names
void
proc_anova_create_interaction_level_names(int n)
{
	int i, j, k, len, m, x;
	char *name, *s;

	m = dataset->nvar - 1; // index of new interaction column

	for (i = 0; i < n; i++)
		kk[i] = 0;

	for (i = 0; i < dataset->spec[m].num_levels; i++) {

		len = n;

		for (j = 0; j < n; j++) {
			x = xx[j];
			k = kk[j];
			s = dataset->spec[x].ltab[k];
			len += strlen(s);
		}

		name = (char *) xmalloc(len);

		name[0] = 0;

		for (j = 0; j < n; j++) {
			if (j > 0)
				strcat(name, "*");
			x = xx[j];
			k = kk[j];
			s = dataset->spec[x].ltab[k];
			strcat(name, s);
		}

		dataset->spec[m].ltab[i] = name;

		// increment indices

		for (j = n - 1; j >= 0; j--) {
			x = xx[j];
			if (++kk[j] < dataset->spec[x].num_levels)
				break;
			kk[j] = 0;
		}
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq 0xd9de(%rip), %r10      # 0x13ed8
movslq 0x10(%r10), %rbx
decq %rbx
movl %edi, %r14d
testl %edi, %edi
movl %edi, -0x2c(%rbp)
jle 0x652a
leaq (,%r14,4), %rdx
leaq 0xe3a6(%rip), %rdi      # 0x148c0
xorl %esi, %esi
movq %r10, %r15
callq 0x2100
movq %r15, %r10
movl -0x2c(%rbp), %edi
leaq (%rbx,%rbx,4), %r12
cmpl $0x0, 0x2c(%r10,%r12,8)
jle 0x66b3
leaq (,%r14,4), %r13
incq %r14
movq %r14, -0x48(%rbp)
xorl %r8d, %r8d
leaq 0xe36d(%rip), %rbx      # 0x148c0
movq %r12, -0x38(%rbp)
testl %edi, %edi
movq %r8, -0x40(%rbp)
jle 0x6670
addq $0x20, %r10
xorl %r12d, %r12d
movl %edi, %r14d
leaq 0xe02c(%rip), %rax      # 0x145a0
movslq (%r12,%rax), %rax
movslq (%r12,%rbx), %rcx
leaq (%rax,%rax,4), %rax
movq 0x10(%r10,%rax,8), %rax
movq (%rax,%rcx,8), %rdi
movq %r13, %r15
movq %r10, %r13
callq 0x20b0
movq %r13, %r10
movq %r15, %r13
addl %eax, %r14d
addq $0x4, %r12
cmpq %r12, %r15
jne 0x656d
movl %r14d, %edi
callq 0x2bd8
movq %rax, %r14
movb $0x0, (%rax)
movq 0xd91d(%rip), %rax      # 0x13ed8
movl -0x2c(%rbp), %edi
testl %edi, %edi
jle 0x668a
movq %rax, -0x50(%rbp)
leaq 0x20(%rax), %r15
xorl %r12d, %r12d
testq %r12, %r12
je 0x65e5
movq %r14, %rdi
callq 0x20b0
movw $0x2a, (%r14,%rax)
leaq 0xdfb4(%rip), %rax      # 0x145a0
movslq (%r12,%rax), %rax
movslq (%r12,%rbx), %rcx
leaq (%rax,%rax,4), %rax
movq 0x10(%r15,%rax,8), %rax
movq (%rax,%rcx,8), %rsi
movq %r14, %rdi
callq 0x21f0
addq $0x4, %r12
cmpq %r12, %r13
jne 0x65d1
movq -0x38(%rbp), %r12
movq -0x50(%rbp), %rax
movq 0x30(%rax,%r12,8), %rax
movq -0x40(%rbp), %r8
movq %r14, (%rax,%r8,8)
movq 0xd8aa(%rip), %r10      # 0x13ed8
movl -0x2c(%rbp), %edi
testl %edi, %edi
jle 0x66a2
leaq 0x20(%r10), %rax
movq -0x48(%rbp), %rcx
leaq 0xdf5c(%rip), %r9       # 0x145a0
movslq -0x8(%r9,%rcx,4), %rdx
movl -0x8(%rbx,%rcx,4), %esi
incl %esi
movl %esi, -0x8(%rbx,%rcx,4)
leaq (%rdx,%rdx,4), %rdx
cmpl 0xc(%rax,%rdx,8), %esi
jl 0x66a2
movl $0x0, -0x8(%rbx,%rcx,4)
decq %rcx
cmpq $0x1, %rcx
jg 0x6644
jmp 0x66a2
movl -0x2c(%rbp), %edi
callq 0x2bd8
movl -0x2c(%rbp), %edi
movq %rax, %r14
movb $0x0, (%rax)
movq 0xd850(%rip), %rax      # 0x13ed8
jmp 0x668e
movq -0x38(%rbp), %r12
movq 0x30(%rax,%r12,8), %rax
movq -0x40(%rbp), %r8
movq %r14, (%rax,%r8,8)
movq 0xd836(%rip), %r10      # 0x13ed8
incq %r8
movslq 0x2c(%r10,%r12,8), %rax
cmpq %rax, %r8
jl 0x6557
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq