Difference between: Opcode, byte code, mnemonics, machine code and assembly

后端 未结 6 1493
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-12 12:35

I am quite new to this. I tried to understand the difference between the mentioned terms in a clear fashion, however, I am still confused. Here is what I have found:

6条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-12 12:36

    "Assembly" originates from the very early code "assemblers" which would "assemble" programs from multiple files (what we would now call "include" files). (Though note the "files" were often card decks.) The use of the term "assembly language" to refer to a mnemonic representation of the code is a back-formation from "assembler", and somewhat imprecise, since a number of "assemblers" do not support include files and hence do not "assemble".

    It's interesting to note that "assemblers" were invented to support "subroutines". Originally there were "internal" and "external" subroutines. "Internal" subroutines were what we would now call "inline", whereas "external" ones were reached via a primitive "call" mechanism. There was much controversy at the time as to whether "external" subroutines were a good idea or not.

    "Mnemonic" comes from the name of the Greek god Mnemosyne, the goddess of memory. Anything that helps you remember stuff is a "mnemonic device".

提交回复
热议问题