Wednesday, August 08, 2012

Memory Hirerarchy in Embedded Systems

Memory Hierarchy


The cache memory is defined as the first level of memory after the Registers. In the memory hierarchy, it is placed right below the processor registers as shown in the figure above.

Speed Vs Distance Vs Size of the Memory
 The above diagram shows the position of the Cache memory based on the Speed, Distance from the Processor and the Size.

How the Processor check for the data?


The cache is generally made up of SRAM because of the high speed of operation of SRAMs and the faster a cache operates, faster data can be made available to the processor for processing.

Components in the Memory Hierarchy


The cache stores in it the data of memory locations that the processor uses repeatably or is expected to use very soon in future. When the processor wants to access data of a certain memory location, the data might be present in cache or not, this is defined by the terms cache hit and cache miss respectively.

Cache Miss

Cache Miss


When the processor does not find, the memory location which it wants to access, stored in the cache it has to fetch the data from the main memory. As the data is missing in the cache this is termed as a cache miss.

Cache Hit

Cache Hit
If the memory location is present in the cache, processor can fetch the data from cache itself and need not go to the main memory to fetch it. This is termed as a cache hit.

Temporal Locality

Temporal Locality
A memory location accessed once will be accessed again soon and hence need to be stored close to the processor. This is an assumption and if the same data is required in the near future, we can save time by doing this.

Spatial Locality

Spatial Locality


The memory locations around the memory that the processor accesses might also be accessed by the processor soon and hence need to stored close the processor in the cache.This is also based on an assumption and we believe that the data next to the current location will be required for the next computation.


I think this below 3 Dimensional Diagram will make the Memory Hierarchy much more clear to the readers.

How the CPU Access the Memory





  1. The address of the needed data is formed in the processor execution or instruction-fetch unit. Most addresses are then mapped from virtual to real through the Translation Look aside Buffer (TLB). Certain ranges of addresses are not mapped, and bypass the TLB.
  2. Most addresses are presented to the primary cache, a cache in the processor chip. If a copy of the data with that address is found, it is returned immediately. Certain address ranges are never cached; these addresses pass directly to the bus.
  3. When the primary cache does not contain the data, the address is presented to the secondary cache. If it contains a copy of the data, the data is returned immediately. The size and the architecture of the secondary cache differ from one CPU model to another.
  4. The address is placed on the system bus. The memory module that recognizes the address places the data on the bus.

(Courtesy: www.mbeded.blogspot.in, www.techpubs.sgi.com)

