The case for the reduced Instruction Set computer读后感

来源:互联网 发布:ps合成图片软件 编辑:程序博客网 时间:2024/05/16 12:43

The case for the reduced Instruction Set computer读后感

计算机体系结构的目标

One of the primary goals of computer architexts is to design computers that are more cost-effective than their predecessors.

计算机体系结构设计的目标就是保证比之前的产品具有更高的成本效益。成本效益包括用于制造计算机的硬件成本、软件花费、在初始硬件和随后程序调试及测试所需的费用。在过去计算机发展的历史中,CISC是一种趋势。但本文认为CISC是弊大于利的,RISC才是下一代超大规模集成电路更好的解决方案。

复杂性增加的原因

存储的速度vsCPU处理速度

John Cocke says that the complexity began with the transition from the 701 to the709.The 701 CPU was about ten times as fast as the core main memory;this made any primitives that were implements as subroutines much slower than primitives that were instructions.

可以看出由于701CPU速度与核心主存储器速度差异,导致了用子程序实现的原语要比指令实现的原语慢的多。而在709中由于复杂度的提高进而实现了成本效益的提高。由此我们可以直到CISC趋势源于CPU与存储器速度的失衡。

微代码和大规模集成电路

Microprogrammed control allows the implementation of complex architectures more cost-effectively than hardwired control.Advances in integrated circuit memories made in the late 60’s and early 70’s have caused microprogrammed control to be the more cost-effective approach in almost every case.

集成电路技术的使得在大多数情况下微程序控制成为了最经济的方式,而这种解决方案把指令集的拓展成本降低到极致。同时技术的发展导致了传统的子程序方式在计算机体系架构中被广泛应用。而子程序的应用广泛则需要依靠CISC来提升性能。这一点在存储的速度vsCPU处理速度有说明。

代码密度

With early computers, memory was very expensive. It was therefore cost-effective to have very compact programs. Complex instruction sets are often heralded for their “sup- posed” code compaction. Attempting to obtain code density by increasing the complexity of the instruction set is often a double-edged sword however, as more instructions and addressing modes require more bits to represent them.

计算机发展的早期过程,存储器的价格是非常昂贵的, 而对存储器资源的有效利用降低成本是一个需要着重考虑的方面。而有效利用存储资源必须要对代码进行压缩,提高代码密度,通过增加指令集的复杂性可以达到这一目的。但这一解决方案是一把双刃剑,它提升代码密度的同时也会占用更多资源,降低单片机的性能。

营销策略

Unfortunately, the primary goal of a computer company is not to design the most cost-effective computer; the primary goal of a computer company is to make the most money by selling computers.

比追求设计成本效益更重要的事情是最求更高的利润。CISC在这里作为了一种营销手段而存在,电脑公司试图向消费者说明, 他们的电脑拥有更复杂的指令集,所以性能会比其他公司的更加优秀。

向上兼容性

Coincident with marketing strategy is the perceived need for upward compatibility. Upward compatibility means that the primary way to improve a design is to add new, and usually more complex, features. Seldom are instructions or addressing modes removed from an architecture, resulting in a gradual increase in both the number and complexity of instructions over a series of computers.

在计算机的发展过程中,向上兼容性是一个需要考虑的问题。 而为了实现向上兼容,增加更多以及更复杂的指令是主要的方式。与此同时,指令集的删减则是极少数会出现的情况。这两个原因使得指令集变得越来越复杂。而新的架构方式中往往会选择继承过去架构中最竞争力最强的那一套(往往指令集也是最复杂)的指令集。

支持高级语言

As the use of high level languages becomes increasingly popular, manufacturers have become eager to provide more powerful instructions to support them.

制造商试图提供更复杂更有效的指令集来支持高级语言。但是几乎没有证据证明CISC对高级语言拥有更好的支持,与此相反很多情况下CISC的应用对高级语言的支持是负作用的。

多道程序设计

plex instructions and addressing modes increase the state that has to be saved on any interrupt. Saving this state often involves the use of shadow registers and a large increase in the complexity of the microcode.

分时系统对计算机中断响应提出了要求,要求实现保护现场,当进程停下后仍旧能重新开始。而CISC对中断保存点提出了更多的需求,由此也带来了寄存器大规模的使用以及大规模复杂伪代码的增加。如果没有复杂指令的负面影响,机器复杂性将会大大降低。

CISC如何应用?

ilers are often unable to utilize complex instructions, nor do they use the insidious tricks in which assembly language programmers delight.

软件成本的增加导致了对高级语言的依赖程度的增加。高级语言往往拥有更快的开发速度,能够降低开发的成本。这些事实带来的一个影响之一就是编译器正在逐渐取代汇编器。但大部分编译器都无法使用复杂的指令,最终的结往往是只有部分指令集被使用,这也说明RISC有其应用的可能。

CISC机实现的结果

更快速的存储

advances in semiconductor memory have made several changes to the assumptions about the relative difference in speed between the CPU and main memory.

