// File: /workspace/github_cpp_makefile_star2_O1/marxn[P]pupp/3rdparty/gmp/mpn/mul_fft.c
// Function: mpn_mul_fft_decompose
static void
mpn_mul_fft_decompose (mp_ptr A, mp_ptr *Ap, mp_size_t K, mp_size_t nprime,
		       mp_srcptr n, mp_size_t nl, mp_size_t l, mp_size_t Mp,
		       mp_ptr T)
{
  mp_size_t i, j;
  mp_ptr tmp;
  mp_size_t Kl = K * l;
  TMP_DECL;
  TMP_MARK;

  if (nl > Kl) /* normalize {n, nl} mod 2^(Kl*GMP_NUMB_BITS)+1 */
    {
      mp_size_t dif = nl - Kl;
      mp_limb_signed_t cy;

      tmp = TMP_BALLOC_LIMBS(Kl + 1);

      if (dif > Kl)
	{
	  int subp = 0;

	  cy = mpn_sub_n (tmp, n, n + Kl, Kl);
	  n += 2 * Kl;
	  dif -= Kl;

	  /* now dif > 0 */
	  while (dif > Kl)
	    {
	      if (subp)
		cy += mpn_sub_n (tmp, tmp, n, Kl);
	      else
		cy -= mpn_add_n (tmp, tmp, n, Kl);
	      subp ^= 1;
	      n += Kl;
	      dif -= Kl;
	    }
	  /* now dif <= Kl */
	  if (subp)
	    cy += mpn_sub (tmp, tmp, Kl, n, dif);
	  else
	    cy -= mpn_add (tmp, tmp, Kl, n, dif);
	  if (cy >= 0)
	    cy = mpn_add_1 (tmp, tmp, Kl, cy);
	  else
	    cy = mpn_sub_1 (tmp, tmp, Kl, -cy);
	}
      else /* dif <= Kl, i.e. nl <= 2 * Kl */
	{
	  cy = mpn_sub (tmp, n, Kl, n + Kl, dif);
	  cy = mpn_add_1 (tmp, tmp, Kl, cy);
	}
      tmp[Kl] = cy;
      nl = Kl + 1;
      n = tmp;
    }
  for (i = 0; i < K; i++)
    {
      Ap[i] = A;
      /* store the next M bits of n into A[0..nprime] */
      if (nl > 0) /* nl is the number of remaining limbs */
	{
	  j = (l <= nl && i < K - 1) ? l : nl; /* store j next limbs */
	  nl -= j;
	  MPN_COPY (T, n, j);
	  MPN_ZERO (T + j, nprime + 1 - j);
	  n += l;
	  mpn_fft_mul_2exp_modF (A, T, i * Mp, nprime);
	}
      else
	MPN_ZERO (A, nprime + 1);
      A += nprime + 1;
    }
  ASSERT_ALWAYS (nl == 0);
  TMP_FREE;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %r8, %rbp
movq %rcx, 0x28(%rsp)
movq %rsi, 0x40(%rsp)
movq 0x80(%rsp), %rax
imulq %rdx, %rax
movq $0x0, 0x30(%rsp)
movq %r9, %r14
subq %rax, %r14
movq %rdx, 0x18(%rsp)
jle 0x30c13
movq %rdi, %r12
leaq 0x8(,%rax,8), %rsi
leaq 0x30(%rsp), %rdi
movq %rax, 0x8(%rsp)
callq 0x30170
movq 0x8(%rsp), %rcx
movq %rax, %r13
movq %r14, %r15
subq %rcx, %r15
jle 0x30c21
leaq (,%rcx,8), %rdx
addq %rbp, %rdx
movq %r13, %rdi
movq %rbp, %rsi
callq 0x1c1c0
movq 0x8(%rsp), %rcx
movq %rax, %rbx
movq %rbp, %rax
movq %rcx, %rbp
shlq $0x4, %rbp
addq %rax, %rbp
movb $0x1, %al
cmpq %rcx, %r15
jle 0x30bc8
leaq (,%rcx,8), %rax
movq %rax, 0x20(%rsp)
xorl %eax, %eax
movq %r13, 0x10(%rsp)
movl %eax, %r14d
movq %r13, %rdi
movq %r13, %rsi
movq %rbp, %rdx
movq %rcx, %r13
testl %eax, %eax
je 0x30b9e
callq 0x1c1c0
addq %rax, %rbx
jmp 0x30ba6
callq 0x1bfa0
subq %rax, %rbx
movl %r14d, %eax
xorl $0x1, %eax
subq %r13, %r15
addq 0x20(%rsp), %rbp
cmpq %r13, %r15
movq %r13, %rcx
movq 0x10(%rsp), %r13
jg 0x30b81
cmpl $0x1, %r14d
sete %al
testb %al, %al
je 0x30c74
testq %r15, %r15
je 0x30cbd
movq %r13, %rdi
movq %r13, %rsi
movq %rbp, %rdx
movq %r15, %rcx
callq 0x1bfa0
testq %rax, %rax
je 0x30d47
xorl %eax, %eax
movq 0x8(%rsp), %rcx
cmpq %rcx, %r15
jge 0x30d57
incq (%r13,%r15,8)
leaq 0x1(%r15), %r15
je 0x30bfa
jmp 0x30d65
movq %r9, %rbx
movq %rdx, %r15
movq %rbp, %r13
jmp 0x30dea
testq %r14, %r14
je 0x30cb4
leaq (,%rcx,8), %rdx
addq %rbp, %rdx
movq %r13, %rdi
movq %rbp, %rsi
movq %r14, %rcx
callq 0x1c1c0
testq %rax, %rax
movq 0x18(%rsp), %r15
je 0x30cc4
movq 0x8(%rsp), %rcx
cmpq %rcx, %r14
jge 0x30d50
movq (%rbp,%r14,8), %rdx
leaq 0x1(%r14), %rax
subq $0x1, %rdx
movq %rdx, (%r13,%r14,8)
movq %rax, %r14
jb 0x30c52
jmp 0x30ccc
testq %r15, %r15
je 0x30cbd
movq %r13, %rdi
movq %r13, %rsi
movq %rbp, %rdx
movq %r15, %rcx
callq 0x1c1c0
testq %rax, %rax
je 0x30d47
xorl %eax, %eax
movq 0x8(%rsp), %rcx
cmpq %rcx, %r15
jge 0x30d60
subq $0x1, (%r13,%r15,8)
leaq 0x1(%r15), %r15
jb 0x30c9a
jmp 0x30d65
xorl %eax, %eax
movq 0x18(%rsp), %r15
jmp 0x30ccc
xorl %eax, %eax
jmp 0x30d65
movq %r14, %rax
movq 0x8(%rsp), %rcx
cmpq %rbp, %r13
setne %sil
cmpq %rcx, %rax
setl %dl
andb %sil, %dl
cmpb $0x1, %dl
jne 0x30d0b
leaq (,%rax,8), %rdi
addq %r13, %rdi
leaq (,%rax,8), %rsi
addq %rbp, %rsi
movq %rcx, %rdx
subq %rax, %rdx
shlq $0x3, %rdx
callq 0x6200
movq 0x8(%rsp), %rcx
xorl %eax, %eax
addq %rax, (%r13)
jae 0x30dda
cmpq $0x2, %rcx
movl $0x1, %eax
movl $0x1, %esi
cmovgeq %rcx, %rsi
movl $0x1, %edx
cmpq %rdx, %rsi
je 0x30ddc
incq (%r13,%rdx,8)
leaq 0x1(%rdx), %rdx
je 0x30d2e
jmp 0x30dda
xorl %eax, %eax
movq 0x8(%rsp), %rcx
jmp 0x30d65
movl $0x1, %eax
jmp 0x30d0d
movq $-0x1, %rax
jmp 0x30d65
movl $0x1, %eax
addq %rbx, %rax
movq 0x18(%rsp), %r15
js 0x30d9e
addq %rax, (%r13)
jae 0x30dda
cmpq $0x2, %rcx
movl $0x1, %eax
movl $0x1, %esi
cmovgeq %rcx, %rsi
movl $0x1, %edx
cmpq %rdx, %rsi
je 0x30ddc
incq (%r13,%rdx,8)
leaq 0x1(%rdx), %rdx
je 0x30d8c
jmp 0x30dda
movq (%r13), %rsi
leaq (%rsi,%rax), %rdx
negq %rax
movq %rdx, (%r13)
cmpq %rax, %rsi
jae 0x30dda
cmpq $0x2, %rcx
movl $0x1, %eax
movl $0x1, %esi
cmovgeq %rcx, %rsi
movl $0x1, %edx
cmpq %rdx, %rsi
je 0x30ddc
subq $0x1, (%r13,%rdx,8)
leaq 0x1(%rdx), %rdx
jb 0x30dc9
xorl %eax, %eax
movq %r12, %rdi
movq %rax, (%r13,%rcx,8)
incq %rcx
movq %rcx, %rbx
testq %r15, %r15
jle 0x30ee8
movq %r13, 0x10(%rsp)
movq 0x90(%rsp), %r12
leaq -0x1(%r15), %rax
movq %rax, 0x8(%rsp)
movq 0x28(%rsp), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0x38(%rsp)
leaq 0x8(,%rax,8), %rax
movq %rax, 0x20(%rsp)
xorl %r14d, %r14d
xorl %r13d, %r13d
movq 0x40(%rsp), %rax
movq %rdi, (%rax,%r13,8)
testq %rbx, %rbx
jle 0x30eb5
movq %rdi, %rbp
cmpq 0x8(%rsp), %r13
movq %rbx, %r15
movq 0x80(%rsp), %rax
cmovlq %rax, %r15
cmpq %rax, %rbx
cmovlq %rbx, %r15
movq %r12, %rdi
movq 0x10(%rsp), %rsi
movq %r15, %rdx
callq 0x2f4c6
movq 0x38(%rsp), %rdx
subq %r15, %rdx
je 0x30e7f
leaq (%r12,%r15,8), %rdi
shlq $0x3, %rdx
xorl %esi, %esi
callq 0x6170
subq %r15, %rbx
movq 0x80(%rsp), %rax
movq 0x10(%rsp), %rcx
leaq (%rcx,%rax,8), %rcx
movq %rcx, 0x10(%rsp)
movq %rbp, %rdi
movq %r12, %rsi
movq %r14, %rdx
movq 0x28(%rsp), %rcx
callq 0x31d86
movq %rbp, %rdi
movq 0x18(%rsp), %r15
jmp 0x30ecf
cmpq $-0x1, 0x28(%rsp)
je 0x30ecf
xorl %esi, %esi
movq %rdi, %rbp
movq 0x20(%rsp), %rdx
callq 0x6170
movq %rbp, %rdi
incq %r13
addq 0x20(%rsp), %rdi
addq 0x88(%rsp), %r14
cmpq %r13, %r15
jne 0x30e2a
testq %rbx, %rbx
jne 0x30f06
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
jne 0x30f0b
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x7579
callq 0x301a3
jmp 0x30ef7