Question

In Intel page table structure, there is "page global" bit which indicates the page table entry is globally used. In my understanding, this global entry will not be flushed during TLB flushing caused by overwriting CR3. my question is, can we assume that global PTE entry will never be flushed from TLB once it is set?

Was it helpful?

Solution

You cannot assume that. There are a many reasons to flush a TLB entry, such as:

  • The TLB is full, and a new entry needs to be cached, and the entry in question is replaced with the new one.
  • There is an instruction to explicitly invalidate a TLB entry, which can be used for such pages as well.
  • There are many other conditions in which HW will flush the TLB completely in order to maintain consistency for reasons other than CR3.

In short, you cannot assume that once a page translation is in the TLB, it will always remain there.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top