主存与CPU速度的失衡是CISC趋势的起点,而随着技术的发展,存储器的速度越来越快。同时利用高速缓存进一步弥补了CPU主存速度失衡带来的影响。

不合理的实现

ps the most unusual aspect of the implementation of a complex architecture is that it is difficult to have “rational” implementations.

特殊的/有目的的指令未必比一系列简单的指令执行的快,因为无法保证这些特殊的指令所采取的实现是最合理的。一些事实说明在一些情况下,一系列装载指令要比一条多装载指令快的多。进一步能够说明,更少的指令(将一系列简单指令组合后实现的功能用一条复杂的指令去 ,所以更少)并不意味着更快的速度,高级的指令也不意味着更快的速度。

设计时间的延长

Even though the replication costs of a CISC may be low, the design time is greatly expand.

尽管CISC提供了一系列复杂的指令来保证开发程序的效率,但CISC本身在实现的过程中需要相当高的时间成本。

设计错误的增加

One of the major problems of complex instruction sets is debugging the design; this usually means removing errors from the microprogram control.

复杂的指令集往往意味着设计难度的增加,而随着产品的更新换代,设计的难度也会一直增加(有前文向上兼容性分析可知,指令集会越来越复杂)。而难度的增加,往往会带来更多的设计错误。

RISC与超大规模集成电路

随着超大规模继承电路的发展,更多的因素表明RISC设计方向更加合理。

实现的灵活性

A great deal depends on being able to fit an entire CPU design on a single chip.

复杂的架构与精简架构相比较而言,更难在现有技术的条件下实现单一芯片的设计。而实现的灵活性很大的程度依赖于在单一芯片上实现完整的CPU设计的能力。VLSI技术的发展使在单一芯片上实现CPU成为可能,而采取RISC架构毫无疑问有利于这种实现。

设计时间

Design difficulty is a crucial factor in the success of VLSI computer.

倘若VLSI技术发展每两年可以使片密度至少翻倍,那么两年后则可以采取更高效的设计。一个例子可以说明一些问题:从设计到交付PDP-1仅仅花费了DEC六个月的时间,但是却需要花费至少三年的时间完成诸如VAX等机器的设计。若VLSI也采取这种模式,那就意味着设计一直处于一种过时的状态。

速度

The ultimate test for cost-effectiveness is the speed at which an implementation executes a given algorithm.

芯片资源的有效使用以及通过应用新技术减少调试时间。采用RISC可以实现精简设计,进而提升速度。简单的寻址模式以及指令将导致控制结构的简单。这将导致更小的控制PLA、更小的微代码存储、机器关键路径更少的门电路。而这些所有的因素都可以使得周期时间更短,速度更快。

芯片资源的更好使用

As VLSI technology improves, the RISC architecture can always stay one step ahead of the comparable CISC.

较CISC而言,本文觉得芯片可以通过设计更吸引人的RISC机获得更高的收益。当CISC架构可以在单芯片上实现时,RISC可以应用流水线技术;当CISC应用流水线技术时,RISC开始采用片上cache,等等。对于先进的技术,CISC机往往更难实现。

支持高级语言的计算机系统

高级计算机语言系统的定义:

  • Uses high-level languages for all programming, debugging and other user~system interactions.
  • Discovers and reports syntax and execution time errors in terms of the high-level language source program.
  • Does not have any outward appearance of transformations from the user programming language to any internal languages.

最重要的特性是软硬件协同特性,这一特性保证了程序员总是通过高级语言与计算机进行交互。在编写程序时,程序员不需要了解计算机底层的实现情况。从高级语言的层面出发,计算机采用RISC还是CISC对它而言,没有什么必然的关系。但从前文对编译器与汇编器的讨论可知,编译器正逐渐取代汇编器,在这一过程中,RISC更为合适。

RISC架构的应用

By a judicious choice of the proper instruction set and the design of a corresponding architecture, we feel that it should be possible to have a very simple instruction set that can be very fast. This may lead to a substantial net gain in overall program execution.

在Berkeley,Bell实验室以及IBM中已经有一些RISC的成功应用。一些命题也得到 :RISC相比CISC,成本更低。在实验的过程中32位的RISC设计开始被提出。倘若能够证明简单的架构能够与CISC一样有效的支持高级语言,那么就完成了有效的设计。

结论

We have assumed that it is worthwhile to minimize the “complexity” (perhaps measured in design time and gates) and maximize “performance” (perhaps using average execution time expressed in gate delays as a technology-independent time unit) while meeting the definition of a High-Level Language Computer System.

The case for the reduced Instruction Set computer这篇文章通过对CISC与RISC的设计/应用/实现的讨论,认为RISC是提升计算机性能的有效途径,RISC可以减小复杂性提升性能并且适用于高级语言计算机系统。RISC是在VLSI和存储速度的提升的背景下被提出的,在进行RISC与CISC的讨论时,我们要依托计算机发展的背景,关注体系结构技术的发展。

0 0