bil shah

bil shah

  • NA
  • 1
  • 0

Building very high speed C# application

Nov 25 2007 2:08 AM

I need to know the best pratices to develop high-speed C# live trading applications.

Such application typically include an event handler that receive live market ticks in string format and is invoked a few hundred times in a matter of milliseconds. The string is parsed and stock symbol name and pricing information is extracted from it. The symbol name is looked up in a list of a object that typically holds upto 700-800 "Stock" objects. Once the relevant stock object is retrieved, the pricing information is passed to a member function of STock object that performs some calculations. To perform these calculations some other lists are looked up that typically hold a few thousand items. These calculations result in creation of an "Order" object which is added into another list that holds a few thousand "Order" objects. The order object is converted into an array of bytes and is trasmitted out over a socket connection. This whole process needs to be thread safe.

 

In short, there is a lot of list storage and list look-up going on..

 

Is there any Microsoft manual or any other articles that list best coding practices to implement such solution in the most memory efficient manner ?

If anyone else has some suggestions n developing such high speed applications, please let me know.

 

Thanks,