Question
Mack Altman · Feb 23, 2017

How common is it to utilize $ZSTORAGE?

While I can see the benefits that $ZSTORAGE could have if used properly, I have not seen it used in the environments I have worked in. I was wondering if there are any developers that promote its usage.

If used properly, I would imagine it could be highly effective in maximizing free memory since some processes will never go over X amount, while others may very well need much more.

0
0 305
Discussion (2)2
Log in or sign up to continue

Process memory is allocated as required, so decreasing $ZSTORAGE would not decrease actual memory usage.

With this you can override the global setting. It is useful to have a maximum to protect you from having a "runaway" process to eat all your memory. If you need more in a process (for example I needed to instantiate a very large XML file as an object), you could overide the global setting (in my case 4GByte). But since only one specific process needs it, it is better to set it dynamically in that process. As Eduard said, it is only a maximum, it is not claimed when the process starts but only when needed.