Pros and Cons of Separate Read / Write Cache Spaces Topic is solved

FAQ, getting help, user experience about PrimoCache
Post Reply
TomB
Level 5
Level 5
Posts: 44
Joined: Wed Jul 29, 2020 11:15 pm

Pros and Cons of Separate Read / Write Cache Spaces

Post by TomB »

Hello, Primo people!

I just stumbled on PrimoCache a few days ago, when shopping for memory and SSD for my home computer.

I trialed it for only a few days and then purchased it just a couple of days later.

I'm not really a gamer at all. I'm just an old-time mainframe guy that still likes to play with computers, and I have had more fun tweaking this program than I have had in quite a while. I've also enjoyed reading the online documentation and technical discussions in the Community Forum. The docs and answers from Support appear to be lucid and concise. I think this is important with technical discussions, since it is easy to misunderstand exactly what is being discussed. Anyway, this is just a great product and the company seems just great!

Ok, so all that having been said, I am not really asking for particular settings for particular situations; I just have a couple of general questions:

1) I would like to know what are the advantages and disadvantages of using Shared R/W Cache Spaces or of using Individual R/W Cache Spaces?
2) Also, are these trade-offs the same for L1 (RAM) Cache and L2 (SSD) Cache? Is this why the default L2 Setting is Read-Only or are these questions unrelated?

Thank you all so much for your thoughts, and thank you, Romex, for developing such an amazingly great piece of software!

Tom
User avatar
Support
Support Team
Support Team
Posts: 3623
Joined: Sun Dec 21, 2008 2:42 am

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by Support »

Thank you for your purchasing and support to us!
TomB wrote: Fri Jul 31, 2020 6:32 am 1) I would like to know what are the advantages and disadvantages of using Shared R/W Cache Spaces or of using Individual R/W Cache Spaces?
When cache is full of data, PrimoCache will discard certain old cached data. Deciding what data to be discarded are different between Shared and Individual Cache. If you separate read/write space, PrimoCache will discard old data in the Read space if new data to be cached is read-data, and discard old data in the Write space if new data is write-data. While with shared space, PrimoCache choose data to be discarded in the whole cache space.
So the pro of the individual cache is that cached read data won't be affected by write requests and vice versa. The con is that space size is limited to a certain portion of the whole space for read/write requests. For shared cache space, read/write requests can utilize the whole cache space, but their cached data might be discarded by new write/read requests.
TomB wrote: Fri Jul 31, 2020 6:32 am 2) Also, are these trade-offs the same for L1 (RAM) Cache and L2 (SSD) Cache?
Yes.
TomB wrote: Fri Jul 31, 2020 6:32 am Is this why the default L2 Setting is Read-Only or are these questions unrelated?
Usually SSDs are used as L2 cache and SSDs have limited write cycles, so to reduce too much writes in SSDs, L2 is set to only cache read-data that is 100% read space. With 0% write space, no write-data will be cached into L2.
TomB
Level 5
Level 5
Posts: 44
Joined: Wed Jul 29, 2020 11:15 pm

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by TomB »

RE: "So the pro of the individual cache is that cached read data won't be affected by write requests and vice versa. The con is that space size is limited to a certain portion of the whole space for read/write requests. For shared cache space, read/write requests can utilize the whole cache space, but their cached data might be discarded by new write/read requests."

This is so great. This is what I thought.

So it sounds like the pro of a shared L1 or L2 space is that the cache space is more dynamic and can respond to more writes or more reads, depending as the workload changes over time. But the downside of shared L1 / L2 may be that if huge or very many write requests arrive, then the cache may flush all of my read requests. Or more likely the reverse: If many, many read requests come, then shared space may flush all my cached write data?

Thank you for you clear and timely answers. I am having a wonderful time tweaking this program. It is like the game of chess or like a programming language. You have certain rules / statements, but there are many things that can be done with them!
Last edited by TomB on Sat Aug 01, 2020 5:24 am, edited 1 time in total.
TomB
Level 5
Level 5
Posts: 44
Joined: Wed Jul 29, 2020 11:15 pm

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by TomB »

I am using separate R/W spaces and I think I will continue to do so, since I have enough RAM and enough L2 SSD. I will play with this for a few more days and perhaps I will have one more question for you ...

Thanks again for your help with clarification ...
TomB
Level 5
Level 5
Posts: 44
Joined: Wed Jul 29, 2020 11:15 pm

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by TomB »

Please, one more question, just to make sure I understand? If I have Individual R/W cache spaces and I have deferred-write enabled, then if a write request arrives for a data block that is not in write cache and also not in read cache. Then PrimoCache will service the request to the write cache of L1 and L2, yes? But my question is this: Will this cached write also be available for read if a read request now comes for this same block (which is now only in the write cache, I think) ?

(Also, I am sorry to take too much of your time. I am just having fun, so there is no hurry for this answer.)

Thank you again and please have a great day.
User avatar
Support
Support Team
Support Team
Posts: 3623
Joined: Sun Dec 21, 2008 2:42 am

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by Support »

TomB wrote: Sat Aug 01, 2020 5:13 am So it sounds like the pro of a shared L1 or L2 space is that the cache space is more dynamic and can respond to more writes or more reads, depending as the workload changes over time. But the downside of shared L1 / L2 may be that if huge or very many write requests arrive, then the cache may flush all of my read requests. Or more likely the reverse: If many, many read requests come, then shared space may flush all my cached write data?
Yes, exactly.
User avatar
Support
Support Team
Support Team
Posts: 3623
Joined: Sun Dec 21, 2008 2:42 am

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by Support »

TomB wrote: Sat Aug 01, 2020 5:50 am But my question is this: Will this cached write also be available for read if a read request now comes for this same block (which is now only in the write cache, I think) ?
Good question! The answer is yes. All cached data blocks are available for read requests whether they belong to read or write space. We don't waste the performance. ;)
TomB
Level 5
Level 5
Posts: 44
Joined: Wed Jul 29, 2020 11:15 pm

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by TomB »

Support wrote: Sat Aug 01, 2020 9:57 am
TomB wrote: Sat Aug 01, 2020 5:50 am But my question is this: Will this cached write also be available for read if a read request now comes for this same block (which is now only in the write cache, I think) ?
Good question! The answer is yes. All cached data blocks are available for read requests whether they belong to read or write space. We don't waste the performance. ;)

Hooray!!

Exactly what one would hope for!

Thanks again for taking time to reply to my questions. With this specific information, I will play for a few more days and perhaps ! will have another question afterwards.

Thanks so much for your help!

Tom
User avatar
Support
Support Team
Support Team
Posts: 3623
Joined: Sun Dec 21, 2008 2:42 am

Re: Pros and Cons of Separate Read / Write Cache Spaces

Post by Support »

You are welcome!
Post Reply