// File: /workspace/github_c_makefile_star2_O0/theck01[P]offbrand_lib/src/classes/obdeque.c
// Function: obdeque_compare
int8_t obdeque_compare(const obj *a, const obj *b){

  int8_t retval = OB_EQUAL_TO; /* assume equality and disprove if not */
  const obdeque *comp_a = (obdeque *)a;
  const obdeque *comp_b = (obdeque *)b;
  obdeque_iterator *a_it, *b_it;

  assert(a);
  assert(b);
  assert(ob_has_class(a, "obdeque"));
  assert(ob_has_class(b, "obdeque"));

  if(comp_a->length != comp_b->length) return OB_NOT_EQUAL;

  a_it = obdeque_head_iterator(comp_a);
  b_it = obdeque_head_iterator(comp_b);

  if(!a_it && !b_it) return OB_EQUAL_TO;

  if(a_it && b_it){
    do{
      if(ob_compare(obdeque_obj_at_iterator(comp_a, a_it),
                    obdeque_obj_at_iterator(comp_b, b_it)) !=
       OB_EQUAL_TO){
      retval = OB_NOT_EQUAL;
      break;
    }
    }while(obdeque_iterate_next(comp_a, a_it) &&
           obdeque_iterate_next(comp_b, b_it));
  }
  else retval = OB_NOT_EQUAL;

  ob_release((obj *)a_it);
  ob_release((obj *)b_it);

  return retval;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movb $0x0, -0x19(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x360d
jmp 0x362c
leaq 0x2682(%rip), %rdi      # 0x5c96
leaq 0x1fe6(%rip), %rsi      # 0x5601
movl $0x290, %edx            # imm = 0x290
leaq 0x2671(%rip), %rcx      # 0x5c98
callq 0x1050
cmpq $0x0, -0x18(%rbp)
je 0x3635
jmp 0x3654
leaq 0x268d(%rip), %rdi      # 0x5cc9
leaq 0x1fbe(%rip), %rsi      # 0x5601
movl $0x291, %edx            # imm = 0x291
leaq 0x2649(%rip), %rcx      # 0x5c98
callq 0x1050
movq -0x10(%rbp), %rdi
leaq 0x260e(%rip), %rsi      # 0x5c6d
callq 0x4010
cmpb $0x0, %al
je 0x366a
jmp 0x3689
leaq 0x265a(%rip), %rdi      # 0x5ccb
leaq 0x1f89(%rip), %rsi      # 0x5601
movl $0x292, %edx            # imm = 0x292
leaq 0x2614(%rip), %rcx      # 0x5c98
callq 0x1050
movq -0x18(%rbp), %rdi
leaq 0x25d9(%rip), %rsi      # 0x5c6d
callq 0x4010
cmpb $0x0, %al
je 0x369f
jmp 0x36be
leaq 0x2640(%rip), %rdi      # 0x5ce6
leaq 0x1f54(%rip), %rsi      # 0x5601
movl $0x293, %edx            # imm = 0x293
leaq 0x25df(%rip), %rcx      # 0x5c98
callq 0x1050
movq -0x28(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x30(%rbp), %rcx
cmpq 0x18(%rcx), %rax
je 0x36d9
movb $0x2, -0x1(%rbp)
jmp 0x37ac
movq -0x28(%rbp), %rdi
callq 0x1e60
movq %rax, -0x38(%rbp)
movq -0x30(%rbp), %rdi
callq 0x1e60
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x38(%rbp)
jne 0x370a
cmpq $0x0, -0x40(%rbp)
jne 0x370a
movb $0x0, -0x1(%rbp)
jmp 0x37ac
cmpq $0x0, -0x38(%rbp)
je 0x3790
cmpq $0x0, -0x40(%rbp)
je 0x3790
jmp 0x371a
movq -0x28(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x1eb0
movq %rax, -0x48(%rbp)
movq -0x30(%rbp), %rdi
movq -0x40(%rbp), %rsi
callq 0x1eb0
movq -0x48(%rbp), %rdi
movq %rax, %rsi
callq 0x3dd0
movsbl %al, %eax
cmpl $0x0, %eax
je 0x3752
movb $0x2, -0x19(%rbp)
jmp 0x378e
jmp 0x3754
movq -0x28(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x2040
movzbl %al, %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x49(%rbp)
je 0x3787
movq -0x30(%rbp), %rdi
movq -0x40(%rbp), %rsi
callq 0x2040
movzbl %al, %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x49(%rbp)
movb -0x49(%rbp), %al
testb $0x1, %al
jne 0x371a
jmp 0x3794
movb $0x2, -0x19(%rbp)
movq -0x38(%rbp), %rdi
callq 0x3ef0
movq -0x40(%rbp), %rdi
callq 0x3ef0
movb -0x19(%rbp), %al
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)