This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
struct AnyCodable: Codable { | |
let value: Any | |
init<T>(_ value: T?) { | |
self.value = value ?? () | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
对于CPU来讲,系统中所有的存储器中的存储单元都存储在一个统一的逻辑存储器中,而它的容量受CPU寻址能力的限制。这个逻辑存储器就是内存地址空间。 | |
1. 地址总线与内存地址空间的转换 | |
2. 一根总线只能传递01两个信号,即传送1 bit内容,10根则可以传送2^10个信号,即1024bit内容 | |
3. 1G=1024MB 1MB=1024KB 1KB=1024B | |
4. 20根总线可以传送(10+10=1024*1024B=)1MB内容 | |
5. 地址总线宽度为32的CPU,可以传送10+10+10+2=4GB内容 |