// File: /workspace/github_c_makefile_star2_O0/stonezwr[P]SpiKL-IP/neuron.C
// Function: Neuron::PrintSyn(std::basic_ofstream<char, std::char_traits<char>>&, char const*, char)
void Neuron::PrintSyn(ofstream& f_out, const char * t, const char s){
    bool f;
    if(strcmp(t, "in") == 0)  f = false;
    else if(strcmp(t, "out") == 0)  f = true;
    else assert(0);
    vector<Synapse*>& syns = !f ? _inputSyns : _outputSyns;

    // print all the input synapses starts with 's':
    for(auto it=syns.begin();it != syns.end(); ++it){
        Neuron * neu = !f ? (*it)->PreNeuron() : (*it)->PostNeuron();  assert(neu);
        char * name = neu->Name();  assert(name);
        if(name[0] == s){
            if(!f)
                f_out<<name<<"\t"<<_name;
            else
                f_out<<_name<<"\t"<<name;
        }   
    }
    f_out<<endl;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movb %cl, %al
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movb %al, -0x19(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x18(%rbp), %rdi
leaq 0x26f0b(%rip), %rsi     # 0x348b7
callq 0x4520
cmpl $0x0, %eax
jne 0xd9bc
movb $0x0, -0x1a(%rbp)
jmp 0xd9f8
movq -0x18(%rbp), %rdi
leaq 0x28ef9(%rip), %rsi     # 0x368c0
callq 0x4520
cmpl $0x0, %eax
jne 0xd9d7
movb $0x1, -0x1a(%rbp)
jmp 0xd9f6
leaq 0x2793a(%rip), %rdi     # 0x35318
leaq 0x26cbc(%rip), %rsi     # 0x346a1
movl $0x263, %edx            # imm = 0x263
leaq 0x26f41(%rip), %rcx     # 0x34932
callq 0x4210
jmp 0xd9f8
testb $0x1, -0x1a(%rbp)
jne 0xda0c
movq -0x50(%rbp), %rax
addq $0x30, %rax
movq %rax, -0x58(%rbp)
jmp 0xda18
movq -0x50(%rbp), %rax
addq $0x18, %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
callq 0x12080
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rdi
callq 0x120b0
movq %rax, -0x38(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x120e0
testb $0x1, %al
jne 0xda50
jmp 0xdb68
testb $0x1, -0x1a(%rbp)
jne 0xda6d
leaq -0x30(%rbp), %rdi
callq 0x12120
movq (%rax), %rdi
callq 0x1c140
movq %rax, -0x60(%rbp)
jmp 0xda82
leaq -0x30(%rbp), %rdi
callq 0x12120
movq (%rax), %rdi
callq 0x1c160
movq %rax, -0x60(%rbp)
movq -0x60(%rbp), %rax
movq %rax, -0x40(%rbp)
cmpq $0x0, -0x40(%rbp)
je 0xda93
jmp 0xdab2
leaq 0x26ed4(%rip), %rdi     # 0x3496e
leaq 0x26c00(%rip), %rsi     # 0x346a1
movl $0x268, %edx            # imm = 0x268
leaq 0x26e85(%rip), %rcx     # 0x34932
callq 0x4210
movq -0x40(%rbp), %rdi
callq 0xbea0
movq %rax, -0x48(%rbp)
cmpq $0x0, -0x48(%rbp)
je 0xdac8
jmp 0xdae7
leaq 0x26e5e(%rip), %rdi     # 0x3492d
leaq 0x26bcb(%rip), %rsi     # 0x346a1
movl $0x269, %edx            # imm = 0x269
leaq 0x26e50(%rip), %rcx     # 0x34932
callq 0x4210
movq -0x48(%rbp), %rax
movsbl (%rax), %eax
movsbl -0x19(%rbp), %ecx
cmpl %ecx, %eax
jne 0xdb58
testb $0x1, -0x1a(%rbp)
jne 0xdb2a
movq -0x10(%rbp), %rdi
movq -0x48(%rbp), %rsi
callq 0x4360
movq %rax, %rdi
leaq 0x26515(%rip), %rsi     # 0x34028
callq 0x4360
movq %rax, %rdi
movq -0x50(%rbp), %rax
movq 0x10(%rax), %rsi
callq 0x4360
jmp 0xdb56
movq -0x50(%rbp), %rax
movq -0x10(%rbp), %rdi
movq 0x10(%rax), %rsi
callq 0x4360
movq %rax, %rdi
leaq 0x264e3(%rip), %rsi     # 0x34028
callq 0x4360
movq %rax, %rdi
movq -0x48(%rbp), %rsi
callq 0x4360
jmp 0xdb58
jmp 0xdb5a
leaq -0x30(%rbp), %rdi
callq 0x12160
jmp 0xda2d
movq -0x10(%rbp), %rdi
movq 0x3f445(%rip), %rsi     # 0x4cfb8
callq 0x43b0
addq $0x60, %rsp
popq %rbp
retq
nop