In a computer system having a cache memory, a method of re-mapping a virtual address to a physical address to improve performance of the computer system, comprising the steps of:
- (A) identifying at least one virtual address that is incurring delay in the computer system, said identifying including:
- (i) recording in a list, for each of a plurality of faults that occur during operation of the computer system, a virtual address that is being referenced in the computer system;
- (ii) maintaining for each of a plurality of cache page addresses, a count of the number of virtual addresses in the list that map to physical addresses substantially including the cache page address;
- and
- (iii) selecting as the at least one virtual address a virtual address in the list associated with the cache page address having the highest count;
- (B) determining a physical address of a memory page corresponding to the at least one virtual address, wherein the physical address substantially includes a cache page address for the cache memory;
- (C) selecting a new physical address for mapping the at least one virtual address, wherein the new physical address is selected to maintain a substantially even distribution of cache page addresses included in physical addresses of memory pages corresponding to a plurality of virtual addresses in the virtual address space;
- and
- (D) copying data located at the determined physical address to the memory page indicated by the new physical address.