Variable Memory Size
#1

How much memory does a single variable consume?
Is there a difference in the amount of memory between variable types such as _ bool Text and etc?
Does the amount of memory goes straight into the .amx size?
Is there a memory limit? Should I have any worries about memory consumption except for .amx size? Because the scale is really low comparing to the amount of RAM servers have.

tnx.
Reply
#2

https://sampforum.blast.hk/showthread.php?tid=275142

https://sampforum.blast.hk/showthread.php?pid=174871#pid174871

important threads
Reply
#3

Read them both.. didn't fully answer my questions.
The amx size is generated by stack or global variables? (probably both?) how does it work?
Why is the memory allocated for stack is so low in comparison to general memory?
As long as I don't get the stack warning message, should I care about memory consumption?
Is there any difference between regular var types? Or they are all 32bit?

Tnx again.
Reply
#4

That makes it clearer, thanks.
One more question left...
Should I care about memory as long I stay away from stack/heap overflow? Obviously it'll longer the compile time but anything else performence-wise? Because still, that's nothing comparing to what servers allow.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)