LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/c-zhou[P]oatk/kthread.c
// Function: kt_fp_worker
static void *kt_fp_worker(void *data)
{
	kto_worker_t *w = (kto_worker_t*)data;
	kt_forpool_t *fp = w->t;
	for (;;) {
		long i;
		int action;
		pthread_mutex_lock(&fp->mutex);
		if (--fp->n_pending == 0)
			pthread_cond_signal(&fp->cv_m);
		w->action = 0;
		while (w->action == 0) pthread_cond_wait(&fp->cv_s, &fp->mutex);
		action = w->action;
		pthread_mutex_unlock(&fp->mutex);
		if (action < 0) break;
		for (;;) { // process jobs allocated to this worker
			i = __sync_fetch_and_add(&w->i, fp->n_threads);
			if (i >= fp->n) break;
			fp->func(fp->data, i, w - fp->w);
		}
		while ((i = kt_fp_steal_work(fp)) >= 0) // steal jobs allocated to other workers
			fp->func(fp->data, i, w - fp->w);
	}
	pthread_exit(0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %r13
leaq 0x30(%r13), %r14
leaq 0x58(%r13), %rax
movq %rax, (%rsp)
leaq 0x88(%r13), %r12
movq $-0x1, %r15
movq %r14, %rdi
callq 0x23e0
decl 0x4(%r13)
jne 0x5ecf
movq (%rsp), %rdi
callq 0x21e0
movl $0x0, 0x10(%rbx)
movq %r12, %rdi
movq %r14, %rsi
callq 0x2100
movl 0x10(%rbx), %ebp
testl %ebp, %ebp
je 0x5ed6
movq %r14, %rdi
callq 0x2260
testl %ebp, %ebp
jns 0x5f12
jmp 0x5fa8
movq 0x28(%r13), %rdi
movq %rbx, %rax
subq 0x18(%r13), %rax
shrq $0x3, %rax
imull $0xaaaaaaab, %eax, %edx # imm = 0xAAAAAAAB
callq *0x20(%r13)
movslq (%r13), %rsi
lock
xaddq %rsi, 0x8(%rbx)
cmpq 0x8(%r13), %rsi
jl 0x5ef9
jmp 0x5f3d
movq 0x28(%r13), %rdi
movq %rbx, %rax
subq 0x18(%r13), %rax
shrq $0x3, %rax
imull $0xaaaaaaab, %eax, %edx # imm = 0xAAAAAAAB
callq *0x20(%r13)
movslq (%r13), %rsi
testq %rsi, %rsi
jle 0x5f7d
movq 0x18(%r13), %rax
addq $0x8, %rax
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
xorl %edx, %edx
movabsq $0x7fffffffffffffff, %rdi # imm = 0x7FFFFFFFFFFFFFFF
movq (%rax), %r8
cmpq %r8, %rdi
cmovgl %edx, %ecx
cmovgeq %r8, %rdi
incq %rdx
addq $0x18, %rax
cmpq %rdx, %rsi
jne 0x5f5f
movslq %ecx, %rax
jmp 0x5f84
movq $-0x1, %rax
movq 0x18(%r13), %rcx
leaq (%rax,%rax,2), %rax
lock
xaddq %rsi, 0x8(%rcx,%rax,8)
cmpq 0x8(%r13), %rsi
cmovgeq %r15, %rsi
testq %rsi, %rsi
jns 0x5f24
testl %ebp, %ebp
jns 0x5eb8
xorl %edi, %edi
callq 0x2270
// File: /workspace/github_c_makefile_star2_O1/c-zhou[P]oatk/kthread.c
// Function: kt_forpool_destroy
void kt_forpool_destroy(void *_fp)
{
	kt_forpool_t *fp = (kt_forpool_t*)_fp;
	int i;
	for (i = 0; i < fp->n_threads; ++i) fp->w[i].action = -1;
	pthread_cond_broadcast(&fp->cv_s);
	for (i = 0; i < fp->n_threads; ++i) pthread_join(fp->tid[i], 0);
	pthread_cond_destroy(&fp->cv_s);
	pthread_cond_destroy(&fp->cv_m);
	pthread_mutex_destroy(&fp->mutex);
	free(fp->w); free(fp->tid); free(fp);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movslq (%rdi), %rcx
testq %rcx, %rcx
jle 0x5fde
movq 0x18(%rbx), %rax
shlq $0x3, %rcx
leaq (%rcx,%rcx,2), %rcx
xorl %edx, %edx
movl $0xffffffff, 0x10(%rax,%rdx) # imm = 0xFFFFFFFF
addq $0x18, %rdx
cmpq %rdx, %rcx
jne 0x5fcd
leaq 0x88(%rbx), %r14
movq %r14, %rdi
callq 0x20a0
cmpl $0x0, (%rbx)
jle 0x600f
xorl %r15d, %r15d
movq 0x10(%rbx), %rax
movq (%rax,%r15,8), %rdi
xorl %esi, %esi
callq 0x23a0
incq %r15
movslq (%rbx), %rax
cmpq %rax, %r15
jl 0x5ff5
movq %r14, %rdi
callq 0x2300
leaq 0x58(%rbx), %rdi
callq 0x2300
leaq 0x30(%rbx), %rdi
callq 0x2150
movq 0x18(%rbx), %rdi
callq 0x2050
movq 0x10(%rbx), %rdi
callq 0x2050
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x2050
// File: /workspace/github_c_makefile_star2_O1/c-zhou[P]oatk/kthread.c
// Function: kt_forpool
void kt_forpool(void *_fp, void (*func)(void*,long,int), void *data, long n)
{
	kt_forpool_t *fp = (kt_forpool_t*)_fp;
	long i;
	if (fp && fp->n_threads > 1) {
		fp->n = n, fp->func = func, fp->data = data, fp->n_pending = fp->n_threads;
		for (i = 0; i < fp->n_threads; ++i) fp->w[i].i = i, fp->w[i].action = 1;
		pthread_mutex_lock(&fp->mutex);
		pthread_cond_broadcast(&fp->cv_s);
		while (fp->n_pending) pthread_cond_wait(&fp->cv_m, &fp->mutex);
		pthread_mutex_unlock(&fp->mutex);
	} else for (i = 0; i < n; ++i) func(data, i, 0);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r15
movq %rdx, %r14
movq %rsi, %r12
testq %rdi, %rdi
je 0x60e3
movq %rdi, %rbx
movslq (%rdi), %rax
cmpq $0x2, %rax
jl 0x60e3
movq %r15, 0x8(%rbx)
movq %r12, 0x20(%rbx)
movq %r14, 0x28(%rbx)
movl %eax, 0x4(%rbx)
movq 0x18(%rbx), %rcx
addq $0x10, %rcx
xorl %edx, %edx
movq %rdx, -0x8(%rcx)
movl $0x1, (%rcx)
incq %rdx
addq $0x18, %rcx
cmpq %rdx, %rax
jne 0x6087
leaq 0x30(%rbx), %r14
movq %r14, %rdi
callq 0x23e0
leaq 0x88(%rbx), %rdi
callq 0x20a0
cmpl $0x0, 0x4(%rbx)
je 0x60d0
leaq 0x58(%rbx), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x2100
cmpl $0x0, 0x4(%rbx)
jne 0x60bf
movq %r14, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x2260
testq %r15, %r15
jle 0x60fd
xorl %ebx, %ebx
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq *%r12
incq %rbx
cmpq %rbx, %r15
jne 0x60ea
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/c-zhou[P]oatk/kthread.c
// Function: kt_pipeline
void kt_pipeline(int n_threads, void *(*func)(void*, int, void*), void *shared_data, int n_steps)
{
	ktp_t aux;
	pthread_t *tid;
	int i;

	if (n_threads < 1) n_threads = 1;
	aux.n_workers = n_threads;
	aux.n_steps = n_steps;
	aux.func = func;
	aux.shared = shared_data;
	aux.index = 0;
	pthread_mutex_init(&aux.mutex, 0);
	pthread_cond_init(&aux.cv, 0);

	aux.workers = (ktp_worker_t*)alloca(n_threads * sizeof(ktp_worker_t));
	for (i = 0; i < n_threads; ++i) {
		ktp_worker_t *w = &aux.workers[i];
		w->step = 0; w->pl = &aux; w->data = 0;
		w->index = aux.index++;
	}

	tid = (pthread_t*)alloca(n_threads * sizeof(pthread_t));
	for (i = 0; i < n_threads; ++i) pthread_create(&tid[i], 0, ktp_worker, &aux.workers[i]);
	for (i = 0; i < n_threads; ++i) pthread_join(tid[i], 0);

	pthread_mutex_destroy(&aux.mutex);
	pthread_cond_destroy(&aux.cv);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
cmpl $0x2, %edi
movl $0x1, %r14d
cmovgel %edi, %r14d
leaq -0x88(%rbp), %rdi
movl %r14d, -0x10(%rdi)
movl %ecx, -0xc(%rdi)
movq %rsi, -0x20(%rdi)
movq %rdx, -0x28(%rdi)
movq $0x0, -0x18(%rdi)
xorl %ebx, %ebx
xorl %esi, %esi
callq 0x23d0
leaq -0x60(%rbp), %r15
movq %r15, %rdi
xorl %esi, %esi
callq 0x2250
movq %r14, %r13
shlq $0x5, %r13
movq %rsp, %rax
subq %r13, %rax
movq %rax, %rsp
movq %rax, -0x30(%r15)
movq -0x40(%r15), %rcx
leaq -0xb0(%rbp), %rdx
movl $0x0, 0x10(%rax,%rbx)
movq %rdx, (%rax,%rbx)
movq $0x0, 0x18(%rax,%rbx)
movq %rcx, 0x8(%rax,%rbx)
incq %rcx
addq $0x20, %rbx
cmpq %rbx, %r13
jne 0x617e
movq %rcx, -0xa0(%rbp)
movq %rsp, %rbx
movq %r14, -0x30(%rbp)
leaq 0xf(,%r14,8), %rax
andq $-0x10, %rax
subq %rax, %rbx
movq %rbx, %rsp
xorl %r14d, %r14d
leaq 0x65(%rip), %r15        # 0x6233
movq %rbx, %r12
movq -0x90(%rbp), %rcx
addq %r14, %rcx
movq %r12, %rdi
xorl %esi, %esi
movq %r15, %rdx
callq 0x22e0
addq $0x20, %r14
addq $0x8, %r12
cmpq %r14, %r13
jne 0x61d1
xorl %r14d, %r14d
movq -0x30(%rbp), %r15
movq (%rbx,%r14,8), %rdi
xorl %esi, %esi
callq 0x23a0
incq %r14
cmpq %r14, %r15
jne 0x61fc
leaq -0x88(%rbp), %rdi
callq 0x2150
leaq -0x60(%rbp), %rdi
callq 0x2300
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: toBitInterleaving
void toBitInterleaving(UINT32 low, UINT32 high, UINT32 *even, UINT32 *odd)
{
    unsigned int i;

    *even = 0;
    *odd = 0;
    for(i=0; i<64; i++) {
        unsigned int inBit;
        if (i < 32)
            inBit = (low >> i) & 1;
        else
            inBit = (high >> (i-32)) & 1;
        if ((i % 2) == 0)
            *even |= inBit << (i/2);
        else
            *odd |= inBit << ((i-1)/2);
    }
}

// Assembly:
xorl %eax, %eax
movl %eax, (%rdx)
movl %eax, (%rcx)
movl %eax, %r8d
subl $0x20, %r8d
shrxl %eax, %edi, %r9d
shrxl %r8d, %esi, %r10d
cmovbl %r9d, %r10d
andl $0x1, %r10d
movl %eax, %r9d
andl $0x1fe, %r9d            # imm = 0x1FE
testb $0x1, %al
movq %rdx, %rax
cmovneq %rcx, %rax
shrl %r9d
shlxl %r9d, %r10d, %r9d
orl %r9d, (%rax)
leal 0x21(%r8), %eax
cmpl $0x40, %eax
jne 0x5842
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: fromBitInterleaving
void fromBitInterleaving(UINT32 even, UINT32 odd, UINT32 *low, UINT32 *high)
{
    unsigned int i;

    *low = 0;
    *high = 0;
    for(i=0; i<64; i++) {
        unsigned int inBit;
        if ((i % 2) == 0)
            inBit = (even >> (i/2)) & 1;
        else
            inBit = (odd >> ((i-1)/2)) & 1;
        if (i < 32)
            *low |= inBit << i;
        else
            *high |= inBit << (i-32);
    }
}

// Assembly:
xorl %eax, %eax
movl %eax, (%rdx)
movl %eax, (%rcx)
movl %eax, %r8d
andl $0x1fe, %r8d            # imm = 0x1FE
testb $0x1, %al
movl %edi, %r9d
cmovnel %esi, %r9d
shrl %r8d
shrxl %r8d, %r9d, %r8d
andl $0x1, %r8d
movl %eax, %r9d
subl $0x20, %r9d
movq %rcx, %r10
cmovbq %rdx, %r10
cmovael %r9d, %eax
shlxl %eax, %r8d, %eax
orl %eax, (%r10)
leal 0x21(%r9), %eax
cmpl $0x40, %eax
jne 0x5889
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_AddByte
void KeccakP1600_AddByte(void *state, unsigned char byte, unsigned int offset)
{
    unsigned char data[1];

    assert(offset < 200);
    data[0] = byte;
    KeccakP1600_AddBytes(state, data, offset, 1);
}

// Assembly:
pushq %rax
cmpl $0xc8, %edx
jae 0x5922
leaq 0x7(%rsp), %rax
movb %sil, (%rax)
movq %rax, %rsi
movl $0x1, %ecx
callq 0x5650
popq %rax
retq
leaq 0xa7b7(%rip), %rdi      # 0x100e0
leaq 0xa7bd(%rip), %rsi      # 0x100ed
leaq 0xa7fc(%rip), %rcx      # 0x10133
movl $0xc4, %edx
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_AddBytes
void KeccakP1600_AddBytes(void *state, const unsigned char *data, unsigned int offset, unsigned int length)
{
    unsigned int lanePosition = offset/8;
    unsigned int offsetInLane = offset%8;

    assert(offset < 200);
    assert(offset+length <= 200);
    while(length > 0) {
        unsigned int bytesInLane = 8 - offsetInLane;
        if (bytesInLane > length)
            bytesInLane = length;
        KeccakP1600_AddBytesInLane(state, lanePosition, data, offsetInLane, bytesInLane);
        length -= bytesInLane;
        lanePosition++;
        offsetInLane = 0;
        data += bytesInLane;
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
cmpl $0xc8, %edx
jae 0x59ae
movl %ecx, %ebx
movl %edx, %r14d
leal (%rbx,%r14), %eax
cmpl $0xc8, %eax
ja 0x59cd
testl %ebx, %ebx
je 0x59a4
movq %rsi, %r15
movq %rdi, %r12
movl %r14d, %ecx
andl $0x7, %ecx
shrl $0x3, %r14d
movl $0x8, %r13d
subl %ecx, %r13d
cmpl %ebx, %r13d
cmovael %ebx, %r13d
movq %r12, %rdi
movl %r14d, %esi
movq %r15, %rdx
movl %r13d, %r8d
callq 0x5490
incl %r14d
addq %r13, %r15
xorl %ecx, %ecx
subl %r13d, %ebx
jne 0x5976
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0xa72b(%rip), %rdi      # 0x100e0
leaq 0xa731(%rip), %rsi      # 0x100ed
leaq 0xa7ae(%rip), %rcx      # 0x10171
movl $0xe9, %edx
callq 0x5190
leaq 0xa7f2(%rip), %rdi      # 0x101c6
leaq 0xa712(%rip), %rsi      # 0x100ed
leaq 0xa78f(%rip), %rcx      # 0x10171
movl $0xea, %edx
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_AddBytesInLane
void KeccakP1600_AddBytesInLane(void *state, unsigned int lanePosition, const unsigned char *data, unsigned int offset, unsigned int length)
{
    if ((lanePosition < 25) && (offset < 8) && (offset+length <= 8)) {
        UINT8 laneAsBytes[8];
        UINT32 low, high;
        UINT32 lane[2];
        UINT32 *stateAsHalfLanes;

        memset(laneAsBytes, 0, 8);
        memcpy(laneAsBytes+offset, data, length);
        low = laneAsBytes[0]
            | ((UINT32)(laneAsBytes[1]) << 8)
            | ((UINT32)(laneAsBytes[2]) << 16)
            | ((UINT32)(laneAsBytes[3]) << 24);
        high = laneAsBytes[4]
            | ((UINT32)(laneAsBytes[5]) << 8)
            | ((UINT32)(laneAsBytes[6]) << 16)
            | ((UINT32)(laneAsBytes[7]) << 24);
        toBitInterleaving(low, high, lane, lane+1);
        stateAsHalfLanes = (UINT32*)state;
        stateAsHalfLanes[lanePosition*2+0] ^= lane[0];
        stateAsHalfLanes[lanePosition*2+1] ^= lane[1];
    }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
cmpl $0x19, %esi
setae %al
cmpl $0x8, %ecx
setae %sil
orb %al, %sil
leal (%r8,%rcx), %eax
cmpl $0x9, %eax
setae %al
orb %sil, %al
jne 0x5b26
movq %rdi, %r14
movq $0x0, (%rsp)
movl %ecx, %eax
leaq (%rsp,%rax), %rdi
movl %r8d, %eax
movq %rdx, %rsi
movq %rax, %rdx
callq 0x5700
vpbroadcastd (%rsp), %ymm0
vpmovsxbd 0xa665(%rip), %ymm1 # 0x100a8
vpxor %xmm9, %xmm9, %xmm9
movl $0x40, %eax
vpbroadcastd 0x4(%rsp), %ymm3
vpbroadcastd 0xa623(%rip), %ymm4 # 0x10080
vpbroadcastd 0xa61e(%rip), %ymm5 # 0x10084
vpbroadcastd 0xa619(%rip), %ymm6 # 0x10088
vpcmpeqd %ymm7, %ymm7, %ymm7
vpbroadcastd 0xa610(%rip), %ymm8 # 0x1008c
vpxor %xmm2, %xmm2, %xmm2
vmovdqa %ymm9, %ymm10
vpcmpltud %ymm4, %ymm1, %k1
vpaddd %ymm5, %ymm1, %ymm9
vpsrlvd %ymm9, %ymm3, %ymm9
vpsrlvd %ymm1, %ymm0, %ymm9 {%k1}
vpand %ymm6, %ymm9, %ymm9
vptestnmd %ymm6, %ymm1, %k1
vpaddd %ymm7, %ymm1, %ymm11
vpsrld $0x1, %ymm11, %ymm11
vpsllvd %ymm11, %ymm9, %ymm11
vpsrld $0x1, %ymm1, %ymm12
vpsllvd %ymm12, %ymm9, %ymm12
vpor %ymm11, %ymm10, %ymm9
vmovdqa32 %ymm10, %ymm9 {%k1}
vpord %ymm12, %ymm2, %ymm2 {%k1}
vpaddd %ymm1, %ymm8, %ymm1
addl $-0x8, %eax
jne 0x5a80
vextracti128 $0x1, %ymm9, %xmm0
vpor %xmm0, %xmm9, %xmm0
vpshufd $0xee, %xmm0, %xmm1     # xmm1 = xmm0[2,3,2,3]
vpor %xmm1, %xmm0, %xmm0
vpsrlq $0x20, %xmm0, %xmm1
vextracti128 $0x1, %ymm2, %xmm3
vpor %xmm3, %xmm2, %xmm2
vpshufd $0xee, %xmm2, %xmm3     # xmm3 = xmm2[2,3,2,3]
vpor %xmm3, %xmm2, %xmm2
vpsrlq $0x20, %xmm2, %xmm3
addl %ebx, %ebx
vmovq (%r14,%rbx,4), %xmm4
vpor %xmm1, %xmm0, %xmm0
vpor %xmm3, %xmm2, %xmm1
vpunpckldq %xmm0, %xmm1, %xmm0 # xmm0 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
vpxor %xmm0, %xmm4, %xmm0
vmovq %xmm0, (%r14,%rbx,4)
addq $0x8, %rsp
popq %rbx
popq %r14
vzeroupper
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_OverwriteBytesInLane
void KeccakP1600_OverwriteBytesInLane(void *state, unsigned int lanePosition, const unsigned char *data, unsigned int offset, unsigned int length)
{
    if ((lanePosition < 25) && (offset < 8) && (offset+length <= 8)) {
        UINT8 laneAsBytes[8];
        UINT32 low, high;
        UINT32 lane[2];
        UINT32 *stateAsHalfLanes;

        KeccakP1600_ExtractBytesInLane(state, lanePosition, laneAsBytes, 0, 8);
        memcpy(laneAsBytes+offset, data, length);
        low = laneAsBytes[0]
            | ((UINT32)(laneAsBytes[1]) << 8)
            | ((UINT32)(laneAsBytes[2]) << 16)
            | ((UINT32)(laneAsBytes[3]) << 24);
        high = laneAsBytes[4]
            | ((UINT32)(laneAsBytes[5]) << 8)
            | ((UINT32)(laneAsBytes[6]) << 16)
            | ((UINT32)(laneAsBytes[7]) << 24);
        toBitInterleaving(low, high, lane, lane+1);
        stateAsHalfLanes = (UINT32*)state;
        stateAsHalfLanes[lanePosition*2+0] = lane[0];
        stateAsHalfLanes[lanePosition*2+1] = lane[1];
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %r8d, %r12d
movl %ecx, %r13d
cmpl $0x19, %esi
setae %al
cmpl $0x8, %ecx
setae %cl
orb %al, %cl
leal (%r12,%r13), %eax
cmpl $0x9, %eax
setae %al
orb %cl, %al
jne 0x5c7d
movq %rdx, %r15
movl %esi, %r14d
movq %rdi, %rbx
movq %rsp, %rbp
movq %rbp, %rdx
xorl %ecx, %ecx
movl $0x8, %r8d
callq 0x5030
movl %r13d, %eax
leaq (%rsp,%rax), %rdi
movl %r12d, %edx
movq %r15, %rsi
callq 0x5700
vpbroadcastd (%rbp), %ymm0
vpmovsxbd 0xa509(%rip), %ymm1 # 0x100a8
vpxor %xmm9, %xmm9, %xmm9
movl $0x40, %eax
vpbroadcastd 0x4(%rbp), %ymm3
vpbroadcastd 0xa4c8(%rip), %ymm4 # 0x10080
vpbroadcastd 0xa4c3(%rip), %ymm5 # 0x10084
vpbroadcastd 0xa4be(%rip), %ymm6 # 0x10088
vpcmpeqd %ymm7, %ymm7, %ymm7
vpbroadcastd 0xa4b5(%rip), %ymm8 # 0x1008c
vpxor %xmm2, %xmm2, %xmm2
vmovdqa %ymm9, %ymm10
vpcmpltud %ymm4, %ymm1, %k1
vpaddd %ymm5, %ymm1, %ymm9
vpsrlvd %ymm9, %ymm3, %ymm9
vpsrlvd %ymm1, %ymm0, %ymm9 {%k1}
vpand %ymm6, %ymm9, %ymm9
vptestnmd %ymm6, %ymm1, %k1
vpaddd %ymm7, %ymm1, %ymm11
vpsrld $0x1, %ymm11, %ymm11
vpsllvd %ymm11, %ymm9, %ymm11
vpsrld $0x1, %ymm1, %ymm12
vpsllvd %ymm12, %ymm9, %ymm12
vpor %ymm11, %ymm10, %ymm9
vmovdqa32 %ymm10, %ymm9 {%k1}
vpord %ymm12, %ymm2, %ymm2 {%k1}
vpaddd %ymm1, %ymm8, %ymm1
addl $-0x8, %eax
jne 0x5bdb
vextracti128 $0x1, %ymm9, %xmm0
vpor %xmm0, %xmm9, %xmm0
vpshufd $0xee, %xmm0, %xmm1     # xmm1 = xmm0[2,3,2,3]
vpor %xmm1, %xmm0, %xmm0
vpsrlq $0x20, %xmm0, %xmm1
vpor %xmm1, %xmm0, %xmm0
vextracti128 $0x1, %ymm2, %xmm1
vpor %xmm1, %xmm2, %xmm1
vpshufd $0xee, %xmm1, %xmm2     # xmm2 = xmm1[2,3,2,3]
vpor %xmm2, %xmm1, %xmm1
vpsrlq $0x20, %xmm1, %xmm2
vpor %xmm2, %xmm1, %xmm1
leal (%r14,%r14), %eax
vmovd %xmm1, (%rbx,%rax,4)
movl %r14d, %eax
vmovd %xmm0, 0x4(%rbx,%rax,8)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
vzeroupper
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_ExtractBytesInLane
void KeccakP1600_ExtractBytesInLane(const void *state, unsigned int lanePosition, unsigned char *data, unsigned int offset, unsigned int length)
{
    if ((lanePosition < 25) && (offset < 8) && (offset+length <= 8)) {
        UINT32 *stateAsHalfLanes = (UINT32*)state;
        UINT32 lane[2];
        UINT8 laneAsBytes[8];
        fromBitInterleaving(stateAsHalfLanes[lanePosition*2], stateAsHalfLanes[lanePosition*2+1], lane, lane+1);
        laneAsBytes[0] = lane[0] & 0xFF;
        laneAsBytes[1] = (lane[0] >> 8) & 0xFF;
        laneAsBytes[2] = (lane[0] >> 16) & 0xFF;
        laneAsBytes[3] = (lane[0] >> 24) & 0xFF;
        laneAsBytes[4] = lane[1] & 0xFF;
        laneAsBytes[5] = (lane[1] >> 8) & 0xFF;
        laneAsBytes[6] = (lane[1] >> 16) & 0xFF;
        laneAsBytes[7] = (lane[1] >> 24) & 0xFF;
        memcpy(data, laneAsBytes+offset, length);
    }
}

// Assembly:
cmpl $0x19, %esi
setae %al
cmpl $0x8, %ecx
setae %r9b
orb %al, %r9b
leal (%r8,%rcx), %eax
cmpl $0x9, %eax
setae %al
orb %r9b, %al
jne 0x5df1
movl %esi, %eax
addl %esi, %esi
vpbroadcastd 0x4(%rdi,%rax,8), %ymm1
vpbroadcastd (%rdi,%rsi,4), %ymm2
vpmovsxbd 0xa3dc(%rip), %ymm3 # 0x100a8
vpxor %xmm0, %xmm0, %xmm0
movl $0x40, %eax
vpbroadcastd 0xa3aa(%rip), %ymm4 # 0x10088
vpbroadcastd 0xa3a9(%rip), %ymm5 # 0x10090
vpcmpeqd %ymm6, %ymm6, %ymm6
vpbroadcastd 0xa390(%rip), %ymm7 # 0x10084
vpbroadcastd 0xa38f(%rip), %ymm8 # 0x1008c
vpxor %xmm9, %xmm9, %xmm9
vmovdqa %ymm9, %ymm10
vptestnmd %ymm4, %ymm3, %k1
vpaddd %ymm6, %ymm3, %ymm9
vpsrld $0x1, %ymm9, %ymm9
vpsrlvd %ymm9, %ymm1, %ymm9
vpsrld $0x1, %ymm3, %ymm11
vpsrlvd %ymm11, %ymm2, %ymm9 {%k1}
vpand %ymm4, %ymm9, %ymm9
vpcmpnleud %ymm5, %ymm3, %k1
vpaddd %ymm7, %ymm3, %ymm11
vpsllvd %ymm11, %ymm9, %ymm11
vpsllvd %ymm3, %ymm9, %ymm9
vpord %ymm11, %ymm0, %ymm0 {%k1}
vpor %ymm9, %ymm10, %ymm9
vmovdqa32 %ymm10, %ymm9 {%k1}
vpaddd %ymm3, %ymm8, %ymm3
addl $-0x8, %eax
jne 0x5d02
pushq %rbx
subq $0x10, %rsp
vextracti128 $0x1, %ymm0, %xmm1
vpor %xmm1, %xmm0, %xmm0
vpshufd $0xee, %xmm0, %xmm1     # xmm1 = xmm0[2,3,2,3]
vpor %xmm1, %xmm0, %xmm0
vpsrlq $0x20, %xmm0, %xmm1
vpor %xmm1, %xmm0, %xmm0
vmovd %xmm0, %eax
vextracti128 $0x1, %ymm9, %xmm0
vpor %xmm0, %xmm9, %xmm0
vpshufd $0xee, %xmm0, %xmm1     # xmm1 = xmm0[2,3,2,3]
vpor %xmm1, %xmm0, %xmm0
vpsrlq $0x20, %xmm0, %xmm1
vpor %xmm1, %xmm0, %xmm0
vmovd %xmm0, %ebx
movb %bl, 0x8(%rsp)
movb %bh, 0x9(%rsp)
movl %ebx, %esi
shrl $0x10, %esi
movb %sil, 0xa(%rsp)
shrl $0x18, %ebx
movb %bl, 0xb(%rsp)
movb %al, 0xc(%rsp)
movb %ah, 0xd(%rsp)
movl %eax, %esi
shrl $0x10, %esi
movb %sil, 0xe(%rsp)
shrl $0x18, %eax
movb %al, 0xf(%rsp)
movl %ecx, %eax
leaq (%rsp,%rax), %rsi
addq $0x8, %rsi
movl %r8d, %eax
movq %rdx, %rdi
movq %rax, %rdx
vzeroupper
callq 0x5700
addq $0x10, %rsp
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_OverwriteBytes
void KeccakP1600_OverwriteBytes(void *state, const unsigned char *data, unsigned int offset, unsigned int length)
{
    unsigned int lanePosition = offset/8;
    unsigned int offsetInLane = offset%8;

    assert(offset < 200);
    assert(offset+length <= 200);
    while(length > 0) {
        unsigned int bytesInLane = 8 - offsetInLane;
        if (bytesInLane > length)
            bytesInLane = length;
        KeccakP1600_OverwriteBytesInLane(state, lanePosition, data, offsetInLane, bytesInLane);
        length -= bytesInLane;
        lanePosition++;
        offsetInLane = 0;
        data += bytesInLane;
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
cmpl $0xc8, %edx
jae 0x5e5f
movl %ecx, %ebx
movl %edx, %r14d
leal (%rbx,%r14), %eax
cmpl $0xc8, %eax
ja 0x5e7e
testl %ebx, %ebx
je 0x5e55
movq %rsi, %r15
movq %rdi, %r12
movl %r14d, %ecx
andl $0x7, %ecx
shrl $0x3, %r14d
movl $0x8, %r13d
subl %ecx, %r13d
cmpl %ebx, %r13d
cmovael %ebx, %r13d
movq %r12, %rdi
movl %r14d, %esi
movq %r15, %rdx
movl %r13d, %r8d
callq 0x54e0
incl %r14d
addq %r13, %r15
xorl %ecx, %ecx
subl %r13d, %ebx
jne 0x5e27
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0xa27a(%rip), %rdi      # 0x100e0
leaq 0xa280(%rip), %rsi      # 0x100ed
leaq 0xa367(%rip), %rcx      # 0x101db
movl $0x119, %edx            # imm = 0x119
callq 0x5190
leaq 0xa341(%rip), %rdi      # 0x101c6
leaq 0xa261(%rip), %rsi      # 0x100ed
leaq 0xa348(%rip), %rcx      # 0x101db
movl $0x11a, %edx            # imm = 0x11A
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_OverwriteWithZeroes
void KeccakP1600_OverwriteWithZeroes(void *state, unsigned int byteCount)
{
    UINT8 laneAsBytes[8];
    unsigned int lanePosition = 0;

    assert(byteCount <= 200);
    memset(laneAsBytes, 0, 8);
    while(byteCount > 0) {
        if (byteCount < 8) {
            KeccakP1600_OverwriteBytesInLane(state, lanePosition, laneAsBytes, 0, byteCount);
            byteCount = 0;
        }
        else {
            UINT32 *stateAsHalfLanes = (UINT32*)state;
            stateAsHalfLanes[lanePosition*2+0] = 0;
            stateAsHalfLanes[lanePosition*2+1] = 0;
            byteCount -= 8;
            lanePosition++;
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
cmpl $0xc9, %esi
jae 0x5f03
movl %esi, %r8d
movq $0x0, (%rsp)
testl %esi, %esi
je 0x5ef8
movq %rdi, %rbx
xorl %ebp, %ebp
movq %rsp, %r14
xorl %r15d, %r15d
cmpl $0x7, %r8d
ja 0x5ee1
movq %rbx, %rdi
movl %r15d, %esi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x54e0
xorl %r8d, %r8d
jmp 0x5ef3
leal (%r15,%r15), %eax
movl %ebp, (%rbx,%rax,4)
movl %ebp, 0x4(%rbx,%rax,4)
addl $-0x8, %r8d
incl %r15d
testl %r8d, %r8d
jne 0x5ec6
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0xa32c(%rip), %rdi      # 0x10236
leaq 0xa1dc(%rip), %rsi      # 0x100ed
leaq 0xa32f(%rip), %rcx      # 0x10247
movl $0x12e, %edx            # imm = 0x12E
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_Permute_12rounds
void KeccakP1600_Permute_12rounds(void *state)
{
    UINT32 *stateAsHalfLanes = (UINT32*)state;
    {
        UINT8 stateAsBytes[1600/8];
        KeccakP1600_ExtractBytes(state, stateAsBytes, 0, 1600/8);
#ifdef KeccakReference
        displayStateAsBytes(1, "Input of permutation", stateAsBytes, 1600);
#endif
    }
    KeccakP1600_PermutationOnWords(stateAsHalfLanes, 12);
    {
        UINT8 stateAsBytes[1600/8];
        KeccakP1600_ExtractBytes(state, stateAsBytes, 0, 1600/8);
#ifdef KeccakReference
        displayStateAsBytes(1, "State after permutation", stateAsBytes, 1600);
#endif
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xd0, %rsp
movq %rdi, %rbx
movq %rsp, %r14
movl $0xc8, %r12d
xorl %ebp, %ebp
cmpl $0x8, %r12d
movl $0x8, %r15d
cmovbl %r12d, %r15d
movq %rbx, %rdi
movl %ebp, %esi
movq %r14, %rdx
xorl %ecx, %ecx
movl %r15d, %r8d
callq 0x5030
subl %r15d, %r12d
incl %ebp
addq %r15, %r14
cmpl $0x19, %ebp
jne 0x5f3f
movq %rbx, %rdi
movl $0xc, %esi
callq 0x5590
movq %rsp, %r14
movl $0xc8, %r12d
xorl %ebp, %ebp
cmpl $0x8, %r12d
movl $0x8, %r15d
cmovbl %r12d, %r15d
movq %rbx, %rdi
movl %ebp, %esi
movq %r14, %rdx
xorl %ecx, %ecx
movl %r15d, %r8d
callq 0x5030
subl %r15d, %r12d
incl %ebp
addq %r15, %r14
cmpl $0x19, %ebp
jne 0x5f84
addq $0xd0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_ExtractBytes
void KeccakP1600_ExtractBytes(const void *state, unsigned char *data, unsigned int offset, unsigned int length)
{
    unsigned int lanePosition = offset/8;
    unsigned int offsetInLane = offset%8;

    assert(offset < 200);
    assert(offset+length <= 200);
    while(length > 0) {
        unsigned int bytesInLane = 8 - offsetInLane;
        if (bytesInLane > length)
            bytesInLane = length;
        KeccakP1600_ExtractBytesInLane(state, lanePosition, data, offsetInLane, bytesInLane);
        length -= bytesInLane;
        lanePosition++;
        offsetInLane = 0;
        data += bytesInLane;
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
cmpl $0xc8, %edx
jae 0x602e
movl %ecx, %ebx
movl %edx, %r14d
leal (%rbx,%r14), %eax
cmpl $0xc8, %eax
ja 0x604d
testl %ebx, %ebx
je 0x6024
movq %rsi, %r15
movq %rdi, %r12
movl %r14d, %ecx
andl $0x7, %ecx
shrl $0x3, %r14d
movl $0x8, %r13d
subl %ecx, %r13d
cmpl %ebx, %r13d
cmovael %ebx, %r13d
movq %r12, %rdi
movl %r14d, %esi
movq %r15, %rdx
movl %r13d, %r8d
callq 0x5030
incl %r14d
addq %r13, %r15
xorl %ecx, %ecx
subl %r13d, %ebx
jne 0x5ff6
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
leaq 0xa0ab(%rip), %rdi      # 0x100e0
leaq 0xa0b1(%rip), %rsi      # 0x100ed
leaq 0xa23f(%rip), %rcx      # 0x10282
movl $0x201, %edx            # imm = 0x201
callq 0x5190
leaq 0xa172(%rip), %rdi      # 0x101c6
leaq 0xa092(%rip), %rsi      # 0x100ed
leaq 0xa220(%rip), %rcx      # 0x10282
movl $0x202, %edx            # imm = 0x202
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_Permute_24rounds
void KeccakP1600_Permute_24rounds(void *state)
{
    UINT32 *stateAsHalfLanes = (UINT32*)state;
    {
        UINT8 stateAsBytes[1600/8];
        KeccakP1600_ExtractBytes(state, stateAsBytes, 0, 1600/8);
#ifdef KeccakReference
        displayStateAsBytes(1, "Input of permutation", stateAsBytes, 1600);
#endif
    }
    KeccakP1600_PermutationOnWords(stateAsHalfLanes, 24);
    {
        UINT8 stateAsBytes[1600/8];
        KeccakP1600_ExtractBytes(state, stateAsBytes, 0, 1600/8);
#ifdef KeccakReference
        displayStateAsBytes(1, "State after permutation", stateAsBytes, 1600);
#endif
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xd0, %rsp
movq %rdi, %rbx
movq %rsp, %r14
movl $0xc8, %r12d
xorl %ebp, %ebp
cmpl $0x8, %r12d
movl $0x8, %r15d
cmovbl %r12d, %r15d
movq %rbx, %rdi
movl %ebp, %esi
movq %r14, %rdx
xorl %ecx, %ecx
movl %r15d, %r8d
callq 0x5030
subl %r15d, %r12d
incl %ebp
addq %r15, %r14
cmpl $0x19, %ebp
jne 0x64d2
movq %rbx, %rdi
movl $0x18, %esi
callq 0x5590
movq %rsp, %r14
movl $0xc8, %r12d
xorl %ebp, %ebp
cmpl $0x8, %r12d
movl $0x8, %r15d
cmovbl %r12d, %r15d
movq %rbx, %rdi
movl %ebp, %esi
movq %r14, %rdx
xorl %ecx, %ecx
movl %r15d, %r8d
callq 0x5030
subl %r15d, %r12d
incl %ebp
addq %r15, %r14
cmpl $0x19, %ebp
jne 0x6517
addq $0xd0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: ROL64
void ROL64(UINT32 inEven, UINT32 inOdd, UINT32 *outEven, UINT32 *outOdd, unsigned int offset)
{
    if ((offset % 2) == 0) {
        *outEven = ROL32(inEven, offset/2);
        *outOdd = ROL32(inOdd, offset/2);
    }
    else {
        *outEven = ROL32(inOdd, (offset+1)/2);
        *outOdd = ROL32(inEven, (offset-1)/2);
    }
}

// Assembly:
movl %r8d, %eax
testb $0x1, %r8b
jne 0x658c
shrl %eax
shlxl %eax, %edi, %r9d
shlxl %eax, %esi, %r10d
negb %al
shrxl %eax, %edi, %r11d
xorl %r9d, %r11d
shrxl %eax, %esi, %eax
xorl %r10d, %eax
testl %r8d, %r8d
cmovel %edi, %r11d
movl %r11d, (%rdx)
cmovel %esi, %eax
movl %eax, %edi
jmp 0x65ba
incl %eax
je 0x65a1
shrl %eax
shlxl %eax, %esi, %r9d
negb %al
shrxl %eax, %esi, %esi
xorl %r9d, %esi
movl %esi, (%rdx)
decl %r8d
je 0x65ba
shrl %r8d
shlxl %r8d, %edi, %eax
negb %r8b
shrxl %r8d, %edi, %edi
xorl %eax, %edi
movl %edi, (%rcx)
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_ExtractAndAddBytesInLane
void KeccakP1600_ExtractAndAddBytesInLane(const void *state, unsigned int lanePosition, const unsigned char *input, unsigned char *output, unsigned int offset, unsigned int length)
{
    if ((lanePosition < 25) && (offset < 8) && (offset+length <= 8)) {
        UINT8 laneAsBytes[8];
        unsigned int i;

        KeccakP1600_ExtractBytesInLane(state, lanePosition, laneAsBytes, offset, length);
        for(i=0; i<length; i++)
            output[i] = input[i] ^ laneAsBytes[i];
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %r9d, %r15d
movq %rcx, %rbx
cmpl $0x19, %esi
setae %al
cmpl $0x8, %r8d
setae %cl
orb %al, %cl
leal (%r15,%r8), %eax
cmpl $0x9, %eax
setae %al
orb %cl, %al
jne 0x6619
movq %rdx, %r14
leaq 0x8(%rsp), %rdx
movl %r8d, %ecx
movl %r15d, %r8d
callq 0x5030
testl %r15d, %r15d
je 0x6619
movl %r15d, %eax
xorl %ecx, %ecx
movb 0x8(%rsp,%rcx), %dl
xorb (%r14,%rcx), %dl
movb %dl, (%rbx,%rcx)
incq %rcx
cmpq %rcx, %rax
jne 0x6606
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_ExtractAndAddBytes
void KeccakP1600_ExtractAndAddBytes(const void *state, const unsigned char *input, unsigned char *output, unsigned int offset, unsigned int length)
{
    unsigned int lanePosition = offset/8;
    unsigned int offsetInLane = offset%8;

    assert(offset < 200);
    assert(offset+length <= 200);
    while(length > 0) {
        unsigned int bytesInLane = 8 - offsetInLane;
        if (bytesInLane > length)
            bytesInLane = length;
        KeccakP1600_ExtractAndAddBytesInLane(state, lanePosition, input, output, offsetInLane, bytesInLane);
        length -= bytesInLane;
        lanePosition++;
        offsetInLane = 0;
        input += bytesInLane;
        output += bytesInLane;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpl $0xc8, %ecx
jae 0x669f
movl %r8d, %ebx
movl %ecx, %r14d
leal (%rbx,%r14), %eax
cmpl $0xc8, %eax
ja 0x66be
testl %ebx, %ebx
je 0x6690
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r13
movl %r14d, %r8d
andl $0x7, %r8d
shrl $0x3, %r14d
movl $0x8, %ebp
subl %r8d, %ebp
cmpl %ebx, %ebp
cmovael %ebx, %ebp
movq %r13, %rdi
movl %r14d, %esi
movq %r12, %rdx
movq %r15, %rcx
movl %ebp, %r9d
callq 0x5210
incl %r14d
addq %rbp, %r12
addq %rbp, %r15
xorl %r8d, %r8d
subl %ebp, %ebx
jne 0x665f
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x9a3a(%rip), %rdi      # 0x100e0
leaq 0x9a40(%rip), %rsi      # 0x100ed
leaq 0x9c27(%rip), %rcx      # 0x102db
movl $0x222, %edx            # imm = 0x222
callq 0x5190
leaq 0x9b01(%rip), %rdi      # 0x101c6
leaq 0x9a21(%rip), %rsi      # 0x100ed
leaq 0x9c08(%rip), %rcx      # 0x102db
movl $0x223, %edx            # imm = 0x223
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_DisplayRoundConstants
void KeccakP1600_DisplayRoundConstants(FILE *f)
{
    unsigned int i;

    for(i=0; i<maxNrRounds; i++) {
        fprintf(f, "RC[%02i][0][0] = ", i);
        fprintf(f, "%08X:%08X", (unsigned int)(KeccakRoundConstants[i][0]), (unsigned int)(KeccakRoundConstants[i][1]));
        fprintf(f, "\n");
    }
    fprintf(f, "\n");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
leaq 0x9c61(%rip), %r14      # 0x10351
leaq 0x9c99(%rip), %r13      # 0x10390
leaq 0x9c65(%rip), %r15      # 0x10363
xorl %r12d, %r12d
movq %rbx, %rdi
movq %r14, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x56e0
movl (%r13,%r12,8), %edx
movl 0x4(%r13,%r12,8), %ecx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x56e0
movl $0xa, %edi
movq %rbx, %rsi
callq 0x5360
incq %r12
cmpq $0x18, %r12
jne 0x6701
movl $0xa, %edi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x5360
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-1600-reference32BI.c
// Function: KeccakP1600_DisplayRhoOffsets
void KeccakP1600_DisplayRhoOffsets(FILE *f)
{
    unsigned int x, y;

    for(y=0; y<5; y++) for(x=0; x<5; x++) {
        fprintf(f, "RhoOffset[%i][%i] = ", x, y);
        fprintf(f, "%2i", KeccakRhoOffsets[5*y+x]);
        fprintf(f, "\n");
    }
    fprintf(f, "\n");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x9ce7(%rip), %rbp      # 0x10450
leaq 0x9bfd(%rip), %r14      # 0x1036d
leaq 0x9c0b(%rip), %r15      # 0x10382
xorl %r12d, %r12d
xorl %r13d, %r13d
movq %rbx, %rdi
movq %r14, %rsi
movl %r13d, %edx
movl %r12d, %ecx
xorl %eax, %eax
callq 0x56e0
movl (%rbp,%r13,4), %edx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x56e0
movl $0xa, %edi
movq %rbx, %rsi
callq 0x5360
incq %r13
cmpq $0x5, %r13
jne 0x677d
incq %r12
addq $0x14, %rbp
cmpq $0x5, %r12
jne 0x677a
movl $0xa, %edi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x5360
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-800-reference.c
// Function: KeccakP800_AddBytes
void KeccakP800_AddBytes(void *state, const unsigned char *data, unsigned int offset, unsigned int length)
{
    unsigned int i;

    assert(offset < 100);
    assert(offset+length <= 100);
    for(i=0; i<length; i++)
        ((unsigned char *)state)[offset+i] ^= data[i];
}

// Assembly:
pushq %rax
cmpl $0x64, %edx
jae 0x7adb
leal (%rcx,%rdx), %eax
cmpl $0x64, %eax
ja 0x7afa
testl %ecx, %ecx
je 0x7ad9
movl %ecx, %eax
movl %edx, %ecx
xorl %edx, %edx
movb (%rsi,%rdx), %r8b
leal (%rcx,%rdx), %r9d
xorb %r8b, (%rdi,%r9)
incq %rdx
cmpq %rdx, %rax
jne 0x7ac5
popq %rax
retq
leaq 0x9242(%rip), %rdi      # 0x10d24
leaq 0x9248(%rip), %rsi      # 0x10d31
leaq 0x92bf(%rip), %rcx      # 0x10daf
movl $0x98, %edx
callq 0x5190
leaq 0x9302(%rip), %rdi      # 0x10e03
leaq 0x9229(%rip), %rsi      # 0x10d31
leaq 0x92a0(%rip), %rcx      # 0x10daf
movl $0x99, %edx
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-800-reference.c
// Function: KeccakP800_ExtractAndAddBytes
void KeccakP800_ExtractAndAddBytes(const void *state, const unsigned char *input, unsigned char *output, unsigned int offset, unsigned int length)
{
    unsigned int i;

    assert(offset < 100);
    assert(offset+length <= 100);
    for(i=0; i<length; i++)
        output[i] = input[i] ^ ((unsigned char *)state)[offset+i];
}

// Assembly:
pushq %rax
cmpl $0x64, %ecx
jae 0x80bb
leal (%r8,%rcx), %eax
cmpl $0x64, %eax
ja 0x80da
testl %r8d, %r8d
je 0x80b9
movl %r8d, %eax
movl %ecx, %ecx
xorl %r8d, %r8d
leal (%rcx,%r8), %r9d
movb (%rdi,%r9), %r9b
xorb (%rsi,%r8), %r9b
movb %r9b, (%rdx,%r8)
incq %r8
cmpq %r8, %rax
jne 0x80a1
popq %rax
retq
leaq 0x8c62(%rip), %rdi      # 0x10d24
leaq 0x8c68(%rip), %rsi      # 0x10d31
leaq 0x8e45(%rip), %rcx      # 0x10f15
movl $0x16c, %edx            # imm = 0x16C
callq 0x5190
leaq 0x8d22(%rip), %rdi      # 0x10e03
leaq 0x8c49(%rip), %rsi      # 0x10d31
leaq 0x8e26(%rip), %rcx      # 0x10f15
movl $0x16d, %edx            # imm = 0x16D
callq 0x5190
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/KeccakP-800-reference.c
// Function: KeccakP800_DisplayRoundConstants
void KeccakP800_DisplayRoundConstants(FILE *f)
{
    unsigned int i;

    for(i=0; i<maxNrRounds; i++) {
        fprintf(f, "RC[%02i][0][0] = ", i);
        fprintf(f, "%08X", (unsigned int)(KeccakRoundConstants[i]));
        fprintf(f, "\n");
    }
    fprintf(f, "\n");
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdi, %rbx
leaq 0x8b44(%rip), %r13      # 0x10c50
leaq 0x823e(%rip), %r14      # 0x10351
leaq 0x824e(%rip), %r15      # 0x10368
xorl %r12d, %r12d
movq %rbx, %rdi
movq %r14, %rsi
movl %r12d, %edx
xorl %eax, %eax
callq 0x56e0
movl (%r13), %edx
movq %rbx, %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x56e0
movl $0xa, %edi
movq %rbx, %rsi
callq 0x5360
incq %r12
addq $0x4, %r13
cmpq $0x16, %r12
jne 0x811d
movl $0xa, %edi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
jmp 0x5360
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/displayIntermediateValues.c
// Function: displayBytes
void displayBytes(int level, const char *text, const unsigned char *bytes, unsigned int size)
{
    unsigned int i;

    if ((intermediateValueFile) && (level <= displayLevel)) {
        fprintf(intermediateValueFile, "%s:\n", text);
        for(i=0; i<size; i++)
            fprintf(intermediateValueFile, "%02X ", bytes[i]);
        fprintf(intermediateValueFile, "\n");
        fprintf(intermediateValueFile, "\n");
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %eax
movq 0x7353(%rip), %r15      # 0x15ff0
movq (%r15), %rdi
testq %rdi, %rdi
je 0xed19
movl %ecx, %ebp
movq 0x734a(%rip), %rcx      # 0x15ff8
cmpl %eax, (%rcx)
jl 0xed19
movq %rdx, %rbx
movq %rsi, %rdx
leaq 0x22cb(%rip), %rsi      # 0x10f8a
xorl %eax, %eax
callq 0x56e0
testl %ebp, %ebp
je 0xecf1
movl %ebp, %r12d
leaq 0x22bb(%rip), %r14      # 0x10f8f
xorl %r13d, %r13d
movq (%r15), %rdi
movzbl (%rbx,%r13), %edx
movq %r14, %rsi
xorl %eax, %eax
callq 0x56e0
incq %r13
cmpq %r13, %r12
jne 0xecd7
movq (%r15), %rsi
movl $0xa, %edi
callq 0x5360
movq (%r15), %rsi
movl $0xa, %edi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x5360
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/displayIntermediateValues.c
// Function: displayBits
void displayBits(int level, const char *text, const unsigned char *data, unsigned int size, int MSBfirst)
{
    unsigned int i, iByte, iBit;

    if ((intermediateValueFile) && (level <= displayLevel)) {
        fprintf(intermediateValueFile, "%s:\n", text);
        for(i=0; i<size; i++) {
            iByte = i/8;
            iBit = i%8;
            if (MSBfirst)
                fprintf(intermediateValueFile, "%d ", ((data[iByte] << iBit) & 0x80) != 0);
            else
                fprintf(intermediateValueFile, "%d ", ((data[iByte] >> iBit) & 0x01) != 0);
        }
        fprintf(intermediateValueFile, "\n");
        fprintf(intermediateValueFile, "\n");
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %eax
movq 0x72b4(%rip), %r12      # 0x15ff0
movq (%r12), %rdi
testq %rdi, %rdi
je 0xede9
movl %ecx, %ebp
movq 0x72a6(%rip), %rcx      # 0x15ff8
cmpl %eax, (%rcx)
jl 0xede9
movl %r8d, %ebx
movq %rdx, %r14
movq %rsi, %rdx
leaq 0x2220(%rip), %rsi      # 0x10f8a
xorl %eax, %eax
callq 0x56e0
testl %ebp, %ebp
je 0xedbf
leaq 0x2219(%rip), %r15      # 0x10f95
xorl %r13d, %r13d
movl %r13d, %ecx
shrl $0x3, %ecx
movl %r13d, %eax
andl $0x7, %eax
movzbl (%r14,%rcx), %ecx
testl %ebx, %ebx
je 0xeda1
shlxl %eax, %ecx, %eax
shrb $0x7, %al
movzbl %al, %edx
jmp 0xeda9
shrxl %eax, %ecx, %edx
andl $0x1, %edx
movq (%r12), %rdi
movq %r15, %rsi
xorl %eax, %eax
callq 0x56e0
incl %r13d
cmpl %r13d, %ebp
jne 0xed7f
movq (%r12), %rsi
movl $0xa, %edi
callq 0x5360
movq (%r12), %rsi
movl $0xa, %edi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x5360
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/displayIntermediateValues.c
// Function: displayStateAs32bitWords
void displayStateAs32bitWords(int level, const char *text, const unsigned int *state)
{
    unsigned int i;

    if ((intermediateValueFile) && (level <= displayLevel)) {
        fprintf(intermediateValueFile, "%s:\n", text);
        for(i=0; i<25; i++) {
            fprintf(intermediateValueFile, "%08X:%08X", (unsigned int)state[2*i+0], (unsigned int)state[2*i+1]);
            if ((i%5) == 4)
                fprintf(intermediateValueFile, "\n");
            else
                fprintf(intermediateValueFile, " ");
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %eax
movq 0x71dc(%rip), %r15      # 0x15ff0
movq (%r15), %rdi
testq %rdi, %rdi
je 0xee96
movq 0x71d5(%rip), %rcx      # 0x15ff8
cmpl %eax, (%rcx)
jl 0xee96
movq %rdx, %rbx
movq %rsi, %rdx
leaq 0x2156(%rip), %rsi      # 0x10f8a
xorl %eax, %eax
callq 0x56e0
movl $0x4, %ebp
movl $0xa, %r13d
xorl %r12d, %r12d
movl %r12d, %eax
movl $0xcccccccd, %ecx       # imm = 0xCCCCCCCD
imulq %rcx, %rax
shrq $0x22, %rax
leal (%rax,%rax,4), %r14d
movq (%r15), %rdi
movl (%rbx,%r12,8), %edx
movl 0x4(%rbx,%r12,8), %ecx
leaq 0x14f3(%rip), %rsi      # 0x10363
xorl %eax, %eax
callq 0x56e0
addl %ebp, %r14d
movq (%r15), %rsi
movl $0x20, %edi
cmovel %r13d, %edi
callq 0x5360
incq %r12
decl %ebp
cmpq $0x19, %r12
jne 0xee49
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/displayIntermediateValues.c
// Function: displayStateAs64bitLanes
void displayStateAs64bitLanes(int level, const char *text, void *statePointer)
{
    unsigned int i;
    unsigned long long int *state = statePointer;

    if ((intermediateValueFile) && (level <= displayLevel)) {
        fprintf(intermediateValueFile, "%s:\n", text);
        for(i=0; i<25; i++) {
            fprintf(intermediateValueFile, "%08X", (unsigned int)(state[i] >> 32));
            fprintf(intermediateValueFile, "%08X", (unsigned int)(state[i] & 0xFFFFFFFFULL));
            if ((i%5) == 4)
                fprintf(intermediateValueFile, "\n");
            else
                fprintf(intermediateValueFile, " ");
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %eax
movq 0x7137(%rip), %r15      # 0x15ff0
movq (%r15), %rdi
testq %rdi, %rdi
je 0xef4d
movq 0x712c(%rip), %rcx      # 0x15ff8
cmpl %eax, (%rcx)
jl 0xef4d
movq %rdx, %rbx
movq %rsi, %rdx
leaq 0x20ad(%rip), %rsi      # 0x10f8a
xorl %eax, %eax
callq 0x56e0
movl $0x4, %ebp
leaq 0x1478(%rip), %r14      # 0x10368
xorl %r12d, %r12d
movl %r12d, %eax
movl $0xcccccccd, %ecx       # imm = 0xCCCCCCCD
imulq %rcx, %rax
shrq $0x22, %rax
leal (%rax,%rax,4), %r13d
movq (%r15), %rdi
movl 0x4(%rbx,%r12,8), %edx
movq %r14, %rsi
xorl %eax, %eax
callq 0x56e0
movq (%r15), %rdi
movl (%rbx,%r12,8), %edx
movq %r14, %rsi
xorl %eax, %eax
callq 0x56e0
addl %ebp, %r13d
movq (%r15), %rsi
movl $0x20, %edi
movl $0xa, %eax
cmovel %eax, %edi
callq 0x5360
incq %r12
decl %ebp
cmpq $0x19, %r12
jne 0xeef3
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/displayIntermediateValues.c
// Function: displayStateAs32bitLanes
void displayStateAs32bitLanes(int level, const char *text, void *statePointer)
{
    unsigned int i;
    unsigned int *state = statePointer;

    if ((intermediateValueFile) && (level <= displayLevel)) {
        fprintf(intermediateValueFile, "%s:\n", text);
        for(i=0; i<25; i++) {
            fprintf(intermediateValueFile, "%08X", state[i]);
            if ((i%5) == 4)
                fprintf(intermediateValueFile, "\n");
            else
                fprintf(intermediateValueFile, " ");
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %eax
movq 0x7080(%rip), %r15      # 0x15ff0
movq (%r15), %rdi
testq %rdi, %rdi
je 0xefed
movq 0x7079(%rip), %rcx      # 0x15ff8
cmpl %eax, (%rcx)
jl 0xefed
movq %rdx, %rbx
movq %rsi, %rdx
leaq 0x1ffa(%rip), %rsi      # 0x10f8a
xorl %eax, %eax
callq 0x56e0
movl $0x4, %ebp
movl $0xa, %r13d
xorl %r12d, %r12d
movl %r12d, %eax
movl $0xcccccccd, %ecx       # imm = 0xCCCCCCCD
imulq %rcx, %rax
shrq $0x22, %rax
leal (%rax,%rax,4), %r14d
movq (%r15), %rdi
movl (%rbx,%r12,4), %edx
leaq 0x13a1(%rip), %rsi      # 0x10368
xorl %eax, %eax
callq 0x56e0
addl %ebp, %r14d
movq (%r15), %rsi
movl $0x20, %edi
cmovel %r13d, %edi
callq 0x5360
incq %r12
decl %ebp
cmpq $0x19, %r12
jne 0xefa5
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mjosaarinen[P]brutus/crypto_aead/lunarkeyakv2/reference32bits/displayIntermediateValues.c
// Function: displayStateAs16bitLanes
void displayStateAs16bitLanes(int level, const char *text, void *statePointer)
{
    unsigned int i;
    unsigned short *state = statePointer;

    if ((intermediateValueFile) && (level <= displayLevel)) {
        fprintf(intermediateValueFile, "%s:\n", text);
        for(i=0; i<25; i++) {
            fprintf(intermediateValueFile, "%04X ", state[i]);
            if ((i%5) == 4)
                fprintf(intermediateValueFile, "\n");
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %eax
movq 0x6fe0(%rip), %r15      # 0x15ff0
movq (%r15), %rdi
testq %rdi, %rdi
je 0xf089
movq 0x6fd9(%rip), %rcx      # 0x15ff8
cmpl %eax, (%rcx)
jl 0xf089
movq %rdx, %rbx
movq %rsi, %rdx
leaq 0x1f5a(%rip), %rsi      # 0x10f8a
xorl %eax, %eax
callq 0x56e0
movl $0x4, %ebp
leaq 0x1f56(%rip), %r14      # 0x10f99
xorl %r13d, %r13d
movl %r13d, %eax
movl $0xcccccccd, %ecx       # imm = 0xCCCCCCCD
imulq %rcx, %rax
shrq $0x22, %rax
leal (%rax,%rax,4), %r12d
movq (%r15), %rdi
movzwl (%rbx,%r13,2), %edx
movq %r14, %rsi
xorl %eax, %eax
callq 0x56e0
addl %ebp, %r12d
jne 0xf07e
movq (%r15), %rsi
movl $0xa, %edi
callq 0x5360
incq %r13
decl %ebp
cmpq $0x19, %r13
jne 0xf046
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq