Introduction To CA
Introduction To CA
Concepts on
numerical
representations
(Part 1)
Topic Outcome
• https://youtu.be/AkFi90lZmXA?feature=shared
Why I need to learn CA?
• Studying computer architecture is important for several reasons. Firstly, it helps us understand
how computers work at a fundamental level, including the design of the central processing unit
(CPU), memory, and input/output systems. This knowledge is crucial for computer engineers and
scientists to design and optimize computer systems.
• Secondly, understanding computer architecture allows us to develop more efficient software. By
knowing how the hardware operates, software developers can write programs that take full
advantage of the underlying hardware, leading to better performance and more efficient use of
resources.
• Furthermore, studying computer architecture provides insights into the evolution of computing
technology and the challenges associated with designing and building computer systems. This
knowledge is essential for advancing the field of computer science and engineering.
• Ultimately, studying computer architecture is foundational for anyone interested in working with
computers, whether in hardware design, software development, or system optimization.
Example of real world scenario
While migrating software from Sun Sparc machines to Intel based Linux.
One of our tests was failing on Linux. There was code that tested some computation and
made sure the result was correct.
it looked something like this:
1.double r = some_function(fixed_set_of_arguments)
2.if (r == 0.12345) {
3.printf("test passes")
4.}
compiler optimized this code it kept temporary values in the floating point registers
and on Intel chips, floating point registers are longer than 64 bits (the normal size of a double)
to allow for more precision.
So, when the function computed the value it kept it in a register and
when it was compared to the constant, they were not equal.
Level of Transformation
Problem
Algorithm
Program/Language
ISA (Architecture)
Microarchitecture
Logic
Circuits
Electrons
Abstraction Layers
Application
Software
Compiler
Assembler Operating System
• Storage devices
• Volatile memory devices: DRAM, SRAM, …
• Permanent storage devices: Magnetic, Optical, and Flash disks, …
• Processor
• The device that computes the instructions into outputs
• Network component
• Essential component for communication in any computer system
Major Components of a Computer
• Information is very often represented and managed in a digital format: photos, pictures,
video, music, data are translated to 0s and 1s, and manipulated that way:
• We shall see that hexadecimal and octal numbers are very useful when dealing
with binary numbers, and we’ll learn to use and do arithmetic in each of them
Binary Numbers
• The positional value of each binary digit indicates the power of 2, as follows:
Binary Numbers
• 1111111 = ?
Counting in Binary Numbers
Binary Numbers
• The bit on the right-hand side is the Least Significant Bit (LSB), while the bit on the left-hand side is the
Most Significant Bit (MSB)
• Digits may have meaning for different bases: 10010 which may be a binary, octal, decimal or hexadecimal number.
• Binary numbers are very easy for computers, but not for human beings
• Hexadecimal and octal are important because of the ease of conversions between both systems and binary.
$7E = ?
$A8 = ?
$13BF = ?
Counting in Hexadecimal
Octal Numbers
15738
= 1 * 83 + 5 * 82 + 7 * 81 + 3 * 80
= 1 * 512 + 5 * 64 + 7 * 8 + 3 * 1
= 512 + 320 + 56 + 3
= 89110
Octal Numbers
3048 = ?
15348 = ?
Counting in Octal
Additional source
• https://youtu.be/uTNCVRxuP_c?feature=shared
Next Topic: Introductory Concepts on Numerical
Representations (Part 2)
THANK YOU