// File: redpony[P]cpyp/./cpyp/crp.h
// Function: cpyp::crp<int, std::hash<int>>::check_hyperparameters()
void check_hyperparameters() {
    if (discount_ < 0.0 || discount_ >= 1.0) {
      std::cerr << "Bad discount: " << discount_ << std::endl;
      abort();
    }
    if (strength_ <= -discount_) {
      std::cerr << "Bad strength: " << strength_ << " (discount="
                << discount_ << ")" << std::endl;
      abort();
    }

    if (discount_) {
      llh_ = lgamma(strength_) - lgamma(strength_ / discount_);
      if (has_discount_prior()) {
        llh_ = Md::log_beta_density(discount_,
                                    discount_prior_strength_,
                                    discount_prior_beta_);
      }
      if (has_strength_prior()) {
        llh_ += Md::log_gamma_density(
            strength_ + discount_,
            strength_prior_shape_,
            strength_prior_rate_);
      }
      if (num_tables_ > 0) {
        llh_ = log_likelihood(discount_, strength_);
      }
    } else {
      llh_ = lgamma(strength_);
      if (has_strength_prior()) {
        llh_ += Md::log_gamma_density(
            strength_, strength_prior_shape_, strength_prior_rate_);
      }
      if (num_tables_ > 0) {
        llh_ = log_likelihood(discount_, strength_);
      }
    }
  }

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
xorps %xmm0, %xmm0
ucomisd 0x40(%rax), %xmm0
ja 0xbed5
movq 0x10(%rsp), %rax
movsd 0x40(%rax), %xmm0
movsd 0x9141(%rip), %xmm1     # 0x15010
ucomisd %xmm1, %xmm0
jb 0xbf0e
movq 0x12114(%rip), %rdi     # 0x1dff0
leaq 0x98bc(%rip), %rsi      # 0x1579f
callq 0x2180
movq %rax, %rdi
movq 0x10(%rsp), %rax
movsd 0x40(%rax), %xmm0
callq 0x2290
movq %rax, %rdi
movq 0x120c4(%rip), %rsi     # 0x1dfc8
callq 0x21a0
callq 0x20d0
movq 0x10(%rsp), %rax
movsd 0x48(%rax), %xmm1
movsd 0x40(%rax), %xmm0
movq %xmm0, %rax
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
xorq %rcx, %rax
movq %rax, %xmm0
ucomisd %xmm1, %xmm0
jb 0xbfa3
movq 0x120af(%rip), %rdi     # 0x1dff0
leaq 0x9866(%rip), %rsi      # 0x157ae
callq 0x2180
movq %rax, %rdi
movq 0x10(%rsp), %rax
movsd 0x48(%rax), %xmm0
callq 0x2290
movq %rax, %rdi
leaq 0x9854(%rip), %rsi      # 0x157bd
callq 0x2180
movq %rax, %rdi
movq 0x10(%rsp), %rax
movsd 0x40(%rax), %xmm0
callq 0x2290
movq %rax, %rdi
leaq 0x94d8(%rip), %rsi      # 0x15462
callq 0x2180
movq %rax, %rdi
movq 0x1202f(%rip), %rsi     # 0x1dfc8
callq 0x21a0
callq 0x20d0
movq 0x10(%rsp), %rax
movsd 0x40(%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0xbfbd
jp 0xbfbd
jmp 0xc0a5
movq 0x10(%rsp), %rax
movsd 0x48(%rax), %xmm0
callq 0x2110
movq 0x10(%rsp), %rax
movsd %xmm0, 0x8(%rsp)
movsd 0x48(%rax), %xmm0
divsd 0x40(%rax), %xmm0
callq 0x2110
movq 0x10(%rsp), %rdi
movaps %xmm0, %xmm1
movsd 0x8(%rsp), %xmm0
subsd %xmm1, %xmm0
movsd %xmm0, 0x70(%rdi)
callq 0xa780
testb $0x1, %al
jne 0xc008
jmp 0xc02e
movq 0x10(%rsp), %rdx
movq %rdx, %rdi
addq $0x40, %rdi
movq %rdx, %rsi
addq $0x50, %rsi
addq $0x58, %rdx
callq 0xa7a0
movq 0x10(%rsp), %rax
movsd %xmm0, 0x70(%rax)
movq 0x10(%rsp), %rdi
callq 0xa930
testb $0x1, %al
jne 0xc03e
jmp 0xc077
movq 0x10(%rsp), %rdx
movsd 0x48(%rdx), %xmm0
addsd 0x40(%rdx), %xmm0
movsd %xmm0, 0x18(%rsp)
movq %rdx, %rsi
addq $0x60, %rsi
addq $0x68, %rdx
leaq 0x18(%rsp), %rdi
callq 0xa950
movq 0x10(%rsp), %rax
addsd 0x70(%rax), %xmm0
movsd %xmm0, 0x70(%rax)
movq 0x10(%rsp), %rax
cmpl $0x0, (%rax)
jbe 0xc0a3
movq 0x10(%rsp), %rdi
movq %rdi, %rsi
addq $0x40, %rsi
movq %rdi, %rdx
addq $0x48, %rdx
callq 0xa0e0
movq 0x10(%rsp), %rax
movsd %xmm0, 0x70(%rax)
jmp 0xc122
movq 0x10(%rsp), %rax
movsd 0x48(%rax), %xmm0
callq 0x2110
movq 0x10(%rsp), %rdi
movsd %xmm0, 0x70(%rdi)
callq 0xa930
testb $0x1, %al
jne 0xc0c9
jmp 0xc0f4
movq 0x10(%rsp), %rdx
movq %rdx, %rdi
addq $0x48, %rdi
movq %rdx, %rsi
addq $0x60, %rsi
addq $0x68, %rdx
callq 0xa950
movq 0x10(%rsp), %rax
addsd 0x70(%rax), %xmm0
movsd %xmm0, 0x70(%rax)
movq 0x10(%rsp), %rax
cmpl $0x0, (%rax)
jbe 0xc120
movq 0x10(%rsp), %rdi
movq %rdi, %rsi
addq $0x40, %rsi
movq %rdi, %rdx
addq $0x48, %rdx
callq 0xa0e0
movq 0x10(%rsp), %rax
movsd %xmm0, 0x70(%rax)
jmp 0xc122
addq $0x28, %rsp
retq
nopw (%rax,%rax)