280 karma · joined October 25, 2021
Every time I've setup makefiles for projects someone always comes in and tries to make determining of dependencies happen before building rather than "determining dependencies as we build for the next build", which is just as robust. I don't know why software engineers always don't like that haha.
Either the reference is elsewhere (and now you have to dereference another area of memory occasionally which is the worst case for cache performance), or its alongside your object. If its alongside your object it's better to know it's there for padding, etc.
And it's easy to forget to allocate for the alongside case, so you can have hidden poor performance.
We did use some C++ standard library but very sparingly. For example, std::unique_ptr<> was fine, but std::shared_ptr<> was not because of the way it implicitly stores it's reference, so we had our own implementation that exposed the reference.
When I was doing console games this was a must. You would often have restrictions where the container itself should live in a different area of memory to the items which is much easier to manage with your own classes.
If a line is missing a newline then we just disregard it?!
A way better way to deal with newline is it's a separator like comma. And like in modern languages we allow a final separator, but ignore it so that is easier for tools to generate files.
Now all combinations of characters, including newline characters, has an interpretation without dropping anything.
Instead of stashing or anything like that we would commit with the text "WIP". Every time we had a stable point, we would make a "WIP" commit and then continue, giving us a good point to revert to if the next steps don't work.
If someone interrupts me I would make a WIP commit and then revert it and then make the change they're asking about.
Later on we would squash the WIP commits and make real commits out of the changes.
Another nice thing about this workflow is that everything goes into the reflog.
You could still beat them by tweaking for your hardware. But for the first time there was research into why Q sort is faster than heap sort
The only bit missing is some algorithm deciding how often to introduce new cards based on your historical data.
I definitely spent way too long on the "making the cards" phase!
FMAs were difficult. The Visual Studio compiler in particular didn't support purposeful FMAs for SSE instructions so you had to rely on the compiler to recognise and replace multiply-additions. Generally I want FMAs because they're more accurate but I want to control where they go.
Every 754 architecture (including SSE) I've worked on has an accurate sqrt().
I'm assuming you're talking about with "fast math" enabled? In which case all bets are off anyway!
The slowing down on Intel platforms has always frustrated me because denorms provide nice smoothing around 0.
At the same time it was nice only having to consider normal floating point when trying to get more accuracy out of calculations, etc.
Unless of course we are talking about the 80 bit format.
If that's not the case, would be interested to know where they differ.
Unfortunately for the transcendental function the accuracy still hasn't been pinned down, especially since that's still an ongoing research problem.
There's been some great strides in figuring out the worst cases for binary floating point up to doubles so hopefully an upcoming standard will stipulate 0.5 ULP for transcendentals. But decimal floating point still has a long way to go.
So I started reverse engineering the Winamp skinning engine with the intention of making an engine that can run it on one of the Linux media apps. I did this by writing short programs and looking at the generated binary.
I had about 95% of it figured out when we had a robbery and the thief took the laptop I was using. By the time I got a new machine I had completely lost interest!
I wouldn't be surprised if it was using a well known VM that I just didn't know about at the time!
I haven't done this stuff for quite a while, so my memory might be foggy, but the main advantage of Vulcan was that you can control all the CPU locking rather than the API doing it. This allows you to do stuff like prepare on one thread and submit on another, etc.
But that would be negated if you're using an abstraction layer.
So that leaves blog posts for most developers actually implementing this stuff.
But the solution here is that when you finally figure out a good strategy to deal with something muddy like this is to write that better blog post :)
I'm not in the US, so I could easily be off base.
I really enjoyed The Time Ships by Stephen Baxter, which is a sequel to The Time Machine by H. G. Wells. He's a UK author, so maybe it's different.
As a society I think we are better off with this kind of remixing so I'd hope that's the direction we head in.
897 is about 900. 394 is about 400. 900×400 = 360,000. Only 2% error!
We would still use refactoring tools even though they would often miss stuff. You just rely on a combination of refactoring tool / search and replace / the compiler.
We would also debug our code in release mode with symbols. You get used to a debugging environment where you don't trust anything you're seeing in variables, etc. too.
Now that I'm doing more application development it's sitting on my bookshelf looking neglected.
It wasn't bad actually. We had macros to do 16 bit work with 8 bit registers, etc. so the code was much more high level than it sounds. We did have to be very careful with the stack (making sure it's balanced), but otherwise very similar to coding in C.
With modern architectures, I much prefer C and intrinsics and let the compiler deal with it (and nudge it when it gets it wrong).
It is great that the spec is YAML because that's quick to get up and running. It was just unfortunate that the expression language is custom string, i.e. not YAML.
It may have improved, but at the time the custom language wasn't unambiguously specified either.
I told my teacher I don't need to touch type (I could already use a keyboard from tons of programming) so she said if I could beat her I could sit it out. I beat her and she kept up her end of the bargain.
However years later I wish I had just sucked up my pride and learnt it because I had to eventually anyway. It wasn't so useful for programming, but it's great for text (emails, etc.).
I find it interesting that in your view most people aren't touch typist. My experience (now in Australia) is that most people touch type. Although, there does seem to be a spectrum of purity. e.g. my fingers always remain on the home rows, but I use left shift for all capitals except Q, A, Z (when I'm using QWERTY).
Set the exponent to 0 and stuff in bits for the significand. This gets you a random float in the range [1,2). Now subtract 1.0.
Note that this misses many floating point values that should be selectable if you wanted all floats between 1 and 2, but it was good enough for video games.
It's worth pointing out that IEEE 754-2008 has decimal numbers like you describe without the hidden bit. But for decimals this can be really useful because numbers "remember" their exponent. So if you're doing addition of dollar values, for example, .84 + .12 = 1.00 rather than 1 (i.e. it remembers its significant digits).