20145317 "Information Security system Design Fundamentals" 7th Week study summary 1 Textbook Learning content Summary
Basic storage technology: SRAM memory DRAM memory ROM memory rotary hard drive SSD
1. Storage Technology
Three common storage technologies: ram/rom/disk
( 1 ) random access memory RAM
- Two categories: Static RAM (SRAM) and dynamic RAM (DRAM)
- Static RAM (SRAM) is faster, but much more expensive than dynamic RAM (DRAM).
- Static RAM
- SRAM stores each bit in a bistable memory unit, each of which is implemented using a six-transistor circuit.
- A property of this circuit: it can be kept indefinitely in one of two different voltage configurations or states. Any other state is not stable.
- -Features: Due to the bistable characteristics of SRAM, as long as there is electricity, it will always maintain its value, even if there is interference, such as electronic noise, to disturb the voltage, when the interference is eliminated, the circuit can also be restored to a stable value.
-Application: SRAM is used as a cache memory, which can be on the CPU chip or under the chip.
- Dynamic DRAM
- DRAM stores each bit as a charge to the capacitor. The capacitance is approximately 30x10-15f.
- -Features: Particularly sensitive to interference, when the voltage of the capacitor is disturbed, it will never recover. Exposure to light can cause a change in the capacitance voltage.
-Application: DRAM is used as a frame buffer for primary storage as well as for graphics systems.
( 2 Non-volatile memory ( ROM )
- ROM distinction: The number of times that can be reprogrammed and the mechanism used to reprogram them.
- -PROM: Can only be programmed once.
- -EPROM: Erasable programmable ROM, ultraviolet light clear unit content, erasable number of orders of magnitude 1000.
- -E2prom: Electronic erasable Prom, can be programmed directly on the printed circuit card, the number of times to erase the order of 10^5.
-Flash: Flash, based on EEPROM. (SSD SSD based Flash)
- Programs stored in ROM devices are often referred to as firmware.
( 3 ) Access to main memory
-Read transaction: Transfer data from main memory to CPU.
-Write transactions: Transfer data from the CPU to main memory.
-Bus: A group of parallel conductors that can carry the control signal of address and data.
Data bus, control bus, address bus
- Read TRANSACTION statement
MOVL A,%eax
-The CPU puts address A on the memory bus
-Main memory reads a from the bus, receives the word X, and then puts X on the bus
-The CPU reads the word X from the bus and copy it to the register EAX.
- Write TRANSACTION statement
MOVL%eax,a
-The CPU puts address A in the memory bus, main memory reads this address, waits for the data word to receive
-CPU puts the data word y on the total road
-Main memory reads the data word y from the bus and stores it in address a.
( 4 ) disk storage
- Disk Construction
- Made from platters , each platter has two sides or a surface , and the surface is covered with magnetic recording material. The center of the platter has a rotating spindle that rotates the disc at a fixed rotational rate , usually 5400~15000 rpm
- Each surface consists of a set of concentric circles called tracks , each of which is divided into a set of sectors , and each sector contains an equal number of data bits (usually 512 bytes), which are encoded in magnetic materials on the sector. The sectors are separated by a few gaps , and no data bits exist in these gaps. The Gap store is used to identify the format bits of the sector.
- Disk capacity
- The maximum number of bits that can be recorded on a disk is called its maximum capacity/capacity.
- Determining factors for disk capacity:
- -Record density: The number of bits that an inch of a track can fit into.
- -Track density: The number of tracks that can be in the one-inch radius from the center of the disc.
-Surface density: the product of recording density and track density.
- Disk capacity (cannot be knocked out)
- That is, sector size X average number of sectors per track x tracks per face x number of faces per disc x number of disks per disk
- Example:
- For units associated with DRAM and SRAM capacity, typically
K = 210,m = 220,g = 230
- Units related to the capacity of I/O devices, such as disks and networks, are typically
K = 103,m = 106,g = 109
- Disk operations
- The disk reads and writes the bits stored on the magnetic surface, and the read-write head is connected to one end of the rotating arm . The seek is to move the rotating arm forward and backward along the radius axis so that the drive can position the read-write head on any track on the disc surface.
- All reading and writing heads are located on the same cylinder at any one time.
- The read/write head at the end of the drive arm flies on a thin cushion of about 0.1 microns above the surface of the disk, at a speed of about 80km/h.
- The disk reads and writes data as a block of sector size.
- There are three main sections of access time for sectors:
- -Seek time: In order to read the contents of a target sector, the drive ARM positions the read/write head first on the track containing the target sector, which is the seek time, approximately equal to the maximum rotation time.
- -The Seek time Tseek relies on the position of the reading and writing head and the speed at which the rotating arm moves on the disk surface.
- -Rotation time: After locating the desired track, the drive waits for the first bit of the target sector to rotate below the read/write header. Depends on the location of the disc and the disk rotation speed when the read-write header reaches the target sector.
- -After locating the desired track, the drive waits for the first bit of the target sector to rotate below the read/write header.
- -Maximum rotation time = 1/maximum rotation number ratio
- -Average Rotation time = (1/2) * Maximum rotation time.
- -Transfer time: When the first bit of the target sector is under the read-write header, the drive can begin reading or writing the contents of the sector. Depends on the rotational speed and the number of sectors per track.
-Average Transfer time = (1/maximum rotation number) * (1/Average number of sectors per track)
( 5 ) Logical Disk block
Memory can be viewed as a byte array, and disks can be seen as block arrays
- Modern disk construction is complex and has multiple disk faces, which have different memory areas. To hide such complexity from the operating system, modern disks present their constructs as a simple attempt, a sequence of logical blocks of sector size B, numbered 0,1,...,b-1.
- The disk has a small hardware/firmware device called a disk controller that maintains a mapping between the logical block number and the actual (physical) sector.
- The firmware on the controller performs a quick table lookup, translating a logical block number into a ternary group (disk, track, sector) that uniquely represents the corresponding physical sector. The hardware on the controller interprets this ternary group, moving the read-write head to the appropriate boiling surface, waiting for the sector to move to the read-write header, placing the read-write head-aware bits in a small buffer on the controller, and then copying them into main memory.
( 6 ) connected to I/O Equipment
- Input like graphics cards, monitors, mice, keyboards and disks are connected to the CPU and main memory via the I/O bus.
- The system bus and memory bus are CPU-related and the I/O bus is designed to be independent of the underlying CPU.
- The I/O bus is slower than the system bus compared to the memory bus, but it can accommodate a wide variety of third-party I/O devices.
- -Universal Serial Bus usb:2.0 maximum bandwidth 60mb/s,3.0 Maximum bandwidth 600mb/s
- -Graphics Card (adapter)
-Host Bus Adapter
( 7 ) to access the disk
- The CPU uses a memory-mapped I/O technique to issue commands to I/O devices, where a block of addresses in the address space is reserved for communication with I/O devices, called I/O ports, in a system that uses memory-mapped I/O. When a device is connected to a bus, it is connected to one or more ports.
- Direct Memory Access: The device can perform its own read or write bus transactions without the need for CPU interference. This data transfer is called DMA transfer.
( 8 ) Solid Disk
- SSD is a flash-based storage technology.
- An SSD package consists of one or more flash chips and a flash translation layer, a flash chip instead of a mechanical drive in a traditional rotating disk; The Flash translation layer (a hardware/firmware device) replaces the disk controller, translating requests for logical blocks into access to the underlying physical device.
- Performance characteristics
- -Sequential Read and write (CPU accesses logical disk blocks sequentially) performance is comparable, sequential reads are slightly faster than sequential writes.
- -When a logical block is randomly accessed, the write is one order of magnitude slower than the read.
* Read and write performance differences are determined by underlying flash basic properties.
- Advantages and Disadvantages
- Advantages:
- -Components made of semiconductors with no moving parts
- -Faster random access times than rotating disks, low energy consumption and strong
- Disadvantages
-Easy to wear and more expensive
( 9 ) Storage Technology Trends
- Different storage technologies have different price and performance tradeoffs
- The price and performance attributes of different storage technologies change at a very different rate (increasing density to reduce costs is easier than reducing access time)
- DRAM and disk performance lags behind CPU performance
Random access Memory:
1 static (SRAM): Dual stable characteristics, as long as the power can be stable forever, faster
2 dynamic (DRAM): sensitive to interference, once the voltage is disturbed, can never be restored, and exposure to light will cause a change in the capacitance voltage, slower.
DRAM = The chip unit is divided into M-units, each of which consists of n dram cells, and has r row C column.
Read process: Read the 4,3 from the dram of 16*8, first the storage controller sends the line address 4, then the DRAM copies all the contents of 4 rows to the internal row buffer, then the controller sends the column address 3,dram the row buffer copies the ultra-unit (4, 3) in the 8-bit and sent to the storage controller.
DRAM in fast-track mode: When the storage controller sends the line address followed by three column addresses (1+3), it is much faster to waste a single line than the original DRAM copy.
VRAM: The output is faster by shifting through the entire content line of the inner buffer of the row, and allows read and write parallel to the memory.
Non-volatile Memory:
ROM (read-only memory):
1 PROM (can only be programmed once, only high current fuse once)
2 erasable programmable ROM (the number of erasable and flush programming of optical erase is up to 1000 times, electronic erasable can reach 10^5 times)
3 Flash memory
Firmware: A program stored in a ROM device. The process of MOVL A,%eax:
1 CPU puts the address on the system bus
2 I/O bridge transmits the signal to the memory
3 Memory read address A from the system bus
4 and read except the data write to the memory bus
The 5 I/O bridge translates the signal on the memory bus into the system bus number and passes it to the cup.
6 CPU reads data from the bus and copies it to register%EAX
The process of MOVL%eax,a:
1 CPU puts address A on the system bus (I/O bridge signal translation process is also in it)
2 Memory reads address A from the bus, waits for data to be served
3 CPU copies the data word from the%EAX to the system bus (and 2 simultaneously)
4 main memory from the storage bus alone data word coexistence to the a address of the DRAM.
Disk Construction:
Platters (with two sides, with rotatable spindle at the center of the disc, rotational speed RPM)
Each surface has 8 tracks, and no bayonet is divided into a set of sectors, and the gap in the sector stores the format bits used to identify the sectors.
Disk capacity = Bytes/sector + average number of sectors/tracks + number of tracks/surface + surfaces/platters + discs/disk disk A Sector read time = Seek time + transfer time + average rotation time (half of total transfer time) locality:
1 time locality (the memory location that has been referenced once may also be quoted several times later)
2 spatial locality (a memory location that has been referenced once will soon refer to a nearby location)
A program with a reference pattern with a step size of K, the better the locality of K smaller space.
A program that repeatedly references the same variable has good time locality.
20145317 "Information Security system Design Fundamentals" 7th Week study Summary 1