// File: besm6[P]pascal-re/pascompl.cc
// Function: endOfLine()
void endOfLine()
{
    int64_t err, errPos, prevPos, listMode,
    startPos, lastErr;

    listMode = PASINFOR.listMode;
    if ((listMode != 0) or (errsInLine != 0)) {
        printf(" %05lo%5ld%3ld%c", (lineStartOffset + PASINFOR.startOffset),
               lineCnt, lineNesting, commentModeCH);
        startPos = 12;
        if (optSflags.m.has(S4)
            and (maxLineLen == 72)
            and (linePos >= 80)) {
            for (err = 73; err <= 80; ++err)
                putchar(lineBufBase[err]);
            putchar(' ');
            linePos = 73;
            startPos += 9;
        }; /* 1106 */
        do
            linePos = linePos-1;
        while ((lineBufBase[linePos]  == ' ') and (linePos != 0));
        for (err = 1; err <= linePos; ++err) {
            kputc(lineBufBase[err]);
        };
        putchar('\n');
        if (errsInLine != 0)  {
            printf("%*s %*c0", int(startPos), "^^^^^", int(errMapBase[0]), ' ');
            lastErr = errsInLine - 1;
            for (err = 1; err <= lastErr; ++err) {
                errPos = errMapBase[err];
                prevPos = errMapBase[err-1];
                if (errPos != prevPos) {
                    if (prevPos + 1 != errPos)
                        printf("%*c", int(errPos-prevPos-1), ' ');
                    putchar(char(err + 48));
                }
            }
            putchar('\n');
            errsInLine = 0;
            prevErrPos = 0;
        }
    } /* 1160 */
    if ((listMode == 2) and (moduleOffset != lineStartOffset)) {
        OBPROG(objBuffer[objBufIdx - moduleOffset + lineStartOffset],
               objBuffer[objBufIdx-1]);
    } /* 1174 */
    lineStartOffset = moduleOffset;
    linePos = 0;
    lineCnt = lineCnt + 1;
    // One EOF is OK when the file doesn't have any extra characters after "END."
    static int eofs;
    if (feof(pasinput) && eofs++) {
        error(errEOFEncountered);
        throw 9999;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq 0xcfd01(%rip), %rax     # 0xd8a20
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
jne 0x8d38
cmpq $0x0, 0x7720e(%rip)     # 0x7ff40
je 0x8f7a
movq 0x77211(%rip), %rsi     # 0x7ff50
addq 0xcfce2(%rip), %rsi     # 0xd8a28
movq 0x77223(%rip), %rdx     # 0x7ff70
movq 0x77294(%rip), %rcx     # 0x7ffe8
movsbl 0x7727c(%rip), %r8d     # 0x7ffd8
leaq 0x2959c(%rip), %rdi     # 0x322ff
movb $0x0, %al
callq 0x4030
movq $0xc, -0x28(%rbp)
leaq 0x773b7(%rip), %rdi     # 0x80130
movl $0x1, %esi
callq 0x1e5f0
testb $0x1, %al
jne 0x8d89
jmp 0x8def
cmpq $0x48, 0x77197(%rip)    # 0x7ff28
jne 0x8def
cmpq $0x50, 0x77195(%rip)    # 0x7ff30
jl 0x8def
movq $0x49, -0x8(%rbp)
cmpq $0x50, -0x8(%rbp)
jg 0x8dce
movq -0x8(%rbp), %rcx
leaq 0x7bdf9(%rip), %rax     # 0x84bb0
movsbl (%rax,%rcx), %edi
callq 0x4410
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
jmp 0x8da5
movl $0x20, %edi
callq 0x4410
movq $0x49, 0x7714d(%rip) # 0x7ff30
movq -0x28(%rbp), %rax
addq $0x9, %rax
movq %rax, -0x28(%rbp)
jmp 0x8df1
movq 0x77138(%rip), %rax     # 0x7ff30
subq $0x1, %rax
movq %rax, 0x7712d(%rip)     # 0x7ff30
movq 0x77126(%rip), %rcx     # 0x7ff30
leaq 0x7bd9f(%rip), %rax     # 0x84bb0
movsbl (%rax,%rcx), %ecx
xorl %eax, %eax
cmpl $0x20, %ecx
movb %al, -0x31(%rbp)
jne 0x8e2d
cmpq $0x0, 0x77109(%rip)     # 0x7ff30
setne %al
movb %al, -0x31(%rbp)
movb -0x31(%rbp), %al
testb $0x1, %al
jne 0x8df1
movq $0x1, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq 0x770e9(%rip), %rax     # 0x7ff30
jg 0x8e6b
movq -0x8(%rbp), %rcx
leaq 0x7bd5c(%rip), %rax     # 0x84bb0
movzbl (%rax,%rcx), %edi
callq 0x9060
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
jmp 0x8e3c
movl $0xa, %edi
callq 0x4410
cmpq $0x0, 0x770c3(%rip)     # 0x7ff40
je 0x8f78
movq -0x28(%rbp), %rax
movl %eax, %esi
movq 0x7bdb0(%rip), %rax     # 0x84c40
movl %eax, %ecx
leaq 0x29477(%rip), %rdi     # 0x32310
leaq 0x29479(%rip), %rdx     # 0x32319
movl $0x20, %r8d
movb $0x0, %al
callq 0x4030
movq 0x7708c(%rip), %rax     # 0x7ff40
subq $0x1, %rax
movq %rax, -0x30(%rbp)
movq $0x1, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpq -0x30(%rbp), %rax
jg 0x8f58
movq -0x8(%rbp), %rcx
leaq 0x7bd63(%rip), %rax     # 0x84c40
movq (%rax,%rcx,8), %rax
movq %rax, -0x10(%rbp)
movq -0x8(%rbp), %rcx
subq $0x1, %rcx
leaq 0x7bd4c(%rip), %rax     # 0x84c40
movq (%rax,%rcx,8), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
cmpq -0x18(%rbp), %rax
je 0x8f45
movq -0x18(%rbp), %rax
addq $0x1, %rax
cmpq -0x10(%rbp), %rax
je 0x8f35
movq -0x10(%rbp), %rax
subq -0x18(%rbp), %rax
subq $0x1, %rax
movl %eax, %esi
leaq 0x293f6(%rip), %rdi     # 0x3231f
movl $0x20, %edx
movb $0x0, %al
callq 0x4030
movq -0x8(%rbp), %rax
addq $0x30, %rax
movsbl %al, %edi
callq 0x4410
jmp 0x8f47
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
jmp 0x8ec4
movl $0xa, %edi
callq 0x4410
movq $0x0, 0x76fd3(%rip) # 0x7ff40
movq $0x0, 0x76fc0(%rip) # 0x7ff38
jmp 0x8f7a
cmpq $0x2, -0x20(%rbp)
jne 0x8fd2
movq 0x76fc0(%rip), %rax     # 0x7ff48
cmpq 0x76fc1(%rip), %rax     # 0x7ff50
je 0x8fd2
movq 0x77060(%rip), %rax     # 0x7fff8
subq 0x76fa9(%rip), %rax     # 0x7ff48
addq 0x76faa(%rip), %rax     # 0x7ff50
leaq 0xbf933(%rip), %rdi     # 0xc88e0
shlq $0x3, %rax
addq %rax, %rdi
movq 0x7703d(%rip), %rax     # 0x7fff8
subq $0x1, %rax
leaq 0xbf91a(%rip), %rsi     # 0xc88e0
shlq $0x3, %rax
addq %rax, %rsi
callq 0x8c50
movq 0x76f6f(%rip), %rax     # 0x7ff48
movq %rax, 0x76f70(%rip)     # 0x7ff50
movq $0x0, 0x76f45(%rip) # 0x7ff30
movq 0x76f7e(%rip), %rax     # 0x7ff70
addq $0x1, %rax
movq %rax, 0x76f73(%rip)     # 0x7ff70
movq 0x36e6c(%rip), %rdi     # 0x3fe70
callq 0x4460
cmpl $0x0, %eax
je 0x9051
movl 0xcfa3c(%rip), %eax     # 0xd8a50
movl %eax, %ecx
addl $0x1, %ecx
movl %ecx, 0xcfa31(%rip)     # 0xd8a50
cmpl $0x0, %eax
je 0x9051
movl $0x34, %edi
callq 0x7b40
movl $0x4, %edi
callq 0x4130
movq %rax, %rdi
movl $0x270f, (%rdi)         # imm = 0x270F
movq 0x35f38(%rip), %rsi     # 0x3ef80
xorl %eax, %eax
movl %eax, %edx
callq 0x44b0
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)