3 ms·
>if C is not a portable low-level language, what on earth is? This question doesn't have to have an answer. The author of TFA apparently believes that a low-le
by scythe 3y ago
>if C is not a portable low-level language, what on earth is?
This question doesn't have to have an answer. The author of TFA apparently believes that a low-level language is one that effectively and clearly exposes the execution model of the hardware to the programmer. Under this definition, no widespread language (except assembly) is truly low-level, and possibly none are.
Which, for what it's worth, is also what I was taught in school. C was consistently described as a high-level language by my professors, even if it is "lower-level" than almost everything else.
- gpderetta 3y agoThe real question is whether you would even want to use a language that effectively and clearly exposes the execution model of the hardware. Not even most assemblers do that as architectures give stronger guarantees that would be implied by the microarch execution model. Some machines do expose the microarchitecture (or better, there is no architecture other that what is implemented in hardware by a specific revision) and rely on install-time or even JIT code specialization. But especially on this machines it would be insane to try to manually target them as you would have to rewrite your code for every revision. So, targeting the effective execution model of the machine is out of question. You need an abstraction. The question is whether C is the correct abstraction.