Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does a CPU cache entry contains physical or virtual address?

Does a CPU cache deal with physical or virtual addresses? And if it deals with virtual addresses, does that mean that it has be to emptied on context switch, assuming that the new thread is from another process.

like image 762
MetallicPriest Avatar asked Nov 02 '22 15:11

MetallicPriest


1 Answers

This depends on the processor model. Some processors use both. (See “SPARC” in the “Virtual tags and vhints” section.)

You have tagged this question with x86-64, and an answer could be given for all x86-64 models to date, but I am not sure whether the architecture specification specifies whether processors conforming to the specification must use one or the other for cache information.

like image 190
Eric Postpischil Avatar answered Dec 01 '22 00:12

Eric Postpischil