// File: /workspace/github_c_makefile_star2_O1/aspone[P]OrderBook/./FeedHandler.h
// Function: OrderBook::FeedHandler<unsigned int, OrderLevelEntry>::processMessage(char*)
void processMessage(char *line) {
#ifdef DEBUG
      uint32_t len = strlen(line);
      char orig_msg[len];
      strncpy(orig_msg, line, strlen(line));
#endif
      MessageType mt = parser_.getMessageType(line);
      bool valid_message = false;
      if (mt == eMT_Unknown) {
         FHErrorTracker::instance()->corruptMessage();
         return;
      }
      else if (mt == eMT_Trade) {
         STARTPROFILE();
         TradeMessage tm;
         parser_.parseTrade(line, tm);
         if (tm.trade_price_ != 0) {
            valid_message = true;
            DB("%s", orig_msg);
            order_book_.handleTrade(tm);
         }
         STOPPROFILE(trade_);
      }
      else {
         // Poked hole in memory model to avoid temporary stack-based ORDERTYPE
         // and copy ctor onto heap object.  Premature optimization out the
         // wazoo on this one, but "MOST OPTIMIZED CODE POSSIBLE" (within the
         // time constraint of the time I have to work on this) meant this nasty
         // split.  All "delete" calls are within OrderBook except for on bad
         // messages, and new / delete calls are kept tight here to attempt to
         // keep flow clear.  As mentioned in documentation - I'd be curious to
         // see how this performs with a ref counted shared_ptr from boost.
         STARTPROFILE();
         ORDERTYPE *ole = new ORDERTYPE();
         parser_.parseOrder(line, *ole);
         if (ole->order_side_ == eS_Unknown) {
            delete ole;
         }
         else {
            switch (mt) {
               case eMT_Add:
                  order_book_.addOrder(ole);
                  STOPPROFILE(add_);
                  valid_message = true;
                  break;
               case eMT_Modify:
                  order_book_.modifyOrder(ole);
                  STOPPROFILE(modify_);
                  valid_message = true;
                  break;
               case eMT_Remove:
                  order_book_.removeOrder(ole);
                  STOPPROFILE(remove_);
                  valid_message = true;
                  break;
               default:
                  fprintf(stderr, "Unknown order type hit in switch.  This should not happen.\n");
                  delete ole;
                  FAILASSERT();
                  break;
            }
         }
      }
      if (valid_message) {
#ifdef DEBUG
         DB("%s", orig_msg);
         order_book_.printBook();
#endif
         STARTPROFILE();
         order_book_.printMidpoint();
         STOPPROFILE(midquote_);
      }
   }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x20a0
addl $-0x25, %eax
cmpl $-0x25, %eax
ja 0x2b67
leaq 0x86d1(%rip), %r15      # 0xb1c0
cmpq $0x0, (%r15)
jne 0x2b14
movl $0x28, %edi
callq 0x21f0
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movups %xmm0, 0x10(%rax)
movq $0x0, 0x20(%rax)
movq %rax, (%r15)
movq (%r15), %rax
incl 0x14(%rax)
xorl %ebp, %ebp
leaq 0x180(%rbx), %r12
cmpl $0x4, %ebp
je 0x2b97
testl %ebp, %ebp
jne 0x2bc3
leaq 0x8689(%rip), %rbx      # 0xb1c0
cmpq $0x0, (%rbx)
jne 0x2b5c
movl $0x28, %edi
callq 0x21f0
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movups %xmm0, 0x10(%rax)
movq $0x0, 0x20(%rax)
movq %rax, (%rbx)
movq (%rbx), %rax
incl 0x14(%rax)
jmp 0x2c72
leaq 0x46aa(%rip), %rsi      # 0x7218
movq %r14, %rdi
callq 0x22c0
movzbl (%rax), %eax
cmpl $0x53, %eax
jg 0x2c12
cmpl $0x41, %eax
je 0x2c3e
cmpl $0x4d, %eax
jne 0x2b1a
movl $0x3, %ebp
jmp 0x2b1c
movq %rsp, %r15
movq %r12, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x348a
cmpq $0x0, 0x8(%r15)
je 0x2c72
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x377c
jmp 0x2c6a
movl $0x28, %edi
callq 0x21f0
movq %rax, %r15
movl $0x0, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movups %xmm0, 0x18(%rax)
movq %r12, %rdi
movq %r14, %rsi
movq %rax, %rdx
callq 0x3ac8
cmpl $0x0, 0x14(%r15)
je 0x2c2a
cmpl $0x3, %ebp
je 0x2c52
cmpl $0x2, %ebp
je 0x2c5f
cmpl $0x1, %ebp
jne 0x2c7f
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3e32
jmp 0x2c6a
cmpl $0x54, %eax
je 0x2c48
cmpl $0x58, %eax
jne 0x2b1a
movl $0x2, %ebp
jmp 0x2b1c
movq %r15, %rdi
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x21c0
movl $0x1, %ebp
jmp 0x2b1c
movl $0x4, %ebp
jmp 0x2b1c
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3f3a
jmp 0x2c6a
movq %rbx, %rdi
movq %r15, %rsi
callq 0x41c4
movq %rbx, %rdi
callq 0x4320
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
callq 0x2465
jmp 0x2c72
nop