// File: /workspace/github_cpp_makefile_star2_O1/sighingnow[P]compile-pascal/pl0_opt.cpp
// Function: BasicBlock::trans(std::vector<TAC, std::allocator<TAC>>&, int)
void BasicBlock::trans(std::vector<TAC> & irs, int nno) {
    if (G[nno].op == "=") {
        irs.emplace_back(TAC(G[nno].op, G[nno].item, G[G[nno].lhs].item));
    }
    else if (G[nno].op == "read") {
        while (!this->IOBuf.empty()) {
            if (this->IOBuf[0].first < G[nno].rhs) {
                irs.emplace_back(this->IOBuf[0].second);
                this->IOBuf.erase(IOBuf.begin());
            }
            else {
                break;
            }
        }
        irs.emplace_back(TAC("read", G[G[nno].lhs].item));
    }
    else if (G[nno].op == "write_e") {
        while (!this->IOBuf.empty()) {
            if (this->IOBuf[0].first < G[nno].rhs) {
                irs.emplace_back(this->IOBuf[0].second);
                this->IOBuf.erase(IOBuf.begin());
            }
            else {
                break;
            }
        }
        irs.emplace_back(TAC("write_e", G[G[nno].lhs].item));
    }
    else {
        irs.emplace_back(TAC(G[nno].op, G[nno].item, G[G[nno].lhs].item, G[G[nno].rhs].item));
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movslq %edx, %rax
movq 0x60(%rdi), %rcx
imulq $0x58, %rax, %r12
leaq (%rcx,%r12), %rdi
addq $0x30, %rdi
leaq 0x163af(%rip), %rsi     # 0x97118
callq 0x50c0
testl %eax, %eax
je 0x80e92
movq 0x60(%r14), %rax
leaq (%rax,%r12), %rdi
addq $0x30, %rdi
leaq 0x163a3(%rip), %rsi     # 0x9712c
callq 0x50c0
testl %eax, %eax
je 0x80f5f
movq 0x60(%r14), %rax
leaq (%rax,%r12), %rdi
addq $0x30, %rdi
leaq 0x17f42(%rip), %rsi     # 0x98ceb
callq 0x50c0
testl %eax, %eax
je 0x8107d
movq 0x60(%r14), %rax
leaq 0x68(%rsp), %rcx
movq %rcx, -0x10(%rcx)
movq 0x30(%rax,%r12), %rsi
movq 0x38(%rax,%r12), %rdx
addq %rsi, %rdx
leaq 0x58(%rsp), %r15
movq %r15, %rdi
callq 0x36590
movq 0x60(%r14), %rax
movq 0x10(%rax,%r12), %rbp
movslq 0x50(%rax,%r12), %rcx
imulq $0x58, %rcx, %rcx
movq 0x10(%rax,%rcx), %r13
movslq 0x54(%rax,%r12), %rcx
imulq $0x58, %rcx, %rcx
movq 0x10(%rax,%rcx), %r12
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x36590
leaq 0x8(%rsp), %rsi
movq %rbp, 0x20(%rsi)
movq %r13, 0x28(%rsi)
movq %r12, 0x30(%rsi)
xorps %xmm0, %xmm0
movups %xmm0, 0x38(%rsi)
movq $0x0, 0x48(%rsi)
movq %rbx, %rdi
callq 0x7d292
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x80e5e
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x5260
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x80e75
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x5260
movq 0x58(%rsp), %rdi
leaq 0x68(%rsp), %rax
cmpq %rax, %rdi
je 0x81191
movq 0x68(%rsp), %rsi
jmp 0x81189
movq 0x60(%r14), %rax
leaq 0xc8(%rsp), %r13
movq %r13, -0x10(%r13)
movq 0x30(%rax,%r12), %rsi
movq 0x38(%rax,%r12), %rdx
addq %rsi, %rdx
leaq 0xb8(%rsp), %r15
movq %r15, %rdi
callq 0x36590
movq 0x60(%r14), %rax
movq 0x10(%rax,%r12), %rbp
movslq 0x50(%rax,%r12), %rcx
imulq $0x58, %rcx, %rcx
movq 0x10(%rax,%rcx), %r12
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x36590
leaq 0x8(%rsp), %rsi
movq %rbp, 0x20(%rsi)
movq %r12, 0x28(%rsi)
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rsi)
movups %xmm0, 0x40(%rsi)
movq %rbx, %rdi
callq 0x7d292
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x80f2a
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x5260
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x80f41
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x5260
movq 0xb8(%rsp), %rdi
cmpq %r13, %rdi
je 0x81191
movq 0xc8(%rsp), %rsi
jmp 0x81189
movq 0xa8(%r14), %rsi
cmpq 0xb0(%r14), %rsi
je 0x80fae
leaq 0xa8(%r14), %r15
movl (%rsi), %eax
movq 0x60(%r14), %rcx
cmpl 0x54(%rcx,%r12), %eax
jge 0x80fae
addq $0x8, %rsi
movq %rbx, %rdi
callq 0x81b58
movq 0xa8(%r14), %rsi
movq %r15, %rdi
callq 0x83e10
movq 0xa8(%r14), %rsi
cmpq 0xb0(%r14), %rsi
jne 0x80f76
leaq 0xa8(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x1616b(%rip), %rsi     # 0x9712c
leaq 0x16168(%rip), %rdx     # 0x97130
leaq 0x98(%rsp), %rdi
callq 0x2670a
movq 0x60(%r14), %rax
movslq 0x50(%rax,%r12), %rcx
imulq $0x58, %rcx, %rcx
movq 0x10(%rax,%rcx), %r12
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x98(%rsp), %rsi
movq 0xa0(%rsp), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x36590
leaq 0x8(%rsp), %rsi
movq %r12, 0x20(%rsi)
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rsi)
movups %xmm0, 0x38(%rsi)
movq $0x0, 0x48(%rsi)
movq %rbx, %rdi
callq 0x7d292
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x81048
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x5260
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x8105f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x5260
movq 0x98(%rsp), %rdi
cmpq %r15, %rdi
je 0x81191
movq 0xa8(%rsp), %rsi
jmp 0x81189
movq 0xa8(%r14), %rsi
cmpq 0xb0(%r14), %rsi
je 0x810cc
leaq 0xa8(%r14), %r15
movl (%rsi), %eax
movq 0x60(%r14), %rcx
cmpl 0x54(%rcx,%r12), %eax
jge 0x810cc
addq $0x8, %rsi
movq %rbx, %rdi
callq 0x81b58
movq 0xa8(%r14), %rsi
movq %r15, %rdi
callq 0x83e10
movq 0xa8(%r14), %rsi
cmpq 0xb0(%r14), %rsi
jne 0x81094
leaq 0x88(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x17c0c(%rip), %rsi     # 0x98ceb
leaq 0x17c0c(%rip), %rdx     # 0x98cf2
leaq 0x78(%rsp), %rdi
callq 0x2670a
movq 0x60(%r14), %rax
movslq 0x50(%rax,%r12), %rcx
imulq $0x58, %rcx, %rcx
movq 0x10(%rax,%rcx), %r12
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x78(%rsp), %rsi
movq 0x80(%rsp), %rdx
addq %rsi, %rdx
leaq 0x8(%rsp), %rdi
callq 0x36590
leaq 0x8(%rsp), %rsi
movq %r12, 0x20(%rsi)
xorps %xmm0, %xmm0
movups %xmm0, 0x28(%rsi)
movups %xmm0, 0x38(%rsi)
movq $0x0, 0x48(%rsi)
movq %rbx, %rdi
callq 0x7d292
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x81160
movq 0x50(%rsp), %rsi
subq %rdi, %rsi
callq 0x5260
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x81177
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x5260
movq 0x78(%rsp), %rdi
cmpq %r15, %rdi
je 0x81191
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x5260
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x6afce
jmp 0x811b5
movq %rax, %rbx
movq 0x78(%rsp), %rdi
cmpq %r15, %rdi
je 0x81254
movq 0x88(%rsp), %rsi
jmp 0x8124c
jmp 0x811f8
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x6afce
jmp 0x811e1
movq %rax, %rbx
movq 0x98(%rsp), %rdi
cmpq %r15, %rdi
je 0x81254
movq 0xa8(%rsp), %rsi
jmp 0x8124c
movq %rax, %rbx
jmp 0x81254
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x6afce
jmp 0x8120f
movq %rax, %rbx
movq 0x58(%rsp), %rdi
leaq 0x68(%rsp), %rax
cmpq %rax, %rdi
je 0x81254
movq 0x68(%rsp), %rsi
jmp 0x8124c
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x6afce
jmp 0x81237
movq %rax, %rbx
movq 0xb8(%rsp), %rdi
cmpq %r13, %rdi
je 0x81254
movq 0xc8(%rsp), %rsi
incq %rsi
callq 0x5260
movq %rbx, %rdi
callq 0x53d0