[CS61C FA20] Lecture 19.6 - Single-Cycle CPU Datapath II: Adding U-Types — Transcript
Full transcript
- 0:01[Music]
- 0:09hello
- 0:10welcome back to design over s5 cpu so
- 0:13far we have designed
- 0:14a data path that supports r type i type
- 0:19s type b type and j type instruction so
- 0:21there is only one type of instructions
- 0:23that is missing
- 0:24which is the u type this five base is a
- 0:29has six instruction types
- 0:32and that u type is something that we
- 0:34have seen before
- 0:35it is to support those unusually long
- 0:39immediates which we call upper
- 0:40immediates the format is fairly
- 0:42straightforward it has
- 0:4420 bits of an upper immediate in
- 0:48stored in the most significant bits of
- 0:51the instruction
- 0:52followed by the destination register and
- 0:54the op code
- 0:55there are two instructions of that type
- 0:58louis and now epc
- 1:00louis simply loads that 20-bit
- 1:04long upper immediate in the destination
- 1:06register and clears the lower
- 1:0912 bits our epc
- 1:13adds that upper immediate to the program
- 1:15counter
- 1:16and stores the result in destination
- 1:18register rd
- 1:21we already have almost all the hardware
- 1:23that we need
- 1:24we just need to add the hardware that is
- 1:27going to
- 1:28be supporting that u type immediate
- 1:32we didn't have that in that kind of
- 1:33intermediate before this one deals with
- 1:35upper immediates and it's fairly simple
- 1:37to support we just need to add a
- 1:38multiplexer that is going to be
- 1:41sending those upper 20
- 1:44immediate bits into the
- 1:47immediate bypassing various kinds of
- 1:52sign extension and so on
- 1:57so let's convince ourselves that we got
- 1:59what we wanted that we can execute both
- 2:01louis and our apc so let's light up
- 2:05the louis data path we'll first fetch
- 2:09the instruction by pointing the program
- 2:11counter
- 2:12to the the the
- 2:15instruction memory we'll
- 2:19increment the program counter to point
- 2:21to the next instruction
- 2:22at the same time the this instruction
- 2:24will point to the destination register
- 2:26in the register file and we'll decode it
- 2:28not going to show various control
- 2:31signals
- 2:31we all know how to set them
- 2:34appropriately
- 2:36go through the immediate generation and
- 2:38all what we need to do is to make sure
- 2:41that this immediate makes its way
- 2:45all the way to the
- 2:48destination register rd so we are going
- 2:51to
- 2:52set the b cell to one and then we need
- 2:55to set
- 2:55the alu such that it simply copies the
- 2:58value of b
- 2:59to its output over here and then
- 3:03we send set right back select to one
- 3:06and we have a new datum ready to be
- 3:09written into destination register
- 3:11rd on the next clock tick we are going
- 3:14to
- 3:14update the program counter to pc plus 4
- 3:18and write that upper immediate
- 3:22into destination register rd let's do
- 3:24the same thing
- 3:25with our pc we're going to fetch the
- 3:29instruction
- 3:31increment the program counter point to
- 3:33the destination register
- 3:35generate the immediate but at the same
- 3:37time
- 3:38we are lighting up this spot where we
- 3:41are sending the program counter
- 3:43and selecting it as the a input to the
- 3:45alu
- 3:46the b input to the alu will be that
- 3:48immediate we'll add them together
- 3:52select the write back select to pick
- 3:54that result
- 3:55and write it into a destination register
- 3:57the destination register
- 3:59and the program counter get updated
- 4:03on the next clock deck and as the new
- 4:05format
- 4:06completes all of our instruction formats
- 4:10in risk five see in a sec to wrap this
- 4:14up
About this transcript
This page contains the full transcript of [CS61C FA20] Lecture 19.6 - Single-Cycle CPU Datapath II: Adding U-Types by CS 61C Departmental, generated from the public captions YouTube serves with the video. The transcript has 561 words across 104 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.
What you can do with it
Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to translate the transcript into 100+ languages.
Free YouTube transcript tool
YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, translation to 100+ languages, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.