[转]cache操作方式
1.前言
本文主要介绍cache相关的操作方式,包括:
read through, read allocate, write through, write back, write allocate
2. CPU读Cache
●若hit,则CPU直接从Cache中读取数据即可。
●若miss,有两种处理方式:
>Read through,即直接从内存中读取数据;
>Read allocate,先把数据读取到Cache中,再从Cache中读数据。
3. CPU写Cache
●若hit,有两种处理方式:
>Write through:把数据同时写到Cache和内存中;
>Write back:先把数据写到Cache中,再通过flush方式写入到内存中。
●若miss,有两种处理方式:
>Write allocate:先把要写的数据载入到Cache中,写Cache,然后再通过flush方式写入到内存中;
>No write allocate:直接把要写的数据写入到内存中。
4.参考文献
- 顶
- 0
- 踩

浙公网安备 33010602011771号