Skip to main content

Featured

Neuralink: Elon Musk Another Venture

Hello everyone, this is the second post of 2020. Also, the first one in Feb (wrote in Feb but published in March). So, I officially lagging behind my 2020 target. But, I have some reasonable excuses and other projects in the pipeline to blame. However, today we will be talking about a very interesting company called 'Neuralink'. It's currently working on the brain-machine interface. I know it's a topic that can make you overwhelmed pretty quickly. But, bare with me and we will together try to grasp those concepts. What is Neuralink? So, what the heck is Neuralink? It's a company founded by Elon Musk and is currently working on brain-machine interface research. The long term intention for Nueralink is to help us achieve symbiosis with AI. And, to provide us with a way to get along in this super fast-changing world. More on that later. Before you raise your eyebrows and start imagining a dystopian future, some real-world scenarios can be achieved shortly. In simple t…

Geeky Shots: What is Cache?


Hello everyone, hope you all doing great. Today, I am going to discuss one of the most confusing things, Cache, I would try my best to stick to the topic without any distraction. My objective is that by the end of the article, you will have a strong understanding of cache. I won't be going too deep because it is easy to get confused about it. Having said that, I won't be going for information any less than required.

What is Cache?

Cache memory is the fastest storage on the CPU, which stores the most frequently used data and instructions from RAM. This reduces the processing time and delivers you faster performance. As soon as you are given a task to your  CPU, it goes to cache before primary memory. If data is found in the cache, then it's called a "cache hit". Otherwise, it's called a "cache miss", this also helps for cache management i.e. Whether to keep data in cache or not. Let me put it this way, you won't instantly remember if I ask you what you did at work 15 days ago at 5: 00 pm but you remember what you did this morning or things which you do every day. This is similar to what cache does. It stores the most frequent data or the location of that data in the memory to be exact.

Why We Need Cache Memory?

So, why do we need Cache? Aren't the storage drive (hard disk drive or solid state drive) or memory (RAM/ Dynamic Memory) fast enough? The answer to this question is a clear NO. Here's how the hierarchy works. Static Memory (cache memory) > Dynamic/Main Memory (RAM) > Storage  (HDD/SSD).


Now, how much of a difference do they have. Storage memory is way slower to even compare. And for RAM, even the fastest DDR4 memory works at 2133 MHz. And the CPU can be anywhere from 1.6 GHz to 3.7 GHz. And these processors are at least dual core if not quad-core or octa-core. And this is why RAM is not as fast as processors. Because there are multiple cores, who need to access memory at the same rate. If the CPU needs to wait for a long time, it makes your processing time long.

Now, you might be thinking that if cache memory is so fast, then why not all memory is cache memory. Well, I think most of you have already guessed it. Yes, It's super-expensive. Recently, we have seen a reduction in SSD pricing, that too after SSDs been around for years now. What I am trying to say is that we all are aware of the price difference between SSDs and HDDs. And the price difference for the cache is way higher than that.

Types Of Cache?


There are various kinds of cache memory, for hardware and software. It works the same way and for reasons as said above. In the hardware section, CPU, GPU both have some amount of cache memory. On the software side, there are disc cache, web cache and a lot more. No matter what, but their function is the same.

In addition to that, there are also different levels of cache. For example, there are three levels of CPU cache, namely L1, L2, and L3. L1 have less capacity but faster than L2 (more capacity), L1 operates at the same speed of CPU. On the other hand, L3 has more capacity than L2 and L1 but is slower than them. Also, L1 and L2 have their own cores. You might be asking yourself how do they store data?  L1 stores the most frequently used data. L2 stores the data missed by L1 and so on. 

Make sure to share your thoughts in the comment section below. And, for all the updates, you can follow me on InstagramFacebook, and Twitter.

Thank You & Stay Tuned

    




Comments

Popular Posts