Computer Science An Overview _J. Glenn Brookshear _11th Edition

Chapter 6 Programming Languages

As suggested in Section 6.1, high-level programming languages allow locations in main memory to be referenced by descriptive names rather than by numeric addresses. Such a name is known as a variable, in recognition of the fact that by changing the value stored at the location, the value associated with the name changes as the program executes.

--

Early Generations

As we learned in Chapter 2, programs for modern computers consist of sequences of instructions that are encoded as numeric digits. Such an encoding system is known as a machine language. Unfortunately, writing programs in a machine language is a tedious task that often leads to errors that must be located and corrected (a process known as debugging) before the job is finished.

In the 1940s, researchers simplified the programming process by developing notational systems by which instructions could be represented in mnemonic rather than numeric form.

For example, the instruction

Move the contents of register 5 to register 6

would be expressed as

4056

using the machine language introduced in Chapter 2, whereas in a mnemonic system it might appear as

MOV R5, R6.

As a more extensive example, the machine language routine

156C

166D

5056

306E

C000

which adds the contents of memory cells 6C and 6D and stores the result at location 6E (Figure 2.7 of Chapter 2) might be expressed as

LD R5,Price

LD R6,ShippingCharge

ADDI R0,R5 R6

ST R0,TotalCost

HLT

using mnemonics. (Here we have used LD, ADDI, ST, and HLT to represent load, add, store, and halt. Moreover, we have used the descriptive names Price, ShippingCharge, and TotalCost to refer to the memory cells at locations 6C, 6D, and 6E, respectively. Such descriptive names are often called identifiers.)

Once such a mnemonic system was established, programs called assemblers were developed to convert mnemonic expressions into machine language instructions. Thus, rather than being forced to develop a program directly in machine language, a human could develop a program in mnemonic form and then have it converted into machine language by means of an assembler.

A mnemonic system for representing programs is collectively called an assembly language. At the time assembly languages were first developed, they represented a giant step forward in the search for better programming techniques. In fact, assembly languages were so revolutionary that they became known as second-generation languages, the first generation being the machine languages themselves.

--programming languages - assembly language - identifiers -  mnemonic -

locations in main memory to be referenced by descriptive names rather than by numeric addresses的更多相关文章

  1. he time that it takes to bring a block from disk into main memory

    DATABASE SYSTEM CONCEPTS, SIXTH EDITION There is a trade-off that the system designer must make betw ...

  2. Main Memory Object-Relational Database Management System

    Main Memory Object-Relational Database Management System FastDBMain Memory Relational Database Manag ...

  3. Power Management of Hybrid DRAM/PRAM-Based Main Memory

    0.ABSTRACT (1)non-volatile memory——low standby power DRAM——high performance and better active power ...

  4. Types of Computer Systems

    Types of Computer Systems Para 1 You should be familiar with the differences among computer systems ...

  5. Custom Settings.in 配置信息收集

    [Settings] Priority=Default Properties=MyCustomProperty [Default] ;是否允许部署操作系统到目标计算机 OSInstall=YES ;是 ...

  6. Method and apparatus for providing total and partial store ordering for a memory in multi-processor system

    An improved memory model and implementation is disclosed. The memory model includes a Total Store Or ...

  7. Memory Allocation with COBOL

    Generally, the use of a table/array (Static Memory) is most common in COBOL modules in an applicatio ...

  8. C++ TUTORIAL - MEMORY ALLOCATION - 2016

    http://www.bogotobogo.com/cplusplus/memoryallocation.php Variables and Memory Variables represent st ...

  9. Partitioned Replacement for Cache Memory

    In a particular embodiment, a circuit device includes a translation look-aside buffer (TLB) configur ...

随机推荐

  1. wp8 --未找到与约束ContractName Microsoft.VisualStudio.Text.ITextDocumentFactoryService...匹配的导出

    今天打算用VisualStudio2012做一个js效果页面测试的时候,打开VS2012新建项目,但是并没有像之前那样顺利的创建页面,而是弹出了一个错误窗口. 我的系统是win8专业版 64位 ,同时 ...

  2. 对Android项目中的文件夹进行解释

    对Android项目中的文件夹进行解释: · src:里面存放的是Activity程序,或者是以后的其他组件,在此文件夹之中建立类的时候一定要注意,包名称不能是一级. · gen:此文件夹中的内容是自 ...

  3. hdu 4586 Play the Dice 概率推导题

    A - Play the DiceTime Limit: 20 Sec Memory Limit: 256 MB 题目连接 http://acm.hust.edu.cn/vjudge/contest/ ...

  4. 2016.6.11 ASP提交数据到SQL server数据乱码解决方法

    1.检查数据库排序规则 China-PRE-90-CS-AI 2.ASP文档中,写入数据的页面的编码和检查提交数据页面的编码一致:

  5. 2015ACM/ICPC亚洲区长春站 L hdu 5538 House Building

    House Building Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others) ...

  6. BZOJ2610 : [Poi2003]Monkeys

    考虑离线,将删边操作倒过来变成加边,等价于询问每个点什么时候与1连通 使用并查集维护,每次合并时如果有一边是1所在连通块,就把另一边的所有点的答案更新 #include<cstdio> # ...

  7. TextBlock 格式化内容

    Text="{Binding ContentName,StringFormat=分享好书\{0\}}"

  8. CentOS 拷贝mysql数据库到新的硬盘报错了

    服务器硬盘满了,加了一块,在目录 下新建了 mkdir /mysql cp -r /var/lib/mysql/* /mysql chown -R mysql:root /mysql 更改/etc/m ...

  9. Shell 操作练习2

    #! /bin/sh ############################### # -- # # author jackluo # # net.webjoy@gmail.com # ###### ...

  10. asp.net 微信企业号办公系统-流程设计--流转条件设置(路由)

    当一个步骤后面有多个步骤时,可以设置为根据设置条件系统自动判断该流向哪些步骤,也叫路由. 工作流没有单独的路由步骤来设置条件,流程条件通过双击连线弹出条件设置框来设置. 1.sql条件 即通过sql条 ...