// File: /workspace/github_c_makefile_star2_O0/LemonBoy[P]autobahn/xdiff/xdiffi.c
// Function: score_add_split
static void score_add_split(const struct split_measurement *m, struct split_score *s)
{
	/*
	 * A place to accumulate penalty factors (positive makes this index more
	 * favored):
	 */
	int post_blank, total_blank, indent, any_blanks;

	if (m->pre_indent == -1 && m->pre_blank == 0)
		s->penalty += START_OF_FILE_PENALTY;

	if (m->end_of_file)
		s->penalty += END_OF_FILE_PENALTY;

	/*
	 * Set post_blank to the number of blank lines following the split,
	 * including the line immediately after the split:
	 */
	post_blank = (m->indent == -1) ? 1 + m->post_blank : 0;
	total_blank = m->pre_blank + post_blank;

	/* Penalties based on nearby blank lines: */
	s->penalty += TOTAL_BLANK_WEIGHT * total_blank;
	s->penalty += POST_BLANK_WEIGHT * post_blank;

	if (m->indent != -1)
		indent = m->indent;
	else
		indent = m->post_indent;

	any_blanks = (total_blank != 0);

	/* Note that the effective indent is -1 at the end of the file: */
	s->effective_indent += indent;

	if (indent == -1) {
		/* No additional adjustments needed. */
	} else if (m->pre_indent == -1) {
		/* No additional adjustments needed. */
	} else if (indent > m->pre_indent) {
		/*
		 * The line is indented more than its predecessor.
		 */
		s->penalty += any_blanks ?
			RELATIVE_INDENT_WITH_BLANK_PENALTY :
			RELATIVE_INDENT_PENALTY;
	} else if (indent == m->pre_indent) {
		/*
		 * The line has the same indentation level as its predecessor.
		 * No additional adjustments needed.
		 */
	} else {
		/*
		 * The line is indented less than its predecessor. It could be
		 * the block terminator of the previous block, but it could
		 * also be the start of a new block (e.g., an "else" block, or
		 * maybe the previous block didn't have a block terminator).
		 * Try to distinguish those cases based on what comes next:
		 */
		if (m->post_indent != -1 && m->post_indent > indent) {
			/*
			 * The following line is indented more. So it is likely
			 * that this line is the start of a block.
			 */
			s->penalty += any_blanks ?
				RELATIVE_OUTDENT_WITH_BLANK_PENALTY :
				RELATIVE_OUTDENT_PENALTY;
		} else {
			/*
			 * That was probably the end of a block.
			 */
			s->penalty += any_blanks ?
				RELATIVE_DEDENT_WITH_BLANK_PENALTY :
				RELATIVE_DEDENT_PENALTY;
		}
	}
}

// Assembly:
movq %rdi, -0x8(%rsp)
movq %rsi, -0x10(%rsp)
movq -0x8(%rsp), %rax
cmpl $-0x1, 0xc(%rax)
jne 0x2f2e
movq -0x8(%rsp), %rax
cmpl $0x0, 0x8(%rax)
jne 0x2f2e
movq -0x10(%rsp), %rax
movl 0x4(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x4(%rax)
movq -0x8(%rsp), %rax
cmpl $0x0, (%rax)
je 0x2f46
movq -0x10(%rsp), %rax
movl 0x4(%rax), %ecx
addl $0x15, %ecx
movl %ecx, 0x4(%rax)
movq -0x8(%rsp), %rax
cmpl $-0x1, 0x4(%rax)
jne 0x2f62
movq -0x8(%rsp), %rax
movl 0x10(%rax), %eax
addl $0x1, %eax
movl %eax, -0x24(%rsp)
jmp 0x2f6a
xorl %eax, %eax
movl %eax, -0x24(%rsp)
jmp 0x2f6a
movl -0x24(%rsp), %eax
movl %eax, -0x14(%rsp)
movq -0x8(%rsp), %rax
movl 0x8(%rax), %eax
addl -0x14(%rsp), %eax
movl %eax, -0x18(%rsp)
imull $0xffffffe2, -0x18(%rsp), %ecx # imm = 0xFFFFFFE2
movq -0x10(%rsp), %rax
addl 0x4(%rax), %ecx
movl %ecx, 0x4(%rax)
imull $0x6, -0x14(%rsp), %ecx
movq -0x10(%rsp), %rax
addl 0x4(%rax), %ecx
movl %ecx, 0x4(%rax)
movq -0x8(%rsp), %rax
cmpl $-0x1, 0x4(%rax)
je 0x2fbe
movq -0x8(%rsp), %rax
movl 0x4(%rax), %eax
movl %eax, -0x1c(%rsp)
jmp 0x2fca
movq -0x8(%rsp), %rax
movl 0x14(%rax), %eax
movl %eax, -0x1c(%rsp)
cmpl $0x0, -0x18(%rsp)
setne %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x20(%rsp)
movl -0x1c(%rsp), %ecx
movq -0x10(%rsp), %rax
addl (%rax), %ecx
movl %ecx, (%rax)
cmpl $-0x1, -0x1c(%rsp)
jne 0x2ff4
jmp 0x30a4
movq -0x8(%rsp), %rax
cmpl $-0x1, 0xc(%rax)
jne 0x3004
jmp 0x30a2
movl -0x1c(%rsp), %eax
movq -0x8(%rsp), %rcx
cmpl 0xc(%rcx), %eax
jle 0x3033
movl -0x20(%rsp), %edx
movl $0xfffffffc, %ecx       # imm = 0xFFFFFFFC
movl $0xa, %eax
cmpl $0x0, %edx
cmovnel %eax, %ecx
movq -0x10(%rsp), %rax
addl 0x4(%rax), %ecx
movl %ecx, 0x4(%rax)
jmp 0x30a0
movl -0x1c(%rsp), %eax
movq -0x8(%rsp), %rcx
cmpl 0xc(%rcx), %eax
jne 0x3043
jmp 0x309e
movq -0x8(%rsp), %rax
cmpl $-0x1, 0x14(%rax)
je 0x307d
movq -0x8(%rsp), %rax
movl 0x14(%rax), %eax
cmpl -0x1c(%rsp), %eax
jle 0x307d
movl -0x20(%rsp), %edx
movl $0x18, %ecx
movl $0x11, %eax
cmpl $0x0, %edx
cmovnel %eax, %ecx
movq -0x10(%rsp), %rax
addl 0x4(%rax), %ecx
movl %ecx, 0x4(%rax)
jmp 0x309c
movl -0x20(%rsp), %edx
movl $0x17, %ecx
movl $0x11, %eax
cmpl $0x0, %edx
cmovnel %eax, %ecx
movq -0x10(%rsp), %rax
addl 0x4(%rax), %ecx
movl %ecx, 0x4(%rax)
jmp 0x309e
jmp 0x30a0
jmp 0x30a2
jmp 0x30a4
retq
nopw %cs:(%rax,%rax)