Most of the stuff went over my head, Why should I care that C is no longer low-level? What exactly is considered close-to-metal in today’s time, apart from binary and assembly?

  • @Blue_Morpho
    link
    172 months ago

    The author is confusing two completely different things and comes to a wrong conclusion.

    He states that C isn’t low level because CPU are much more complex today. But those aren’t related. His argument would be no different if he claimed assembly isn’t a low level language.

    That the CPU speculatively executes instructions and maintains many levels of cache doesn’t change that C is low level. Even if you wrote a program in OP codes you can’t change that.

    There was a single paragraph to support his argument that was optimizing compilers can create machine code wildly different than what might be expected.

    Then he goes off on a complete tangent of how C isn’t good for parallel processing which has nothing to do with his thesis.

    • @[email protected]
      link
      fedilink
      52 months ago

      I think for these types of discussions it’s really necessary to clearly define what “low level” really means, something both you and the author kinda skip over. I think a reasonable definition is about the amount of layers of abstraction between the language’s model of the machine and the actual hardware.

      The author is correct that nowadays, on lots of hardware, there are considerably more abstractions in place and the C abstract machine does not accurately represent high performance modern consumer processors. So the language is not as low level as it was before. At the same time, many languages exist that are still way higher level than C is.

      I’d say C is still in the same place on the abstraction ladder it’s always been, but the floor is deeper nowadays (and the top probably higher as well).

      • @Blue_Morpho
        link
        2
        edit-2
        2 months ago

        So the language is not as low level as it was before.

        But it’s the hardware that has changed not C. As I said, with his argument Assembly isn’t a low level programming language either.

        Besides, early risc cpus from the 80’s had out of order write back so this isn’t new. By the 90’s all risc were ooe. The first was the ibm 360 from the 1960’s.

        I’d say C is still in the same place on the abstraction ladder it’s always been, but the floor is deeper nowadays (and the top probably higher as well).

        I agree!