随笔分类 - Computer System
摘要:Loading and Linking Shared Libraries from Applications Up to this point, we have discussed the scenario in which the dynamic linker loads and links sh
阅读全文
摘要:Executable Object Files The format of an executable object file is similar to that of a relocatable object file. The ELF header describes the overall
阅读全文
摘要:Relocation Once the linker has completed the symbol resolution step, it has associated each symbol reference in the code with exactly one symbol defin
阅读全文
摘要:Linking with Static Libraries In practice, all compilation systems provide a mechanism for packaging related object modules into a single file called
阅读全文
摘要:简介和分类 Linking is the process of collecting and combining various pieces of code and data into a single file that can be loaded (copied) into memory an
阅读全文
摘要:Hiding variable and function names with static C programmers use the static attribute to hide variable and function declarations inside modules, much
阅读全文
摘要:Procedure Example 准备调用swap_add之前的代码: 此时,ebp指向顶部,esp指向中部,call之后push return address 要改变ebp之前必须保存,以便之后恢复: setup code for swap_add: 此时,ebp指向中部,esp指向中部 bod
阅读全文
摘要:Loops: Instead, combinations of condi- tional tests and jumps are used to implement the effect of loops. Most compilers generate loop code based on th
阅读全文
摘要:Unary and Binary Operations unary operations: This operand can be either a register or a memory location. For example, the instruction incl (%esp) cau
阅读全文
摘要:Data Formats 如图: Accessing Information 如图: The low-order 2 bytes of the first four registers can be independently read or written by the byte operatio
阅读全文
摘要:x86(wiki): x86 is a family of backward-compatible(向后兼容) instruction set architectures[a]based on the Intel 8086 CPU and its Intel 8088 variant(变种). IA
阅读全文
摘要:需要虚拟存储器的原因: As demand on the CPU increases, processes slow down in some reasonably smooth way. But if too many processes need too much memory, then so
阅读全文
摘要:Fully Associative Caches: definition: A fully associative cache consists of a single set (i.e., E = C/B) that contains all of the cache lines. 只有一个set
阅读全文
摘要:Generic Cache Memory Organization: 这个结构可以用一个四元组表示: (S, E, B, m) 图示: S表示set的数量,标志了s的长度。如果在address里的set index也为3,那么应该把这个缓存放在Set3 B代表cache block的大小,标志了b的
阅读全文
摘要:局部性: 局部性分为时间局部性和空间局部性:Locality is typically described as having two distinct forms: temporal locality and spatial locality. In a program with good tem
阅读全文
摘要:csapp 560: 不同层次存储器的区别: If the data your program needs are stored in a CPU register, then they can be accessed in zero cycles during the execution of t
阅读全文