// File: /workspace/github_cpp_makefile_star2_O3/manschga[P]M5GB/lab_poly.cpp
// Function: spair(Lab_poly const&, Lab_poly const&)
pair<Lab_poly,Lab_poly> spair(const Lab_poly& F, const Lab_poly& G)
{
  #ifdef Null
  cout << "Spair construction: " << endl;
  cout << "F: " << F << endl;
  cout << "G: " << G << endl;
  #endif
  pair<int,vector<int>> u,v;
  //  monomial u,v;
  lcm(u,F.Get_LM(),v,G.Get_LM());
  //for case p = 2 works, else need coeff!
  #ifdef Null
  cout << "uF: " << F.Multiply(u.second).Multiply(u.first,true);
  cout << "vG:"  << G.Multiply(v.second).Multiply(v.first,true);
  #endif
  return make_pair(F.Multiply(u.second).Multiply(u.first,true),G.Multiply(v.second).Multiply(v.first,true));
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x130, %rsp            # imm = 0x130
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
xorl %eax, %eax
leaq 0x20(%rsp), %rdi
movl %eax, (%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rdi)
movq %rax, 0x18(%rdi)
movq %rsp, %rdx
movl %eax, (%rdx)
movups %xmm0, 0x8(%rdx)
movq %rax, 0x18(%rdx)
movq (%rsi), %rsi
movq (%r14), %rcx
callq 0x10a5e
leaq 0x28(%rsp), %rdx
leaq 0xf8(%rsp), %rdi
movq %r15, %rsi
callq 0x63c4
movl 0x20(%rsp), %edx
leaq 0x40(%rsp), %rdi
leaq 0xf8(%rsp), %rsi
movl $0x1, %ecx
callq 0x6442
leaq 0x8(%rsp), %rdx
leaq 0xc0(%rsp), %rdi
movq %r14, %rsi
callq 0x63c4
movl (%rsp), %edx
leaq 0x80(%rsp), %rdi
leaq 0xc0(%rsp), %rsi
movl $0x1, %ecx
callq 0x6442
movaps 0x40(%rsp), %xmm0
movups %xmm0, (%rbx)
movq 0x50(%rsp), %rax
movq %rax, 0x10(%rbx)
xorl %eax, %eax
movq %rax, 0x50(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x40(%rsp)
movl 0x58(%rsp), %ecx
movl %ecx, 0x18(%rbx)
movl 0x70(%rsp), %ecx
movl %ecx, 0x30(%rbx)
movaps 0x60(%rsp), %xmm1
movups %xmm1, 0x20(%rbx)
movaps 0x80(%rsp), %xmm1
movups %xmm1, 0x38(%rbx)
movq 0x90(%rsp), %rcx
movq %rcx, 0x48(%rbx)
movq %rax, 0x90(%rsp)
movaps %xmm0, 0x80(%rsp)
movl 0x98(%rsp), %eax
movl %eax, 0x50(%rbx)
movl 0xb0(%rsp), %eax
movl %eax, 0x68(%rbx)
movaps 0xa0(%rsp), %xmm0
movups %xmm0, 0x58(%rbx)
movq 0xc0(%rsp), %rdi
testq %rdi, %rdi
je 0x5543
movq 0xd0(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x5543
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq 0xf8(%rsp), %rdi
testq %rdi, %rdi
je 0x5560
movq 0x108(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x5577
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x558e
movq 0x38(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq %rbx, %rax
addq $0x130, %rsp            # imm = 0x130
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq 0xc0(%rsp), %rdi
testq %rdi, %rdi
je 0x55c3
movq 0xd0(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
jmp 0x55c3
movq %rax, %rbx
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x55df
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
jmp 0x55df
movq %rax, %rbx
movq 0xf8(%rsp), %rdi
testq %rdi, %rdi
je 0x5603
movq 0x108(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
jmp 0x5603
jmp 0x5600
movq %rax, %rbx
movq 0x8(%rsp), %rdi
testq %rdi, %rdi
je 0x561a
movq 0x18(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq 0x28(%rsp), %rdi
testq %rdi, %rdi
je 0x5631
movq 0x38(%rsp), %rsi
subq %rdi, %rsi
callq 0x2180
movq %rbx, %rdi
callq 0x2240