4 ms·
Yes the machine can do those things, you're right. If that's all you meant then sure the abstraction is enough. But you can learn those broad concepts using Pyt
by ChrisSD 7y ago
Yes the machine can do those things, you're right. If that's all you meant then sure the abstraction is enough. But you can learn those broad concepts using Python if you want to.
However, what the machine is actually doing can differ substantially from these naive models. An algorithm that should be slower according to the C model can in reality be fast. Registers, cache levels, vectorization, etc are all concepts that C doesn't teach. Compilers often have extensions to C that enable more direct access (and also do things like adjust memory layout) but at that point you're no longer using the C model.
Optimizing compilers (and even cpus themselves) also do a good job of trying to uphold the abstraction but at the end of the day it's still leaky.
So knowing what the machine is actually doing is helpful.