49 comments:


  1. My cousin recommended this blog and she was totally right keep up the fantastic work!














    Embedded System Projects

    ReplyDelete
  2. Thanks for another great post. The place else may anyone get that type of information in such a perfect way of writing? I’ve a presentation next week, and I’m at the look for such information. embedded training in Chennai | embedded systems training in Chennai

    ReplyDelete
  3. This is excellent information. It is amazing and wonderful to visit your site.Thanks for sharng this information,this is useful to me...
    Android Training in Chennai
    Ios Training in Chennai

    ReplyDelete
  4. Everybody is talking about microservices. Industry veterans may remember monolithic or SOA-based solutions being the way of doing things. Times have changed. New tools have allowed developers to focus on specific problems without adding excessive complexity to deployment or other administrative tasks that are usually associated with isolated services.
    Microservices training in chennai

    ReplyDelete
  5. Thank you a lot for providing individuals with a very spectacular possibility to read critical reviews from this site.

    Best Java Training Institute Chennai

    ReplyDelete
  6. Thanks for providing such a great information.I ‘d mention that most of us visitors are endowed to exist in a fabulous place with very many wonderful individuals with very helpful things.
    selenium training in bangalore

    ReplyDelete
  7. Needed to compose you a very little word to thank you yet again regarding the nice suggestions you’ve contributed here.
    Hadoop Training Institute In chennai

    ReplyDelete
  8. It is really amazing...thanks for sharing....provide more useful information...

    Embedded training in chennai | Embedded training centre in chennai

    ReplyDelete
  9. Read all the information that i've given in above article. It'll give u the whole idea about it.
    Click here:
    Angularjs training in chennai

    Click here:
    angularjs training in bangalore

    Click here:
    angularjs training in online

    Click here:
    angularjs training in Annanagar

    ReplyDelete
  10. Thanks for the informative article. This is one of the best resources I have found in quite some time. Nicely written and great info. I really cannot thank you enough for sharing.
    Blueprism training in Chennai

    Blueprism training in Bangalore

    Blueprism training in Pune

    Blueprism online training

    ReplyDelete
  11. Great post! I am actually getting ready to across this information, It’s very helpful for this blog.Also great with all of the valuable information you have Keep up the good work you are doing well.
    Devops Training in Chennai

    Devops Training in Bangalore

    Devops Training in pune

    ReplyDelete
  12. Appreciation for really being thoughtful and also for deciding on certain marvelous guides most people really want to be aware of.
    fire and safety course in chennai

    ReplyDelete
  13. Good Post! Thank you so much for sharing this pretty post, it was so good to read and useful to improve my knowledge as updated one, keep blogging.

    rpa training in velachery| rpa training in tambaram |rpa training in sholinganallur | rpa training in annanagar| rpa training in kalyannagar

    ReplyDelete
  14. Those guidelines additionally worked to become a good way to recognize that other people online have the identical fervor like mine to grasp great deal more around this condition.
    best safety training in chennai

    ReplyDelete
  15. Wow, Nice blog. Thank you so much for the efforts of this blog. Visit for
    Best Offshore VPS

    ReplyDelete
  16. This is an awesome post.Really very informative and creative contents. These concept is a good way to enhance the knowledge.

    Tableau Training in Chennai
    Tableau Training

    ReplyDelete
  17. Thanks for sharing this valuable information.Its more useful to us.its very interesting to know the blog
    with clear vision.

    Article submission sites
    Guest posting sites

    ReplyDelete
  18. nice work keep it up thanks for sharing the knowledge.Thanks for sharing this type of information, it is so useful.
    Epoxy Grout manufacturer in delhi

    ReplyDelete
  19. Laminated Doors manufacturer in hubli
    Thanks for giving great kind of information. So useful and practical for me. Thanks for your excellent blog, nice work keep it up thanks for sharing the knowledge.

    ReplyDelete
  20. led lawn lights in delhi
    Thanks for giving great kind of information. So useful and practical for me. Thanks for your excellent blog, nice work keep it up thanks for sharing the knowledge.

    ReplyDelete
  21. Some us know all relating to the compelling medium you present powerful steps on this blog and therefore strongly encourage contribution from other ones on this subject while our own child is truly discovering a great deal. Have fun with the remaining portion of the year.
    Data Science training in Chennai
    Data science online training

    ReplyDelete
  22. can you offer guest writers to write content for you? I wouldn’t mind producing a post or elaborating on some the subjects you write concerning here. Again, awesome weblog!
    iosh safety course in chennai

    ReplyDelete
  23. I would like to thank you for the efforts you have made in writing this article. I am hoping the same best work from you in the future as well. In fact your creative writing abilities has inspired me to start my own BlogEngine blog now. Really the blogging is spreading its wings rapidly. Your write up is a fine example of it.
    Data Science course in rajaji nagar
    Data Science with Python course in chenni
    Data Science course in electronic city
    Data Science course in USA
    Data science course in pune | Data Science Training institute in Pune

    ReplyDelete
  24. Your good knowledge and kindness in playing with all the pieces were very useful. I don’t know what I would have done if I had not encountered such a step like this.
    Microsoft azure training in Bangalore
    Power bi training in Chennai

    ReplyDelete
  25. Thanks for giving great kind of information. So useful and practical for me. Thanks for your excellent blog, nice work keep it up thanks for sharing the knowledge.
    Modular Kitchen in Noida

    ReplyDelete
  26. Thank You! For sharing such a great article, It’s been a amazing article.
    It’s provide lot’s of information, I really enjoyed to read this.
    Mobile app development company in toronto

    ReplyDelete
  27. Thanks for sharing such an amazing blog. It is really helpful for me and I get my lots of solution with this blog. Thank you for sharing valuable information. Nice post. I enjoyed reading this post…
    SEO Company in Noida

    ReplyDelete
  28. This is really impressive post, I am inspired with your post, do post more blogs like this, I am waiting for your blogs.
    Regards,
    Devops Training in Chennai | Devops Certification in Chennai

    ReplyDelete
  29. Incredible Article… I want to peruse your articles on the grounds that you're composing style is too great, its is extremely useful for every one of us and I never get exhausted while perusing your article in light of the fact that
    Devops Training in Chennai | Devops Training Institute in Chennai

    ReplyDelete
  30. I would like to thank you for your nicely written post, its informative and your writing style encouraged me to read it till end. Thanks

    angularjs online training

    apache spark online training

    informatica mdm online training

    devops online training

    aws online training

    ReplyDelete
  31. This is a nice post in an interesting line of content.Thanks for sharing this article, great way of bring this topic to discussion.
    Microsoft Azure online training
    Selenium online training
    Java online training
    Python online training
    uipath online training

    ReplyDelete
  32. This blog is wonderful i like studying your posts. Keep up the great work! You understand, lots of persons are hunting around for this info, you could help them greatly.
    R Training Institute in Chennai | R Programming Training in Chennai

    ReplyDelete
  33. I feel happy about and learning more about this topic. keep sharing your information regularly for my future reference. This content creates new hope and inspiration within me. Thanks for sharing an article like this. the information which you have provided is better than another blog.
    IELTS Coaching in Dwarka mor

    ReplyDelete
  34. And indeed, I’m just always astounded concerning the remarkable things served by you. Some four facts on this page are undeniably the most effective I’ve had.
    Data science Course Training in Chennai | No.1 Data Science Training in Chennai
    RPA Course Training in Chennai | No.1 RPA Training in Chennai

    ReplyDelete
  35. Amazing article. Your blog helped me to improve myself in many ways thanks for sharing this kind of wonderful informative blogs in live. I have bookmarked more article from this website. Such a nice blog you are providing ! Kindly Visit Us @ Best Travels in Madurai | Tours and Travels in Madurai | Madurai Travels

    ReplyDelete

Thank you for your valuable suggestion. If you feel this post useful, please share our Blog with others!!! Comments just for Backlinking your Website or Blog will be Deleted...