Introduction to Computing Recap: Bits and Data Storage Inside Today’s computer systems, information is encoded as patterns of 0s and 1s. These digits are bits (short for binary digits).
Although you may be inclined to associate bits with numeric
values, they are only symbols whose meaning depends on the application at hand.
The bits are used to represent information on any form on the
computer; they can be used to represent a numeric value or a character in an alphabet or even sometimes images or sound!
Regardless of data type, bits are used to represent the data in
temporary and permanent storage. Block Diagram of a Computer System Memory
Computers and Computer Systems contains
large collection of circuits (much like flip-flops), each capable of storing bits for the purpose of storing data.
This bit reservoir is known as computer
memory. Memory Cell Cell: A unit of main memory (typically 8 bits which is one byte)
To identify individual cells in a machine’s main
memory, each cell is assigned a unique name, called its address. Measuring Memory Capacity Memory Hierarchy Primary vs Secondary Memory The information stored on your Primary Memory (i.e. RAM) and the Cache are volatile; which means computer systems use these memory blocks for temporary usage. As an example, if you restart your computer, all the information stored on your RAM will be overwritten.
The information stored on your Secondary Memory is
permanent. As an example, when you save a word file on your hard drive, you can always find the file even when you restart the machine unless there is a failure on your system. Cache
Cache is similar to primary memory but it
generally has less capacity. Cache is primarily designed for storing small portions of information in process and supporting the Central Processing Unit (CPU).
There are two types of Cache : Memory
Cache and Disk Cache. Memory Cache
Cache Memory is located between Central
Processing Unit (CPU) and RAM.
It is primarily designed to improve
performance of the CPU by storing small parts of information which could reduce the need for CPU to access RAM continuously.
Memory Cache works faster than RAM but
has always got much less capacity. Types of Memory Cache: L1, L2 and L3 CPU Cache memory is divided into three "levels": L1, L2, and L3. L1 cache is the fastest memory that is present in a computer system. In terms of priority of access, the L1 cache has the data the CPU is most likely to need while completing a certain task. The L1 cache size is 64 K. Some top-end consumer CPUs now feature a 1MB L1 cache, like the Intel i9. L2 cache is slower than the L1 cache but bigger in size. Where an L1 cache may measure in kilobytes, modern L2 memory caches measure in megabytes. When it comes to speed, the L2 cache lags behind the L1 cache but is still much faster than your system RAM. The L1 memory cache is typically 100 times faster than your RAM, while the L2 cache is around 25 times faster. L3 cache in your CPU can be massive, with top-end consumer CPUs featuring L3 caches up to 32MB. Some server CPU L3 caches can exceed this, featuring up to 64MB. The L3 cache is the largest but also the slowest cache memory unit. Modern CPUs include the L3 cache on the CPU itself. But while the L1 and L2 cache exist for each core (CPU processor) on the chip itself. Disk Cache
Disk Cache is located at Hard-Drive and is only
accessed when Memory Cache is not available.
Disk Cache works slower than Memory Cache.
As an example, Photoshop and various Internet
Browsers such as Google Chrome use Disk Cache very often to create temporary files on the Hard-drive. Recap: Block Diagram of a Computer System Registers For temporary storage of information, the CPU contains cells similar to main memory cells. These are called registers.
Although they are virtually similar, CPU Registers and
Cache are not the same. Registers hold the data being processed whereas Cache holds the data that would be transferred to CPU immediately.
Registers handle instructions and data at a speed about
10 times faster than the cache memory. Register, Cache, Main Memory, Secondary Memory Secondary Memory
Due to volatile and limited size of a
computer’s primary memory; computers and computer systems have additional memory mechanism to store data permanently.
These devices are called secondary
memory, or mass storage devices. Magnetic Systems (1) For decades now, magnetic technology has dominated the mass storage area.
The magnetic technology is predominantly used in Hard-disk.
The Hard-disk consists of large shiny, circular "plate" of magnetic
material called a platter, divided into billions of tiny areas.
Each one of those areas can be independently magnetized
(to store a 1) or demagnetized (to store a 0).
Magnetism is used in computer storage because it goes on
storing information even when the power is switched off. Magnetic Systems (2) The data is stored in a very orderly pattern on each platter. Bits of data are arranged in concentric, circular paths called tracks. Each track is broken up into smaller areas called sectors. Cluster is a number of contiguous (next to each other) sectors. Part of the hard drive stores a map of sectors that have already been used up and others that are still free. (In Windows, this map is called the File Allocation Table or FAT.) When the computer wants to store new information, it takes a look at the map to find some free sectors. Then it instructs the read-write head to move across the platter to exactly the right location and store the data there. To read information, the same process runs in reverse. Hard-disk (1) Hard-disk (2) Optical Mechanism Another Class of mass storage systems (such as CD, DVD Writers) apply Optical technology.
In optical Technology, data is recorded on reflective
material surface to a single track consisting of individual sectors, that spiral toward the outer edge of a disc.
The information can be retrieved via a laser beam that
monitors irregularities on the reflective surface as the disc spins.
Optical Mechanism is frequently used today in CDs, DVDs,
and in Blu-Ray technology. Flash Drivers and Other External Storage Magnetic and Optical Technologies rely on physical spinning disks, moving read/write heads and aiming laser beams.
To overcome these requirements, external storage devices use
electronic signals directly sent to the storage medium (electrons are trapped in tiny electronic circuits).
Data is transferred in small byte sizes units as in RAM applications
thus, making this technology convenient for offline data storage - is called nonvolatile memory.
However, since data is transferred in small portions, this technology is
not very suitable for general main memory applications where its content might be altered many times in one second. Representing Information as Bit Patterns In addition to techniques for storing bits, encoding systems are developed to represent letters, numbers and special characters (&, $, +, etc).
Encoding system translates the data from/to
human readable format to/from machine understanding format as a string of 1’s and 0’s. Encoding Systems
‘ANSI’ (American National Standards Institute) : 8
bits are used for encoding. 128 characters are encoded by this system, and Microsoft Windows use ANSI Standards.
ASCII Encoding system: ‘ASCII’ (American Standard
Code for Information Interchange) encoding is the most popular encoding system. This system uses 7 bits encoding.