I Wrote a High-Frequency Trading Platform in D
1–10 of 16 posts
Re: I Wrote a High-Frequency Trading Platform in D
#2Re: I Wrote a High-Frequency Trading Platform in D
#3D is an interesting language, but I don't really know much about it. Seems like the first time I ever heard of D was in a BBS files listing back in the 90s. That must have been right around when it first came out. Since then I hear about it from time to time, but never checked it out, until yesterday, when I happen to have finally downloaded the compiler. I'm now looking for code samples, tutorials and such to get st…
Re: I Wrote a High-Frequency Trading Platform in D
#4D is an interesting language, but I don't really know much about it. Seems like the first time I ever heard of D was in a BBS files listing back in the 90s. That must have been right around when it first came out. Since then I hear about it from time to time, but never checked it out, until yesterday, when I happen to have finally downloaded the compiler. I'm now looking for code samples, tutorials and such to get st…
Re: I Wrote a High-Frequency Trading Platform in D
#5D is an interesting language, but I don't really know much about it. Seems like the first time I ever heard of D was in a BBS files listing back in the 90s. That must have been right around when it first came out. Since then I hear about it from time to time, but never checked it out, until yesterday, when I happen to have finally downloaded the compiler. I'm now looking for code samples, tutorials and such to get st…
D is an excellent mix of good design decisions, metaprogramming (your macros can run arbitrary code at compile time, a la zig), and a nice standard library. They also have some of the best API-building libraries available, and the compiler has the ability to run source code almost as if it were interpreted and it caches binaries under /tmp/ to avoid work if the source is unchanged.
Re: I Wrote a High-Frequency Trading Platform in D
#6D is an interesting language, but I don't really know much about it. Seems like the first time I ever heard of D was in a BBS files listing back in the 90s. That must have been right around when it first came out. Since then I hear about it from time to time, but never checked it out, until yesterday, when I happen to have finally downloaded the compiler. I'm now looking for code samples, tutorials and such to get st…
It's basically C++ done right. Much more easy to learn than C or C++ and be productive in it from day one. It won't become boring or annoying like Go, because the language is loaded with features and there's always something new to learn. It's garbage collected, so you don't need to worry too much abot allocating and freeing memory, but it's helpful to have an insight and understand how it works (there are articles a…
Re: I Wrote a High-Frequency Trading Platform in D
#7D is an interesting language, but I don't really know much about it. Seems like the first time I ever heard of D was in a BBS files listing back in the 90s. That must have been right around when it first came out. Since then I hear about it from time to time, but never checked it out, until yesterday, when I happen to have finally downloaded the compiler. I'm now looking for code samples, tutorials and such to get st…
Anyway D is a good language. It pays my bills.
You take from D what you bring. If you basically want to write C++ with nicer OOP you can, if you want to write heavy-metaprogramming functional code then you can as well.
The only thing I would say is that D is a language that does take a little programming experience to really appreciate.
Re: I Wrote a High-Frequency Trading Platform in D
#8Earlier quoted context omitted.
It's basically C++ done right. Much more easy to learn than C or C++ and be productive in it from day one. It won't become boring or annoying like Go, because the language is loaded with features and there's always something new to learn. It's garbage collected, so you don't need to worry too much abot allocating and freeing memory, but it's helpful to have an insight and understand how it works (there are articles a…
I'm a C guy and have played around with C++ back in the day, but have come to despise the language, with all of its increasing complexity, warts, design flaws, and footguns. I'm highly suspicious of Rust and Go as well. I prefer the C way of doing things, with no garbage collector, though I do tire sometimes of all the extra grunt work that goes into implementing anything in C. Looks like D has a lot of features gear…
Re: I Wrote a High-Frequency Trading Platform in D
#9When I have strings on performance-critical paths, unless they’re too long for a good reason, I sometimes pad them with \0 and limiting them to 16- or 32-bytes length. This way I can pass strings in a vector register by value (i.e. __m128i or __m256i data type in C++), and they’re very efficient to deal with. For instance, comparing them for equality only takes two instructions, vpxor and vptest (_mm_xor_si128 and _mm_testz_si128 intrinsics for 16-byte vectors), that’s 3-4 cycles of latency, an order of magnitude better than comparing traditional C or C++ strings.
I don’t have any experience with dlang though, not sure how easy or hard to implement that in D.
Re: I Wrote a High-Frequency Trading Platform in D
#10Earlier quoted context omitted.
It's basically C++ done right. Much more easy to learn than C or C++ and be productive in it from day one. It won't become boring or annoying like Go, because the language is loaded with features and there's always something new to learn. It's garbage collected, so you don't need to worry too much abot allocating and freeing memory, but it's helpful to have an insight and understand how it works (there are articles a…
I'm a C guy and have played around with C++ back in the day, but have come to despise the language, with all of its increasing complexity, warts, design flaws, and footguns. I'm highly suspicious of Rust and Go as well. I prefer the C way of doing things, with no garbage collector, though I do tire sometimes of all the extra grunt work that goes into implementing anything in C. Looks like D has a lot of features gear…
https://github.com/dlang-community/awesome-d
If you insist dissecting existing code, the Hunt library is well commented and seems more approachable. It uses OOP and some templates.