Тёмный

How Computers Add Numbers - Superscalar 8-Bit CPU #27 

Fabian Schuiki
Подписаться 2,9 тыс.
Просмотров 1,7 тыс.
50% 1

Наука

Опубликовано:

 

29 авг 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 46   
@JaenEngineering
@JaenEngineering Год назад
Very cool. A few months back out of boredom I built a full adder from descrete transistors. Had a lot of fun optimising the design to find the minimum number of transistors needed. Also looking forward to seeing this unit progress. I already figured out the add, subtract and multiply modules, but the division section is melting my mind. Found a design that annoyingly mostly works, except it has some random combinations of inputs produce completely erroneous results 🤨
@fabianschuiki
@fabianschuiki Год назад
Thanks! 🙂 Can't wait to integrate this into the CPU. Thinking about having separate multiplier and divider units later on that work iteratively across multiple cycles. Building an adder up from discrete transistors sounds like a very nice project, love it! 🥳
@JaenEngineering
@JaenEngineering Год назад
It seems RU-vid has eaten my last comment 🤔 Anyways, my point was that at the current clock speeds it should be possible to build circuits that could do multiplication and division in a single clock cycle, but I agree that as they are likely to have significant propagation delays it would probably be a good idea to pad them out to avoid issues. Oh, and this is the circuit I found for division https [://] userpages [.] umbc [.] edu [/] ~squire [/] cs411_l10 [.] html Seems to work fine so long as you treat it as a 4/4 bit divider, not the 7/4 bit that it describes
@wplays4u
@wplays4u 8 месяцев назад
How do you not have like millions of subs already?! Good job dude! And a great explanation as well...
@fabianschuiki
@fabianschuiki 8 месяцев назад
Thanks! 🙂
@yashsavani
@yashsavani Год назад
Wonderful video! I really enjoyed the thorough walk through of the boolean algebra! It helped me understand the connection between circuit design and complexity theory (dual of 3-SAT). Keep it up! I always look forward to these videos! :)
@fabianschuiki
@fabianschuiki Год назад
Thank you very much 🙂!
@schrodingerscat1863
@schrodingerscat1863 Год назад
In a real world situation it is often better to use more gates and reduce logic layers to reduce propagation delay, this is where the tools you were discussing really become essential. This was a nice explanation but I thought you would use Karnaugh maps rather than going the boolean algebra route. Still I suppose algebraic simplification is easier for many to understand exactly what is going on.
@fabianschuiki
@fabianschuiki Год назад
Excellent point about favoring speed over minimum number of terms! 👍 A common strategy among those tools is to do an initial minimization to the most compact boolean expression, then map to the logic gates available and start optimizing/replicating to improce timing. Love those tools, always feel like magic. I was considering Karnaugh maps. They would work quite well here, but going beyond 4 or 5 inputs with them is very difficult. Boolean algebra rewriting is a bit more general in that it'll just keep working, but has its own downsides and scaling issues. If I recall correctly, minimization algorithms like Espresso use a form of higher-dimensional Karnaugh maps and boolean rewriting in combination.
@griffinretro
@griffinretro Месяц назад
The fact that one can reduce a truth table into DNF is the basis of the PLA chip design. They are structured in the same way, AND gates generating terms that are then ORed for the outputs.
@fabianschuiki
@fabianschuiki Месяц назад
You're totally right! 🙂
@LaSchui
@LaSchui Год назад
always looking forward to your videos! keep 'em coming :)
@fabianschuiki
@fabianschuiki Год назад
Thanks 🙂!
@MissTrollwut
@MissTrollwut Год назад
same dude
@ghostlucian12
@ghostlucian12 Год назад
For tables more complex(with a lot of inputs) than a truth table, it is simple to use karnaugh maps, for a simple table a truth table is enough. AB\C 0 1 00 0 1 01 1 0 =>C'A'B + C'AB' + A"B"C + ABC = C(A'B'+BA) + C'(A'B+AB') = C(A'^B')+C'(A^B) 11 0 1 10 1 0 For cary: AB\C 0 1 00 0 0 01 0 1 =>AB + AC + BC 11 1 1 10 0 1 Another way is to simplify the truth table, select the rows where outputs are 1 and add them for example XOR gate: A B O 0 0 0 0 1 1 1 0 1 1 1 0 So what we notice is A = 0 and B = 1 outputs 1 or A = 1 and B = 0 outputs 1, we can translate the function above into: O = A'B+AB', this can be also noted O = (~A)&B | A&(~B) If the output function is too big, it can be simplified using simple math, example OR Gate. A B O 0 0 0 0 1 1 1 0 1 1 1 1 O = A'B+AB'+AB = A(B+B') + A'B = A + A'B =A+B Rules: A+A' = 1 A+A'B = A+B A' = ~A AB = A&B A+B = A|B
@stewartclark3259
@stewartclark3259 Год назад
excellent explanation!
@schrodingerscat1863
@schrodingerscat1863 Год назад
I thought he would go the Karnaugh maps route in this example but instead went the algebraic simplification route.
@fabianschuiki
@fabianschuiki Год назад
Karnaugh maps are definitely a great approach here 👍! They do struggle with more inputs though: if you have more than 4 or 5, it becomes hard to draw the grids and find the covering rectangles, because you run out of dimensions on the 2D sheet of paper that you're writing on. And with Karnaugh maps you'll still need a separate step to rewrite some of the AND/OR ops into XOR ops. That's why I went with boolean equation rewriting from the beginning: theoretically works with any number of imputs, XOR comes more naturally, and you could just stubbornly try rewrites without understanding what they do and you'll get a half-decent result. 😇
@Eugensson
@Eugensson 4 месяца назад
You should consider a 4-bit look ahead adder, it is faster.
@fabianschuiki
@fabianschuiki 4 месяца назад
Yes definitely! The 74HC283 that I'm using as the actual 4 bit adder in my system *is* a carry look-ahead adder 🙂
@MissTrollwut
@MissTrollwut Год назад
really nice videos. Do you have any other projects in mind?
@LaSchui
@LaSchui Год назад
Can't wait to see them! :)
@jasonvandonsel1384
@jasonvandonsel1384 Месяц назад
No wire diagrams?
@fabianschuiki
@fabianschuiki Месяц назад
I haven't prepred any for the individual breadboard experimentation, sorry. The later PCB conversions will have the full schematic though! 🙂
@mekafinchi
@mekafinchi Год назад
every video I see about full adders I am appalled to see that the creator has managed to make it yet longer than the last
@fabianschuiki
@fabianschuiki Год назад
Most thoroughly treated circuit on RU-vid? 😅
@JaenEngineering
@JaenEngineering Год назад
Just be thankful he only showed ripple carry adders. Explaining fast carry adders (like the 283 IC mentioned) would almost certainly double the video length 😅
@mekafinchi
@mekafinchi Год назад
@@JaenEngineeringif people used the bloated time to explain more advanced circuits instead of ludicrous pointless detail I would be very happy
@JaenEngineering
@JaenEngineering Год назад
@@mekafinchi not much point in explaining a circuit that's wholly impractical to build though is it? Also, it's the overall function that's important, as we're not going to be using discreet logic gates in the final design. I'd also add most people would likely agree that understanding how to solve a problem is more useful than just being given the answer and so appreciated the explanation of different approaches. Finally, I'm sure there's plenty of other videos that go into detail about the design of fast carry lookahead adders if that's all you're interested in.
@mekafinchi
@mekafinchi Год назад
@@JaenEngineering it'd still be better use of an hour long video
Далее
Teaching My CPU Addition - Superscalar 8-Bit CPU #28
49:31
버블티로 체감되는 요즘 물가2
00:15
Просмотров 2 млн
Exploring How Computers Work
18:12
Просмотров 3,5 млн
Decoding ALU Micro-Ops - Superscalar 8-Bit CPU #33
45:27
I built my own 16-Bit CPU in Excel
16:28
Просмотров 1,4 млн
How a Computer Works - from silicon to apps
42:32
Просмотров 1,3 млн
Carry Flag - Superscalar 8-Bit CPU #30
52:23
Просмотров 1,5 тыс.
Why build an entire computer on breadboards?
28:43
Просмотров 3,1 млн
HOW TRANSISTORS RUN CODE?
14:28
Просмотров 380 тыс.
Hardware interrupts
27:36
Просмотров 593 тыс.
Новый фонарик в iPhone с iOS 18
0:49
Просмотров 672 тыс.