LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/fm4dd[P]learn-ssl/keycompare.c
// Function: RSAcmp_mod
int RSAcmp_mod(EVP_PKEY *priv, EVP_PKEY *pub) {
  int match;

#if OPENSSL_VERSION_NUMBER < 0x30000000L
  /* -------------------------------------------------------- *
   * Old code for OpenSSL versions before version 3.0         *
   * ---------------------------------------------------------*/
  const BIGNUM *privrsa_mod;
  const BIGNUM *pubrsa_mod;
  RSA *privrsa = EVP_PKEY_get1_RSA(priv);
  RSA_get0_key(privrsa, &privrsa_mod, NULL, NULL);
  RSA *pubrsa = EVP_PKEY_get1_RSA(pub);
  RSA_get0_key(pubrsa, &pubrsa_mod, NULL, NULL);
#else
  /* -------------------------------------------------------- *
   * New code for latest OpenSSL version 3.0                  *
   * ---------------------------------------------------------*/
  BIGNUM *privrsa_mod = NULL;
  BIGNUM *pubrsa_mod = NULL;
  EVP_PKEY_get_bn_param(priv, OSSL_PKEY_PARAM_RSA_N, &privrsa_mod);
  EVP_PKEY_get_bn_param(pub, OSSL_PKEY_PARAM_RSA_N, &pubrsa_mod);
#endif

  char *privrsa_mod_hex = BN_bn2hex(privrsa_mod);
  char *pubrsa_mod_hex = BN_bn2hex(pubrsa_mod);

  printf("priv: %s\n", privrsa_mod_hex);
  printf(" pub: %s\n", pubrsa_mod_hex);

  if(strcmp(privrsa_mod_hex, pubrsa_mod_hex) == 0)
    match = 0; // the keys modulus is matching
  else
    match = 1; // the keys modulus don't match

  OPENSSL_free(privrsa_mod_hex);
  OPENSSL_free(pubrsa_mod_hex);

#if OPENSSL_VERSION_NUMBER < 0x30000000L
  RSA_free(privrsa);
  RSA_free(pubrsa);
#endif
  return match;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
xorl %eax, %eax
leaq 0x8(%rsp), %r14
movq %rax, (%r14)
movq %rsp, %r15
movq %rax, (%r15)
leaq 0xcc2(%rip), %r12       # 0x2004
movq %r12, %rsi
movq %r14, %rdx
callq 0x10c0
movq %rbx, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x10c0
movq (%r14), %rdi
callq 0x1210
movq %rax, %rbx
movq (%r15), %rdi
callq 0x1210
movq %rax, %r14
leaq 0xc8e(%rip), %rdi       # 0x2006
movq %rbx, %rsi
xorl %eax, %eax
callq 0x1040
leaq 0xc87(%rip), %rdi       # 0x2010
movq %r14, %rsi
xorl %eax, %eax
callq 0x1040
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1190
xorl %ebp, %ebp
testl %eax, %eax
setne %bpl
leaq 0xc6d(%rip), %r15       # 0x201a
movq %rbx, %rdi
movq %r15, %rsi
movl $0x48, %edx
callq 0x1100
movq %r14, %rdi
movq %r15, %rsi
movl $0x49, %edx
callq 0x1100
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/fm4dd[P]learn-ssl/keycompare.c
// Function: RSAencrypt
int RSAencrypt(EVP_PKEY *key, const unsigned char *teststring) {
  int rsa_outlen = 0;
  encdata = OPENSSL_zalloc(1024); // allocate and zero 1kb space

#if OPENSSL_VERSION_NUMBER < 0x30000000L
  RSA *pubrsa = NULL;
  pubrsa = EVP_PKEY_get1_RSA(key);
  rsa_outlen = RSA_public_encrypt(teststr_len, teststring, encdata, pubrsa, pad);
  RSA_free(pubrsa);
#else
  EVP_PKEY_CTX *ctx = NULL;
  ctx = EVP_PKEY_CTX_new_from_pkey(NULL, key, NULL);
  OSSL_PARAM params[2];
  set_optional_params(params);
  EVP_PKEY_encrypt_init_ex(ctx, params);
  EVP_PKEY_encrypt(ctx, encdata, (size_t *) &rsa_outlen, teststring, teststr_len);
  EVP_PKEY_CTX_free(ctx);
#endif
  return rsa_outlen;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x80, %rsp
movq %rsi, %r14
movq %rdi, %r15
leaq 0x4(%rsp), %rbx
movl $0x0, (%rbx)
leaq 0x92e(%rip), %rsi       # 0x201a
movl $0x400, %edi            # imm = 0x400
movl $0xc3, %edx
callq 0x11e0
movq %rax, 0x2a26(%rip)      # 0x4128
xorl %edi, %edi
movq %r15, %rsi
xorl %edx, %edx
callq 0x1090
movq %rax, %r15
leaq 0xaf2(%rip), %rsi       # 0x220a
leaq 0xaf4(%rip), %rdx       # 0x2213
leaq 0x30(%rsp), %r12
movq %r12, %rdi
xorl %ecx, %ecx
callq 0x1110
leaq 0x8(%rsp), %r13
movq %r13, %rdi
callq 0x10b0
movq 0x20(%r13), %rax
movq %rax, 0x48(%r12)
movups (%r13), %xmm0
movups 0x10(%r13), %xmm1
movups %xmm1, 0x38(%r12)
movups %xmm0, 0x28(%r12)
movq %r15, %rdi
movq %r12, %rsi
callq 0x1060
movq 0x29bc(%rip), %rsi      # 0x4128
movslq 0x29c9(%rip), %r8       # 0x413c
movq %r15, %rdi
movq %rbx, %rdx
movq %r14, %rcx
callq 0x1140
movq %r15, %rdi
callq 0x11b0
movl (%rbx), %eax
addq $0x80, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/fm4dd[P]learn-ssl/keycompare.c
// Function: RSAdecrypt
int RSAdecrypt(EVP_PKEY *key, int rsa_inlen) {
  int rsa_outlen = 0;
  decdata = OPENSSL_zalloc(1024); // allocate and zero 1kb space

#if OPENSSL_VERSION_NUMBER < 0x30000000L
  RSA *privrsa = NULL;
  privrsa = EVP_PKEY_get1_RSA(key);
  rsa_outlen = RSA_private_decrypt(rsa_inlen, encdata, decdata, privrsa, pad);
  RSA_free(privrsa);
#else
  EVP_PKEY_CTX *ctx = NULL;
  ctx = EVP_PKEY_CTX_new_from_pkey(NULL, key, NULL);
  OSSL_PARAM params[2];
  set_optional_params(params);
  EVP_PKEY_decrypt_init_ex(ctx, params);
  EVP_PKEY_decrypt(ctx, decdata, (size_t *) &rsa_outlen, encdata, rsa_inlen);
#endif
  return rsa_outlen;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x80, %rsp
movl %esi, %ebp
movq %rdi, %r14
leaq 0x4(%rsp), %rbx
movl $0x0, (%rbx)
leaq 0x858(%rip), %rsi       # 0x201a
movl $0x400, %edi            # imm = 0x400
movl $0xdb, %edx
callq 0x11e0
movq %rax, 0x2958(%rip)      # 0x4130
xorl %edi, %edi
movq %r14, %rsi
xorl %edx, %edx
callq 0x1090
movq %rax, %r14
leaq 0xa1c(%rip), %rsi       # 0x220a
leaq 0xa1e(%rip), %rdx       # 0x2213
leaq 0x30(%rsp), %r15
movq %r15, %rdi
xorl %ecx, %ecx
callq 0x1110
leaq 0x8(%rsp), %r12
movq %r12, %rdi
callq 0x10b0
movq 0x20(%r12), %rax
movq %rax, 0x48(%r15)
movups (%r12), %xmm0
movups 0x10(%r12), %xmm1
movups %xmm1, 0x38(%r15)
movups %xmm0, 0x28(%r15)
movq %r14, %rdi
movq %r15, %rsi
callq 0x1030
movq 0x28ef(%rip), %rsi      # 0x4130
movq 0x28e0(%rip), %rcx      # 0x4128
movslq %ebp, %r8
movq %r14, %rdi
movq %rbx, %rdx
callq 0x1130
movl (%rbx), %eax
addq $0x80, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/fm4dd[P]learn-ssl/keycompare.c
// Function: ECsign
ECDSA_SIG *ECsign(EVP_PKEY *key, const unsigned char *teststring) {
  ECDSA_SIG *sig;

#if OPENSSL_VERSION_NUMBER < 0x30000000L
  EC_KEY *priveckey = NULL;
  priveckey = EVP_PKEY_get1_EC_KEY(key);
  sig = ECDSA_do_sign(teststring, teststr_len, priveckey);
  EC_KEY_free(priveckey);
#else
  EVP_MD_CTX *ctx = NULL;
  ctx = EVP_MD_CTX_new();
  unsigned char *sigstr;
  size_t *sig_len;
  EVP_DigestSign(ctx, sigstr, sig_len, teststring, teststr_len);
  sig = d2i_ECDSA_SIG(NULL, (const unsigned char **) &sigstr, (long) &sig_len);
  EVP_MD_CTX_free(ctx);
#endif
  return sig;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rbx
callq 0x1160
movq %rax, %r14
leaq 0x10(%rsp), %r15
movq (%r15), %rsi
leaq 0x8(%rsp), %r12
movq (%r12), %rdx
movslq 0x28a6(%rip), %r8       # 0x413c
movq %rax, %rdi
movq %rbx, %rcx
callq 0x1050
xorl %edi, %edi
movq %r15, %rsi
movq %r12, %rdx
callq 0x10e0
movq %rax, %rbx
movq %r14, %rdi
callq 0x11f0
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/fm4dd[P]learn-ssl/keycompare.c
// Function: ECverify
int ECverify(EVP_PKEY *key, const unsigned char *teststring, ECDSA_SIG *sig) {

  teststr_len = strlen( (const char *) teststring);
#if OPENSSL_VERSION_NUMBER < 0x30000000L
  EC_KEY *pubeckey = NULL;
  pubeckey = EVP_PKEY_get1_EC_KEY(key);
  ret = ECDSA_do_verify(teststring, teststr_len, sig, pubeckey);
  EC_KEY_free(pubeckey);
#else
  EVP_MD_CTX *ctx = NULL;
  ctx = EVP_MD_CTX_new();
  unsigned char *sigstr;
  i2d_ECDSA_SIG(sig, &sigstr);
  size_t sig_len = strlen( (const char *) sigstr);
  /* ---------------------------------------------------------- *
   * Successful verification returns 1                          *
   * ---------------------------------------------------------- */
    ret = EVP_DigestVerify(ctx, sigstr, sig_len, teststring, teststr_len);
   EVP_MD_CTX_free(ctx);
#endif
  return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rsi, %rdi
callq 0x10d0
movl %eax, 0x2858(%rip)      # 0x413c
callq 0x1160
movq %rax, %r15
movq %rsp, %r12
movq %rbx, %rdi
movq %r12, %rsi
callq 0x1170
movq (%r12), %rbx
movq %rbx, %rdi
callq 0x10d0
movslq 0x282f(%rip), %r8       # 0x413c
movq %r15, %rdi
movq %rbx, %rsi
movq %rax, %rdx
movq %r14, %rcx
callq 0x1070
movl %eax, 0x2814(%rip)      # 0x4138
movq %r15, %rdi
callq 0x11f0
movl 0x2806(%rip), %eax      # 0x4138
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/main.c
// Function: main.cold.1
static int usage()
{
	fprintf(stderr, "Usage: bgt <command> <argument>\n");
	fprintf(stderr, "Commands:\n");
	fprintf(stderr, "  import       convert VCF to BGT\n");
	fprintf(stderr, "  atomize      atomize VCF\n");
	fprintf(stderr, "  view         extract from BGT\n");
	fprintf(stderr, "  fmf          manipulate FMF files\n");
	fprintf(stderr, "  bcfidx       (re)index BCF with record number index\n");
	fprintf(stderr, "  version      show version number\n");
	return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq 0x23b6c(%rip), %r15     # 0x25ff8
movq (%r15), %rcx
leaq 0x1bbcc(%rip), %rdi     # 0x1e062
pushq $0x20
popq %r14
pushq $0x1
popq %rbx
movq %r14, %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bbd1(%rip), %rdi     # 0x1e083
pushq $0xa
popq %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bbc7(%rip), %rdi     # 0x1e08e
pushq $0x22
popq %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bbd5(%rip), %rdi     # 0x1e0b1
pushq $0x1b
popq %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bbdc(%rip), %rdi     # 0x1e0cd
movq %r14, %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bbe8(%rip), %rdi     # 0x1e0ee
pushq $0x24
popq %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bbf8(%rip), %rdi     # 0x1e113
pushq $0x36
popq %rsi
movq %rbx, %rdx
callq 0x2400
movq (%r15), %rcx
leaq 0x1bc1a(%rip), %rdi     # 0x1e14a
pushq $0x23
popq %rsi
movq %rbx, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x2400
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/main.c
// Function: main
int main(int argc, char *argv[])
{
	if (argc < 2) return usage();
	if (strcmp(argv[1], "import") == 0) return main_import(argc-1, argv+1);
	else if (strcmp(argv[1], "atomize") == 0) return main_atomize(argc-1, argv+1);
	else if (strcmp(argv[1], "view") == 0 || strcmp(argv[1], "mview") == 0 ) return main_view(argc-1, argv+1);
	else if (strcmp(argv[1], "fmf") == 0 ) return main_fmf(argc-1, argv+1);
	else if (strcmp(argv[1], "getalt") == 0) return main_getalt(argc-1, argv+1);
	else if (strcmp(argv[1], "bcfidx") == 0) return main_bcfidx(argc-1, argv+1);
	else if (strcmp(argv[1], "version") == 0) {
		puts(BGT_VERSION);
		return 0;
	} else {
		fprintf(stderr, "[E::%s] unrecognized command '%s'\n", __func__, argv[1]);
		return 1;
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
cmpl $0x1, %edi
jle 0x2da6
movq %rsi, %rbx
movl %edi, %ebp
movq 0x8(%rsi), %r14
addq $0x8, %rbx
leaq 0x1b347(%rip), %rsi     # 0x1e004
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2d76
leaq 0x1c813(%rip), %rsi     # 0x1f4e7
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2d96
leaq 0x1b898(%rip), %rsi     # 0x1e583
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2d86
leaq 0x1b309(%rip), %rsi     # 0x1e00b
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2d86
leaq 0x1b2fc(%rip), %rsi     # 0x1e011
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2db5
leaq 0x1b2e9(%rip), %rsi     # 0x1e015
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2dc5
leaq 0x1b2d9(%rip), %rsi     # 0x1e01c
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
je 0x2dd5
leaq 0x1b2c9(%rip), %rsi     # 0x1e023
movq %r14, %rdi
callq 0x2230
testl %eax, %eax
jne 0x2de5
leaq 0x1b2be(%rip), %rdi     # 0x1e02b
callq 0x20e0
xorl %eax, %eax
jmp 0x2db0
decl %ebp
movl %ebp, %edi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x2e0c
decl %ebp
movl %ebp, %edi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x3680
decl %ebp
movl %ebp, %edi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x3442
callq 0x2480
movl $0x1, %eax
popq %rbx
popq %r14
popq %rbp
retq
decl %ebp
movl %ebp, %edi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0xa8e4
decl %ebp
movl %ebp, %edi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x3deb
decl %ebp
movl %ebp, %edi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x33be
movq 0x2320c(%rip), %rax     # 0x25ff8
movq (%rax), %rdi
leaq 0x1b244(%rip), %rsi     # 0x1e03a
leaq 0x1b260(%rip), %rdx     # 0x1e05d
movq %r14, %rcx
xorl %eax, %eax
callq 0x2250
jmp 0x2dab
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/import.c
// Function: main_bcfidx
int main_bcfidx(int argc, char *argv[])
{
	int c, min_shift = 14;
	while ((c = getopt(argc, argv, "s:")) >= 0)
		if (c == 's') min_shift = atoi(optarg);
	if (optind == argc) {
		fprintf(stderr, "Usage: bgt bcfidx [-s minShift] <in.bcf>\n");
		return 1;
	}
	bcf_index_build(argv[optind], min_shift);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x1af92(%rip), %rdx     # 0x1e364
callq 0x23d0
movl $0xe, %r14d
testl %eax, %eax
js 0x3411
movq 0x22bc8(%rip), %r12     # 0x25fb0
leaq 0x1af75(%rip), %r15     # 0x1e364
cmpl $0x73, %eax
jne 0x3400
movq (%r12), %rdi
callq 0x23e0
movl %eax, %r14d
movl %ebp, %edi
movq %rbx, %rsi
movq %r15, %rdx
callq 0x23d0
testl %eax, %eax
jns 0x33ef
movq 0x22b80(%rip), %rax     # 0x25f98
movslq (%rax), %rax
cmpl %ebp, %eax
je 0x3436
movq (%rbx,%rax,8), %rdi
movl %r14d, %esi
callq 0x1092f
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
callq 0x25d3
movl $0x1, %eax
jmp 0x342d
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/fmf.c
// Function: fmf_destroy
void fmf_destroy(fmf_t *f)
{
	int i;
	if (f == 0) return;
	for (i = 0; i < f->n_keys; ++i) free(f->keys[i]);
	for (i = 0; i < f->n_vals; ++i) free(f->vals[i]);
	for (i = 0; i < f->n_rows; ++i) {
		fmf1_t *r = &f->rows[i];
		free(r->name); free(r->meta);
	}
	free(f->rows); free(f->keys); free(f->vals);
	free(f);
}

// Assembly:
testq %rdi, %rdi
je 0x9f78
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
cmpl $0x0, (%rdi)
jle 0x9ef2
xorl %r14d, %r14d
movq 0x8(%rbx), %rax
movq (%rax,%r14,8), %rdi
callq 0x2050
incq %r14
movslq (%rbx), %rax
cmpq %rax, %r14
jl 0x9eda
cmpl $0x0, 0x10(%rbx)
jle 0x9f14
xorl %r14d, %r14d
movq 0x18(%rbx), %rax
movq (%rax,%r14,8), %rdi
callq 0x2050
incq %r14
movslq 0x10(%rbx), %rax
cmpq %rax, %r14
jl 0x9efb
cmpl $0x0, 0x20(%rbx)
jle 0x9f4a
movl $0x10, %r14d
xorl %r15d, %r15d
movq 0x28(%rbx), %r12
movq -0x10(%r12,%r14), %rdi
callq 0x2050
movq (%r12,%r14), %rdi
callq 0x2050
incq %r15
movslq 0x20(%rbx), %rax
addq $0x18, %r14
cmpq %rax, %r15
jl 0x9f23
movq 0x28(%rbx), %rdi
callq 0x2050
movq 0x8(%rbx), %rdi
callq 0x2050
movq 0x18(%rbx), %rdi
callq 0x2050
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x2050
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/fmf.c
// Function: fmf_test
int fmf_test(const fmf_t *f, int r, kexpr_t *ke) // FIXME: a quadratic implementation!!! optimize later if too slow
{
	fmf1_t *u;
	int err, i, is_true;
	if (r >= f->n_rows) return 0;
	u = &f->rows[r];
	ke_unset(ke);
	for (i = 0; i < u->n_meta; ++i) {
		fmf_meta_t *m = &u->meta[i];
		ke_set_str(ke, "_ROW_", u->name);
		if (m->type == FMF_STR) ke_set_str(ke, f->keys[m->key], f->vals[m->v.s]);
		else if (m->type == FMF_INT) ke_set_int(ke, f->keys[m->key], m->v.i);
		else if (m->type == FMF_REAL) ke_set_int(ke, f->keys[m->key], m->v.r);
	}
	is_true = !!ke_eval_int(ke, &err);
	return !(err || !is_true);
}

// Assembly:
xorl %eax, %eax
cmpl %esi, 0x20(%rdi)
jle 0xa60f
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r14
movq 0x28(%rdi), %r15
movslq %esi, %rax
leaq (%rax,%rax,2), %r12
movq %rdx, %rdi
callq 0x1d3e4
cmpl $0x0, 0x8(%r15,%r12,8)
jle 0xa5df
leaq (%r15,%r12,8), %r12
xorl %r13d, %r13d
leaq 0x14b8a(%rip), %r15     # 0x1f0d7
movq (%r12), %rdx
movq 0x10(%r12), %rbp
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1d0a0
movl (%rbp,%r13,8), %eax
movl %eax, %ecx
shrl $0x1c, %ecx
cmpl $0x1, %ecx
je 0xa5b4
cmpl $0x2, %ecx
je 0xa59e
cmpl $0x3, %ecx
jne 0xa5ce
andl $0xfffffff, %eax        # imm = 0xFFFFFFF
movq 0x8(%r14), %rcx
movq 0x18(%r14), %rdx
movq (%rcx,%rax,8), %rsi
movl 0x4(%rbp,%r13,8), %eax
movq (%rdx,%rax,8), %rdx
movq %rbx, %rdi
callq 0x1d0a0
jmp 0xa5ce
movq 0x8(%r14), %rcx
andl $0xfffffff, %eax        # imm = 0xFFFFFFF
movq (%rcx,%rax,8), %rsi
cvttss2si 0x4(%rbp,%r13,8), %rdx
jmp 0xa5c6
movq 0x8(%r14), %rcx
andl $0xfffffff, %eax        # imm = 0xFFFFFFF
movq (%rcx,%rax,8), %rsi
movslq 0x4(%rbp,%r13,8), %rdx
movq %rbx, %rdi
callq 0x1cf2e
incq %r13
movslq 0x8(%r12), %rax
cmpq %rax, %r13
jl 0xa54d
leaq 0x4(%rsp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1ce6c
testq %rax, %rax
setne %al
cmpl $0x0, (%r14)
sete %cl
andb %al, %cl
movzbl %cl, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/fmf.c
// Function: fms_open
fms_t *fms_open(const char *fn)
{
	fms_t *f;
	gzFile fp;
	fp = fn && strcmp(fn, "-")? gzopen(fn, "r") : gzdopen(fileno(stdin), "r");
	if (fp == 0) return 0;
	f = (fms_t*)calloc(1, sizeof(fms_t));
	f->ks = ks_init(fp);
	f->fp = fp;
	return f;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0xa63d
movq %rdi, %rbx
leaq 0x13e91(%rip), %rsi     # 0x1e4b4
callq 0x2230
testl %eax, %eax
je 0xa63d
leaq 0x14c08(%rip), %rsi     # 0x1f23b
movq %rbx, %rdi
callq 0x2370
jmp 0xa65a
movq 0x1b944(%rip), %rax     # 0x25f88
movq (%rax), %rdi
callq 0x22a0
leaq 0x14be8(%rip), %rsi     # 0x1f23b
movl %eax, %edi
callq 0x2140
movq %rax, %rbx
testq %rax, %rax
je 0xa685
movl $0x1, %edi
movl $0x28, %esi
callq 0x2220
movq %rax, %r14
movq %rbx, %rdi
callq 0x5b18
movq %rax, (%r14)
movq %rbx, 0x20(%r14)
jmp 0xa688
xorl %r14d, %r14d
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/fmf.c
// Function: fms_close
void fms_close(fms_t *f)
{
	if (f == 0) return;
	free(f->s.s);
	ks_destroy(f->ks);
	gzclose(f->fp);
	free(f);
}

// Assembly:
testq %rdi, %rdi
je 0xa6bf
pushq %rbx
movq %rdi, %rbx
movq 0x18(%rdi), %rdi
callq 0x2050
movq (%rbx), %rdi
callq 0x5b5d
movq 0x20(%rbx), %rdi
callq 0x2040
movq %rbx, %rdi
popq %rbx
jmp 0x2050
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/fmf.c
// Function: fms_read
const char *fms_read(fms_t *f, kexpr_t *ke, int name_only)
{
	int ret;
	char *end0 = 0;
	while ((ret = fms_read_and_test(f, ke, &end0)) == 0);
	if (ret < 0) return 0;
	if (name_only) *end0 = 0;
	return f->s.s;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %edx, 0x2c(%rsp)
movq %rsi, 0x8(%rsp)
movq %rdi, %rbx
leaq 0x8(%rdi), %r14
xorl %edx, %edx
leaq 0x18(%rsp), %r12
movq %rdi, 0x38(%rsp)
movq %r14, 0x30(%rsp)
movq %rdx, %r15
movl $0x0, 0x1c(%rsp)
movq (%rbx), %rdi
movl $0x2, %esi
movq %r14, %rdx
movq %r12, %rcx
xorl %r8d, %r8d
callq 0x5b79
testl %eax, %eax
js 0xa896
cmpq $0x0, (%r14)
je 0xa894
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0xa73b
movq 0x8(%rsp), %rdi
callq 0x1d3e4
movq 0x8(%rsp), %rdi
movq 0x18(%rbx), %r12
xorl %ecx, %ecx
movq %r12, %r14
movq %r12, %rbp
movq %r15, %rdx
movzbl (%rbp), %r15d
cmpl $0x9, %r15d
je 0xa75e
testl %r15d, %r15d
jne 0xa86c
movb $0x0, (%rbp)
testl %ecx, %ecx
je 0xa7eb
movq %r12, %rax
subq %r14, %rax
movq %r14, %rbx
movq %rbx, 0x40(%rsp)
movzbl (%rbx), %r13d
testl %r13d, %r13d
je 0xa78f
cmpl $0x3a, %r13d
je 0xa78f
incq %rbx
decq %rax
jmp 0xa773
movb $0x0, (%rbx)
cmpb $0x3a, %r13b
jne 0xa85a
testq %rdi, %rdi
je 0xa85a
cmpq $0x3, %rax
jl 0xa85a
movq %rdx, 0x20(%rsp)
movzbl 0x1(%rbx), %eax
leaq 0x3(%rbx), %rdx
cmpl $0x66, %eax
movl %ecx, 0x14(%rsp)
je 0xa815
cmpl $0x69, %eax
jne 0xa83f
movq %rdx, %rdi
leaq 0x40(%rsp), %rsi
xorl %edx, %edx
callq 0x2270
movq 0x8(%rsp), %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x1cf2e
jmp 0xa84c
movq %rbp, %rdx
testq %rdi, %rdi
je 0xa85d
movq 0x8(%rsp), %rdi
leaq 0x148d8(%rip), %rsi     # 0x1f0d7
movq %r14, %rdx
movl %ecx, %ebx
callq 0x1d0a0
movl %ebx, %ecx
movq 0x8(%rsp), %rdi
movq %rbp, %rdx
jmp 0xa85d
movq %rdx, %rdi
leaq 0x40(%rsp), %rsi
callq 0x2100
movq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x1cfe6
movl 0x14(%rsp), %ecx
movq 0x8(%rsp), %rdi
movq 0x20(%rsp), %rdx
jmp 0xa85a
movq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x1d0a0
movq 0x8(%rsp), %rdi
movq 0x20(%rsp), %rdx
movl 0x14(%rsp), %ecx
movb %r13b, (%rbx)
testb %r15b, %r15b
je 0xa877
incl %ecx
leaq 0x1(%rbp), %r14
movb %r15b, (%rbp)
incq %rbp
incq %r12
jmp 0xa74a
testq %rdi, %rdi
je 0xa89b
leaq 0x1c(%rsp), %rsi
movq %rdx, %rbx
callq 0x1ce6c
movq %rbx, %rdx
testq %rax, %rax
setne %al
jmp 0xa89d
xorl %eax, %eax
movq %r15, %rdx
jmp 0xa8b9
movb $0x1, %al
movq 0x38(%rsp), %rbx
movq 0x30(%rsp), %r14
leaq 0x18(%rsp), %r12
cmpl $0x0, 0x1c(%rsp)
sete %cl
andb %al, %cl
movzbl %cl, %eax
testl %eax, %eax
je 0xa6ef
js 0xa8d3
cmpl $0x0, 0x2c(%rsp)
je 0xa8cd
movb $0x0, (%rdx)
movq 0x18(%rbx), %rax
jmp 0xa8d5
xorl %eax, %eax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/fmf.c
// Function: main_fmf
int main_fmf(int argc, char *argv[])
{
	kexpr_t *ke = 0;
	int i, c, err, in_mem = 0, name_only = 0;
	while ((c = getopt(argc, argv, "mn")) >= 0)
		if (c == 'm') in_mem = 1;
		else if (c == 'n') name_only = 1;
	if (argc == optind) {
		fprintf(stderr, "Usage: fmf [-mn] <in.fmf> [condition]\n");
		fprintf(stderr, "Options:\n");
		fprintf(stderr, "  -m   load the entire FMF into RAM\n");
		fprintf(stderr, "  -n   only output the row name (the 1st column)\n");
		return 1;
	}
	if (argc - optind >= 2) ke = ke_parse(argv[optind+1], &err);
	if (in_mem) {
		fmf_t *f;
		f = fmf_read(argv[optind]);
		for (i = 0; i < f->n_rows; ++i) {
			char *s;
			if (ke && !fmf_test(f, i, ke)) continue;
			if (!name_only) {
				s = fmf_write(f, i);
				puts(s);
				free(s);
			} else puts(f->rows[i].name);
		}
		fmf_destroy(f);
	} else {
		fms_t *f;
		const char *s;
		f = fms_open(argv[optind]);
		while ((s = fms_read(f, ke, name_only)) != 0)
			puts(s);
		fms_close(f);
	}
	if (ke) ke_destroy(ke);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r15
movl %edi, %ebp
leaq 0x147e2(%rip), %rdx     # 0x1f0dd
callq 0x23d0
testl %eax, %eax
js 0xa941
xorl %r12d, %r12d
leaq 0x147cf(%rip), %r14     # 0x1f0dd
xorl %ebx, %ebx
cmpl $0x6d, %eax
je 0xa921
cmpl $0x6e, %eax
jne 0xa927
movl $0x1, %ebx
jmp 0xa927
movl $0x1, %r12d
movl %ebp, %edi
movq %r15, %rsi
movq %r14, %rdx
callq 0x23d0
testl %eax, %eax
jns 0xa910
testl %r12d, %r12d
sete %r12b
jmp 0xa946
movb $0x1, %r12b
xorl %ebx, %ebx
movq 0x1b64b(%rip), %r13     # 0x25f98
movslq (%r13), %rax
cmpl %eax, %ebp
je 0xaa4c
subl %eax, %ebp
cmpl $0x2, %ebp
jl 0xa974
movq 0x8(%r15,%rax,8), %rdi
leaq 0x4(%rsp), %rsi
callq 0x1b574
movq %rax, %r14
jmp 0xa977
xorl %r14d, %r14d
movslq (%r13), %rax
movq (%r15,%rax,8), %rdi
testb %r12b, %r12b
je 0xa9af
callq 0xa610
movq %rax, %r15
movq %rax, %rdi
movq %r14, %rsi
movl %ebx, %edx
callq 0xa6c0
testq %rax, %rax
je 0xaa24
movq %rax, %rdi
callq 0x20e0
movq %r15, %rdi
jmp 0xa98f
callq 0x9a08
movq %rax, %r15
cmpl $0x0, 0x20(%rax)
jle 0xaa1a
xorl %ebp, %ebp
xorl %r12d, %r12d
testq %r14, %r14
je 0xa9d9
movq %r15, %rdi
movl %r12d, %esi
movq %r14, %rdx
callq 0xa504
testl %eax, %eax
je 0xaa0a
testl %ebx, %ebx
je 0xa9ec
movq 0x28(%r15), %rax
movq (%rax,%rbp), %rdi
callq 0x20e0
jmp 0xaa0a
movq %r15, %rdi
movl %r12d, %esi
callq 0x9f79
movq %rax, %r13
movq %rax, %rdi
callq 0x20e0
movq %r13, %rdi
callq 0x2050
incq %r12
movslq 0x20(%r15), %rax
addq $0x18, %rbp
cmpq %rax, %r12
jl 0xa9c2
movq %r15, %rdi
callq 0x9ebe
jmp 0xaa2c
movq %r15, %rdi
callq 0xa693
xorl %ebx, %ebx
testq %r14, %r14
je 0xaa3b
movq %r14, %rdi
callq 0x1ced4
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x2ad3
movl $0x1, %ebx
jmp 0xaa3b
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_hdr_sync
int bcf_hdr_sync(bcf_hdr_t *h)
{
	int i;
	for (i = 0; i < 3; ++i) {
		khint_t k;
		vdict_t *d = (vdict_t*)h->dict[i];
		h->n[i]  = kh_size(d);
		h->id[i] = (bcf_idpair_t*)realloc(h->id[i], kh_size(d) * sizeof(bcf_idpair_t));
		for (k = kh_begin(d); k != kh_end(d); ++k) {
			if (!kh_exist(d, k)) continue;
			h->id[i][kh_val(d, k).id].key = kh_key(d, k);
			h->id[i][kh_val(d, k).id].val = &kh_val(d, k);
		}
	}
	return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
xorl %r14d, %r14d
movq 0x30(%rbx,%r14,8), %r15
movl 0x4(%r15), %eax
movl %eax, 0x8(%rbx,%r14,4)
movq 0x18(%rbx,%r14,8), %rdi
movl 0x4(%r15), %esi
shlq $0x4, %rsi
callq 0x2330
movq %rax, 0x18(%rbx,%r14,8)
movl (%r15), %eax
testq %rax, %rax
je 0xb640
movq 0x10(%r15), %rdx
movl $0xc, %esi
xorl %edi, %edi
xorl %r8d, %r8d
movl %r8d, %ecx
shrl $0x4, %ecx
movl (%rdx,%rcx,4), %r9d
movl %edi, %ecx
andb $0x1e, %cl
shrl %cl, %r9d
testb $0x3, %r9b
jne 0xb631
movq 0x18(%r15), %rcx
movq 0x20(%r15), %r9
movq (%rcx,%r8,8), %rcx
movq 0x18(%rbx,%r14,8), %r10
addq %rsi, %r9
addq $-0xc, %r9
movslq 0xc(%r9), %r11
shlq $0x4, %r11
movq %rcx, (%r10,%r11)
movq 0x18(%rbx,%r14,8), %rcx
movslq 0xc(%r9), %r10
shlq $0x4, %r10
movq %r9, 0x8(%rcx,%r10)
incq %r8
addq $0x10, %rsi
addl $0x2, %edi
cmpq %r8, %rax
jne 0xb5e3
incq %r14
cmpq $0x3, %r14
jne 0xb5a8
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_hdr_parse
int bcf_hdr_parse(bcf_hdr_t *h)
{
	char *p, *q;
	bcf_hdr_parse1(h, "##FILTER=<ID=PASS,Description=\"All filters passed\">"); // add PASS before anything else
	for (p = q = h->text; q - h->text < h->l_text; ++q) {
		int c;
		if (*q != '\n' && *q != 0) continue;
		c = *q; *q = 0;
		bcf_hdr_parse1(h, p);
		*q = c;
		if (*q == 0) break;
		p = q + 1;
	}
	bcf_hdr_sync(h);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
leaq 0x13c9a(%rip), %rsi     # 0x1f301
callq 0xb132
cmpl $0x0, (%rbx)
jle 0xb6c8
movq 0x48(%rbx), %r15
leaq 0x1(%r15), %r12
movq %r15, %r14
movzbl -0x1(%r12), %ebp
cmpl $0xa, %ebp
je 0xb68b
testl %ebp, %ebp
jne 0xb6ad
movb $0x0, -0x1(%r12)
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb132
movb %bpl, -0x1(%r12)
testb %bpl, %bpl
sete %al
cmovneq %r12, %r14
jmp 0xb6af
xorl %eax, %eax
testb %al, %al
jne 0xb6c8
movslq (%rbx), %rax
incq %r12
incq %r15
movq %r15, %rcx
subq 0x48(%rbx), %rcx
cmpq %rax, %rcx
jl 0xb67c
movq %rbx, %rdi
callq 0xb59d
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_hdr_append
int bcf_hdr_append(bcf_hdr_t *h, const char *line)
{
	int len, i;
	len = strlen(line);
	if (line[len - 1] == '\n') --len;
	if (h->m_text < h->l_text + len + 1) {
		h->m_text = h->l_text + len + 1;
		kroundup32(h->m_text);
		h->text = (char*)realloc(h->text, h->m_text);
	}
	for (i = h->l_text - 1; i >= 0; --i)
		if (h->text[i] == '#' && (i == 0 || h->text[i-1] == '\n'))
			break;
	if (i < 0) return -1; // no #CHROM line
	memmove(&h->text[i+len+1], &h->text[i], h->l_text - i);
	memcpy(&h->text[i], line, len);
	h->text[i+len] = '\n';
	h->l_text += len;
	bcf_hdr_parse1(h, line);
	bcf_hdr_sync(h);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x2170
movq %rax, %r15
decl %eax
cltq
xorl %ecx, %ecx
cmpb $0xa, (%r14,%rax)
sete %cl
subl %ecx, %r15d
movl (%rbx), %eax
addl %r15d, %eax
cmpl %eax, 0x4(%rbx)
jg 0xb746
movl %eax, %ecx
sarl %ecx
orl %eax, %ecx
movl %ecx, %eax
sarl $0x2, %eax
orl %ecx, %eax
movl %eax, %ecx
sarl $0x4, %ecx
orl %eax, %ecx
movl %ecx, %eax
sarl $0x8, %eax
orl %ecx, %eax
movl %eax, %ecx
sarl $0x10, %ecx
orl %eax, %ecx
incl %ecx
movl %ecx, 0x4(%rbx)
movq 0x48(%rbx), %rdi
movslq %ecx, %rsi
callq 0x2330
movq %rax, 0x48(%rbx)
movslq (%rbx), %rax
leal -0x1(%rax), %ecx
testq %rax, %rax
jle 0xb793
movq 0x48(%rbx), %rsi
movl %ecx, %ecx
leaq (%rax,%rsi), %rdi
addq $-0x2, %rdi
addq %rcx, %rsi
xorl %edx, %edx
cmpb $0x23, (%rsi,%rdx)
jne 0xb778
movq %rcx, %r8
addq %rdx, %r8
je 0xb797
cmpb $0xa, (%rdi,%rdx)
je 0xb797
leaq (%rcx,%rdx), %r8
decq %r8
decq %rdx
incq %r8
testq %r8, %r8
jg 0xb764
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
xorl %edi, %edi
jmp 0xb79d
movl %eax, %edi
jmp 0xb79d
addl %edx, %ecx
movl %eax, %edi
addl %edx, %edi
testl %edi, %edi
jle 0xb7f9
movq 0x48(%rbx), %rsi
leal (%rcx,%r15), %ebp
addl %r15d, %edi
movslq %edi, %rdi
addq %rsi, %rdi
movl %ecx, %r12d
addq %r12, %rsi
subl %ecx, %eax
movslq %eax, %rdx
callq 0x2360
addq 0x48(%rbx), %r12
movslq %r15d, %rdx
movq %r12, %rdi
movq %r14, %rsi
callq 0x2280
movq 0x48(%rbx), %rax
movslq %ebp, %rcx
movb $0xa, (%rax,%rcx)
addl %r15d, (%rbx)
movq %rbx, %rdi
movq %r14, %rsi
callq 0xb132
movq %rbx, %rdi
callq 0xb59d
xorl %eax, %eax
jmp 0xb7fe
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_hdr_init
bcf_hdr_t *bcf_hdr_init(void)
{
	int i;
	bcf_hdr_t *h;
	h = (bcf_hdr_t*)calloc(1, sizeof(bcf_hdr_t));
	for (i = 0; i < 3; ++i)
		h->dict[i] = kh_init(vdict);
	return h;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl $0x1, %edi
movl $0x68, %esi
callq 0x2220
movq %rax, %rbx
movl $0x6, %r14d
movl $0x1, %edi
movl $0x28, %esi
callq 0x2220
movq %rax, (%rbx,%r14,8)
incq %r14
cmpq $0x9, %r14
jne 0xb823
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_hdr_destroy
void bcf_hdr_destroy(bcf_hdr_t *h)
{
	int i;
	khint_t k;
	for (i = 0; i < 3; ++i) {
		vdict_t *d = (vdict_t*)h->dict[i];
		if (d == 0) continue;
		for (k = kh_begin(d); k != kh_end(d); ++k)
			if (kh_exist(d, k)) free((char*)kh_key(d, k));
		kh_destroy(vdict, d);
		free(h->id[i]);
	}
	free(h->mem.s); free(h->text);
	free(h);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
xorl %r15d, %r15d
movq 0x30(%rbx,%r15,8), %r14
testq %r14, %r14
je 0xb8cd
cmpl $0x0, (%r14)
je 0xb8a0
xorl %ebp, %ebp
xorl %r12d, %r12d
movq 0x10(%r14), %rax
movl %r12d, %ecx
shrl $0x4, %ecx
movl (%rax,%rcx,4), %eax
movl %ebp, %ecx
andb $0x1e, %cl
shrl %cl, %eax
testb $0x3, %al
jne 0xb895
movq 0x18(%r14), %rax
movl %r12d, %ecx
movq (%rax,%rcx,8), %rdi
callq 0x2050
incl %r12d
addl $0x2, %ebp
cmpl (%r14), %r12d
jne 0xb86d
movq 0x18(%r14), %rdi
callq 0x2050
movq 0x10(%r14), %rdi
callq 0x2050
movq 0x20(%r14), %rdi
callq 0x2050
movq %r14, %rdi
callq 0x2050
movq 0x18(%rbx,%r15,8), %rdi
callq 0x2050
incq %r15
cmpq $0x3, %r15
jne 0xb858
movq 0x60(%rbx), %rdi
callq 0x2050
movq 0x48(%rbx), %rdi
callq 0x2050
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x2050
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_hdr_read
bcf_hdr_t *bcf_hdr_read(BGZF *fp)
{
	uint8_t magic[5];
	bcf_hdr_t *h;
	h = bcf_hdr_init();
	bgzf_read(fp, magic, 5);
	if (strncmp((char*)magic, "BCF\2\2", 5) != 0) {
		if (hts_verbose >= 2)
			fprintf(stderr, "[E::%s] invalid BCF2 magic string\n", __func__);
		bcf_hdr_destroy(h);
		return 0;
	}
	bgzf_read(fp, &h->l_text, 4);
	h->m_text = h->l_text;
	h->text = (char*)malloc(h->l_text);
	bgzf_read(fp, h->text, h->l_text);
	bcf_hdr_parse(h);
	return h;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %r14
callq 0xb807
movq %rax, %rbx
leaq 0xb(%rsp), %r15
movl $0x5, %edx
movq %r14, %rdi
movq %r15, %rsi
callq 0x4a9f
movl $0x2464342, %eax        # imm = 0x2464342
xorl (%r15), %eax
movzbl 0x4(%r15), %ecx
xorl $0x2, %ecx
orl %eax, %ecx
je 0xb94d
leaq 0x1a914(%rip), %rax     # 0x26250
cmpl $0x2, (%rax)
jge 0xb993
movq %rbx, %rdi
callq 0xb84a
xorl %ebx, %ebx
jmp 0xb986
movl $0x4, %edx
movq %r14, %rdi
movq %rbx, %rsi
callq 0x4a9f
movslq (%rbx), %r15
movl %r15d, 0x4(%rbx)
movq %r15, %rdi
callq 0x22e0
movq %rax, 0x48(%rbx)
movq %r14, %rdi
movq %rax, %rsi
movq %r15, %rdx
callq 0x4a9f
movq %rbx, %rdi
callq 0xb655
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
callq 0x2b5b
jmp 0xb941
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_read1_core
static inline int bcf_read1_core(BGZF *fp, bcf1_t *v)
{
	uint32_t x[8];
	int ret;
	if ((ret = bgzf_read(fp, x, 32)) != 32) {
		if (ret == 0) return -1;
		return -2;
	}
	x[0] -= 24; // to exclude six 32-bit integers
	ks_resize(&v->shared, x[0]);
	ks_resize(&v->indiv, x[1]);
	memcpy(v, x + 2, 16);
	v->n_allele = x[6]>>16; v->n_info = x[6]&0xffff;
	v->n_fmt = x[7]>>24; v->n_sample = x[7]&0xffffff;
	v->shared.l = x[0], v->indiv.l = x[1];
	v->unpacked = 0;
	v->unpack_ptr = NULL;
	bgzf_read(fp, v->shared.s, v->shared.l);
	bgzf_read(fp, v->indiv.s, v->indiv.l);
	return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsp, %rsi
movl $0x20, %edx
callq 0x4a9f
testl %eax, %eax
je 0xbbb5
cmpl $0x20, %eax
jne 0xbbbc
movl (%rsp), %eax
addl $-0x18, %eax
movl %eax, (%rsp)
cmpq %rax, 0x20(%r14)
jae 0xbada
decq %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rsi
shrq $0x10, %rsi
orq %rax, %rsi
incq %rsi
movq %rsi, 0x20(%r14)
movq 0x28(%r14), %rdi
callq 0x2330
movq %rax, 0x28(%r14)
movl 0x4(%rsp), %eax
cmpq %rax, 0x38(%r14)
jae 0xbb2c
decq %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rsi
shrq $0x10, %rsi
orq %rax, %rsi
incq %rsi
movq %rsi, 0x38(%r14)
movq 0x40(%r14), %rdi
callq 0x2330
movq %rax, 0x40(%r14)
movups 0x8(%rsp), %xmm0
movups %xmm0, (%r14)
movl 0x18(%rsp), %eax
movl 0x14(%r14), %ecx
shlq $0x20, %rcx
movzwl %ax, %edx
andl $0xffff0000, %eax       # imm = 0xFFFF0000
orq %rcx, %rax
orq %rdx, %rax
movq %rax, 0x10(%r14)
movl 0x1c(%rsp), %ecx
movl %ecx, %edx
shrl $0x18, %edx
shlq $0x20, %rdx
movl %eax, %eax
orq %rdx, %rax
shlq $0x28, %rcx
orq %rax, %rcx
movq %rcx, 0x10(%r14)
movl (%rsp), %edx
movq %rdx, 0x18(%r14)
movl 0x4(%rsp), %eax
movq %rax, 0x30(%r14)
movl $0x0, 0x88(%r14)
movq $0x0, 0x90(%r14)
movq 0x28(%r14), %rsi
movq %rbx, %rdi
callq 0x4a9f
movq 0x30(%r14), %rdx
movq 0x40(%r14), %rsi
movq %rbx, %rdi
callq 0x4a9f
xorl %eax, %eax
jmp 0xbbc1
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xbbc1
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
addq $0x28, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_write1
int bcf_write1(BGZF *fp, const bcf1_t *v)
{
	uint32_t x[8];
	x[0] = v->shared.l + 24; // to include six 32-bit integers
	x[1] = v->indiv.l;
	memcpy(x + 2, v, 16);
	x[6] = (uint32_t)v->n_allele<<16 | v->n_info;
	x[7] = (uint32_t)v->n_fmt<<24 | v->n_sample;
	bgzf_write(fp, x, 32);
	bgzf_write(fp, v->shared.s, v->shared.l);
	bgzf_write(fp, v->indiv.s, v->indiv.l);
	return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movl 0x18(%rsi), %eax
addl $0x18, %eax
movq %rsp, %rsi
movl %eax, (%rsi)
movl 0x30(%r14), %eax
movl %eax, 0x4(%rsi)
movups (%r14), %xmm0
movups %xmm0, 0x8(%rsi)
movq 0x10(%r14), %rax
movl %eax, 0x18(%rsi)
movq %rax, %rcx
shrq $0x8, %rcx
andl $0xff000000, %ecx       # imm = 0xFF000000
shrq $0x28, %rax
orl %ecx, %eax
movl %eax, 0x1c(%rsi)
movl $0x20, %edx
callq 0x4f33
movq 0x18(%r14), %rdx
movq 0x28(%r14), %rsi
movq %rbx, %rdi
callq 0x4f33
movq 0x30(%r14), %rdx
movq 0x40(%r14), %rsi
movq %rbx, %rdi
callq 0x4f33
xorl %eax, %eax
addq $0x28, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: vcf_hdr_write
void vcf_hdr_write(htsFile *fp, const bcf_hdr_t *h)
{
	if (!fp->is_bin) {
		int l = h->l_text;
		while (l && h->text[l-1] == 0) --l; // kill the trailing zeros
		if (l && h->text[l-1] == '\n') --l;
		fwrite(h->text, 1, l, (FILE*)fp->fp);
		fputc('\n', (FILE*)fp->fp);
	} else bcf_hdr_write((BGZF*)fp->fp, h);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
testb $0x1, (%rdi)
jne 0xc319
movslq (%rsi), %rax
testq %rax, %rax
je 0xc323
movq 0x48(%rsi), %rcx
xorl %edx, %edx
movb -0x1(%rcx,%rax), %dil
testb %dil, %dil
jne 0xc327
decq %rax
jne 0xc308
jmp 0xc335
movq 0x38(%rbx), %rdi
popq %rbx
jmp 0xb99a
xorl %edx, %edx
jmp 0xc335
xorl %ecx, %ecx
cmpb $0xa, %dil
sete %cl
subl %ecx, %eax
movslq %eax, %rdx
movq 0x48(%rsi), %rdi
movq 0x38(%rbx), %rcx
movl $0x1, %esi
callq 0x2400
movq 0x38(%rbx), %rsi
movl $0xa, %edi
popq %rbx
jmp 0x21f0
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_fmt_sized_array
uint8_t *bcf_fmt_sized_array(kstring_t *s, uint8_t *ptr)
{
	int x, type;
	x = bcf_dec_size(ptr, &ptr, &type);
	bcf_fmt_array(s, x, type, ptr);
	return ptr + (x << bcf_type_shift[type]);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movzbl (%rsi), %r14d
cmpl $0xef, %r14d
jbe 0xd5f3
movzbl 0x1(%rbx), %eax
andl $0xf, %eax
cmpl $0x2, %eax
je 0xd5fe
cmpl $0x1, %eax
jne 0xd608
movsbl 0x2(%rbx), %ebp
addq $0x3, %rbx
jmp 0xd60f
incq %rbx
movl %r14d, %ebp
shrl $0x4, %ebp
jmp 0xd60f
movswl 0x2(%rbx), %ebp
addq $0x4, %rbx
jmp 0xd60f
movl 0x2(%rbx), %ebp
addq $0x6, %rbx
andl $0xf, %r14d
movl %ebp, %esi
movl %r14d, %edx
movq %rbx, %rcx
callq 0xceac
leaq 0x18d69(%rip), %rax     # 0x26390
movb (%r14,%rax), %cl
shll %cl, %ebp
movslq %ebp, %rax
addq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: vcf_read1
int vcf_read1(htsFile *fp, const bcf_hdr_t *h, bcf1_t *v)
{
	if (!fp->is_bin) {
		int ret;
		ret = hts_getline(fp, KS_SEP_LINE, &fp->line);
		if (ret < 0) return -1;
		ret = vcf_parse1(&fp->line, h, v);
		return 0;
	} else return bcf_read1((BGZF*)fp->fp, v);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
testb $0x1, (%rdi)
jne 0xee9e
movq %rsi, %r14
leaq 0x10(%rdi), %r15
movl $0x2, %esi
movq %r15, %rdx
callq 0x6671
testl %eax, %eax
js 0xeeaf
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0xd638
xorl %eax, %eax
jmp 0xeeb4
movq 0x38(%rdi), %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0xba58
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_unpack_fmt_core
uint8_t *bcf_unpack_fmt_core(uint8_t *ptr, int n_sample, int n_fmt, bcf_fmt_t *fmt)
{
	int i;
	for (i = 0; i < n_fmt; ++i) {
		bcf_fmt_t *f = &fmt[i];
		f->id = bcf_dec_typed_int1(ptr, &ptr);
		f->n = bcf_dec_size(ptr, &ptr, &f->type);
		f->size = f->n << bcf_type_shift[f->type];
		f->p = ptr;
		ptr += n_sample * f->size;
	}
	return ptr;
}

// Assembly:
testl %edx, %edx
jle 0xef8c
movq %rcx, %rax
movl %edx, %ecx
shlq $0x3, %rcx
leaq (%rcx,%rcx,2), %rdx
xorl %r8d, %r8d
leaq 0x174b7(%rip), %r9      # 0x26390
movzbl (%rdi), %ecx
andl $0xf, %ecx
cmpl $0x2, %ecx
je 0xeef3
cmpl $0x1, %ecx
jne 0xeefd
movsbl 0x1(%rdi), %ecx
addq $0x2, %rdi
jmp 0xef04
movswl 0x1(%rdi), %ecx
addq $0x3, %rdi
jmp 0xef04
movl 0x1(%rdi), %ecx
addq $0x5, %rdi
movl %ecx, (%rax,%r8)
movzbl (%rdi), %ecx
andl $0xf, %ecx
movl %ecx, 0x8(%rax,%r8)
movzbl (%rdi), %r10d
cmpl $0xef, %r10d
jbe 0xef40
movzbl 0x1(%rdi), %r10d
andl $0xf, %r10d
cmpl $0x2, %r10d
je 0xef49
cmpl $0x1, %r10d
jne 0xef54
movsbl 0x2(%rdi), %r10d
addq $0x3, %rdi
jmp 0xef5c
incq %rdi
shrl $0x4, %r10d
jmp 0xef5c
movswl 0x2(%rdi), %r10d
addq $0x4, %rdi
jmp 0xef5c
movl 0x2(%rdi), %r10d
addq $0x6, %rdi
movq %rdi, %r11
movl %r10d, 0x4(%rax,%r8)
movb (%rcx,%r9), %cl
shll %cl, %r10d
movl %r10d, 0xc(%rax,%r8)
movq %rdi, 0x10(%rax,%r8)
imull %esi, %r10d
movslq %r10d, %rdi
addq %r11, %rdi
addq $0x18, %r8
cmpq %r8, %rdx
jne 0xeed9
movq %rdi, %rax
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_unpack_info_core
uint8_t *bcf_unpack_info_core(uint8_t *ptr, int n_info, bcf_info_t *info)
{
	int i;
	for (i = 0; i < n_info; ++i) {
		bcf_info_t *z = &info[i];
		z->key = bcf_dec_typed_int1(ptr, &ptr);
		z->len = bcf_dec_size(ptr, &ptr, &z->type);
		z->vptr = ptr;
		z->v1.i = 0;
		if (z->len == 1) {
			if (z->type == BCF_BT_INT8 || z->type == BCF_BT_CHAR) z->v1.i = *(int8_t*)ptr;
			else if (z->type == BCF_BT_INT32) z->v1.i = *(int32_t*)ptr;
			else if (z->type == BCF_BT_FLOAT) z->v1.f = *(float*)ptr;
			else if (z->type == BCF_BT_INT16) z->v1.i = *(int16_t*)ptr;
		}
		ptr += z->len << bcf_type_shift[z->type];
	}
	return ptr;
}

// Assembly:
movq %rdi, %rax
testl %esi, %esi
jle 0xf0a3
movl %esi, %ecx
shlq $0x3, %rcx
leaq (%rcx,%rcx,2), %rsi
xorl %edi, %edi
leaq 0x1022e(%rip), %r8      # 0x1f1dc
leaq 0x173db(%rip), %r9      # 0x26390
movzbl (%rax), %ecx
andl $0xf, %ecx
cmpl $0x2, %ecx
je 0xefcf
cmpl $0x1, %ecx
jne 0xefd9
movsbl 0x1(%rax), %ecx
addq $0x2, %rax
jmp 0xefe0
movswl 0x1(%rax), %ecx
addq $0x3, %rax
jmp 0xefe0
movl 0x1(%rax), %ecx
addq $0x5, %rax
movl %ecx, (%rdx,%rdi)
movzbl (%rax), %ecx
andl $0xf, %ecx
movl %ecx, 0x4(%rdx,%rdi)
movzbl (%rax), %r10d
cmpl $0xef, %r10d
jbe 0xf01a
movzbl 0x1(%rax), %r10d
andl $0xf, %r10d
cmpl $0x2, %r10d
je 0xf023
cmpl $0x1, %r10d
jne 0xf02e
movsbl 0x2(%rax), %r10d
addq $0x3, %rax
jmp 0xf036
incq %rax
shrl $0x4, %r10d
jmp 0xf036
movswl 0x2(%rax), %r10d
addq $0x4, %rax
jmp 0xf036
movl 0x2(%rax), %r10d
addq $0x6, %rax
movl %r10d, 0x8(%rdx,%rdi)
movq %rax, 0x10(%rdx,%rdi)
movl $0x0, 0xc(%rdx,%rdi)
cmpl $0x1, %r10d
jne 0xf071
movzbl %cl, %ecx
decl %ecx
cmpl $0x6, %ecx
ja 0xf071
movslq (%r8,%rcx,4), %rcx
addq %r8, %rcx
jmpq *%rcx
movsbl (%rax), %ecx
jmp 0xf06d
movswl (%rax), %ecx
jmp 0xf06d
movl (%rax), %ecx
movl %ecx, 0xc(%rdx,%rdi)
movl 0x8(%rdx,%rdi), %r10d
movslq 0x4(%rdx,%rdi), %rcx
movb (%rcx,%r9), %cl
shll %cl, %r10d
movslq %r10d, %rcx
addq %rcx, %rax
addq $0x18, %rdi
cmpq %rdi, %rsi
jne 0xefb5
jmp 0xf0a3
movss (%rax), %xmm0
movss %xmm0, 0xc(%rdx,%rdi)
jmp 0xf071
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: vcf_write1
int vcf_write1(htsFile *fp, const bcf_hdr_t *h, const bcf1_t *v)
{
	if (!fp->is_bin) {
		vcf_format1(h, v, &fp->line);
		fwrite(fp->line.s, 1, fp->line.l, (FILE*)fp->fp);
		fputc('\n', (FILE*)fp->fp);
	} else return bcf_write1((BGZF*)fp->fp, v);
	return 0;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
testb $0x1, (%rdi)
jne 0x106ce
leaq 0x10(%rbx), %rax
movq %rsi, %rdi
movq %rdx, %rsi
movq %rax, %rdx
callq 0xf529
movq 0x10(%rbx), %rdx
movq 0x20(%rbx), %rdi
movq 0x38(%rbx), %rcx
movl $0x1, %esi
callq 0x2400
movq 0x38(%rbx), %rsi
movl $0xa, %edi
callq 0x21f0
jmp 0x106da
movq 0x38(%rbx), %rdi
movq %rdx, %rsi
callq 0xbc0d
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_id2int
int bcf_id2int(const bcf_hdr_t *h, int which, const char *id)
{
	khint_t k;
	vdict_t *d = (vdict_t*)h->dict[which];
	k = kh_get(vdict, d, id);
	return k == kh_end(d)? -1 : kh_val(d, k).id;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movslq %esi, %rax
movq 0x30(%rdi,%rax,8), %rax
movq %rax, 0x8(%rsp)
movl (%rax), %ecx
testl %ecx, %ecx
je 0x10739
movq %rdx, %rbx
leal -0x1(%rcx), %esi
movsbl (%rdx), %r13d
testl %r13d, %r13d
movq %rcx, 0x18(%rsp)
je 0x10741
movb 0x1(%rbx), %al
testb %al, %al
je 0x10744
leaq 0x2(%rbx), %rcx
movl %r13d, %edx
shll $0x5, %edx
subl %r13d, %edx
movsbl %al, %r13d
addl %edx, %r13d
movb (%rcx), %al
incq %rcx
testb %al, %al
jne 0x1071e
jmp 0x10744
xorl %r15d, %r15d
jmp 0x107df
xorl %r13d, %r13d
movl %r13d, %r14d
andl %esi, %r14d
movl %r13d, %eax
shrl $0x3, %eax
shll $0x3, %r13d
xorl %eax, %r13d
orl $0x1, %r13d
andl %esi, %r13d
movq 0x8(%rsp), %rax
movq 0x10(%rax), %rdi
movl %r14d, %r15d
movl %esi, 0x14(%rsp)
movq %rdi, 0x20(%rsp)
movl %r15d, %eax
shrl $0x4, %eax
movl (%rdi,%rax,4), %r12d
leal (%r15,%r15), %ebp
andl $0x1e, %ebp
movl %r12d, %eax
movl %ebp, %ecx
shrl %cl, %eax
testb $0x2, %al
jne 0x107cd
testb $0x1, %al
jne 0x107b8
movq 0x8(%rsp), %rax
movq 0x18(%rax), %rax
movl %r15d, %ecx
movq (%rax,%rcx,8), %rdi
movq %rbx, %rsi
callq 0x2230
movq 0x20(%rsp), %rdi
movl 0x14(%rsp), %esi
testl %eax, %eax
je 0x107cd
addl %r13d, %r15d
andl %esi, %r15d
cmpl %r14d, %r15d
jne 0x10773
movq 0x18(%rsp), %rcx
movl %ecx, %r15d
jmp 0x107df
movl %ebp, %ecx
shrl %cl, %r12d
testb $0x3, %r12b
movq 0x18(%rsp), %rcx
cmovnel %ecx, %r15d
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpl %ecx, %r15d
je 0x107fd
movq 0x8(%rsp), %rax
movq 0x20(%rax), %rax
movl %r15d, %ecx
shlq $0x4, %rcx
movl 0xc(%rax,%rcx), %eax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_index
hts_idx_t *bcf_index(BGZF *fp, int min_shift)
{
	int n_lvls, i;
	bcf1_t *b;
	hts_idx_t *idx;
	bcf_hdr_t *h;
	int64_t max_len = 0, s;
	h = bcf_hdr_read(fp);
	for (i = 0; i < h->n[BCF_DT_CTG]; ++i)
		if (max_len < h->id[BCF_DT_CTG][i].val->info[0])
			max_len = h->id[BCF_DT_CTG][i].val->info[0];
	max_len += 256;
	for (n_lvls = 0, s = 1<<min_shift; max_len > s; ++n_lvls, s <<= 3);
	idx = hts_idx_init(h->n[BCF_DT_CTG], HTS_FMT_CSI, bgzf_tell(fp), min_shift, n_lvls);
	bcf_hdr_destroy(h);
	b = bcf_init1();
	while (bcf_read1(fp, b) >= 0) {
		int ret;
		ret = hts_idx_push(idx, b->rid, b->pos, b->pos + b->rlen, bgzf_tell(fp), 1);
		if (ret < 0) break;
	}
	hts_idx_finish(idx, bgzf_tell(fp));
	bcf_destroy1(b);
	return idx;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0xb8f8
movq %rax, %r14
movslq 0xc(%rax), %rdi
testq %rdi, %rdi
jle 0x10867
movq 0x20(%r14), %rcx
movq %rdi, %rdx
shlq $0x4, %rdx
xorl %esi, %esi
xorl %eax, %eax
movq %rax, %r8
movq 0x8(%rcx,%rsi), %rax
movl (%rax), %eax
cmpq %rax, %r8
cmovgq %r8, %rax
addq $0x10, %rsi
cmpq %rsi, %rdx
jne 0x10845
addq $0x100, %rax            # imm = 0x100
jmp 0x1086c
movl $0x100, %eax            # imm = 0x100
movl $0x1, %edx
movl %ebp, %ecx
shll %cl, %edx
movslq %edx, %rcx
xorl %r8d, %r8d
cmpq %rcx, %rax
jle 0x1088f
xorl %r8d, %r8d
incl %r8d
shlq $0x3, %rcx
cmpq %rcx, %rax
jg 0x10883
movq 0x10(%rbx), %rax
shlq $0x10, %rax
movzwl 0xc(%rbx), %edx
orq %rax, %rdx
xorl %esi, %esi
movl %ebp, %ecx
callq 0x6caf
movq %rax, %r15
movq %r14, %rdi
callq 0xb84a
movl $0x1, %edi
movl $0x98, %esi
callq 0x2220
movq %rax, %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0xba58
testl %eax, %eax
js 0x10902
movl (%r14), %esi
movl 0x4(%r14), %edx
movl 0x8(%r14), %ecx
addl %edx, %ecx
movq 0x10(%rbx), %rax
shlq $0x10, %rax
movzwl 0xc(%rbx), %r8d
orq %rax, %r8
movq %r15, %rdi
movl $0x1, %r9d
callq 0x75b6
testl %eax, %eax
jns 0x108c4
movq 0x10(%rbx), %rax
shlq $0x10, %rax
movzwl 0xc(%rbx), %esi
orq %rax, %rsi
movq %r15, %rdi
callq 0x6d87
movq %r14, %rdi
callq 0xb9ea
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_index_build
int bcf_index_build(const char *fn, int min_shift)
{
	BGZF *fp;
	hts_idx_t *idx;
	if ((fp = bgzf_open(fn, "r")) == 0) return -1;
	idx = bcf_index(fp, min_shift);
	bgzf_close(fp);
	hts_idx_save(idx, fn, HTS_FMT_CSI);
	hts_idx_destroy(idx);
	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
leaq 0xe8f9(%rip), %rsi      # 0x1f23b
callq 0x434c
testq %rax, %rax
je 0x1097d
movq %rax, %r14
movq %rax, %rdi
movl %ebp, %esi
callq 0x10819
movq %rax, %r15
movq %r14, %rdi
callq 0x5040
xorl %ebp, %ebp
movq %r15, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x7c89
movq %r15, %rdi
callq 0x7b9b
jmp 0x10982
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/lh3[P]bgt/vcf.c
// Function: bcf_is_snp
int bcf_is_snp(bcf1_t *v)
{
	int i;
	bcf_unpack(v, BCF_UN_STR);
	for (i = 0; i < v->n_allele; ++i)
		if (strlen(v->d.allele[i]) != 1) break;
	return i == v->n_allele;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movl $0x1, %esi
callq 0xf0a4
movl 0x10(%rbx), %eax
movl %eax, %ebp
shrl $0x10, %ebp
xorl %r14d, %r14d
cmpl $0x10000, %eax          # imm = 0x10000
jb 0x10ef3
movq 0x68(%rbx), %rbx
cmpl $0x1, %ebp
movl %ebp, %r14d
adcl $0x0, %r14d
xorl %r15d, %r15d
movq (%rbx,%r15,8), %rdi
callq 0x2170
cmpq $0x1, %rax
jne 0x10ef0
incq %r15
cmpq %r15, %r14
jne 0x10ed7
jmp 0x10ef3
movl %r15d, %r14d
xorl %eax, %eax
cmpl %ebp, %r14d
sete %al
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq