1 votes 1 votes a direct-mapped cache of the size of 4 blocks. The main memory block access sequences are 0,1,2,3,4,1,2,3,0,4,0 No. of compulsory misses, conflict misses and capacity misses? CO and Architecture cache-memory misses + – Raj_Choudhary asked Dec 4, 2017 Raj_Choudhary 1.7k views answer comment Share Follow See all 22 Comments See all 22 22 Comments reply joshi_nitish commented Dec 4, 2017 i edited by joshi_nitish Dec 4, 2017 reply Follow Share compulsory misses- 5 capacity misses- 0 conflict misses- 3 2 votes 2 votes Red_devil commented Dec 4, 2017 i edited by Red_devil Dec 4, 2017 reply Follow Share compulsory miss-5 capacity miss- 0; conflict miss-3;; 1 votes 1 votes Raj_Choudhary commented Dec 4, 2017 reply Follow Share 0 (com miss), 1 (comp Miss) , 2 (comp miss ) , 3 (comp miss ) , 4 (comp miss ) 1(hit) ,2(hit), 3 hit now i hv doubt about next 0 ( ?? ), 4(??) ,0(??) 0 votes 0 votes Anu007 commented Dec 4, 2017 i edited by Anu007 Dec 4, 2017 reply Follow Share compulsory misses- 5 for 0,1,2,3,4 capacity misses- 1 for 0,4 conflict misses- 1 for 0 https://stackoverflow.com/questions/33314115/whats-the-difference-between-conflict-miss-and-capacity-miss 1 votes 1 votes Red_devil commented Dec 4, 2017 reply Follow Share @joshi_nitish for 4 there should be compulsory miss because it is getting access for first time. 0 votes 0 votes Anu007 commented Dec 4, 2017 reply Follow Share Compulsory or Cold The first reference to a block of memory, starting with an empty cache. The hotel is empty and the first guest has not yet arrived. 0 votes 0 votes Ashwin Kulkarni commented Dec 4, 2017 reply Follow Share Why not for first 4 it is conflict miss? 0 votes 0 votes joshi_nitish commented Dec 4, 2017 reply Follow Share because first 4 is referred for the first time, which is compulsory miss. 0 votes 0 votes Anu007 commented Dec 4, 2017 reply Follow Share and compusory miss = number of cache block if items are come into cache blocks 0 votes 0 votes Ashwin Kulkarni commented Dec 4, 2017 reply Follow Share So as per @Anu said is it should not be compulsory miss. Because for compulsory miss block is referred first time and cache should be empty. So What will be the final answer? 0 votes 0 votes sumit chakraborty commented Dec 4, 2017 reply Follow Share According to this : https://gateoverflow.in/69118/difference-between-compulsory-miss-conflict-miss-capacity , I think the first 4 should be a conflict miss. Compulsory misses occur due to first time access to the block. 0th block which will contain both 0 and 4 is already accessed for the first time when 0 came in sequence. Conflict-4 (4,0,4,0) Capacity - 1 (4) Compulsory - 4(0,1,2,3) 0 votes 0 votes Anu007 commented Dec 4, 2017 reply Follow Share conflict come into picutre when the same block acsees the second time, if all block are distinct then no conflict miss 4 votes 4 votes joshi_nitish commented Dec 4, 2017 reply Follow Share yes, exactly as @Anu sir said, there will be no conflict miss untill same block is reaccessed again. 1 votes 1 votes Ashwin Kulkarni commented Dec 4, 2017 reply Follow Share So first 4 is compulsory miss or capacity miss? @joshi_nitish your answer is not matching with @Anu sir's. According to Sir's definition first 4 should not be compulsory miss because at that time no space is remaining in the cache, Hence is it capacity miss? 0 votes 0 votes sumit chakraborty commented Dec 4, 2017 reply Follow Share What is the final answer then ? 0 votes 0 votes Rishabh Gupta 2 commented Dec 5, 2017 reply Follow Share When the block is accessed for the first time it leads to a compulsory miss. No matter if the cache is full of empty, because even if cache has some space, that block access would have been a miss, bcoz its being accessed for the first time. So, its "compulsory" miss. matlab, yeh miss toh pakka hi hoga. so, number of compulsory misses = 5. http://csillustrated.berkeley.edu/PDFs/handouts/cache-2-misses-handout.pdf 1 votes 1 votes Rishabh Gupta 2 commented Dec 5, 2017 reply Follow Share And capacity miss = 2 and conflict miss = 1 ..., 0 (capacity), 4(capacity) ,0(conflict). 1 votes 1 votes Raj_Choudhary commented Dec 5, 2017 reply Follow Share Rishab 0(capacity ) and 4(capacity )miss also satisfying the definition of conflict miss 0 votes 0 votes Rishabh Gupta 2 commented Dec 5, 2017 reply Follow Share I referred to this answer: https://stackoverflow.com/a/40465392/6430403 1 votes 1 votes Prateek Raghuvanshi commented Dec 13, 2018 reply Follow Share can anybody help me why 0,4 are taken as capacity miss not conflict miss?? 0 votes 0 votes Prateek Raghuvanshi commented Dec 13, 2018 reply Follow Share i think 0,4 are also conflict miss because if they are capacity miss then increasing cache size these misses should not be there but still these are misses means these are not capacity ,these are conflict misses . 0 votes 0 votes codingo1234 commented Dec 31, 2018 reply Follow Share @ Prateek Raghuvanshi ,check this ans https://gatestack.in/t/conflict-miss-compulsory-miss-capacity-miss-direct-mapped-cache/487/2 after reading it I came to conclusion that Compulsory misses are 5 Capacity misses =1(second last 0) Conflict miss=2(last 4 and last 0) please someone just confirm it 0 votes 0 votes Please log in or register to add a comment.
2 votes 2 votes 0 A compulsory miss ->A 1 A conflict miss -> B 2 A capacity miss -> C 3 A 4 A 1 HIT 2 HIT 3 HIT 0 C (as from last access of 0 to this access we have 4 unique accesses and 4-1=3 unique blocks so capacity miss) 4 C (as from last access of 4 to this access we have 4 unique accesses and 4-1=3 unique blocks so capacity miss) 0 B (as from last access of 0 to this access we have 1 unique accesses and 4-1=3 unique blocks so conflict miss) so compulsory miss = 5 conflict miss = 1 capacity miss = 2 and total miss=7 shubham gupta 4 answered Sep 28, 2019 shubham gupta 4 comment Share Follow See all 0 reply Please log in or register to add a comment.