Simple High performance, low latency system implemented in C++ written for learning purposes. Processes Data in realtime via FIX protocol.
- Lock Free queues
- Memory Pools to eliminate allocations
- CPU pinning with dedicated cores for market and order processing
- Zero copy using in place parsing and string views
- State machine for FIX parsing
- Compile time optimizations
- Average tik-to-trade: 10-15 microseconds
- Peak Performance: 2.8μs minimum latency
- Message Processing: 400+ messages per 30-second test with ~98% execution rate
- Parser efficiency: Sub-2μs (averaging around 1.4μs)
Tree
├── config.json
├── include/
│ ├── fast_float/ (9 headers)
│ ├── json.hpp
│ ├── ordermanager.h
│ ├── orders.h
│ ├── parser.h
│ └── receive.h
├── Makefile
├── README.md
└── src/
├── (main, ordermanager, parser, orders, receive).cpp
└── testserver.pyPrerequisites
# Ubuntu/Debian
sudo apt-get install build-essential nlohmann-json3-dev libboost-devCompilation
make clean && makeEdit config.json for trading parameters (for now its only one config variable)
{
"symbol": "EUR/USD",
"target_buy_price": 1.1235,
"order_quantity": 1500
}Compile and run
./TIKTest with Market data
python3 testserver.pyMarket Data (UDP) → Parser → Order Book → Strategy → Order Execution- Implement SBE protocol
- Multi-symbol support