![]() ![]() The lower level cache will be marked as M (again, assuming the lower level cache is write-back) The block will be written to in this cache and also in the lower level cache. At the same time Block 4 is NOT invalidated.Įxactly the same thing happens when I6 writes to Block 4. ![]() When I4 is writing to Block 6, it is already in the cache, which means it will modify both this cache and the lower level cache, which will be marked as M (assuming the lower level cache is write-back). The answer to 2nd question also depends on the number of caches and whether your LLC is write-back. If they are one to one and there is no conflict in the cache, then A and B will stay in Exclusive Mode, if there is conflict you would need to decide based on the replacement policy. It is unclear to me how your memory locations A,B, and C are mapped to cache lines. The only way they would be invalidated is if another processor were to write to them or you have a conflict. So the answer here would depend on the number of caches you have as well as the write-policy.īut I4 should not invalidate A or B, so they both stay in Exclusive Mode. If you are assuming write-allocate policy, then the cache line C will be requested in M state (at least in one of the cache levels, and definitely in the LLC). If you are assuming NO-write-allocate, the store (I4) will write around the cache and not request the line at all, so it will remain Invalid. Are you using write-allocate or No-write-allocate? And is it fair to assume that you have L2 that is write-back? The answer to 1st question depends on your write policy and whether you have more than one cache level in your hierarchy. Is my answer correct please? Thank you very much in advance. If memory block 4 and 6 are loaded onto two differentĬache blocks (initially empty) on a single processor If memory block A, B, and C are loaded (if needed) onto two different cache blocks (initially empty) on a single processor, complete the following table to identify the cache state of the blocks containing A, B, C, after each instruction executes.Īssume write-thru cache policy. ![]() (1)Consider the following code fragment that runs on a uniprocessor system that Implements the MESI cache coherence protocol:Īssume write-thru cache policy. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |