青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品

posts - 71,  comments - 41,  trackbacks - 0
? 2003 by Charles C. Lin. All rights reserved.

Register File, Part 1

Consider a typical R-type instruction.
   add $r10, $r3, $r4   # R[10] = R[3] + R[4]
The first step to executing this instruction is fetching the operands. In this case, we need to get the values of $r3 and $r4.

Recall that the CPU processes a 32-bit machine code instruction that's translated from the assembly code above, and encoded in that instruction are the 3 registers. In particular, each of the register is encoded using 5 bit UB.

For example, register 3 is encoded as 00011 and register 4 is encoded as 00100.

We're going to create a circuit called a register file. This circuit contains all 32 user-visible integer registers. We could create one for floating point, but that's not absolutely necessary. You'll still understand how a CPU works if we leave out floating point registers (they work pretty much like the integer registers).

We want the ability to access both registers (in this case, $r3 and $r4) at the same time. That way, we can save time. If we have to access one register at a time, it would slow down the execution of the instruction.

So, we have two sets of inputs to our register file, which specify which two registers we want. They can even be the same register.

Here's how our initial register file looks:

We've labelled the inputs as SRC 1 Index and SRC 2 Index, which are 5 bits each. We can think of registers 3 and 4 and source registers, and their result is stored in the destination register (in our example, it's $r10).

Register File, Part 2

However, we need the register file to have outputs. These outputs are going to be 32 bits each since each register in MIPS32 has 32 bits. The outputs are the contents of the registers specified by SRC 1 Index and SRC 2 Index. Thus SRC 1 Data is the contents of the register specified by SRC 1 Index, and SRC 2 Data is the contents of the register specified by SRC 2 Index.

Register File, Part 3

At this point, the two 32-bit outputs are sent to the ALU (we'll discuss the ALU in more detail soon). The ALU does computations on these and produces a 32-bit result. This result is saved back into the destination register. The register file needs 32-bit data as input as a 5-bit index. We'll call these DST Index and DST Data for short.

The DST Index comes from the instruction itself, just as SRC 1 Index and SRC 2 Index did. In our example, that's the encoding of $r10 (which is 01010).

It turns out we need one more input, in addition to DST Index and DST Data. Even though this particular instruction updates a destination register, not every instruction does so. We want to control when a register value is updated in the register file.

This control signal is called RegWrite and it's only 1 bit. If RegWrite = 1, then a write is performed on the register specified by DST Index, using the 32-bit data given by DST Data. If RegWrite = 0, then no write is performed. Both DST Index and DST Data are ignored.

Which reminds me, we have to talk about a clock. The register file also has a clock. The diagram below is now complete.

Why no RegRead?

You may wonder why there's no RegRead to control when the register file outputs SRC 1 Data and SRC 2 Data.

The reason is simple. SRC 1 Data and SRC 2 Data are sent to the outside world (i.e., to other parts of the CPU). Those parts can simply choose to ignore the data, if they don't need it.

However, when you are performing a write on a register using DST Index and DST Data, you are updating the register file. The register file can't very well ignore that. To give it the option to ignore it, we must include RegWrite.

Clocks

The register file should be thought of as partly using the clock and partly not.

SRC 1 Data and SRC 2 Data are output with a small delay given a change in SRC 1 Index and SRC 2 Index. If you're curious about the implementation (or, more precisely, if you're curious about an implementation), look at the MAR from the previous set of notes.

You can see that it's hooked up to tri-state buffers. Once the tri-state buffers are enabled (which doesn't require a clock), the output is sent to the address bus.

Similarly, SRC 1 Index and SRC 2 Index enable two 32-bit tri-state buffers. In particular, they enable the tri-state buffers to the registers specified by SRC 1 Index and SRC 2 Index.

Again, this part does not need a clock. If SRC 1 Index and SRC 2 Index both change, then the tri-state buffers associated with the new registers are enabled (while the previous ones are disabled), and they are output after a small delay.

Writing Requires a Clock

However, when you want to write to a register, you are performing a parallel load on that register. This operation relies on a clock. We're going to assume that the register file, like MAR and MDR, is loaded on negative edges. This allows computations to be performed by the rest of the CPU before registers are loaded.

Summary

A register file is a black box that contains 32 32-bit registers. At any one time, you can specify up to two registers to "read" and one register to write, with the option to decide whether you want to write or not.

Reading a value from the register file does not require a clock. Once you specify the registers you want to read (i.e., SRC 1 Index and SRC 2 Index), then there's only a small delay before the data comes out of the register file via SRC 1 Data and SRC 2 Data.

Writing a value to the register file does require a clock. You can specify which register you want to write to (using DST Index), the data you want to write (using DST Data) and whether you really want to write to the register file or not (using RegWrite). This action takes place on the negative edge of the clocks. (Positive edges are used to transition in the finite state machine and set up control signals for ALU, MUX, tri-state buffers, etc).

posted on 2007-01-24 09:25 Charles 閱讀(899) 評論(0)  編輯 收藏 引用 所屬分類: 拿來主義
<2006年11月>
2930311234
567891011
12131415161718
19202122232425
262728293012
3456789

決定開始寫工作日記,記錄一下自己的軌跡...

常用鏈接

留言簿(4)

隨筆分類(70)

隨筆檔案(71)

charles推薦訪問

搜索

  •  

積分與排名

  • 積分 - 52089
  • 排名 - 448

最新評論

閱讀排行榜

評論排行榜

青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            欧美黑人在线播放| 亚洲一区免费网站| 免费成人在线观看视频| 国内久久婷婷综合| 免费看的黄色欧美网站| 久久久久久久久蜜桃| 亚洲国产精品久久久久秋霞蜜臀| 久久综合网hezyo| 能在线观看的日韩av| 日韩午夜高潮| 亚洲欧美在线x视频| 国产日韩精品一区二区三区| 老司机精品视频网站| 欧美成人嫩草网站| 亚洲小少妇裸体bbw| 性欧美大战久久久久久久免费观看 | 国产欧美日韩中文字幕在线| 欧美主播一区二区三区| 久久女同精品一区二区| 亚洲精品一区二区在线| 亚洲视频一区二区| 国产一区二区在线观看免费| 亚洲国产综合在线| 欧美视频网站| 猫咪成人在线观看| 欧美精品18+| 久久久精彩视频| 欧美日韩岛国| 久热爱精品视频线路一| 欧美日韩在线免费| 免费成人美女女| 国产精品毛片在线| 亚洲盗摄视频| 国产一区二区久久精品| 日韩视频一区二区| 影音先锋日韩有码| 亚洲一区二区三区久久| 亚洲日本va午夜在线电影| 亚洲在线免费观看| 一区二区欧美国产| 久久综合网色—综合色88| 亚洲欧美一区二区精品久久久| 免费的成人av| 久久国产日韩| 国产精品久久久久影院色老大| 亚洲第一在线| 在线观看成人网| 亚洲欧美日韩国产一区| 一本久久青青| 免费观看成人www动漫视频| 久久精品国产99精品国产亚洲性色 | 亚洲视频香蕉人妖| 日韩图片一区| 欧美高清视频一二三区| 久热成人在线视频| 国产一区二区在线观看免费| 亚洲深爱激情| 亚洲一区免费在线观看| 欧美乱人伦中文字幕在线| 欧美国产日韩亚洲一区| 韩国三级在线一区| 欧美一区二区视频免费观看| 午夜精品视频网站| 国产精品久在线观看| 99在线热播精品免费| 999在线观看精品免费不卡网站| 久久久久五月天| 久久男人av资源网站| 国产视频在线观看一区二区三区 | 欧美国产免费| 91久久精品www人人做人人爽| 久久免费视频一区| 欧美成人精品不卡视频在线观看| 国产在线精品成人一区二区三区 | 女人天堂亚洲aⅴ在线观看| 国产日韩亚洲| 久久精品系列| 欧美国产一区二区三区激情无套| 91久久精品一区二区别| 亚洲视频你懂的| 免费在线欧美视频| 国产一区亚洲| 久久乐国产精品| 欧美国产亚洲另类动漫| 一区二区欧美在线观看| 亚洲一区二区三区成人在线视频精品| 一本色道久久综合狠狠躁篇怎么玩| 亚洲一区在线免费| 国产精品久久网| 欧美在线亚洲| 亚洲国产精品成人久久综合一区| 久久久www免费人成黑人精品 | 亚洲精品一区二| 欧美日韩大陆在线| 午夜国产精品视频免费体验区| 久久久欧美一区二区| 亚洲激情欧美激情| 国产精品老牛| 久久久久在线| 制服丝袜亚洲播放| 免费观看成人www动漫视频| 亚洲美女精品久久| 国产日韩亚洲欧美精品| 麻豆久久久9性大片| 一区二区三区蜜桃网| 久久综合久久综合久久| 中国亚洲黄色| 黄色工厂这里只有精品| 欧美视频官网| 久久天天躁狠狠躁夜夜av| 夜夜爽夜夜爽精品视频| 麻豆精品视频在线观看| 亚洲欧美经典视频| 亚洲精品视频在线| 国产午夜精品理论片a级大结局| 欧美电影在线| 久久久久久网址| 亚洲自拍另类| 亚洲美女视频在线观看| 久久午夜视频| 久久福利精品| 亚洲欧美在线播放| 夜夜爽99久久国产综合精品女不卡| 国产一区二区中文字幕免费看| 欧美人在线视频| 欧美成人黑人xx视频免费观看| 欧美一级大片在线观看| 一本色道久久综合精品竹菊| 亚洲第一在线综合在线| 99精品欧美一区二区蜜桃免费| 篠田优中文在线播放第一区| 亚洲精品护士| 亚洲缚视频在线观看| 国内精品视频一区| 国产精品剧情在线亚洲| 欧美日韩精品在线播放| 欧美国产极速在线| 女同性一区二区三区人了人一| 久久av一区二区三区漫画| 午夜视频在线观看一区| 亚洲一区二区四区| 亚洲视频免费| 亚洲香蕉网站| 亚洲综合电影一区二区三区| 亚洲一区二区三区午夜| 亚洲一区二区三区四区五区午夜| 一区二区日韩精品| 亚洲一卡久久| 亚洲一区二区三区在线看| 亚洲视频中文字幕| 亚洲一区亚洲| 久久av资源网| 国产精品www.| 国产精品系列在线播放| 国产精品资源在线观看| 国产精品视频专区| 国产亚洲欧美一区二区三区| 国产一区成人| 亚洲国产精品福利| 99国产精品一区| 亚洲欧美国产高清va在线播| 欧美一级成年大片在线观看| 久久不射电影网| 免费观看久久久4p| 亚洲日本在线视频观看| 亚洲视频欧美视频| 欧美夜福利tv在线| 欧美va亚洲va香蕉在线| 欧美视频在线播放| 国产日韩欧美中文| 亚洲激情亚洲| 亚洲男人第一网站| 蜜臀av国产精品久久久久| 91久久久国产精品| 亚洲专区在线| 女同性一区二区三区人了人一 | 一区二区三区欧美日韩| 午夜精品国产更新| 欧美成人一区二区三区| 国产精品大片wwwwww| 激情综合网激情| 在线天堂一区av电影| 久久久美女艺术照精彩视频福利播放| 亚洲第一黄网| 午夜精品福利电影| 欧美极品一区| 精品福利电影| 亚洲尤物在线| 亚洲福利视频网| 欧美主播一区二区三区美女 久久精品人| 欧美.日韩.国产.一区.二区| 国产精品嫩草99a| 亚洲精品视频一区二区三区| 欧美一区中文字幕| 日韩午夜视频在线观看| 久久天天躁狠狠躁夜夜爽蜜月| 国产精品电影网站| 亚洲精品美女久久7777777| 久久久久国色av免费看影院| 99re视频这里只有精品|