// File: BelfordZ[P]SimpleFileServer/Frame.cpp
// Function: Frame::frametype_to_string[abi:cxx11](FrameType const&) const
std::string Frame::frametype_to_string(const FrameType& f) const {
   switch(f) {
      case CLIENT_HELLO:
	 return "0";
      case SERVER_HELLO:
	 return "1";
      case SYNC:
	 return "2";
      case GOODBYE:
	 return "3";
      case DATA:
	 return "4";
      case ACK:
	 return "5";
      case NAK:
	 return "6";
      default:
	 return "4";
   }

   return "4"; // this should never happen!!!
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x50(%rbp)
movq %rdi, %rax
movq %rax, -0x48(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x18(%rbp), %rax
movl (%rax), %eax
movq %rax, -0x40(%rbp)
subq $0x6, %rax
ja 0x86a7
movq -0x40(%rbp), %rax
leaq 0x2dc7(%rip), %rcx      # 0xb258
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq -0x19(%rbp), %rdi
movq %rdi, -0x58(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x58(%rbp), %rdx
leaq 0x2dc0(%rip), %rsi      # 0xb276
callq 0x3ad0
jmp 0x84bd
leaq -0x19(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x19(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x2d(%rbp), %rdi
movq %rdi, -0x60(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x60(%rbp), %rdx
leaq 0x2ea4(%rip), %rsi      # 0xb3a5
callq 0x3ad0
jmp 0x8508
leaq -0x2d(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x2d(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x2e(%rbp), %rdi
movq %rdi, -0x68(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x68(%rbp), %rdx
leaq 0x2d2c(%rip), %rsi      # 0xb278
callq 0x3ad0
jmp 0x8553
leaq -0x2e(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x2e(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x2f(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x70(%rbp), %rdx
leaq 0x2ce3(%rip), %rsi      # 0xb27a
callq 0x3ad0
jmp 0x859e
leaq -0x2f(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x2f(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x30(%rbp), %rdi
movq %rdi, -0x78(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x78(%rbp), %rdx
leaq 0x2c9a(%rip), %rsi      # 0xb27c
callq 0x3ad0
jmp 0x85e9
leaq -0x30(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x31(%rbp), %rdi
movq %rdi, -0x80(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x80(%rbp), %rdx
leaq 0x2c51(%rip), %rsi      # 0xb27e
callq 0x3ad0
jmp 0x8634
leaq -0x31(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x31(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x32(%rbp), %rdi
movq %rdi, -0x88(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x88(%rbp), %rdx
leaq 0x2c02(%rip), %rsi      # 0xb280
callq 0x3ad0
jmp 0x8685
leaq -0x32(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x32(%rbp), %rdi
callq 0x3330
jmp 0x86ff
leaq -0x33(%rbp), %rdi
movq %rdi, -0x90(%rbp)
callq 0x34a0
movq -0x50(%rbp), %rdi
movq -0x90(%rbp), %rdx
leaq 0x2bb3(%rip), %rsi      # 0xb27c
callq 0x3ad0
jmp 0x86d0
leaq -0x33(%rbp), %rdi
callq 0x3330
jmp 0x86f2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x33(%rbp), %rdi
callq 0x3330
jmp 0x86ff
movq -0x48(%rbp), %rax
addq $0x90, %rsp
popq %rbp
retq
movq -0x28(%rbp), %rdi
callq 0x3490
nopl (%rax,%rax)