News for hackers. Stuff that matters.

idispatch

Re:Carbon Language: An experimental successor to C++ on Thursday July 31, 2025 @06:44PM (#44751030)
I counted the word “sound” in this reply 8 times. When I the word sound there is always the word Rust nearby. It is just a coincidence, of course.
On that angle - I like the project structure, overall, CMake use and documentation. It was helpful to understand, high level, before diving into code.

I also recall the discussion here related to fast associative containers, like unordered map/set. This is the implementation - https://github.com/martinus/unordered_dense

Combined with HFT CppCon talk that emphasizes the impact of node-based STL containers you may benefit from using some optimized hash maps on top of vectors, if you aim at top-performance in runtime. Also, abseil has some flat sets/maps implementation. All of this could be a nice addition if you experiment with performance (I figured that from std::pmr use in your project).

Related video for those who are interested: “When Nanoseconds Matter: Ultrafast Trading Systems in C++ - David Gross - CppCon 2024” https://youtu.be/sX2nF1fW7kI?si=komqKuZ0-eOH2v4V

This is basics for those who start creating anything HFT.

Your project is a nice start. It has a lot of things waiting to be added and improved. I’d also add it looks like a 1-2 week project (excluding benchmarks) in my company for people who just started doing trading systems, and it reminds me of the project that is given to people that have finished C++ training and need something to exercise on.

While it is a good start, I’d add you may find a lot of interesting ideas in QuantLib (https://www.quantlib.org/).

Please also be careful with double for price and quantity especially in HFT and especially with asset types like BTC. The precision issues may lead to some confusion and eventual losses here and there. I noticed that you use fuzzy floating point comparisons, even in tests. That may not be suitable for important use cases.

Please also add some examples for specific trading strategies. Let’s say if you have back testing and some simple historic data in JSON a good example could be a comparison of two trading strategies and the difference compared to most optimal trading strategy possible.

Re:The demoscene as a UNESCO heritage in Sweden on Monday March 31, 2025 @07:10PM (#43540987)
Classic masterpiece, for those who experienced it in 1990s and wanted to know how it was done: https://github.com/mtuomi/SecondReality
Re:The Jakt Programming Language on Tuesday March 25, 2025 @05:33PM (#43476233)
Sooner or later there will inevitably appear a new language, or an evolution of the current Rust, which will be significantly better than Rust and not just a minor tweak to the language we know today . Let’s say it is named Rust++ (any resemblance to existing languages is a pure coincidence). And the whole hype and rewrite starts over again… it is just a matter of time.
Re:AI Killed the Tech Interview. Now What? on Thursday February 20, 2025 @12:17PM (#43117447)
It looks like you professionally sold 30 years of your life for money with no fun. You could have done something for fun all this time, and got payed for it, too. Much better that way.
And VSCode will still be around.
Re:Unicode 88 (1988) [pdf] on Friday September 01, 2023 @10:17PM (#37358054)
Looks like a unipost in a uniblog
Re:Few lesser known tricks, quirks and features of C on Saturday July 01, 2023 @05:34PM (#36555492)
This is plainly not true
Re:Meta is about to start its next round of layoffs on Tuesday April 18, 2023 @11:08PM (#35623811)
To be more precise, to e.
Re:Advanced Bash-Scripting Guide (2014) on Friday August 19, 2022 @04:34PM (#32525655)
Mind you, before this goes to prod please add error handling and logging. What happens when bar fails? What about baz? Now, please rewrite this so your team mates can maintain and extend. Yawn, I’ll wait for the PR.
Re:We Need Software Updates Forever on Thursday September 23, 2021 @03:03PM (#28633683)
OTOH, if it wasn't that good we would be using something else, good and better that win3.1 and the history would erase Windows.