Associative memories are great for finding things quickly because the gates are set up to compare every word with the MBR all at once and to tell if the value is found. The alternative is to sequentially compare every word in the memory, which would take time. In the context of virtual memory, the page number is what is being searched for in the TLB and the corresponding frame number is what is found and returned if that page number is there. There is always a cost, some sort of trade-off or dark side, and for associative memories the cost lies in the complexity of the gates and circuits. Associative memories are larger and more complex than regular memories so TLBs in real computers tend to be tiny, usually 8 or 16 words. Studies have shown that such small TLBs are effective, nevertheless. Approximately 90% of the addresses translated can be done by getting values out of the TLB instead of out of the page table. This percentage is often called the hit ratio, and a positive match of an item with a value in the TLB is called a hit. |