Ever want to see what assembly code your compiler is really generating?
There are a few reasons to want to know this. Firstly is correctness. Sometimes obscure bugs can crop up when you switch from one compiler to another, from one set of optimization settings to another, from debug to release, or even from one compiler version to another.
The second is optimization. What addressing mode(s) are being used, are there data hazards that are slowing things, are simd instructions being used? Game and high performance compute companies still spend time pulling every cycle they can out of a routine.
It used to be you had to compile and then pull the executable into a debugger and examine the code. Now, there’s an online tool that can quickly do the same. Enter the Godbolt compiler explorer.
It allows you to type in C/C++ code, select from a whole host of compilers, enter custom compiler flags, then show you the generated output.
In the case above, I wanted to verify C/C++ short-circuit comparison behavior of a variable against NULL and then dereference in the same conditional. If the compare against NULL doesn’t execute and exit before the dereference, a NULL pointer exception/segfault will result. According to C/C++ rules, there should be an early out after the comparison against NULL – and sure enough – on line 8 and 9 we see the test and exit.
Anyway – it’s a neat online tool you might give a try to learn more about the assembly your C/C++ code turns into.
There are some off-the-shelf kits out there for building colorful LED cubes, but Mike Caan’s light cube features a whopping 24,576 RGB LEDs across its six 64×64 faces, each capable of displaying animations and videos uploaded from his computer. It also has a gyro and other cool features.
I wrote previously about the 1 Euro homes for sale:
Some time has now passed, and interviewers are starting to get the stories from those that gave it a try. The reality is that they have cost much more than $1 – but it has still has worked out great for many that tried it. Worth a listen.
How the Unreal game engine and a nearly 360 degree video wall has transformed how special effects are done. It’s a complete game changer because it solves almost all the problems relating to green screens and digital effects.
I think they wanted things to come easy for them. They didn’t want to work for a transformative experience. They didn’t want to help other people achieve a transformative experience. I find them all very selfish.
I still have trouble figuring out how a person crosses a line in their own mind, to be willing to hurt another person to get what they want. I think once you’ve crossed that line, I think it’s a dangerous line to cross.
It makes me wonder if they really know why they did it.
-Betty Jean Gouch
American Animals is a 2018 movie based on the true story of four young men who attempt to execute an audacious (and ill executed) art heist by stealing 2 rare Audubon books from a nearby library’s special collections. Struggling to find meaning in their dull lives, they formulate a daring plan for the robbery only to watch their mistakes and reality catch up with them.
The quote comes one of the real life office workers who encountered them when they tried to steal the books. Of all the characters, I think she grasps the humanity of the situation the best.