LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/./permutation.h
// Function: rng_init
static inline void rng_init(unsigned thread_num) {
  rng_buf = (char *)calloc(1, RNG_BUF_SIZE);
  rand_state = (struct random_data *)calloc(1, sizeof(struct random_data));
  assert(rand_state);
  if (initstate_r(thread_num, rng_buf, RNG_BUF_SIZE, rand_state) != 0) {
    perror("initstate_r");
    exit(1);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x4(%rbp)
movl $0x1, %edi
movl $0x20, %esi
callq 0x43e780
movq %rax, %rcx
movq $-0x60, %rdx
movq %fs:0x0, %rax
addq %rdx, %rax
movq %rcx, (%rax)
movl $0x1, %edi
movl $0x30, %esi
callq 0x43e780
movq %rax, %rcx
movq $-0x58, %rdx
movq %fs:0x0, %rax
addq %rdx, %rax
movq %rcx, (%rax)
movq $-0x58, %rcx
movq %fs:0x0, %rax
addq %rcx, %rax
cmpq $0x0, (%rax)
je 0x402f36
jmp 0x402f55
leaq 0xd709d(%rip), %rdi     # 0x4d9fda
leaq 0xd70a1(%rip), %rsi     # 0x4d9fe5
movl $0x5d, %edx
leaq 0xd70a5(%rip), %rcx     # 0x4d9ff5
callq 0x413d50
movl -0x4(%rbp), %edi
movq $-0x60, %rcx
movq %fs:0x0, %rax
addq %rcx, %rax
movq (%rax), %rsi
movq $-0x58, %rcx
movq %fs:0x0, %rax
addq %rcx, %rax
movq (%rax), %rcx
movl $0x20, %edx
callq 0x41a840
cmpl $0x0, %eax
je 0x402fa9
leaq 0xd7077(%rip), %rdi     # 0x4da011
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
addq $0x10, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/multichase.c
// Function: timestamp
static void timestamp(void) {
  if (!print_timestamp) return;
  struct timeval tv;
  gettimeofday(&tv, NULL);
  printf("%.6f ", tv.tv_sec + tv.tv_usec / 1000000.);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
cmpl $0x0, 0x10edc1(%rip)    # 0x5123a0
jne 0x4035e3
jmp 0x40361a
leaq -0x10(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x46c610
cvtsi2sdq -0x10(%rbp), %xmm0
cvtsi2sdq -0x8(%rbp), %xmm1
movsd 0xd5a1c(%rip), %xmm2    # 0x4d9020
divsd %xmm2, %xmm1
addsd %xmm1, %xmm0
leaq 0xd6a57(%rip), %rdi     # 0x4da06a
movb $0x1, %al
callq 0x41b480
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/multichase.c
// Function: chase_branch
static void chase_branch(per_thread_t *t) {
  void *p = t->x.cycle[0];
  typedef void* (*fptr)(void);
  fptr fp = p;

  do {
    fp = (fptr)(fp)();
  } while (__sync_add_and_fetch(&t->x.count, t->x.branch_chunk_size));

  // we never actually reach here, but the compiler doesn't know that
  t->x.dummy = (uintptr_t)p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x18(%rbp)
callq *-0x18(%rbp)
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rdx
movl 0x94(%rdx), %ecx
movl %ecx, %eax
lock
xaddl %eax, 0x4(%rdx)
addl %ecx, %eax
cmpl $0x0, %eax
jne 0x404b10
movq -0x10(%rbp), %rax
movl %eax, %ecx
movq -0x8(%rbp), %rax
movl %ecx, 0x60(%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/permutation.c
// Function: gen_random_permutation
void gen_random_permutation(perm_t *perm, size_t nr, size_t base) {
  size_t i;

  for (i = 0; i < nr; ++i) {
    size_t t = rng_int(i);
    perm[i] = perm[t];
    perm[t] = base + i;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x10(%rbp), %rax
jae 0x40eded
movq -0x20(%rbp), %rdi
callq 0x40ee00
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq -0x28(%rbp), %rcx
movq (%rax,%rcx,8), %rdx
movq -0x8(%rbp), %rax
movq -0x20(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq -0x18(%rbp), %rdx
addq -0x20(%rbp), %rdx
movq -0x8(%rbp), %rax
movq -0x28(%rbp), %rcx
movq %rdx, (%rax,%rcx,8)
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x40ed9c
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/./permutation.h
// Function: rng_int
static inline perm_t rng_int(perm_t limit) {
  int r1, r2, r3, r4;
  uint64_t r;

  if (random_r(rand_state, &r1) || random_r(rand_state, &r2)
    || random_r(rand_state, &r3) || random_r(rand_state, &r4)) {
    perror("random_r");
    exit(1);
  }
  // Assume that RAND_MAX is at least 16-bit long
  _Static_assert (RAND_MAX >= (1ul << 16), "RAND_MAX is too small");
  r = (((uint64_t)r1 <<  0) & 0x000000000000FFFFull) |
      (((uint64_t)r2 << 16) & 0x00000000FFFF0000ull) |
      (((uint64_t)r3 << 32) & 0x0000FFFF00000000ull) |
      (((uint64_t)r4 << 48) & 0xFFFF000000000000ull);

  return r % (limit + 1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %fs:0x0, %rax
leaq -0x58(%rax), %rax
movq (%rax), %rdi
leaq -0xc(%rbp), %rsi
callq 0x41aae0
cmpl $0x0, %eax
jne 0x40ee90
movq %fs:0x0, %rax
leaq -0x58(%rax), %rax
movq (%rax), %rdi
leaq -0x10(%rbp), %rsi
callq 0x41aae0
cmpl $0x0, %eax
jne 0x40ee90
movq %fs:0x0, %rax
leaq -0x58(%rax), %rax
movq (%rax), %rdi
leaq -0x14(%rbp), %rsi
callq 0x41aae0
cmpl $0x0, %eax
jne 0x40ee90
movq %fs:0x0, %rax
leaq -0x58(%rax), %rax
movq (%rax), %rdi
leaq -0x18(%rbp), %rsi
callq 0x41aae0
cmpl $0x0, %eax
je 0x40eea6
leaq 0xcb391(%rip), %rdi     # 0x4da228
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
movslq -0xc(%rbp), %rax
shlq $0x0, %rax
andq $0xffff, %rax           # imm = 0xFFFF
movslq -0x10(%rbp), %rcx
shlq $0x10, %rcx
movabsq $0xffff0000, %rdx       # imm = 0xFFFF0000
andq %rdx, %rcx
orq %rcx, %rax
movslq -0x14(%rbp), %rcx
shlq $0x20, %rcx
movabsq $0xffff00000000, %rdx   # imm = 0xFFFF00000000
andq %rdx, %rcx
orq %rcx, %rax
movslq -0x18(%rbp), %rcx
shlq $0x30, %rcx
movabsq $-0x1000000000000, %rdx # imm = 0xFFFF000000000000
andq %rdx, %rcx
orq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq -0x8(%rbp), %rcx
addq $0x1, %rcx
xorl %edx, %edx
divq %rcx
movq %rdx, %rax
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/permutation.c
// Function: is_a_permutation
int is_a_permutation(const perm_t *perm, size_t nr_elts) {
  uint8_t *vec;
  size_t vec_len = (nr_elts + 7) / 8;
  size_t i;

  vec = malloc(vec_len);
  memset(vec, 0, vec_len);

  for (i = 0; i < nr_elts; ++i) {
    size_t vec_elt = perm[i] / 8;
    size_t test_bit = 1u << (perm[i] % 8);
    if (vec[vec_elt] & test_bit) {
      free(vec);
      return 0;
    }
    vec[vec_elt] |= test_bit;
  }
  for (i = 0; i < nr_elts / 8; ++i) {
    if (vec[i] != 0xff) {
      free(vec);
      return 0;
    }
  }
  if (nr_elts % 8) {
    if (vec[vec_len - 1] != ((1u << (nr_elts % 8)) - 1)) {
      free(vec);
      return 0;
    }
  }
  free(vec);
  return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x18(%rbp), %rax
addq $0x7, %rax
shrq $0x3, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
callq 0x43d330
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
movq -0x28(%rbp), %rdx
xorl %esi, %esi
callq 0x4010a8
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpq -0x18(%rbp), %rax
jae 0x40f047
movq -0x10(%rbp), %rax
movq -0x30(%rbp), %rcx
movq (%rax,%rcx,8), %rax
shrq $0x3, %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq -0x30(%rbp), %rcx
movq (%rax,%rcx,8), %rax
andq $0x7, %rax
movl %eax, %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, %eax
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rax
movq -0x38(%rbp), %rcx
movzbl (%rax,%rcx), %eax
andq -0x40(%rbp), %rax
cmpq $0x0, %rax
je 0x40f020
movq -0x20(%rbp), %rdi
callq 0x43d670
movl $0x0, -0x4(%rbp)
jmp 0x40f0ef
movq -0x40(%rbp), %rsi
movq -0x20(%rbp), %rax
movq -0x38(%rbp), %rcx
movzbl (%rax,%rcx), %edx
orq %rsi, %rdx
movb %dl, (%rax,%rcx)
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x40efb4
movq $0x0, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq -0x18(%rbp), %rcx
shrq $0x3, %rcx
cmpq %rcx, %rax
jae 0x40f095
movq -0x20(%rbp), %rax
movq -0x30(%rbp), %rcx
movzbl (%rax,%rcx), %eax
cmpl $0xff, %eax
je 0x40f085
movq -0x20(%rbp), %rdi
callq 0x43d670
movl $0x0, -0x4(%rbp)
jmp 0x40f0ef
jmp 0x40f087
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x40f04f
movq -0x18(%rbp), %rax
andq $0x7, %rax
cmpq $0x0, %rax
je 0x40f0df
movq -0x20(%rbp), %rax
movq -0x28(%rbp), %rcx
subq $0x1, %rcx
movzbl (%rax,%rcx), %eax
movq -0x18(%rbp), %rcx
andq $0x7, %rcx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
je 0x40f0dd
movq -0x20(%rbp), %rdi
callq 0x43d670
movl $0x0, -0x4(%rbp)
jmp 0x40f0ef
jmp 0x40f0df
movq -0x20(%rbp), %rdi
callq 0x43d670
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: get_native_page_size
size_t get_native_page_size(void) {
  long sz;

  sz = sysconf(_SC_PAGESIZE);
  if (sz < 0) {
    perror("failed to get native page size");
    exit(1);
  }

  return (size_t)sz;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl $0x1e, %edi
callq 0x46c8c0
movq %rax, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
jge 0x40fe83
leaq 0xca3bd(%rip), %rdi     # 0x4da231
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
movq -0x8(%rbp), %rax
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: print_page_size
void print_page_size(size_t page_size, bool use_thp) {
  FILE *f;
  size_t read;
  /* Big enough to fit UINT64_MAX + '\n' + '\0'. */
  char buf[22];

  if (!use_thp) {
    printf("page_size = %zu bytes\n", page_size);
    return;
  }

  f = fopen("/sys/kernel/mm/transparent_hugepage/hpage_pmd_size", "r");
  if (!f) goto err;

  read = fread(buf, 1, sizeof(buf) - 1, f);
  if (!feof(f) || (ferror(f) && !feof(f))) goto err;

  if (fclose(f)) goto err;

  if (buf[read - 1] == '\n') --read;
  buf[read] = '\0';

  printf("page_size = %s bytes (THP)\n", buf);
  return;

err:
  perror(
      "page_size = <failed to read "
      "/sys/kernel/mm/transparent_hugepage/hpage_pmd_size>");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movb %sil, %al
movq %rdi, -0x8(%rbp)
andb $0x1, %al
movb %al, -0x9(%rbp)
testb $0x1, -0x9(%rbp)
jne 0x40fef1
movq -0x8(%rbp), %rsi
leaq 0xca36b(%rip), %rdi     # 0x4da250
movb $0x0, %al
callq 0x41b480
jmp 0x40ffb2
leaq 0xca36f(%rip), %rdi     # 0x4da267
leaq 0xca11c(%rip), %rsi     # 0x4da01b
callq 0x42a230
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x40ff14
jmp 0x40ffa6
leaq -0x40(%rbp), %rdi
movq -0x18(%rbp), %rcx
movl $0x1, %esi
movl $0x15, %edx
callq 0x42a330
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rdi
callq 0x42c6c0
cmpl $0x0, %eax
je 0x40ff59
movq -0x18(%rbp), %rdi
callq 0x42c790
cmpl $0x0, %eax
je 0x40ff5b
movq -0x18(%rbp), %rdi
callq 0x42c6c0
cmpl $0x0, %eax
jne 0x40ff5b
jmp 0x40ffa6
movq -0x18(%rbp), %rdi
callq 0x429b00
cmpl $0x0, %eax
je 0x40ff6b
jmp 0x40ffa6
movq -0x20(%rbp), %rax
subq $0x1, %rax
movsbl -0x40(%rbp,%rax), %eax
cmpl $0xa, %eax
jne 0x40ff89
movq -0x20(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movb $0x0, -0x40(%rbp,%rax)
leaq -0x40(%rbp), %rsi
leaq 0xca2fd(%rip), %rdi     # 0x4da29a
movb $0x0, %al
callq 0x41b480
jmp 0x40ffb2
leaq 0xca309(%rip), %rdi     # 0x4da2b6
callq 0x41b6b0
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: alloc_arena_mmap
void *alloc_arena_mmap(size_t page_size, bool use_thp, size_t arena_size, int fd) {
  void *arena;
  size_t pagemask = page_size - 1;
  int flags;

  if (fd == -1)
    flags = MAP_PRIVATE | MAP_ANONYMOUS | get_page_size_flags(page_size);
  else
    flags = MAP_SHARED;

  arena_size = (arena_size + pagemask) & ~pagemask;
  arena = mmap(0, arena_size, PROT_READ | PROT_WRITE, flags, fd, 0);
  if (arena == MAP_FAILED) {
    perror("mmap");
    exit(1);
  }

  if (use_thp && fd == -1)
    check_thp_state();

  /* Explicitly disable THP for small pages. */
  if (!page_size_is_huge(page_size) && fd == -1) {
    if (madvise(arena, arena_size, use_thp ? MADV_HUGEPAGE : MADV_NOHUGEPAGE)) {
      perror("madvise");
    }
  } else if (use_thp) {
    fprintf(stderr,
            "Can't use transparent hugepages with a non-native page size.\n");
    exit(1);
  }

  if (is_weighted_mbind) {
    arena_weighted_mbind(page_size, arena, arena_size, mbind_weights,
                         MAX_MEM_NODES);
  }
  return arena;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movb %sil, %al
movq %rdi, -0x8(%rbp)
andb $0x1, %al
movb %al, -0x9(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movq -0x8(%rbp), %rax
subq $0x1, %rax
movq %rax, -0x30(%rbp)
cmpl $-0x1, -0x1c(%rbp)
jne 0x40fffe
movq -0x8(%rbp), %rdi
callq 0x410120
orl $0x22, %eax
movl %eax, -0x34(%rbp)
jmp 0x410005
movl $0x1, -0x34(%rbp)
movq -0x18(%rbp), %rax
addq -0x30(%rbp), %rax
movq -0x30(%rbp), %rcx
xorq $-0x1, %rcx
andq %rcx, %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rsi
movl -0x34(%rbp), %ecx
movl -0x1c(%rbp), %r8d
xorl %eax, %eax
movl %eax, %r9d
movl $0x3, %edx
movq %r9, %rdi
callq 0x46f240
movq %rax, -0x28(%rbp)
movq $-0x1, %rax
cmpq %rax, -0x28(%rbp)
jne 0x410060
leaq 0xca2b5(%rip), %rdi     # 0x4da306
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
testb $0x1, -0x9(%rbp)
je 0x410071
cmpl $-0x1, -0x1c(%rbp)
jne 0x410071
callq 0x4101c0
movq -0x8(%rbp), %rdi
callq 0x40fe90
testb $0x1, %al
jne 0x4100b7
cmpl $-0x1, -0x1c(%rbp)
jne 0x4100b7
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rsi
movb -0x9(%rbp), %cl
movl $0xf, %edx
movl $0xe, %eax
testb $0x1, %cl
cmovnel %eax, %edx
callq 0x46f300
cmpl $0x0, %eax
je 0x4100b5
leaq 0xca25b(%rip), %rdi     # 0x4da30b
callq 0x41b6b0
jmp 0x4100e1
testb $0x1, -0x9(%rbp)
je 0x4100df
movq $0x510708, %rax         # imm = 0x510708
movq (%rax), %rdi
leaq 0xca245(%rip), %rsi     # 0x4da313
movb $0x0, %al
callq 0x41b3c0
movl $0x1, %edi
callq 0x41a3f0
jmp 0x4100e1
movq $0x512314, %rax         # imm = 0x512314
cmpl $0x0, (%rax)
je 0x41010b
movq -0x8(%rbp), %rdi
movq -0x28(%rbp), %rsi
movq -0x18(%rbp), %rdx
movq $0x512320, %rcx         # imm = 0x512320
movl $0x40, %r8d
callq 0x410290
movq -0x28(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: get_page_size_flags
static int get_page_size_flags(size_t page_size) {
  int lg = 0;

  if (!page_size || (page_size & (page_size - 1))) {
    fprintf(stderr, "page size must be a power of 2: %zu\n", page_size);
    exit(1);
  }

  if (!page_size_is_huge(page_size)) {
    return 0;
  }

  /*
   * We need not just MAP_HUGETLB, but also a flag specifying the page size.
   * mmap(2) says that these flags are defined as:
   * log2(page size) << MAP_HUGE_SHIFT.
   */
  while (page_size >>= 1) {
    ++lg;
  }
  return MAP_HUGETLB | (lg << MAP_HUGE_SHIFT);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movl $0x0, -0x14(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x41014f
movq -0x10(%rbp), %rax
movq -0x10(%rbp), %rcx
subq $0x1, %rcx
andq %rcx, %rax
cmpq $0x0, %rax
je 0x410175
movq $0x510708, %rax         # imm = 0x510708
movq (%rax), %rdi
movq -0x10(%rbp), %rdx
leaq 0xca201(%rip), %rsi     # 0x4da365
movb $0x0, %al
callq 0x41b3c0
movl $0x1, %edi
callq 0x41a3f0
movq -0x10(%rbp), %rdi
callq 0x40fe90
testb $0x1, %al
jne 0x41018b
movl $0x0, -0x4(%rbp)
jmp 0x4101b7
jmp 0x41018d
movq -0x10(%rbp), %rax
shrq %rax
movq %rax, -0x10(%rbp)
cmpq $0x0, %rax
je 0x4101a9
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x41018d
movl -0x14(%rbp), %eax
shll $0x1a, %eax
orl $0x40000, %eax          # imm = 0x40000
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: check_thp_state
static void check_thp_state(void) {
  char *enabled =
      read_sysfs_state_file("/sys/kernel/mm/transparent_hugepage/enabled");
  char *defrag =
      read_sysfs_state_file("/sys/kernel/mm/transparent_hugepage/defrag");

  if (strcmp(enabled, "[always]") && strcmp(enabled, "[madvise]")) {
    write_sysfs_file("/sys/kernel/mm/transparent_hugepage/enabled", "madvise");
  }

  if (strcmp(defrag, "[always]") && strcmp(defrag, "[defer+madvise]") &&
      strcmp(defrag, "[madvise]")) {
    write_sysfs_file("/sys/kernel/mm/transparent_hugepage/defrag", "madvise");
  }

  free(enabled);
  free(defrag);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
leaq 0xca1bb(%rip), %rdi     # 0x4da38a
callq 0x4104a0
movq %rax, -0x8(%rbp)
leaq 0xca1d7(%rip), %rdi     # 0x4da3b6
callq 0x4104a0
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rdi
leaq 0xca1ee(%rip), %rsi     # 0x4da3e1
callq 0x4010b8
cmpl $0x0, %eax
je 0x410225
movq -0x8(%rbp), %rdi
leaq 0xca1e2(%rip), %rsi     # 0x4da3ea
callq 0x4010b8
cmpl $0x0, %eax
je 0x410225
leaq 0xca171(%rip), %rdi     # 0x4da38a
leaq 0xca0eb(%rip), %rsi     # 0x4da30b
callq 0x410590
movq -0x10(%rbp), %rdi
leaq 0xca1b1(%rip), %rsi     # 0x4da3e1
callq 0x4010b8
cmpl $0x0, %eax
je 0x410277
movq -0x10(%rbp), %rdi
leaq 0xca1af(%rip), %rsi     # 0x4da3f4
callq 0x4010b8
cmpl $0x0, %eax
je 0x410277
movq -0x10(%rbp), %rdi
leaq 0xca190(%rip), %rsi     # 0x4da3ea
callq 0x4010b8
cmpl $0x0, %eax
je 0x410277
leaq 0xca14b(%rip), %rdi     # 0x4da3b6
leaq 0xca099(%rip), %rsi     # 0x4da30b
callq 0x410590
movq -0x8(%rbp), %rdi
callq 0x43d670
movq -0x10(%rbp), %rdi
callq 0x43d670
addq $0x10, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: read_sysfs_state_file
static char *read_sysfs_state_file(char const *path) {
  FILE *f = fopen(path, "r");
  char *token = NULL;
  int ret;

  if (f == NULL) {
    perror("open sysfs state file");
    exit(1);
  }

  while ((ret = fscanf(f, "%ms", &token)) == 1) {
    if (token[0] == '[') break;

    free(token);
    token = NULL;
  }

  if (ferror(f) && !feof(f)) {
    perror("read sysfs state file");
    exit(1);
  }

  if (fclose(f)) {
    perror("close sysfs state file");
    exit(1);
  }

  return token;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
leaq 0xc9b64(%rip), %rsi     # 0x4da01b
callq 0x42a230
movq %rax, -0x10(%rbp)
movq $0x0, -0x18(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x4104e5
leaq 0xc9f2e(%rip), %rdi     # 0x4da404
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
jmp 0x4104e7
movq -0x10(%rbp), %rdi
leaq 0xc9f28(%rip), %rsi     # 0x4da41a
leaq -0x18(%rbp), %rdx
movb $0x0, %al
callq 0x41b770
movl %eax, -0x1c(%rbp)
cmpl $0x1, %eax
jne 0x410526
movq -0x18(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x5b, %eax
jne 0x410513
jmp 0x410526
movq -0x18(%rbp), %rdi
callq 0x43d670
movq $0x0, -0x18(%rbp)
jmp 0x4104e7
movq -0x10(%rbp), %rdi
callq 0x42c790
cmpl $0x0, %eax
je 0x410558
movq -0x10(%rbp), %rdi
callq 0x42c6c0
cmpl $0x0, %eax
jne 0x410558
leaq 0xc9ed5(%rip), %rdi     # 0x4da41e
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
movq -0x10(%rbp), %rdi
callq 0x429b00
cmpl $0x0, %eax
je 0x41057c
leaq 0xc9ec7(%rip), %rdi     # 0x4da434
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
movq -0x18(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/arena.c
// Function: write_sysfs_file
static void write_sysfs_file(char const *path, char const *value) {
  FILE *f = fopen(path, "w");

  if (f == NULL) {
    perror("open sysfs file for write");
    exit(1);
  }

  if (fprintf(f, "%s\n", value) < 0) {
    perror("write value to sysfs file");
    exit(1);
  }

  if (fclose(f)) {
    perror("close sysfs file");
    exit(1);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
leaq 0xc9ea0(%rip), %rsi     # 0x4da44b
callq 0x42a230
movq %rax, -0x18(%rbp)
cmpq $0x0, -0x18(%rbp)
jne 0x4105d1
leaq 0xc9e8b(%rip), %rdi     # 0x4da44d
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rdx
leaq 0xc8bda(%rip), %rsi     # 0x4d91ba
movb $0x0, %al
callq 0x41b3c0
cmpl $0x0, %eax
jge 0x410602
leaq 0xc9e74(%rip), %rdi     # 0x4da467
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
movq -0x18(%rbp), %rdi
callq 0x429b00
cmpl $0x0, %eax
je 0x410626
leaq 0xc9e6a(%rip), %rdi     # 0x4da481
callq 0x41b6b0
movl $0x1, %edi
callq 0x41a3f0
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/br_asm.c
// Function: cycle_len
static int cycle_len(void *p) {
  int count = 0;
  char *next = (char *)p;
  do {
    ++count;
    next = *(char **)next;
  } while (next != p);
  return count;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
cmpq -0x8(%rbp), %rax
jne 0x410a27
movl -0xc(%rbp), %eax
popq %rbp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/br_asm.c
// Function: x64_emit_mov_imm64_rax
static char *x64_emit_mov_imm64_rax(char *p, uint64_t imm64) {
  *p++ = 0x48;  // movabs
  *p++ = 0xb8;
  for (int i = 0; i < 8; i++)
    *p++ = imm64 >> (8 * i);  // immediate value (8 bytes)
  return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x8(%rbp)
movb $0x48, (%rax)
movq -0x8(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x8(%rbp)
movb $-0x48, (%rax)
movl $0x0, -0x14(%rbp)
cmpl $0x8, -0x14(%rbp)
jge 0x410aba
movq -0x10(%rbp), %rax
movl -0x14(%rbp), %ecx
shll $0x3, %ecx
movl %ecx, %ecx
shrq %cl, %rax
movb %al, %cl
movq -0x8(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x8(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x410a87
movq -0x8(%rbp), %rax
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/google[P]multichase/util.c
// Function: parse_mem_arg
int parse_mem_arg(const char *str, size_t *result) {
  size_t r;
  char *p;

  r = strtoull(str, &p, 0);
  switch (*p) {
    case 'k':
    case 'K':
      r *= 1024;
      ++p;
      break;
    case 'm':
    case 'M':
      r *= 1024 * 1024;
      ++p;
      break;
    case 'g':
    case 'G':
      r *= 1024 * 1024 * 1024;
      ++p;
      break;
  }
  if (*p) {
    return -1;
  }
  *result = r;
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
leaq -0x28(%rbp), %rsi
xorl %edx, %edx
callq 0x41aba0
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
movsbl (%rax), %eax
movl %eax, -0x2c(%rbp)
subl $0x47, %eax
je 0x410bba
jmp 0x410b54
movl -0x2c(%rbp), %eax
subl $0x4b, %eax
je 0x410b86
jmp 0x410b5e
movl -0x2c(%rbp), %eax
subl $0x4d, %eax
je 0x410ba0
jmp 0x410b68
movl -0x2c(%rbp), %eax
subl $0x67, %eax
je 0x410bba
jmp 0x410b72
movl -0x2c(%rbp), %eax
subl $0x6b, %eax
je 0x410b86
jmp 0x410b7c
movl -0x2c(%rbp), %eax
subl $0x6d, %eax
je 0x410ba0
jmp 0x410bd2
movq -0x20(%rbp), %rax
shlq $0xa, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x410bd2
movq -0x20(%rbp), %rax
shlq $0x14, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x410bd2
movq -0x20(%rbp), %rax
shlq $0x1e, %rax
movq %rax, -0x20(%rbp)
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
cmpb $0x0, (%rax)
je 0x410be4
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x410bf6
movq -0x20(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, (%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: chacha_keysetup
void chacha_keysetup(chacha_ctx_t *x, const unsigned char *k, unsigned kbits)
{
  const char *constants;

  x->input[4] = read32le((uint32_t *)(k + 0));
  x->input[5] = read32le((uint32_t *)(k + 4));
  x->input[6] = read32le((uint32_t *)(k + 8));
  x->input[7] = read32le((uint32_t *)(k + 12));
  if (kbits == 256) { /* recommended */
    k += 16;
    constants = sigma;
  } else { /* kbits == 128 */
    constants = tau;
  }
  x->input[8] = read32le((uint32_t *)(k + 0));
  x->input[9] = read32le((uint32_t *)(k + 4));
  x->input[10] = read32le((uint32_t *)(k + 8));
  x->input[11] = read32le((uint32_t *)(k + 12));
  x->input[0] = read32le((uint32_t *)(constants + 0));
  x->input[1] = read32le((uint32_t *)(constants + 4));
  x->input[2] = read32le((uint32_t *)(constants + 8));
  x->input[3] = read32le((uint32_t *)(constants + 12));
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movl %edx, 0x14(%rsp)
movq 0x18(%rsp), %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x10(%rax)
movq 0x18(%rsp), %rdi
addq $0x4, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x14(%rax)
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x18(%rax)
movq 0x18(%rsp), %rdi
addq $0xc, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x1c(%rax)
cmpl $0x100, 0x14(%rsp)      # imm = 0x100
jne 0x12b4
movq 0x18(%rsp), %rax
addq $0x10, %rax
movq %rax, 0x18(%rsp)
leaq 0x2d53(%rip), %rax      # 0x4000
movq %rax, 0x8(%rsp)
jmp 0x12c0
leaq 0x2d65(%rip), %rax      # 0x4020
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x20(%rax)
movq 0x18(%rsp), %rdi
addq $0x4, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x24(%rax)
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x28(%rax)
movq 0x18(%rsp), %rdi
addq $0xc, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x2c(%rax)
movq 0x8(%rsp), %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, (%rax)
movq 0x8(%rsp), %rdi
addq $0x4, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x4(%rax)
movq 0x8(%rsp), %rdi
addq $0x8, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x8(%rax)
movq 0x8(%rsp), %rdi
addq $0xc, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0xc(%rax)
addq $0x28, %rsp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: chacha_ivsetup
void chacha_ivsetup(chacha_ctx_t *x,const unsigned char *iv)
{
  x->input[12] = 0;
  x->input[13] = read32le((uint32_t *)(iv + 0)); /* Modified for 12-byte iv */
  x->input[14] = read32le((uint32_t *)(iv + 4));
  x->input[15] = read32le((uint32_t *)(iv + 8));
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq %rsi, 0x8(%rsp)
movq 0x10(%rsp), %rax
movl $0x0, 0x30(%rax)
movq 0x8(%rsp), %rdi
callq 0x1380
movl %eax, %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x34(%rax)
movq 0x8(%rsp), %rdi
addq $0x4, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x38(%rax)
movq 0x8(%rsp), %rdi
addq $0x8, %rdi
callq 0x1380
movl %eax, %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x3c(%rax)
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: chacha
void chacha(chacha_ctx_t *x,unsigned char *out,unsigned bytes)
{
  unsigned char output[64];
  unsigned i;

  if (!bytes) return;
  for (;;) {
    salsa20_wordtobyte(output,x->input);
    x->input[12] += 1;
    if (bytes <= 64) {
      for (i = 0;i < bytes;++i) out[i] = output[i];
      return;
    }
    for (i = 0;i < 64;++i) out[i] = output[i];
    bytes -= 64;
    out += 64;
  }
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movl %edx, 0x54(%rsp)
cmpl $0x0, 0x54(%rsp)
jne 0x144e
jmp 0x14f7
jmp 0x1450
leaq 0x10(%rsp), %rdi
movq 0x60(%rsp), %rsi
callq 0x1500
movq 0x60(%rsp), %rax
movl 0x30(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x30(%rax)
cmpl $0x40, 0x54(%rsp)
ja 0x14a9
movl $0x0, 0xc(%rsp)
movl 0xc(%rsp), %eax
cmpl 0x54(%rsp), %eax
jae 0x14a7
movl 0xc(%rsp), %eax
movb 0x10(%rsp,%rax), %dl
movq 0x58(%rsp), %rax
movl 0xc(%rsp), %ecx
movb %dl, (%rax,%rcx)
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x147c
jmp 0x14f7
movl $0x0, 0xc(%rsp)
cmpl $0x40, 0xc(%rsp)
jae 0x14d9
movl 0xc(%rsp), %eax
movb 0x10(%rsp,%rax), %dl
movq 0x58(%rsp), %rax
movl 0xc(%rsp), %ecx
movb %dl, (%rax,%rcx)
movl 0xc(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xc(%rsp)
jmp 0x14b1
movl 0x54(%rsp), %eax
subl $0x40, %eax
movl %eax, 0x54(%rsp)
movq 0x58(%rsp), %rax
addq $0x40, %rax
movq %rax, 0x58(%rsp)
jmp 0x1450
addq $0x68, %rsp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: hs1_hash
void hs1_hash(hs1siv_ctx_t *ctx, void *in, unsigned inbytes, void *out) {
    uint64_t *h = (uint64_t *)out;
    unsigned k = (HS1_SIV_HASH_RNDS > 4 ? 1 : 2);

    prf_hash2(h, (uint32_t *)in, inbytes, (uint32_t *)ctx->nh_key,
              (uint64_t *)ctx->poly_key, (uint64_t *)ctx->asu_key);
    #if HS1_SIV_HASH_RNDS > 2
    prf_hash2(h+k, (uint32_t *)in, inbytes, (uint32_t *)ctx->nh_key+8,
              (uint64_t *)ctx->poly_key+2, (uint64_t *)ctx->asu_key+3);
    #if HS1_SIV_HASH_RNDS > 4
    prf_hash2(h+2*k, (uint32_t *)in, inbytes, (uint32_t *)ctx->nh_key+16,
              (uint64_t *)ctx->poly_key+4, (uint64_t *)ctx->asu_key+6);
    #if HS1_SIV_HASH_RNDS > 6
    prf_hash2(h+3*k, (uint32_t *)in, inbytes, (uint32_t *)ctx->nh_key+24,
              (uint64_t *)ctx->poly_key+6, (uint64_t *)ctx->asu_key+9);
    #endif
    #endif
    #endif
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movl %edx, 0x24(%rsp)
movq %rcx, 0x18(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
movl $0x2, 0xc(%rsp)
movq 0x10(%rsp), %rdi
movq 0x28(%rsp), %rsi
movl 0x24(%rsp), %edx
movq 0x30(%rsp), %rcx
addq $0x20, %rcx
movq 0x30(%rsp), %r8
addq $0x90, %r8
movq 0x30(%rsp), %r9
addq $0xb0, %r9
callq 0x1030
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %eax
shlq $0x3, %rax
addq %rax, %rdi
movq 0x28(%rsp), %rsi
movl 0x24(%rsp), %edx
movq 0x30(%rsp), %rcx
addq $0x20, %rcx
addq $0x20, %rcx
movq 0x30(%rsp), %r8
addq $0x90, %r8
addq $0x10, %r8
movq 0x30(%rsp), %r9
addq $0xb0, %r9
addq $0x18, %r9
callq 0x1030
addq $0x38, %rsp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: hs1siv_subkeygen
void hs1siv_subkeygen(hs1siv_ctx_t *ctx, void *user_key, unsigned key_bytes)
{
    unsigned char chacha_key[32];
    unsigned char iv[12];
    unsigned i=0;

    /* Copy user_key as many times as needed to fill 32 byte chacha key */
    while (i < 32) {
        unsigned nbytes = 32-i;
        if (nbytes > key_bytes) nbytes = key_bytes;
        memcpy(chacha_key+i,user_key,nbytes);
        i += nbytes;
    }

    /* Build key-derivation nonce and fill context */
    memset(iv,0,12);
    iv[0] = key_bytes;
    iv[2] = HS1_SIV_SIV_LEN;
    iv[4] = HS1_SIV_CHACHA_RNDS;
    iv[5] = HS1_SIV_HASH_RNDS;
    iv[6] = HS1_SIV_NH_LEN;
    hs1siv_chacha256(ctx, sizeof(hs1siv_ctx_t), iv, chacha_key);

    /* Pre-process internal keys: make future reads little-endian, mod poly */
    for (i=0; i<sizeof(ctx->nh_key)/4; i++)
        ((uint32_t *)ctx->nh_key)[i] = read32le(((uint32_t *)ctx->nh_key)+i);
    for (i=0; i<sizeof(ctx->poly_key)/8; i++)
        ((uint64_t *)ctx->poly_key)[i] = read64le(((uint64_t *)ctx->poly_key)+i)
                                       & m60;
    #if (HS1_SIV_HASH_RNDS > 4)
    for (i=0; i<sizeof(ctx->asu_key)/8; i++)
        ((uint64_t *)ctx->asu_key)[i] = read64le(((uint64_t *)ctx->asu_key)+i);
    #endif
}

// Assembly:
subq $0x58, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movl %edx, 0x44(%rsp)
movl $0x0, 0x10(%rsp)
cmpl $0x20, 0x10(%rsp)
jae 0x280a
movl $0x20, %eax
subl 0x10(%rsp), %eax
movl %eax, 0xc(%rsp)
movl 0xc(%rsp), %eax
cmpl 0x44(%rsp), %eax
jbe 0x27e0
movl 0x44(%rsp), %eax
movl %eax, 0xc(%rsp)
leaq 0x20(%rsp), %rdi
movl 0x10(%rsp), %eax
addq %rax, %rdi
movq 0x48(%rsp), %rsi
movl 0xc(%rsp), %eax
movl %eax, %edx
callq 0x1130
movl 0xc(%rsp), %eax
addl 0x10(%rsp), %eax
movl %eax, 0x10(%rsp)
jmp 0x27ba
leaq 0x14(%rsp), %rdi
xorl %esi, %esi
movl $0xc, %edx
callq 0x1040
movl 0x44(%rsp), %eax
movb %al, 0x14(%rsp)
movb $0x10, 0x16(%rsp)
movb $0xc, 0x18(%rsp)
movb $0x4, 0x19(%rsp)
movb $0x40, 0x1a(%rsp)
movq 0x50(%rsp), %rdi
leaq 0x14(%rsp), %rdx
leaq 0x20(%rsp), %rcx
movl $0xb0, %esi
callq 0x10c0
movl $0x0, 0x10(%rsp)
movl 0x10(%rsp), %eax
cmpq $0x1c, %rax
jae 0x2897
movq 0x50(%rsp), %rdi
addq $0x20, %rdi
movl 0x10(%rsp), %eax
shlq $0x2, %rax
addq %rax, %rdi
callq 0x1380
movl %eax, %edx
movq 0x50(%rsp), %rax
movl 0x10(%rsp), %ecx
movl %edx, 0x20(%rax,%rcx,4)
movl 0x10(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x10(%rsp)
jmp 0x2858
movl $0x0, 0x10(%rsp)
movl 0x10(%rsp), %eax
cmpq $0x4, %rax
jae 0x28f3
movq 0x50(%rsp), %rdi
addq $0x90, %rdi
movl 0x10(%rsp), %eax
shlq $0x3, %rax
addq %rax, %rdi
callq 0x2900
movq %rax, %rdx
movabsq $0xfffffffffffffff, %rax # imm = 0xFFFFFFFFFFFFFFF
andq %rax, %rdx
movq 0x50(%rsp), %rax
movl 0x10(%rsp), %ecx
movq %rdx, 0x90(%rax,%rcx,8)
movl 0x10(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x10(%rsp)
jmp 0x289f
addq $0x58, %rsp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: hs1
void hs1(
    hs1siv_ctx_t *hs1_ctx,
    void *in, unsigned inbytes,
    void *iv,
    void *out, unsigned outbytes
)
{
    #if (HS1_SIV_HASH_RNDS > 4)
    uint64_t h[HS1_SIV_HASH_RNDS/2];
    #else
    uint64_t h[HS1_SIV_HASH_RNDS];
    #endif

    unsigned i;
    unsigned char key[32];
    chacha_ctx_t chacha_ctx;

    hs1_hash(hs1_ctx, in, inbytes, h);
    memcpy(key, hs1_ctx->chacha_key, 32);
    for (i=0; i<sizeof(h)/8;i++) ((uint64_t *)key)[i] ^= h[i];
    chacha_keysetup(&chacha_ctx, key, 256);
    chacha_ivsetup(&chacha_ctx,(unsigned char *)iv);
    chacha(&chacha_ctx, (unsigned char *)out, outbytes);
}

// Assembly:
subq $0xc8, %rsp
movq %rdi, 0xc0(%rsp)
movq %rsi, 0xb8(%rsp)
movl %edx, 0xb4(%rsp)
movq %rcx, 0xa8(%rsp)
movq %r8, 0xa0(%rsp)
movl %r9d, 0x9c(%rsp)
movq 0xc0(%rsp), %rdi
movq 0xb8(%rsp), %rsi
movl 0xb4(%rsp), %edx
leaq 0x70(%rsp), %rcx
callq 0x1060
movq 0xc0(%rsp), %rax
movq (%rax), %rcx
movq %rcx, 0x40(%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x48(%rsp)
movq 0x10(%rax), %rcx
movq %rcx, 0x50(%rsp)
movq 0x18(%rax), %rax
movq %rax, 0x58(%rsp)
movl $0x0, 0x6c(%rsp)
movl 0x6c(%rsp), %eax
cmpq $0x4, %rax
jae 0x29f8
movl 0x6c(%rsp), %eax
movq 0x70(%rsp,%rax,8), %rcx
movl 0x6c(%rsp), %eax
xorq 0x40(%rsp,%rax,8), %rcx
movq %rcx, 0x40(%rsp,%rax,8)
movl 0x6c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x6c(%rsp)
jmp 0x29ca
leaq 0x40(%rsp), %rsi
movq %rsp, %rdi
movl $0x100, %edx            # imm = 0x100
callq 0x1070
movq 0xa8(%rsp), %rsi
movq %rsp, %rdi
callq 0x10d0
movq 0xa0(%rsp), %rsi
movl 0x9c(%rsp), %edx
movq %rsp, %rdi
callq 0x1100
addq $0xc8, %rsp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: hs1siv_encrypt
void hs1siv_encrypt(hs1siv_ctx_t *ctx, void *m, unsigned mbytes,
                    void *a, unsigned abytes, void *n, void *t, void *c)
{
    unsigned i;
    unsigned abuflen = (abytes+HS1_SIV_NH_LEN-1)/HS1_SIV_NH_LEN*HS1_SIV_NH_LEN;
    unsigned buflen = abuflen + (mbytes+15)/16*16 + 16;
    unsigned char tmp_t[HS1_SIV_SIV_LEN];
    unsigned char *buf = (unsigned char *)malloc(buflen);
    memset(buf, 0, buflen);
    memcpy(buf, a, abytes);
    memcpy(buf+abuflen, m, mbytes);
    write32le((uint32_t *)(buf+buflen-16), abytes);
    write32le((uint32_t *)(buf+buflen-8), mbytes);
    hs1(ctx, buf, buflen, n, tmp_t, HS1_SIV_SIV_LEN);
    free(buf);
    buf = (unsigned char *)malloc(mbytes+64);
    hs1(ctx, tmp_t, HS1_SIV_SIV_LEN, n, buf, mbytes+64);
    for (i=0; i<mbytes; i++)
        buf[64+i] ^= ((unsigned char *)m)[i];
    memcpy(c,buf+64,mbytes);
    memcpy(t,tmp_t,HS1_SIV_SIV_LEN);
    free(buf);
}

// Assembly:
subq $0x68, %rsp
movq 0x78(%rsp), %rax
movq 0x70(%rsp), %rax
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movl %edx, 0x54(%rsp)
movq %rcx, 0x48(%rsp)
movl %r8d, 0x44(%rsp)
movq %r9, 0x38(%rsp)
movl 0x44(%rsp), %eax
addl $0x40, %eax
subl $0x1, %eax
shrl $0x6, %eax
shll $0x6, %eax
movl %eax, 0x30(%rsp)
movl 0x30(%rsp), %eax
movl 0x54(%rsp), %ecx
addl $0xf, %ecx
shrl $0x4, %ecx
shll $0x4, %ecx
addl %ecx, %eax
addl $0x10, %eax
movl %eax, 0x2c(%rsp)
movl 0x2c(%rsp), %eax
movl %eax, %edi
callq 0x1080
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rdi
movl 0x2c(%rsp), %eax
movl %eax, %edx
xorl %esi, %esi
callq 0x1040
movq 0x8(%rsp), %rdi
movq 0x48(%rsp), %rsi
movl 0x44(%rsp), %eax
movl %eax, %edx
callq 0x1130
movq 0x8(%rsp), %rdi
movl 0x30(%rsp), %eax
addq %rax, %rdi
movq 0x58(%rsp), %rsi
movl 0x54(%rsp), %eax
movl %eax, %edx
callq 0x1130
movq 0x8(%rsp), %rdi
movl 0x2c(%rsp), %eax
addq %rax, %rdi
addq $-0x10, %rdi
movl 0x44(%rsp), %esi
callq 0x2c10
movq 0x8(%rsp), %rdi
movl 0x2c(%rsp), %eax
addq %rax, %rdi
addq $-0x8, %rdi
movl 0x54(%rsp), %esi
callq 0x2c10
movq 0x60(%rsp), %rdi
movq 0x8(%rsp), %rsi
movl 0x2c(%rsp), %edx
movq 0x38(%rsp), %rcx
leaq 0x10(%rsp), %r8
movl $0x10, %r9d
callq 0x1120
movq 0x8(%rsp), %rdi
callq 0x10a0
movl 0x54(%rsp), %eax
addl $0x40, %eax
movl %eax, %eax
movl %eax, %edi
callq 0x1080
movq %rax, 0x8(%rsp)
movq 0x60(%rsp), %rdi
leaq 0x10(%rsp), %rsi
movq 0x38(%rsp), %rcx
movq 0x8(%rsp), %r8
movl 0x54(%rsp), %r9d
addl $0x40, %r9d
movl $0x10, %edx
callq 0x1120
movl $0x0, 0x34(%rsp)
movl 0x34(%rsp), %eax
cmpl 0x54(%rsp), %eax
jae 0x2bca
movq 0x58(%rsp), %rax
movl 0x34(%rsp), %ecx
movzbl (%rax,%rcx), %esi
movq 0x8(%rsp), %rax
movl 0x34(%rsp), %ecx
addl $0x40, %ecx
movl %ecx, %ecx
movzbl (%rax,%rcx), %edx
xorl %esi, %edx
movb %dl, (%rax,%rcx)
movl 0x34(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x34(%rsp)
jmp 0x2b8f
movq 0x78(%rsp), %rdi
movq 0x8(%rsp), %rsi
addq $0x40, %rsi
movl 0x54(%rsp), %eax
movl %eax, %edx
callq 0x1130
movq 0x70(%rsp), %rax
movq 0x10(%rsp), %rcx
movq %rcx, (%rax)
movq 0x18(%rsp), %rcx
movq %rcx, 0x8(%rax)
movq 0x8(%rsp), %rdi
callq 0x10a0
addq $0x68, %rsp
retq
nopl (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: crypto_aead_encrypt
int crypto_aead_encrypt(
    unsigned char *c,unsigned long long *clen,
    const unsigned char *m,unsigned long long mlen,
    const unsigned char *ad,unsigned long long adlen,
    const unsigned char *nsec,
    const unsigned char *npub,
    const unsigned char *k
)
{
    hs1siv_ctx_t ctx;
    (void)nsec;
    hs1siv_subkeygen(&ctx, (void *)k, CRYPTO_KEYBYTES);
    if (clen) *clen = mlen+CRYPTO_ABYTES;
    hs1siv_encrypt(&ctx, (void *)m, mlen, (void *)ad, adlen, (void *)npub,
                   c+mlen, c);
    return 0;
}

// Assembly:
subq $0xf8, %rsp
movq 0x110(%rsp), %rax
movq 0x108(%rsp), %rax
movq 0x100(%rsp), %rax
movq %rdi, 0xf0(%rsp)
movq %rsi, 0xe8(%rsp)
movq %rdx, 0xe0(%rsp)
movq %rcx, 0xd8(%rsp)
movq %r8, 0xd0(%rsp)
movq %r9, 0xc8(%rsp)
movq 0x110(%rsp), %rsi
leaq 0x10(%rsp), %rdi
movl $0x10, %edx
callq 0x10f0
cmpq $0x0, 0xe8(%rsp)
je 0x2f08
movq 0xd8(%rsp), %rcx
addq $0x10, %rcx
movq 0xe8(%rsp), %rax
movq %rcx, (%rax)
movq 0xe0(%rsp), %rsi
movq 0xd8(%rsp), %rax
movl %eax, %edx
movq 0xd0(%rsp), %rcx
movq 0xc8(%rsp), %rax
movl %eax, %r8d
movq 0x108(%rsp), %r9
movq 0xf0(%rsp), %r10
addq 0xd8(%rsp), %r10
movq 0xf0(%rsp), %rax
leaq 0x10(%rsp), %rdi
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1110
xorl %eax, %eax
addq $0xf8, %rsp
retq
nopw (%rax,%rax)
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: crypto_aead_decrypt
int crypto_aead_decrypt(
    unsigned char *m,unsigned long long *mlen,
    unsigned char *nsec,
    const unsigned char *c,unsigned long long clen,
    const unsigned char *ad,unsigned long long adlen,
    const unsigned char *npub,
    const unsigned char *k
)
{
    hs1siv_ctx_t ctx;
    (void)nsec;
    if (mlen) *mlen = clen-CRYPTO_ABYTES;
    hs1siv_subkeygen(&ctx, (void *)k, CRYPTO_KEYBYTES);
    return hs1siv_decrypt(&ctx, (void *)c, clen-CRYPTO_ABYTES,
    	(void *)ad, adlen, (void *)npub, (void *)(c+clen-CRYPTO_ABYTES), m);
}

// Assembly:
subq $0xf8, %rsp
movq 0x110(%rsp), %rax
movq 0x108(%rsp), %rax
movq 0x100(%rsp), %rax
movq %rdi, 0xf0(%rsp)
movq %rsi, 0xe8(%rsp)
movq %rdx, 0xe0(%rsp)
movq %rcx, 0xd8(%rsp)
movq %r8, 0xd0(%rsp)
movq %r9, 0xc8(%rsp)
cmpq $0x0, 0xe8(%rsp)
je 0x2fe1
movq 0xd0(%rsp), %rcx
subq $0x10, %rcx
movq 0xe8(%rsp), %rax
movq %rcx, (%rax)
movq 0x110(%rsp), %rsi
leaq 0x10(%rsp), %rdi
movl $0x10, %edx
callq 0x10f0
movq 0xd8(%rsp), %rsi
movq 0xd0(%rsp), %rax
subq $0x10, %rax
movl %eax, %edx
movq 0xc8(%rsp), %rcx
movq 0x100(%rsp), %rax
movl %eax, %r8d
movq 0x108(%rsp), %r9
movq 0xd8(%rsp), %r10
addq 0xd0(%rsp), %r10
addq $-0x10, %r10
movq 0xf0(%rsp), %rax
leaq 0x10(%rsp), %rdi
movq %r10, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x1050
addq $0xf8, %rsp
retq
// File: /workspace/github_c_makefile_star2_O0/mjosaarinen[P]brutus/crypto_aead/hs1sivv2/ref/encrypt.c
// Function: swap64
static uint64_t swap64(uint64_t x) {
    return ((x & UINT64_C(0x00000000000000ff)) << 56) |
           ((x & UINT64_C(0x000000000000ff00)) << 40) |
           ((x & UINT64_C(0x0000000000ff0000)) << 24) |
           ((x & UINT64_C(0x00000000ff000000)) <<  8) |
           ((x & UINT64_C(0x000000ff00000000)) >>  8) |
           ((x & UINT64_C(0x0000ff0000000000)) >> 24) |
           ((x & UINT64_C(0x00ff000000000000)) >> 40) |
           ((x & UINT64_C(0xff00000000000000)) >> 56);
}

// Assembly:
movq %rdi, -0x8(%rsp)
movq -0x8(%rsp), %rax
andq $0xff, %rax
shlq $0x38, %rax
movq -0x8(%rsp), %rcx
andq $0xff00, %rcx           # imm = 0xFF00
shlq $0x28, %rcx
orq %rcx, %rax
movq -0x8(%rsp), %rcx
andq $0xff0000, %rcx         # imm = 0xFF0000
shlq $0x18, %rcx
orq %rcx, %rax
movabsq $0xff000000, %rcx       # imm = 0xFF000000
andq -0x8(%rsp), %rcx
shlq $0x8, %rcx
orq %rcx, %rax
movabsq $0xff00000000, %rcx     # imm = 0xFF00000000
andq -0x8(%rsp), %rcx
shrq $0x8, %rcx
orq %rcx, %rax
movabsq $0xff0000000000, %rcx   # imm = 0xFF0000000000
andq -0x8(%rsp), %rcx
shrq $0x18, %rcx
orq %rcx, %rax
movabsq $0xff000000000000, %rcx # imm = 0xFF000000000000
andq -0x8(%rsp), %rcx
shrq $0x28, %rcx
orq %rcx, %rax
movabsq $-0x100000000000000, %rcx # imm = 0xFF00000000000000
andq -0x8(%rsp), %rcx
shrq $0x38, %rcx
orq %rcx, %rax
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O0/mishun[P]plantri/plantri.c
// Function: getswitchvalue
static int 
getswitchvalue(char *arg, int *pj)
 
/* Find integer value for switch. 
   arg is a pointer to a command-line argument.
   pj is an index into arg, which is updated.
   The value of the switch is the function return value.
   For example, if arg="-xyz1432q" and *pj=3 (pointing at "z"),
       the value 1432 is returned and *pj=7 (pointing at "2").
   An absent value is equivalent to 0.
*/

{
    int j,ans;
 
    ans = 0;
    for (j = *pj; arg[j+1] >= '0' && arg[j+1] <= '9'; ++j)
        ans = ans * 10 + (arg[j+1] - '0');
    
    *pj = j;
    return ans;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x18(%rbp)
movq -0x10(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x14(%rbp)
movq -0x8(%rbp), %rax
movl -0x14(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movsbl (%rax,%rcx), %ecx
xorl %eax, %eax
cmpl $0x30, %ecx
movb %al, -0x19(%rbp)
jl 0x6921
movq -0x8(%rbp), %rax
movl -0x14(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x39, %eax
setle %al
movb %al, -0x19(%rbp)
movb -0x19(%rbp), %al
testb $0x1, %al
jne 0x692a
jmp 0x6952
imull $0xa, -0x18(%rbp), %eax
movq -0x8(%rbp), %rcx
movl -0x14(%rbp), %edx
addl $0x1, %edx
movslq %edx, %rdx
movsbl (%rcx,%rdx), %ecx
subl $0x30, %ecx
addl %ecx, %eax
movl %eax, -0x18(%rbp)
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x68ec
movl -0x14(%rbp), %ecx
movq -0x10(%rbp), %rax
movl %ecx, (%rax)
movl -0x18(%rbp), %eax
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O0/mishun[P]plantri/plantri.c
// Function: initialize_splitting
static void
initialize_splitting(int minlevel, int hint, int maxlevel)

/* Set splitlevel and splitcount.  minlevel and maxlevel are bounds
   on its value.  It must be that both minlevel and maxlevel are at
   least equal to the largest starting order (nv for external calls
   to scansimple() or similar routines), and at most equal to the
   smallest parent of a parent of an internal-output graph (call
   from scansimple() or similar to got_one() or similar).  The size
   of internal-output graphs is maxnv-1 for planar triangulations
   and maxnv for other classes.

   hint is a desirable value, which can be anything as the actual
   value used is forced between minlevel and maxlevel.  For plugins,
   the value of splithint is used instead if it is >= 0.

   In case there is no way to use splitting within those limits,
   it is turned off by setting splitlevel=0.  In that case only
   subcase 0 should produce output.

   Splitting occurs at the first level where nv >= splitlevel.
   If an operation can add k vertices, it must be that
   splitlevel <= maxnv - k.
*/
{
    splitlevel = (twoswitch ? hint + 1 : hint);
#ifdef PLUGIN
    if (splithint >= 0) splitlevel = splithint;
#endif

    if (splitlevel > maxlevel) splitlevel = maxlevel;

    if (splitlevel < minlevel && splitlevel > 0)
    {
	if (minlevel <= maxlevel) splitlevel = minlevel;
	else                      splitlevel = 0;
    }
    if (mod == 1) splitlevel = 0;

    splitcount = res;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x4(%rbp)
movl %esi, -0x8(%rbp)
movl %edx, -0xc(%rbp)
cmpl $0x0, 0x35304(%rip)     # 0x3c268
je 0x6f71
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x6f77
movl -0x8(%rbp), %eax
movl %eax, -0x10(%rbp)
movl -0x10(%rbp), %eax
movl %eax, 0x36a74(%rip)     # 0x3d9f4
movl 0x36a6e(%rip), %eax     # 0x3d9f4
cmpl -0xc(%rbp), %eax
jle 0x6f94
movl -0xc(%rbp), %eax
movl %eax, 0x36a60(%rip)     # 0x3d9f4
movl 0x36a5a(%rip), %eax     # 0x3d9f4
cmpl -0x4(%rbp), %eax
jge 0x6fc7
cmpl $0x0, 0x36a4e(%rip)     # 0x3d9f4
jle 0x6fc7
movl -0x4(%rbp), %eax
cmpl -0xc(%rbp), %eax
jg 0x6fbb
movl -0x4(%rbp), %eax
movl %eax, 0x36a3b(%rip)     # 0x3d9f4
jmp 0x6fc5
movl $0x0, 0x36a2f(%rip)     # 0x3d9f4
jmp 0x6fc7
cmpl $0x1, 0x352ae(%rip)     # 0x3c27c
jne 0x6fda
movl $0x0, 0x36a1a(%rip)     # 0x3d9f4
movl 0x35298(%rip), %eax     # 0x3c278
movl %eax, 0x299c4a(%rip)    # 0x2a0c30
popq %rbp
retq
nopl (%rax,%rax)