// File: /workspace/github_c_makefile_star2_O3/hughbarney[P]pEmacs/line.c
// Function: ldelnewline
int ldelnewline ()
{
  LINE *lp1, *lp2, *lp3;
  WINDOW *wp;
  char *cp1, *cp2;

  lp1 = curwp->w_dotp;
  lp2 = lp1->l_fp;
  if (lp2 == curbp->b_linep)
    {			       /* At the buffer end */
      if (lp1->l_used == 0)	 /* Blank line */
	lfree (lp1);
      return (TRUE);
    }
  if (lp2->l_used <= lp1->l_size - lp1->l_used)
    {
      cp1 = &lp1->l_text[lp1->l_used];
      cp2 = &lp2->l_text[0];
      while (cp2 != &lp2->l_text[lp2->l_used])
	*cp1++ = *cp2++;
      wp = wheadp;
      while (wp != NULL)
	{
	  if (wp->w_linep == lp2)
	    wp->w_linep = lp1;
	  if (wp->w_dotp == lp2)
	    {
	      wp->w_dotp = lp1;
	      wp->w_doto += lp1->l_used;
	    }
	  if (wp->w_markp == lp2)
	    {
	      wp->w_markp = lp1;
	      wp->w_marko += lp1->l_used;
	    }
	  wp = wp->w_wndp;
	}
      lp1->l_used += lp2->l_used;
      lp1->l_fp = lp2->l_fp;
      lp2->l_fp->l_bp = lp1;
      free ((char *) lp2);
      return (TRUE);
    }
  if ((lp3 = lalloc (lp1->l_used + lp2->l_used)) == NULL)
    return (FALSE);
  cp1 = &lp1->l_text[0];
  cp2 = &lp3->l_text[0];
  while (cp1 != &lp1->l_text[lp1->l_used])
    *cp2++ = *cp1++;
  cp1 = &lp2->l_text[0];
  while (cp1 != &lp2->l_text[lp2->l_used])
    *cp2++ = *cp1++;
  lp1->l_bp->l_fp = lp3;
  lp3->l_fp = lp2->l_fp;
  lp2->l_fp->l_bp = lp3;
  lp3->l_bp = lp1->l_bp;
  wp = wheadp;
  while (wp != NULL)
    {
      if (wp->w_linep == lp1 || wp->w_linep == lp2)
	wp->w_linep = lp3;
      if (wp->w_dotp == lp1)
	wp->w_dotp = lp3;
      else if (wp->w_dotp == lp2)
	{
	  wp->w_dotp = lp3;
	  wp->w_doto += lp1->l_used;
	}
      if (wp->w_markp == lp1)
	wp->w_markp = lp3;
      else if (wp->w_markp == lp2)
	{
	  wp->w_markp = lp3;
	  wp->w_marko += lp1->l_used;
	}
      wp = wp->w_wndp;
    }
  free ((char *) lp1);
  free ((char *) lp2);
  return (TRUE);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
leaq 0x84fb(%rip), %rax      # 0xda48
movq (%rax), %rax
movq 0x18(%rax), %rbx
movq (%rbx), %r14
leaq 0x84da(%rip), %rax      # 0xda38
movq (%rax), %rax
cmpq 0x28(%rax), %r14
je 0x5667
movl 0x14(%r14), %eax
movl 0x10(%rbx), %ecx
movslq 0x14(%rbx), %rdi
subl %edi, %ecx
cmpl %ecx, %eax
jle 0x5683
addl %eax, %edi
callq 0x4ef4
testq %rax, %rax
je 0x56b9
leaq 0x18(%rax), %rcx
cmpl $0x0, 0x14(%rbx)
je 0x55b9
leaq 0x18(%rbx), %rdx
movq %rdx, %rsi
movb (%rsi), %dil
incq %rsi
movb %dil, (%rcx)
incq %rcx
movslq 0x14(%rbx), %rdi
addq %rdx, %rdi
cmpq %rdi, %rsi
jne 0x55a1
cmpl $0x0, 0x14(%r14)
je 0x55df
leaq 0x18(%r14), %rdx
movq %rdx, %rsi
movb (%rsi), %dil
incq %rsi
movb %dil, (%rcx)
incq %rcx
movslq 0x14(%r14), %rdi
addq %rdx, %rdi
cmpq %rdi, %rsi
jne 0x55c7
movq 0x8(%rbx), %rcx
movq %rax, (%rcx)
movq (%r14), %rcx
movq %rcx, (%rax)
movq %rax, 0x8(%rcx)
movq 0x8(%rbx), %rcx
movq %rcx, 0x8(%rax)
leaq 0x8461(%rip), %rcx      # 0xda60
movq (%rcx), %rcx
testq %rcx, %rcx
je 0x56af
movq 0x10(%rcx), %rdx
cmpq %rbx, %rdx
setne %sil
cmpq %r14, %rdx
setne %dl
testb %dl, %sil
jne 0x5625
movq %rax, 0x10(%rcx)
movq 0x18(%rcx), %rdx
cmpq %rbx, %rdx
je 0x5641
cmpq %r14, %rdx
jne 0x5645
movq %rax, 0x18(%rcx)
movslq 0x14(%rbx), %rdx
addq %rdx, 0x20(%rcx)
jmp 0x5645
movq %rax, 0x18(%rcx)
movq 0x28(%rcx), %rdx
cmpq %rbx, %rdx
je 0x5661
cmpq %r14, %rdx
jne 0x55ff
movq %rax, 0x28(%rcx)
movslq 0x14(%rbx), %rdx
addq %rdx, 0x30(%rcx)
jmp 0x55ff
movq %rax, 0x28(%rcx)
jmp 0x55ff
movl $0x1, %ebp
cmpl $0x0, 0x14(%rbx)
jne 0x5718
movq %rbx, %rdi
callq 0x4f42
jmp 0x5718
testl %eax, %eax
je 0x56bd
leaq 0x18(%r14), %rcx
leaq (%rbx,%rdi), %rdx
addq $0x18, %rdx
movq %rcx, %rsi
movb (%rsi), %al
incq %rsi
movb %al, (%rdx)
incq %rdx
movslq 0x14(%r14), %rax
leaq (%rcx,%rax), %rdi
cmpq %rdi, %rsi
jne 0x5696
jmp 0x56bf
movq %rbx, %rdi
callq 0x2040
jmp 0x570b
xorl %ebp, %ebp
jmp 0x5718
xorl %eax, %eax
leaq 0x839a(%rip), %rcx      # 0xda60
movq (%rcx), %rcx
testq %rcx, %rcx
je 0x56fe
cmpq %r14, 0x10(%rcx)
jne 0x56d8
movq %rbx, 0x10(%rcx)
cmpq %r14, 0x18(%rcx)
jne 0x56ea
movq %rbx, 0x18(%rcx)
movslq 0x14(%rbx), %rdx
addq %rdx, 0x20(%rcx)
cmpq %r14, 0x28(%rcx)
jne 0x56c6
movq %rbx, 0x28(%rcx)
movslq 0x14(%rbx), %rdx
addq %rdx, 0x30(%rcx)
jmp 0x56c6
addl %eax, 0x14(%rbx)
movq (%r14), %rax
movq %rax, (%rbx)
movq %rbx, 0x8(%rax)
movq %r14, %rdi
callq 0x2040
movl $0x1, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq