4 ms·
Well it's really a balance. Looking at the CPU, these days the x86 instruction set is a total illusion--the CPU decodes those instructions so a totally differen
by jdcarter 10y ago
Well it's really a balance. Looking at the CPU, these days the x86 instruction set is a total illusion--the CPU decodes those instructions so a totally different underlying architecture can take action on them. The block diagram for a modern processor is astounding.
Back when I was working on Motorola 68K processors and creating hardware drivers, learning to work with assembly helped me tremendously with basic principles like pointers/registers, stack/heap, memory-mapped IO, and so-forth. How the processor worked inside wasn't really the point; working with assembly made me a better C programmer.
The point isn't so much that you have to keep peeling back the layers of the onion so far that you can understand how the silicon is laid out, you just need to peel back a couple more layers than you're used to. If you're a Ruby programmer, for example, write a C extension. It'll be enlightening.
- hashkb 10y ago> The point isn't so much that you have to keep peeling back the layers of the onion so far that you can understand how the silicon is laid out, you just need to peel back a couple more layers than you're used to. If you're a Ruby programmer, for example, write a C extension. It'll be enlightening. Thanks, this is just right. You don't have to meet the turtle on the bottom, but you should be acquainted with a few turtles down.
- uola 10y agoI'm not sure running on AWS instead of on your own server is actually going down a turtle. I run pretty much everything myself, but that is mostly dealing with complexity which isn't very enlightening. Might very well be that someone who uses a provider gets a better understanding of infrastructure design.
- dredmorbius 10y agoRunning on AWS is going up at least one turtle, possibly several if you're throwing configuration management and deployment tools into the mix. AWS abstracts out bare-metal through Xen, deployment images, the AWS control panel, its monitoring, and the fact that you can't physically grab and yank the server should you want to. On bare metal, you've removed most of those layers, though you have the option of putting most of them back in. I find the head for AWS vs. bare-metal admin to be quite different. Being old school, I prefer metal.
- uola 10y agoI'm just not sure that those layers are actually functional. I see little reason why things couldn't be more like AWS if there were standardized ways to e.g. configure things. A lot that one deals with is glue between the turtles and not necessarily the other turtle.
- dredmorbius 10y agoEverything is glue between turtles. It's glue between turtles all the way down. (A problem now is that the glue is nonstandardised, and you've got vendor-specific glue, much of it with craptacular Web interfaces, at various levels. We used to have this in other parts of the stack, but they eventually got commoditised, and those particular layers went away. If you haven't done it before, crack open a Sendmail.cf file. If you have done it before, I'm truly sorry for the flashbacks.)
- vvanders 10y agoYup, even a basic understanding of CPU caches will go a long way to help you work out performance. It's very realistic to see 10-50x with just simple data layout patterns.